عکس zahta
In this repository, I have written about my experiences in studying Machine learning. Also, I have included the solutions of some Machine learning exercises and my educational projects.Jupyter Notebook
موضوع‌ها
۰
فورک‌ها
۰
ستاره‌ها
۵
تاریخ ایجاد
۲۰ بهمن ۱۳۹۸
آخرین بروزرسانی
۵ روز قبل

🍀 My Path to Machine Learning 🍀
💡 Do not follow where the path may lead. Go instead where there is no path and leave a trail. Ralph Waldo Emerson

What Is Machine Learning?
📗 Machine Learning is the science (and art) of programming computers so they can learn from data.
📘 A slightly more general definition: Machine Learning is the field of study that gives computers the ability to learn without being explicitly programmed (Arthur Samuel-1959)
📙 A more engineering-oriented one: A computer program is said to learn from experience E with respect to some task T and some performance measure P, if its performance on T, as measured by P, improves with experience E (Tom Mitchell-1997)

✏️ Projects and Exercises

✏️ Important Concepts

✏️ Notes and Experiences

  • Anaconda:

    • Anaconda Installation

    • How to Install Anaconda on Ubuntu 20.04

    • Install Miniconda3 on Linux:

      • Download the latest shell script:

        wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh
        
      • Make the miniconda installation script executable:

          chmod +x Miniconda3-latest-Linux-x86_64.sh
        
      • Run miniconda installation script:

          ./Miniconda3-latest-Linux-x86_64.sh
        
    • Conda (Starting and managing)

      1️⃣ conda --version (in a terminal command line) ➡️ Conda version number (if it is installed properly).

      2️⃣ conda update conda and then y (if needed) ➡️ Update conda to the current version.

      • Anaconda Prompt: 1️⃣ Start menu 2️⃣ search for and open "Anaconda Prompt".
      • Windows Command Prompt: 1️⃣ Start menu 2️⃣ search for and open "cmd".
        • When I typed conda --version in the Command Prompt, I encountered conda is not recognized as an internal or external command, operable program or batch file. This issue was resolved by Method 3 of this page.
    • Managing environments

      • Some useful terminal commands:

        1️⃣conda create --name envname or conda create -n envname ➡️ Create the environment "envname".

        2️⃣ conda activate envname➡️ Activate the environment "envname".

        3️⃣ conda info --envs➡️ A list of all your environments (active environment with an asterisk (*)).

        4️⃣ conda install pkgname ➡️ Install the package "pkgname" in the active environment.

        5️⃣ conda list -n envname or conda list➡️ A list of all packages installed in the active environment.

        6️⃣ conda list -n envname pkgname➡️ To see if the package "pkgname" is installed in "envname".

        7️⃣ conda install --revision=0 or conda install --rev 0➡️ Restore active environment to the default version.

        8️⃣ conda deactivate ➡️ Deactivate environment.

        9️⃣ conda remove --name envname --all➡️ Remove the environment "envname".

      • If you encontered the Error 403 while conda update conda or conda create -n envname:

        conda config --add channels conda-canary
        conda config --remove channels defaults
        

        or refer to Troubleshooting (403 Error).

      • Conda cheat sheet

    • Python and Jupyter Lab

      • Python Installation (by a terminal command line): Type conda install python=vnumber to install version "vnumber" of Python in the active environment.

      • Jupyter Lab Installation (by a terminal command line): Type conda install jupyterlab to install Jupyter Lab in the active environment.

      • Use jupyter lab to start Jupyter Lab.

      • Installing the IPython kernel

        • Terminal command: python -m ipykernel install --user --name envname --display-name "Python (envname)"
    • conda-forge

      • Installing packages from conda-forge:

        • conda config --add channels conda-forge ➡️ Register the conda-forge channel as a package source for conda

        • conda config --set channel_priority strict ➡️ Activate the strict channel priority.

  • Python:

    • GitHub Repository: Practical Python

    • Python Cheat Sheet

    • Python Cheat Sheet-Complete

    • Installation of python libraries:

      • Installing libraries with the command conda install "libname":
      Some libraries could not be installed with the above command line. Then, you can either do `pip install 
      

      "libname"` or download the source and install that manually as follows.

      • Installing libraries manually:

        Download the source file of the library containing the file setup.py ➡️ Launch the anaconda prompt and

      navigate to the folder that contains the extracted downloaded files , e.g., with the command cd /d d:\anaconda3\tflearn- master ➡️ Run python setup.py install

  • Colab:

    • What is Colaboratory?

    • A good approach to import local datasets into the Colab:

        1️⃣ Compress the dataset, i.e., as a `zip` file 2️⃣ Upload the compressed file to your Google drive 3️⃣ Mount your Google drive into the colab 4️⃣ Unzip the compressed file in Colab.
      
    • A good approach to unzip dataset files from Google drive into the content folder in colab:

        ```
        import os
        if not os.path.exists("/content/dataset"):
          print("unzip files!")
          !unzip -q "/content/drive/My Drive/dataset.zip"
        ```
      
    • To prevent Google Colab from disconnecting:

      Google Colab notebooks have an idle timeout of 90 minutes and absolute timeout of 12 hours. This means, if user does not interact with his Google Colab notebook for more than 90 minutes, its instance is automatically terminated. Also, maximum lifetime of a Colab instance is 12 hours.

        To prevent Google Colab from disconnecting, Open developer settings in your web browser with `Ctrl+Shift+I` ➡️ Click on console tab  ➡️  Type the following code block in the console prompt:
      
          function ClickConnect(){
       console.log("Working"); 
       document.querySelector("colab-toolbar-button").click() 
       }setInterval(ClickConnect,60000)
      
  • Markdown:

  • Git:

  • Books:

  • Other good resources:

  • Other useful links: