InsightSoftwareConsortium / InsightSoftwareConsortium/ITKElastix
Feature: Write log to file without writing transform parameters
- Dominant language
- Python
- Stars
- 281
- Forks
- 29
- Avg merge
- 16h 28m
- Merged PRs (30d)
- 8
Description
Currently, in order to write the log to file you need to do the following:
```
elastix_object = itk.ElastixRegistrationMethod[itk.Image[itk.F, 3], itk.Image[itk.F, 3]].New()
elastix_object.SetLogToFile(True)
elastix_object.SetLogFileName("out.log")
elastix_object.SetOutputDirectory("/data/")
```
However, by using `elastix_object.SetOutputDirectory`, the transform parameter file will also automatically be written to the specified output directory. I am already saving the transform parameter file separately (after manipulating it a bit ), so having it written to file without explicitly asking Elastix is confusing and clutters up folders.
Ideally, something like this would be sufficient, as it would be clear then that only the log file is written:
```
elastix_object = itk.ElastixRegistrationMethod[itk.Image[itk.F, 3], itk.Image[itk.F, 3]].New()
elastix_object.SetLogToFile(True)
elastix_object.SetLogFileName("/data/out.log")
```
However, explicitly setting that the transform parameter file should not be written is also a solution:
```
elastix_object = itk.ElastixRegistrationMethod[itk.Image[itk.F, 3], itk.Image[itk.F, 3]].New()
elastix_object.SetLogToFile(True)
elastix_object.SetLogFileName("out.log")
elastix_object.SetOutputDirectory("/data/")
elastix_object.SetWriteTransformParameters(False)
```
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.