Skip to content

Commit

Permalink
Skip test subjects in job creator; resolves int-brain-lab/iblscripts#104
Browse files Browse the repository at this point in the history
  • Loading branch information
k1o0 committed Nov 14, 2024
1 parent f7aecdb commit d2a3218
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion ibllib/pipes/local_server.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@
from one.api import ONE
from one.webclient import AlyxClient
from one.remote.globus import get_lab_from_endpoint_id, get_local_endpoint_id
from one.alf.spec import is_session_path
from one.alf.path import session_path_parts

from ibllib import __version__ as ibllib_version
from ibllib.pipes import tasks
Expand Down Expand Up @@ -104,11 +106,15 @@ def job_creator(root_path, one=None, dry=False, rerun=False):
if not one:
one = ONE(cache_rest=None)
rc = IBLRegistrationClient(one=one)
flag_files = list(Path(root_path).glob('**/raw_session.flag'))
flag_files = Path(root_path).glob('*/????-??-??/*/raw_session.flag')
flag_files = filter(lambda x: is_session_path(x.parent), flag_files)
pipes = []
all_datasets = []
for flag_file in flag_files:
session_path = flag_file.parent
if session_path_parts(session_path)[1] in ('test', 'test_subject'):
_logger.debug('skipping test session %s', session_path)
continue
_logger.info(f'creating session for {session_path}')
if dry:
continue
Expand Down

0 comments on commit d2a3218

Please sign in to comment.