Open rita-ni opened 4 years ago
Please check off boxes as applicable, and elaborate in comments below. Your review is not limited to these topics, as described in the reviewer guide
The package includes all the following forms of documentation:
setup.py
file or elsewhere.Readme requirements The package meets the readme requirements below:
The README should include, from top to bottom:
Note: Be sure to check this carefully, as JOSS's submission requirements and scope differ from pyOpenSci's in terms of what types of packages are accepted.
The package contains a paper.md
matching JOSS's requirements with:
Estimated hours spent reviewing:
General Compliments!
Room to improve on!
compress
and sharpen
functions should have some example code to use to ease the user into adopting the functions in Read The Docs website.sharpen
and shrink
, but it was not compatible with compress
. A general solution might be to provide another image to work with it.
-- Firstly, "milad_cropped.png" was a PNG file in your img folder, and it was acutally of dimensions (372, 372, 4). When I tried testing compress on "milad_cropped.png", it threw me an error since it was in (H, W, 4) instead of (H, W, 3). Perhaps this could be improved by using an image example that is suitable for all of your functions.
-- Secondly, when I tried removing the last dimension of "milad_cropped.png" so that it is (H, W, 3), the compress
function returned a black picture regardless of various b values. sharpen
function, the documentation stated that it needs to take in a (H, W, 3) image input. However, it was suitable with the "milad_cropped.png" image which is (372, 372, 4). Perhaps the documentation can be revised such that it does not need to limit to (H, W, 3) images only.compress
and shrink
. However, there was an issue with sharpen
as it only works with image data values with max value =< 1. Perhaps the function can automatically take in data and automatically normalise it by the max value so that all the values are between 0 to 1. This will reduce any rejections for the user.img
folder, it does mean that his photo is publicly distributed via your project Github repo. There was no mention in your README that his permission was obtained to use/distribute his photo, and it might be viewed as a serious issue (see GDPR). To add on to that, it will be great to mention him or give him credit in your README even if he granted permission to use his photo. Alternatively, as a suggestion, you can use the mandrill photo that was used in other labs.imgtoolpy.compress(image, 3)
, it should be imgtoolpy.compress.compress(image, 3)
.I'm sorry for the long feedback but I thought since you guys put in the effort to develop the package, I should also put in the effort to try it out. Thanks for the opportunity to try your package! It was fun figuring out the different functions. Please let me know if you have any questions on my feedback!
Please check off boxes as applicable, and elaborate in comments below. Your review is not limited to these topics, as described in the reviewer guide
The package includes all the following forms of documentation:
setup.py
file or elsewhere.Readme requirements The package meets the readme requirements below:
The README should include, from top to bottom:
Note: Be sure to check this carefully, as JOSS's submission requirements and scope differ from pyOpenSci's in terms of what types of packages are accepted.
The package contains a paper.md
matching JOSS's requirements with:
Estimated hours spent reviewing:
The coding is neat and it is well commented which makes it easier to review and understand. The test cases has appropriate negative as well as positive test cases. There are few bugs which I noticed and also some suggestions for improvement:
Include a working example in the README.md file with code and its result.You can check this repo for your reference. This will help the user understand how to use your package and can give the glipse of what each function does. It took me some time to understand how to use it.
You have three separate files for each function. So the obvious command import imgtoolpy
won't work for your case. The second column name of the usage
section is misleading. It would be better if you mention somewhere how to import your function eg.
from imgtoolpy import compress,sharpen,shrink
Function compress
: Some images have more than 3 channels. I was trying one png image with 4 channels and it threw error. Please add some defensive coding for this so that the user understands what is wrong. Or you can just check for more than 3 channels and strip off the 4th channel inside your code that will make your code more generalized. If you add this write one test case for this one.
Function sharpen
: Although you wrote the code defensively such that it doesn't accept images having value other than 0 to 1, it makes such a powerful function very limited as most of the images have values between 0 to 255. You can just handle this by dividing your array by 255. So my suggestion would be that instead of throwing exception just divide the array by 255 and that will make your pixel intensity between 0 to 1. I tried this on my machine and it worked properly.
Function sharpen
: Your function takes in colored image and returns a sharpened monotone image. So there is no way to see the difference the function is making. If you could return the non sharpened monotone image along with the sharpened monotone image, that will help to make clear distinction of how well your sharpening function is performing.
The docstring of all the functions doesn't have any example. It is a good practice to include example in docstring for all user facing functions.
I really found your package very interesting and it was fun doing the review. I really enjoyed playing around with the function which gave very interesting results. Hope this review can help enhance your package.
Hi @kfoofw and @sgauravm , thank you for the valuable feedback, and we have addressed some of your important comments in release 1.1.0.
More specifically, below are what have been updated:
shrink()
to crop()
sharpen()
Thank you again for your time testing our package!
Nice new release of your package! I really like the new photos!
Thank you @kfoofw and @sgauravm for your valuable feedback. We were unable to address all your feedback due to time constraints, but here is a list of what we improved:
compress
and sharpen
functions in the documentation.README.md
.compress
functionsharpen
function so that all the values are between 0 to 1 automatically.Usage
table in README.md
and added usage scenarios.README.md
.The feedback was extremely helpful, thank you again!
Submitting Author: Ruidan Ni (@rita-ni)
Package Name: imgtoolpy One-Line Description of Package: A Python package that is intended to allow users to compress, sharpen and shrink an input image Repository Link: imgtoolpy Version submitted: v0.3.0 Editor: Varada Kolhatkar (@kvarada) Reviewer 1: Kenneth Foo (@kfoofw) Reviewer 2: Gaurav Sinha (@sgauravm) Archive: TBD
Version accepted: TBD
Description
imgtoolpy
is a Python package that is intended to allow users to compress, sharpen and shrink an input image. Our package only allows the input image to be a 3D numpy array and output the manipulated image as a 3D numpy array. It contains three functions: compress(), sharpen(), and shrink().Scope
* Please fill out a pre-submission inquiry before submitting a data visualization package. For more info, see this section of our guidebook.
Explain how the and why the package falls under these categories (briefly, 1-2 sentences):
Who is the target audience and what are scientific applications of this package?
Are there other Python packages that accomplish the same thing? If so, how does yours differ?
If you made a pre-submission enquiry, please paste the link to the corresponding issue, forum post, or other discussion, or
@tag
the editor you contacted:Technical checks
For details about the pyOpenSci packaging requirements, see our packaging guide. Confirm each of the following by checking the box. This package:
Publication options
JOSS Checks
- [ ] The package has an **obvious research application** according to JOSS's definition in their [submission requirements](https://joss.readthedocs.io/en/latest/submitting.html#submission-requirements). Be aware that completing the pyOpenSci review process **does not** guarantee acceptance to JOSS. Be sure to read their submission requirements (linked above) if you are interested in submitting to JOSS. - [ ] The package is not a "minor utility" as defined by JOSS's [submission requirements](https://joss.readthedocs.io/en/latest/submitting.html#submission-requirements): "Minor ‘utility’ packages, including ‘thin’ API clients, are not acceptable." pyOpenSci welcomes these packages under "Data Retrieval", but JOSS has slightly different criteria. - [ ] The package contains a `paper.md` matching [JOSS's requirements](https://joss.readthedocs.io/en/latest/submitting.html#what-should-my-paper-contain) with a high-level description in the package root or in `inst/`. - [ ] The package is deposited in a long-term repository with the DOI: *Note: Do not submit your package separately to JOSS*Are you OK with Reviewers Submitting Issues and/or pull requests to your Repo Directly?
This option will allow reviewers to open smaller issues that can then be linked to PR's rather than submitting a more dense text based review. It will also allow you to demonstrate addressing the issue via PR links.
Code of conduct
P.S. Have feedback/comments about our review process? Leave a comment here
Editor and Review Templates
Editor and review templates can be found here