Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 5 of 5 for GetQuantizationMethodOrDefault (0.29 sec)

  1. tensorflow/compiler/mlir/quantization/stablehlo/passes/insert_weight_param.cc

          return false;
        }
        Operation* user = operand.getOwner();
        if (!IsWeightOnlyQuantizableOp(*user)) {
          return false;
        }
        Method method = GetQuantizationMethodOrDefault(user);
        return HasValidWeightOnlyPtqMethod(method.weight_only_ptq(), rank);
      }
    
      void rewrite(Operation* op, PatternRewriter& rewriter) const override {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu May 09 05:56:10 UTC 2024
    - 10.2K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/quantization/common/lift_as_function_call_test.cc

          FindFirstOpFromMainFunc<TF::XlaCallModuleOp>(*module_op);
      ASSERT_TRUE(succeeded(xla_call_module_op));
    
      // Test that `GetQuantizationMethodOrDefault` returns a valid `Method`
      // corresponding to `"no_quantization {}"`.
      const Method method = GetQuantizationMethodOrDefault(*xla_call_module_op);
      EXPECT_TRUE(method.has_no_quantization());
    }
    
    TEST_F(
        LiftAsFunctionCallTest,
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri May 10 04:07:09 UTC 2024
    - 26.2K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/quantization/common/lift_as_function_call.h

    // `Method` iff the attribute doesn't exist or the attribute contains an invalid
    // textproto for `Method`. `op` must be non-null.
    ::stablehlo::quantization::Method GetQuantizationMethodOrDefault(
        absl::Nonnull<Operation*> op);
    
    // Creates a function to wrap the section between arguments and results.
    // The generated function call op type will be decided by the given call_op_type
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri May 10 04:07:09 UTC 2024
    - 5.5K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/quantization/common/lift_as_function_call.cc

        return absl::InternalError(
            absl::StrCat("Failed to parse Method from textproto: ", method_txtpb));
      }
    
      return quantization_method;
    }
    
    Method GetQuantizationMethodOrDefault(absl::Nonnull<Operation*> op) {
      absl::StatusOr<Method> method = GetQuantizationMethod(op);
      if (method.status().code() == absl::StatusCode::kInternal) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri May 17 17:58:54 UTC 2024
    - 21.8K bytes
    - Viewed (0)
  5. tensorflow/compiler/mlir/quantization/stablehlo/passes/quantization_patterns.cc

        // TODO: b/331145946 - Each quantization method should be valid
        // (GetQuantizationMethodOrDefault swallows invalid method attribute). Check
        // the validity in `match()`. Use accessors to achieve this.
        const Method quantization_method =
            GetQuantizationMethodOrDefault(xla_call_module_op);
    
        ReplaceQuantizedXlaCallModuleOpWithQuantizedCallOp(
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri May 03 06:04:36 UTC 2024
    - 41.7K bytes
    - Viewed (0)
Back to top