Skip to content

Update the conversion script for the Fe XDI file - #25

Open
mretegan wants to merge 1 commit into
mainfrom
update-xdi-examples
Open

mretegan wants to merge 1 commit into
mainfrom
update-xdi-examples

Conversation

@mretegan

Copy link
Copy Markdown
Contributor

The PR updates the script to write a NeXus file following the current definition proposed here nexusformat/definitions#1640.

Since things are still changing in the definitions, keeping all the converted file updated is tricky, so for the moment only I focused on the 3 Fe XDI files.

@newville Could you have a closer look and let me know what you think?

@mretegan
mretegan requested a review from newville September 23, 2026 15:03

@newville newville left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks mostly okay to me.

Would`root["definition"] = "NXxas" allowed? If not, why not? That is, it's OK to have subclasses, but are they required? That does sort of put an extra burden on defining the data, and on using it.

also: What happens here is mono crystall and/or d_spacing cannot be determined from the "mono" attributes? A reasonable default might be helpful?

@mretegan

Copy link
Copy Markdown
Contributor Author

Having root["definition"] = "NXxas is allowed, of course, but in this case we know it is transmission data; it makes sense to use the NXxas_trans subclass.

I am not sure that we should have defaults for things that are not in the parent file. As you said many times, this could be used for reprocessing, and if the default is not appropriate for that specific case, it might cause more harm than good.

@newville

Copy link
Copy Markdown
Member

@mretegan thanks -- I agree with all of that... just want to make sure that "NXxas" is not invalid...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants