@@ -125,6 +125,10 @@ advanced_group.add_argument(
125125 '--paramOverrides' , metavar = 'NODETYPE:param=value NODEINSTANCE.param=value' , type = str , default = None , nargs = '*' ,
126126 help = 'Override specific parameters directly from the command line (by node type or by node names).' )
127127
128+ advanced_group .add_argument (
129+ '--setInvalidationString' , metavar = 'STRING' , type = str ,
130+ help = 'Set an invalidation string on ALL nodes.' )
131+
128132advanced_group .add_argument (
129133 '--compute' , metavar = '<yes/no>' , type = lambda x : bool (strtobool (x )), default = True , required = False ,
130134 help = 'You can set it to <no/false/0> to disable the computation.' )
@@ -172,6 +176,12 @@ with meshroom.core.graph.GraphModification(graph):
172176 # custom pipeline
173177 graph .initFromTemplate (args .pipeline , copyOutputs = True if args .output else False )
174178
179+ # Set invalidation string
180+ if invalidationString := args .setInvalidationString :
181+ nodes , _ = graph .dfsOnFinish ()
182+ for node in nodes :
183+ node .internalAttribute ("invalidation" ).value = invalidationString
184+
175185 if args .input :
176186 # get init nodes
177187 initNodes = graph .findInitNodes ()
@@ -248,7 +258,7 @@ with meshroom.core.graph.GraphModification(graph):
248258
249259 for n in copyNodes : # Set the remaining CopyPath nodes with the global path
250260 n .output .value = globalCopyPath
251- else :
261+ elif args . submit or args . compute :
252262 print (f'No output set, results will be available in the cache folder: "{ graph .cacheDir } "' )
253263
254264 if args .overrides :
0 commit comments