Search Options

Results per page
Sort
Preferred Languages
Advance

Results 41 - 50 of 103 for SetAttr (0.52 sec)

  1. tensorflow/compiler/mlir/lite/transforms/dilated_conv.h

                  addtional_pad !=
              bts_crops_attr.getValues<APInt>()[{i, j}].getSExtValue()) {
            op->setAttr("padding", rewriter.getStringAttr("SAME"));
            break;
          }
        }
      }
    
      // Set dilations
      op->setAttr("dilations", dilations_attr.value());
    
      if (expand_op) {
        // If there is `expand_op`, we need to rewire the inputs to bypass the
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 20K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/quantization/stablehlo/passes/lift_quantizable_spots_as_functions.cc

          if (!matcher.Match(xla_call_module_op)) continue;
    
          // Set the text representation of `Method` to matched
          // `TF::XlaCallModuleOp`.
          xla_call_module_op->setAttr(
              kQuantizationMethodAttr,
              StringAttr::get(module_op.getContext(),
                              std::move(*quantization_method_txtpb)));
        }
      }
      return success();
    }
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri May 10 04:07:09 UTC 2024
    - 9.3K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/tensorflow/utils/attribute_utils.h

    template <typename Predicate>
    void CopyAttributes(Operation *from, Operation *to, Predicate P) {
      for (const NamedAttribute &attr : from->getAttrs())
        if (P(attr)) to->setAttr(attr.getName(), attr.getValue());
    }
    
    // Copies attributes whose name begins with an _ from `from` to `to`.
    inline void CopyUnderscoredAttributes(Operation *from, Operation *to) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed May 22 19:47:48 UTC 2024
    - 8.7K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/lite/utils/lstm_utils_test.cc

      }
    
      if (cifg) {
        attributes.push_back(kCoupleInputForgetGates);
      }
    
      mlir::StringAttr attr_values =
          builder->getStringAttr(llvm::join(attributes, ","));
    
      func->setAttr(kTFImplements, attr_values);
      return func;
    }
    
    class LstmUtilsTest : public ::testing::Test {
     protected:
      LstmUtilsTest() {}
    
      void SetUp() override {
        context_ = std::make_unique<mlir::MLIRContext>();
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 10K bytes
    - Viewed (0)
  5. tensorflow/compiler/mlir/lite/transforms/lift_tflite_flex_ops.cc

                values.push_back(range.second - range.first);
              }
              auto attr_value =
                  mlir::DenseI32ArrayAttr::get(tf_op->getContext(), values);
              tf_op->setAttr(attr_name, attr_value);
            };
        if (tf_op->hasTrait<mlir::OpTrait::AttrSizedOperandSegments>() ||
            tf_op->hasTrait<mlir::OpTrait::AttrSizedResultSegments>()) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 10.9K bytes
    - Viewed (0)
  6. tensorflow/compiler/mlir/tensorflow/ir/tf_ops_a_m.cc

      if (failed(::mlir::TF::UpdateDataFormat(data_format, this))) return failure();
    
      // Update convolution attributes.
      (*this)->setAttr("dilations", ShuffleArrayAttr(getDilations(), perm));
      (*this)->setAttr("strides", ShuffleArrayAttr(getStrides(), perm));
      (*this)->setAttr("explicit_paddings",
                       ShuffleArrayAttr(getExplicitPaddings(), perm, 2));
    
      return success();
    }
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 146.7K bytes
    - Viewed (0)
  7. tensorflow/compiler/mlir/quantization/tensorflow/passes/preprocess_op.cc

        new_float_func.setType(FunctionType::get(
            getContext(), TypeRange{ValueRange{new_float_func_args}},
            new_float_func.getResultTypes()));
        symbol_table.insert(new_float_func);
    
        op->setAttr("f", SymbolRefAttr::get(rewriter.getContext(),
                                            new_float_func.getName()));
    
        return success();
      }
    
      LogicalResult matchAndRewrite(TF::PartitionedCallOp op,
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 11.4K bytes
    - Viewed (0)
  8. tensorflow/compiler/mlir/tensorflow/translate/tf_mlir_translate.cc

                continue;
              }
              auto new_attr = mlir::DenseElementsAttr::get(
                  llvm::cast<mlir::ShapedType>(attr.getType()), rand_val);
              inst.setAttr(attr_id, new_attr);
            }
          }
        }
      }
      return module_or;
    }
    
    absl::StatusOr<mlir::OwningOpRef<mlir::ModuleOp>>
    GraphdefToSplattedMlirTranslateFunction(
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue May 07 11:51:44 UTC 2024
    - 14.1K bytes
    - Viewed (0)
  9. tensorflow/compiler/mlir/tensorflow/translate/import_model.cc

              /*type=*/mlir::TypeAttr::get(value_attr.getType()),
              /*is_mutable=*/nullptr);
          op->setAttr(
              kTfSavedModelExportedNamesAttr,
              builder.getStrArrayAttr(object_names.GetExportedNames(node_id)));
        }
      }
      AdjustBoundInputArgTypes(module);
      module->setAttr("tf_saved_model.semantics", builder.getUnitAttr());
      SortSavedModelModule(module);
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed May 01 11:17:36 UTC 2024
    - 183.2K bytes
    - Viewed (0)
  10. tensorflow/compiler/mlir/quantization/common/quantization_lib/quantization_utils.h

            }
    
            rewriter.setInsertionPoint(quantizing_op);
            Operation* float_op = rewriter.clone(*quantizing_op);
            quantizing_op->setAttr(kDebugModeOpQuantAttrName,
                                   rewriter.getUnitAttr());
            float_op->setAttr(kDebugModeOpFloatAttrName, rewriter.getUnitAttr());
            RewireFloatModelBackbone(quantizing_op, float_op);
            return success();
          }
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Apr 24 20:30:06 UTC 2024
    - 41.7K bytes
    - Viewed (0)
Back to top