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

update sigma_color description in denoise_bilateral #5393

Merged
merged 8 commits into from
May 20, 2021

Conversation

felipegb94
Copy link
Contributor

Description

Update the description of sigma_color in denoise_bilateral to make it clear that img_as_float only rescales images with any int type, and that it does not rescale float images.

See discussion in: #5391

Checklist

N/A

For reviewers

  • Check that the PR title is short, concise, and will make sense 1 year
    later.
  • Check that new functions are imported in corresponding __init__.py.
  • Check that new features, API changes, and deprecations are mentioned in
    doc/release/release_dev.rst.

Update the description of `sigma_color` in `denoise_bilateral`. See: scikit-image#5391
@pep8speaks
Copy link

pep8speaks commented May 13, 2021

Hello @felipegb94! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:

There are currently no PEP 8 issues detected in this Pull Request. Cheers! 🍻

Comment last updated at 2021-05-20 18:34:51 UTC

Fix PEP 8 issues raised for this PR scikit-image#5393
skimage/restoration/_denoise.py Outdated Show resolved Hide resolved
skimage/restoration/_denoise.py Outdated Show resolved Hide resolved
skimage/restoration/_denoise.py Outdated Show resolved Hide resolved
skimage/restoration/_denoise.py Outdated Show resolved Hide resolved
skimage/restoration/_denoise.py Outdated Show resolved Hide resolved
Copy link
Member

@mkcor mkcor left a comment

Choose a reason for hiding this comment

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

Thanks! I left suggestions for some minor rewording.

skimage/restoration/_denoise.py Outdated Show resolved Hide resolved
skimage/restoration/_denoise.py Outdated Show resolved Hide resolved
@mkcor
Copy link
Member

mkcor commented May 14, 2021

Closes #5391

felipegb94 and others added 2 commits May 14, 2021 10:52
Co-authored-by: Marianne Corvellec <marianne.corvellec@ens-lyon.org>
Co-authored-by: Marianne Corvellec <marianne.corvellec@ens-lyon.org>
Comment on lines 114 to 119
``image`` will be used. Note that, if the image is of
any `int` dtype, ``image`` will be converted using the `img_as_float`
function and thus the standard deviation will be in
range ``[0, 1]``. For more information on scikit-image's data
type conversions and how images are rescaled in these conversions,
see: https://scikit-image.org/docs/stable/user_guide/data_types.html.
Copy link
Member

Choose a reason for hiding this comment

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

I think that Note that... .html. would be better placed in the Notes section, like:

    Note that, if the image is of
    any `int` dtype, ``image`` will be converted using the `img_as_float`
    function and thus the standard deviation will be in
    range ``[0, 1]``.

    For more information on scikit-image's data
    type conversions and how images are rescaled in these conversions,
    see: https://scikit-image.org/docs/stable/user_guide/data_types.html.

Copy link
Member

Choose a reason for hiding this comment

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

Respecting PEP-8, of course 😅

Copy link
Contributor Author

Choose a reason for hiding this comment

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

got it. just applied the suggestions you made. thanks!

Copy link
Member

@alexdesiqueira alexdesiqueira left a comment

Choose a reason for hiding this comment

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

Thank you @felipegb94! I think that these instructions feel too "heavy" for the description already; just left a suggestion, then.
Thanks again!

Comment on lines 114 to 119
``image`` will be used. Note that, if the image is of
any `int` dtype, ``image`` will be converted using the `img_as_float`
function and thus the standard deviation will be in
range ``[0, 1]``. For more information on scikit-image's data
type conversions and how images are rescaled in these conversions,
see: https://scikit-image.org/docs/stable/user_guide/data_types.html.
Copy link
Member

Choose a reason for hiding this comment

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

Respecting PEP-8, of course 😅

@alexdesiqueira alexdesiqueira linked an issue May 16, 2021 that may be closed by this pull request
Move some denoise_bilateral `sigma_color` text to Notes
@alexdesiqueira
Copy link
Member

It looks great @felipegb94! Thank you very much for your work!

@alexdesiqueira alexdesiqueira merged commit 1db5515 into scikit-image:main May 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Confusing documentation for denoise_bilateral
4 participants