Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 6 of 6 for QConstOp (0.29 sec)

  1. tensorflow/compiler/mlir/lite/transforms/dense_to_sparse.cc

            supported_block_size = sparse_op.GetFloatBlockSize();
            type = mlir::cast<ShapedType>(dyn_cast<ConstOp>(inst).getType());
          } else if (isa<QConstOp>(inst)) {
            supported_block_size = sparse_op.GetQuantizedBlockSize();
            type = mlir::cast<ShapedType>(dyn_cast<QConstOp>(inst).getType());
            ratio_threshold = kBlockOverRandomSparsityRatioQuant;
          } else {
            continue;
          }
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 16.1K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/lite/transforms/post_quantize.cc

      LogicalResult matchAndRewrite(TransposeOp op,
                                    PatternRewriter& rewriter) const override {
        Operation* def_op = op.getInput().getDefiningOp();
        auto qconst_op = llvm::dyn_cast_or_null<QConstOp>(def_op);
        if (qconst_op == nullptr) return failure();
    
        DenseIntElementsAttr perm_tensor;
        if (!matchPattern(op.getPerm(), m_Constant(&perm_tensor))) return failure();
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 17.1K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/lite/experimental/tac/hardwares/target_hardware.cc

    inline bool IsNonArithmeticOp(mlir::Operation* op) {
      if (llvm::isa<func::ReturnOp, func::FuncOp>(op)) return true;
      if (op->hasTrait<OpTrait::ConstantLike>()) return true;
      if (llvm::isa<QConstOp, SparseQConstOp>(op)) return true;
      if (!NotTFLQuantDequantizeOp(op)) return true;
      return false;
    }
    
    }  // namespace
    
    bool TargetHardware::Init() {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue May 09 21:39:59 UTC 2023
    - 9.9K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/lite/transforms/quantize.cc

          } else {
            quantized_attr = quant::Quantize(attr, qtype.getValue());
          }
          if (quantized_attr) {
            rewriter.replaceOpWithNewOp<QConstOp>(op, qtype, quantized_attr);
            return success();
          }
        }
        return failure();
      }
    
     private:
      bool legacy_float_scale_;
    };
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Apr 24 20:30:06 UTC 2024
    - 13.3K bytes
    - Viewed (0)
  5. tensorflow/compiler/mlir/lite/transforms/while_loop_outline.cc

        // Sink down constants (including quantized constant) into the functions.
        for (auto extern_value : region_extern_values) {
          if (!matchPattern(extern_value, m_Constant()) &&
              !llvm::dyn_cast_or_null<TFL::QConstOp>(
                  extern_value.getDefiningOp())) {
            extern_values.insert(extern_value);
            continue;
          }
          // Add constant at start of region.
          auto const_builder =
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 11.8K bytes
    - Viewed (0)
  6. tensorflow/compiler/mlir/lite/transforms/legalize_tf.cc

      target.addLegalOp<mlir::func::ConstantOp>();
      target.addLegalOp<TFL::NoValueOp>();
      target.addLegalOp<ConstOp>();
      target.addLegalOp<DequantizeOp>();
      target.addLegalOp<QConstOp>();
      if (run_tfl_runtime_verification_) {
        target.addDynamicallyLegalDialect<TensorFlowLiteDialect>([](Operation* op) {
          auto tfl_op = dyn_cast_or_null<TflRuntimeVerifyOpInterface>(op);
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Mon May 20 20:06:54 UTC 2024
    - 45.2K bytes
    - Viewed (0)
Back to top