No module named as 'sklearn'

ModuleNotFoundError: This app has encountered an error. The original error message is redacted to prevent data leaks. Full error details have been recorded in the logs (if you’re on Streamlit Cloud, click on ‘Manage app’ in the lower right of your app).

Traceback:

File "/home/adminuser/venv/lib/python3.9/site-packages/streamlit/runtime/scriptrunner/script_runner.py", line 534, in _run_script
    exec(code, module.__dict__)File "/mount/src/amaa/streamlit_app.py", line 4, in <module>
    import sklearn

Hello @Kanaujia_Abhishek_Ra, and a warm welcome to our Community! :wave:

We’re keen to assist you and would appreciate it if you could share your code with us.

Please ensure that scikit-learn is installed on your system. You can do this by executing pip install scikit-learn in your terminal. Additionally, if you’re deploying your project on Community Cloud, don’t forget to include scikit-learn in your requirements.txt file.

Best wishes,
Charly

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.