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

Allow dataarrays and preserve dtype in rad2temp #203

Merged
merged 4 commits into from
Nov 22, 2023

Conversation

mraspaud
Copy link
Member

This PR allow xarray's dataarrays to be passe to radiance to temperature conversions, and also makes these functions preserve dtype.

  • Tests added
  • Tests passed: Passes pytest pyspectral
  • Passes flake8 pyspectral
  • Fully documented

@mraspaud mraspaud self-assigned this Nov 17, 2023
Copy link

codecov bot commented Nov 17, 2023

Codecov Report

Attention: 1 lines in your changes are missing coverage. Please review.

Comparison is base (fd32fe9) 89.27% compared to head (ec59df7) 90.00%.

Files Patch % Lines
pyspectral/utils.py 96.15% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #203      +/-   ##
==========================================
+ Coverage   89.27%   90.00%   +0.72%     
==========================================
  Files          23       23              
  Lines        2545     2580      +35     
==========================================
+ Hits         2272     2322      +50     
+ Misses        273      258      -15     
Flag Coverage Δ
unittests 90.00% <99.00%> (+0.72%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Member

@pnuu pnuu left a comment

Choose a reason for hiding this comment

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

LGTM.

I love how much you could just delete from the original code 😂

pyspectral/utils.py Show resolved Hide resolved
pyspectral/tests/test_rad_tb_conversions.py Show resolved Hide resolved
pyspectral/utils.py Show resolved Hide resolved
@pnuu
Copy link
Member

pnuu commented Nov 22, 2023

Closes #201

@pnuu
Copy link
Member

pnuu commented Nov 22, 2023

Closes pytroll/satpy#2613

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