Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

I24 serial: commissioning fixes #645

Merged
merged 20 commits into from
Nov 15, 2024
Merged

I24 serial: commissioning fixes #645

merged 20 commits into from
Nov 15, 2024

Conversation

noemifrisina
Copy link
Contributor

@noemifrisina noemifrisina commented Nov 13, 2024

Fixes from commissioning on 13/11/24

Copy link

codecov bot commented Nov 13, 2024

Codecov Report

Attention: Patch coverage is 67.36111% with 47 lines in your changes missing coverage. Please review.

Project coverage is 85.00%. Comparing base (c2a189f) to head (95cc815).
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #645      +/-   ##
==========================================
+ Coverage   82.64%   85.00%   +2.35%     
==========================================
  Files          98       98              
  Lines        6551     6548       -3     
==========================================
+ Hits         5414     5566     +152     
+ Misses       1137      982     -155     
Components Coverage Δ
i24 SSX 69.59% <67.36%> (+5.48%) ⬆️
hyperion 96.79% <ø> (ø)
other 94.97% <ø> (ø)

@@ -224,20 +222,20 @@ def generate_dcid(
)
resp.raise_for_status()
self.dcid = resp.json()["dataCollectionId"]
logger.info("Generated DCID %s", self.dcid)
SSX_LOGGER.info("Generated DCID %s", self.dcid)
except requests.HTTPError as e:
Copy link
Contributor

Choose a reason for hiding this comment

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

I think we should have some tests for this file

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Adding them in #627 , which is actually changing the code in this file so while I may add them here they would go away in a couple of hours?

@@ -467,7 +471,7 @@ def start_i24(
SSX_LOGGER.info("Using Eiger detector")

SSX_LOGGER.debug(f"Creating the directory for the collection in {filepath}.")
Path(filepath).mkdir(parents=True)
Path(filepath).mkdir(parents=True, exist_ok=True)

Copy link
Contributor

Choose a reason for hiding this comment

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

why do we only create the directory for the eiger and not the pilatus?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Because the Pilatus creates its own directories, while the Eiger doesn't, so there's no need to explicitly create it. Until a few weeks ago - when we started running as i24detector on procserv - this one line was actually triggering a one image collection from the Pilatus just to get the directory....

caput(pv.eiger_wavelength, caget(pv.dcm_lambda))
caput(pv.eiger_omegaincr, 0.0)
caput(pv.eiger_beamx, 1605.7)
caput(pv.eiger_beamy, 1702.7)
caput(pv.eiger_beamx, 1600.0)
Copy link
Contributor

Choose a reason for hiding this comment

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

I think these should be defined as global constants at the top of the file rather than buried in the code here.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is being done in another PR, see

Copy link
Contributor

@rtuck99 rtuck99 left a comment

Choose a reason for hiding this comment

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

Approved

@noemifrisina noemifrisina merged commit 602a3b7 into main Nov 15, 2024
21 of 22 checks passed
@noemifrisina noemifrisina deleted the commissioning13112024 branch November 15, 2024 15:10
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