An in-depth guide to mastering NumPy, covering fundamental to advanced array operations for data science and numerical computing.
- Introduction to Arrays
- Element-Wise Operators
- Index & Slice
- Axes
- Array Manipulations
- NdArray properties & methods
- Array Creation
- Mathematics
- Statistics
- Sort, Search & Count
- Logic
- Set
- Linear Algebra
- Structured Array
- Input/Output
- Random Generator
- Fourier Transform
- Efficient Computing
- Miscellaneous
- Looking Ahead
Note
The mathematics requirements below are not mandatory but will significantly deepen your understanding of tensor concepts.
- π¨βπ» Programming Fundamentals
- π Proficiency in Python (data types, control structures, functions, classes, etc.).
- My Python Workshop: github.com/mr-pylin/python-workshop
- π Proficiency in Python (data types, control structures, functions, classes, etc.).
- π£ Mathematics for Machine Learning
- π² Linear Algebra: Vectors, matrices, matrix operations.
- Linear Algebra Review and Reference written by Zico Kolter.
- Notes on Linear Algebra written by Peter J. Cameron.
- MATH 233 - Linear Algebra I Lecture Notes written by Cesar O. Aguilar.
- π² Probability & Statistics: Probability distributions, mean/variance, etc.
- π² Linear Algebra: Vectors, matrices, matrix operations.
Important
This project requires Python v3.10 or higher. For optimal compatibility and to avoid potential issues with dependencies, it is strongly advised that you use the Python version specified in the .python-version file.
Installing matplotlib and pandas is OPTIONAL. They are used exclusively in the Looking Ahead Notebook to show an application of using them.
-
Use uv for dependency management. It handles dependencies, virtual environments, and locking versions more efficiently than pip.
-
To install exact dependency versions specified in uv.lock for consistent environments without installing the current project as a package:
uv sync --no-install-project # Install only numpy uv sync --no-install-project --extra full # Install numpy + optional dependencies
-
Install all dependencies listed in requirements.txt using pip:
pip install -r requirements.txt
Warning
The requirements.txt includes full installation of dependencies. Comment matplotlib and pandas in order to install only numpy.
Caution
Pip does not lock dependency versions as strictly as uv. You may encounter version conflicts or reproducibility issues. Only use this method if you know what you are doing.
- Open the root folder with VS Code (
Ctrl/Cmd + Kfollowed byCtrl/Cmd + O). - Open
.ipynbfiles using the Jupyter extension integrated with VS Code. - Select the correct Python kernel and virtual environment where the dependencies were installed.
- Allow VS Code to install any recommended dependencies for working with Jupyter Notebooks.
Note
- Stick with the exact dependency versions specified in uv.lock or requirements.txt. The repository has been tested with these versions to ensure compatibility and stability.
- This repository is actively maintained, and dependencies are updated regularly to the latest stable versions.
- The table of contents embedded within notebooks (
.ipynbfiles) may not function correctly on GitHub. - For an improved experience, open the notebooks locally or view them via nbviewer, rather than directly on GitHub.
- Official Website:
- The official website for NumPy, providing information, tutorials, and resources for the NumPy library
- Official site: numpy.org
- Documentation
- Comprehensive guide and reference for all functionalities and features of the NumPy library
- Doc: numpy.org/doc
- Source Code
- Over 1500 contributors are currently working on NumPy.
- Link: github.com/numpy/numpy
- Pandas
- A powerful, open-source data analysis and manipulation library built on top of NumPy for Python
- Official site: pandas.pydata.org
- My Pandas Workshop: github.com/mr-pylin/pandas-workshop
- Data Visualization
- A comprehensive collection of Python libraries for creating static, animated, and interactive visualizations: Matplotlib, Seaborn, and Plotly.
- Official sites: matplotlib.org | seaborn.pydata.org | plotly.com
- My MatPlotLib Workshop: github.com/mr-pylin/data-visualization-workshop
- PyTorch
- An open-source machine learning library for Python developed by Meta AI, used for applications such as deep learning and neural networks.
- Official site: pytorch.org
- My PyTorch Workshop: github.com/mr-pylin/pytorch-workshop
- Image Processing
- A comprehensive resource to explore image processing, from fundamental concepts to advanced techniques.
- Official sites: opencv.org | scikit-image.org | pillow.readthedocs.io | scipy.org
- My Image Processing Workshop: github.com/mr-pylin/image-processing-workshop
Found an issue, have a suggestion, or wish to contribute? Your input is highly valued.
- π All links: linktr.ee/mr_pylin
- π¬ Telegram Group: @python_topics
- π§ Email: amirhosseinheydari78@gmail.com
I look forward to connecting with you! πββοΈ
This project's code is licensed under the Apache License 2.0. This license grants you the freedom to use, modify, and distribute the code. However, any distribution of the code must include copies of both the LICENSE and NOTICE files.
- The images located in the assets/images/numpy/ folder are sourced from the NumPy press kit / website resources and are licensed under the BSD 3-Clause License.