summaryrefslogtreecommitdiff
path: root/caffe2/queue
diff options
context:
space:
mode:
authorHenry Lu <henrylu@fb.com>2017-07-24 15:11:52 -0700
committerFacebook Github Bot <facebook-github-bot@users.noreply.github.com>2017-07-24 15:27:47 -0700
commit10667a914ed21e4ae012b5f852d55d0801547852 (patch)
treeb7fdd10106ecf7e565586413e5f24a57f3f9a1ca /caffe2/queue
parent0eda7955bdb8da11330a6e4e2b4779dbf6aa1e9a (diff)
downloadpytorch-10667a914ed21e4ae012b5f852d55d0801547852.tar.gz
pytorch-10667a914ed21e4ae012b5f852d55d0801547852.tar.bz2
pytorch-10667a914ed21e4ae012b5f852d55d0801547852.zip
Add linter for enforcing caffe operator documentation
Summary: Add check that every time we register a caffe operator to CPU or GPU that documentation is added for the particular operator. Reviewed By: dzhulgakov Differential Revision: D5443110 fbshipit-source-id: 3793c3d29bea1228078cb30bdf8243ac0ab90664
Diffstat (limited to 'caffe2/queue')
-rw-r--r--caffe2/queue/queue_ops.cc3
-rw-r--r--caffe2/queue/queue_ops_gpu.cc3
2 files changed, 0 insertions, 6 deletions
diff --git a/caffe2/queue/queue_ops.cc b/caffe2/queue/queue_ops.cc
index 1671cee237..5b8b8d5e48 100644
--- a/caffe2/queue/queue_ops.cc
+++ b/caffe2/queue/queue_ops.cc
@@ -5,8 +5,6 @@ namespace caffe2 {
CAFFE_KNOWN_TYPE(std::shared_ptr<BlobsQueue>);
-namespace {
-
REGISTER_CPU_OPERATOR(CreateBlobsQueue, CreateBlobsQueueOp<CPUContext>);
REGISTER_CPU_OPERATOR(EnqueueBlobs, EnqueueBlobsOp<CPUContext>);
REGISTER_CPU_OPERATOR(DequeueBlobs, DequeueBlobsOp<CPUContext>);
@@ -86,6 +84,5 @@ NO_GRADIENT(CloseBlobsQueue);
NO_GRADIENT(SafeEnqueueBlobs);
NO_GRADIENT(SafeDequeueBlobs);
NO_GRADIENT(WeightedSampleDequeueBlobs);
-}
}
diff --git a/caffe2/queue/queue_ops_gpu.cc b/caffe2/queue/queue_ops_gpu.cc
index 88ea6c0e4e..dbabcceb1d 100644
--- a/caffe2/queue/queue_ops_gpu.cc
+++ b/caffe2/queue/queue_ops_gpu.cc
@@ -4,8 +4,6 @@
namespace caffe2 {
-namespace {
-
REGISTER_CUDA_OPERATOR(CreateBlobsQueue, CreateBlobsQueueOp<CUDAContext>);
REGISTER_CUDA_OPERATOR(EnqueueBlobs, EnqueueBlobsOp<CUDAContext>);
REGISTER_CUDA_OPERATOR(DequeueBlobs, DequeueBlobsOp<CUDAContext>);
@@ -13,6 +11,5 @@ REGISTER_CUDA_OPERATOR(CloseBlobsQueue, CloseBlobsQueueOp<CUDAContext>);
REGISTER_CUDA_OPERATOR(SafeEnqueueBlobs, SafeEnqueueBlobsOp<CUDAContext>);
REGISTER_CUDA_OPERATOR(SafeDequeueBlobs, SafeDequeueBlobsOp<CUDAContext>);
-}
}