MultiTaskBattery 1.4.0__tar.gz → 1.4.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/MultiTaskBattery/__init__.py +1 -1
- {multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/MultiTaskBattery/experiment_block.py +23 -32
- {multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/MultiTaskBattery.egg-info/PKG-INFO +1 -1
- {multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/PKG-INFO +1 -1
- {multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/tests/test_tasks.py +2 -3
- {multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/LICENSE +0 -0
- {multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/MultiTaskBattery/battery.py +0 -0
- {multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/MultiTaskBattery/fetch.py +0 -0
- {multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/MultiTaskBattery/screen.py +0 -0
- {multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/MultiTaskBattery/task_blocks.py +0 -0
- {multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/MultiTaskBattery/task_details.json +0 -0
- {multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/MultiTaskBattery/task_file.py +0 -0
- {multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/MultiTaskBattery/task_table.tsv +0 -0
- {multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/MultiTaskBattery/ttl_clock.py +0 -0
- {multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/MultiTaskBattery/utils.py +0 -0
- {multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/MultiTaskBattery.egg-info/SOURCES.txt +0 -0
- {multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/MultiTaskBattery.egg-info/dependency_links.txt +0 -0
- {multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/MultiTaskBattery.egg-info/entry_points.txt +0 -0
- {multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/MultiTaskBattery.egg-info/requires.txt +0 -0
- {multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/MultiTaskBattery.egg-info/top_level.txt +0 -0
- {multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/README.md +0 -0
- {multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/pyproject.toml +0 -0
- {multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/setup.cfg +0 -0
|
@@ -82,8 +82,8 @@ class Experiment:
|
|
|
82
82
|
folder as it is. One row for each instruction period ('instruction') and one for each
|
|
83
83
|
task period (trial_type = task name, plus the condition when the block has one).
|
|
84
84
|
Onsets are seconds since the first scanner trigger. Only for runs that waited for the
|
|
85
|
-
trigger; turn
|
|
86
|
-
if not getattr(self.const, 'write_events',
|
|
85
|
+
trigger; turn on with write_events = True in constants.py (off by default)."""
|
|
86
|
+
if not getattr(self.const, 'write_events', False) or getattr(self, 'scan_num', None) is None:
|
|
87
87
|
return
|
|
88
88
|
if not self.run_data_file.exists():
|
|
89
89
|
return
|
|
@@ -174,37 +174,28 @@ class Experiment:
|
|
|
174
174
|
|
|
175
175
|
Args:
|
|
176
176
|
"""
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
self.wait_ttl = bool(inputDlg.data[2])
|
|
198
|
-
else:
|
|
199
|
-
sys.exit()
|
|
200
|
-
|
|
177
|
+
# Step 1: Create a temporary small window for user feedback
|
|
178
|
+
self.screen.start_screen(height=getattr(self.const, 'instruction_text_height', None),
|
|
179
|
+
wrap_width=getattr(self.const, 'instruction_wrap_width', None))
|
|
180
|
+
|
|
181
|
+
# a dialog box pops up so you can enter info
|
|
182
|
+
#Set up input box
|
|
183
|
+
inputDlg = gui.Dlg(title = f"{self.exp_name}")
|
|
184
|
+
inputDlg.addField('Enter Subject id (str):',initial = self.subj_id) # run number (int)
|
|
185
|
+
inputDlg.addField('Enter Run Number (int):',initial = self.run_number+1) # run number (int)
|
|
186
|
+
inputDlg.addField('Wait for TTL pulse?', initial = True) # a checkbox for ttl pulse (set it true for scanning)
|
|
187
|
+
|
|
188
|
+
inputDlg.show()
|
|
189
|
+
|
|
190
|
+
if inputDlg.OK:
|
|
191
|
+
self.subj_id = str(inputDlg.data[0])
|
|
192
|
+
self.run_number = int(inputDlg.data[1])
|
|
193
|
+
# the run file always follows the run number (run 3 -> run_03.tsv); a repeated
|
|
194
|
+
# run is kept apart by its attempt number
|
|
195
|
+
self.run_filename = self.const.default_run_filename.format(f'{self.run_number:02d}')
|
|
196
|
+
self.wait_ttl = bool(inputDlg.data[2])
|
|
201
197
|
else:
|
|
202
|
-
|
|
203
|
-
# pass on the values for your debugging with the following keywords
|
|
204
|
-
self.subj_id = 'test00'
|
|
205
|
-
self.run_number = self.run_number+1
|
|
206
|
-
self.run_filename = 'run_01.tsv'
|
|
207
|
-
self.wait_ttl = True
|
|
198
|
+
sys.exit()
|
|
208
199
|
|
|
209
200
|
def init_run(self):
|
|
210
201
|
"""initializing the run:
|
|
@@ -20,7 +20,7 @@ def const(tmp_path_factory):
|
|
|
20
20
|
return types.SimpleNamespace(
|
|
21
21
|
exp_name='smoke', exp_dir=d, task_dir=d / 'task_files', run_dir=d / 'run_files',
|
|
22
22
|
data_dir=d / 'data', stim_dir=ut._PACKAGE_STIM_DIR, default_run_filename='run_01.tsv',
|
|
23
|
-
response_keys=['a', 's', 'd', 'f'], eye_tracker=False,
|
|
23
|
+
response_keys=['a', 's', 'd', 'f'], eye_tracker=False, show_scoreboard=False, write_events=True,
|
|
24
24
|
screen={'size': [800, 600], 'fullscr': False, 'number': 0, 'width': 53, 'distance': 57})
|
|
25
25
|
|
|
26
26
|
|
|
@@ -49,8 +49,7 @@ def test_task(name, const, screen):
|
|
|
49
49
|
tf.make_run_file([name], [f'{name}.tsv'], instruction_dur=1, task_dur=dur,
|
|
50
50
|
shuffle=False).to_csv(const.run_dir / 'run_01.tsv', sep='\t', index=False)
|
|
51
51
|
e = exp_block.Experiment(const, subj_id=name, screen=screen)
|
|
52
|
-
e.
|
|
53
|
-
e.subj_id, e.wait_ttl = name, False
|
|
52
|
+
e.run_number, e.run_filename, e.wait_ttl = 1, 'run_01.tsv', False # what the run dialog sets
|
|
54
53
|
e.init_run()
|
|
55
54
|
e.run()
|
|
56
55
|
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/MultiTaskBattery.egg-info/dependency_links.txt
RENAMED
|
File without changes
|
{multitaskbattery-1.4.0 → multitaskbattery-1.4.2}/MultiTaskBattery.egg-info/entry_points.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|