Commit Graph

4 Commits

Author SHA1 Message Date
Bugra Akyildiz
27c7158166 Remove __future__ imports for legacy Python2 supports (#45033)
Summary:
There is a module called `2to3` which you can target for future specifically to remove these, the directory of `caffe2` has the most redundant imports:

```2to3 -f future -w caffe2```

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

Reviewed By: seemethere

Differential Revision: D23808648

Pulled By: bugra

fbshipit-source-id: 38971900f0fe43ab44a9168e57f2307580d36a38
2020-09-23 17:57:02 -07:00
Alexander Melnikov
eb2c5930b2 contrib-tensorboard: removed external tensorboardX dependency (#25259)
Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/25259

Switching to tensorboard instead of tensorflow

Test Plan: went through instructions in [fbsource/fbcode/caffe2/caffe2/contrib/tensorboard/tensorboard.md] to make sure everything is working (using/not using tensorboard/tensorflow)

Reviewed By: orionr

Differential Revision: D17059111

fbshipit-source-id: aaa26dec840fb517b3bc7dc988f3a8c54566d356
2019-08-28 13:55:25 -07:00
Dmytro Dzhulgakov
3af2d6d904 Enforce import order to make protobuf cpp implementation in python work (#18560)
Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/18560

We have to import python protobuf here **before** we load cpp extension.
Otherwise it breaks under certain build conditions if cpp implementation of
protobuf is used. Presumably there's some registry in protobuf library and
python side has to initialize the dictionary first, before static
initialization in python extension does so. Otherwise, duplicated protobuf
descriptors will be created and it can lead to obscure errors like

  Parameter to MergeFrom() must be instance of same class: expected caffe2.NetDef got caffe2.NetDef.

I think it also fixes https://github.com/facebookarchive/caffe2/issues/1573

Reviewed By: ezyang, iroot900

Differential Revision: D14622054

fbshipit-source-id: 2499eb88ecdee85ff8d845859048f7ae5da2a480
2019-04-03 13:17:08 -07:00
Jesse Hellemn
07904eaed9 Moving tensorboard to OSS
Summary: Moving tensorboard from fb specific and untying all dependencies on fb code

Reviewed By: dzhulgakov

Differential Revision: D6313818

fbshipit-source-id: 19302c372540400fa60d34015ef9e944ab203d2e
2017-12-03 19:18:01 -08:00