XNNPackLinearOpContext Class — pytorch Architecture
Architecture documentation for the XNNPackLinearOpContext class in OpContext.h from the pytorch codebase.
Entity Profile
Source Code
aten/src/ATen/native/xnnpack/OpContext.h lines 56–83
class XNNPackLinearOpContext final : public LinearOpContext {
private:
ContextLinear op_context_;
public:
XNNPackLinearOpContext(
Tensor&& weight,
std::optional<Tensor>&& bias,
const std::optional<Scalar>& min,
const std::optional<Scalar>& max,
ContextLinear&& op_context)
: op_context_(std::move(op_context)) {
orig_weight_ = std::move(weight);
orig_bias_ = std::move(bias);
output_min_ = min;
output_max_ = max;
orig_weight_and_bias_freed_ = false;
}
Tensor run(const Tensor& input) override;
void free_orig_weight_and_bias() override;
static c10::intrusive_ptr<LinearOpContext> create_context(
Tensor&& weight,
std::optional<Tensor>&& bias,
const std::optional<Scalar>& output_min,
const std::optional<Scalar>& output_max);
};
Source
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free