1 #include "caffe2/operators/quantized/int8_leaky_relu_op.h" 5 REGISTER_CPU_OPERATOR(Int8LeakyRelu, int8::Int8LeakyReluOp);
7 OPERATOR_SCHEMA(Int8LeakyRelu)
10 .Arg(
"alpha",
"Coefficient of leakage, default value is 0.01")
11 .Arg(
"Y_scale",
"Output tensor quantization scale")
12 .Arg(
"Y_zero_point",
"Output tensor quantization offset")
13 .AllowInplace({{0, 0}})
14 .CostInferenceFunction(PointwiseCostInference<2>)
15 .IdenticalTypeAndShape()
17 LeakyRelu takes input data (Tensor<T>) and an argument alpha, and produces one 18 output data (Tensor<T>) where the function `f(x) = alpha * x for x < 0`, 19 `f(x) = x for x >= 0`, is applied to the data tensor elementwise. 21 .Input(0, "X",
"1D input tensor")
22 .Output(0,
"Y",
"1D input tensor");
A global dictionary that holds information about what Caffe2 modules have been loaded in the current ...