Skip to content

docs: image#311

Merged
giovannivolpe merged 18 commits intoDeepTrackAI:developfrom
Pwhsky:docs-image
Mar 15, 2025
Merged

docs: image#311
giovannivolpe merged 18 commits intoDeepTrackAI:developfrom
Pwhsky:docs-image

Conversation

@Pwhsky
Copy link
Copy Markdown
Collaborator

@Pwhsky Pwhsky commented Mar 7, 2025

  • Added __future__ type hints to now use Image instead of 'Image'
  • Changed relative imports to absolute imports.

@Pwhsky Pwhsky marked this pull request as ready for review March 7, 2025 10:54
Copy link
Copy Markdown
Contributor

@cmanzo cmanzo left a comment

Choose a reason for hiding this comment

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

Replace all instances of Union[...] with |
Ensure all classes support both Image and np.ndarray, including lists of each (list[Image] and list[np.ndarray]). Update type hints in method signatures accordingly as well as in the Methods section of the docstring.

Copy link
Copy Markdown
Contributor

@cmanzo cmanzo left a comment

Choose a reason for hiding this comment

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

Remove imports of List, Dict, and other generics from typing, using built-in list, dict, etc., instead.

Copy link
Copy Markdown
Contributor

@cmanzo cmanzo left a comment

Choose a reason for hiding this comment

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

Ensure that "Examples" is always used in the plural form, consistent with "Methods" and "Parameters".

Additionally, all example code should follow the standard of importing deeptrack as dt and referencing dt.Image, etc.
@giovannivolpe please confirm that you like the latter choice

@Pwhsky
Copy link
Copy Markdown
Collaborator Author

Pwhsky commented Mar 14, 2025

Implemented feedback except for examples import statements.

I think in the examples of the image module the context is clearer if we have from deeptrack imports.

@Pwhsky Pwhsky changed the title Image.py documentation revision. docs: image Mar 14, 2025
@cmanzo
Copy link
Copy Markdown
Contributor

cmanzo commented Mar 14, 2025

Implemented feedback except for examples import statements.

I think in the examples of the image module the context is clearer if we have from deeptrack imports.

@giovannivolpe what do you think?
In most of the examples we import deeptrack as dt. Should we always use that of in some cases (like here) we can make an exception?

@giovannivolpe
Copy link
Copy Markdown
Member

giovannivolpe commented Mar 15, 2025

Ensure that "Examples" is always used in the plural form, consistent with "Methods" and "Parameters".

Additionally, all example code should follow the standard of importing deeptrack as dt and referencing dt.Image, etc. @giovannivolpe please confirm that you like the latter choice

Yes, I think it makes sense, so that readers can just cut and paste and it's clearly identified what is part of DeepTrack2.
Of course, exceptions are possible when it makes the code clearer.

@giovannivolpe
Copy link
Copy Markdown
Member

Implemented feedback except for examples import statements.
I think in the examples of the image module the context is clearer if we have from deeptrack imports.

@giovannivolpe what do you think? In most of the examples we import deeptrack as dt. Should we always use that of in some cases (like here) we can make an exception?

Yes, I think we can make exceptions if this makes the code clearer, especially when we have long names or we refer to the class being commented itself.

Copy link
Copy Markdown
Contributor

@cmanzo cmanzo left a comment

Choose a reason for hiding this comment

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

ready to merge

@giovannivolpe giovannivolpe merged commit 464893e into DeepTrackAI:develop Mar 15, 2025
25 checks passed
@Pwhsky Pwhsky deleted the docs-image branch March 15, 2025 16:13
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.

3 participants