- Sort Score
- Result 10 results
- Languages All
Results 1 - 5 of 5 for IsNonConstOp (0.27 sec)
-
tensorflow/compiler/mlir/lite/experimental/tac/transforms/target_annotation.cc
SetAnnotation(op, kDevice, GetHardwareName(hardware), builder); device_is_set = true; break; } } } // default to CPU if (!device_is_set) { if (IsNonConstOp(op) && !IsTerminatorOp(op) && !llvm::isa<func::ReturnOp, func::FuncOp, CallableOpInterface>(op)) { SetAnnotation(op, kDevice, "CPU", builder); device_is_set = true; } }
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Fri May 19 19:32:06 UTC 2023 - 5.9K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/experimental/tac/common/utils.h
#include "tensorflow/compiler/mlir/lite/utils/utils.h" namespace mlir { namespace TFL { namespace tac { // Returns true if 'op' is non const op. Returns false otherwise or if // 'op' is null. inline bool IsNonConstOp(Operation* op) { if (!op) return false; if (llvm::isa<arith::ConstantOp, mlir::func::ConstantOp>(op)) return false; if (op->hasTrait<OpTrait::ConstantLike>()) return false;
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 3.5K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/experimental/tac/tflite_import_export.cc
processed_device_specs.insert( mlir::TFL::tac::GetCanonicalHardwareName(device_spec)); } processed_device_specs.insert("CPU"); module.walk([&](mlir::Operation* op) { if (!mlir::TFL::tac::IsNonConstOp(op) && !llvm::isa<func::ReturnOp, func::FuncOp, CallOpInterface>(op)) return; // Attach cost per target. // Unsupported op will have negative values.
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Jun 08 01:19:25 UTC 2023 - 4.6K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/experimental/tac/transforms/get_alternative_subgraph.cc
} bool AlternativeSubgraphPass::IsAllSupportedbySpec( func::FuncOp func, const InferenceDeviceType& device_inference_type) { bool found_unsupported = false; func.walk([&](Operation* op) { if (IsNonConstOp(op) && !IsTerminatorOp(op) && NotTFLQuantDequantizeOp(op) && !llvm::isa<func::ReturnOp, func::FuncOp, CallOpInterface>(op) && !IsSupported(op, device_inference_type.hardware)) {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Tue Jun 06 03:08:33 UTC 2023 - 12.3K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/experimental/tac/transforms/cost_model.cc
} void runOnOperation() override; }; void GetOpCostPass::runOnOperation() { auto func = getOperation(); OpBuilder builder(func); func.walk([&](Operation* op) { if (IsNonConstOp(op) && !IsTerminatorOp(op) && !llvm::isa<func::ReturnOp, func::FuncOp, CallOpInterface>(op)) { auto hardware = GetTargetAnnotation(op); if (!hardware) return;
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 7.3K bytes - Viewed (0)