Search Options

Results per page
Sort
Preferred Languages
Advance

Results 31 - 40 of 55 for func_20 (0.31 sec)

  1. tensorflow/compiler/mlir/tf2xla/internal/passes/verify_clustering_pass.cc

        : public impl::VerifyClusteringPassBase<VerifyClusteringPass> {
     public:
      void runOnOperation() override;
    };
    
    void VerifyClusteringPass::runOnOperation() {
      Operation* func_op = getOperation();
    
      auto walk_result = func_op->walk([&](Operation* op) {
        if (!tensorflow::tf2xla::internal::IsInBridgeAcceptableDialects(op)) {
          std::string error = "op is in dialect " +
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Nov 08 20:33:37 UTC 2023
    - 2.6K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/tf2xla/internal/passes/input_lowering_metrics_pass.cc

     public:
      void runOnOperation() override;
    };
    
    void InputMetricsLoweringPass::runOnOperation() {
      bool has_dynamic_op = false;
      Operation* func_op = getOperation();
    
      func_op->walk([&](Operation* op) {
        auto abstractOp = op->getRegisteredInfo();
        if (!abstractOp) return WalkResult::advance();
    
        if (mlir::mhlo::IsDynamicPadderOp(abstractOp->getTypeID())) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed May 01 08:55:35 UTC 2024
    - 2.9K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/quantization/stablehlo/cc/saved_model_import.cc

      module_op->walk([&](func::FuncOp func_op) {
        FunctionName func_name = func_op.getSymName().str();
        existing_func_names.insert(func_name);
        // We may retrieve the original function's name from the attribute.
        // Functions without this attribute are ignored.
        auto original_func_name =
            func_op->getAttrOfType<StringAttr>("tf._original_func_name");
        if (original_func_name) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Apr 24 12:49:45 UTC 2024
    - 6.4K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/quantization/tensorflow/cc/convert_asset_args.cc

    // Returns a list of "tf.entry_function" attribute's "inputs" comma-split
    // values.
    //
    // Example: if `func_op` has attribute `tf.entry_function = {inputs =
    // "arg0:0,arg1:0"}`, then this function returns `{"arg0:0", "arg1:0"}`.
    SmallVector<StringRef> GetEntryFunctionInputs(func::FuncOp func_op) {
      auto entry_function_attr =
          func_op->getAttrOfType<DictionaryAttr>("tf.entry_function");
    
      SmallVector<StringRef> inputs;
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 5.4K bytes
    - Viewed (0)
  5. tensorflow/compiler/mlir/quantization/stablehlo/passes/nchw_convolution_to_nhwc.cc

    };
    
    }  // namespace
    
    void NchwConvolutionToNhwcPass::runOnOperation() {
      func::FuncOp func_op = getOperation();
      MLIRContext& ctx = getContext();
    
      RewritePatternSet patterns(&ctx);
      patterns.add<RewriteNchwConvolutionToNhwc>(&ctx);
    
      if (failed(applyPatternsAndFoldGreedily(func_op, std::move(patterns)))) {
        func_op.emitError() << "Failed to run NchwConvolutionToNhwcPass.";
        signalPassFailure();
      }
    }
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 8.2K bytes
    - Viewed (0)
  6. tensorflow/compiler/mlir/quantization/tensorflow/cc/convert_asset_args_test.cc

        EXPECT_TRUE(module_op_ref);
        return module_op_ref;
      }
    
      mlir::MLIRContext ctx_{};
    };
    
    func::FuncOp GetMainFuncOp(ModuleOp module_op) {
      for (auto func_op : module_op.getOps<func::FuncOp>()) {
        if (func_op.getSymName() == "main") {
          return func_op;
        }
      }
      return {};
    }
    
    TEST_F(ConvertAssetArgsTest, ConvertsSingleAssetArg) {
      OwningOpRef<ModuleOp> module_op = ParseModuleOpString(R"mlir(
        module {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 6.2K bytes
    - Viewed (0)
  7. tensorflow/compiler/mlir/quantization/stablehlo/passes/fold_constant_transpose.cc

    };
    
    void FoldConstantTransposePass::runOnOperation() {
      func::FuncOp func_op = getOperation();
      MLIRContext& ctx = getContext();
    
      RewritePatternSet patterns(&ctx);
      patterns.add<FoldTransposedConstantOp>(&ctx);
      if (failed(applyPatternsAndFoldGreedily(func_op, std::move(patterns)))) {
        func_op.emitError("Failed to fold constant->transpose pattern.");
        signalPassFailure();
      }
    }
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 7.7K bytes
    - Viewed (0)
  8. tensorflow/compiler/mlir/tensorflow/transforms/verify_no_outside_compilation_markers_pass.cc

      return op.getAttrOfType<StringAttr>(kXlaOutsideCompilationAttr) != nullptr;
    }
    
    void VerifyNoOutsideCompilationMarkersPass::runOnOperation() {
      Operation* func_op = getOperation();
    
      auto walk_result = func_op->walk([&](Operation* op) {
        if (IsDeviceClusterOp(*op) && HasChildLaunchDeviceOp(*op)) {
          std::string launch_error =
              absl::StrCat("Node `", op->getName().getStringRef().str(), "` ",
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Aug 22 19:52:08 UTC 2023
    - 3.5K bytes
    - Viewed (0)
  9. tensorflow/compiler/mlir/quantization/stablehlo/passes/bridge/verify_quant_legalization.cc

    }
    
    bool IsMhloUniformQuantizedOp(Operation& op) {
      return llvm::isa<mhlo::UniformQuantizeOp, mhlo::UniformDequantizeOp>(op);
    }
    
    void VerifyQuantLegalization::runOnOperation() {
      Operation* func_op = getOperation();
    
      auto walk_result = func_op->walk([&](Operation* op) {
        // Verify all uq and qint types are lowered.
        if (llvm::any_of(op->getOperandTypes(), IsQuantType) ||
            llvm::any_of(op->getResultTypes(), IsQuantType) ||
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 3.5K bytes
    - Viewed (0)
  10. tensorflow/compiler/mlir/quantization/stablehlo/cc/pre_calibration_test.cc

          component.Run(*module_op, quantization_config);
    
      EXPECT_THAT(pre_calibration_result, IsOk());
    
      SmallVector<func::FuncOp> func_ops;
      for (auto func_op : pre_calibration_result->getOps<func::FuncOp>()) {
        func_ops.push_back(func_op);
      }
      ASSERT_THAT(func_ops, SizeIs(2));
      EXPECT_THAT(func_ops, Contains(HasSymName("main")));
      EXPECT_THAT(func_ops, Contains(HasSymName("composite_dot_general_fn_1")));
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Mar 28 21:41:08 UTC 2024
    - 6K bytes
    - Viewed (0)
Back to top