mirror of
https://github.com/saymrwulf/pytorch.git
synced 2026-05-15 21:00:47 +00:00
13 lines
308 B
C++
13 lines
308 B
C++
#include "caffe2/core/context_gpu.h"
|
|
#include "caffe2/operators/scale_op.h"
|
|
|
|
namespace caffe2 {
|
|
|
|
template <>
|
|
bool ScaleOp<CUDAContext>::RunOnDevice() {
|
|
return DispatchHelper<TensorTypes<float16, float>>::call(this, Input(0));
|
|
}
|
|
|
|
REGISTER_CUDA_OPERATOR(Scale, ScaleOp<CUDAContext>);
|
|
|
|
} // namespace caffe2
|