Closed tashrifbillah closed 5 years ago
👍 I agree after thinking about your use case. I think it's safe to always overwrite the path for the data filename and update it.
This would be good to document (in the docs). Additionally, would be good to have a test for this. Maybe even take your use case and demonstrate how it causes problems.
Assign: @tashrifbillah
We should omit the if-else below: https://github.com/mhe/pynrrd/blob/master/nrrd/writer.py#L190
Omitting the condition should also address the TODO below: https://github.com/mhe/pynrrd/blob/master/nrrd/writer.py#L210
I experienced this while modifying an NHDR and saving it as another NHDR. In this case, the modified detached data is not saved where my modified NHDR is.
Correction: Detached data is saved in the working directory.