pytorch/caffe2
Adam Simpkins e0364ccc33 [caffe2] break one circular dependency between Caffe2 and ATen-cpu (#62632)
Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/62632

Update the caffe2/core/context.h to directly use `at::mt19937` instead of the
`at::CPUGeneratorImpl` wrapper class from the ATen-cpu library.

Using `at::CPUGeneratorImpl` causes circular dependencies between the ATen and
caffe2 code.  In particular the `at::CPUGeneratorImpl::get_state()` logic
depends on CPU Tensor functionality that currently depends on code from
caffe2.

Test Plan:
The RNG behavior should be identically to the previous code (perhaps even
faster since we now avoid virtual function calls).

  buck test //caffe2/caffe2:caffe2_test_cpu \
    //caffe2/caffe2/python: //caffe2/caffe2/fb/operators:

Differential Revision: D29915701

fbshipit-source-id: f9b2eab8d3b21b2224d30bcf52be9c0e7eb7cd0a
2021-08-02 22:40:56 -07:00
..
contrib [dte] scaffolding for c2 operator broadcasting fastpath (1/x) (#62369) 2021-07-29 16:31:02 -07:00
core [caffe2] break one circular dependency between Caffe2 and ATen-cpu (#62632) 2021-08-02 22:40:56 -07:00
cuda_rtc
db Disable avoid-non-const-global-variables lint check (#62008) 2021-07-22 18:04:40 -07:00
distributed Modernize override (#61744) 2021-07-23 23:04:46 -07:00
experiments mkl_scsrmm needs to be disabled when MKL is not used (#60051) 2021-06-30 10:40:18 -07:00
ideep [dte] scaffolding for c2 operator broadcasting fastpath (1/x) (#62369) 2021-07-29 16:31:02 -07:00
image Check kernel launches in caffe2/caffe2/image (#52173) 2021-02-12 10:11:41 -08:00
mobile [PyTorch Mobile] Add continuous build config for xplat/caffe2 2020-12-09 16:58:20 -08:00
mpi Renaming CAFFE2_API to TORCH_API (#49496) 2020-12-18 10:54:50 -08:00
observers Disable avoid-non-const-global-variables lint check (#62008) 2021-07-22 18:04:40 -07:00
onnx Disable avoid-non-const-global-variables lint check (#62008) 2021-07-22 18:04:40 -07:00
operators [dte] fastpath implementations for mulgrad / divgrad (3/x) (#62437) 2021-07-30 00:05:34 -07:00
opt Fix subnet counting and re-enable check for multiple onnxifi ops in AOT (#62033) 2021-07-26 16:08:51 -07:00
perfkernels Remove AVX detection code that duplicates FindAVX.cmake (#61748) 2021-07-20 14:34:36 -07:00
predictor Disable avoid-non-const-global-variables lint check (#62008) 2021-07-22 18:04:40 -07:00
proto Fix some typing issues (#59952) 2021-06-15 14:11:06 -07:00
python [dte] fastpath implementation for broadcast utility function (4/x) (#62493) 2021-07-30 16:15:10 -07:00
quantization [dte] scaffolding for c2 operator broadcasting fastpath (1/x) (#62369) 2021-07-29 16:31:02 -07:00
queue Disable avoid-non-const-global-variables lint check (#62008) 2021-07-22 18:04:40 -07:00
serialize [Prototype] [PyTorch Edge] Speed up model loading by 12% by directly calling the C file API from FileAdapter (#61997) 2021-07-29 20:14:49 -07:00
sgd Fixed off-by-one bug in Adam Smart Decay (#62135) 2021-07-26 11:55:38 -07:00
share Disable avoid-non-const-global-variables lint check (#62008) 2021-07-22 18:04:40 -07:00
test
transforms Disable avoid-non-const-global-variables lint check (#62008) 2021-07-22 18:04:40 -07:00
utils [dte] fastpath implementation for broadcast utility function (4/x) (#62493) 2021-07-30 16:15:10 -07:00
video Forbid trailing whitespace (#53406) 2021-03-05 17:22:55 -08:00
__init__.py remediation of S205607 2020-07-17 17:19:47 -07:00
.clang-format
c2_aten_srcs.bzl Move grad_mode.h/cpp to c10. (#56204) 2021-04-16 11:50:08 -07:00
CMakeLists.txt Support system-provided Intel TBB (#61934) 2021-08-02 07:39:00 -07:00
README.md Grammar patch 1 (.md) (#41599) 2020-07-20 10:19:08 -07:00
release-notes.md Forbid trailing whitespace (#53406) 2021-03-05 17:22:55 -08:00
requirements.txt Remove references to typing module from setup.py (#47677) 2020-11-12 10:04:38 -08:00
VERSION_NUMBER

Caffe2

Jenkins Build Status

Caffe2 is a lightweight, modular, and scalable deep learning framework. Building on the original Caffe, Caffe2 is designed with expression, speed, and modularity in mind.

Questions and Feedback

Please use GitHub issues (https://github.com/pytorch/pytorch/issues) to ask questions, report bugs, and request new features.

Further Resources on Caffe2.ai