BlendingToolKit icon indicating copy to clipboard operation
BlendingToolKit copied to clipboard

Fixing SCARLET notebook and improving plotting

Open thuiop opened this issue 2 years ago • 6 comments

Closes #364. The finally functionnal measure function for SCARLET is done and should stay that way thanks to the tag in the scarlet repo. It does not include multiresolution functionnality, as was discussed with Ismael and Axel. Plotting the deblended images was also improved on the occasion, including colorbars and better overall presentation.

@pmelchior @fred3m may be interested in taking a look at this PR ; we manage to reproduce pretty good results with SCARLET in BTK (see following image). resultsscarlet

thuiop avatar Oct 14 '22 09:10 thuiop

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

Codecov Report

Base: 89.76% // Head: 89.31% // Decreases project coverage by -0.44% :warning:

Coverage data is based on head (c9548f5) compared to base (c36b185). Patch coverage: 82.53% of modified lines in pull request are covered.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop     #378      +/-   ##
===========================================
- Coverage    89.76%   89.31%   -0.45%     
===========================================
  Files           11       11              
  Lines         1524     1563      +39     
===========================================
+ Hits          1368     1396      +28     
- Misses         156      167      +11     
Flag Coverage Δ
unittests 89.31% <82.53%> (-0.45%) :arrow_down:

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

Impacted Files Coverage Δ
btk/plot_utils.py 82.68% <82.53%> (-1.15%) :arrow_down:

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.

codecov[bot] avatar Oct 14 '22 09:10 codecov[bot]

  • [x] fixing the residual plotting
  • [x] changing legend names in histogram to look nice
  • [ ] reduce spacing between plots in reconstructions

ismael-mendoza avatar Oct 14 '22 13:10 ismael-mendoza

Here is how the residuals look like currently. residuals

thuiop avatar Oct 16 '22 21:10 thuiop

That looks quite cool. The colorbar at the end of each row applies to the three images?

And could you clarify how you set the scale for the 'zoomed-in' residual? do you let matplotlib choose that one automatically?

ismael-mendoza avatar Oct 17 '22 01:10 ismael-mendoza

That looks quite cool. The colorbar at the end of each row applies to the three images?

And could you clarify how you set the scale for the 'zoomed-in' residual? do you let matplotlib choose that one automatically?

Yes, the colorbar is the same for the 3 images ; it is obviously a different one for the zoomed-in one. The size of the zoom-in window is fixed ; the part that appears in it is currently fixed to be +- 12 pixels around the center of the galaxy. This is probably not ideal is you use a survey with a widely different pixel scale (e.g. HST) or deal with large galaxies, but we do not have these informations at this point in the code.

thuiop avatar Oct 17 '22 18:10 thuiop