Skip to content

Conversation

@mpks
Copy link
Contributor

@mpks mpks commented Oct 6, 2024

Extend ED_mrc_to_nexus command to work with TVIPS cameras (besides eBIC Ceta-D detector). The command now has an option --detector that could be set either to cetad or tvips.

Extend ED_mrc_to_nexus command to work with TVIPS cameras
(besides eBIC Ceta-D detector). The command now has an option
--detector that could be set either to cetad or tvips.
Copy link
Collaborator

@noemifrisina noemifrisina left a comment

Choose a reason for hiding this comment

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

Lgtm, thanks. Definitely much tidier with one command line tool.
I added a couple of comments but nothing big.

Please rebase on top of main before merging - although there shouldn't be any conflicts.
Also, a lot of bits in the code look to be unformatted, could you please run pre-commits on them?

parser.add_argument(
"--detector",
type=str,
default="cetad",
Copy link
Collaborator

Choose a reason for hiding this comment

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

You can add a choices=["cetad", "tvips"] option to the argument so that it will accept only those values and show them as part of the help.

return n, out_file, np.array(angles)
else:
msg = "The converter expects either a list of MRC images\n"
msg = "or a single MRC file with a stack of images."
Copy link
Collaborator

Choose a reason for hiding this comment

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

I think this is complaining because the next msg is missing a '+'

import numpy as np


def cal_wavelength(V0):
Copy link
Collaborator

Choose a reason for hiding this comment

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

Could: add some typing to these functions?

Also it would be good to have a couple of tests...

mpks and others added 11 commits May 7, 2025 10:44
Bumps [h5py](https://github.com/h5py/h5py) from 3.11.0 to 3.13.0.
- [Release notes](https://github.com/h5py/h5py/releases)
- [Changelog](https://github.com/h5py/h5py/blob/master/docs/release_guide.rst)
- [Commits](h5py/h5py@3.11.0...3.13.0)

---
updated-dependencies:
- dependency-name: h5py
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Noemi Frisina <54588199+noemifrisina@users.noreply.github.com>
Bumps [pydantic](https://github.com/pydantic/pydantic) from 2.10.3 to 2.11.4.
- [Release notes](https://github.com/pydantic/pydantic/releases)
- [Changelog](https://github.com/pydantic/pydantic/blob/main/HISTORY.md)
- [Commits](pydantic/pydantic@v2.10.3...v2.11.4)

---
updated-dependencies:
- dependency-name: pydantic
  dependency-version: 2.11.4
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [numpy](https://github.com/numpy/numpy) from 2.2.2 to 2.2.6.
- [Release notes](https://github.com/numpy/numpy/releases)
- [Changelog](https://github.com/numpy/numpy/blob/main/doc/RELEASE_WALKTHROUGH.rst)
- [Commits](numpy/numpy@v2.2.2...v2.2.6)

---
updated-dependencies:
- dependency-name: numpy
  dependency-version: 2.2.6
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Update pydantic things

* A start and some notes

* Replace old namedtuples

* Start rethinking parameter model

* Add utility function to be used by nexgen server for serial

* Update changelog

* Fix test

* Add a couple of dumb tests

* Tidy up where possible

* For now comment out before refactoring

* Pass timestamps as datetime

* Replace deprecated function

* Fix iso timestamp bug and add test

* Improve validation

* Small test detail

* Small improvements on general writer

* Tidy ups

* Update changelog

* Start adding to CLI to make it nicer

* Update command line for i19

* Update changelog

* Add docstring

* Fix typo
@noemifrisina noemifrisina merged commit 9668f79 into DiamondLightSource:main May 20, 2025
9 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