|
1 | 1 | # 🔢 NumPy Workshop |
2 | | -An in-depth guide to mastering NumPy, covering fundamental to advanced array operations for data science and numerical computing. |
| 2 | + |
| 3 | +[](https://github.com/mr-pylin/numpy-workshop/blob/main/LICENSE) |
| 4 | +[](https://www.python.org/downloads/release/python-3123/) |
| 5 | +[](https://app.codacy.com/gh/mr-pylin/numpy-workshop/dashboard?utm_source=gh&utm_medium=referral&utm_content=&utm_campaign=Badge_grade) |
| 6 | +[](https://github.com/psf/black) |
| 7 | + |
| 8 | + |
| 9 | +[](https://github.com/mr-pylin/numpy-workshop/pulls) |
| 10 | + |
| 11 | +An in-depth guide to mastering **NumPy**, covering fundamental to advanced array operations for **data science** and **numerical computing**. |
3 | 12 |
|
4 | 13 | ## 📖 Table of Contents |
5 | | -1. [**Array Basics**](./codes/01_array-basics.ipynb) |
| 14 | + |
| 15 | +### 📖 Main Notebooks |
| 16 | + |
| 17 | +1. [**Array Basics**](./codes/01-array-basics.ipynb) |
6 | 18 | Introduction to NumPy arrays |
7 | | -1. [**Arithmetic Operations**](./codes/02_arithmetic-operations.ipynb) |
| 19 | +1. [**Arithmetic Operations**](./codes/02-arithmetic-operations.ipynb) |
8 | 20 | Arithmetic operations between (array & scalar) or (array & array) |
9 | | -1. [**Comparative Operations**](./codes/03_comparative-operations.ipynb) |
| 21 | +1. [**Comparative Operations**](./codes/03-comparative-operations.ipynb) |
10 | 22 | Comparative operations between (array & scalar) or (array & array) |
11 | | -1. [**Index & Slice**](./codes/04_index-&-slice.ipynb) |
| 23 | +1. [**Index & Slice**](./codes/04-index-&-slice.ipynb) |
12 | 24 | Basic and advanced indexing and slicing arrays including Mask & Filters |
13 | | -1. [**Axes**](./codes/05_axes.ipynb) |
| 25 | +1. [**Axes**](./codes/05-axes.ipynb) |
14 | 26 | Understanding use of axes in multi-dimensional arrays combined with methods [the hardest part in NumPy for newbies in my opinion] |
15 | | -1. [**Array Manipulations**](./codes/06_array-manipulations.ipynb) |
| 27 | +1. [**Array Manipulations**](./codes/06-array-manipulations.ipynb) |
16 | 28 | Techniques for updating values, appending, inserting, reshaping, concatenating, ... |
17 | | -1. [**NdArray properties & methods**](./codes/07_ndarray-members.ipynb) |
| 29 | +1. [**NdArray properties & methods**](./codes/07-ndarray-members.ipynb) |
18 | 30 | Comprehensive overview of properties and methods associated with NumPy arrays. |
19 | | -1. [**Array Creation**](./codes/08_array-creation.ipynb) |
| 31 | +1. [**Array Creation**](./codes/08-array-creation.ipynb) |
20 | 32 | Various methods to create NumPy arrays (e.g., `numpy.array`, `numpy.zeros`, etc.). |
21 | | -1. [**Mathematics**](./codes/09_mathematics.ipynb) |
| 33 | +1. [**Mathematics**](./codes/09-mathematics.ipynb) |
22 | 34 | Mathematical functions and operations available in NumPy |
23 | | -1. [**Statistics**](./codes/10_statistics.ipynb) |
| 35 | +1. [**Statistics**](./codes/10-statistics.ipynb) |
24 | 36 | Statistical functions for data analysis (mean, median, variance, etc.). |
25 | | -1. [**Sort, Search & Count**](./codes/11_sort-search-count.ipynb) |
| 37 | +1. [**Sort, Search & Count**](./codes/11-sort-search-count.ipynb) |
26 | 38 | Methods for sorting, searching, and counting elements in arrays. |
27 | | -1. [**Logic**](./codes/12_logic.ipynb) |
| 39 | +1. [**Logic**](./codes/12-logic.ipynb) |
28 | 40 | Logical operations and boolean indexing with NumPy arrays. |
29 | | -1. [**Set**](./codes/13_set.ipynb) |
| 41 | +1. [**Set**](./codes/13-set.ipynb) |
30 | 42 | Set operations for array elements (union, intersection, difference). |
31 | | -1. [**Linear Algebra**](./codes/14_linear-algebra.ipynb) |
| 43 | +1. [**Linear Algebra**](./codes/14-linear-algebra.ipynb) |
32 | 44 | Fundamental linear algebra operations using NumPy (matrix multiplication, determinants). |
33 | | -1. [**Structured Array**](./codes/15_structured-array.ipynb) |
| 45 | +1. [**Structured Array**](./codes/15-structured-array.ipynb) |
34 | 46 | Creating and manipulating structured arrays with custom data types. |
35 | | -1. [**Input/Output**](./codes/16_input-output.ipynb) |
| 47 | +1. [**Input/Output**](./codes/16-input-output.ipynb) |
36 | 48 | Techniques for reading from and writing to files using NumPy. |
37 | | -1. [**Random Generator**](./codes/17_random-generator.ipynb) |
| 49 | +1. [**Random Generator**](./codes/17-random-generator.ipynb) |
38 | 50 | Generating random numbers and distributions with NumPy's random module. |
39 | | -1. [**Fourier Transform**](./codes/18_fourier-transform.ipynb) |
| 51 | +1. [**Fourier Transform**](./codes/18-fourier-transform.ipynb) |
40 | 52 | Understanding and applying Fourier transforms in NumPy. |
41 | | -1. [**Efficient Computing**](./codes/19_efficient-computing.ipynb) |
| 53 | +1. [**Efficient Computing**](./codes/19-efficient-computing.ipynb) |
42 | 54 | Strategies for optimizing performance and memory usage in NumPy operations. |
43 | | -1. [**Miscellaneous**](./codes/20_miscellaneous.ipynb) |
| 55 | +1. [**Miscellaneous**](./codes/20-miscellaneous.ipynb) |
44 | 56 | Additional topics and advanced features in NumPy. |
45 | | -1. [**Looking Ahead**](./codes/21_looking-ahead.ipynb) |
| 57 | +1. [**Looking Ahead**](./codes/21-looking-ahead.ipynb) |
46 | 58 | Introduction to *Pandas* for data manipulation and *Matplotlib* for data visualization. |
47 | 59 |
|
48 | 60 | ## 📋 Prerequisites |
49 | | - - **Programming Fundamentals** |
50 | | - - Proficiency in Python (data types, control structures, functions, etc.). |
51 | | - - My Python Workshop: [github.com/mr-pylin/python-workshop](https://github.com/mr-pylin/python-workshop) |
52 | | - - **Mathematics for Machine Learning** |
53 | | - - Linear Algebra: Vectors, matrices, matrix operations. |
54 | | - - [*Linear Algebra Review and Reference*](https://www.cs.cmu.edu/%7Ezkolter/course/linalg/linalg_notes.pdf) written by [Zico Kolter](https://zicokolter.com) |
55 | | - - [*Notes on Linear Algebra*](https://webspace.maths.qmul.ac.uk/p.j.cameron/notes/linalg.pdf) written by [Peter J. Cameron](https://cameroncounts.github.io/web) |
56 | | - - [*MATH 233 - Linear Algebra I Lecture Notes*](https://www.geneseo.edu/~aguilar/public/assets/courses/233/main_notes.pdf) written by [Cesar O. Aguilar](https://www.geneseo.edu/~aguilar/) |
57 | | - - Probability & Statistics: Probability distributions, mean/variance, etc. |
58 | | - - [*MATH1024: Introduction to Probability and Statistics*](https://www.sujitsahu.com/teach/2020_math1024.pdf) written by [Sujit Sahu](https://www.southampton.ac.uk/people/5wynjr/professor-sujit-sahu) |
59 | | - |
60 | | -# ⚙️ Setup |
61 | | -This project was developed using Python `v3.12.3`. If you encounter issues running the specified version of dependencies, consider using this specific Python version. |
62 | | - |
63 | | -## 📦 Installing Dependencies |
64 | | -You can install all dependencies listed in `requirements.txt` using [pip](https://pip.pypa.io/en/stable/installation/). |
| 61 | + |
| 62 | +- 👨💻 **Programming Fundamentals** |
| 63 | + - Proficiency in **Python** (data types, control structures, functions, classes, etc.). |
| 64 | + - My Python Workshop: [github.com/mr-pylin/python-workshop](https://github.com/mr-pylin/python-workshop) |
| 65 | +- 🔣 **Mathematics for Machine Learning** |
| 66 | + - 🔲 **Linear Algebra**: Vectors, matrices, matrix operations. |
| 67 | + - [**Linear Algebra Review and Reference**](https://www.cs.cmu.edu/%7Ezkolter/course/linalg/linalg_notes.pdf) written by [*Zico Kolter*](https://zicokolter.com). |
| 68 | + - [**Notes on Linear Algebra**](https://webspace.maths.qmul.ac.uk/p.j.cameron/notes/linalg.pdf) written by [*Peter J. Cameron*](https://cameroncounts.github.io/web). |
| 69 | + - [**MATH 233 - Linear Algebra I Lecture Notes**](https://www.geneseo.edu/~aguilar/public/assets/courses/233/main_notes.pdf) written by [*Cesar O. Aguilar*](https://www.geneseo.edu/~aguilar/). |
| 70 | + - 🎲 **Probability & Statistics**: Probability distributions, mean/variance, etc. |
| 71 | + - [**MATH1024: Introduction to Probability and Statistics**](https://www.sujitsahu.com/teach/2020_math1024.pdf) written by [*Sujit Sahu*](https://www.southampton.ac.uk/people/5wynjr/professor-sujit-sahu). |
| 72 | + |
| 73 | +## ⚙️ Setup |
| 74 | + |
| 75 | +This project was developed using Python **v3.12.3**. If you encounter issues running the specified version of dependencies, consider using this specific Python version. |
| 76 | + |
| 77 | +### 📝 List of Dependencies |
| 78 | + |
| 79 | +Installing **matplotlib** and **pandas** is **OPTIONAL**. They are used exclusively in the [**Looking Ahead Notebook**](./codes/21-looking-ahead.ipynb) to show an application of using them. |
| 80 | + |
| 81 | +[](https://pypi.org/project/numpy/2.1.3/) |
| 82 | +[](https://pypi.org/project/matplotlib/3.9.1/) |
| 83 | +[](https://pypi.org/project/pandas/2.2.2/) |
| 84 | + |
| 85 | +### 📦 Installing Dependencies |
| 86 | + |
| 87 | +You can install all dependencies listed in [**requirements.txt**](./requirements.txt) using [**pip**](https://pip.pypa.io/en/stable/installation/): |
| 88 | + |
65 | 89 | ```bash |
66 | 90 | pip install -r requirements.txt |
67 | 91 | ``` |
68 | 92 |
|
69 | | -## 🛠️ Usage Instructions |
70 | | - - Open the root folder with [VS Code](https://code.visualstudio.com/) |
71 | | - - **Windows/Linux**: `Ctrl + K` followed by `Ctrl + O` |
72 | | - - **macOS**: `Cmd + K` followed by `Cmd + O` |
73 | | - - Open `.ipynb` files using [Jupyter extension](https://marketplace.visualstudio.com/items?itemName=ms-toolsai.jupyter) integrated with **VS Code** |
74 | | - - Allow **VS Code** to install any recommended dependencies for working with Jupyter Notebooks. |
75 | | - - Note: Jupyter is integrated with both **VS Code** & **[Google Colab](https://colab.research.google.com/)** |
76 | | - |
77 | | -# 🔗 Useful Links |
78 | | - - **NumPy Website**: |
79 | | - - The official website for NumPy, providing information, tutorials, and resources for the NumPy library |
80 | | - - Official site: [numpy.org](https://numpy.org/) |
81 | | - - **NumPy Documentation**: |
82 | | - - Comprehensive guide and reference for all functionalities and features of the NumPy library |
83 | | - - Doc: [numpy.org/doc](https://numpy.org/doc/) |
84 | | - - **NumPy Source Code**: |
85 | | - - Over 1500 contributors are currently working on NumPy. |
86 | | - - Link: [github.com/numpy/numpy](https://github.com/numpy/numpy) |
87 | | - - **Looking Ahead**: |
88 | | - - **Pandas** |
89 | | - - A powerful, open-source data analysis and manipulation library built on top of NumPy for Python |
90 | | - - Official site: [pandas.pydata.org](https://pandas.pydata.org/) |
91 | | - - My Pandas Workshop: [Coming Soon](https://github.com/mr-pylin/#) |
92 | | - - **MatPlotLib** |
93 | | - - A comprehensive library for creating static, animated, and interactive visualizations in Python |
94 | | - - Official site: [matplotlib.org](https://matplotlib.org/) |
95 | | - - My MatPlotLib Workshop: [Coming Soon](https://github.com/mr-pylin/#) |
96 | | - - **PyTorch** |
97 | | - - An open-source machine learning library for Python developed by [Meta AI](https://ai.meta.com/), used for applications such as deep learning and neural networks. |
98 | | - - Official site: [pytorch.org](https://pytorch.org/) |
99 | | - - My PyTorch Workshop: [github.com/mr-pylin/pytorch-workshop](https://github.com/mr-pylin/pytorch-workshop) |
100 | | - |
101 | | -# 🔍 Find Me |
| 93 | +### 🛠️ Usage Instructions |
| 94 | + |
| 95 | +1. Open the root folder with [**VS Code**](https://code.visualstudio.com/): |
| 96 | + - **Windows/Linux**: `Ctrl + K` followed by `Ctrl + O` |
| 97 | + - **macOS**: `Cmd + K` followed by `Cmd + O` |
| 98 | +1. Open `.ipynb` files using [**Jupyter extension**](https://marketplace.visualstudio.com/items?itemName=ms-toolsai.jupyter) integrated with **VS Code**. |
| 99 | +1. Allow **VS Code** to install any **recommended dependencies** for working with Jupyter Notebooks. |
| 100 | + |
| 101 | +✍️ **Notes**: |
| 102 | + |
| 103 | +- The **table of contents** embedded in the **notebooks** is not fully functional on **GitHub**! |
| 104 | +- To navigate the **table of contents** effectively, open the notebooks **locally** or view them via [**nbviewer**](https://nbviewer.org/github/mr-pylin/pytorch-workshop) for a better experience. |
| 105 | + |
| 106 | +## 🔗 Useful Links |
| 107 | + |
| 108 | +### **NumPy** |
| 109 | + |
| 110 | +- Official Website: |
| 111 | + - The official website for NumPy, providing information, tutorials, and resources for the NumPy library |
| 112 | + - Official site: [numpy.org](https://numpy.org/) |
| 113 | +- Documentation |
| 114 | + - Comprehensive guide and reference for all functionalities and features of the NumPy library |
| 115 | + - Doc: [numpy.org/doc](https://numpy.org/doc/) |
| 116 | +- Source Code |
| 117 | + - Over 1500 contributors are currently working on NumPy. |
| 118 | + - Link: [github.com/numpy/numpy](https://github.com/numpy/numpy) |
| 119 | + |
| 120 | +### **Looking Ahead** |
| 121 | + |
| 122 | +- **Pandas** |
| 123 | + - A powerful, open-source data analysis and manipulation library built on top of NumPy for Python |
| 124 | + - Official site: [pandas.pydata.org](https://pandas.pydata.org/) |
| 125 | + - My Pandas Workshop: [Coming Soon](https://github.com/mr-pylin/#) |
| 126 | +- **Data Visualization** |
| 127 | + - A comprehensive collection of Python libraries for creating static, animated, and interactive visualizations: **Matplotlib**, **Seaborn**, and **Plotly**. |
| 128 | + - Official sites: [matplotlib.org](https://matplotlib.org/) | [seaborn.pydata.org](https://seaborn.pydata.org/) | [plotly.com](https://plotly.com/) |
| 129 | + - My MatPlotLib Workshop: [github.com/mr-pylin/data-visualization-workshop](https://github.com/mr-pylin/data-visualization-workshop) |
| 130 | +- **PyTorch** |
| 131 | + - An open-source **machine learning** library for Python developed by [**Meta AI**](https://ai.meta.com/), used for applications such as **deep learning** and **neural networks**. |
| 132 | + - Official site: [pytorch.org](https://pytorch.org/) |
| 133 | + - My PyTorch Workshop: [github.com/mr-pylin/pytorch-workshop](https://github.com/mr-pylin/pytorch-workshop) |
| 134 | + |
| 135 | +## 🔍 Find Me |
| 136 | + |
102 | 137 | Any mistakes, suggestions, or contributions? Feel free to reach out to me at: |
103 | | - - 📍[linktr.ee/mr_pylin](https://linktr.ee/mr_pylin) |
104 | | - |
| 138 | + |
| 139 | +- 📍[**linktr.ee/mr_pylin**](https://linktr.ee/mr_pylin) |
| 140 | + |
105 | 141 | I look forward to connecting with you! 🏃♂️ |
106 | 142 |
|
107 | | -# 📄 License |
| 143 | +## 📄 License |
| 144 | + |
108 | 145 | This project is licensed under the **[Apache License 2.0](./LICENSE)**. |
109 | | -You are free to use, modify, and distribute this code, but you must include copies of both the [**LICENSE**](./LICENSE) and [**NOTICE**](./NOTICE) files in any distribution of your work. |
| 146 | +You are free to **use**, **modify**, and **distribute** this code, but you **must** include copies of both the [**LICENSE**](./LICENSE) and [**NOTICE**](./NOTICE) files in any distribution of your work. |
0 commit comments