Search Options

Results per page
Sort
Preferred Languages
Advance

Results 151 - 160 of 345 for setLoc (0.13 sec)

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

          if (!dict_attr) continue;
    
          OpBuilder builder(func.getContext());
          builder.setInsertionPointToStart(&func.getBlocks().front());
          builder.create<TFL::CallOnceOp>(func.getLoc(), init_func_op.getName());
        }
      }
    }
    
    }  // namespace
    
    // Inserts a TFL::CallOnce op when tf_saved_model's session initializer is
    // given.
    std::unique_ptr<OperationPass<ModuleOp>>
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Feb 01 05:03:09 UTC 2023
    - 2.5K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/tfrt/ir/tfrt_fallback_async.cc

                  operand.getDefiningOp<corert::ConstDenseTensorOp>()) {
            new_values.push_back(
                rewriter.create<fallback_async::ConstDenseTensorOp>(
                    op.getLoc(), rewriter.getType<fallback::TFTensorType>(),
                    corert_const_dense_tensor_op.getValue()));
            should_rewrite = true;
            continue;
          }
          if (auto corert_const_string_tensor_op =
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Jun 08 01:19:25 UTC 2023
    - 15.6K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/tf2xla/internal/passes/tpu_cluster_formation.cc

            // and once existing cases have been fixed.
            mlir::InFlightDiagnostic error =
                strict_clusters ? mlir::emitError(op.getLoc(), "")
                                : mlir::emitWarning(op.getLoc(), "");
            error << "Op has cyclic dependency with a compilation cluster:\n";
            error << "The cluster depends on\n";
            error << op.getName() << "\n"
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu May 02 22:03:30 UTC 2024
    - 39.3K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/tensorflow/transforms/host_runtime/tpu_merge_variables_with_execute.cc

      auto merged_execute_launch = builder->create<tf_device::LaunchOp>(
          merged_execute.getLoc(), execute_launch.getDeviceAttr(),
          merged_execute.getResultTypes());
      merged_execute_launch.getBody().push_back(new Block);
    
      builder->setInsertionPointToEnd(&merged_execute_launch.GetBody());
      builder->create<tf_device::ReturnOp>(merged_execute.getLoc(),
                                           merged_execute.getResults());
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Feb 29 17:52:11 UTC 2024
    - 27K bytes
    - Viewed (0)
  5. tensorflow/compiler/mlir/quantization/stablehlo/passes/fold_constant_transpose.cc

            transposer.TransposeValues(original_values);
    
        // Create a new constant op with the transposed values.
        const Location combined_loc =
            rewriter.getFusedLoc({const_op.getLoc(), op.getLoc()});
        auto new_value_type =
            RankedTensorType::getChecked(combined_loc, transposer.GetTargetShape(),
                                         /*elementType=*/rewriter.getF32Type());
        auto new_value_attr =
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 7.7K bytes
    - Viewed (0)
  6. tensorflow/compiler/mlir/tf2xla/transforms/utils.h

      Block* block = builder->createBlock(body);
    
      // Block arguments are scalars of the given element type.
      Type type = RankedTensorType::get(/*shape=*/{}, element_type);
      Location loc = body->getLoc();
      block->addArguments({type, type}, SmallVector<Location, 2>(2, loc));
    
      auto reducer =
          builder->create<Op>(loc, block->getArgument(0), block->getArgument(1));
      builder->create<ReturnOp>(loc, reducer.getResult());
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Sep 06 19:12:29 UTC 2023
    - 2.3K bytes
    - Viewed (0)
  7. tensorflow/compiler/mlir/tensorflow/transforms/region_control_flow_to_functional.cc

        if (existing) return *existing;
      }
    
      ModuleOp module = region.getParentOfType<ModuleOp>();
      OpBuilder builder(module.getContext());
      auto loc = region.getParentOp()->getLoc();
      Block& entry = region.front();
      int num_region_arguments = entry.getNumArguments();
      Operation* terminator = entry.getTerminator();
    
      // Build the function type. Region arguments and extern values together
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 28.7K bytes
    - Viewed (0)
  8. tensorflow/compiler/mlir/tensorflow/ir/tf_ops_canonicalization_helper.h

    // another TF op.
    // TODO(jpienaar): This is a workaround until behavior is established.
    template <typename OpTy, typename... Args>
    OpTy CreateTfOp(RewriterBase &b, Operation *op, Args &&...args) {
      auto ret = b.create<OpTy>(op->getLoc(), std::forward<Args>(args)...);
      CopyDeviceAndUnderscoredAttributes(op, ret.getOperation());
      return ret;
    }
    
    // Helper function to replace TF op with another op while copying all underscore
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri Nov 12 21:57:12 UTC 2021
    - 2.4K bytes
    - Viewed (0)
  9. tensorflow/compiler/mlir/tf2xla/transforms/tfxla_device_specific_transforms.cc

      tensorflow::Algorithm tensorflow_rng =
          tensorflow::ToTensorflowAlgorithm(xla_rng);
    
      OpBuilder opbuilder(get_alg_op);
    
      auto tf_const = opbuilder.create<TF::ConstOp>(
          get_alg_op->getLoc(), opbuilder.getI32IntegerAttr((int)tensorflow_rng));
    
      get_alg_op->replaceAllUsesWith(tf_const);
      get_alg_op->erase();
      return success();
    }
    
    void TFXLADeviceSpecificTransforms::runOnOperation() {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri Mar 03 05:56:39 UTC 2023
    - 3.1K bytes
    - Viewed (0)
  10. tensorflow/compiler/mlir/lite/stablehlo/transforms/legalize_hlo_conversions/custom_call.cc

    LogicalResult ConvertCustomCallOp::matchAndRewrite(
        mhlo::CustomCallOp mhlo_custom_call, OpAdaptor adaptor,
        ConversionPatternRewriter& rewriter) const {
      auto tfl_custom = rewriter.create<TFL::CustomOp>(
          mhlo_custom_call.getLoc(), mhlo_custom_call.getResultTypes(),
          mhlo_custom_call.getInputs());
      tfl_custom.setCustomCodeAttr(
          rewriter.getStringAttr(mhlo_custom_call.getCallTargetName()));
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 2.3K bytes
    - Viewed (0)
Back to top