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

Expose check_latest in the atlas constructor #396

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
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
5 changes: 3 additions & 2 deletions brainrender/atlas.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,14 @@


class Atlas(BrainGlobeAtlas):
def __init__(self, atlas_name=None):
def __init__(self, atlas_name=None, check_latest=True):
"""
Brainrender's Atlas class subclasses BrainGlobeAtlas
to add methods to get regions meshes as Actors
and to get a plane at a given point and normal.

:param atlas_name: str, atlas name from brainglobe's atlas API atlases
:param check_latest: bool, if True checks that the atlas is the latest version
"""
atlas_name = atlas_name or settings.DEFAULT_ATLAS
self.atlas_name = atlas_name
Expand All @@ -26,7 +27,7 @@ def __init__(self, atlas_name=None):
super().__init__(atlas_name=atlas_name, print_authors=False)
except TypeError:
# The latest version of BGatlas has no print_authors argument
super().__init__(atlas_name=atlas_name)
super().__init__(atlas_name=atlas_name, check_latest=check_latest)

@property
def zoom(self):
Expand Down
Loading