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

Dimensioned Spectrum.max() function #395

Merged
merged 3 commits into from Nov 14, 2021
Merged

Conversation

erwanp
Copy link
Member

@erwanp erwanp commented Nov 12, 2021

.max now returns dimensioned quantity. Allows :

s /= s.max()

as another way to normalize a spectrum

(and makes it much easier to multiply / subtract a Spectrum based on min/max values from another Spectrum, without having to worry about units ! )

…ault

this is an official astropy unit and therefore will help dimensioned-operations
@erwanp erwanp added post-process Related to the post-processing (ex: methods of Spectrum objects) interface not related to the physics of the code labels Nov 12, 2021
@erwanp erwanp added this to the 0.10.4 milestone Nov 12, 2021
@erwanp erwanp changed the title Add/dimensioned max Dimensioned Spectrum.max() function Nov 12, 2021
@codecov-commenter
Copy link

Codecov Report

Merging #395 (a0e205b) into develop (61052dc) will decrease coverage by 0.18%.
The diff coverage is 73.44%.

@@             Coverage Diff             @@
##           develop     #395      +/-   ##
===========================================
- Coverage    75.67%   75.48%   -0.19%     
===========================================
  Files          153      156       +3     
  Lines        17430    17574     +144     
===========================================
+ Hits         13190    13266      +76     
- Misses        4240     4308      +68     

@erwanp
Copy link
Member Author

erwanp commented Nov 12, 2021

@CorentinGrimaldi you can approve & merge directly

@erwanp erwanp merged commit 098891c into radis:develop Nov 14, 2021
@erwanp erwanp mentioned this pull request Nov 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
interface not related to the physics of the code post-process Related to the post-processing (ex: methods of Spectrum objects)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants