Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 11 for getNamedAttr (0.35 sec)

  1. tensorflow/compiler/mlir/tensorflow/transforms/readonly_references_to_resources.cc

            ArrayRef<Value>{},
            ArrayRef<NamedAttribute>{
                builder.getNamedAttr("device", device_attr),
                builder.getNamedAttr("container",
                                     variable_v2_op.getContainerAttr()),
                builder.getNamedAttr("shared_name",
                                     builder.getStringAttr(variable_name))});
        for (Operation *user :
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 7.8K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/tensorflow/utils/translate_utils.cc

      mlir::Builder b(module.getContext());
      auto producer =
          b.getNamedAttr("producer", b.getI32IntegerAttr(versions.producer()));
      auto min_consumer = b.getNamedAttr(
          "min_consumer", b.getI32IntegerAttr(versions.min_consumer()));
      auto bad_consumers = b.getNamedAttr(
          "bad_consumers",
          b.getI32ArrayAttr(llvm::ArrayRef<int32_t>(
              versions.bad_consumers().data(),
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri Apr 26 09:37:10 UTC 2024
    - 3.2K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/tensorflow/utils/device_util_test.cc

          mlir::ModuleOp::create(mlir::UnknownLoc::get(&context));
      mlir::Builder builder(*module_ref);
      (*module_ref)
          ->setAttr("tf.devices",
                    builder.getDictionaryAttr(builder.getNamedAttr(
                        "bad_device", builder.getDictionaryAttr({}))));
    
      mlir::TF::RuntimeDevices devices;
      EXPECT_TRUE(mlir::failed(GetDevicesFromOp(*module_ref, &devices)));
    }
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 9.5K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/tfrt/ir/tfrt_fallback_common.cc

        auto key = key_value.getName();
        auto value = key_value.getValue();
        op_attr_array.push_back(builder.getArrayAttr({key, value}));
      }
    
      result.attributes.push_back(
          builder.getNamedAttr("op_attrs", builder.getArrayAttr(op_attr_array)));
    
      // TODO(tfrt-devs): support func attributes in tfrt_fallback_sync.
      if (options.has_func_attr) {
        llvm::SmallVector<mlir::Attribute, 4> op_func_attr_array;
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 5.2K bytes
    - Viewed (0)
  5. tensorflow/compiler/mlir/tensorflow/utils/device_util.cc

        if (device->device_type() == DEVICE_GPU) {
          auto metadata = ParseGpuDeviceMetadata(*device, &builder);
          devices.push_back(builder.getNamedAttr(name, metadata));
        } else {
          auto metadata = builder.getUnitAttr();
          devices.push_back(builder.getNamedAttr(name, metadata));
        }
      }
    
      op->setAttr(kDevicesAttr, builder.getDictionaryAttr(devices));
    }
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 6.4K bytes
    - Viewed (0)
  6. tensorflow/compiler/mlir/lite/stablehlo/transforms/smuggle_disallowed_ops.cc

    //      align_corners = false, device = "", half_pixel_centers = true}
    LogicalResult SmuggleOp(Operation* op, PatternRewriter& rewriter) {
      auto call_target =
          rewriter.getNamedAttr("call_target_name", op->getName().getIdentifier());
      SmallVector<NamedAttribute> attrs{op->getAttrs()};
      attrs.push_back(call_target);
      auto custom_call = rewriter.create<mlir::stablehlo::CustomCallOp>(
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Mar 19 01:14:04 UTC 2024
    - 3.6K bytes
    - Viewed (0)
  7. tensorflow/compiler/mlir/tensorflow/utils/convert_attr.cc

          for (const auto& func_attr : value.func().attr()) {
            TF_ASSIGN_OR_RETURN(auto attr,
                                ConvertAttributeValue(func_attr.second, builder));
            attrs.push_back(builder->getNamedAttr(func_attr.first, attr));
          }
          auto func_attrs = builder->getDictionaryAttr(attrs);
          return mlir::TF::FuncAttr::get(builder->getContext(), value.func().name(),
                                         func_attrs);
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri Apr 26 09:37:10 UTC 2024
    - 4.8K bytes
    - Viewed (0)
  8. tensorflow/compiler/mlir/lite/python/jax_to_tfl_flatbuffer.cc

      }
    
      const auto& inputs = absl::StrJoin(input_names, ",");
      mlir::OpBuilder builder(*module);
      llvm::SmallVector<mlir::NamedAttribute> attrs;
      attrs.push_back(
          builder.getNamedAttr("inputs", builder.getStringAttr(inputs)));
      // Jax wrapped the output nodes in a tuple, so it's pretty hard to us
      // to tell the output at this point, we will set the output at the export
      // phase.
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Mon Mar 11 19:29:56 UTC 2024
    - 8K bytes
    - Viewed (0)
  9. tensorflow/compiler/mlir/tensorflow/transforms/xla_call_module_serialization.cc

        if (inserted) {
          function_list.push_back(called_func);
        }
    
        // Set the `called_index` attribute to the TF function's name.
        new_config.push_back(builder.getNamedAttr(
            kCalledIndexAttrName, builder.getI64IntegerAttr(it->second)));
    
        // Set the `tf.backend_config` attribute to the `new_config`.
        op->setAttr(kTfBackendConfigAttrName,
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 9.5K bytes
    - Viewed (0)
  10. tensorflow/compiler/mlir/quantization/tensorflow/passes/insert_restore_op.cc

          /*shape=*/{}, /*elementType=*/builder.getType<TF::StringType>());
      const auto file_prefix_attr = builder.getStringAttr(kTfFilePrefix);
      const auto arg_attrs = builder.getDictionaryAttr({builder.getNamedAttr(
          kTfSavedModelIndexPathAttr, builder.getArrayAttr({file_prefix_attr}))});
    
      const int insert_idx = func_op.getNumArguments();
    
      func_op.insertArgument(insert_idx, /*argType=*/filename_op_type, arg_attrs,
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Sun Mar 12 06:02:20 UTC 2023
    - 9K bytes
    - Viewed (0)
Back to top