diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 2dac3f5..d773348 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -15,12 +15,12 @@ repos: - id: requirements-txt-fixer - id: trailing-whitespace - repo: https://github.com/astral-sh/ruff-pre-commit - rev: v0.1.9 + rev: v0.2.0 hooks: - id: ruff args: [ --config=pyproject.toml ] - repo: https://github.com/psf/black - rev: 23.12.1 + rev: 24.1.1 hooks: - id: black args: [--config=pyproject.toml] diff --git a/bg_atlasgen/atlas_scripts/allen_mouse.py b/bg_atlasgen/atlas_scripts/allen_mouse.py index 1de0f46..8d903bb 100644 --- a/bg_atlasgen/atlas_scripts/allen_mouse.py +++ b/bg_atlasgen/atlas_scripts/allen_mouse.py @@ -30,7 +30,7 @@ def create_atlas(working_dir, resolution): manifest=download_dir_path / "manifest.json", # downloaded files are stored relative to here resolution=resolution, - reference_space_key="annotation/ccf_2017" + reference_space_key="annotation/ccf_2017", # use the latest version of the CCF ) diff --git a/bg_atlasgen/atlas_scripts/example_mouse.py b/bg_atlasgen/atlas_scripts/example_mouse.py index 5f757a0..57fb25d 100644 --- a/bg_atlasgen/atlas_scripts/example_mouse.py +++ b/bg_atlasgen/atlas_scripts/example_mouse.py @@ -30,7 +30,7 @@ def create_atlas(working_dir, resolution): manifest=download_dir_path / "manifest.json", # downloaded files are stored relative to here resolution=RES_UM, - reference_space_key="annotation/ccf_2017" + reference_space_key="annotation/ccf_2017", # use the latest version of the CCF ) diff --git a/bg_atlasgen/atlas_scripts/kim_mouse.py b/bg_atlasgen/atlas_scripts/kim_mouse.py index 63e78bb..569a103 100644 --- a/bg_atlasgen/atlas_scripts/kim_mouse.py +++ b/bg_atlasgen/atlas_scripts/kim_mouse.py @@ -72,7 +72,7 @@ def create_atlas(working_dir, resolution): manifest=download_dir_path / "manifest.json", # downloaded files are stored relative to here resolution=resolution, - reference_space_key="annotation/ccf_2017" + reference_space_key="annotation/ccf_2017", # use the latest version of the CCF ) diff --git a/bg_atlasgen/atlas_scripts/osten_mouse.py b/bg_atlasgen/atlas_scripts/osten_mouse.py index bd9e97a..1079fd7 100644 --- a/bg_atlasgen/atlas_scripts/osten_mouse.py +++ b/bg_atlasgen/atlas_scripts/osten_mouse.py @@ -69,7 +69,7 @@ def create_atlas(working_dir, resolution): manifest=download_dir_path / "manifest.json", # downloaded files are stored relative to here resolution=resolution, - reference_space_key="annotation/ccf_2017" + reference_space_key="annotation/ccf_2017", # use the latest version of the CCF ) diff --git a/bg_atlasgen/metadata_utils.py b/bg_atlasgen/metadata_utils.py index f6c985f..57b125c 100644 --- a/bg_atlasgen/metadata_utils.py +++ b/bg_atlasgen/metadata_utils.py @@ -3,6 +3,7 @@ . structures.csv . README.txt """ + import json import re from datetime import datetime diff --git a/bg_atlasgen/validate_atlases.py b/bg_atlasgen/validate_atlases.py index 503883f..d993c5c 100644 --- a/bg_atlasgen/validate_atlases.py +++ b/bg_atlasgen/validate_atlases.py @@ -1,6 +1,5 @@ """Script to validate atlases""" - import os from pathlib import Path diff --git a/bg_atlasgen/volume_utils.py b/bg_atlasgen/volume_utils.py index d2e2234..a00c04e 100644 --- a/bg_atlasgen/volume_utils.py +++ b/bg_atlasgen/volume_utils.py @@ -2,6 +2,7 @@ Code useful for dealing with volumetric data (e.g. allen annotation volume for the mouse atlas) extracting surfaces from volumetric data .... """ + try: from vedo import Volume except ModuleNotFoundError: