Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

new atlas file added - for cat #403

Draft
wants to merge 26 commits into
base: main
Choose a base branch
from
Draft
Changes from 1 commit
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
f3cf15e
new atlas file added - for cat
HenryCrosswell Sep 3, 2024
56cb6f5
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Sep 3, 2024
101bfcb
included relevant metadata - root_id is 999 as labels are a non struc…
HenryCrosswell Sep 8, 2024
206dcde
Merge branch 'catlas' of github.com:HenryCrosswell/brainglobe-atlasap…
HenryCrosswell Sep 8, 2024
c18a8db
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Sep 8, 2024
84e94f6
formatted for black
HenryCrosswell Sep 8, 2024
e99be8f
fixed precommit issues
HenryCrosswell Sep 8, 2024
2a76b3f
Merge branch 'brainglobe:main' into catlas
HenryCrosswell Sep 8, 2024
724531a
modified for precommit
HenryCrosswell Sep 8, 2024
39f0636
Merge branch 'catlas' of github.com:HenryCrosswell/brainglobe-atlasap…
HenryCrosswell Sep 8, 2024
b95d514
loaded raw data instead of url, loaded niftis into template and ref
HenryCrosswell Sep 8, 2024
43307a0
changed reference and template slice index
HenryCrosswell Sep 8, 2024
04173fe
testing csv and text files for discrepancys before proceeding
HenryCrosswell Sep 9, 2024
ebcb38d
changed for pre-commit formatting purposes
HenryCrosswell Sep 18, 2024
f8f74af
changed from structure, r,g,b to rgba, adding another function to acc…
HenryCrosswell Sep 18, 2024
72330bc
edited function to create and add structure id, as well as adding a f…
HenryCrosswell Sep 20, 2024
e4c8df0
changed df into a dicitonary list to work with the helper functions …
HenryCrosswell Sep 28, 2024
b2dbf7d
added the ability to make meshes, however it fails for about 10 ids, …
HenryCrosswell Sep 28, 2024
45a4d6c
created new function to take mesh from vtk files - uses a lot of temp…
HenryCrosswell Sep 28, 2024
9d2ccc0
remove unecessary mesh function
HenryCrosswell Sep 28, 2024
5491243
edited structure id to work with wrapper function, removed unecessary…
HenryCrosswell Sep 29, 2024
1b5f08f
changed download resources to obtain annotations instead of relying o…
HenryCrosswell Oct 2, 2024
9e14c46
hardcoded my csv of fullnames, mostly for testing and help on the cod…
HenryCrosswell Oct 11, 2024
0c0b4a1
downscaled reference image and added a root for the mask, tidied up s…
HenryCrosswell Nov 22, 2024
ede19b5
updated download functions to properly use pooch hashes, when availab…
HenryCrosswell Dec 5, 2024
7ec0885
made sure the functionality behind the hash_json worked
HenryCrosswell Dec 5, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
included relevant metadata - root_id is 999 as labels are a non struc…
…tured list
  • Loading branch information
HenryCrosswell committed Sep 8, 2024
commit 101bfcb557e04cb0ca8b545ba20140cfbaa03afa
35 changes: 23 additions & 12 deletions brainglobe_atlasapi/atlas_generation/atlas_scripts/catlas.py
Original file line number Diff line number Diff line change
@@ -1,22 +1,30 @@
from brainglobe_atlasapi.atlas_generation.wrapup import wrapup_atlas_from_data
from pathlib import Path
import pooch

###Metadata
__version__ = 1 # The version of the atlas in the brainglobe_atlasapi, this is internal, if this is the first time this atlas has been added the value should be 1
ATLAS_NAME = None # The expected format is FirstAuthor_SpeciesCommonName, ie; kleven_rat
CITATION = None # DOI of the most relevant citable document
SPECIES = None # The scientific name of the species, ie; Rattus norvegicus
ATLAS_LINK = None # The URL for the data files
ORIENTATION = None # The orientation of the atlas, for more information on how to determine this click here: ........
ROOT_ID = None # The id of the highest level of the atlas. This is commonly called root or brain. Include some information on what to do if your atlas is not hierarchical
RESOLUTION = None # the resolution of your volume in microns. details on how to format this parameter for non isotropic datasets or datasets with multiple resolutions.
__version__ = 1
ATLAS_NAME = "catlas"
CITATION = "https://doi.org/10.1002/cne.24271"
SPECIES = "Felis catus"
ATLAS_LINK = "https://github.com/CerebralSystemsLab/CATLAS"
ORIENTATION = "lps"
ROOT_ID = 999 # Placeholder as no hierarchy is present
RESOLUTION = 500 # um
ATLAS_PACKAGER = 'Henry Crosswell'


def download_resources():


"""
Download the necessary resources for the atlas.

If possible, please use the Pooch library to retrieve any resources.
"""



pass


Expand All @@ -25,7 +33,8 @@ def retrieve_template_and_reference():
Retrieve the desired template and reference as two numpy arrays.

Returns:
tuple: A tuple containing two numpy arrays. The first array is the template volume, and the second array is the reference volume.
tuple: A tuple containing two numpy arrays. The first array is the template volume,
and the second array is the reference volume.
"""
template = None
reference = None
Expand All @@ -36,13 +45,15 @@ def retrieve_hemisphere_map():
"""
Retrieve a hemisphere map for the atlas.

If your atlas is asymmetrical, you may want to use a hemisphere map. This is an array in the same shape as your template,
If your atlas is asymmetrical, you may want to use a hemisphere map.
This is an array in the same shape as your template,
with 0's marking the left hemisphere, and 1's marking the right.

If your atlas is symmetrical, ignore this function.

Returns:
numpy.array or None: A numpy array representing the hemisphere map, or None if the atlas is symmetrical.
numpy.array or None: A numpy array representing the hemisphere map,
or None if the atlas is symmetrical.
"""
return None

Expand Down Expand Up @@ -108,4 +119,4 @@ def retrieve_or_construct_meshes():
cleanup_files=False,
compress=True,
scale_meshes=True,
)
)