@@ -34,11 +34,9 @@ def main():
34
34
import sys
35
35
from multiprocessing import Manager , Process
36
36
from os import EX_SOFTWARE
37
- from pathlib import Path
38
37
39
38
from simbids .cli .parser import parse_args
40
39
from simbids .cli .workflow import build_workflow
41
- from simbids .utils .bids import write_bidsignore , write_derivative_description
42
40
43
41
parse_args ()
44
42
@@ -144,7 +142,6 @@ def main():
144
142
'\n ' .join (['SimBIDS config:' ] + [f'\t \t { s } ' for s in config .dumps ().splitlines ()]),
145
143
)
146
144
config .loggers .workflow .log (25 , 'SimBIDS started!' )
147
- errno = 1 # Default is error exit unless otherwise set
148
145
try :
149
146
simbids_wf .run (** config .nipype .get_plugin ())
150
147
except Exception as e :
@@ -172,32 +169,6 @@ def main():
172
169
sentry_sdk .add_breadcrumb (message = success_message , level = 'info' )
173
170
sentry_sdk .capture_message (success_message , level = 'info' )
174
171
175
- # Bother users with the boilerplate only iff the workflow went okay.
176
- boiler_file = config .execution .output_dir / 'logs' / 'CITATION.md'
177
- if boiler_file .exists ():
178
- if config .environment .exec_env in (
179
- 'singularity' ,
180
- 'docker' ,
181
- 'simbids-docker' ,
182
- ):
183
- boiler_file = Path ('<OUTPUT_PATH>' ) / boiler_file .relative_to (
184
- config .execution .output_dir
185
- )
186
-
187
- config .loggers .workflow .log (
188
- 25 ,
189
- 'Works derived from this SimBIDS execution should include the '
190
- f'boilerplate text found in { boiler_file } .' ,
191
- )
192
-
193
- if config .workflow .run_reconall :
194
- from niworkflows .utils .misc import _copy_any
195
- from templateflow import api
196
-
197
- dseg_tsv = str (api .get ('fsaverage' , suffix = 'dseg' , extension = ['.tsv' ]))
198
- _copy_any (dseg_tsv , str (config .execution .output_dir / 'desc-aseg_dseg.tsv' ))
199
- _copy_any (dseg_tsv , str (config .execution .output_dir / 'desc-aparcaseg_dseg.tsv' ))
200
- errno = 0
201
172
finally :
202
173
# Code Carbon
203
174
if config .execution .track_carbon :
@@ -206,28 +177,6 @@ def main():
206
177
config .loggers .workflow .log (25 , f'Saving logs at: { config .execution .log_dir } ' )
207
178
config .loggers .workflow .log (25 , f'Carbon emissions: { emissions } kg' )
208
179
209
- from simbids .reports .core import generate_reports
210
-
211
- # Generate reports phase
212
- failed_reports = generate_reports (
213
- subject_list = config .execution .participant_label ,
214
- output_dir = config .execution .output_dir ,
215
- run_uuid = config .execution .run_uuid ,
216
- )
217
- write_derivative_description (
218
- input_dir = config .execution .bids_dir ,
219
- output_dir = config .execution .output_dir ,
220
- dataset_links = config .execution .dataset_links ,
221
- )
222
- write_bidsignore (config .execution .output_dir )
223
-
224
- if sentry_sdk is not None and failed_reports :
225
- sentry_sdk .capture_message (
226
- f'Report generation failed for { failed_reports } subjects' ,
227
- level = 'error' ,
228
- )
229
- sys .exit (int ((errno + len (failed_reports )) > 0 ))
230
-
231
180
232
181
def migas_exit () -> None :
233
182
"""Exit migas.
0 commit comments