-
-
Notifications
You must be signed in to change notification settings - Fork 53
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
Optimized functions for speed and documentation changes #542
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @ajinkya-kulkarni
Thank you so much for your contribution ❤️ we appreciate it 😄
I left a couple of minor comments, plus a concern about a missing object reference. Could you please address?
Thanks
histolab/util.py
Outdated
@@ -38,25 +38,24 @@ def apply_mask_image(img: PIL.Image.Image, mask: np.ndarray) -> PIL.Image.Image: | |||
Parameters | |||
---------- | |||
img : PIL.Image.Image | |||
Input image | |||
Input image |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
could you explain the rationale of all this whitespaces added in the whole module? Thanks
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same, the numpy docstring style document uses 1 tab / 4 spaces of indentation for the description with respect to the parameter name
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hopefully fixed the import problem
for more information, see https://pre-commit.ci
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm seeing that:
histolab/util.py:138:89: E501 line too long (91 > 88 characters)
histolab/util.py:157:89: E501 line too long (95 > 88 characters)
histolab/util.py:317:89: E501 line too long (90 > 88 characters)
I'd suggest to use pre-commit
to avoid this problems in the commits. Please read the contribution guidelines
class Obj(object): | ||
|
||
@lazyproperty | ||
def fget(self): | ||
return 'some result' | ||
@lazyproperty | ||
def fget(self): | ||
return 'some result' | ||
|
||
obj = Obj() | ||
obj = Obj() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
each new commit is adding further spaces. Could you please check what's the problem?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm, strange. Let me look into it. Might be an issue with the code editor I use
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It could be 😄 thanks ❤️
HI @ajinkya-kulkarni |
No, I didnt run the tests locally. I'll have a look, thanks! |
Description
Types of Changes
Issues Fixed or Closed by This PR
Checklist