diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5f8ee83..287bece 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -12,7 +12,7 @@ jobs: strategy: matrix: os: [ubuntu-latest] - python-version: ['3.9', '3.10', '3.11', '3.12'] + python-version: ['3.10', '3.11', '3.12'] steps: - uses: actions/checkout@v4 @@ -27,7 +27,7 @@ jobs: - name: Install dependencies run: | - uv sync --all-extras + uv sync --extra dev --extra logging - name: Test imports run: | @@ -41,6 +41,41 @@ jobs: - name: Run tests run: uv run pytest tests/ -v --tb=short + test-with-processing: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - name: Set up Python + uses: actions/setup-python@v4 + with: + python-version: '3.11' + + - name: Install R and development dependencies + run: | + sudo apt-get update + sudo apt-get install -y r-base r-base-dev libtirpc-dev + + - name: Install uv + run: pip install uv + + - name: Install all dependencies including processing + run: | + uv sync --all-extras + + - name: Test processing imports + run: | + uv run python -c " + import neon_tree_classification + from neon_tree_classification import NeonCrownDataset + print('Core imports successful!') + try: + import rpy2 + print('Processing dependencies (rpy2) available!') + except ImportError as e: + print(f'Processing dependencies not available: {e}') + " + lint: runs-on: ubuntu-latest steps: diff --git a/pyproject.toml b/pyproject.toml index 630bdc6..a6c658f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -11,7 +11,7 @@ authors = [ ] license = {text = "MIT"} readme = "README.md" -requires-python = ">=3.9" +requires-python = ">=3.10" keywords = ["neon", "tree-species", "classification", "remote-sensing", "hyperspectral", "lidar", "pytorch-lightning"] classifiers = [ "Development Status :: 4 - Beta", @@ -19,7 +19,6 @@ classifiers = [ "License :: OSI Approved :: MIT License", "Operating System :: OS Independent", "Programming Language :: Python :: 3", - "Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.12", @@ -88,7 +87,7 @@ include = ["neon_tree_classification*"] [tool.black] line-length = 88 -target-version = ['py39', 'py310', 'py311', 'py312'] +target-version = ['py310', 'py311', 'py312'] include = '\.pyi?$' extend-exclude = ''' /( @@ -118,7 +117,7 @@ filterwarnings = [ ] [tool.ruff] -target-version = "py39" +target-version = "py310" line-length = 88 select = [ "E", # pycodestyle errors diff --git a/scripts/get_dataloaders.py b/scripts/get_dataloaders.py index 1e0a0c5..9c87aa4 100644 --- a/scripts/get_dataloaders.py +++ b/scripts/get_dataloaders.py @@ -37,9 +37,7 @@ from neon_tree_classification.core.dataset import NeonCrownDataset -DATASET_URL = ( - "https://www.dropbox.com/scl/fi/v49xi6d7wtetctqphebx0/neon_tree_classification_dataset.zip?rlkey=fb7bz6kd0ckip4u0qd5xdor58&st=dvjyd5ry&dl=1" -) +DATASET_URL = "https://www.dropbox.com/scl/fi/v49xi6d7wtetctqphebx0/neon_tree_classification_dataset.zip?rlkey=fb7bz6kd0ckip4u0qd5xdor58&st=dvjyd5ry&dl=1" def _dataset_exists(dataset_dir: Path) -> bool: