├── 001_Convert_IPython_to_PDF ├── 001_Convert_IPython_to_PDF.ipynb ├── README.md └── img │ ├── JLUFE.png │ ├── j2p1.png │ └── j2p2.png ├── 002_Create_Digital_Clock ├── 002_Create_Digital_Clock_and_Stopwatch.ipynb ├── README.md ├── dclock.png ├── img │ └── stopwatch.ico └── swatch.png ├── 003_Convert_.py_to_.exe ├── 003_Convert_.py_to_.exe.ipynb ├── README.md ├── __pycache__ │ └── clock.cpython-38.pyc ├── clock.exe ├── clock.py └── img │ ├── py2exe1.png │ ├── py2exe2.png │ ├── py2exe3.png │ ├── py2exe4.png │ └── py2exe5.png ├── 004_Find_IP_Address ├── 004_Find_IP_Address.ipynb └── README.md ├── 005_Test_Internet_Speed ├── 005_Test_Internet_Speed.ipynb ├── README.md ├── result.png └── speed.ico ├── 006_Check_Weather_Forecast ├── 006_Check_Weather_Forecast.ipynb ├── README.md └── output.png ├── 007_Create_AudioBook_from_PDF ├── 007_Create_AudioBook_from_PDF.ipynb ├── README.md ├── demo.pdf └── demo1.pdf ├── 008_Generate_Random_Jokes ├── 008_Generate_Random_Jokes.ipynb └── README.md ├── 009_Convert_image_to_ASCII ├── 009_Convert_image_to_ASCII_and_PencilSketch.ipynb ├── README.md ├── ascii_img.txt ├── pywhatkit_dbs.txt ├── result.png ├── result2.png └── rose.png ├── 010_Perform_Google_Search ├── 010_Perform_Google_Search.ipynb ├── README.md └── pywhatkit_dbs.txt ├── 011_Generate_QR_Code ├── 011_Generate_QR_Code.ipynb ├── README.md └── githubID.png ├── 012_Encode_CAPTCHA ├── 012_Encode_CAPTCHA.ipynb ├── CAPTCHA_1.png ├── CAPTCHA_2.wav └── README.md ├── 013_Unzip_File ├── 013_Unzip_File.ipynb ├── README.md ├── demo.zip └── unzip │ └── 013_Unzip_File │ └── 013_Unzip_File.ipynb ├── 014_Run_JavaScript_in_Python ├── 014_Run_JavaScript_in_Python.ipynb └── README.md ├── 015_Web_Scraping_Covid-19_Data ├── 015_Web_Scraping_Covid-19_Data.ipynb ├── Covid-19_data.csv ├── README.md ├── wordometer1.png └── wordometer2.png ├── 016_Web_Scraping_CoWin_Vaccine_Slots ├── 016_Web_Scraping_CoWin_Vaccine_Slots.ipynb ├── CoWin.png └── README.md ├── 017_Check_Weather_Forecast_with_GUI ├── 017_Check_Weather_Forecast_with_GUI.ipynb ├── README.md ├── get_weather_icons.ipynb └── img │ ├── 01d.png │ ├── 02d.png │ ├── 03d.png │ ├── 04d.png │ ├── landscape.png │ ├── result_1.png │ ├── result_2.png │ └── sun_icon.ico ├── 018_Draw_Sakura_Tree ├── 018_Draw_Sakura_Tree.ipynb ├── README.md └── sakura.png ├── 019_Plagiarism_Checker ├── 019_Plagiarism_Checker.ipynb ├── Arthur.txt ├── Ben.txt ├── Clark.txt ├── README.md └── output.png ├── 020_Road_Detection ├── 020_Road_Detection.ipynb └── img │ ├── road_1.jpeg │ ├── road_2.jpeg │ └── road_3.jpeg ├── LICENSE ├── README.md └── img └── dnld_rep.png /001_Convert_IPython_to_PDF/001_Convert_IPython_to_PDF.ipynb: -------------------------------------------------------------------------------- 1 | { 2 | "cells": [ 3 | { 4 | "cell_type": "markdown", 5 | "metadata": {}, 6 | "source": [ 7 | "\n", 8 | "All the IPython Notebooks in Python Mini-Projects series by Dr. Milan Parmar are available @ **[GitHub](https://github.com/milaan9/91_Python_Mini_Projects)**\n", 9 | "" 10 | ] 11 | }, 12 | { 13 | "cell_type": "markdown", 14 | "metadata": {}, 15 | "source": [ 16 | "# Convert Jupyter Notebook to PDF\n", 17 | "\n", 18 | "
\n", 19 | "\n", 20 | "
\n", 21 | "\n", 22 | "There is an easy way to turn our Jupyer Notebooks into PDF files. Just with a simple setup, you can access your notebook as a PDF." 23 | ] 24 | }, 25 | { 26 | "cell_type": "markdown", 27 | "metadata": {}, 28 | "source": [ 29 | "## Jupyter-to-PDF\n", 30 | "\n", 31 | "1. The first thing we need to do is to install the necessary package. Here we would use the package called notebook-as-pdf to help us convert Jupyter Notebook as PDF file. You need to run the following code in your command prompt. If you are using Anaconda type in anaconda command prompt.\n", 32 | "\n", 33 | "**`pip install -U notebook-as-pdf`**\n", 34 | "\n", 35 | "2. We also need an additional setup for Chromium. It is used to perform the HTML to PDF conversion. Just run the following code in your code prompt. If you are using Anaconda type in anaconda command prompt.\n", 36 | "\n", 37 | "**`pyppeteer-install`**\n", 38 | "\n", 39 | "3. Just like that, we have already finished our preparation. Now, let’s **open the notebook** you intend to convert into the PDF. In your notebook, click the **File** menu bar then select **Download as** then select the **PDF via HTML (.pdf)** to transform the notebook.\n", 40 | "\n", 41 | "
\n", 42 | "\n", 43 | "
\n", 44 | "\n", 45 | "or\n", 46 | "\n", 47 | "4. (optional) Just like that, you already have your notebook as a PDF file. If you prefer to use command prompt to convert the notebook, you could do it with the following code.\n", 48 | "\n", 49 | "**`jupyter-nbconvert --to PDFviaHTML example.ipynb`**\n", 50 | "\n", 51 | "The result would be called example.pdf as our Jupyter Notebook is called example.ipynb." 52 | ] 53 | }, 54 | { 55 | "cell_type": "code", 56 | "execution_count": null, 57 | "metadata": {}, 58 | "outputs": [], 59 | "source": [] 60 | } 61 | ], 62 | "metadata": { 63 | "hide_input": false, 64 | "kernelspec": { 65 | "display_name": "Python 3", 66 | "language": "python", 67 | "name": "python3" 68 | }, 69 | "language_info": { 70 | "codemirror_mode": { 71 | "name": "ipython", 72 | "version": 3 73 | }, 74 | "file_extension": ".py", 75 | "mimetype": "text/x-python", 76 | "name": "python", 77 | "nbconvert_exporter": "python", 78 | "pygments_lexer": "ipython3", 79 | "version": "3.8.8" 80 | }, 81 | "toc": { 82 | "base_numbering": 1, 83 | "nav_menu": {}, 84 | "number_sections": true, 85 | "sideBar": true, 86 | "skip_h1_title": false, 87 | "title_cell": "Table of Contents", 88 | "title_sidebar": "Contents", 89 | "toc_cell": false, 90 | "toc_position": {}, 91 | "toc_section_display": true, 92 | "toc_window_display": false 93 | }, 94 | "varInspector": { 95 | "cols": { 96 | "lenName": 16, 97 | "lenType": 16, 98 | "lenVar": 40 99 | }, 100 | "kernels_config": { 101 | "python": { 102 | "delete_cmd_postfix": "", 103 | "delete_cmd_prefix": "del ", 104 | "library": "var_list.py", 105 | "varRefreshCmd": "print(var_dic_list())" 106 | }, 107 | "r": { 108 | "delete_cmd_postfix": ") ", 109 | "delete_cmd_prefix": "rm(", 110 | "library": "var_list.r", 111 | "varRefreshCmd": "cat(var_dic_list()) " 112 | } 113 | }, 114 | "types_to_exclude": [ 115 | "module", 116 | "function", 117 | "builtin_function_or_method", 118 | "instance", 119 | "_Feature" 120 | ], 121 | "window_display": false 122 | } 123 | }, 124 | "nbformat": 4, 125 | "nbformat_minor": 2 126 | } 127 | -------------------------------------------------------------------------------- /001_Convert_IPython_to_PDF/README.md: -------------------------------------------------------------------------------- 1 |

2 | Last Commit 3 | 4 |

5 | 6 | 7 | 8 | # Convert IPython to PDF 9 | 10 | In this class, you'll learn how to Convert IPython to PDF using python. 11 | 12 |

13 | 14 |

15 | 16 | 17 | ## Prerequisites: 18 | 19 | 1. Python Basics 20 | 2. -U notebook-as-pdf Basics 21 | 3. pyppeteer-install module 22 | 23 | --- 24 | 25 | 26 | ## Install Necessary Modules: 27 | 28 | Open your [![Anaconda](https://img.shields.io/badge/Anaconda-342B029.svg?&style=flate&logo=anaconda&logoColor=white)](https://www.anaconda.com/products/individual) Prompt propmt and type and run the following command (individually): 29 | 30 | - pip install -U notebook-as-pdf 31 | 32 | - pyppeteer-install 33 | 34 | Once Installed now we can import it inside our python code. 35 | 36 | --- 37 | 38 | ## Frequently asked questions ❔ 39 | 40 | ### How can I thank you for writing and sharing this tutorial? 🌷 41 | 42 | You can Star Badge and Fork Badge Starring and Forking is free for you, but it tells me and other people that it was helpful and you like this tutorial. 43 | 44 | Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) if you aren't here already and click ➞ **`✰ Star`** and **`ⵖ Fork`** button in the top right corner. You'll be asked to create a GitHub account if you don't already have one. 45 | 46 | --- 47 | 48 | ### How can I read this tutorial without an Internet connection? GIF 49 | 50 | 1. Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) and click the big green ➞ **`Code`** button in the top right of the page, then click ➞ [**`Download ZIP`**](https://github.com/milaan9/91_Python_Mini_Projects/archive/refs/heads/main.zip). 51 | 52 | ![Download ZIP](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/img/dnld_rep.png) 53 | 54 | 2. Extract the ZIP and open it. Unfortunately I don't have any more specific instructions because how exactly this is done depends on which operating system you run. 55 | 56 | 3. Launch ipython notebook from the folder which contains the notebooks. Open each one of them 57 | 58 | `Kernel > Restart & Clear Output` 59 | 60 | This will clear all the outputs and now you can understand each statement and learn interactively. 61 | 62 | If you have git and you know how to use it, you can also clone the repository instead of downloading a zip and extracting it. An advantage with doing it this way is that you don't need to download the whole tutorial again to get the latest version of it, all you need to do is to pull with git and run ipython notebook again. 63 | 64 | --- 65 | 66 | ## Authors ✍️ 67 | 68 | I'm Dr. Milaan Parmar and I have written this tutorial. If you think you can add/correct/edit and enhance this tutorial you are most welcome🙏 69 | 70 | See [github's contributors page](https://github.com/milaan9/91_Python_Mini_Projects/graphs/contributors) for details. 71 | 72 | If you have trouble with this tutorial please tell me about it by [Create an issue on GitHub](https://github.com/milaan9/91_Python_Mini_Projects/issues/new). and I'll make this tutorial better. This is probably the best choice if you had trouble following the tutorial, and something in it should be explained better. You will be asked to create a GitHub account if you don't already have one. 73 | 74 | If you like this tutorial, please [give it a ⭐ star](https://github.com/milaan9/91_Python_Mini_Projects). 75 | 76 | --- 77 | 78 | ## Licence 📜 79 | 80 | You may use this tutorial freely at your own risk. See [LICENSE](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/LICENSE). 81 | 82 | Copyright (c) 2020 Dr. Milaan Parmar 83 | 84 | --- 85 | 86 |
87 |

Connect with me 88 |

89 |

90 | LinkedIn 91 | Instagram 92 | Facebook 93 | Gmail 94 |

95 | -------------------------------------------------------------------------------- /001_Convert_IPython_to_PDF/img/JLUFE.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/001_Convert_IPython_to_PDF/img/JLUFE.png -------------------------------------------------------------------------------- /001_Convert_IPython_to_PDF/img/j2p1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/001_Convert_IPython_to_PDF/img/j2p1.png -------------------------------------------------------------------------------- /001_Convert_IPython_to_PDF/img/j2p2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/001_Convert_IPython_to_PDF/img/j2p2.png -------------------------------------------------------------------------------- /002_Create_Digital_Clock/002_Create_Digital_Clock_and_Stopwatch.ipynb: -------------------------------------------------------------------------------- 1 | { 2 | "cells": [ 3 | { 4 | "cell_type": "markdown", 5 | "metadata": {}, 6 | "source": [ 7 | "\n", 8 | "All the IPython Notebooks in **Python Mini-Projects** series by Dr. Milaan Parmar are available @ **[GitHub](https://github.com/milaan9/91_Python_Mini_Projects)**\n", 9 | "" 10 | ] 11 | }, 12 | { 13 | "cell_type": "markdown", 14 | "metadata": {}, 15 | "source": [ 16 | "# Python Program to Create Digital Clock" 17 | ] 18 | }, 19 | { 20 | "cell_type": "code", 21 | "execution_count": 1, 22 | "metadata": { 23 | "ExecuteTime": { 24 | "end_time": "2021-09-21T07:01:44.204077Z", 25 | "start_time": "2021-09-21T06:46:16.505015Z" 26 | } 27 | }, 28 | "outputs": [], 29 | "source": [ 30 | "'''\n", 31 | "Python Program to Create Digital Clock\n", 32 | "'''\n", 33 | "# Import necessary modules!\n", 34 | "from tkinter import *\n", 35 | "from tkinter.ttk import *\n", 36 | "\n", 37 | "# Import time\n", 38 | "from time import strftime\n", 39 | "\n", 40 | "# Create UI for our digital clock.\n", 41 | "root = Tk()\n", 42 | "\n", 43 | "# Set the title of our clock using title method.\n", 44 | "root.title(\"Digital clock\")\n", 45 | "\n", 46 | "# Define a clock function to get the time\n", 47 | "# Use strftime method to get the time and store it inside a string and name the string as tick\n", 48 | "def clock():\n", 49 | " tick = strftime(\"%H:%M:%S %p\")\n", 50 | " \n", 51 | " # Set the label using config method.\n", 52 | " label.config(text =tick)\n", 53 | "\n", 54 | " # Call our clock function and use the after method to do the same\n", 55 | " label.after(1000, clock)\n", 56 | "\n", 57 | "# Use label method to store our title. \n", 58 | "label = Label(root, font = (\"segoe\", 60), foreground = \"yellow\", background = \"black\")\n", 59 | "\n", 60 | "# Use pack method to pack our label\n", 61 | "# Define the alignment of the label using the anchor method.\n", 62 | "label.pack(anchor= \"center\")\n", 63 | "\n", 64 | "# Call our clock function and at the end we will call it mainloop\n", 65 | "clock()\n", 66 | "mainloop()" 67 | ] 68 | }, 69 | { 70 | "cell_type": "markdown", 71 | "metadata": {}, 72 | "source": [ 73 | "

\n", 74 | " \n", 75 | "

" 76 | ] 77 | }, 78 | { 79 | "cell_type": "markdown", 80 | "metadata": {}, 81 | "source": [ 82 | "# Python Program to Create Stopwatch" 83 | ] 84 | }, 85 | { 86 | "cell_type": "code", 87 | "execution_count": 2, 88 | "metadata": { 89 | "ExecuteTime": { 90 | "end_time": "2021-09-21T07:01:50.719877Z", 91 | "start_time": "2021-09-21T07:01:44.207016Z" 92 | } 93 | }, 94 | "outputs": [], 95 | "source": [ 96 | "'''\n", 97 | "Python Program to Create Stowatch\n", 98 | "'''\n", 99 | "# Import necessary modules!\n", 100 | "import tkinter as Tkinter\n", 101 | "\n", 102 | "# Import datetime\n", 103 | "from datetime import datetime\n", 104 | "\n", 105 | "counter=66600\n", 106 | "running=False\n", 107 | "\n", 108 | "def counter_label(label):\n", 109 | " def count():\n", 110 | " if running:\n", 111 | " global counter\n", 112 | "\n", 113 | " # To manage the initial delay.\n", 114 | " if counter==66600:\n", 115 | " display=\"Starting...⏳\"\n", 116 | " else:\n", 117 | " tt=datetime.fromtimestamp(counter)\n", 118 | " string=tt.strftime(\"%H:%M:%S\")\n", 119 | " display=string\n", 120 | "\n", 121 | " label[\"text\"]=display\n", 122 | " label.after(1000, count)\n", 123 | " counter+=1\n", 124 | "\n", 125 | " # Triggering the start of the counter.\n", 126 | " count()\n", 127 | "\n", 128 | "# Start function of the stopwatch\n", 129 | "def Start(label):\n", 130 | " global running\n", 131 | " running=True\n", 132 | " counter_label(label)\n", 133 | " start[\"state\"]=\"disabled\"\n", 134 | " stop[\"state\"]=\"normal\"\n", 135 | " reset[\"state\"]=\"normal\"\n", 136 | "\n", 137 | "# Stop function of the stopwatch\n", 138 | "def Stop():\n", 139 | " global running\n", 140 | " start[\"state\"]=\"normal\"\n", 141 | " stop[\"state\"]=\"disabled\"\n", 142 | " reset[\"state\"]=\"normal\"\n", 143 | " running=False\n", 144 | "\n", 145 | "# Reset function of the stopwatch\n", 146 | "def Reset(label):\n", 147 | " global counter\n", 148 | " counter=66600\n", 149 | "\n", 150 | " # If rest is pressed after pressing stop.\n", 151 | " if running == False:\n", 152 | " reset[\"state\"]=\"disabled\"\n", 153 | " label[\"text\"]=\"Click '▶' to Start⏱\"\n", 154 | "\n", 155 | " # If reset is pressed while the stopwatch is running.\n", 156 | " else:\n", 157 | " label[\"text\"]=\"Starting...⏳\"\n", 158 | "root=Tkinter.Tk()\n", 159 | "root.title(\"Stopwatch\")\n", 160 | "root.iconbitmap(\"img/stopwatch.ico\") # optional\n", 161 | "root.configure(bg=\"yellow\") #FFE873\n", 162 | "\n", 163 | "# Fixing the window size.\n", 164 | "root.minsize(width=350,height=100)\n", 165 | "label=Tkinter.Label(root,text=\"Click '▶' to Start⏱\",fg=\"#4B8BBE\",bg=\"yellow\",font=\"Verdana 25 bold\") #4B8BBE #FFE873\n", 166 | "label.pack()\n", 167 | "f=Tkinter.Frame(root)\n", 168 | "start=Tkinter.Button(f,text=\"Start ▶\",width=10,command=lambda:Start(label))\n", 169 | "stop=Tkinter.Button(f,text=\"Pause ⏸\",width=10,state=\"disabled\",command=Stop)\n", 170 | "reset=Tkinter.Button(f,text=\"Reset 🔁\",width=10,state=\"disabled\",command=lambda:Reset(label))\n", 171 | "f.pack(anchor=\"center\",pady=5)\n", 172 | "start.pack(side=\"left\")\n", 173 | "stop.pack(side=\"left\")\n", 174 | "reset.pack(side=\"left\")\n", 175 | "root.mainloop()" 176 | ] 177 | }, 178 | { 179 | "cell_type": "markdown", 180 | "metadata": {}, 181 | "source": [ 182 | "

\n", 183 | " \n", 184 | "

" 185 | ] 186 | }, 187 | { 188 | "cell_type": "code", 189 | "execution_count": null, 190 | "metadata": {}, 191 | "outputs": [], 192 | "source": [] 193 | } 194 | ], 195 | "metadata": { 196 | "hide_input": false, 197 | "kernelspec": { 198 | "display_name": "Python 3", 199 | "language": "python", 200 | "name": "python3" 201 | }, 202 | "language_info": { 203 | "codemirror_mode": { 204 | "name": "ipython", 205 | "version": 3 206 | }, 207 | "file_extension": ".py", 208 | "mimetype": "text/x-python", 209 | "name": "python", 210 | "nbconvert_exporter": "python", 211 | "pygments_lexer": "ipython3", 212 | "version": "3.8.8" 213 | }, 214 | "toc": { 215 | "base_numbering": 1, 216 | "nav_menu": {}, 217 | "number_sections": true, 218 | "sideBar": true, 219 | "skip_h1_title": false, 220 | "title_cell": "Table of Contents", 221 | "title_sidebar": "Contents", 222 | "toc_cell": false, 223 | "toc_position": {}, 224 | "toc_section_display": true, 225 | "toc_window_display": false 226 | }, 227 | "varInspector": { 228 | "cols": { 229 | "lenName": 16, 230 | "lenType": 16, 231 | "lenVar": 40 232 | }, 233 | "kernels_config": { 234 | "python": { 235 | "delete_cmd_postfix": "", 236 | "delete_cmd_prefix": "del ", 237 | "library": "var_list.py", 238 | "varRefreshCmd": "print(var_dic_list())" 239 | }, 240 | "r": { 241 | "delete_cmd_postfix": ") ", 242 | "delete_cmd_prefix": "rm(", 243 | "library": "var_list.r", 244 | "varRefreshCmd": "cat(var_dic_list()) " 245 | } 246 | }, 247 | "types_to_exclude": [ 248 | "module", 249 | "function", 250 | "builtin_function_or_method", 251 | "instance", 252 | "_Feature" 253 | ], 254 | "window_display": false 255 | } 256 | }, 257 | "nbformat": 4, 258 | "nbformat_minor": 2 259 | } 260 | -------------------------------------------------------------------------------- /002_Create_Digital_Clock/README.md: -------------------------------------------------------------------------------- 1 |

2 | Last Commit 3 | 4 |

5 | 6 | 7 | 8 | # Create Digital Clock 9 | 10 | In this class, you'll learn how to create digital clock and stopwatch using python 11 | 12 | **Digital Clock** 13 |

14 | 15 |

16 | 17 | **Stopwatch** 18 |

19 | 20 |

21 | 22 | 23 | 24 | ## Prerequisites: 25 | 26 | 1. Python Basics 27 | 2. tkinter module 28 | 3. tkinter.ttk module 29 | 30 | --- 31 | 32 | 33 | ## Install Necessary Modules: 34 | 35 | Since **`tkinter`** and **`tkinter.ttk`** modules are in-built modules, hence we do not need to install them separately. 36 | 37 | --- 38 | 39 | ## Frequently asked questions ❔ 40 | 41 | ### How can I thank you for writing and sharing this tutorial? 🌷 42 | 43 | You can Star Badge and Fork Badge Starring and Forking is free for you, but it tells me and other people that it was helpful and you like this tutorial. 44 | 45 | Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) if you aren't here already and click ➞ **`✰ Star`** and **`ⵖ Fork`** button in the top right corner. You'll be asked to create a GitHub account if you don't already have one. 46 | 47 | --- 48 | 49 | ### How can I read this tutorial without an Internet connection? GIF 50 | 51 | 1. Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) and click the big green ➞ **`Code`** button in the top right of the page, then click ➞ [**`Download ZIP`**](https://github.com/milaan9/91_Python_Mini_Projects/archive/refs/heads/main.zip). 52 | 53 | ![Download ZIP](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/img/dnld_rep.png) 54 | 55 | 2. Extract the ZIP and open it. Unfortunately I don't have any more specific instructions because how exactly this is done depends on which operating system you run. 56 | 57 | 3. Launch ipython notebook from the folder which contains the notebooks. Open each one of them 58 | `Kernel > Restart & Clear Output` 59 | 60 | This will clear all the outputs and now you can understand each statement and learn interactively. 61 | 62 | If you have git and you know how to use it, you can also clone the repository instead of downloading a zip and extracting it. An advantage with doing it this way is that you don't need to download the whole tutorial again to get the latest version of it, all you need to do is to pull with git and run ipython notebook again. 63 | 64 | --- 65 | 66 | ## Authors ✍️ 67 | 68 | I'm Dr. Milaan Parmar and I have written this tutorial. If you think you can add/correct/edit and enhance this tutorial you are most welcome🙏 69 | 70 | See [github's contributors page](https://github.com/milaan9/91_Python_Mini_Projects/graphs/contributors) for details. 71 | 72 | If you have trouble with this tutorial please tell me about it by [Create an issue on GitHub](https://github.com/milaan9/91_Python_Mini_Projects/issues/new). and I'll make this tutorial better. This is probably the best choice if you had trouble following the tutorial, and something in it should be explained better. You will be asked to create a GitHub account if you don't already have one. 73 | 74 | If you like this tutorial, please [give it a ⭐ star](https://github.com/milaan9/91_Python_Mini_Projects). 75 | 76 | --- 77 | 78 | ## Licence 📜 79 | 80 | You may use this tutorial freely at your own risk. See [LICENSE](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/LICENSE). 81 | 82 | Copyright (c) 2020 Dr. Milaan Parmar 83 | 84 | --- 85 | 86 |
87 |

Connect with me 88 |

89 |

90 | LinkedIn 91 | Instagram 92 | Facebook 93 | Gmail 94 |

95 | 96 | 97 | -------------------------------------------------------------------------------- /002_Create_Digital_Clock/dclock.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/002_Create_Digital_Clock/dclock.png -------------------------------------------------------------------------------- /002_Create_Digital_Clock/img/stopwatch.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/002_Create_Digital_Clock/img/stopwatch.ico -------------------------------------------------------------------------------- /002_Create_Digital_Clock/swatch.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/002_Create_Digital_Clock/swatch.png -------------------------------------------------------------------------------- /003_Convert_.py_to_.exe/003_Convert_.py_to_.exe.ipynb: -------------------------------------------------------------------------------- 1 | { 2 | "cells": [ 3 | { 4 | "cell_type": "markdown", 5 | "metadata": {}, 6 | "source": [ 7 | "\n", 8 | "All the IPython Notebooks in Python Mini-Projects series by Dr. Milan Parmar are available @ **[GitHub](https://github.com/milaan9/91_Python_Mini_Projects)**\n", 9 | "" 10 | ] 11 | }, 12 | { 13 | "cell_type": "markdown", 14 | "metadata": {}, 15 | "source": [ 16 | "# Convert .py to .exe file format\n", 17 | "\n", 18 | "A **`.py`** to **`.exe`** converter using a simple graphical interface and **[PyInstaller](https://www.pyinstaller.org/)** in Python." 19 | ] 20 | }, 21 | { 22 | "cell_type": "markdown", 23 | "metadata": {}, 24 | "source": [ 25 | "## Pre-requisites\n", 26 | "\n", 27 | "**Python : 3.5-3.9**\n", 28 | "\n", 29 | "To have the interface displayed in the images, you will need chrome. If chrome is not installed or --no-chrome is supplied, the default browser will be used.\n", 30 | "\n", 31 | ">**Note:** As of **[PyInstaller 4.0](https://github.com/pyinstaller/pyinstaller/releases/tag/v4.0)**, Python 2.7 is no longer supported. Read **[Python 2.7 Support](https://pypi.org/project/auto-py-to-exe/#python-27-support)** below for steps on how to use this tool with Python 2.7." 32 | ] 33 | }, 34 | { 35 | "cell_type": "markdown", 36 | "metadata": {}, 37 | "source": [ 38 | "## Open your Anaconda Command Promt and type:\n", 39 | "\n", 40 | "**`pip install auto-py-to-exe`**\n", 41 | "\n", 42 | "Then to run it, execute the following in the terminal:\n", 43 | "\n", 44 | "**`auto-py-to-exe`**" 45 | ] 46 | }, 47 | { 48 | "cell_type": "markdown", 49 | "metadata": {}, 50 | "source": [ 51 | "## Using the Application\n", 52 | "\n", 53 | "1. At first you will see empty console\n", 54 | "
\n", 55 | "
\n", 56 | "
\n", 57 | "\n", 58 | "
\n", 59 | "
\n", 60 | "
\n", 61 | "1. Select your script location (paste in or use a file explorer)\n", 62 | " - Outline will become blue when file exists \n", 63 | "
\n", 64 | "
\n", 65 | "
\n", 66 | "\n", 67 | "
\n", 68 | "
\n", 69 | "
\n", 70 | "2. Select other options and add things like an other files and output location\n", 71 | "
\n", 72 | "
\n", 73 | "
\n", 74 | "\n", 75 | "
\n", 76 | "
\n", 77 | "
\n", 78 | "3. Click the big blue button at the bottom to convert\n", 79 | "
\n", 80 | "
\n", 81 | "
\n", 82 | "\n", 83 | "
\n", 84 | "
\n", 85 | "
\n", 86 | "4. Find your converted files in /output when completed\n", 87 | "
\n", 88 | "
\n", 89 | "
\n", 90 | "\n", 91 | "
" 92 | ] 93 | }, 94 | { 95 | "cell_type": "code", 96 | "execution_count": null, 97 | "metadata": {}, 98 | "outputs": [], 99 | "source": [] 100 | } 101 | ], 102 | "metadata": { 103 | "hide_input": false, 104 | "kernelspec": { 105 | "display_name": "Python 3", 106 | "language": "python", 107 | "name": "python3" 108 | }, 109 | "language_info": { 110 | "codemirror_mode": { 111 | "name": "ipython", 112 | "version": 3 113 | }, 114 | "file_extension": ".py", 115 | "mimetype": "text/x-python", 116 | "name": "python", 117 | "nbconvert_exporter": "python", 118 | "pygments_lexer": "ipython3", 119 | "version": "3.8.8" 120 | }, 121 | "toc": { 122 | "base_numbering": 1, 123 | "nav_menu": {}, 124 | "number_sections": true, 125 | "sideBar": true, 126 | "skip_h1_title": false, 127 | "title_cell": "Table of Contents", 128 | "title_sidebar": "Contents", 129 | "toc_cell": false, 130 | "toc_position": {}, 131 | "toc_section_display": true, 132 | "toc_window_display": false 133 | }, 134 | "varInspector": { 135 | "cols": { 136 | "lenName": 16, 137 | "lenType": 16, 138 | "lenVar": 40 139 | }, 140 | "kernels_config": { 141 | "python": { 142 | "delete_cmd_postfix": "", 143 | "delete_cmd_prefix": "del ", 144 | "library": "var_list.py", 145 | "varRefreshCmd": "print(var_dic_list())" 146 | }, 147 | "r": { 148 | "delete_cmd_postfix": ") ", 149 | "delete_cmd_prefix": "rm(", 150 | "library": "var_list.r", 151 | "varRefreshCmd": "cat(var_dic_list()) " 152 | } 153 | }, 154 | "types_to_exclude": [ 155 | "module", 156 | "function", 157 | "builtin_function_or_method", 158 | "instance", 159 | "_Feature" 160 | ], 161 | "window_display": false 162 | } 163 | }, 164 | "nbformat": 4, 165 | "nbformat_minor": 2 166 | } 167 | -------------------------------------------------------------------------------- /003_Convert_.py_to_.exe/README.md: -------------------------------------------------------------------------------- 1 |

2 | Last Commit 3 | 4 |

5 | 6 | 7 | 8 | # Convert .py to .exe 9 | 10 | In this class, you'll learn how to convert .py to .exe file format using a simple graphical interface and **[PyInstaller](https://www.pyinstaller.org/)** in Python. 11 | 12 |

13 | 14 |

15 | 16 | 17 | ## Prerequisites: 18 | 19 | 1. Python Basics 20 | 2. auto-py-to-exe module 21 | 22 | --- 23 | 24 | 25 | ## Install Necessary Modules: 26 | 27 | Open your [![Anaconda](https://img.shields.io/badge/Anaconda-342B029.svg?&style=flate&logo=anaconda&logoColor=white)](https://www.anaconda.com/products/individual) Prompt propmt and type and run the following command (individually): 28 | 29 | - pip install auto-py-to-exe 30 | 31 | --- 32 | 33 | ## Frequently asked questions ❔ 34 | 35 | ### How can I thank you for writing and sharing this tutorial? 🌷 36 | 37 | You can Star Badge and Fork Badge Starring and Forking is free for you, but it tells me and other people that it was helpful and you like this tutorial. 38 | 39 | Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) if you aren't here already and click ➞ **`✰ Star`** and **`ⵖ Fork`** button in the top right corner. You'll be asked to create a GitHub account if you don't already have one. 40 | 41 | --- 42 | 43 | ### How can I read this tutorial without an Internet connection? GIF 44 | 45 | 1. Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) and click the big green ➞ **`Code`** button in the top right of the page, then click ➞ [**`Download ZIP`**](https://github.com/milaan9/91_Python_Mini_Projects/archive/refs/heads/main.zip). 46 | 47 | ![Download ZIP](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/img/dnld_rep.png) 48 | 49 | 2. Extract the ZIP and open it. Unfortunately I don't have any more specific instructions because how exactly this is done depends on which operating system you run. 50 | 51 | 3. Launch ipython notebook from the folder which contains the notebooks. Open each one of them 52 | 53 | `Kernel > Restart & Clear Output` 54 | 55 | This will clear all the outputs and now you can understand each statement and learn interactively. 56 | 57 | If you have git and you know how to use it, you can also clone the repository instead of downloading a zip and extracting it. An advantage with doing it this way is that you don't need to download the whole tutorial again to get the latest version of it, all you need to do is to pull with git and run ipython notebook again. 58 | 59 | --- 60 | 61 | ## Authors ✍️ 62 | 63 | I'm Dr. Milaan Parmar and I have written this tutorial. If you think you can add/correct/edit and enhance this tutorial you are most welcome🙏 64 | 65 | See [github's contributors page](https://github.com/milaan9/91_Python_Mini_Projects/graphs/contributors) for details. 66 | 67 | If you have trouble with this tutorial please tell me about it by [Create an issue on GitHub](https://github.com/milaan9/91_Python_Mini_Projects/issues/new). and I'll make this tutorial better. This is probably the best choice if you had trouble following the tutorial, and something in it should be explained better. You will be asked to create a GitHub account if you don't already have one. 68 | 69 | If you like this tutorial, please [give it a ⭐ star](https://github.com/milaan9/91_Python_Mini_Projects). 70 | 71 | --- 72 | 73 | ## Licence 📜 74 | 75 | You may use this tutorial freely at your own risk. See [LICENSE](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/LICENSE). 76 | 77 | Copyright (c) 2020 Dr. Milaan Parmar 78 | 79 | --- 80 | 81 |
82 |

Connect with me 83 |

84 |

85 | LinkedIn 86 | Instagram 87 | Facebook 88 | Gmail 89 |

90 | -------------------------------------------------------------------------------- /003_Convert_.py_to_.exe/__pycache__/clock.cpython-38.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/003_Convert_.py_to_.exe/__pycache__/clock.cpython-38.pyc -------------------------------------------------------------------------------- /003_Convert_.py_to_.exe/clock.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/003_Convert_.py_to_.exe/clock.exe -------------------------------------------------------------------------------- /003_Convert_.py_to_.exe/clock.py: -------------------------------------------------------------------------------- 1 | ''' 2 | Python Program to Create Digital Clock 3 | Author: Dr.Milan Parmar 4 | ''' 5 | 6 | from tkinter import * 7 | from tkinter.ttk import * 8 | 9 | from time import strftime 10 | 11 | root = Tk() 12 | 13 | root.title("Digital clock") 14 | 15 | def clock(): 16 | tick = strftime("%H:%M:%S %p") 17 | 18 | label.config(text =tick) 19 | 20 | label.after(1000, clock) 21 | 22 | label = Label(root, font = ("segoe", 60), foreground = "yellow", background = "black") 23 | 24 | label.pack(anchor= "center") 25 | 26 | clock() 27 | mainloop() -------------------------------------------------------------------------------- /003_Convert_.py_to_.exe/img/py2exe1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/003_Convert_.py_to_.exe/img/py2exe1.png -------------------------------------------------------------------------------- /003_Convert_.py_to_.exe/img/py2exe2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/003_Convert_.py_to_.exe/img/py2exe2.png -------------------------------------------------------------------------------- /003_Convert_.py_to_.exe/img/py2exe3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/003_Convert_.py_to_.exe/img/py2exe3.png -------------------------------------------------------------------------------- /003_Convert_.py_to_.exe/img/py2exe4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/003_Convert_.py_to_.exe/img/py2exe4.png -------------------------------------------------------------------------------- /003_Convert_.py_to_.exe/img/py2exe5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/003_Convert_.py_to_.exe/img/py2exe5.png -------------------------------------------------------------------------------- /004_Find_IP_Address/004_Find_IP_Address.ipynb: -------------------------------------------------------------------------------- 1 | { 2 | "cells": [ 3 | { 4 | "cell_type": "markdown", 5 | "metadata": {}, 6 | "source": [ 7 | "\n", 8 | "All the IPython Notebooks in Python Mini-Projects series by Dr. Milan Parmar are available @ **[GitHub](https://github.com/milaan9/91_Python_Mini_Projects)**\n", 9 | "" 10 | ] 11 | }, 12 | { 13 | "cell_type": "markdown", 14 | "metadata": {}, 15 | "source": [ 16 | "# Python Program to Find IP Address" 17 | ] 18 | }, 19 | { 20 | "cell_type": "code", 21 | "execution_count": 1, 22 | "metadata": { 23 | "ExecuteTime": { 24 | "end_time": "2021-07-24T07:18:01.072465Z", 25 | "start_time": "2021-07-24T07:18:01.001177Z" 26 | } 27 | }, 28 | "outputs": [ 29 | { 30 | "name": "stdout", 31 | "output_type": "stream", 32 | "text": [ 33 | "Your Hostname is: PARMAR-DESKTOP\n", 34 | "Your Ip Address is: 192.168.0.105\n", 35 | "The IP Address of github.com is: 13.234.210.38\n" 36 | ] 37 | } 38 | ], 39 | "source": [ 40 | "'''\n", 41 | "Python Program to Find IP Address\n", 42 | "'''\n", 43 | "\n", 44 | "# Import the necessary module!\n", 45 | "import socket as s \n", 46 | "\n", 47 | "# Get my hostname\n", 48 | "my_hostname = s.gethostname()\n", 49 | "# Display my hostname\n", 50 | "print(\"Your Hostname is: \" + my_hostname)\n", 51 | "\n", 52 | "# Get my IP\n", 53 | "my_ip = s.gethostbyname(my_hostname)\n", 54 | "# Display my IP \n", 55 | "print(\"Your Ip Address is: \" + my_ip)\n", 56 | "\n", 57 | "# Set the hostname\n", 58 | "host = \"github.com\"\n", 59 | "# Fetch the IP\n", 60 | "ip = s.gethostbyname(host)\n", 61 | "\n", 62 | "# Display the IP\n", 63 | "print(\"The IP Address of \" + host + \" is: \" + ip)" 64 | ] 65 | }, 66 | { 67 | "cell_type": "code", 68 | "execution_count": null, 69 | "metadata": {}, 70 | "outputs": [], 71 | "source": [] 72 | } 73 | ], 74 | "metadata": { 75 | "hide_input": false, 76 | "kernelspec": { 77 | "display_name": "Python 3", 78 | "language": "python", 79 | "name": "python3" 80 | }, 81 | "language_info": { 82 | "codemirror_mode": { 83 | "name": "ipython", 84 | "version": 3 85 | }, 86 | "file_extension": ".py", 87 | "mimetype": "text/x-python", 88 | "name": "python", 89 | "nbconvert_exporter": "python", 90 | "pygments_lexer": "ipython3", 91 | "version": "3.8.8" 92 | }, 93 | "toc": { 94 | "base_numbering": 1, 95 | "nav_menu": {}, 96 | "number_sections": true, 97 | "sideBar": true, 98 | "skip_h1_title": false, 99 | "title_cell": "Table of Contents", 100 | "title_sidebar": "Contents", 101 | "toc_cell": false, 102 | "toc_position": {}, 103 | "toc_section_display": true, 104 | "toc_window_display": false 105 | }, 106 | "varInspector": { 107 | "cols": { 108 | "lenName": 16, 109 | "lenType": 16, 110 | "lenVar": 40 111 | }, 112 | "kernels_config": { 113 | "python": { 114 | "delete_cmd_postfix": "", 115 | "delete_cmd_prefix": "del ", 116 | "library": "var_list.py", 117 | "varRefreshCmd": "print(var_dic_list())" 118 | }, 119 | "r": { 120 | "delete_cmd_postfix": ") ", 121 | "delete_cmd_prefix": "rm(", 122 | "library": "var_list.r", 123 | "varRefreshCmd": "cat(var_dic_list()) " 124 | } 125 | }, 126 | "types_to_exclude": [ 127 | "module", 128 | "function", 129 | "builtin_function_or_method", 130 | "instance", 131 | "_Feature" 132 | ], 133 | "window_display": false 134 | } 135 | }, 136 | "nbformat": 4, 137 | "nbformat_minor": 2 138 | } 139 | -------------------------------------------------------------------------------- /004_Find_IP_Address/README.md: -------------------------------------------------------------------------------- 1 |

2 | Last Commit 3 | 4 |

5 | 6 | 7 | 8 | # Find IP Address 9 | 10 | In this class, you'll learn how to find IP address using python 11 | 12 | 13 | ## Prerequisites: 14 | 15 | 1. Python Basics 16 | 2. socket module 17 | 18 | --- 19 | 20 | ### What is IP address? 21 | 22 | **[IP address](https://en.wikipedia.org/wiki/IP_address)** stands for Internet Protocol address, is a numerical label assigned to each device connected to a **[computer network](https://en.wikipedia.org/wiki/Computer_network)** that uses the **[Internet Protocol](https://en.wikipedia.org/wiki/Internet_Protocol)** for communication. 23 | 24 | IP (Internet Protocol) Address is an address of your network hardware. An IP Address is made up of numbers or characters. All devices that are connected to an internet connection have a unique IP address 25 | 26 | There are are two IP versions: 27 | 28 | * IPv4 29 | * IPv6 30 | 31 | There are a few other types of IP addresses as well like private IP addresses, public IP addresses, static IP addresses and dynamic IP addresses. 32 | 33 | --- 34 | ## Install Necessary Modules: 35 | 36 | Since **`socket`** is in-built module, hence no need to install it separately. 37 | 38 | --- 39 | 40 | ## Frequently asked questions ❔ 41 | 42 | ### How can I thank you for writing and sharing this tutorial? 🌷 43 | 44 | You can Star Badge and Fork Badge Starring and Forking is free for you, but it tells me and other people that it was helpful and you like this tutorial. 45 | 46 | Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) if you aren't here already and click ➞ **`✰ Star`** and **`ⵖ Fork`** button in the top right corner. You'll be asked to create a GitHub account if you don't already have one. 47 | 48 | --- 49 | 50 | ### How can I read this tutorial without an Internet connection? GIF 51 | 52 | 1. Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) and click the big green ➞ **`Code`** button in the top right of the page, then click ➞ [**`Download ZIP`**](https://github.com/milaan9/91_Python_Mini_Projects/archive/refs/heads/main.zip). 53 | 54 | ![Download ZIP](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/img/dnld_rep.png) 55 | 56 | 2. Extract the ZIP and open it. Unfortunately I don't have any more specific instructions because how exactly this is done depends on which operating system you run. 57 | 58 | 3. Launch ipython notebook from the folder which contains the notebooks. Open each one of them 59 | 60 | `Kernel > Restart & Clear Output` 61 | 62 | This will clear all the outputs and now you can understand each statement and learn interactively. 63 | 64 | If you have git and you know how to use it, you can also clone the repository instead of downloading a zip and extracting it. An advantage with doing it this way is that you don't need to download the whole tutorial again to get the latest version of it, all you need to do is to pull with git and run ipython notebook again. 65 | 66 | --- 67 | 68 | ## Authors ✍️ 69 | 70 | I'm Dr. Milaan Parmar and I have written this tutorial. If you think you can add/correct/edit and enhance this tutorial you are most welcome🙏 71 | 72 | See [github's contributors page](https://github.com/milaan9/91_Python_Mini_Projects/graphs/contributors) for details. 73 | 74 | If you have trouble with this tutorial please tell me about it by [Create an issue on GitHub](https://github.com/milaan9/91_Python_Mini_Projects/issues/new). and I'll make this tutorial better. This is probably the best choice if you had trouble following the tutorial, and something in it should be explained better. You will be asked to create a GitHub account if you don't already have one. 75 | 76 | If you like this tutorial, please [give it a ⭐ star](https://github.com/milaan9/91_Python_Mini_Projects). 77 | 78 | --- 79 | 80 | ## Licence 📜 81 | 82 | You may use this tutorial freely at your own risk. See [LICENSE](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/LICENSE). 83 | 84 | Copyright (c) 2020 Dr. Milaan Parmar 85 | 86 | --- 87 | 88 |
89 |

Connect with me 90 |

91 |

92 | LinkedIn 93 | Instagram 94 | Facebook 95 | Gmail 96 |

97 | -------------------------------------------------------------------------------- /005_Test_Internet_Speed/README.md: -------------------------------------------------------------------------------- 1 |

2 | Last Commit 3 | 4 |

5 | 6 | 7 | 8 | # Test Internet Speed 9 | 10 | In this class, you'll learn how to test internet speed using python with and without GUI (Tkinter) 11 | 12 |

13 | 14 |

15 | 16 | ## Prerequisites: 17 | 18 | 1. Python Basics 19 | 2. speedtest-cli module 20 | 21 | --- 22 | 23 | 24 | ## Install Necessary Modules: 25 | 26 | Open your [![Anaconda](https://img.shields.io/badge/Anaconda-342B029.svg?&style=flate&logo=anaconda&logoColor=white)](https://www.anaconda.com/products/individual) Prompt propmt and type and run the following command (individually): 27 | 28 | - pip install speedtest-cli 29 | 30 | 31 | **[`speedtest-cli`](https://pypi.org/project/speedtest-cli/)** is a Python library which provides Command line interface for testing internet bandwidth using **[speedtest.net](http://speedtest.net/)** 32 | 33 | Once Installed now we can import it inside our python code. 34 | 35 | --- 36 | 37 | ## Frequently asked questions ❔ 38 | 39 | ### How can I thank you for writing and sharing this tutorial? 🌷 40 | 41 | You can Star Badge and Fork Badge Starring and Forking is free for you, but it tells me and other people that it was helpful and you like this tutorial. 42 | 43 | Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) if you aren't here already and click ➞ **`✰ Star`** and **`ⵖ Fork`** button in the top right corner. You will be asked to create a GitHub account if you don't already have one. 44 | 45 | --- 46 | 47 | ### How can I read this tutorial without an Internet connection? GIF 48 | 49 | 1. Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) and click the big green ➞ **`Code`** button in the top right of the page, then click ➞ [**`Download ZIP`**](https://github.com/milaan9/91_Python_Mini_Projects/archive/refs/heads/main.zip). 50 | 51 | ![Download ZIP](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/img/dnld_rep.png) 52 | 53 | 2. Extract the ZIP and open it. Unfortunately I don't have any more specific instructions because how exactly this is done depends on which operating system you run. 54 | 55 | 3. Launch ipython notebook from the folder which contains the notebooks. Open each one of them 56 | 57 | `Kernel > Restart & Clear Output` 58 | 59 | This will clear all the outputs and now you can understand each statement and learn interactively. 60 | 61 | If you have git and you know how to use it, you can also clone the repository instead of downloading a zip and extracting it. An advantage with doing it this way is that you don't need to download the whole tutorial again to get the latest version of it, all you need to do is to pull with git and run ipython notebook again. 62 | 63 | --- 64 | 65 | ## Authors ✍️ 66 | 67 | I'm Dr. Milaan Parmar and I have written this tutorial. If you think you can add/correct/edit and enhance this tutorial you are most welcome🙏 68 | 69 | See [github's contributors page](https://github.com/milaan9/91_Python_Mini_Projects/graphs/contributors) for details. 70 | 71 | If you have trouble with this tutorial please tell me about it by [Create an issue on GitHub](https://github.com/milaan9/91_Python_Mini_Projects/issues/new). and I'll make this tutorial better. This is probably the best choice if you had trouble following the tutorial, and something in it should be explained better. You will be asked to create a GitHub account if you don't already have one. 72 | 73 | If you like this tutorial, please [give it a ⭐ star](https://github.com/milaan9/91_Python_Mini_Projects). 74 | 75 | --- 76 | 77 | ## Licence 📜 78 | 79 | You may use this tutorial freely at your own risk. See [LICENSE](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/LICENSE). 80 | 81 | Copyright (c) 2020 Dr. Milaan Parmar 82 | 83 | --- 84 | 85 |
86 |

Connect with me 87 |

88 |

89 | LinkedIn 90 | Instagram 91 | Facebook 92 | Gmail 93 |

94 | -------------------------------------------------------------------------------- /005_Test_Internet_Speed/result.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/005_Test_Internet_Speed/result.png -------------------------------------------------------------------------------- /005_Test_Internet_Speed/speed.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/005_Test_Internet_Speed/speed.ico -------------------------------------------------------------------------------- /006_Check_Weather_Forecast/README.md: -------------------------------------------------------------------------------- 1 |

2 | Last Commit 3 | 4 |

5 | 6 | 7 | 8 | # Check Weather Forecast 9 | 10 | In this class, you'll learn how to check weather forecast using python 11 | 12 |

13 | 14 |

15 | 16 | ## Prerequisites: 17 | 18 | 1. Python Basics 19 | 2. requests module 20 | 21 | --- 22 | 23 | ### What is wttr? 24 | 25 | **wttr — the right way to check the weather** 26 | 27 | **[wttr.in](https://github.com/chubin/wttr.in)** is a console-oriented weather forecast service that supports various information representation methods like terminal-oriented ANSI-sequences for console HTTP clients (curl, httpie, or wget), HTML for web browsers, or PNG for graphical viewers. 28 | 29 | **[wttr.in](http://wttr.in/)** uses **[wego](http://github.com/schachmat/wego)** for visualization and various data sources for weather forecast information. 30 | 31 | --- 32 | 33 | ## Install Necessary Modules: 34 | 35 | Open your [![Anaconda](https://img.shields.io/badge/Anaconda-342B029.svg?&style=flate&logo=anaconda&logoColor=white)](https://www.anaconda.com/products/individual) Prompt propmt and type and run the following command (individually): 36 | 37 | - pip install requests 38 | 39 | 40 | **[`requests`](https://docs.python-requests.org/en/master/)** is a simple, yet elegant HTTP library. It allows you to send HTTP/1.1 requests extremely easily. Requests officially support Python 2.7 & 3.5+. 41 | 42 | Once Installed now we can import it inside our python code. 43 | 44 | --- 45 | 46 | ## Frequently asked questions ❔ 47 | 48 | ### How can I thank you for writing and sharing this tutorial? 🌷 49 | 50 | You can Star Badge and Fork Badge Starring and Forking is free for you, but it tells me and other people that it was helpful and you like this tutorial. 51 | 52 | Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) if you aren't here already and click ➞ **`✰ Star`** and **`ⵖ Fork`** button in the top right corner. You will be asked to create a GitHub account if you don't already have one. 53 | 54 | --- 55 | 56 | ### How can I read this tutorial without an Internet connection? GIF 57 | 58 | 1. Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) and click the big green ➞ **`Code`** button in the top right of the page, then click ➞ [**`Download ZIP`**](https://github.com/milaan9/91_Python_Mini_Projects/archive/refs/heads/main.zip). 59 | 60 | ![Download ZIP](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/img/dnld_rep.png) 61 | 62 | 2. Extract the ZIP and open it. Unfortunately I don't have any more specific instructions because how exactly this is done depends on which operating system you run. 63 | 64 | 3. Launch ipython notebook from the folder which contains the notebooks. Open each one of them 65 | 66 | `Kernel > Restart & Clear Output` 67 | 68 | This will clear all the outputs and now you can understand each statement and learn interactively. 69 | 70 | If you have git and you know how to use it, you can also clone the repository instead of downloading a zip and extracting it. An advantage with doing it this way is that you don't need to download the whole tutorial again to get the latest version of it, all you need to do is to pull with git and run ipython notebook again. 71 | 72 | --- 73 | 74 | ## Authors ✍️ 75 | 76 | I'm Dr. Milaan Parmar and I have written this tutorial. If you think you can add/correct/edit and enhance this tutorial you are most welcome🙏 77 | 78 | See [github's contributors page](https://github.com/milaan9/91_Python_Mini_Projects/graphs/contributors) for details. 79 | 80 | If you have trouble with this tutorial please tell me about it by [Create an issue on GitHub](https://github.com/milaan9/91_Python_Mini_Projects/issues/new). and I'll make this tutorial better. This is probably the best choice if you had trouble following the tutorial, and something in it should be explained better. You will be asked to create a GitHub account if you don't already have one. 81 | 82 | If you like this tutorial, please [give it a ⭐ star](https://github.com/milaan9/91_Python_Mini_Projects). 83 | 84 | --- 85 | 86 | ## Licence 📜 87 | 88 | You may use this tutorial freely at your own risk. See [LICENSE](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/LICENSE). 89 | 90 | Copyright (c) 2020 Dr. Milaan Parmar 91 | 92 | --- 93 | 94 |
95 |

Connect with me 96 |

97 |

98 | LinkedIn 99 | Instagram 100 | Facebook 101 | Gmail 102 |

103 | -------------------------------------------------------------------------------- /006_Check_Weather_Forecast/output.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/006_Check_Weather_Forecast/output.png -------------------------------------------------------------------------------- /007_Create_AudioBook_from_PDF/007_Create_AudioBook_from_PDF.ipynb: -------------------------------------------------------------------------------- 1 | { 2 | "cells": [ 3 | { 4 | "cell_type": "markdown", 5 | "metadata": {}, 6 | "source": [ 7 | "\n", 8 | "All the IPython Notebooks in Python Mini-Projects series by Dr. Milan Parmar are available @ **[GitHub](https://github.com/milaan9/91_Python_Mini_Projects)**\n", 9 | "" 10 | ] 11 | }, 12 | { 13 | "cell_type": "markdown", 14 | "metadata": {}, 15 | "source": [ 16 | "# Python Program to Create AudioBook from PDF" 17 | ] 18 | }, 19 | { 20 | "cell_type": "code", 21 | "execution_count": 1, 22 | "metadata": { 23 | "ExecuteTime": { 24 | "end_time": "2021-07-25T13:22:09.776305Z", 25 | "start_time": "2021-07-25T13:21:28.622069Z" 26 | } 27 | }, 28 | "outputs": [ 29 | { 30 | "name": "stdout", 31 | "output_type": "stream", 32 | "text": [ 33 | "Playing Audio Book\n" 34 | ] 35 | } 36 | ], 37 | "source": [ 38 | "'''\n", 39 | "Python Program to Create AudioBook from PDF\n", 40 | "'''\n", 41 | "\n", 42 | "# Import the necessary modules!\n", 43 | "import pyttsx3\n", 44 | "import PyPDF2\n", 45 | "\n", 46 | "# Open our file in reading format and store into book\n", 47 | "book = open('demo.pdf','rb') # `rb` stands for reading mode\n", 48 | "\n", 49 | "# Call PyPDF2's PdfFileReader method on book and store it into pdf_reader\n", 50 | "pdf_reader = PyPDF2.PdfFileReader(book)\n", 51 | "\n", 52 | "# Calculate the no of pages in our pdf by using numPages method\n", 53 | "num_pages = pdf_reader.numPages\n", 54 | "\n", 55 | "# Initialize pyttsx3 using init method and let's print playing Audiobook\n", 56 | "play = pyttsx3.init()\n", 57 | "print('Playing Audio Book')\n", 58 | "\n", 59 | "# Run a loop for the number of pages in our pdf file. \n", 60 | "# A page will get retrieved at each iteration.\n", 61 | "for num in range(0, num_pages):\n", 62 | " page = pdf_reader.getPage(num)\n", 63 | " # Extract the text from our page using extractText method on our page and store it into data.\n", 64 | " data = page.extractText()\n", 65 | "\n", 66 | "\n", 67 | "# Call say method on data and finally we can call runAndWait method at the end. \n", 68 | " play.say(data)\n", 69 | " play.runAndWait()" 70 | ] 71 | }, 72 | { 73 | "cell_type": "code", 74 | "execution_count": null, 75 | "metadata": {}, 76 | "outputs": [], 77 | "source": [] 78 | } 79 | ], 80 | "metadata": { 81 | "hide_input": false, 82 | "kernelspec": { 83 | "display_name": "Python 3", 84 | "language": "python", 85 | "name": "python3" 86 | }, 87 | "language_info": { 88 | "codemirror_mode": { 89 | "name": "ipython", 90 | "version": 3 91 | }, 92 | "file_extension": ".py", 93 | "mimetype": "text/x-python", 94 | "name": "python", 95 | "nbconvert_exporter": "python", 96 | "pygments_lexer": "ipython3", 97 | "version": "3.8.8" 98 | }, 99 | "toc": { 100 | "base_numbering": 1, 101 | "nav_menu": {}, 102 | "number_sections": true, 103 | "sideBar": true, 104 | "skip_h1_title": false, 105 | "title_cell": "Table of Contents", 106 | "title_sidebar": "Contents", 107 | "toc_cell": false, 108 | "toc_position": {}, 109 | "toc_section_display": true, 110 | "toc_window_display": false 111 | }, 112 | "varInspector": { 113 | "cols": { 114 | "lenName": 16, 115 | "lenType": 16, 116 | "lenVar": 40 117 | }, 118 | "kernels_config": { 119 | "python": { 120 | "delete_cmd_postfix": "", 121 | "delete_cmd_prefix": "del ", 122 | "library": "var_list.py", 123 | "varRefreshCmd": "print(var_dic_list())" 124 | }, 125 | "r": { 126 | "delete_cmd_postfix": ") ", 127 | "delete_cmd_prefix": "rm(", 128 | "library": "var_list.r", 129 | "varRefreshCmd": "cat(var_dic_list()) " 130 | } 131 | }, 132 | "types_to_exclude": [ 133 | "module", 134 | "function", 135 | "builtin_function_or_method", 136 | "instance", 137 | "_Feature" 138 | ], 139 | "window_display": false 140 | } 141 | }, 142 | "nbformat": 4, 143 | "nbformat_minor": 2 144 | } 145 | -------------------------------------------------------------------------------- /007_Create_AudioBook_from_PDF/README.md: -------------------------------------------------------------------------------- 1 |

2 | Last Commit 3 | 4 |

5 | 6 | 7 | 8 | # Create AudioBook from PDF 9 | 10 | In this class, you'll learn how to create audiobook from PDF using python 11 | 12 | 13 | ## Prerequisites: 14 | 15 | 1. Python Basics 16 | 2. PyPDF2 module 17 | 3. pyttsx3 module 18 | 19 | --- 20 | 21 | 22 | ## Install Necessary Modules: 23 | 24 | Open your [![Anaconda](https://img.shields.io/badge/Anaconda-342B029.svg?&style=flate&logo=anaconda&logoColor=white)](https://www.anaconda.com/products/individual) Prompt propmt and type and run the following command (individually): 25 | 26 | - pip install PyPDF2 27 | - pip install pyttsx3 28 | 29 | 30 | **[`PyPDF2`](https://pythonhosted.org/PyPDF2/)** is a python library built as a PDF toolkit. It is capable of extracting document information splitting documents page by page merging documents page by page cropping pages merging multiple pages into a single page encrypting and decrypting PDF files and more! 31 | 32 | **[`pyttsx3`](https://pyttsx3.readthedocs.io/en/latest/)** is a text-to-speech conversion library in Python. Unlike alternative libraries, it works offline, and is compatible with both Python 2 and 3. 33 | 34 | Once Installed now we can import it inside our python code. 35 | 36 | --- 37 | 38 | ## Frequently asked questions ❔ 39 | 40 | ### How can I thank you for writing and sharing this tutorial? 🌷 41 | 42 | You can Star Badge and Fork Badge Starring and Forking is free for you, but it tells me and other people that it was helpful and you like this tutorial. 43 | 44 | Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) if you aren't here already and click ➞ **`✰ Star`** and **`ⵖ Fork`** button in the top right corner. You will be asked to create a GitHub account if you don't already have one. 45 | 46 | --- 47 | 48 | ### How can I read this tutorial without an Internet connection? GIF 49 | 50 | 1. Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) and click the big green ➞ **`Code`** button in the top right of the page, then click ➞ [**`Download ZIP`**](https://github.com/milaan9/91_Python_Mini_Projects/archive/refs/heads/main.zip). 51 | 52 | ![Download ZIP](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/img/dnld_rep.png) 53 | 54 | 2. Extract the ZIP and open it. Unfortunately I don't have any more specific instructions because how exactly this is done depends on which operating system you run. 55 | 56 | 3. Launch ipython notebook from the folder which contains the notebooks. Open each one of them 57 | 58 | `Kernel > Restart & Clear Output` 59 | 60 | This will clear all the outputs and now you can understand each statement and learn interactively. 61 | 62 | If you have git and you know how to use it, you can also clone the repository instead of downloading a zip and extracting it. An advantage with doing it this way is that you don't need to download the whole tutorial again to get the latest version of it, all you need to do is to pull with git and run ipython notebook again. 63 | 64 | --- 65 | 66 | ## Authors ✍️ 67 | 68 | I'm Dr. Milaan Parmar and I have written this tutorial. If you think you can add/correct/edit and enhance this tutorial you are most welcome🙏 69 | 70 | See [github's contributors page](https://github.com/milaan9/91_Python_Mini_Projects/graphs/contributors) for details. 71 | 72 | If you have trouble with this tutorial please tell me about it by [Create an issue on GitHub](https://github.com/milaan9/91_Python_Mini_Projects/issues/new). and I'll make this tutorial better. This is probably the best choice if you had trouble following the tutorial, and something in it should be explained better. You will be asked to create a GitHub account if you don't already have one. 73 | 74 | If you like this tutorial, please [give it a ⭐ star](https://github.com/milaan9/91_Python_Mini_Projects). 75 | 76 | --- 77 | 78 | ## Licence 📜 79 | 80 | You may use this tutorial freely at your own risk. See [LICENSE](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/LICENSE). 81 | 82 | Copyright (c) 2020 Dr. Milaan Parmar 83 | 84 | --- 85 | 86 |
87 |

Connect with me 88 |

89 |

90 | LinkedIn 91 | Instagram 92 | Facebook 93 | Gmail 94 |

95 | 96 | 97 | -------------------------------------------------------------------------------- /007_Create_AudioBook_from_PDF/demo.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/007_Create_AudioBook_from_PDF/demo.pdf -------------------------------------------------------------------------------- /007_Create_AudioBook_from_PDF/demo1.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/007_Create_AudioBook_from_PDF/demo1.pdf -------------------------------------------------------------------------------- /008_Generate_Random_Jokes/008_Generate_Random_Jokes.ipynb: -------------------------------------------------------------------------------- 1 | { 2 | "cells": [ 3 | { 4 | "cell_type": "markdown", 5 | "metadata": {}, 6 | "source": [ 7 | "\n", 8 | "All the IPython Notebooks in Python Mini-Projects series by Dr. Milan Parmar are available @ **[GitHub](https://github.com/milaan9/91_Python_Mini_Projects)**\n", 9 | "" 10 | ] 11 | }, 12 | { 13 | "cell_type": "markdown", 14 | "metadata": {}, 15 | "source": [ 16 | "# Python Program to Generate Random Jokes" 17 | ] 18 | }, 19 | { 20 | "cell_type": "markdown", 21 | "metadata": {}, 22 | "source": [ 23 | "There are two methods in **`pyjokes`**:\n", 24 | "\n", 25 | "1. **`get_joke()`**\n", 26 | "\n", 27 | "**Function:** It only returns one joke at a time. It is generated randomly.\n", 28 | "\n", 29 | "**Parameters:** It has two parameters- **`language`** and **`category`**.\n", 30 | "\n", 31 | "**Return Type:** It returns string type (str).\n", 32 | "\n", 33 | "---\n", 34 | "\n", 35 | "2. **`get_jokes()`**\n", 36 | "\n", 37 | "**Function:** It returns a list of jokes.\n", 38 | "\n", 39 | "**Parameters:** The parameters are the same as above- **`language`** and **`category`**.\n", 40 | "\n", 41 | "**Return Type:** It returns a list." 42 | ] 43 | }, 44 | { 45 | "cell_type": "code", 46 | "execution_count": 1, 47 | "metadata": { 48 | "ExecuteTime": { 49 | "end_time": "2021-07-24T11:51:31.264784Z", 50 | "start_time": "2021-07-24T11:51:31.036264Z" 51 | } 52 | }, 53 | "outputs": [ 54 | { 55 | "name": "stdout", 56 | "output_type": "stream", 57 | "text": [ 58 | "How many programmers does it take to kill a cockroach? Two: one holds, the other installs Windows on it. \n", 59 | "\n", 60 | "What's the object-oriented way to become wealthy? Inheritance. \n", 61 | "\n", 62 | "1 . Complaining about the lack of smoking shelters, the nicotine addicted Python programmers said there ought to be 'spaces for tabs'. \n", 63 | "\n", 64 | "2 . Ubuntu users are apt to get this joke. \n", 65 | "\n", 66 | "3 . Obfuscated Reality Mappers (ORMs) can be useful database tools. \n", 67 | "\n", 68 | "4 . Asked to explain Unicode during an interview, Geoff went into detail about his final year university project. He was not hired. \n", 69 | "\n", 70 | "5 . Triumphantly, Beth removed Python 2.7 from her server in 2030. 'Finally!' she said with glee, only to see the announcement for Python 4.4. \n", 71 | "\n" 72 | ] 73 | } 74 | ], 75 | "source": [ 76 | "'''\n", 77 | "Python Program to Generate Random Jokes\n", 78 | "'''\n", 79 | "\n", 80 | "# Import the necessary package\n", 81 | "import pyjokes\n", 82 | "\n", 83 | "# Fetch the joke\n", 84 | "joke1 = pyjokes.get_joke(language=\"en\", category=\"all\")\n", 85 | "\n", 86 | "# Display the joke\n", 87 | "print(joke1,\"\\n\")\n", 88 | "\n", 89 | "# Different category\n", 90 | "joke2 = pyjokes.get_joke(language=\"en\", category=\"neutral\")\n", 91 | "\n", 92 | "# Display the joke\n", 93 | "print(joke2,\"\\n\")\n", 94 | "\n", 95 | "# Fetch multiple jokes\n", 96 | "jokes = pyjokes.get_jokes(language=\"en\", category=\"neutral\")\n", 97 | "\n", 98 | "for i in range(5):\n", 99 | " print(i+1,\".\",jokes[i],\"\\n\")" 100 | ] 101 | }, 102 | { 103 | "cell_type": "code", 104 | "execution_count": null, 105 | "metadata": {}, 106 | "outputs": [], 107 | "source": [] 108 | } 109 | ], 110 | "metadata": { 111 | "hide_input": false, 112 | "kernelspec": { 113 | "display_name": "Python 3", 114 | "language": "python", 115 | "name": "python3" 116 | }, 117 | "language_info": { 118 | "codemirror_mode": { 119 | "name": "ipython", 120 | "version": 3 121 | }, 122 | "file_extension": ".py", 123 | "mimetype": "text/x-python", 124 | "name": "python", 125 | "nbconvert_exporter": "python", 126 | "pygments_lexer": "ipython3", 127 | "version": "3.8.8" 128 | }, 129 | "toc": { 130 | "base_numbering": 1, 131 | "nav_menu": {}, 132 | "number_sections": true, 133 | "sideBar": true, 134 | "skip_h1_title": false, 135 | "title_cell": "Table of Contents", 136 | "title_sidebar": "Contents", 137 | "toc_cell": false, 138 | "toc_position": {}, 139 | "toc_section_display": true, 140 | "toc_window_display": false 141 | }, 142 | "varInspector": { 143 | "cols": { 144 | "lenName": 16, 145 | "lenType": 16, 146 | "lenVar": 40 147 | }, 148 | "kernels_config": { 149 | "python": { 150 | "delete_cmd_postfix": "", 151 | "delete_cmd_prefix": "del ", 152 | "library": "var_list.py", 153 | "varRefreshCmd": "print(var_dic_list())" 154 | }, 155 | "r": { 156 | "delete_cmd_postfix": ") ", 157 | "delete_cmd_prefix": "rm(", 158 | "library": "var_list.r", 159 | "varRefreshCmd": "cat(var_dic_list()) " 160 | } 161 | }, 162 | "types_to_exclude": [ 163 | "module", 164 | "function", 165 | "builtin_function_or_method", 166 | "instance", 167 | "_Feature" 168 | ], 169 | "window_display": false 170 | } 171 | }, 172 | "nbformat": 4, 173 | "nbformat_minor": 2 174 | } 175 | -------------------------------------------------------------------------------- /008_Generate_Random_Jokes/README.md: -------------------------------------------------------------------------------- 1 |

2 | Last Commit 3 | 4 |

5 | 6 | 7 | 8 | # Generate Random Jokes 9 | 10 | In this class, you'll learn how to generate random jokes using python 11 | 12 | 13 | ## Prerequisites: 14 | 15 | 1. Python Basics 16 | 2. pyjokes module 17 | 18 | --- 19 | 20 | 21 | ## Install Necessary Modules: 22 | 23 | Open your [![Anaconda](https://img.shields.io/badge/Anaconda-342B029.svg?&style=flate&logo=anaconda&logoColor=white)](https://www.anaconda.com/products/individual) Prompt propmt and type and run the following command (individually): 24 | 25 | - pip install pyjokes 26 | 27 | 28 | **[`pyjokes`](https://pyjok.es/)** is a python library for one line jokes for programmers (jokes as a service). You can get funny one-liner, mostly related to programming. This is a fun python library. It returns a random joke from the given category in the given language. 29 | 30 | Supported Languages By Pyjokes 31 | - English – ‘en’ 32 | - Spanish – ‘es’ 33 | - Italian – ‘it’ 34 | - German – ‘de’ 35 | - Galician – ‘gl’ 36 | - Basque – ‘eu’ 37 | 38 | Categories Included In Pyjokes 39 | - For geeky jokes -’neutral’ (It is chosen by default) 40 | - For Chris Norris Jokes – ‘chuck’. 41 | - If you want all type of jokes – ‘all’ 42 | - There is one more category known as ‘twister’ which only works for the German Language (‘de’) and mostly includes tongue twister. 43 | 44 | Once Installed now we can import it inside our python code. 45 | 46 | --- 47 | 48 | ## Frequently asked questions ❔ 49 | 50 | ### How can I thank you for writing and sharing this tutorial? 🌷 51 | 52 | You can Star Badge and Fork Badge Starring and Forking is free for you, but it tells me and other people that it was helpful and you like this tutorial. 53 | 54 | Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) if you aren't here already and click ➞ **`✰ Star`** and **`ⵖ Fork`** button in the top right corner. You will be asked to create a GitHub account if you don't already have one. 55 | 56 | --- 57 | 58 | ### How can I read this tutorial without an Internet connection? GIF 59 | 60 | 1. Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) and click the big green ➞ **`Code`** button in the top right of the page, then click ➞ [**`Download ZIP`**](https://github.com/milaan9/91_Python_Mini_Projects/archive/refs/heads/main.zip). 61 | 62 | ![Download ZIP](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/img/dnld_rep.png) 63 | 64 | 2. Extract the ZIP and open it. Unfortunately I don't have any more specific instructions because how exactly this is done depends on which operating system you run. 65 | 66 | 3. Launch ipython notebook from the folder which contains the notebooks. Open each one of them 67 | 68 | `Kernel > Restart & Clear Output` 69 | 70 | This will clear all the outputs and now you can understand each statement and learn interactively. 71 | 72 | If you have git and you know how to use it, you can also clone the repository instead of downloading a zip and extracting it. An advantage with doing it this way is that you don't need to download the whole tutorial again to get the latest version of it, all you need to do is to pull with git and run ipython notebook again. 73 | 74 | --- 75 | 76 | ## Authors ✍️ 77 | 78 | I'm Dr. Milaan Parmar and I have written this tutorial. If you think you can add/correct/edit and enhance this tutorial you are most welcome🙏 79 | 80 | See [github's contributors page](https://github.com/milaan9/91_Python_Mini_Projects/graphs/contributors) for details. 81 | 82 | If you have trouble with this tutorial please tell me about it by [Create an issue on GitHub](https://github.com/milaan9/91_Python_Mini_Projects/issues/new). and I'll make this tutorial better. This is probably the best choice if you had trouble following the tutorial, and something in it should be explained better. You will be asked to create a GitHub account if you don't already have one. 83 | 84 | If you like this tutorial, please [give it a ⭐ star](https://github.com/milaan9/91_Python_Mini_Projects). 85 | 86 | --- 87 | 88 | ## Licence 📜 89 | 90 | You may use this tutorial freely at your own risk. See [LICENSE](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/LICENSE). 91 | 92 | Copyright (c) 2020 Dr. Milaan Parmar 93 | 94 | --- 95 | 96 |
97 |

Connect with me 98 |

99 |

100 | LinkedIn 101 | Instagram 102 | Facebook 103 | Gmail 104 |

105 | -------------------------------------------------------------------------------- /009_Convert_image_to_ASCII/README.md: -------------------------------------------------------------------------------- 1 |

2 | Last Commit 3 | 4 |

5 | 6 | 7 | 8 | # Convert Imane to ASCII Symbols, Grayscale image, Negative image and Pencil Sketch Art 9 | 10 | In this class, you'll learn how to convert image to an ASCII symbols, Grayscale image, Negative image and Pencil Sketch art. 11 | 12 | - Result for ASCII symbols 13 |

14 | 15 |

16 | 17 | - Result for Grayscale image, Negative image and Pencil Sketch art 18 |

19 | 20 |

21 | 22 | 23 | ## Prerequisites: 24 | 25 | 1. Python Basics 26 | 2. pywhatkit module 27 | 28 | --- 29 | 30 | ### What is ASCII? 31 | 32 | **[ASCII](https://en.wikipedia.org/wiki/ASCII)**, acronym of American Standard Code for Information Interchange. 33 | 34 | ASCII is a character encoding standard for electronic communication. ASCII codes represent text in computers, telecommunications equipment, and other devices. 35 | 36 | 37 | --- 38 | 39 | ## Install Necessary Modules: 40 | 41 | Open your [![Anaconda](https://img.shields.io/badge/Anaconda-342B029.svg?&style=flate&logo=anaconda&logoColor=white)](https://www.anaconda.com/products/individual) Prompt propmt and type and run the following command (individually): 42 | 43 | - pip install pywhatkit 44 | 45 | 46 | **[`pywhatkit`](https://pypi.org/project/pywhatkit/)** is a Python library with various helpful features. It is an easy-to-use library that does not require you to do some additional setup. 47 | 48 | This module has lots of other cool features as well. Feel free and go-ahead to explore them or if you wish I can write an article about them. 49 | 50 | If you wish to know more about it, you can refer to **[pywhatkit Module Documentation](https://github.com/Ankit404butfound/PyWhatKit)**. 51 | 52 | Once Installed now we can import it inside our python code. 53 | 54 | --- 55 | 56 | ## Frequently asked questions ❔ 57 | 58 | ### How can I thank you for writing and sharing this tutorial? 🌷 59 | 60 | You can Star Badge and Fork Badge Starring and Forking is free for you, but it tells me and other people that it was helpful and you like this tutorial. 61 | 62 | Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) if you aren't here already and click ➞ **`✰ Star`** and **`ⵖ Fork`** button in the top right corner. You will be asked to create a GitHub account if you don't already have one. 63 | 64 | --- 65 | 66 | ### How can I read this tutorial without an Internet connection? GIF 67 | 68 | 1. Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) and click the big green ➞ **`Code`** button in the top right of the page, then click ➞ [**`Download ZIP`**](https://github.com/milaan9/91_Python_Mini_Projects/archive/refs/heads/main.zip). 69 | 70 | ![Download ZIP](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/img/dnld_rep.png) 71 | 72 | 2. Extract the ZIP and open it. Unfortunately I don't have any more specific instructions because how exactly this is done depends on which operating system you run. 73 | 74 | 3. Launch ipython notebook from the folder which contains the notebooks. Open each one of them 75 | 76 | `Kernel > Restart & Clear Output` 77 | 78 | This will clear all the outputs and now you can understand each statement and learn interactively. 79 | 80 | If you have git and you know how to use it, you can also clone the repository instead of downloading a zip and extracting it. An advantage with doing it this way is that you don't need to download the whole tutorial again to get the latest version of it, all you need to do is to pull with git and run ipython notebook again. 81 | 82 | --- 83 | 84 | ## Authors ✍️ 85 | 86 | I'm Dr. Milaan Parmar and I have written this tutorial. If you think you can add/correct/edit and enhance this tutorial you are most welcome🙏 87 | 88 | See [github's contributors page](https://github.com/milaan9/91_Python_Mini_Projects/graphs/contributors) for details. 89 | 90 | If you have trouble with this tutorial please tell me about it by [Create an issue on GitHub](https://github.com/milaan9/91_Python_Mini_Projects/issues/new). and I'll make this tutorial better. This is probably the best choice if you had trouble following the tutorial, and something in it should be explained better. You will be asked to create a GitHub account if you don't already have one. 91 | 92 | If you like this tutorial, please [give it a ⭐ star](https://github.com/milaan9/91_Python_Mini_Projects). 93 | 94 | --- 95 | 96 | ## Licence 📜 97 | 98 | You may use this tutorial freely at your own risk. See [LICENSE](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/LICENSE). 99 | 100 | Copyright (c) 2020 Dr. Milaan Parmar 101 | 102 | --- 103 | 104 |
105 |

Connect with me 106 |

107 |

108 | LinkedIn 109 | Instagram 110 | Facebook 111 | Gmail 112 |

113 | -------------------------------------------------------------------------------- /009_Convert_image_to_ASCII/ascii_img.txt: -------------------------------------------------------------------------------- 1 | ................................................................................ 2 | ..........................................::!!!!::::............................ 3 | .......................................:*%@@@&&&&&&@$!:......................... 4 | ..............................:::::!*%$@&@@@@&&&#####&@*........................ 5 | ...........................:*$@&#####&&@@@@@@&&&#####&&@%:...................... 6 | .........................:$&###SSS#&&&&&@&#&&&###&&###&&&%:..................... 7 | .........................!####SS#&&####@&#S#&&####&&&&&&&&$*!:.................. 8 | ....................::!%$#S#@#SS#&#SSS&&SSSSS##SS#&#&&&&&&@&&@*:................ 9 | .................:*@#SS***SS&#SSS&#SS#&SSSSSSSSSS#&##&&&&&@&&&&@*:.............. 10 | .................!S*******SS#&SSS#&#S#SS#@##SSSSS#S###@&&&&&&&&&@:.............. 11 | .................!SSSS*****SS##SS###&#*S#&###S#SSS#$##&&&&&&&&&@$............... 12 | .................!#SSSS****SS##&#S####SS###@@@##&@@&S#&&@&&&&&&@*............... 13 | ..................@S#SSS****SS##&@#####&&&&&&&&@&&#S##&&&&&&&&@*................ 14 | ..................!#####SS**SSS##&@&#S######&&&##SS#&&&#&&&&@%!................. 15 | ...................!&S####S**SSSSS#&@&#S######&&@$$$@&##&&@$!................... 16 | .....................*&######S*SSSSSS#&&&##&@@$%%%$@&&&&@$*..........::......... 17 | .......................!*%*@&&#SSSSSSSS#&&&&&@$%$@&&&@$%***:.......:!:.......... 18 | ...........................@#&&&#SSSSSSSS#&@@@$@&&&@%******:.....:!!:........... 19 | ...........................*SS&&&&#SSSSSS###&@@&&&$********:..:!**:............. 20 | ............................&*S##&&&#SSSS#####&&&%***********%$%!............... 21 | ............................!#*SSS#&@&#SS#####&&&@%*******$@@%!................. 22 | .............................!#SSSSS#&&&######&&&&@%*****$$*:................... 23 | .......................::::...:@SSSSSS##&###S#$$$@@%*%%%%*:..................... 24 | .......................:::!!!*%$&#SS######&##S@$&@%%%*!:........................ 25 | ...........................:!*%$@&&#&&&&@$&##SS&@*$*:........................... 26 | ...............................::*%%%%*!:.$###@%!:.............................. 27 | ..........................................!!&$:................................. 28 | ............................................$@!................................. 29 | ............................................*&!................................. 30 | ................:*%%%*!!:...................*&*:................................ 31 | ................::*@@&@@$%**::..............*&!................................. 32 | ....................:!%$$$$@$%*!!::.........*&!................................. 33 | ........................::$###&@$%%%*:......*&!................................. 34 | .........................!&####&&@%%*!:.....*@:................................. 35 | ...........................:!*%$%%!::**:....%@:................................. 36 | ...........................!*%%%%%***!!!::::$$.................................. 37 | .........................*@&&&&@@@$%!:.::!::@$!::::!:::......................... 38 | ........................*S##&&&@$*:.......::&$:......:!:........................ 39 | ........................%$%%%*!:...........:&%........:!:....................... 40 | ...........................................:@*..........*!...................... 41 | ...........................................!@:.........:$$:..................... 42 | ...........................................*$..........:!:...................... 43 | .......................................::::$%::!%%*!!::......................... 44 | ...............................::!!!****%$$@@$%%$$%%%%**:....................... 45 | ..............................:!!::::::$@@@@@@@%.....:::!....................... 46 | ...........::::::::...................@S##&@&&&@!............................... 47 | ...........*&&&&&&&@$%*::.............&###&&#&&&%............................... 48 | ...........:$&&&&#######&%:...........!###&###&&$:.............................. 49 | .............*@&&&&&&###SS%............!&######@!............................... 50 | ..........:!%@&&&&#&&&&&@&*!:::::.......:$###&%:................................ 51 | .........!&####&@&&##@%%%$@&&@$$$$%*!....%@!!:.................................. 52 | ........:#S#####&###$**%$%$@@@$%$$%$$...:@*..................................... 53 | ........*SS##S#S##@!.*@$%**%%%%*%%%$%!:.*&:..................................... 54 | ........:SSSSS#&$!...:$&@%%***!!**$$%*!*@%...................................... 55 | .........*@$%*!........*@&@$*:..:!%%*:.*&!...................................... 56 | ........................:!::.......::..:&!...................................... 57 | ........................................@*...................................... 58 | ........................................%$...................................... -------------------------------------------------------------------------------- /009_Convert_image_to_ASCII/pywhatkit_dbs.txt: -------------------------------------------------------------------------------- 1 | -------------------- 2 | -------------------------------------------------------------------------------- /009_Convert_image_to_ASCII/result.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/009_Convert_image_to_ASCII/result.png -------------------------------------------------------------------------------- /009_Convert_image_to_ASCII/result2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/009_Convert_image_to_ASCII/result2.png -------------------------------------------------------------------------------- /009_Convert_image_to_ASCII/rose.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/009_Convert_image_to_ASCII/rose.png -------------------------------------------------------------------------------- /010_Perform_Google_Search/010_Perform_Google_Search.ipynb: -------------------------------------------------------------------------------- 1 | { 2 | "cells": [ 3 | { 4 | "cell_type": "markdown", 5 | "metadata": {}, 6 | "source": [ 7 | "\n", 8 | "All the IPython Notebooks in Python Mini-Projects series by Dr. Milan Parmar are available @ **[GitHub](https://github.com/milaan9/91_Python_Mini_Projects)**\n", 9 | "" 10 | ] 11 | }, 12 | { 13 | "cell_type": "markdown", 14 | "metadata": {}, 15 | "source": [ 16 | "# Python Program to Perform Google Search" 17 | ] 18 | }, 19 | { 20 | "cell_type": "code", 21 | "execution_count": 1, 22 | "metadata": { 23 | "ExecuteTime": { 24 | "end_time": "2021-07-24T16:07:38.349084Z", 25 | "start_time": "2021-07-24T16:07:32.222642Z" 26 | } 27 | }, 28 | "outputs": [ 29 | { 30 | "name": "stdout", 31 | "output_type": "stream", 32 | "text": [ 33 | "Let's perform Google search!\n" 34 | ] 35 | } 36 | ], 37 | "source": [ 38 | "'''\n", 39 | "Python Program to Perform Google Search\n", 40 | "'''\n", 41 | "\n", 42 | "# Import the necessary module!\n", 43 | "import pywhatkit as kt\n", 44 | "\n", 45 | "###############################################\n", 46 | "# Method 1:\n", 47 | "\n", 48 | "# Display welcome message\n", 49 | "print(\"Let's perform Google search!\")\n", 50 | "\n", 51 | "# Single search item\n", 52 | "search1 = \"Dr Milan Parmar\"\n", 53 | "\n", 54 | "# Options for multiple search items\n", 55 | "search2 = \"github\"\n", 56 | "search3 = \"python4DataScience\"\n", 57 | "search4 = \"Happiness\"\n", 58 | "\n", 59 | "# Call search the method\n", 60 | "kt.search(search1)\n", 61 | "\n", 62 | "###############################################\n", 63 | "# Method 2:\n", 64 | "\n", 65 | "# Import pywhatkit as kt\n", 66 | "# kt.search(\"python4DataScience\")\n", 67 | "\n", 68 | "\n", 69 | "# NOTE: If your browser window is open is already running, \n", 70 | "# it will perform the search in a new tab otherwise will open a new window." 71 | ] 72 | }, 73 | { 74 | "cell_type": "code", 75 | "execution_count": null, 76 | "metadata": {}, 77 | "outputs": [], 78 | "source": [] 79 | } 80 | ], 81 | "metadata": { 82 | "hide_input": false, 83 | "kernelspec": { 84 | "display_name": "Python 3", 85 | "language": "python", 86 | "name": "python3" 87 | }, 88 | "language_info": { 89 | "codemirror_mode": { 90 | "name": "ipython", 91 | "version": 3 92 | }, 93 | "file_extension": ".py", 94 | "mimetype": "text/x-python", 95 | "name": "python", 96 | "nbconvert_exporter": "python", 97 | "pygments_lexer": "ipython3", 98 | "version": "3.8.8" 99 | }, 100 | "toc": { 101 | "base_numbering": 1, 102 | "nav_menu": {}, 103 | "number_sections": true, 104 | "sideBar": true, 105 | "skip_h1_title": false, 106 | "title_cell": "Table of Contents", 107 | "title_sidebar": "Contents", 108 | "toc_cell": false, 109 | "toc_position": {}, 110 | "toc_section_display": true, 111 | "toc_window_display": false 112 | }, 113 | "varInspector": { 114 | "cols": { 115 | "lenName": 16, 116 | "lenType": 16, 117 | "lenVar": 40 118 | }, 119 | "kernels_config": { 120 | "python": { 121 | "delete_cmd_postfix": "", 122 | "delete_cmd_prefix": "del ", 123 | "library": "var_list.py", 124 | "varRefreshCmd": "print(var_dic_list())" 125 | }, 126 | "r": { 127 | "delete_cmd_postfix": ") ", 128 | "delete_cmd_prefix": "rm(", 129 | "library": "var_list.r", 130 | "varRefreshCmd": "cat(var_dic_list()) " 131 | } 132 | }, 133 | "types_to_exclude": [ 134 | "module", 135 | "function", 136 | "builtin_function_or_method", 137 | "instance", 138 | "_Feature" 139 | ], 140 | "window_display": false 141 | } 142 | }, 143 | "nbformat": 4, 144 | "nbformat_minor": 2 145 | } 146 | -------------------------------------------------------------------------------- /010_Perform_Google_Search/README.md: -------------------------------------------------------------------------------- 1 |

2 | Last Commit 3 | 4 |

5 | 6 | 7 | 8 | # Perform Google Search 9 | 10 | In this class, you'll learn how to perform google search using python 11 | 12 | 13 | ## Prerequisites: 14 | 15 | 1. Python Basics 16 | 2. pywhatkit module 17 | 18 | --- 19 | 20 | 21 | ## Install Necessary Modules: 22 | 23 | Open your [![Anaconda](https://img.shields.io/badge/Anaconda-342B029.svg?&style=flate&logo=anaconda&logoColor=white)](https://www.anaconda.com/products/individual) Prompt propmt and type and run the following command (individually): 24 | 25 | - pip install pywhatkit 26 | 27 | 28 | **[`pywhatkit`](https://pypi.org/project/pywhatkit/)** is a Python library with various helpful features. It is an easy-to-use library that does not require you to do some additional setup. 29 | 30 | This module has lots of other cool features as well. Feel free and go-ahead to explore them or if you wish I can write an article about them. 31 | 32 | If you wish to know more about it, you can refer to **[pywhatkit Module Documentation](https://github.com/Ankit404butfound/PyWhatKit)**. 33 | 34 | Now that you are familiar with Google search basics and have acquired basic knowledge of pywhatkit module, we can move forward to the coding section. 35 | 36 | Once Installed now we can import it inside our python code. 37 | 38 | --- 39 | 40 | ## Frequently asked questions ❔ 41 | 42 | ### How can I thank you for writing and sharing this tutorial? 🌷 43 | 44 | You can Star Badge and Fork Badge Starring and Forking is free for you, but it tells me and other people that it was helpful and you like this tutorial. 45 | 46 | Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) if you aren't here already and click ➞ **`✰ Star`** and **`ⵖ Fork`** button in the top right corner. You will be asked to create a GitHub account if you don't already have one. 47 | 48 | --- 49 | 50 | ### How can I read this tutorial without an Internet connection? GIF 51 | 52 | 1. Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) and click the big green ➞ **`Code`** button in the top right of the page, then click ➞ [**`Download ZIP`**](https://github.com/milaan9/91_Python_Mini_Projects/archive/refs/heads/main.zip). 53 | 54 | ![Download ZIP](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/img/dnld_rep.png) 55 | 56 | 2. Extract the ZIP and open it. Unfortunately I don't have any more specific instructions because how exactly this is done depends on which operating system you run. 57 | 58 | 3. Launch ipython notebook from the folder which contains the notebooks. Open each one of them 59 | 60 | `Kernel > Restart & Clear Output` 61 | 62 | This will clear all the outputs and now you can understand each statement and learn interactively. 63 | 64 | If you have git and you know how to use it, you can also clone the repository instead of downloading a zip and extracting it. An advantage with doing it this way is that you don't need to download the whole tutorial again to get the latest version of it, all you need to do is to pull with git and run ipython notebook again. 65 | 66 | --- 67 | 68 | ## Authors ✍️ 69 | 70 | I'm Dr. Milaan Parmar and I have written this tutorial. If you think you can add/correct/edit and enhance this tutorial you are most welcome🙏 71 | 72 | See [github's contributors page](https://github.com/milaan9/91_Python_Mini_Projects/graphs/contributors) for details. 73 | 74 | If you have trouble with this tutorial please tell me about it by [Create an issue on GitHub](https://github.com/milaan9/91_Python_Mini_Projects/issues/new). and I'll make this tutorial better. This is probably the best choice if you had trouble following the tutorial, and something in it should be explained better. You will be asked to create a GitHub account if you don't already have one. 75 | 76 | If you like this tutorial, please [give it a ⭐ star](https://github.com/milaan9/91_Python_Mini_Projects). 77 | 78 | --- 79 | 80 | ## Licence 📜 81 | 82 | You may use this tutorial freely at your own risk. See [LICENSE](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/LICENSE). 83 | 84 | Copyright (c) 2020 Dr. Milaan Parmar 85 | 86 | --- 87 | 88 |
89 |

Connect with me 90 |

91 |

92 | LinkedIn 93 | Instagram 94 | Facebook 95 | Gmail 96 |

97 | -------------------------------------------------------------------------------- /010_Perform_Google_Search/pywhatkit_dbs.txt: -------------------------------------------------------------------------------- 1 | -------------------- 2 | -------------------------------------------------------------------------------- /011_Generate_QR_Code/011_Generate_QR_Code.ipynb: -------------------------------------------------------------------------------- 1 | { 2 | "cells": [ 3 | { 4 | "cell_type": "markdown", 5 | "metadata": {}, 6 | "source": [ 7 | "\n", 8 | "All the IPython Notebooks in Python Mini-Projects series by Dr. Milan Parmar are available @ **[GitHub](https://github.com/milaan9/91_Python_Mini_Projects)**\n", 9 | "" 10 | ] 11 | }, 12 | { 13 | "cell_type": "markdown", 14 | "metadata": {}, 15 | "source": [ 16 | "# Python Program to Generate QR Code" 17 | ] 18 | }, 19 | { 20 | "cell_type": "code", 21 | "execution_count": 1, 22 | "metadata": { 23 | "ExecuteTime": { 24 | "end_time": "2021-07-24T14:56:05.864646Z", 25 | "start_time": "2021-07-24T14:56:05.755277Z" 26 | } 27 | }, 28 | "outputs": [], 29 | "source": [ 30 | "'''\n", 31 | "Python Program to Generate QR Code\n", 32 | "'''\n", 33 | "\n", 34 | "# Import the necessary module!\n", 35 | "import pyqrcode\n", 36 | "\n", 37 | "# Define the data:\n", 38 | "# We need some text that we want to convert as our QR Code. \n", 39 | "# Since I am creating the QR Code for my github profile, \n", 40 | "# I will \"https://github.com/milaan9\" as data here. Let's store inside a variable.\n", 41 | "data = \"https://github.com/milaan9\"\n", 42 | "\n", 43 | "# Create qrcode:\n", 44 | "# Now that we have the data with us, we can move forward and \n", 45 | "# make use of the package we just imported. Let's create an variable.\n", 46 | "# We will use the create method (as it results in a cleaner looking code) on data.\n", 47 | "qr = pyqrcode.create(data)\n", 48 | "\n", 49 | "# Save the qrcode in png format with proper scaling:\n", 50 | "# Now let's store it in .png format with proper scaling.\n", 51 | "qr.png(\"githubID.png\", scale= 5)" 52 | ] 53 | }, 54 | { 55 | "cell_type": "markdown", 56 | "metadata": {}, 57 | "source": [ 58 | "
\n", 59 | "\n", 60 | "
" 61 | ] 62 | }, 63 | { 64 | "cell_type": "code", 65 | "execution_count": null, 66 | "metadata": {}, 67 | "outputs": [], 68 | "source": [] 69 | } 70 | ], 71 | "metadata": { 72 | "hide_input": false, 73 | "kernelspec": { 74 | "display_name": "Python 3", 75 | "language": "python", 76 | "name": "python3" 77 | }, 78 | "language_info": { 79 | "codemirror_mode": { 80 | "name": "ipython", 81 | "version": 3 82 | }, 83 | "file_extension": ".py", 84 | "mimetype": "text/x-python", 85 | "name": "python", 86 | "nbconvert_exporter": "python", 87 | "pygments_lexer": "ipython3", 88 | "version": "3.8.8" 89 | }, 90 | "toc": { 91 | "base_numbering": 1, 92 | "nav_menu": {}, 93 | "number_sections": true, 94 | "sideBar": true, 95 | "skip_h1_title": false, 96 | "title_cell": "Table of Contents", 97 | "title_sidebar": "Contents", 98 | "toc_cell": false, 99 | "toc_position": {}, 100 | "toc_section_display": true, 101 | "toc_window_display": false 102 | }, 103 | "varInspector": { 104 | "cols": { 105 | "lenName": 16, 106 | "lenType": 16, 107 | "lenVar": 40 108 | }, 109 | "kernels_config": { 110 | "python": { 111 | "delete_cmd_postfix": "", 112 | "delete_cmd_prefix": "del ", 113 | "library": "var_list.py", 114 | "varRefreshCmd": "print(var_dic_list())" 115 | }, 116 | "r": { 117 | "delete_cmd_postfix": ") ", 118 | "delete_cmd_prefix": "rm(", 119 | "library": "var_list.r", 120 | "varRefreshCmd": "cat(var_dic_list()) " 121 | } 122 | }, 123 | "types_to_exclude": [ 124 | "module", 125 | "function", 126 | "builtin_function_or_method", 127 | "instance", 128 | "_Feature" 129 | ], 130 | "window_display": false 131 | } 132 | }, 133 | "nbformat": 4, 134 | "nbformat_minor": 2 135 | } 136 | -------------------------------------------------------------------------------- /011_Generate_QR_Code/README.md: -------------------------------------------------------------------------------- 1 |

2 | Last Commit 3 | 4 |

5 | 6 | 7 | 8 | # Generate QR Code 9 | 10 | In this class, you'll learn how to generate QR Code using python. 11 | 12 |

13 | 14 |

15 | 16 | 17 | ## Prerequisites: 18 | 19 | 1. Python Basics 20 | 2. QR Code Basics 21 | 3. pyqrcode module 22 | 23 | --- 24 | 25 | ### 1. What is QR Code? 26 | Introduction 27 | QR is short for Quick Response. A QR code is a type of matrix barcode first designed in 1994 for the automotive industry in Japan. A barcode is a machine-readable optical label that contains information about the item to which it is attached. 28 | 29 | ### 2. QR Code vs Barcode 30 | While QR Codes and Barcodes are similar in practice, QR Codes contain more information because they have the ability to hold information both horizontally and vertically. 31 | 32 | Barcodes only use horizontal information. 33 | 34 | ### 3. Types of QR Code: 35 | #### 3.1. Static QR Code: 36 | A Static QR Code contains information that is fixed and uneditable once the Code has been generated. 37 | 38 | Usecases: 39 | - QR Codes in business cards or product packaging 40 | - QR Codes for personal use like a party invitation 41 | - QR Codes for Gyms 42 | 43 | #### 3.2. Dynamic QR Code: 44 | Dynamic QR Codes allow you to update, edit and modify the type of the QR Code however many times you need i.e. the content is editable. 45 | 46 | Usecases: 47 | - QR Codes for Coupons 48 | - QR Codes for Social media 49 | 50 | --- 51 | 52 | ## Install Necessary Modules: 53 | 54 | Open your [![Anaconda](https://img.shields.io/badge/Anaconda-342B029.svg?&style=flate&logo=anaconda&logoColor=white)](https://www.anaconda.com/products/individual) Prompt propmt and type and run the following command (individually): 55 | 56 | - pip install pyqrcode 57 | 58 | - pip install pypng 59 | 60 | 61 | **`pyqrcode`** module is used to create QR Codes. It is designed to be as simple and as possible. It does this by using sane defaults and autodetection to make creating a QR Code very simple. 62 | 63 | Once Installed now we can import it inside our python code. 64 | 65 | --- 66 | 67 | ## Frequently asked questions ❔ 68 | 69 | ### How can I thank you for writing and sharing this tutorial? 🌷 70 | 71 | You can Star Badge and Fork Badge Starring and Forking is free for you, but it tells me and other people that it was helpful and you like this tutorial. 72 | 73 | Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) if you aren't here already and click ➞ **`✰ Star`** and **`ⵖ Fork`** button in the top right corner. You will be asked to create a GitHub account if you don't already have one. 74 | 75 | --- 76 | 77 | ### How can I read this tutorial without an Internet connection? GIF 78 | 79 | 1. Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) and click the big green ➞ **`Code`** button in the top right of the page, then click ➞ [**`Download ZIP`**](https://github.com/milaan9/91_Python_Mini_Projects/archive/refs/heads/main.zip). 80 | 81 | ![Download ZIP](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/img/dnld_rep.png) 82 | 83 | 2. Extract the ZIP and open it. Unfortunately I don't have any more specific instructions because how exactly this is done depends on which operating system you run. 84 | 85 | 3. Launch ipython notebook from the folder which contains the notebooks. Open each one of them 86 | 87 | `Kernel > Restart & Clear Output` 88 | 89 | This will clear all the outputs and now you can understand each statement and learn interactively. 90 | 91 | If you have git and you know how to use it, you can also clone the repository instead of downloading a zip and extracting it. An advantage with doing it this way is that you don't need to download the whole tutorial again to get the latest version of it, all you need to do is to pull with git and run ipython notebook again. 92 | 93 | --- 94 | 95 | ## Authors ✍️ 96 | 97 | I'm Dr. Milaan Parmar and I have written this tutorial. If you think you can add/correct/edit and enhance this tutorial you are most welcome🙏 98 | 99 | See [github's contributors page](https://github.com/milaan9/91_Python_Mini_Projects/graphs/contributors) for details. 100 | 101 | If you have trouble with this tutorial please tell me about it by [Create an issue on GitHub](https://github.com/milaan9/91_Python_Mini_Projects/issues/new). and I'll make this tutorial better. This is probably the best choice if you had trouble following the tutorial, and something in it should be explained better. You will be asked to create a GitHub account if you don't already have one. 102 | 103 | If you like this tutorial, please [give it a ⭐ star](https://github.com/milaan9/91_Python_Mini_Projects). 104 | 105 | --- 106 | 107 | ## Licence 📜 108 | 109 | You may use this tutorial freely at your own risk. See [LICENSE](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/LICENSE). 110 | 111 | Copyright (c) 2020 Dr. Milaan Parmar 112 | 113 | --- 114 | 115 |
116 |

Connect with me 117 |

118 |

119 | LinkedIn 120 | Instagram 121 | Facebook 122 | Gmail 123 |

124 | -------------------------------------------------------------------------------- /011_Generate_QR_Code/githubID.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/011_Generate_QR_Code/githubID.png -------------------------------------------------------------------------------- /012_Encode_CAPTCHA/012_Encode_CAPTCHA.ipynb: -------------------------------------------------------------------------------- 1 | { 2 | "cells": [ 3 | { 4 | "cell_type": "markdown", 5 | "metadata": {}, 6 | "source": [ 7 | "\n", 8 | "All the IPython Notebooks in Python Mini-Projects series by Dr. Milan Parmar are available @ **[GitHub](https://github.com/milaan9/91_Python_Mini_Projects)**\n", 9 | "" 10 | ] 11 | }, 12 | { 13 | "cell_type": "markdown", 14 | "metadata": {}, 15 | "source": [ 16 | "# Python Program to Encode CAPTCHA\n", 17 | "\n", 18 | "**CAPTCHA** are used by any website that wishes to restrict usage by bots." 19 | ] 20 | }, 21 | { 22 | "cell_type": "markdown", 23 | "metadata": {}, 24 | "source": [ 25 | "## 1. Image CAPTCHA" 26 | ] 27 | }, 28 | { 29 | "cell_type": "code", 30 | "execution_count": 1, 31 | "metadata": { 32 | "ExecuteTime": { 33 | "end_time": "2021-07-25T08:38:30.677730Z", 34 | "start_time": "2021-07-25T08:38:30.436523Z" 35 | }, 36 | "scrolled": true 37 | }, 38 | "outputs": [], 39 | "source": [ 40 | "'''\n", 41 | "Python Program to Encode and Decode Text CAPTCHA\n", 42 | "'''\n", 43 | "\n", 44 | "# Import the necessary module!\n", 45 | "from captcha.image import ImageCaptcha\n", 46 | "\n", 47 | "# Store and define dimentions\n", 48 | "image = ImageCaptcha(width = 500, height = 100)\n", 49 | "\n", 50 | "# Define data\n", 51 | "data = image.generate(\"9Pyth0n4d@tA6\")\n", 52 | "\n", 53 | "# Write to the file\n", 54 | "image.write(\"9Pyth0n4d@ta6\",\"CAPTCHA_1.png\")" 55 | ] 56 | }, 57 | { 58 | "cell_type": "markdown", 59 | "metadata": {}, 60 | "source": [ 61 | "## 2. Audio CAPTCHA" 62 | ] 63 | }, 64 | { 65 | "cell_type": "code", 66 | "execution_count": 2, 67 | "metadata": { 68 | "ExecuteTime": { 69 | "end_time": "2021-07-25T08:38:31.295406Z", 70 | "start_time": "2021-07-25T08:38:30.681638Z" 71 | } 72 | }, 73 | "outputs": [ 74 | { 75 | "data": { 76 | "text/plain": [ 77 | "59840" 78 | ] 79 | }, 80 | "execution_count": 2, 81 | "metadata": {}, 82 | "output_type": "execute_result" 83 | } 84 | ], 85 | "source": [ 86 | "'''\n", 87 | "Python Program to Encode Audio CAPTCHA\n", 88 | "'''\n", 89 | "\n", 90 | "# Import the necessary module!\n", 91 | "from captcha.audio import AudioCaptcha\n", 92 | "\n", 93 | "# Define properties\n", 94 | "audio = AudioCaptcha()\n", 95 | "\n", 96 | "# Define data\n", 97 | "data = audio.generate(\"978\")\n", 98 | "\n", 99 | "# Write to the file\n", 100 | "audio.write(\"978\", \"CAPTCHA_2.wav\")" 101 | ] 102 | }, 103 | { 104 | "cell_type": "code", 105 | "execution_count": null, 106 | "metadata": {}, 107 | "outputs": [], 108 | "source": [] 109 | } 110 | ], 111 | "metadata": { 112 | "hide_input": false, 113 | "kernelspec": { 114 | "display_name": "Python 3", 115 | "language": "python", 116 | "name": "python3" 117 | }, 118 | "language_info": { 119 | "codemirror_mode": { 120 | "name": "ipython", 121 | "version": 3 122 | }, 123 | "file_extension": ".py", 124 | "mimetype": "text/x-python", 125 | "name": "python", 126 | "nbconvert_exporter": "python", 127 | "pygments_lexer": "ipython3", 128 | "version": "3.8.8" 129 | }, 130 | "toc": { 131 | "base_numbering": 1, 132 | "nav_menu": {}, 133 | "number_sections": true, 134 | "sideBar": true, 135 | "skip_h1_title": false, 136 | "title_cell": "Table of Contents", 137 | "title_sidebar": "Contents", 138 | "toc_cell": false, 139 | "toc_position": {}, 140 | "toc_section_display": true, 141 | "toc_window_display": false 142 | }, 143 | "varInspector": { 144 | "cols": { 145 | "lenName": 16, 146 | "lenType": 16, 147 | "lenVar": 40 148 | }, 149 | "kernels_config": { 150 | "python": { 151 | "delete_cmd_postfix": "", 152 | "delete_cmd_prefix": "del ", 153 | "library": "var_list.py", 154 | "varRefreshCmd": "print(var_dic_list())" 155 | }, 156 | "r": { 157 | "delete_cmd_postfix": ") ", 158 | "delete_cmd_prefix": "rm(", 159 | "library": "var_list.r", 160 | "varRefreshCmd": "cat(var_dic_list()) " 161 | } 162 | }, 163 | "types_to_exclude": [ 164 | "module", 165 | "function", 166 | "builtin_function_or_method", 167 | "instance", 168 | "_Feature" 169 | ], 170 | "window_display": false 171 | } 172 | }, 173 | "nbformat": 4, 174 | "nbformat_minor": 2 175 | } 176 | -------------------------------------------------------------------------------- /012_Encode_CAPTCHA/CAPTCHA_1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/012_Encode_CAPTCHA/CAPTCHA_1.png -------------------------------------------------------------------------------- /012_Encode_CAPTCHA/CAPTCHA_2.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/012_Encode_CAPTCHA/CAPTCHA_2.wav -------------------------------------------------------------------------------- /012_Encode_CAPTCHA/README.md: -------------------------------------------------------------------------------- 1 |

2 | Last Commit 3 | 4 |

5 | 6 | 7 | 8 | # Encode CAPTCHA 9 | 10 | In this class, you'll learn how to encode CAPTCHA using python. 11 | 12 | 13 | ## Prerequisites: 14 | 15 | 1. Python Basics 16 | 2. CAPTCHA Basics 17 | 3. CAPTCHA module 18 | 19 | --- 20 | 21 | ### 1. What is CAPTCHA? 22 | 23 | | Acronym | Stands for | 24 | |:---: |:--- | 25 | | **`C`** | **Completely** | 26 | | **`A`** | **Automated** | 27 | | **`P`** | **Public** | 28 | | **`T`** | **Turing test to tell** | 29 | | **`C`** | **Computers and** | 30 | | **`H`** | **Humans** | 31 | | **`A`** | **Apart** | 32 | 33 | Its primary motive is to determine whether the user is a real human or a spam robot. CAPTCHA is an example of one-way conversion and a type of challenge-response test used in computing to determine whether or not the user is human. 34 | 35 | The most common form is Image CAPTCHA. You are shown an image and if you are a real person, then you need to enter its text in a separate field. 36 | 37 | ### Types of CAPTCHA 38 | 39 | #### 1. Image CAPTCHA 40 | The CAPTCHA presents characters in a way that is alienated and requires interpretation. Alienation can involve scaling, rotation, distorting characters. It can also involve overlapping characters with graphic elements such as colour, background noise, lines, arcs, or dots. This alienation provides protection against bots with insufficient text recognition algorithms but can also be difficult for humans to interpret. 41 | 42 |

43 | 44 |

45 | 46 | #### 2. Audio CAPTCHA 47 | Audio CAPTCHAs were developed as an alternative that grants accessibility to visually impaired users. These CAPTCHAs are often used in combination with text or image-based CAPTCHAs. Audio CAPTCHAs present an audio recording of a series of letters or numbers which a user then enters. 48 | 49 | These CAPTCHAs rely on bots not being able to distinguish relevant characters from background noise. Like text-based CAPTCHAs, these tools can be difficult for humans to interpret as well as for bots. 50 | 51 | --- 52 | 53 | ## Install Necessary Modules: 54 | 55 | Open your [![Anaconda](https://img.shields.io/badge/Anaconda-342B029.svg?&style=flate&logo=anaconda&logoColor=white)](https://www.anaconda.com/products/individual) Prompt propmt and type and run the following command (individually): 56 | 57 | - pip install captcha 58 | 59 | 60 | Once Installed now we can import it inside our python code. 61 | 62 | --- 63 | 64 | ## Frequently asked questions ❔ 65 | 66 | ### How can I thank you for writing and sharing this tutorial? 🌷 67 | 68 | You can Star Badge and Fork Badge Starring and Forking is free for you, but it tells me and other people that it was helpful and you like this tutorial. 69 | 70 | Go [**`here`**](https://github.com/milaan9/01_Python_Introduction) if you aren't here already and click ➞ **`✰ Star`** and **`ⵖ Fork`** button in the top right corner. You will be asked to create a GitHub account if you don't already have one. 71 | 72 | --- 73 | 74 | ### How can I read this tutorial without an Internet connection? GIF 75 | 76 | 1. Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) and click the big green ➞ **`Code`** button in the top right of the page, then click ➞ [**`Download ZIP`**](https://github.com/milaan9/91_Python_Mini_Projects/archive/refs/heads/main.zip). 77 | 78 | ![Download ZIP](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/img/dnld_rep.png) 79 | 80 | 2. Extract the ZIP and open it. Unfortunately I don't have any more specific instructions because how exactly this is done depends on which operating system you run. 81 | 82 | 3. Launch ipython notebook from the folder which contains the notebooks. Open each one of them 83 | 84 | `Kernel > Restart & Clear Output` 85 | 86 | This will clear all the outputs and now you can understand each statement and learn interactively. 87 | 88 | If you have git and you know how to use it, you can also clone the repository instead of downloading a zip and extracting it. An advantage with doing it this way is that you don't need to download the whole tutorial again to get the latest version of it, all you need to do is to pull with git and run ipython notebook again. 89 | 90 | --- 91 | 92 | ## Authors ✍️ 93 | 94 | I'm Dr. Milaan Parmar and I have written this tutorial. If you think you can add/correct/edit and enhance this tutorial you are most welcome🙏 95 | 96 | See [github's contributors page](https://github.com/milaan9/91_Python_Mini_Projects/graphs/contributors) for details. 97 | 98 | If you have trouble with this tutorial please tell me about it by [Create an issue on GitHub](https://github.com/milaan9/91_Python_Mini_Projects/issues/new). and I'll make this tutorial better. This is probably the best choice if you had trouble following the tutorial, and something in it should be explained better. You will be asked to create a GitHub account if you don't already have one. 99 | 100 | If you like this tutorial, please [give it a ⭐ star](https://github.com/milaan9/91_Python_Mini_Projects). 101 | 102 | --- 103 | 104 | ## Licence 📜 105 | 106 | You may use this tutorial freely at your own risk. See [LICENSE](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/LICENSE). 107 | 108 | Copyright (c) 2020 Dr. Milaan Parmar 109 | 110 | --- 111 | 112 |
113 |

Connect with me 114 |

115 |

116 | LinkedIn 117 | Instagram 118 | Facebook 119 | Gmail 120 |

121 | -------------------------------------------------------------------------------- /013_Unzip_File/013_Unzip_File.ipynb: -------------------------------------------------------------------------------- 1 | { 2 | "cells": [ 3 | { 4 | "cell_type": "markdown", 5 | "metadata": {}, 6 | "source": [ 7 | "\n", 8 | "All the IPython Notebooks in Python Mini-Projects series by Dr. Milan Parmar are available @ **[GitHub](https://github.com/milaan9/91_Python_Mini_Projects)**\n", 9 | "" 10 | ] 11 | }, 12 | { 13 | "cell_type": "markdown", 14 | "metadata": {}, 15 | "source": [ 16 | "# Python Program to Unzip File" 17 | ] 18 | }, 19 | { 20 | "cell_type": "code", 21 | "execution_count": 1, 22 | "metadata": { 23 | "ExecuteTime": { 24 | "end_time": "2021-07-25T06:33:26.850053Z", 25 | "start_time": "2021-07-25T06:33:26.820755Z" 26 | } 27 | }, 28 | "outputs": [ 29 | { 30 | "name": "stdout", 31 | "output_type": "stream", 32 | "text": [ 33 | "Starting to Unzip the File\n", 34 | "\n", 35 | "File is Succesfully Unzipped!\n" 36 | ] 37 | } 38 | ], 39 | "source": [ 40 | "'''\n", 41 | "Python Program to Unzip File\n", 42 | "'''\n", 43 | "\n", 44 | "# Import the necessary module!\n", 45 | "import zipfile as zip\n", 46 | "\n", 47 | "# Set the target file\n", 48 | "target = \"demo.zip\"\n", 49 | "\n", 50 | "# Display a start message\n", 51 | "print(\"Starting to Unzip the File\")\n", 52 | "\n", 53 | "# Use ZipFile method\n", 54 | "root = zip.ZipFile(target)\n", 55 | "\n", 56 | "# Give destination path\n", 57 | "# If the folder with name `unzip` already exists, it will create an unzipped file inside it. \n", 58 | "# Otherwise, a new folder will be created with the given name (even if no parameter is passed).\n", 59 | "root.extractall(\"unzip\")\n", 60 | "# End the process using close method.\n", 61 | "root.close()\n", 62 | "\n", 63 | "# Display the end message\n", 64 | "print(\"\\nFile is Succesfully Unzipped!\")" 65 | ] 66 | }, 67 | { 68 | "cell_type": "code", 69 | "execution_count": null, 70 | "metadata": {}, 71 | "outputs": [], 72 | "source": [] 73 | } 74 | ], 75 | "metadata": { 76 | "hide_input": false, 77 | "kernelspec": { 78 | "display_name": "Python 3", 79 | "language": "python", 80 | "name": "python3" 81 | }, 82 | "language_info": { 83 | "codemirror_mode": { 84 | "name": "ipython", 85 | "version": 3 86 | }, 87 | "file_extension": ".py", 88 | "mimetype": "text/x-python", 89 | "name": "python", 90 | "nbconvert_exporter": "python", 91 | "pygments_lexer": "ipython3", 92 | "version": "3.8.8" 93 | }, 94 | "toc": { 95 | "base_numbering": 1, 96 | "nav_menu": {}, 97 | "number_sections": true, 98 | "sideBar": true, 99 | "skip_h1_title": false, 100 | "title_cell": "Table of Contents", 101 | "title_sidebar": "Contents", 102 | "toc_cell": false, 103 | "toc_position": {}, 104 | "toc_section_display": true, 105 | "toc_window_display": false 106 | }, 107 | "varInspector": { 108 | "cols": { 109 | "lenName": 16, 110 | "lenType": 16, 111 | "lenVar": 40 112 | }, 113 | "kernels_config": { 114 | "python": { 115 | "delete_cmd_postfix": "", 116 | "delete_cmd_prefix": "del ", 117 | "library": "var_list.py", 118 | "varRefreshCmd": "print(var_dic_list())" 119 | }, 120 | "r": { 121 | "delete_cmd_postfix": ") ", 122 | "delete_cmd_prefix": "rm(", 123 | "library": "var_list.r", 124 | "varRefreshCmd": "cat(var_dic_list()) " 125 | } 126 | }, 127 | "types_to_exclude": [ 128 | "module", 129 | "function", 130 | "builtin_function_or_method", 131 | "instance", 132 | "_Feature" 133 | ], 134 | "window_display": false 135 | } 136 | }, 137 | "nbformat": 4, 138 | "nbformat_minor": 2 139 | } 140 | -------------------------------------------------------------------------------- /013_Unzip_File/README.md: -------------------------------------------------------------------------------- 1 |

2 | Last Commit 3 | 4 |

5 | 6 | 7 | 8 | # Unzip File 9 | 10 | In this class, you'll learn how to Unzip File using python 11 | 12 | 13 | ## Prerequisites: 14 | 15 | 1. Python Basics 16 | 2. zipfile module 17 | 18 | --- 19 | 20 | ### What is Zip file? 21 | 22 | **[ZIP](https://en.wikipedia.org/wiki/ZIP_%28file_format%29)** is an archive file format that supports lossless data compression. A ZIP file may contain one or more files or directories that may have been compressed. 23 | 24 | ZIP files can come handy for a lot different things, we make use of it on a regular basis. 25 | 26 | Uses for Zip File: 27 | 28 | * Zip files help you to put all related files in one place. 29 | * Zip files help to reduce the data size. 30 | * Zip files transfer faster than the individual file over many connections. 31 | 32 | --- 33 | ## Install Necessary Modules: 34 | 35 | Since **`zipfile`** is in-built module, hence no need to install it separately. 36 | 37 | **[ZipFile module](https://docs.python.org/3/library/zipfile.html)** provides tools to create, read, write, append, and list a ZIP file. Any advanced use of this module will require an understanding of the format, as defined in PKZIP Application Note. 38 | 39 | Now that you are familiar with Zip file use cases and have acquired basic knowledge of ZipFile module, we can move forward to the coding section. 40 | 41 | --- 42 | 43 | ## Frequently asked questions ❔ 44 | 45 | ### How can I thank you for writing and sharing this tutorial? 🌷 46 | 47 | You can Star Badge and Fork Badge Starring and Forking is free for you, but it tells me and other people that it was helpful and you like this tutorial. 48 | 49 | Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) if you aren't here already and click ➞ **`✰ Star`** and **`ⵖ Fork`** button in the top right corner. You will be asked to create a GitHub account if you don't already have one. 50 | 51 | --- 52 | 53 | ### How can I read this tutorial without an Internet connection? GIF 54 | 55 | 1. Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) and click the big green ➞ **`Code`** button in the top right of the page, then click ➞ [**`Download ZIP`**](https://github.com/milaan9/91_Python_Mini_Projects/archive/refs/heads/main.zip). 56 | 57 | ![Download ZIP](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/img/dnld_rep.png) 58 | 59 | 2. Extract the ZIP and open it. Unfortunately I don't have any more specific instructions because how exactly this is done depends on which operating system you run. 60 | 61 | 3. Launch ipython notebook from the folder which contains the notebooks. Open each one of them 62 | 63 | `Kernel > Restart & Clear Output` 64 | 65 | This will clear all the outputs and now you can understand each statement and learn interactively. 66 | 67 | If you have git and you know how to use it, you can also clone the repository instead of downloading a zip and extracting it. An advantage with doing it this way is that you don't need to download the whole tutorial again to get the latest version of it, all you need to do is to pull with git and run ipython notebook again. 68 | 69 | --- 70 | 71 | ## Authors ✍️ 72 | 73 | I'm Dr. Milaan Parmar and I have written this tutorial. If you think you can add/correct/edit and enhance this tutorial you are most welcome🙏 74 | 75 | See [github's contributors page](https://github.com/milaan9/91_Python_Mini_Projects/graphs/contributors) for details. 76 | 77 | If you have trouble with this tutorial please tell me about it by [Create an issue on GitHub](https://github.com/milaan9/91_Python_Mini_Projects/issues/new). and I'll make this tutorial better. This is probably the best choice if you had trouble following the tutorial, and something in it should be explained better. You will be asked to create a GitHub account if you don't already have one. 78 | 79 | If you like this tutorial, please [give it a ⭐ star](https://github.com/milaan9/91_Python_Mini_Projects). 80 | 81 | --- 82 | 83 | ## Licence 📜 84 | 85 | You may use this tutorial freely at your own risk. See [LICENSE](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/LICENSE). 86 | 87 | Copyright (c) 2020 Dr. Milaan Parmar 88 | 89 | --- 90 | 91 |
92 |

Connect with me 93 |

94 |

95 | LinkedIn 96 | Instagram 97 | Facebook 98 | Gmail 99 |

100 | {"mode":"full","isActive":false} 101 | -------------------------------------------------------------------------------- /013_Unzip_File/demo.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/013_Unzip_File/demo.zip -------------------------------------------------------------------------------- /013_Unzip_File/unzip/013_Unzip_File/013_Unzip_File.ipynb: -------------------------------------------------------------------------------- 1 | { 2 | "cells": [ 3 | { 4 | "cell_type": "markdown", 5 | "metadata": {}, 6 | "source": [ 7 | "\n", 8 | "All the IPython Notebooks in Python Mini-Projects series by Dr. Milan Parmar are available @ **[GitHub](https://github.com/milaan9/91_Python_Mini_Projects)**\n", 9 | "" 10 | ] 11 | }, 12 | { 13 | "cell_type": "markdown", 14 | "metadata": {}, 15 | "source": [ 16 | "# Python Program to Unzip File" 17 | ] 18 | }, 19 | { 20 | "cell_type": "code", 21 | "execution_count": 1, 22 | "metadata": { 23 | "ExecuteTime": { 24 | "end_time": "2021-07-25T06:33:26.850053Z", 25 | "start_time": "2021-07-25T06:33:26.820755Z" 26 | } 27 | }, 28 | "outputs": [ 29 | { 30 | "name": "stdout", 31 | "output_type": "stream", 32 | "text": [ 33 | "Starting to Unzip the File\n", 34 | "\n", 35 | "File is Succesfully Unzipped!\n" 36 | ] 37 | } 38 | ], 39 | "source": [ 40 | "'''\n", 41 | "Python Program to Unzip File\n", 42 | "'''\n", 43 | "\n", 44 | "# Import the necessary module!\n", 45 | "import zipfile as zip\n", 46 | "\n", 47 | "# Set the target file\n", 48 | "target = \"demo.zip\"\n", 49 | "\n", 50 | "# Display a start message\n", 51 | "print(\"Starting to Unzip the File\")\n", 52 | "\n", 53 | "# Use ZipFile method\n", 54 | "root = zip.ZipFile(target)\n", 55 | "\n", 56 | "# Give destination path\n", 57 | "# If the folder with name `unzip` already exists, it will create an unzipped file inside it. \n", 58 | "# Otherwise, a new folder will be created with the given name (even if no parameter is passed).\n", 59 | "root.extractall(\"unzip\")\n", 60 | "# End the process using close method.\n", 61 | "root.close()\n", 62 | "\n", 63 | "# Display the end message\n", 64 | "print(\"\\nFile is Succesfully Unzipped!\")" 65 | ] 66 | }, 67 | { 68 | "cell_type": "code", 69 | "execution_count": null, 70 | "metadata": {}, 71 | "outputs": [], 72 | "source": [] 73 | } 74 | ], 75 | "metadata": { 76 | "hide_input": false, 77 | "kernelspec": { 78 | "display_name": "Python 3", 79 | "language": "python", 80 | "name": "python3" 81 | }, 82 | "language_info": { 83 | "codemirror_mode": { 84 | "name": "ipython", 85 | "version": 3 86 | }, 87 | "file_extension": ".py", 88 | "mimetype": "text/x-python", 89 | "name": "python", 90 | "nbconvert_exporter": "python", 91 | "pygments_lexer": "ipython3", 92 | "version": "3.8.8" 93 | }, 94 | "toc": { 95 | "base_numbering": 1, 96 | "nav_menu": {}, 97 | "number_sections": true, 98 | "sideBar": true, 99 | "skip_h1_title": false, 100 | "title_cell": "Table of Contents", 101 | "title_sidebar": "Contents", 102 | "toc_cell": false, 103 | "toc_position": {}, 104 | "toc_section_display": true, 105 | "toc_window_display": false 106 | }, 107 | "varInspector": { 108 | "cols": { 109 | "lenName": 16, 110 | "lenType": 16, 111 | "lenVar": 40 112 | }, 113 | "kernels_config": { 114 | "python": { 115 | "delete_cmd_postfix": "", 116 | "delete_cmd_prefix": "del ", 117 | "library": "var_list.py", 118 | "varRefreshCmd": "print(var_dic_list())" 119 | }, 120 | "r": { 121 | "delete_cmd_postfix": ") ", 122 | "delete_cmd_prefix": "rm(", 123 | "library": "var_list.r", 124 | "varRefreshCmd": "cat(var_dic_list()) " 125 | } 126 | }, 127 | "types_to_exclude": [ 128 | "module", 129 | "function", 130 | "builtin_function_or_method", 131 | "instance", 132 | "_Feature" 133 | ], 134 | "window_display": false 135 | } 136 | }, 137 | "nbformat": 4, 138 | "nbformat_minor": 2 139 | } 140 | -------------------------------------------------------------------------------- /014_Run_JavaScript_in_Python/014_Run_JavaScript_in_Python.ipynb: -------------------------------------------------------------------------------- 1 | { 2 | "cells": [ 3 | { 4 | "cell_type": "markdown", 5 | "metadata": {}, 6 | "source": [ 7 | "\n", 8 | "All the IPython Notebooks in Python Mini-Projects series by Dr. Milan Parmar are available @ **[GitHub](https://github.com/milaan9/91_Python_Mini_Projects)**\n", 9 | "" 10 | ] 11 | }, 12 | { 13 | "cell_type": "markdown", 14 | "metadata": {}, 15 | "source": [ 16 | "# Python Program to Run JavaScript in Python" 17 | ] 18 | }, 19 | { 20 | "cell_type": "code", 21 | "execution_count": 1, 22 | "metadata": { 23 | "ExecuteTime": { 24 | "end_time": "2021-07-25T13:56:39.531715Z", 25 | "start_time": "2021-07-25T13:56:35.493643Z" 26 | } 27 | }, 28 | "outputs": [ 29 | { 30 | "name": "stdout", 31 | "output_type": "stream", 32 | "text": [ 33 | "'Running JavaScript in Python'\n", 34 | "Enter value of x: 6\n", 35 | "Result: x + 3 = 9\n" 36 | ] 37 | } 38 | ], 39 | "source": [ 40 | "'''\n", 41 | "Python Program to Run JavaScript in Python\n", 42 | "'''\n", 43 | "\n", 44 | "\"\"\"\n", 45 | "Equivalent Python code:\n", 46 | "\n", 47 | "# Example 1: \n", 48 | "print(\"Running JavaScript in Python\")\n", 49 | " \n", 50 | "#Example 2: \n", 51 | "def add(x, y):\n", 52 | " return x + y\n", 53 | " \n", 54 | "\"\"\"\n", 55 | "\n", 56 | "\n", 57 | "# Import the necessary module!\n", 58 | "import js2py\n", 59 | "\n", 60 | "# Example 1: JavaScript command\n", 61 | "# Use of eval.js method from js2py module here, \n", 62 | "# Pass in our js code in it and store it in res1.\n", 63 | "js_1 = 'console.log(\"Running JavaScript in Python\")'\n", 64 | "\n", 65 | "res1 = js2py.eval_js(js_1)\n", 66 | "\n", 67 | "# Print the result\n", 68 | "res1\n", 69 | "\n", 70 | "########################################################\n", 71 | "\n", 72 | "# Exapmle 2: JavaScript function\n", 73 | "\n", 74 | "# Ask for user input\n", 75 | "x = int(input(\"Enter value of x: \"))\n", 76 | "js_2 = '''function add(x, y){\n", 77 | " return x + y;\n", 78 | " }'''\n", 79 | "# Use of eval.js method from js2py module here, \n", 80 | "# Pass in our js code in it and store it in res2. \n", 81 | "res2 = js2py.eval_js(js_2)\n", 82 | "\n", 83 | "# Print the result\n", 84 | "print(\"Result: x + 3 =\", res2(x,3))" 85 | ] 86 | }, 87 | { 88 | "cell_type": "code", 89 | "execution_count": null, 90 | "metadata": {}, 91 | "outputs": [], 92 | "source": [] 93 | } 94 | ], 95 | "metadata": { 96 | "hide_input": false, 97 | "kernelspec": { 98 | "display_name": "Python 3", 99 | "language": "python", 100 | "name": "python3" 101 | }, 102 | "language_info": { 103 | "codemirror_mode": { 104 | "name": "ipython", 105 | "version": 3 106 | }, 107 | "file_extension": ".py", 108 | "mimetype": "text/x-python", 109 | "name": "python", 110 | "nbconvert_exporter": "python", 111 | "pygments_lexer": "ipython3", 112 | "version": "3.8.8" 113 | }, 114 | "toc": { 115 | "base_numbering": 1, 116 | "nav_menu": {}, 117 | "number_sections": true, 118 | "sideBar": true, 119 | "skip_h1_title": false, 120 | "title_cell": "Table of Contents", 121 | "title_sidebar": "Contents", 122 | "toc_cell": false, 123 | "toc_position": {}, 124 | "toc_section_display": true, 125 | "toc_window_display": false 126 | }, 127 | "varInspector": { 128 | "cols": { 129 | "lenName": 16, 130 | "lenType": 16, 131 | "lenVar": 40 132 | }, 133 | "kernels_config": { 134 | "python": { 135 | "delete_cmd_postfix": "", 136 | "delete_cmd_prefix": "del ", 137 | "library": "var_list.py", 138 | "varRefreshCmd": "print(var_dic_list())" 139 | }, 140 | "r": { 141 | "delete_cmd_postfix": ") ", 142 | "delete_cmd_prefix": "rm(", 143 | "library": "var_list.r", 144 | "varRefreshCmd": "cat(var_dic_list()) " 145 | } 146 | }, 147 | "types_to_exclude": [ 148 | "module", 149 | "function", 150 | "builtin_function_or_method", 151 | "instance", 152 | "_Feature" 153 | ], 154 | "window_display": false 155 | } 156 | }, 157 | "nbformat": 4, 158 | "nbformat_minor": 2 159 | } 160 | -------------------------------------------------------------------------------- /014_Run_JavaScript_in_Python/README.md: -------------------------------------------------------------------------------- 1 |

2 | Last Commit 3 | 4 |

5 | 6 | 7 | 8 | # Run JavaScript in Python 9 | 10 | 11 | In this class, you'll learn how to run JavaScript in python. 12 | 13 | 14 | ## Prerequisites: 15 | 16 | 1. Python Basics 17 | 2. JavaScript Basics 18 | 3. js2py module 19 | 20 | --- 21 | 22 | ### 1. What is JavaScript? 23 | 24 | JavaScript, often abbreviated as JS, is a programming language that conforms to the ECMAScript specification. JavaScript is high-level, often just-in-time compiled, and multi-paradigm. It has curly-bracket syntax, dynamic typing, prototype-based object-orientation, and first-class functions. 25 | 26 | --- 27 | 28 | ## Install Necessary Modules: 29 | 30 | Open your [![Anaconda](https://img.shields.io/badge/Anaconda-342B029.svg?&style=flate&logo=anaconda&logoColor=white)](https://www.anaconda.com/products/individual) Prompt propmt and type and run the following command (individually): 31 | 32 | - pip install js2py 33 | 34 | 35 | **[`js2py`](https://github.com/PiotrDabkowski/Js2Py)** module is used to translator JavaScript to Python & acts as a JavaScript interpreter written in 100% pure Python. 36 | 37 | * It translates any valid JavaScript (ECMA Script 5.1) to Python. 38 | * Translation is fully automatic. 39 | * Does not have any dependencies - uses only standard python library. 40 | 41 | Limitations: 42 | 43 | * strict mode is ignored. 44 | * with statement is not supported. 45 | * Indirect call to eval will is treated as direct call to eval (hence always evals in local scope) 46 | 47 | Once Installed now we can import it inside our python code. 48 | 49 | --- 50 | 51 | ## Frequently asked questions ❔ 52 | 53 | ### How can I thank you for writing and sharing this tutorial? 🌷 54 | 55 | You can Star Badge and Fork Badge Starring and Forking is free for you, but it tells me and other people that it was helpful and you like this tutorial. 56 | 57 | Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) if you aren't here already and click ➞ **`✰ Star`** and **`ⵖ Fork`** button in the top right corner. You will be asked to create a GitHub account if you don't already have one. 58 | 59 | --- 60 | 61 | ### How can I read this tutorial without an Internet connection? GIF 62 | 63 | 1. Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) and click the big green ➞ **`Code`** button in the top right of the page, then click ➞ [**`Download ZIP`**](https://github.com/milaan9/91_Python_Mini_Projects/archive/refs/heads/main.zip). 64 | 65 | ![Download ZIP](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/img/dnld_rep.png) 66 | 67 | 2. Extract the ZIP and open it. Unfortunately I don't have any more specific instructions because how exactly this is done depends on which operating system you run. 68 | 69 | 3. Launch ipython notebook from the folder which contains the notebooks. Open each one of them 70 | 71 | `Kernel > Restart & Clear Output` 72 | 73 | This will clear all the outputs and now you can understand each statement and learn interactively. 74 | 75 | If you have git and you know how to use it, you can also clone the repository instead of downloading a zip and extracting it. An advantage with doing it this way is that you don't need to download the whole tutorial again to get the latest version of it, all you need to do is to pull with git and run ipython notebook again. 76 | 77 | --- 78 | 79 | ## Authors ✍️ 80 | 81 | I'm Dr. Milaan Parmar and I have written this tutorial. If you think you can add/correct/edit and enhance this tutorial you are most welcome🙏 82 | 83 | See [github's contributors page](https://github.com/milaan9/91_Python_Mini_Projects/graphs/contributors) for details. 84 | 85 | If you have trouble with this tutorial please tell me about it by [Create an issue on GitHub](https://github.com/milaan9/91_Python_Mini_Projects/issues/new). and I'll make this tutorial better. This is probably the best choice if you had trouble following the tutorial, and something in it should be explained better. You will be asked to create a GitHub account if you don't already have one. 86 | 87 | If you like this tutorial, please [give it a ⭐ star](https://github.com/milaan9/91_Python_Mini_Projects). 88 | 89 | --- 90 | 91 | ## Licence 📜 92 | 93 | You may use this tutorial freely at your own risk. See [LICENSE](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/LICENSE). 94 | 95 | Copyright (c) 2020 Dr. Milaan Parmar 96 | 97 | --- 98 | 99 |
100 |

Connect with me 101 |

102 |

103 | LinkedIn 104 | Instagram 105 | Facebook 106 | Gmail 107 |

108 | -------------------------------------------------------------------------------- /015_Web_Scraping_Covid-19_Data/Covid-19_data.csv: -------------------------------------------------------------------------------- 1 | ,CoronaData 2 | TotalCases,"35,185,064 " 3 | TotalDeaths,"626,717" 4 | TotalRecovered,"29,507,148" 5 | -------------------------------------------------------------------------------- /015_Web_Scraping_Covid-19_Data/README.md: -------------------------------------------------------------------------------- 1 |

2 | Last Commit 3 | 4 |

5 | 6 | 7 | 8 | # Web Scraping Covid-19 Data 9 | 10 | In this class, you'll learn how to perform web scraping on Covid-19 data using python. 11 | 12 | 13 | ## Prerequisites: 14 | 15 | 1. Python Basics 16 | 2. pandas Basics 17 | 3. HTML Basics 18 | 4. CSS module 19 | 5. Beautiful soup/bs4 module 20 | 6. requests module 21 | 7. lxml module 22 | 23 | --- 24 | 25 | ### 1. What is Web Scrapping?? 26 | 27 | **[Web scraping](https://en.wikipedia.org/wiki/Web_scraping)**, also known as web **data extraction**, is the process of retrieving or “scraping” data from a website. This information is collected and then exported into a format that is more useful for the user. Be it a spreadsheet or an API. 28 | 29 | #### Two important points to be taken into consideration here: 30 | 31 | 1. Always be respectful and try to get permission to scrape, do not bombard a website with scraping requests, otherwise, your IP address may get blocked! 32 | 2. Be aware that websites change often, meaning your code could go from working to totally broken from one day to the next. 33 | 34 | #### The Process: 35 | 1. Request for a response from the webpage 36 | 2. Parse and extract with the help of Beautiful soup and lxml 37 | 3. Download and export the data with pandas into excel 38 | 39 | #### Uses 40 | It can serve several purposes, most popular ones are Investment Decision Making, Competitor Monitoring, News Monitoring, Market Trend Analysis, Appraising Property Value, Estimating Rental Yields, Politics and Campaigns and many more. 41 | 42 | ### 2. Covid-19 Data Source 43 | 44 | We will use **[Worldometer](https://www.worldometers.info/coronavirus/#countries)** website to fetch the data because we are interested in the data contained in a table at Worldometer’s website, where there are lists all the countries together with their current reported coronavirus cases, new cases for the day, total deaths, new deaths for the day, etc. 45 | 46 |

47 | 48 |

49 | 50 |

51 | 52 |

53 | 54 | ### 3. HTML 55 | 56 | ```html 57 | 58 | 59 | 60 | 61 | 62 |

Scrapping

63 |

Hello

64 | 65 | 66 | ``` 67 | 68 | * **``**: HTML documents must start with a type declaration. 69 | * The HTML document is contained between **``** and **``** . 70 | * The meta and script declaration of the HTML document is between **``** and **``** . 71 | * The visible part of the HTML document is between **``** and **``** tags. 72 | * Title headings are defined with the **`

`** through **`

`** tags. 73 | * Paragraphs are defined with the **`

`** tag. 74 | * Other useful tags include **``** for hyperlinks, **``** for tables, **``** for table rows, and **`
`** for table columns. 75 | --- 76 | 77 | ## Install Necessary Modules: 78 | 79 | Open your [![Anaconda](https://img.shields.io/badge/Anaconda-342B029.svg?&style=flate&logo=anaconda&logoColor=white)](https://www.continuum.io/downloads) Prompt propmt and type and run the following command (individually): 80 | 81 | - pip install requests 82 | - pip install lxml 83 | - pip install bs4 84 | 85 | ### requests 86 | * Use the requests library to grab the page. 87 | * This may fail if you have a firewall blocking Python/Jupyter. 88 | * Sometimes you need to run this twice if it fails the first time. 89 | 90 | 91 | ### Beautiful soup 92 | **[BeautifulSoup](https://www.crummy.com/software/BeautifulSoup/bs4/doc/)** library already has lots of built-in tools and methods to grab information from a string of this nature (basically an HTML file). It is a Python library for pulling data out of HTML and XML files. 93 | 94 | Using BeautifulSoup we can create a "soup" object that contains all the "ingredients" of the webpage. 95 | 96 | Once Installed now we can import it inside our python code. 97 | 98 | --- 99 | 100 | ## Frequently asked questions ❔ 101 | 102 | ### How can I thank you for writing and sharing this tutorial? 🌷 103 | 104 | You can Star Badge and Fork Badge Starring and Forking is free for you, but it tells me and other people that it was helpful and you like this tutorial. 105 | 106 | Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) if you aren't here already and click ➞ **`✰ Star`** and **`ⵖ Fork`** button in the top right corner. You will be asked to create a GitHub account if you don't already have one. 107 | 108 | --- 109 | 110 | ### How can I read this tutorial without an Internet connection? GIF 111 | 112 | 1. Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) and click the big green ➞ **`Code`** button in the top right of the page, then click ➞ [**`Download ZIP`**](https://github.com/milaan9/91_Python_Mini_Projects/archive/refs/heads/main.zip). 113 | 114 | ![Download ZIP](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/img/dnld_rep.png) 115 | 116 | 2. Extract the ZIP and open it. Unfortunately I don't have any more specific instructions because how exactly this is done depends on which operating system you run. 117 | 118 | 3. Launch ipython notebook from the folder which contains the notebooks. Open each one of them 119 | 120 | `Kernel > Restart & Clear Output` 121 | 122 | This will clear all the outputs and now you can understand each statement and learn interactively. 123 | 124 | If you have git and you know how to use it, you can also clone the repository instead of downloading a zip and extracting it. An advantage with doing it this way is that you don't need to download the whole tutorial again to get the latest version of it, all you need to do is to pull with git and run ipython notebook again. 125 | 126 | --- 127 | 128 | ## Authors ✍️ 129 | 130 | I'm Dr. Milaan Parmar and I have written this tutorial. If you think you can add/correct/edit and enhance this tutorial you are most welcome🙏 131 | 132 | See [github's contributors page](https://github.com/milaan9/91_Python_Mini_Projects/graphs/contributors) for details. 133 | 134 | If you have trouble with this tutorial please tell me about it by [Create an issue on GitHub](https://github.com/milaan9/91_Python_Mini_Projects/issues/new). and I'll make this tutorial better. This is probably the best choice if you had trouble following the tutorial, and something in it should be explained better. You will be asked to create a GitHub account if you don't already have one. 135 | 136 | If you like this tutorial, please [give it a ⭐ star](https://github.com/milaan9/91_Python_Mini_Projects). 137 | 138 | --- 139 | 140 | ## Licence 📜 141 | 142 | You may use this tutorial freely at your own risk. See [LICENSE](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/LICENSE). 143 | 144 | Copyright (c) 2020 Dr. Milaan Parmar 145 | 146 | --- 147 | 148 |
149 |

Connect with me 150 |

151 |

152 | LinkedIn 153 | Instagram 154 | Facebook 155 | Gmail 156 |

157 | -------------------------------------------------------------------------------- /015_Web_Scraping_Covid-19_Data/wordometer1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/015_Web_Scraping_Covid-19_Data/wordometer1.png -------------------------------------------------------------------------------- /015_Web_Scraping_Covid-19_Data/wordometer2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/015_Web_Scraping_Covid-19_Data/wordometer2.png -------------------------------------------------------------------------------- /016_Web_Scraping_CoWin_Vaccine_Slots/CoWin.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/016_Web_Scraping_CoWin_Vaccine_Slots/CoWin.png -------------------------------------------------------------------------------- /016_Web_Scraping_CoWin_Vaccine_Slots/README.md: -------------------------------------------------------------------------------- 1 |

2 | Last Commit 3 | 4 |

5 | 6 | 7 | 8 | # Web Scraping CoWin Vaccine Slots 9 | 10 | In this class, you'll learn how to perform web scraping on CoWin vaccine slots. 11 | 12 | 13 | ## Prerequisites: 14 | 15 | 1. Python Basics 16 | 2. HTML Basics 17 | 3. requests module 18 | 7. pygame module 19 | 20 | --- 21 | 22 | ### 1. What is Web Scrapping?? 23 | 24 | **[Web scraping](https://en.wikipedia.org/wiki/Web_scraping)**, also known as web **data extraction**, is the process of retrieving or “scraping” data from a website. This information is collected and then exported into a format that is more useful for the user. Be it a spreadsheet or an API. 25 | 26 | #### Two important points to be taken into consideration here: 27 | 28 | 1. Always be respectful and try to get permission to scrape, do not bombard a website with scraping requests, otherwise, your IP address may get blocked! 29 | 2. Be aware that websites change often, meaning your code could go from working to totally broken from one day to the next. 30 | 31 | #### The Process: 32 | 1. Request for a response from the webpage 33 | 2. Parse and extract with the help of Beautiful soup and lxml 34 | 3. Download and export the data with pandas into excel 35 | 36 | #### Uses 37 | It can serve several purposes, most popular ones are Investment Decision Making, Competitor Monitoring, News Monitoring, Market Trend Analysis, Appraising Property Value, Estimating Rental Yields, Politics and Campaigns and many more. 38 | 39 | ### 2. Covid-19 Data Source 40 | 41 | We will use **[CoWin](https://www.cowin.gov.in/)** website to fetch the data because we are interested in the data contained in a table at CoWin’s website, where there are lists all the available slots for vaccination along with the types of vaccines and their prices. 42 | 43 |

44 | 45 |

46 | 47 | 48 | ### 3. HTML 49 | 50 | ```html 51 | 52 | 53 | 54 | 55 | 56 |

Scrapping

57 |

Hello

58 | 59 | 60 | ``` 61 | 62 | * **``**: HTML documents must start with a type declaration. 63 | * The HTML document is contained between **``** and **``** . 64 | * The meta and script declaration of the HTML document is between **``** and **``** . 65 | * The visible part of the HTML document is between **``** and **``** tags. 66 | * Title headings are defined with the **`

`** through **`

`** tags. 67 | * Paragraphs are defined with the **`

`** tag. 68 | * Other useful tags include **``** for hyperlinks, **``** for tables, **``** for table rows, and **`
`** for table columns. 69 | --- 70 | 71 | ## Install Necessary Modules: 72 | 73 | Open your [![Anaconda](https://img.shields.io/badge/Anaconda-342B029.svg?&style=flate&logo=anaconda&logoColor=white)](https://www.continuum.io/downloads) Prompt propmt and type and run the following command (individually): 74 | 75 | - pip install requests 76 | - pip install pygame 77 | 78 | ### requests 79 | * Use the requests library to grab the page. 80 | * This may fail if you have a firewall blocking Python/Jupyter. 81 | * Sometimes you need to run this twice if it fails the first time. 82 | 83 | Once Installed now we can import it inside our python code. 84 | 85 | --- 86 | 87 | ## Frequently asked questions ❔ 88 | 89 | ### How can I thank you for writing and sharing this tutorial? 🌷 90 | 91 | You can Star Badge and Fork Badge Starring and Forking is free for you, but it tells me and other people that it was helpful and you like this tutorial. 92 | 93 | Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) if you aren't here already and click ➞ **`✰ Star`** and **`ⵖ Fork`** button in the top right corner. You will be asked to create a GitHub account if you don't already have one. 94 | 95 | --- 96 | 97 | ### How can I read this tutorial without an Internet connection? GIF 98 | 99 | 1. Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) and click the big green ➞ **`Code`** button in the top right of the page, then click ➞ [**`Download ZIP`**](https://github.com/milaan9/91_Python_Mini_Projects/archive/refs/heads/main.zip). 100 | 101 | ![Download ZIP](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/img/dnld_rep.png) 102 | 103 | 2. Extract the ZIP and open it. Unfortunately I don't have any more specific instructions because how exactly this is done depends on which operating system you run. 104 | 105 | 3. Launch ipython notebook from the folder which contains the notebooks. Open each one of them 106 | 107 | `Kernel > Restart & Clear Output` 108 | 109 | This will clear all the outputs and now you can understand each statement and learn interactively. 110 | 111 | If you have git and you know how to use it, you can also clone the repository instead of downloading a zip and extracting it. An advantage with doing it this way is that you don't need to download the whole tutorial again to get the latest version of it, all you need to do is to pull with git and run ipython notebook again. 112 | 113 | --- 114 | 115 | ## Authors ✍️ 116 | 117 | I'm Dr. Milaan Parmar and I have written this tutorial. If you think you can add/correct/edit and enhance this tutorial you are most welcome🙏 118 | 119 | See [github's contributors page](https://github.com/milaan9/91_Python_Mini_Projects/graphs/contributors) for details. 120 | 121 | If you have trouble with this tutorial please tell me about it by [Create an issue on GitHub](https://github.com/milaan9/91_Python_Mini_Projects/issues/new). and I'll make this tutorial better. This is probably the best choice if you had trouble following the tutorial, and something in it should be explained better. You will be asked to create a GitHub account if you don't already have one. 122 | 123 | If you like this tutorial, please [give it a ⭐ star](https://github.com/milaan9/91_Python_Mini_Projects). 124 | 125 | --- 126 | 127 | ## Licence 📜 128 | 129 | You may use this tutorial freely at your own risk. See [LICENSE](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/LICENSE). 130 | 131 | Copyright (c) 2020 Dr. Milaan Parmar 132 | 133 | --- 134 | 135 |
136 |

Connect with me 137 |

138 |

139 | LinkedIn 140 | Instagram 141 | Facebook 142 | Gmail 143 |

144 | -------------------------------------------------------------------------------- /017_Check_Weather_Forecast_with_GUI/README.md: -------------------------------------------------------------------------------- 1 |

2 | Last Commit 3 | 4 |

5 | 6 | 7 | 8 | # Check Weather Forecast with GUI 9 | 10 | In this class, you'll learn how to check weather forecast with GUI using python 11 | 12 |

13 | 14 |

15 | 16 | 17 | ## Prerequisites: 18 | 19 | 1. Python Basics 20 | 2. tkinter module 21 | 3. tkinter.ttk module 22 | 23 | --- 24 | 25 | 26 | ## Install Necessary Modules: 27 | 28 | Since **`tkinter`** and **`tkinter.ttk`** modules are in-built modules, hence we do not need to install them separately. 29 | 30 | --- 31 | 32 | ## Frequently asked questions ❔ 33 | 34 | ### How can I thank you for writing and sharing this tutorial? 🌷 35 | 36 | You can Star Badge and Fork Badge Starring and Forking is free for you, but it tells me and other people that it was helpful and you like this tutorial. 37 | 38 | Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) if you aren't here already and click ➞ **`✰ Star`** and **`ⵖ Fork`** button in the top right corner. You will be asked to create a GitHub account if you don't already have one. 39 | 40 | --- 41 | 42 | ### How can I read this tutorial without an Internet connection? GIF 43 | 44 | 1. Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) and click the big green ➞ **`Code`** button in the top right of the page, then click ➞ [**`Download ZIP`**](https://github.com/milaan9/91_Python_Mini_Projects/archive/refs/heads/main.zip). 45 | 46 | ![Download ZIP](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/img/dnld_rep.png) 47 | 48 | 2. Extract the ZIP and open it. Unfortunately I don't have any more specific instructions because how exactly this is done depends on which operating system you run. 49 | 50 | 3. Launch ipython notebook from the folder which contains the notebooks. Open each one of them 51 | 52 | `Kernel > Restart & Clear Output` 53 | 54 | This will clear all the outputs and now you can understand each statement and learn interactively. 55 | 56 | If you have git and you know how to use it, you can also clone the repository instead of downloading a zip and extracting it. An advantage with doing it this way is that you don't need to download the whole tutorial again to get the latest version of it, all you need to do is to pull with git and run ipython notebook again. 57 | 58 | --- 59 | 60 | ## Authors ✍️ 61 | 62 | I'm Dr. Milaan Parmar and I have written this tutorial. If you think you can add/correct/edit and enhance this tutorial you are most welcome🙏 63 | 64 | See [github's contributors page](https://github.com/milaan9/91_Python_Mini_Projects/graphs/contributors) for details. 65 | 66 | If you have trouble with this tutorial please tell me about it by [Create an issue on GitHub](https://github.com/milaan9/91_Python_Mini_Projects/issues/new). and I'll make this tutorial better. This is probably the best choice if you had trouble following the tutorial, and something in it should be explained better. You will be asked to create a GitHub account if you don't already have one. 67 | 68 | If you like this tutorial, please [give it a ⭐ star](https://github.com/milaan9/91_Python_Mini_Projects). 69 | 70 | --- 71 | 72 | ## Licence 📜 73 | 74 | You may use this tutorial freely at your own risk. See [LICENSE](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/LICENSE). 75 | 76 | Copyright (c) 2020 Dr. Milaan Parmar 77 | 78 | --- 79 | 80 |
81 |

Connect with me 82 |

83 |

84 | LinkedIn 85 | Instagram 86 | Facebook 87 | Gmail 88 |

89 | -------------------------------------------------------------------------------- /017_Check_Weather_Forecast_with_GUI/get_weather_icons.ipynb: -------------------------------------------------------------------------------- 1 | { 2 | "cells": [ 3 | { 4 | "cell_type": "markdown", 5 | "metadata": {}, 6 | "source": [ 7 | "\n", 8 | "All the IPython Notebooks in **Python Mini-Projects** series by Dr. Milaan Parmar are available @ **[GitHub](https://github.com/milaan9/91_Python_Mini_Projects)**\n", 9 | "" 10 | ] 11 | }, 12 | { 13 | "cell_type": "code", 14 | "execution_count": null, 15 | "metadata": { 16 | "ExecuteTime": { 17 | "start_time": "2021-08-09T09:46:34.731Z" 18 | } 19 | }, 20 | "outputs": [], 21 | "source": [ 22 | "import os\n", 23 | "import urllib.request\n", 24 | "\n", 25 | "day = ['01d.png', '02d.png', '03d.png', '04d.png', '09d.png', '10d.png', '11d.png', '13n.png', '50d.png']\n", 26 | "night = ['01n.png', '02n.png', '03n.png', '04n.png', '09n.png', '10n.png', '11n.png', '13n.png', '50n.png']\n", 27 | "\n", 28 | "base_url = 'https://openweathermap.org/img/w/'\n", 29 | "img_dir = './img/'\n", 30 | "if not os.path.exists(img_dir):\n", 31 | "\tos.makedirs(img_dir)\n", 32 | "\n", 33 | "# Get the day weather icons\n", 34 | "for name in day:\n", 35 | "\tfile_name = img_dir+name\n", 36 | "\tif not os.path.exists(file_name):\n", 37 | "\t\turllib.request.urlretrieve(base_url+name, file_name)\n", 38 | "\n", 39 | "# Repeat the same thing for night weather icons\n", 40 | "for name in night:\n", 41 | "\tfile_name = img_dir+name\n", 42 | "\tif not os.path.exists(file_name):\n", 43 | "\t\turllib.request.urlretrieve(base_url+name, file_name)" 44 | ] 45 | } 46 | ], 47 | "metadata": { 48 | "hide_input": false, 49 | "kernelspec": { 50 | "display_name": "Python 3", 51 | "language": "python", 52 | "name": "python3" 53 | }, 54 | "language_info": { 55 | "codemirror_mode": { 56 | "name": "ipython", 57 | "version": 3 58 | }, 59 | "file_extension": ".py", 60 | "mimetype": "text/x-python", 61 | "name": "python", 62 | "nbconvert_exporter": "python", 63 | "pygments_lexer": "ipython3", 64 | "version": "3.8.8" 65 | }, 66 | "toc": { 67 | "base_numbering": 1, 68 | "nav_menu": {}, 69 | "number_sections": true, 70 | "sideBar": true, 71 | "skip_h1_title": false, 72 | "title_cell": "Table of Contents", 73 | "title_sidebar": "Contents", 74 | "toc_cell": false, 75 | "toc_position": {}, 76 | "toc_section_display": true, 77 | "toc_window_display": false 78 | }, 79 | "varInspector": { 80 | "cols": { 81 | "lenName": 16, 82 | "lenType": 16, 83 | "lenVar": 40 84 | }, 85 | "kernels_config": { 86 | "python": { 87 | "delete_cmd_postfix": "", 88 | "delete_cmd_prefix": "del ", 89 | "library": "var_list.py", 90 | "varRefreshCmd": "print(var_dic_list())" 91 | }, 92 | "r": { 93 | "delete_cmd_postfix": ") ", 94 | "delete_cmd_prefix": "rm(", 95 | "library": "var_list.r", 96 | "varRefreshCmd": "cat(var_dic_list()) " 97 | } 98 | }, 99 | "types_to_exclude": [ 100 | "module", 101 | "function", 102 | "builtin_function_or_method", 103 | "instance", 104 | "_Feature" 105 | ], 106 | "window_display": false 107 | } 108 | }, 109 | "nbformat": 4, 110 | "nbformat_minor": 4 111 | } 112 | -------------------------------------------------------------------------------- /017_Check_Weather_Forecast_with_GUI/img/01d.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/017_Check_Weather_Forecast_with_GUI/img/01d.png -------------------------------------------------------------------------------- /017_Check_Weather_Forecast_with_GUI/img/02d.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/017_Check_Weather_Forecast_with_GUI/img/02d.png -------------------------------------------------------------------------------- /017_Check_Weather_Forecast_with_GUI/img/03d.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/017_Check_Weather_Forecast_with_GUI/img/03d.png -------------------------------------------------------------------------------- /017_Check_Weather_Forecast_with_GUI/img/04d.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/017_Check_Weather_Forecast_with_GUI/img/04d.png -------------------------------------------------------------------------------- /017_Check_Weather_Forecast_with_GUI/img/landscape.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/017_Check_Weather_Forecast_with_GUI/img/landscape.png -------------------------------------------------------------------------------- /017_Check_Weather_Forecast_with_GUI/img/result_1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/017_Check_Weather_Forecast_with_GUI/img/result_1.png -------------------------------------------------------------------------------- /017_Check_Weather_Forecast_with_GUI/img/result_2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/017_Check_Weather_Forecast_with_GUI/img/result_2.png -------------------------------------------------------------------------------- /017_Check_Weather_Forecast_with_GUI/img/sun_icon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/017_Check_Weather_Forecast_with_GUI/img/sun_icon.ico -------------------------------------------------------------------------------- /018_Draw_Sakura_Tree/018_Draw_Sakura_Tree.ipynb: -------------------------------------------------------------------------------- 1 | { 2 | "cells": [ 3 | { 4 | "cell_type": "markdown", 5 | "metadata": {}, 6 | "source": [ 7 | "\n", 8 | "All the IPython Notebooks in **Python Mini-Projects** series by Dr. Milaan Parmar are available @ **[GitHub](https://github.com/milaan9/91_Python_Mini_Projects)**\n", 9 | "" 10 | ] 11 | }, 12 | { 13 | "cell_type": "markdown", 14 | "metadata": {}, 15 | "source": [ 16 | "# Python Program to draw Sakura Tree" 17 | ] 18 | }, 19 | { 20 | "cell_type": "code", 21 | "execution_count": 1, 22 | "metadata": { 23 | "ExecuteTime": { 24 | "end_time": "2021-09-21T08:32:47.179568Z", 25 | "start_time": "2021-09-21T08:32:37.930039Z" 26 | } 27 | }, 28 | "outputs": [], 29 | "source": [ 30 | "'''\n", 31 | "Python Program to Create Digital Clock\n", 32 | "'''\n", 33 | "\n", 34 | "# Import necessary modules!\n", 35 | "import turtle\n", 36 | "import random\n", 37 | "from turtle import *\n", 38 | "from time import sleep\n", 39 | "\n", 40 | "static_turtle = turtle.Turtle()\n", 41 | "frame = turtle.Screen()\n", 42 | "\n", 43 | "def tree(branch_len, inner_turtle):\n", 44 | " if branch_len > 3:\n", 45 | " if 9 <= branch_len <= 12:\n", 46 | " if random.randint(0, 2) == 0:\n", 47 | " inner_turtle.color(\"snow\")\n", 48 | " else:\n", 49 | " inner_turtle.color(\"lightcoral\")\n", 50 | " inner_turtle.pensize(branch_len / 3)\n", 51 | " elif branch_len < 9:\n", 52 | " if random.randint(0, 1) == 0:\n", 53 | " inner_turtle.color(\"snow\")\n", 54 | " else:\n", 55 | " inner_turtle.color(\"lightcoral\")\n", 56 | " inner_turtle.pensize(branch_len / 2)\n", 57 | " else:\n", 58 | " inner_turtle.color(\"sienna\")\n", 59 | " inner_turtle.pensize(branch_len / 10)\n", 60 | "\n", 61 | " inner_turtle.forward(branch_len)\n", 62 | " angle_elem = 1.5 * random.random()\n", 63 | " inner_turtle.right(20 * angle_elem)\n", 64 | " length_elem = 1.5 * random.random()\n", 65 | " tree(branch_len - 10 * length_elem, inner_turtle)\n", 66 | " inner_turtle.left(40 * angle_elem)\n", 67 | " tree(branch_len - 10 * length_elem, inner_turtle)\n", 68 | " inner_turtle.right(20 * angle_elem)\n", 69 | " inner_turtle.up()\n", 70 | " inner_turtle.backward(branch_len)\n", 71 | " inner_turtle.down()\n", 72 | " \n", 73 | "def petal(maxim, inner_turtle):\n", 74 | " for i in range(maxim):\n", 75 | " right_branch = 300 - 500 * random.random()\n", 76 | " left_branch = 30 - 50 * random.random()\n", 77 | " inner_turtle.up()\n", 78 | " inner_turtle.forward(left_branch)\n", 79 | " inner_turtle.left(90)\n", 80 | " inner_turtle.forward(right_branch)\n", 81 | " inner_turtle.down()\n", 82 | " inner_turtle.color(\"lightcoral\")\n", 83 | " inner_turtle.circle(1)\n", 84 | " inner_turtle.up()\n", 85 | " inner_turtle.backward(right_branch)\n", 86 | " inner_turtle.right(90)\n", 87 | " inner_turtle.backward(left_branch)\n", 88 | " \n", 89 | "if __name__ == '__main__':\n", 90 | " static_turtle = turtle.Turtle()\n", 91 | " my_frame = turtle.Screen()\n", 92 | " getscreen().tracer(5, 0)\n", 93 | " turtle.screensize(bg=\"#f3cef5\") \n", 94 | " static_turtle.left(90)\n", 95 | " static_turtle.up()\n", 96 | " static_turtle.backward(150)\n", 97 | " static_turtle.down()\n", 98 | " static_turtle.color(\"sienna\") \n", 99 | " tree(60, static_turtle)\n", 100 | " petal(100, static_turtle)\n", 101 | " my_frame.exitonclick() " 102 | ] 103 | }, 104 | { 105 | "cell_type": "markdown", 106 | "metadata": {}, 107 | "source": [ 108 | "

\n", 109 | " \n", 110 | "

" 111 | ] 112 | }, 113 | { 114 | "cell_type": "code", 115 | "execution_count": null, 116 | "metadata": {}, 117 | "outputs": [], 118 | "source": [] 119 | } 120 | ], 121 | "metadata": { 122 | "hide_input": false, 123 | "kernelspec": { 124 | "display_name": "Python 3", 125 | "language": "python", 126 | "name": "python3" 127 | }, 128 | "language_info": { 129 | "codemirror_mode": { 130 | "name": "ipython", 131 | "version": 3 132 | }, 133 | "file_extension": ".py", 134 | "mimetype": "text/x-python", 135 | "name": "python", 136 | "nbconvert_exporter": "python", 137 | "pygments_lexer": "ipython3", 138 | "version": "3.8.8" 139 | }, 140 | "toc": { 141 | "base_numbering": 1, 142 | "nav_menu": {}, 143 | "number_sections": true, 144 | "sideBar": true, 145 | "skip_h1_title": false, 146 | "title_cell": "Table of Contents", 147 | "title_sidebar": "Contents", 148 | "toc_cell": false, 149 | "toc_position": {}, 150 | "toc_section_display": true, 151 | "toc_window_display": false 152 | }, 153 | "varInspector": { 154 | "cols": { 155 | "lenName": 16, 156 | "lenType": 16, 157 | "lenVar": 40 158 | }, 159 | "kernels_config": { 160 | "python": { 161 | "delete_cmd_postfix": "", 162 | "delete_cmd_prefix": "del ", 163 | "library": "var_list.py", 164 | "varRefreshCmd": "print(var_dic_list())" 165 | }, 166 | "r": { 167 | "delete_cmd_postfix": ") ", 168 | "delete_cmd_prefix": "rm(", 169 | "library": "var_list.r", 170 | "varRefreshCmd": "cat(var_dic_list()) " 171 | } 172 | }, 173 | "types_to_exclude": [ 174 | "module", 175 | "function", 176 | "builtin_function_or_method", 177 | "instance", 178 | "_Feature" 179 | ], 180 | "window_display": false 181 | } 182 | }, 183 | "nbformat": 4, 184 | "nbformat_minor": 4 185 | } 186 | -------------------------------------------------------------------------------- /018_Draw_Sakura_Tree/README.md: -------------------------------------------------------------------------------- 1 |

2 | Last Commit 3 | 4 |

5 | 6 | 7 | 8 | # Draw Sakura Tree 9 | 10 | In this class, you'll learn how to draw Sakura tree using python 11 | 12 | 13 |

14 | 15 |

16 | 17 | ## Prerequisites: 18 | 19 | 1. Python Basics 20 | 2. turtle module 21 | 22 | --- 23 | 24 | ## Install Necessary Modules: 25 | 26 | Open your [![Anaconda](https://img.shields.io/badge/Anaconda-342B029.svg?&style=flate&logo=anaconda&logoColor=white)](https://www.anaconda.com/products/individual) Prompt propmt and type and run the following command (individually): 27 | 28 | - pip install turtle 29 | 30 | **[`turtle`](https://docs.python.org/3/library/turtle.html)** is a pre-installed Python library that allows users to create pictures and shapes with a provided, virtual canvas. We can use functions like turtle.forward(…) and turtle.right(…) which can move the turtle around. The onscreen pen you use to draw is called the turtle. 31 | 32 | Once Installed now we can import it inside our python code. 33 | 34 | --- 35 | 36 | ## Frequently asked questions ❔ 37 | 38 | ### How can I thank you for writing and sharing this tutorial? 🌷 39 | 40 | You can Star Badge and Fork Badge Starring and Forking is free for you, but it tells me and other people that it was helpful and you like this tutorial. 41 | 42 | Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) if you aren't here already and click ➞ **`✰ Star`** and **`ⵖ Fork`** button in the top right corner. You will be asked to create a GitHub account if you don't already have one. 43 | 44 | --- 45 | 46 | ### How can I read this tutorial without an Internet connection? GIF 47 | 48 | 1. Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) and click the big green ➞ **`Code`** button in the top right of the page, then click ➞ [**`Download ZIP`**](https://github.com/milaan9/91_Python_Mini_Projects/archive/refs/heads/main.zip). 49 | 50 | ![Download ZIP](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/img/dnld_rep.png) 51 | 52 | 2. Extract the ZIP and open it. Unfortunately I don't have any more specific instructions because how exactly this is done depends on which operating system you run. 53 | 54 | 3. Launch ipython notebook from the folder which contains the notebooks. Open each one of them 55 | 56 | `Kernel > Restart & Clear Output` 57 | 58 | This will clear all the outputs and now you can understand each statement and learn interactively. 59 | 60 | If you have git and you know how to use it, you can also clone the repository instead of downloading a zip and extracting it. An advantage with doing it this way is that you don't need to download the whole tutorial again to get the latest version of it, all you need to do is to pull with git and run ipython notebook again. 61 | 62 | --- 63 | 64 | ## Authors ✍️ 65 | 66 | I'm Dr. Milaan Parmar and I have written this tutorial. If you think you can add/correct/edit and enhance this tutorial you are most welcome🙏 67 | 68 | See [github's contributors page](https://github.com/milaan9/91_Python_Mini_Projects/graphs/contributors) for details. 69 | 70 | If you have trouble with this tutorial please tell me about it by [Create an issue on GitHub](https://github.com/milaan9/91_Python_Mini_Projects/issues/new). and I'll make this tutorial better. This is probably the best choice if you had trouble following the tutorial, and something in it should be explained better. You will be asked to create a GitHub account if you don't already have one. 71 | 72 | If you like this tutorial, please [give it a ⭐ star](https://github.com/milaan9/91_Python_Mini_Projects). 73 | 74 | --- 75 | 76 | ## Licence 📜 77 | 78 | You may use this tutorial freely at your own risk. See [LICENSE](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/LICENSE). 79 | 80 | Copyright (c) 2020 Dr. Milaan Parmar 81 | 82 | --- 83 | 84 |
85 |

Connect with me 86 |

87 |

88 | LinkedIn 89 | Instagram 90 | Facebook 91 | Gmail 92 |

93 | 94 | 95 | -------------------------------------------------------------------------------- /018_Draw_Sakura_Tree/sakura.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/018_Draw_Sakura_Tree/sakura.png -------------------------------------------------------------------------------- /019_Plagiarism_Checker/019_Plagiarism_Checker.ipynb: -------------------------------------------------------------------------------- 1 | { 2 | "cells": [ 3 | { 4 | "cell_type": "markdown", 5 | "metadata": {}, 6 | "source": [ 7 | "\n", 8 | "All the IPython Notebooks in **Python Mini-Projects** series by Dr. Milaan Parmar are available @ **[GitHub](https://github.com/milaan9/91_Python_Mini_Projects)**\n", 9 | "" 10 | ] 11 | }, 12 | { 13 | "cell_type": "markdown", 14 | "metadata": {}, 15 | "source": [ 16 | "# Python Program to Check Plagiarism " 17 | ] 18 | }, 19 | { 20 | "cell_type": "code", 21 | "execution_count": 1, 22 | "metadata": { 23 | "ExecuteTime": { 24 | "end_time": "2021-10-05T13:06:11.749110Z", 25 | "start_time": "2021-10-05T13:06:09.467318Z" 26 | } 27 | }, 28 | "outputs": [ 29 | { 30 | "name": "stdout", 31 | "output_type": "stream", 32 | "text": [ 33 | "Similarity data:\n", 34 | " ('Ben.txt', 'Clark.txt', 0.408904884400347)\n", 35 | "Similarity data:\n", 36 | " ('Arthur.txt', 'Clark.txt', 0.5430431121089816)\n", 37 | "Similarity data:\n", 38 | " ('Arthur.txt', 'Ben.txt', 0.4595329317649595)\n" 39 | ] 40 | } 41 | ], 42 | "source": [ 43 | "'''\n", 44 | "Python Program to Check Plagiarism \n", 45 | "'''\n", 46 | "\n", 47 | "# Import necessary modules!\n", 48 | "import os\n", 49 | "from sklearn.feature_extraction.text import TfidfVectorizer\n", 50 | "from sklearn.metrics.pairwise import cosine_similarity\n", 51 | "\n", 52 | "student_files = [doc for doc in os.listdir() if doc.endswith('.txt')]\n", 53 | "student_notes = [open(_file, encoding='utf-8').read()\n", 54 | " for _file in student_files]\n", 55 | "\n", 56 | "\n", 57 | "def vectorize(Text): return TfidfVectorizer().fit_transform(Text).toarray()\n", 58 | "def similarity(doc1, doc2): return cosine_similarity([doc1, doc2])\n", 59 | "\n", 60 | "\n", 61 | "vectors = vectorize(student_notes)\n", 62 | "s_vectors = list(zip(student_files, vectors))\n", 63 | "plagiarism_results = set()\n", 64 | "\n", 65 | "\n", 66 | "def check_plagiarism():\n", 67 | " global s_vectors\n", 68 | " for student_a, text_vector_a in s_vectors:\n", 69 | " new_vectors = s_vectors.copy()\n", 70 | " current_index = new_vectors.index((student_a, text_vector_a))\n", 71 | " del new_vectors[current_index]\n", 72 | " for student_b, text_vector_b in new_vectors:\n", 73 | " sim_score = similarity(text_vector_a, text_vector_b)[0][1]\n", 74 | " student_pair = sorted((student_a, student_b))\n", 75 | " score = (student_pair[0], student_pair[1], sim_score)\n", 76 | " plagiarism_results.add(score)\n", 77 | " return plagiarism_results\n", 78 | "\n", 79 | "\n", 80 | "for data in check_plagiarism():\n", 81 | " print(\"Similarity data:\\n\", data) " 82 | ] 83 | }, 84 | { 85 | "cell_type": "code", 86 | "execution_count": null, 87 | "metadata": {}, 88 | "outputs": [], 89 | "source": [] 90 | } 91 | ], 92 | "metadata": { 93 | "hide_input": false, 94 | "kernelspec": { 95 | "display_name": "Python 3", 96 | "language": "python", 97 | "name": "python3" 98 | }, 99 | "language_info": { 100 | "codemirror_mode": { 101 | "name": "ipython", 102 | "version": 3 103 | }, 104 | "file_extension": ".py", 105 | "mimetype": "text/x-python", 106 | "name": "python", 107 | "nbconvert_exporter": "python", 108 | "pygments_lexer": "ipython3", 109 | "version": "3.8.8" 110 | }, 111 | "toc": { 112 | "base_numbering": 1, 113 | "nav_menu": {}, 114 | "number_sections": true, 115 | "sideBar": true, 116 | "skip_h1_title": false, 117 | "title_cell": "Table of Contents", 118 | "title_sidebar": "Contents", 119 | "toc_cell": false, 120 | "toc_position": {}, 121 | "toc_section_display": true, 122 | "toc_window_display": false 123 | }, 124 | "varInspector": { 125 | "cols": { 126 | "lenName": 16, 127 | "lenType": 16, 128 | "lenVar": 40 129 | }, 130 | "kernels_config": { 131 | "python": { 132 | "delete_cmd_postfix": "", 133 | "delete_cmd_prefix": "del ", 134 | "library": "var_list.py", 135 | "varRefreshCmd": "print(var_dic_list())" 136 | }, 137 | "r": { 138 | "delete_cmd_postfix": ") ", 139 | "delete_cmd_prefix": "rm(", 140 | "library": "var_list.r", 141 | "varRefreshCmd": "cat(var_dic_list()) " 142 | } 143 | }, 144 | "types_to_exclude": [ 145 | "module", 146 | "function", 147 | "builtin_function_or_method", 148 | "instance", 149 | "_Feature" 150 | ], 151 | "window_display": false 152 | } 153 | }, 154 | "nbformat": 4, 155 | "nbformat_minor": 4 156 | } 157 | -------------------------------------------------------------------------------- /019_Plagiarism_Checker/Arthur.txt: -------------------------------------------------------------------------------- 1 | Success can mean a variety of different things. Success is, quite simply, the accomplishment of a predetermined goal. To some people it could mean making money, cultivate and develop certain basic qualities, to others it could mean keeping everyone happy, but to me, it means achieving the goals and objective I have set for myself for my life. Besides working on your goals that would lead a person towards success it is very important to push your limit every day, take charge of your life, and keep learning. This experience enables us to think smartly to solve a critical problem and achieve success. It is very important to take care of your mind which could be done by eliminating negative thoughts and negative people from your life. I think in order to call something successful, both the result and the process should be great. Without success, you, the group, your company, your goals, dreams and even entire civilizations cease to survive. -------------------------------------------------------------------------------- /019_Plagiarism_Checker/Ben.txt: -------------------------------------------------------------------------------- 1 | In order to be successful one needs cultivate and develop certain basic qualities. Success is, quite simply, the accomplishment of a predetermined goal. We consciously or subconsciously set goals for ourselves all the time. First of all, you must know aim and objective of your life. Unless you know your destination, you cannot set out on a journey. At first, you must by very clear in your objectives to be achieved. Finally, you should enjoy the overall process rather than the final outcome. There is no shortcut to success. Hard work is the only key to achieving it; it teaches us discipline, dedication and determination. There is no single right way to be successful. What works for you might not work for someone else. -------------------------------------------------------------------------------- /019_Plagiarism_Checker/Clark.txt: -------------------------------------------------------------------------------- 1 | Success is, quite simply, the accomplishment of a predetermined goal. Success is considered to be a term that describes two things. It also the combination of variety of different things. The first one is achievement of a certain major or minor goal. This could be succeeding in making a delicious dinner, or a more global thing succeeding in a career or job. The second definition of success is more broad and subjective. Success provides confidence, security, a sense of well-being, the ability to contribute at a greater level, hope and leadership. This experience enables us to think smartly to solve a critical problem and achieve success. Without success, you, the group, your company, your goals, dreams and even entire civilizations cease to survive. -------------------------------------------------------------------------------- /019_Plagiarism_Checker/README.md: -------------------------------------------------------------------------------- 1 |

2 | Last Commit 3 | 4 |

5 | 6 | 7 | 8 | # Plagiarism Checker 9 | 10 | In this class, you'll learn how to check similarity between text (.txt) documents using cosine similarity 11 | 12 | In order to compute the simlilarity between on two text documents, the textual raw data is transformed into vectors ➡ **arrays of numbers** and then from that we are going to use a basic knowledge vector to compute the the similarity between them. 13 | 14 | 15 |

16 | 17 |

18 | 19 | ## Prerequisites: 20 | 21 | 1. Python Basics 22 | 2. sklearn module 23 | 24 | --- 25 | 26 | ## Install Necessary Modules: 27 | 28 | Open your [![Anaconda](https://img.shields.io/badge/Anaconda-342B029.svg?&style=flate&logo=anaconda&logoColor=white)](https://www.anaconda.com/products/individual) Prompt propmt and type and run the following command (individually): 29 | 30 | - pip install sklearn 31 | 32 | **[`Sklearn`](https://scikit-learn.org/)** (Scikit-learn) is the most useful and robust library for machine learning in Python. It provides a selection of efficient tools for machine learning and statistical modeling including classification, regression, clustering and dimensionality reduction via a consistence interface in Python. This library, which is largely written in Python, is built upon NumPy, SciPy and Matplotlib. 33 | 34 | Once Installed now we can import it inside our python code. 35 | 36 | --- 37 | 38 | ## Frequently asked questions ❔ 39 | 40 | ### How can I thank you for writing and sharing this tutorial? 🌷 41 | 42 | You can Star Badge and Fork Badge Starring and Forking is free for you, but it tells me and other people that it was helpful and you like this tutorial. 43 | 44 | Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) if you aren't here already and click ➞ **`✰ Star`** and **`ⵖ Fork`** button in the top right corner. You will be asked to create a GitHub account if you don't already have one. 45 | 46 | --- 47 | 48 | ### How can I read this tutorial without an Internet connection? GIF 49 | 50 | 1. Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) and click the big green ➞ **`Code`** button in the top right of the page, then click ➞ [**`Download ZIP`**](https://github.com/milaan9/91_Python_Mini_Projects/archive/refs/heads/main.zip). 51 | 52 | ![Download ZIP](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/img/dnld_rep.png) 53 | 54 | 2. Extract the ZIP and open it. Unfortunately I don't have any more specific instructions because how exactly this is done depends on which operating system you run. 55 | 56 | 3. Launch ipython notebook from the folder which contains the notebooks. Open each one of them 57 | 58 | `Kernel > Restart & Clear Output` 59 | 60 | This will clear all the outputs and now you can understand each statement and learn interactively. 61 | 62 | If you have git and you know how to use it, you can also clone the repository instead of downloading a zip and extracting it. An advantage with doing it this way is that you don't need to download the whole tutorial again to get the latest version of it, all you need to do is to pull with git and run ipython notebook again. 63 | 64 | --- 65 | 66 | ## Authors ✍️ 67 | 68 | I'm Dr. Milaan Parmar and I have written this tutorial. If you think you can add/correct/edit and enhance this tutorial you are most welcome🙏 69 | 70 | See [github's contributors page](https://github.com/milaan9/91_Python_Mini_Projects/graphs/contributors) for details. 71 | 72 | If you have trouble with this tutorial please tell me about it by [Create an issue on GitHub](https://github.com/milaan9/91_Python_Mini_Projects/issues/new). and I'll make this tutorial better. This is probably the best choice if you had trouble following the tutorial, and something in it should be explained better. You will be asked to create a GitHub account if you don't already have one. 73 | 74 | If you like this tutorial, please [give it a ⭐ star](https://github.com/milaan9/91_Python_Mini_Projects). 75 | 76 | --- 77 | 78 | ## Licence 📜 79 | 80 | You may use this tutorial freely at your own risk. See [LICENSE](https://github.com/milaan9/91_Python_Mini_Projects/blob/main/LICENSE). 81 | 82 | Copyright (c) 2020 Dr. Milaan Parmar 83 | 84 | --- 85 | 86 |
87 |

Connect with me 88 |

89 |

90 | LinkedIn 91 | Instagram 92 | Facebook 93 | Gmail 94 |

95 | 96 | 97 | -------------------------------------------------------------------------------- /019_Plagiarism_Checker/output.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/019_Plagiarism_Checker/output.png -------------------------------------------------------------------------------- /020_Road_Detection/img/road_1.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/020_Road_Detection/img/road_1.jpeg -------------------------------------------------------------------------------- /020_Road_Detection/img/road_2.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/020_Road_Detection/img/road_2.jpeg -------------------------------------------------------------------------------- /020_Road_Detection/img/road_3.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/020_Road_Detection/img/road_3.jpeg -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2021 milaan9 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 |

2 | Last Commit 3 | 4 | 5 | 6 | 7 | Stars Badge 8 | Forks Badge 9 | Size 10 | Pull Requests Badge 11 | Issues Badge 12 | Language 13 | MIT License 14 |

15 | 16 | 17 |

18 | binder 19 | colab 20 |

21 | 22 | # 91_Python_Mini_Projects 23 | 24 | This repository contains all the mini-projects that I've worked on python. 25 | 26 | | **No.** | **Name** | 27 | | ------- | -------- | 28 | | 01 | **[001_Convert_IPython_to_PDF](https://github.com/milaan9/91_Python_Mini_Projects/tree/main/001_Convert_IPython_to_PDF)** | 29 | | 02 | **[002_Create_Digital_Clock_and_Stopwatch](https://github.com/milaan9/91_Python_Mini_Projects/tree/main/002_Create_Digital_Clock)** | 30 | | 03 | **[003_Convert_.py_to_.exe](https://github.com/milaan9/91_Python_Mini_Projects/tree/main/003_Convert_.py_to_.exe)** | 31 | | 04 | **[004_Find_IP_Address](https://github.com/milaan9/91_Python_Mini_Projects/tree/main/004_Find_IP_Address)** | 32 | | 05 | **[005_Test_Internet_Speed](https://github.com/milaan9/91_Python_Mini_Projects/tree/main/005_Test_Internet_Speed)** | 33 | | 06 | **[006_Check_Weather_Forecast](https://github.com/milaan9/91_Python_Mini_Projects/tree/main/006_Check_Weather_Forecast)** | 34 | | 07 | **[007_Create_AudioBook_from_PDF](https://github.com/milaan9/91_Python_Mini_Projects/tree/main/007_Create_AudioBook_from_PDF)** | 35 | | 08 | **[008_Generate_Random_Jokes](https://github.com/milaan9/91_Python_Mini_Projects/tree/main/008_Generate_Random_Jokes)** | 36 | | 09 | **[009_Convert_image_to_ASCII_Grayscale_Negative_and_Pencil_Sketch_Art](https://github.com/milaan9/91_Python_Mini_Projects/tree/main/009_Convert_image_to_ASCII)** | 37 | | 10 | **[010_Perform_Google_Search](https://github.com/milaan9/91_Python_Mini_Projects/tree/main/010_Perform_Google_Search)** | 38 | | 11 | **[011_Generate_QR_Code](https://github.com/milaan9/91_Python_Mini_Projects/tree/main/011_Generate_QR_Code)** | 39 | | 12 | **[012_Encode_CAPTCHA](https://github.com/milaan9/91_Python_Mini_Projects/tree/main/012_Encode_CAPTCHA)** | 40 | | 13 | **[013_Unzip_File](https://github.com/milaan9/91_Python_Mini_Projects/tree/main/013_Unzip_File)** | 41 | | 14 | **[014_Run_JavaScript_in_Python](https://github.com/milaan9/91_Python_Mini_Projects/tree/main/014_Run_JavaScript_in_Python)** | 42 | | 15 | **[015_Web_Scraping_Covid-19_Data](https://github.com/milaan9/91_Python_Mini_Projects/tree/main/015_Web_Scraping_Covid-19_Data)** | 43 | | 16 | **[016_Web_Scraping_CoWin_Vaccine_Slots](https://github.com/milaan9/91_Python_Mini_Projects/tree/main/016_Web_Scraping_CoWin_Vaccine_Slots)** | 44 | | 17 | **[017_Check_Weather_Forecast_with_GUI](https://github.com/milaan9/91_Python_Mini_Projects/tree/main/017_Check_Weather_Forecast_with_GUI)** | 45 | | 18 | **[018_Draw_Sakura_Tree](https://github.com/milaan9/91_Python_Mini_Projects/tree/main/018_Draw_Sakura_Tree)** | 46 | | 19 | **[019_Plagiarism_Checker](https://github.com/milaan9/91_Python_Mini_Projects/tree/main/019_Plagiarism_Checker)** | 47 | | 20 | **[020_Road_Detection](https://github.com/milaan9/91_Python_Mini_Projects/tree/main/020_Road_Detection)** | 48 | 49 | These are **read-only** versions. However you can **`Run ▶`** all the codes **online** by clicking here ➞ binder 50 | 020_Road_Detection 51 | --- 52 | 53 | ## Frequently asked questions ❔ 54 | 55 | ### How can I thank you for writing and sharing this tutorial? 🌷 56 | 57 | You can Star Badge and Fork Badge Starring and Forking is free for you, but it tells me and other people that it was helpful and you like this tutorial. 58 | 59 | Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) if you aren't here already and click ➞ **`✰ Star`** and **`ⵖ Fork`** button in the top right corner. You will be asked to create a GitHub account if you don't already have one. 60 | 61 | --- 62 | 63 | ### How can I read this tutorial without an Internet connection? GIF 64 | 65 | 1. Go [**`here`**](https://github.com/milaan9/91_Python_Mini_Projects) and click the big green ➞ **`Code`** button in the top right of the page, then click ➞ [**`Download ZIP`**](https://github.com/milaan9/91_Python_Mini_Projects/archive/refs/heads/main.zip). 66 | 67 | ![Download ZIP](img/dnld_rep.png) 68 | 69 | 2. Extract the ZIP and open it. Unfortunately I don't have any more specific instructions because how exactly this is done depends on which operating system you run. 70 | 71 | 3. Launch ipython notebook from the folder which contains the notebooks. Open each one of them 72 | 73 | **`Kernel > Restart & Clear Output`** 74 | 75 | This will clear all the outputs and now you can understand each statement and learn interactively. 76 | 77 | If you have git and you know how to use it, you can also clone the repository instead of downloading a zip and extracting it. An advantage with doing it this way is that you don't need to download the whole tutorial again to get the latest version of it, all you need to do is to pull with git and run ipython notebook again. 78 | 79 | --- 80 | 81 | ## Authors ✍️ 82 | 83 | I'm Dr. Milaan Parmar and I have written this tutorial. If you think you can add/correct/edit and enhance this tutorial you are most welcome🙏 84 | 85 | See [github's contributors page](https://github.com/milaan9/91_Python_Mini_Projects/graphs/contributors) for details. 86 | 87 | If you have trouble with this tutorial please tell me about it by [Create an issue on GitHub](https://github.com/milaan9/91_Python_Mini_Projects/issues/new) PNG and I'll make this tutorial better. This is probably the best choice if you had trouble following the tutorial, and something in it should be explained better. You will be asked to create a GitHub account if you don't already have one. 88 | 89 | If you like this tutorial, please [give it a ⭐ star](https://github.com/milaan9/91_Python_Mini_Projects). 90 | 91 | --- 92 | 93 | ## Licence 📜 94 | 95 | You may use this tutorial freely at your own risk. See [LICENSE](./LICENSE). 96 | -------------------------------------------------------------------------------- /img/dnld_rep.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/milaan9/91_Python_Mini_Projects/6f2d8b7153bd575144a037cfda7ed170c9499c74/img/dnld_rep.png --------------------------------------------------------------------------------