This is the repository for Getting Started with Python in Robotics. It contains a single notebook covering Python basics up to object-oriented programming (OOP):
The notebook is designed to help you learn Python for robotics applications.
You can install Python using pyenv (recommended) or without it. Follow the instructions below for your operating system.
1. Install pyenv:
- macOS:
brew install pyenv
- Linux:
curl https://pyenv.run | bash - Windows:
Use pyenv-win with the following command:
winget install pyenv-win
2. Install Python
-
Install a specific Python version using
pyenv install:pyenv install 3.x.x
This downloads and compiles the specified Python version.
-
Set the installed version as the global default with
pyenv global:pyenv global 3.x.x
This makes it the default Python version across your system.
3. Verify Installation
- Confirm Python is installed and accessible:
This should display the installed version.
python --version
Additional Pyenv Commands:
pyenv versions- Lists all installed Python versions.pyenv local <version>- Sets a Python version for the current directory.pyenv uninstall <version>- Uninstalls a specified Python version.
1. macOS and Linux:
- Install using your package manager.
- macOS:
brew install python - Ubuntu:
sudo apt install python3 python3-pip
- macOS:
2. Windows:
- Download from the official Python website.
- Ensure "Add Python to PATH" is checked during installation.
3. Verify Installation:
- Check the installed version of Python and Pip:
python --version pip --version
- Clone the repository:
git clone https://github.com/yourusername/Getting-Started-with-Python-in-Robotics.git cd Getting-Started-with-Python-in-Robotics - Install dependencies:
pip install -r requirements.txt
- Launch Jupyter Notebook:
jupyter notebook
Open notebooks/python_basics.ipynb and follow along to learn Python.
If you have any issues, feel free to create an issue in the repository or reach out via GitHub Discussions.
This project is licensed under the GPLv3 License.