Commit Graph

14 Commits

Author SHA1 Message Date
75651e3cc4 Add remaining ToCs to ToC lint (#56487)
Summary:
The lint was originally added in https://github.com/pytorch/pytorch/issues/54974, but at the time I didn't realize that these other Markdown files also each have a table of contents:

- `GLOSSARY.md`
- `torch/csrc/jit/OVERVIEW.md`
- `torch/csrc/jit/docs/serialization.md`
- `torch/fx/OVERVIEW.md`

This PR adds those files to the lint, and also changes the rule from using a fixed list of filenames to a `git grep` command that finds all Markdown files containing this magic comment:

```md

```

Pull Request resolved: https://github.com/pytorch/pytorch/pull/56487

Test Plan: The "Lint / toc" job in GitHub Actions.

Reviewed By: janeyx99

Differential Revision: D27884885

Pulled By: samestep

fbshipit-source-id: 5462437502b17fba93abf5098e21754bf566a4fe
2021-04-20 10:28:47 -07:00
9bfe16a308 should_check_autodiff is now should_autodiff_node (#56013)
Summary:
The name `should_check_autodiff` became `should_autodiff_node` but documentation did not change. The identifier is used in `test/test_jit.py`. It seems the file is too big for github to link to the line, but it is the return value from `normalize_check_ad`

Pull Request resolved: https://github.com/pytorch/pytorch/pull/56013

Reviewed By: agolynski

Differential Revision: D27800008

Pulled By: Lilyjjo

fbshipit-source-id: 88a43c14c0f48fb3f94792e3fd6de2bd6a59a1a2
2021-04-15 14:49:49 -07:00
fbf7eec86d Update JIT_OPT macro for easier use (#50602)
Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/50602

Test Plan: Imported from OSS

Reviewed By: ZolotukhinM

Differential Revision: D25931371

fbshipit-source-id: cf6bc58c419a1dc0018639596b304a3a05e38360
2021-01-20 11:15:20 -08:00
559e2d8816 Implement optimization bisect (#49031)
Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/49031

Test Plan: Imported from OSS

Reviewed By: nikithamalgifb

Differential Revision: D25691790

Pulled By: tugsbayasgalan

fbshipit-source-id: a9c4ff1142f8a234a4ef5b1045fae842c82c18bf
2021-01-11 12:25:28 -08:00
c619892482 Fix errata (#49903)
Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/49903

Test Plan: Imported from OSS

Reviewed By: ngimel

Differential Revision: D25718411

Pulled By: ansley

fbshipit-source-id: 0cc365c5a53077752dc1c5a5c4a65b873baa3604
2020-12-28 20:40:41 -08:00
6c5f634657 Fix grammar and spelling errors (#46713)
Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/46713

Test Plan: Imported from OSS

Reviewed By: Lilyjjo

Differential Revision: D24477771

Pulled By: ansley

fbshipit-source-id: bc39b63ab2158a5233e48b89bfaa97a4cfb1f7a1
2020-10-23 01:31:17 -07:00
a4dbc64800 Add documentation for PYTORCH_JIT_TYPE_VERBOSITY (#42241)
Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/42241

that's it

Test Plan: docs only

Reviewed By: SplitInfinity

Differential Revision: D22818705

fbshipit-source-id: 22cdf4f23c3ed0a15c23f116457fc842d7f7b520
2020-08-06 10:39:39 -07:00
53af9df557 Unify boxed function signature between jit and c10 (#37034)
Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/37034

c10 takes a Stack* in boxed functions while JIT took Stack&.
c10 doesn't return anything while JIT returns an int which is always zero.

This changes JIT to follow the c10 behavior.
ghstack-source-id: 106834069

Test Plan: unit tests

Differential Revision: D20567950

fbshipit-source-id: 1a7aea291023afc52ae706957e9a5ca576fbb53b
2020-06-29 19:24:26 -07:00
d58b8222b7 [JIT] Add support for with statements (#34705)
Summary:
**Summary**
This commit adds support for with statements to PyTorch JIT. Each
of the with items in a with statement is represented in the JIT IR
as a pair of `prim::Enter` and `prim::Exit` nodes that call the
`__enter__` and `__exit__` methods defined on the context manager objects
returned by the expressions in the with item.

**Testing**
This commit adds unit tests for with statements with named with items,
nameless with items, and with statements that encounter exceptions.
```
$ python test/test_jit.py TestWith.test_with_as
Fail to import hypothesis in common_utils, tests are not derandomized
.
----------------------------------------------------------------------
Ran 1 test in 0.430s

OK
```

```
$ python test/test_jit.py TestWith.test_with_no_as
Fail to import hypothesis in common_utils, tests are not derandomized
.
----------------------------------------------------------------------
Ran 1 test in 0.264s

OK
```

```
$ python test/test_jit.py TestWith.test_with_exceptions
Fail to import hypothesis in common_utils, tests are not derandomized
Couldn't download test skip set, leaving all tests enabled...
.
----------------------------------------------------------------------
Ran 1 test in 1.053s

OK
```
Pull Request resolved: https://github.com/pytorch/pytorch/pull/34705

Differential Revision: D22095945

Pulled By: SplitInfinity

fbshipit-source-id: f661565a834786725259b8ea014b4d7532f9419d
2020-06-18 16:57:18 -07:00
16e3df3ac6 Fix typo: TupleUnpack. (#38043)
Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/38043

Fixes https://github.com/pytorch/pytorch/issues/37183

Signed-off-by: Edward Z. Yang <ezyang@fb.com>

Test Plan: Imported from OSS

Differential Revision: D21471000

Pulled By: ezyang

fbshipit-source-id: feea7021a23a68053db32ef02751e97e1b61ca8f
2020-05-07 20:57:20 -07:00
fbf110293d jit/OVERVIEW.md: screen * in 'Node*' for proper rendering. (#37686)
Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/37686

Test Plan: Imported from OSS

Reviewed By: jamesr66a

Differential Revision: D21358819

Pulled By: ZolotukhinM

fbshipit-source-id: 6425786f3b19d6b3d51c8d5386c3ab31d4344959
2020-05-01 14:44:37 -07:00
f4532d7542 Fix typo (#33925)
Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/33925

Differential Revision: D20171970

Pulled By: vincentqb

fbshipit-source-id: 5c1a8553760f74cecebaea7e88463b767ab81211
2020-03-02 08:13:55 -08:00
8f84deddd1 [jit] fix up refs in overview.md (#33919)
Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/33919

Test Plan: Imported from OSS

Differential Revision: D20154953

Pulled By: suo

fbshipit-source-id: 2ef83cce8da88212bed7edc813c9b233267ea81b
2020-02-27 19:22:51 -08:00
d6485b411b [jit] add top-level readme to csrc/jit (#33916)
Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/33916

Test Plan: Imported from OSS

Differential Revision: D20150771

Pulled By: suo

fbshipit-source-id: c7550954ddd6a294ce833348bf9fa058503e9bd7
2020-02-27 19:21:05 -08:00