- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 11 for set_shape (0.24 sec)
-
tensorflow/compiler/mlir/tensorflow/ir/tf_ops_a_m.cc
if (s0_shape == s1_shape) return; for (int i = bcasted_shape.size(); i > 0; --i) { int idx = bcasted_shape.size() - i; int s0_idx = i > s0_shape.size() ? -1 : s0_shape.size() - i; int s1_idx = i > s1_shape.size() ? -1 : s1_shape.size() - i; if (s0_idx == -1) { r0.push_back(idx); if (s1_shape[s1_idx] == 1) r1.push_back(idx); } else if (s1_idx == -1) {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 146.7K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/transforms/optimize.cc
// only when height = width. if (params_type.getShape().size() != 4 || indices_type.getShape().size() != 2) return failure(); if (params_type.getShape()[1] != 1) return failure(); if (params_type.getShape()[0] != params_type.getShape()[2]) return failure(); if (result_type.getShape()[0] != params_type.getShape()[0] * 2) return failure();
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Tue Apr 30 00:40:15 UTC 2024 - 102.3K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/ir/tfl_ops.cc
value_attr.getValues<Attribute>()[outer_index * inner_dims_size + i]); } } std::vector<int64_t> new_shape = value_attr.getType().getShape().vec(); new_shape[0] = lookup_attr.getType().getShape()[0]; auto new_type = value_attr.getType().clone(new_shape); return DenseElementsAttr::get(new_type, new_values); }
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu May 02 09:41:17 UTC 2024 - 169.2K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/ir/tf_ops_n_z.cc
} else { output_ty = tensorflow::GetTypeFromTFTensorShape( {static_cast<int64_t>(sub_shape.size())}, output_elt_ty); } } // Down-cast to 32 bit int if needed. if (output_elt_ty.isInteger(32)) { SmallVector<int32_t, 2> sub_shape_i32(sub_shape.size()); std::transform(sub_shape.begin(), sub_shape.end(), sub_shape_i32.begin(), [](int64_t d) { return static_cast<int32_t>(d); });
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu May 09 22:07:10 UTC 2024 - 170.8K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/stablehlo/transforms/uniform_quantized_stablehlo_to_tfl_pass.cc
/*shape=*/new_shape, /*type=*/new_filter_quantized_type); } else if (element_type.isa<UniformQuantizedType>()) { auto per_tensor_type = element_type.cast<UniformQuantizedType>(); new_filter_result_type = RankedTensorType::getChecked(location, /*shape=*/new_shape,
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Mon Apr 22 09:00:19 UTC 2024 - 99.8K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/shape_inference.cc
SmallVector<int64_t> new_shape(shape.begin(), shape.end()); // If dimension of the input type is dynamic. Update the // bounds of the dim with the new type if needed. for (int i = 0; i < input_ty.getShape().size(); i++) { if (hlo::isDynamicDimSize(input_ty.getShape()[i])) { new_bounds[i] = new_shape[i]; new_shape[i] = ShapedType::kDynamic; } }
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Sat Jun 08 07:28:49 UTC 2024 - 134.1K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/stablehlo/transforms/legalize_hlo.cc
// Reshape input image to add a new spatial dimension. auto image_type = mlir::cast<ShapedType>(conv_op.getLhs().getType()); SmallVector<int64_t, 4> image_2d_shape(image_type.getShape().begin(), image_type.getShape().end()); image_2d_shape.push_back(1); auto image_2d_type = RankedTensorType::get(image_2d_shape, image_type.getElementType()); auto loc = conv_op.getLoc();
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 154.9K bytes - Viewed (0) -
tensorflow/c/c_api.cc
InvalidArgument("Node ", node->name(), " was not found in the graph"); return; } tensorflow::shape_inference::ShapeHandle new_shape = tensorflow::ShapeHandleFromDims(ic, num_dims, dims); status->status = graph->refiner.SetShape(node, output.index, new_shape); } int TF_GraphGetTensorNumDims(TF_Graph* graph, TF_Output output, TF_Status* status) {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Mon Apr 15 03:35:10 UTC 2024 - 102.3K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/ir/tfl_ops.td
".getShape()[" # dim # " ] == " # size>]>; // Returns true if the n-th operand is ranked and has a dimension length <= // size at the rank dim. class TFL_OperandDimIsAtMost<int n, int dim, int size> : And<[ TFL_OperandIsRankedAndHasDimPred<n, dim>, CPred<"$_op.getOperand(" # n # ").getType().cast<ShapedType>()" ".getShape()[" # dim # " ] <= " # size>]>;
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Jun 06 19:09:08 UTC 2024 - 186K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/flatbuffer_export.cc
llvm::ArrayRef<int64_t> shape_ref = mlir::cast<TensorType>(tensor_attr.getType()).getShape(); if (mlir::failed(check_shape(shape_ref))) return std::nullopt; shape = std::vector<int32_t>(shape_ref.begin(), shape_ref.end()); } else if (type.hasRank()) { llvm::ArrayRef<int64_t> shape_ref = type.getShape(); if (mlir::failed(check_shape(shape_ref))) return std::nullopt;
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Wed Jun 12 21:41:49 UTC 2024 - 164.5K bytes - Viewed (2)