MCPcopy Create free account
hub / github.com/MegEngine/MegEngine / Dot

Method Dot

src/opr/impl/blas.cpp:379–389  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

377MGB_DYN_TYPE_OBJ_FINAL_IMPL(Dot);
378
379Dot::Dot(VarNode* opr0, VarNode* opr1, const OperatorNodeConfig& config)
380 : Super{opr0->owner_graph(), config, "dot", {opr0, opr1}} {
381 init_megdnn_opr(*this, {});
382 add_input({opr0, opr1}, AddInputSortType::CUR_ADDED);
383 output(0)->add_flag(VarNode::Flag::ALLOW_EMPTY_SHAPE);
384 static_assert(std::is_empty<Param>::value, "Dot param should be empty");
385 mgb_assert(
386 opr0->dtype().category() != DTypeCategory::QUANTIZED &&
387 opr1->dtype().category() != DTypeCategory::QUANTIZED,
388 "Dot does not support quantized input.");
389}
390
391void Dot::init_output_static_infer_desc() {
392 using namespace cg::static_infer;

Callers 2

_matmulFunction · 0.80
dotFunction · 0.80

Calls 3

categoryMethod · 0.80
owner_graphMethod · 0.45
dtypeMethod · 0.45

Tested by

no test coverage detected