Skip to content

Conversation

@smribet
Copy link
Collaborator

@smribet smribet commented Dec 29, 2024

A few small updates to the Arina reader:

  • default square scan
  • optional transpose to accommodate new and old files
  • metadata reading for new files

Example here.

Copy link
Member

@gvarnavi gvarnavi left a comment

Choose a reason for hiding this comment

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

lgtm, added two minor comments but will go ahead and approve regardless.

)

try:
with h5py.File(f"{filename[:-10]}.h5", "r") as f:
Copy link
Member

Choose a reason for hiding this comment

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

let's add a comment here to make sure we don't forget that [:-10] comes from dropping the "_master" suffix?

mem="RAM",
binfactor: int = 1,
dtype_bin: float = None,
fix_transpose=False,
Copy link
Member

Choose a reason for hiding this comment

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

It would be great if this default could None, and we could (reliably) detect whether the file is using the old/new ARINA format and set a default value accordingly if not passed.

@smribet smribet merged commit 544416c into py4dstem:dev Jan 21, 2025
6 checks passed
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