Skip to content

guowenbin90/AI-MachineLearning

Repository files navigation

Run ud120-projects in Anaconda step by step

Sometimes because of the system environment or path issues, we can't run the code directly. Therefore, I used Anaconda to install the virutal environment to run the code. Here are the procedures to run the code step by step.

Install Anaconda

Download Anaconda from the official website to install it based on the system requirements.

Create virtual environment to run the python code

  • (Windows): Anaconda Powershell Prompt
  • (Mac): Terminal
  1. Check the python version: python --version
  2. Here is the cheat sheet to create the virtual environment.
  3. My virtual environment (udacity): conda create --name udacity
  4. Enter the vitural environemnt: conda activate udacity
  5. Install Scikit-Learn using conda: conda install scikit-learn
  6. Install other modules using conda install ... if it has 'ModuleNotFoundError'.
  7. Download the ud120-projects from github
  8. Enter the directory of the project, such as ..\ud120-projects-master\naive_bayes
  9. Run the python code: python nb_author_id.py
  10. It will show the results of in the terminal: No. of Chris training emails : 7936 No. of Sara training emails : 7884

Edit the code with Visual Studio Code

About

Introduction to Machine Learning, course of Coursera

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages