Skip to content

Commit

Permalink
Noise (#38)
Browse files Browse the repository at this point in the history
* Initial port of NoiseLevelEstimation to function-level

* Replaced NoiseLevelEstimation class and associated tests with function equivalents.

* Declassed NoiseLevelEstimation routines and provided appropriate tests

* Addressed PEP8 errors

* Added changelog

* Fixed __main__ in test_noise.py and added comments to noise.py

* Declassed NoiseLevelEstimation and added appropriate tests. Updated master branch and recommiting to solve merge conflicts

* Output of noise estimation function is now a dictionary. Added DOIs for references. Other small changes. No changes to algorithms themselves, as was suggested by @dpshelio

* added reduce cr example

* fixed tox

* Fixed deps

* renamed example file

* ran linters

* Apply suggestions from code review

Co-Authored-By: Nabil Freij <[email protected]>

* added few links

* fixed docs build

* Apply suggestions from code review

Co-Authored-By: Nabil Freij <[email protected]>

* Apply suggestions from code review

Co-Authored-By: Nabil Freij <[email protected]>

* Added note for jp2

* removed jp2

* changed parameters for better results

* added parameter docs

* deleted few lines

* Apply suggestions from code review

Co-Authored-By: Nabil Freij <[email protected]>

* Update examples/remove_CR_hits.py

Co-Authored-By: Nabil Freij <[email protected]>

* fixed comments on the previous PR

* fixed pytest

* changelog and pep

* docs and linters
  • Loading branch information
vatch123 authored and nabobalis committed Aug 21, 2019
1 parent a0315b2 commit fbf6a19
Show file tree
Hide file tree
Showing 5 changed files with 353 additions and 273 deletions.
1 change: 1 addition & 0 deletions changelog/38.trivial.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Transferred sunkit_image.utils.noise.NoiseLevelEstimation from class object into a series of functions.
4 changes: 3 additions & 1 deletion examples/remove_CR_hits.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,9 @@
# to clean the high intensity bright cosmic ray hits.
# We also modify the ``readnoise`` parameter to obtain better results.

mask, clean_data = astroscrappy.detect_cosmics(lasco_map.data, sigclip=2, objlim=2, readnoise=4, verbose=True)
mask, clean_data = astroscrappy.detect_cosmics(
lasco_map.data, sigclip=2, objlim=2, readnoise=4, verbose=True
)
# This returns two variables - mask is a boolean array depicting whether there is
# a cosmic ray hit at that pixel, clean_data is the cleaned image after removing those
# hits.
Expand Down
1 change: 1 addition & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ install_requires =

[options.extras_require]
tests =
pytest<5.1
pytest-astropy
pytest-cov
tox
Expand Down
Loading

0 comments on commit fbf6a19

Please sign in to comment.