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

Add delmic load function #139

Open
wants to merge 9 commits into
base: main
Choose a base branch
from

Conversation

noemiebonnet
Copy link

@noemiebonnet noemiebonnet commented Jun 13, 2023

Description of the change

  • Addition of a delmic reader

Progress of the PR

  • basic parsing of the file
  • basic testing
  • add metadata handling
  • ... (additional functionalities)
  • add tests,
  • update docstring (if appropriate),
  • add an changelog entry in the upcoming_changes folder (see upcoming_changes/README.rst),
  • Check formatting changelog entry in the readthedocs doc build of this PR (link in github checks)
  • ready for review.

@jlaehne
Copy link
Contributor

jlaehne commented Jun 13, 2023

Tests are failing, because docstrings has been made private _docstrings in #132. Could you rename that in line 4 of your _api.py

@noemiebonnet
Copy link
Author

noemiebonnet commented Jun 13, 2023 via email

@codecov
Copy link

codecov bot commented Jun 15, 2023

Codecov Report

Patch coverage: 100.00% and project coverage change: +0.43 🎉

Comparison is base (a05840e) 85.24% compared to head (e793735) 85.68%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #139      +/-   ##
==========================================
+ Coverage   85.24%   85.68%   +0.43%     
==========================================
  Files          73       76       +3     
  Lines        9034     9841     +807     
  Branches     2045     2161     +116     
==========================================
+ Hits         7701     8432     +731     
- Misses        872      909      +37     
- Partials      461      500      +39     
Impacted Files Coverage Δ
rsciio/delmic/__init__.py 100.00% <100.00%> (ø)
rsciio/delmic/_api.py 100.00% <100.00%> (ø)

... and 25 files with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

…remove issue with reading h5 and hdf5 fomats
@jlaehne
Copy link
Contributor

jlaehne commented Jun 15, 2023

Thanks for putting this forward @noemiebonnet

As far as I understand, it only reads spectral images and not other types of Delmic-HDF5 files (e.g. single spectra, intensity maps, angle-resolved data) so far?

Note that we changed the placement and handling of the test data files in #123

Concerning the metadata, it would be great if the full metadata tree from the hdf5 file could be placed under original_metadata.

For the fields mentioned in https://docs.lumispy.org/en/latest/user_guide/metadata_structure.html it would be great if they can be mapped to the metadata tree at some point.

@@ -0,0 +1,8 @@
name: delmic
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
name: delmic
name: Delmic

},
]

metadata = {"signal": {"signal_type": "", "quantity": "Intensity (counts)"}}
Copy link
Contributor

Choose a reason for hiding this comment

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

If LumiSpy is installed, signal_type should be set to CL to provide the CL specific functions.


metadata = {"signal": {"signal_type": "", "quantity": "Intensity (counts)"}}

original_metadata = dict(DimensionScaleX="182", DimensionScaleY="132")
Copy link
Contributor

Choose a reason for hiding this comment

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

I guess these fixed values are just from testing so far?

@jlaehne
Copy link
Contributor

jlaehne commented Jun 15, 2023

I added a progress tracker to the initial comment. It helps show others how far this PR is, feel free to amend the list by editing the comment.

@ericpre ericpre added this to the v0.2 milestone Jul 8, 2023
@ericpre ericpre modified the milestones: v0.2, v0.3 Nov 8, 2023
@ericpre ericpre removed this from the v0.3 milestone Dec 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants