mirror of
https://github.com/zebrajr/pytorch.git
synced 2025-12-06 12:20:52 +01:00
Simplifies and optimizes dict construction using the `fromkeys` classmethod ctor. This also makes it really obvious when all the keys will have the same static value, which could be a bug if unintentional. It is also significantly faster than using a dict comprehension. The rule is in preview, but I am adding a forward fix for when it becomes stable. Pull Request resolved: https://github.com/pytorch/pytorch/pull/118637 Approved by: https://github.com/albanD |
||
|---|---|---|
| .. | ||
| types | ||
| __init__.py | ||
| autograd.py | ||
| cpp.py | ||
| dispatcher.py | ||
| functionalization.py | ||
| lazy.py | ||
| meta.py | ||
| native.py | ||
| python.py | ||
| structured.py | ||
| translate.py | ||
| ufunc.py | ||
| unboxing.py | ||