Search Options

Results per page
Sort
Preferred Languages
Advance

Results 31 - 40 of 128 for dequantize (0.39 sec)

  1. tensorflow/compiler/mlir/quantization/common/quantization_lib/quantization_utils.h

            // correct float op should be the user of the last DequantizeOp.
            if (llvm::isa<QuantizeOpT>(user)) {
              user = *user->getResult(0).getUsers().begin();
            }
            if (auto dequantize = llvm::dyn_cast<DequantizeOpT>(user)) {
              // Replace all uses, except not quantizable ops that are being used in
              // the float backbone.
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Apr 24 20:30:06 UTC 2024
    - 41.7K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/lite/tests/modify_io_nodes.mlir

      %6 = "tfl.dequantize"(%5) : (tensor<1x401408x!quant.uniform<i8:f32, 3.906250e-03>>) -> tensor<1x401408xf32>
      func.return %6 : tensor<1x401408xf32>
    
    // CHECK-LABEL: func @modified(%arg0: tensor<1x224x224x3xf32>) -> tensor<1x401408xf32>
    // CHECK-NEXT: %[[shape:.*]] = arith.constant dense<[1, 401408]> : tensor<2xi32>
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu May 02 09:41:17 UTC 2024
    - 19.9K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/lite/tests/split-merged-operands.mlir

      // CHECK-DAG:  %[[CST_1:.*]] = "tfl.pseudo_const"() <{value = dense<0.000000e+00> : tensor<4x4xf16>}> : () -> tensor<4x4xf16>
      // CHECK-DAG:  %[[DQ_0:.*]] = "tfl.dequantize"(%[[CST_0]]) : (tensor<4x4xf16>) -> tensor<4x4xf32>
      // CHECK-DAG:  %[[DQ_1:.*]] = "tfl.dequantize"(%[[CST_1]]) : (tensor<4x4xf16>) -> tensor<4x4xf32>
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu May 02 09:41:17 UTC 2024
    - 7.7K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/quantization/common/quantization_lib/quantization_driver.cc

      // TODO: b/323478683 - Make the attribute being part of op definition.
      quantize->setAttr(kVolatileOpAttrName, builder_.getUnitAttr());
    
      // `original_result` has a use to `quantize`, so this will replace that use
      // by the result of `dequantize`. Remember to reset that use afterwards
      value.replaceAllUsesWith(dequantize);
      quantize.getOperation()->replaceUsesOfWith(dequantize, value);
    }
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 38.1K bytes
    - Viewed (0)
  5. tensorflow/compiler/mlir/quantization/common/uniform_quantized_types.cc

    // `tfl.quantize` or `tfl.dequantize` ops. ui8, i8 and i16 are supported.
    bool IsSupportedByTfliteQuantizeOrDequantizeOps(IntegerType storage_type) {
      if (storage_type.getWidth() == 8 ||
          (storage_type.isSigned() && storage_type.getWidth() == 16)) {
        return true;
      }
      LLVM_DEBUG(llvm::dbgs()
                 << "Uniform quantize / dequantize op only supports ui8, i8 or "
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 8.4K bytes
    - Viewed (0)
  6. tensorflow/compiler/mlir/quantization/stablehlo/passes/merge_fusion_with_dequantize.cc

            mlir::cast<ShapedType>(call_op.getResult(0).getType())
                .clone(rewriter.getF32Type()));
        rewriter.setInsertionPoint(call_op);
        rewriter.insert(new_call_op);
    
        // Remove the dequantize ops and replace uses by the new func.call op.
        SmallVector<Operation*> users_to_erase;
        for (auto user : users) {
          llvm::dyn_cast<mlir::stablehlo::UniformDequantizeOp>(user)
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 5.9K bytes
    - Viewed (0)
  7. tensorflow/compiler/mlir/lite/transforms/split_merged_operands.cc

          // Rewire the inputs.
          op->setOperand(index, duplicated_input_op->getResult(0));
        } else if (auto dq = dyn_cast<DequantizeOp>(input_op);
                   dq && matchPattern(dq.getInput(), m_Constant(&attr))) {
          // Constant -> Dequantize case.
          builder->setInsertionPoint(op);
          Operation* duplicated_input_op =
              builder->clone(*dq.getInput().getDefiningOp());
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Apr 24 20:30:06 UTC 2024
    - 5.9K bytes
    - Viewed (0)
  8. tensorflow/compiler/mlir/quantization/stablehlo/passes/quantization_patterns.h

        if (failed(candidate_ops) || candidate_ops->empty()) return failure();
    
        // Rewrite the floating-point ops to the quantized version, by fusing
        // preceding dequantize ops and succeding quantize ops.
        for (Operation* candidate_op : *candidate_ops) {
          // If it is requantize op, we shouldn't rewrite this op.
          if (isa<QuantizeOpT, DequantizeOpT>(candidate_op)) {
            return failure();
          }
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 10.9K bytes
    - Viewed (0)
  9. tensorflow/compiler/mlir/lite/transforms/prepare_quantize_dynamic_range.cc

      quant::QuantizationSpecs quant_specs_;
    };
    
    #include "tensorflow/compiler/mlir/lite/utils/generated_op_quant_spec_getters.inc"
    
    // If the weight is applicable to dynamic range quantization, insert Quantize
    // and Dequantize ops with either per-axis or per-tensor scale.
    class PrepareDynamicRangeQuantizableOp
        : public OpRewritePattern<arith::ConstantOp> {
     public:
      explicit PrepareDynamicRangeQuantizableOp(
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 20.8K bytes
    - Viewed (0)
  10. tensorflow/compiler/mlir/quantization/stablehlo/tests/components/post_calibration_component.mlir

    // CHECK-NO-UNPACK: %[[DEQUANTIZE:.+]] = stablehlo.uniform_dequantize %[[QUANTIZE_1]] : (tensor<1x3x!quant.uniform<i8:f32, {{.*}}>>) -> tensor<1x3xf32>
    // CHECK-NO-UNPACK: return %[[DEQUANTIZE]] : tensor<1x3xf32>
    
    // -----
    
    // Tests that a simple dot_general without CustomAggregators is not quantized.
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 01:09:50 UTC 2024
    - 6.7K bytes
    - Viewed (0)
Back to top