Skip to content

Distiller metadata updater#530

Merged
ercius merged 10 commits into
mainfrom
distiller_metadata_updater
Jan 23, 2026
Merged

Distiller metadata updater#530
ercius merged 10 commits into
mainfrom
distiller_metadata_updater

Conversation

@ercius

@ercius ercius commented Jan 23, 2026

Copy link
Copy Markdown
Collaborator

This will write astigmatism results (C12 and phi12) from the quantem-direct-ptycho into the metadata of the correct Distiller scan.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 889f754db1

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread operators/update-distiller-metadata/run.py Outdated
Comment thread operators/update-distiller-metadata/run.py Outdated
Comment thread operators/update-distiller-metadata/run.py Outdated
Comment thread operators/update-distiller-metadata/run.py Outdated
@ercius
ercius force-pushed the distiller_metadata_updater branch from f27f547 to 52a71dc Compare January 23, 2026 19:18
}
updated_scan = add_metadata(distiller_scan_id, metadata_payload)
logger.info(f"Updated Distiller scan metadata: {updated_scan.metadata}")
else:

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.

For future reference if you have something like this you can instead return early, and you reduce the nesting by 1 which makes more readable code

if not C12_magnitude or not C12_angle:
    logger.info("C12 Magnitude or phi12 not found in metadata.")
    return
...

@ercius
ercius merged commit 41e0331 into main Jan 23, 2026
13 checks passed
@ercius
ercius deleted the distiller_metadata_updater branch January 23, 2026 19:30
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