-
Notifications
You must be signed in to change notification settings - Fork 24.8k
[typing] Add type hints to __init__
methods in torch.distributions
.
#144197
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
Closed
randolf-scholz
wants to merge
39
commits into
pytorch:main
from
randolf-scholz:distributions_type_hint_init
Closed
Changes from 1 commit
Commits
Show all changes
39 commits
Select commit
Hold shift + click to select a range
ef2329f
added type hints to lazy_property
randolf-scholz 0937a2a
added type hints to lazy_properties & simplified 'torch.Tensor' hints…
randolf-scholz 61366fe
fixed typing errors
randolf-scholz 1fc1bd9
replace 'Dict' with 'dict'
randolf-scholz aa3c769
replace 'Tuple' with 'tuple'
randolf-scholz dac5f4d
replace 'Type' with 'type'
randolf-scholz a9f72e1
fixed typing of transform._inv
randolf-scholz 9e9a1bb
fixed circular import
randolf-scholz 092be0b
added unit test
randolf-scholz def92d5
lintrunner fixes
randolf-scholz 6e54911
added type hints for __init__ signatures
randolf-scholz d568418
replaced Any with more concrete type in Distribution.support
randolf-scholz <
8000
relative-time datetime="2025-01-04T18:29:04Z" class="no-wrap">Jan 4, 2025
6c5c878
Merge branch 'annotate_dist_properties' into distributions_type_hint_…
randolf-scholz d250c91
added second typevar to lazy_property
randolf-scholz 14c0db1
Merge branch 'annotate_dist_properties' into distributions_type_hint_…
randolf-scholz c5a4d02
use typing.Union for 3.9 compat
randolf-scholz 64d9269
wishart.py: use Tensor instead of torch.Tensor annotation
randolf-scholz b2852f6
merged
randolf-scholz 9ca3df5
use typing.Union for 3.9 compat
randolf-scholz dc1010d
added missing type hints
randolf-scholz 70b0634
added missing type hints and fixed type error
randolf-scholz a028526
use typing.Union for 3.9 compat
randolf-scholz 98d12c3
wishart.py added missing type hint
randolf-scholz 4da39a8
fixed torch.Size related failure
randolf-scholz e18d00a
fixed missing type hint for cache_size
randolf-scholz 9c8c6ba
Update torch/distributions/geometric.py
randolf-scholz 7656785
added missing type hint in CatTransform.__init__
randolf-scholz c9f1516
Merge branch 'main' into distributions_type_hint_init
randolf-scholz 92f07f6
made distributiions.Independent a generic class of the base distribut…
randolf-scholz 5dd4a6b
Merge branch 'main' into distributions_type_hint_init
randolf-scholz dad0e1d
removed non-typing changes
randolf-scholz ce07b51
removed unused type: ignore comments
randolf-scholz c344806
updated binomial
randolf-scholz a5e7396
merged main
randolf-scholz 9caeb08
Merge branch 'main' into distributions_type_hint_init
randolf-scholz 3924079
lintrunner fixes
randolf-scholz 212325e
use assert logits is not None instead of elif branch
randolf-scholz 0116bfc
removed spurious newlines
randolf-scholz aafae2d
Merge branch 'main' into distributions_type_hint_init
randolf-scholz File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
wishart.py: use Tensor instead of torch.Tensor annotation
- Loading branch information
commit 64d9269011d11f82179859b3b997b86ea703679c
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.