Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 13 for populateWithGenerated (0.64 sec)

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

                           custom_op_map_);
      }
    
      RewritePatternSet patterns(&getContext());
      auto func = getOperation();
      auto* ctx = func.getContext();
      TFL::populateWithGenerated(patterns);
      patterns.add<quant::FoldTrivalRequantizeOp<QuantizeOp>>(ctx);
      patterns.add<PruneUnusedOpsWithSideEffect<TFL::LSTMOp>>(ctx);
      patterns.add<PruneUnusedOpsWithSideEffect<TFL::UnidirectionalSequenceLSTMOp>>(
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 17.1K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/quantization/tensorflow/passes/prepare_quantize_drq.cc

    void PrepareQuantizeDRQPass::runOnOperation() {
      MLIRContext* ctx = &getContext();
      RewritePatternSet patterns(ctx);
      ModuleOp module_op = getOperation();
    
      populateWithGenerated(patterns);
      patterns.add<PrepareDRQQuantizableOp>(ctx, quant_specs_, op_set_,
                                            enable_per_channel_quantization_);
      FrozenRewritePatternSet frozen_patterns(std::move(patterns));
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 11.5K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/lite/transforms/quantize.cc

      }
    
      const quant::QuantPassSpec quant_params = {
          {quant_specs.verify_numeric, error_tolerance_,
           quant_specs.whole_model_verify, enable_log_if_failed_},
          quant_specs};
    
      populateWithGenerated(patterns);
    
      if (quant_specs.weight_quantization || quant_specs.use_fake_quant_num_bits ||
          quant_specs.qdq_conversion_mode ==
              quant::QDQConversionMode::kQDQDynamic) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Apr 24 20:30:06 UTC 2024
    - 13.3K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/quantization/tensorflow/passes/convert_tf_xla_op_to_tf_op.cc

      auto func = getOperation();
    
      // The pattern includes
      // - Converting XlaDotV2Op to EinsumOp
      // - Converting XlaGatherOp to SliceOp
      RewritePatternSet patterns(ctx);
      populateWithGenerated(patterns);
    
      if (failed(applyPatternsAndFoldGreedily(func, std::move(patterns)))) {
        func.emitError() << "quant-converting-tf-xla-op-to-tf-op failed.";
        signalPassFailure();
      }
    }
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 13.2K bytes
    - Viewed (0)
  5. tensorflow/compiler/mlir/lite/transforms/legalize_tensorlist.cc

                          "all can be supported."
                       << "\n";
          return;
        }
        RewritePatternSet patterns(&getContext());
        populateWithGenerated(patterns);
        patterns.add<ConvertTensorListPopBack>(&getContext());
        patterns.add<ConvertTensorListPushBack>(&getContext());
        patterns.add<ConvertVariantAddNOp>(&getContext());
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue May 07 23:04:40 UTC 2024
    - 10.6K bytes
    - Viewed (0)
  6. tensorflow/compiler/mlir/quantization/tensorflow/passes/preprocess_op.cc

    void PreprocessOpPass::runOnOperation() {
      MLIRContext* ctx = &getContext();
      RewritePatternSet patterns(ctx);
      ModuleOp module_op = getOperation();
    
      populateWithGenerated(patterns);
      patterns.add<PreprocessConstantOp>(ctx, op_set_, quantization_method_,
                                         enable_per_channel_quantization_);
      FrozenRewritePatternSet frozen_patterns(std::move(patterns));
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 11.4K bytes
    - Viewed (0)
  7. tensorflow/compiler/mlir/quantization/tensorflow/passes/prepare_lifting.cc

      auto func = getOperation();
    
      // The pattern includes decomposing batch normalization ops, fusing add/mul
      // with a constant operand to a preceding affine operation.
      RewritePatternSet patterns(ctx);
      populateWithGenerated(patterns);
      patterns.add<RemoveIdentity, ConstantFoldQuantizableOperands>(ctx);
      if (op_set_ != OpSet::XLA) {
        // Convert Einsum into BatchMatMul for non-XLA opsets.
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri May 17 17:58:54 UTC 2024
    - 13.3K bytes
    - Viewed (0)
  8. tensorflow/compiler/mlir/quantization/tensorflow/passes/lift_quantizable_spots_as_functions.cc

    void LiftQuantizableSpotsAsFunctionsPass::runOnOperation() {
      MLIRContext* ctx = &getContext();
      RewritePatternSet patterns(ctx);
      ModuleOp module = getOperation();
    
      populateWithGenerated(patterns);
      patterns.add<CheckQuantizableOps>(ctx, quant_options_);
      FrozenRewritePatternSet frozen_patterns(std::move(patterns));
    
      // Iterate over the sorted list of functions to keep the order deterministic.
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri May 10 04:07:09 UTC 2024
    - 16.4K bytes
    - Viewed (0)
  9. tensorflow/compiler/mlir/lite/quantization/tensorflow/fallback_to_flex_ops.cc

      if (mode_.empty()) return;
    
      func::FuncOp func = getOperation();
      MLIRContext *ctx = &getContext();
    
      // Convert binary ops to BiasAdd ops if possible.
      RewritePatternSet patterns(ctx);
      populateWithGenerated(patterns);
      (void)applyPatternsAndFoldGreedily(func, std::move(patterns));
    
      // Convert unsupported ops to Flex ops.
      auto tf_dialect = ctx->getLoadedDialect<TF::TensorFlowDialect>();
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 12.2K bytes
    - Viewed (0)
  10. tensorflow/compiler/mlir/tfr/passes/decompose.cc

    #include "tensorflow/compiler/mlir/tfr/passes/generated_decompose.inc"
    
    void DecomposeTFOpsPass::ApplyCanonicalization() {
      func::FuncOp func = getOperation();
      RewritePatternSet patterns(&getContext());
    
      populateWithGenerated(patterns);
      populateCanonicalizationPatterns(func, patterns);
    
      (void)applyPatternsAndFoldGreedily(func, std::move(patterns));
    }
    
    LogicalResult DecomposeTFOpsPass::RewriteUnregisteredTFOps() {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 14.6K bytes
    - Viewed (0)
Back to top