This guide will help you set up your development environment to run the EOPF 101 notebooks and interact with Sentinel data in Zarr format.
- Python 3.9 or higher
- Git
- pip (Python package installer)
- Clone the repository:
git clone https://github.com/eopf-toolkit/eopf-101
cd eopf-101- Run the setup script:
./setup.shThis script will:
- Check Python version requirements
- Create and activate a virtual environment
- Install all dependencies
- Set up Jupyter kernel
- Verify the installation
- Clone the repository:
git clone https://github.com/eopf-toolkit/eopf-101
cd eopf-101- Create and activate a Python virtual environment:
python -m venv .venv
# On Linux/macOS:
source .venv/bin/activate
# On Windows:
.venv\Scripts\activate- Install the required dependencies:
python -m pip install --upgrade pip
pip install -e .Create a pyproject.toml file in your project root with the following content:
[project]
name = "eopf-101"
version = "0.1.0"
description = "EOPF 101 - A toolkit for working with Sentinel data in Zarr format"
requires-python = ">=3.9"
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[tool.pytest.ini_options]
addopts = "-ra -q"
testpaths = ["tests"]
[project.dependencies]
jupyter = "^1.0.0"
zarr = "^2.14.2"
pystac = "^1.7.3"
numpy = "^1.24.3"
pandas = "^2.0.2"
matplotlib = "^3.7.1"
rioxarray = "^0.14.1"
stackstac = "^0.4.4"
ipykernel = "^6.23.1"Create a requirements.txt file with the following content:
jupyter>=1.0.0
zarr>=2.14.2
pystac>=1.7.3
numpy>=1.24.3
pandas>=2.0.2
matplotlib>=3.7.1
rioxarray>=0.14.1
stackstac>=0.4.4
ipykernel>=6.23.1
quarto>=0.1.0- After installing dependencies, register the Python kernel for Jupyter:
python -m ipykernel install --user --name=eopf101- Start Jupyter:
jupyter notebookSince this project uses Quarto for documentation:
- Install Quarto from: https://quarto.org/docs/get-started/
- Preview the documentation:
quarto previewTo verify your setup:
- Ensure your virtual environment is activated
- Run the following Python commands:
import zarr
import pystac
import rioxarray
import stackstac
print("Environment setup successful!")If you encounter issues:
- Ensure your Python version is correct:
python --version- Verify virtual environment activation:
# You should see (.venv) at the start of your prompt- Check installed packages:
pip listIf you need assistance:
- Open an issue on our GitHub repository
- Check our documentation at https://github.com/eopf-toolkit/eopf-101
- Refer to the README.md for project overview