readOnly parameter is missing in TRestRun?

REST version : v2.2.12_dev

Somehow, the previously existing parameter readOnly inside TRestRun seems it is now missing.

It was useful to set this parameter readOnly=true when using pure-visualisation processes. Has this parameter been replaced by other configuration settings?

On the other hand, I was trying to find out the parameters that are read by TRestRun from the RML, but those seem not retrieved as usual from InitFromConfigFile. Where are TRestRun parameters read?

Thanks

I don’t know the detailed functionality of readOnly parameter. Is that REST generates no output file? or that the input file is not changed?

The parameter reading is in method TRestRun::BeginOfInit()

When readOnly was enabled no output file was generated at all. In that case, also, makes no sense to check if output path exists and/or it is writable.

I don’t use it now since some time, and I don’t mind it is not anymore there. But it seems overwrite parameter in TRestRun is also not behaving as before.

I was using overwrite parameter in simulations.

If overwrite was set to OFF it would check if the output file exists and avoid overwriting it. Not sure now how, if adding an appendix to the filename like _001, _002, etc. Or by increasing the runNumber to the next value when using runNumber=auto.

Anyway, the readOnly option is more important to recover. We were using it in 2.1.7 as an eventDisplay for the DAQ, together with TRestSharedBufferToSignalProcess. We were not interested there to generate any output data.

If overwrite is false, and if the output file name is “default”, then it will increase the sub run number in the default output file name. Like:

Run_Test_nkx_simulation_Template_0001_00000_V2.2.12.root
Run_Test_nkx_simulation_Template_0001_00001_V2.2.12.root
Run_Test_nkx_simulation_Template_0001_00002_V2.2.12.root

It makes sense to have a “read only” option. Maybe we can implement it by adding a preserved value in “outputFile” parameter? This will be more straight forward.

<TRestRun name="SJTU_Proto" >
...
    <parameter name="outputFile" value="null" />
  </TRestRun>

Then this option can also be set in the command line:

restManager --c XXX.rml --o null
1 Like

Yes, that looks awesome!