Skip to content

Commit e6703ff

Browse files
committed
add: prov:type for activity that includes nipype module
1 parent 0fa4234 commit e6703ff

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

nipype/utils/provenance.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -256,9 +256,12 @@ def add_results(self, results):
256256
inputs = results.inputs
257257
outputs = results.outputs
258258
classname = interface.__name__
259+
modulepath = "{0}.{1}".format(interface.__module__, interface.__name__)
260+
activitytype = ''.join([i.capitalize() for i in modulepath.split('.')])
259261

260262
a0_attrs = {nipype_ns['module']: interface.__module__,
261263
nipype_ns["interface"]: classname,
264+
pm.PROV["type"]: nipype_ns[activitytype],
262265
pm.PROV["label"]: classname,
263266
nipype_ns['duration']: safe_encode(runtime.duration),
264267
nipype_ns['workingDirectory']: safe_encode(runtime.cwd),

0 commit comments

Comments
 (0)