Search Options

Results per page
Sort
Preferred Languages
Advance

Results 31 - 40 of 60 for IntegerType (0.14 sec)

  1. tensorflow/compiler/mlir/lite/utils/convert_type.cc

        } else if (complex_type.getElementType().isF64()) {
          return tflite::TensorType_COMPLEX128;
        }
        llvm_unreachable("invalid complex Type in conversion");
      } else if (auto itype = mlir::dyn_cast<mlir::IntegerType>(type)) {
        switch (itype.getWidth()) {
          case 1:
            return tflite::TensorType_BOOL;
          case 4:
            if (itype.isUnsigned())
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue May 07 23:04:40 UTC 2024
    - 8.2K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/lite/stablehlo/transforms/legalize_hlo_conversions/util.cc

      return rewriter.create<mhlo::TransposeOp>(value.getLoc(), type, value,
                                                permutation);
    }
    
    Value CreateCastToInt32(Value val, Location loc, PatternRewriter& rewriter) {
      IntegerType new_ele_type = rewriter.getIntegerType(32);
      if (auto shaped_type = mlir::dyn_cast<RankedTensorType>(val.getType())) {
        ShapedType new_type =
            RankedTensorType::get(shaped_type.getShape(), new_ele_type);
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 10.1K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/tensorflow/translate/tf_mlir_translate.cc

            if (auto attr = inst.getAttrOfType<mlir::ElementsAttr>(attr_id)) {
              mlir::Attribute rand_val;
              mlir::Type element_type = attr.getShapedType().getElementType();
              if (mlir::isa<mlir::IntegerType>(element_type)) {
                rand_val = mlir::IntegerAttr::get(element_type, std::rand());
              } else if (element_type.isF16() || element_type.isF32() ||
                         element_type.isF64()) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue May 07 11:51:44 UTC 2024
    - 14.1K bytes
    - Viewed (0)
  4. src/go/types/builtins.go

    		x.mode = value
    		x.typ = &emptyInterface
    		if check.recordTypes() {
    			check.recordBuiltinType(call.Fun, makeSig(x.typ))
    		}
    
    	case _Add:
    		// unsafe.Add(ptr unsafe.Pointer, len IntegerType) unsafe.Pointer
    		check.verifyVersionf(call.Fun, go1_17, "unsafe.Add")
    
    		check.assignment(x, Typ[UnsafePointer], "argument to unsafe.Add")
    		if x.mode == invalid {
    			return
    		}
    
    		y := args[1]
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 30 19:19:55 UTC 2024
    - 27.2K bytes
    - Viewed (0)
  5. src/cmd/compile/internal/types2/builtins.go

    		x.mode = value
    		x.typ = &emptyInterface
    		if check.recordTypes() {
    			check.recordBuiltinType(call.Fun, makeSig(x.typ))
    		}
    
    	case _Add:
    		// unsafe.Add(ptr unsafe.Pointer, len IntegerType) unsafe.Pointer
    		check.verifyVersionf(call.Fun, go1_17, "unsafe.Add")
    
    		check.assignment(x, Typ[UnsafePointer], "argument to unsafe.Add")
    		if x.mode == invalid {
    			return
    		}
    
    		y := args[1]
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 30 19:19:55 UTC 2024
    - 27.1K bytes
    - Viewed (0)
  6. tensorflow/compiler/mlir/lite/transforms/legalize_tf.cc

      /// Performs the lowering to TFLite dialect.
      void runOnOperation() override;
    };
    
    // Util that casts 'val' to Int32 by adding a cast Op.
    Value CreateCastToInt32(Value val, Location loc, PatternRewriter& rewriter) {
      IntegerType new_ele_type = rewriter.getIntegerType(32);
      if (auto shaped_type = mlir::dyn_cast<RankedTensorType>(val.getType())) {
        ShapedType new_type =
            RankedTensorType::get(shaped_type.getShape(), new_ele_type);
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Mon May 20 20:06:54 UTC 2024
    - 45.2K bytes
    - Viewed (0)
  7. tensorflow/compiler/mlir/lite/transforms/while_loop_outline.cc

          mlir::cast<ComplexType>(elemType).getElementType().isF32())
        return true;
    
      // QUINT8 and UI8 are allowed.
      if (mlir::isa<TF::Quint8Type>(elemType) ||
          (elemType.isInteger(8) && mlir::cast<IntegerType>(elemType).isUnsigned()))
        return true;
    
      return false;
    }
    
    func::FuncOp CreateOutlineFunc(StringRef name, Region& region,
                                   bool passthru_extra_args, int num_loop_carried,
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 11.8K bytes
    - Viewed (0)
  8. tensorflow/compiler/mlir/lite/utils/tftext_utils.cc

        return func.emitError() << "First input should be a string tensor";
      }
      auto row_splits_type = GetInputType(func, 1);
      if (!row_splits_type ||
          !mlir::isa<IntegerType>(row_splits_type.getElementType())) {
        return func.emitError() << "Second input should be an integer tensor";
      }
    
      auto hash_seed =
          mlir::dyn_cast_or_null<ArrayAttr>(attr.getAttrs().get("hash_seed"));
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 14.4K bytes
    - Viewed (0)
  9. tensorflow/compiler/mlir/quantization/common/quantization_lib/quantization_utils.cc

          scales[i] = static_cast<float>(scales[i]);
        }
      }
    
      // Builds the result quantized type, which has signed 32 bits storage type.
      Builder builder(expressed_type.getContext());
      const IntegerType storage_type = builder.getIntegerType(32);
      const int64_t storage_type_min =
          quant::QuantizedType::getDefaultMinimumForInteger(/*isSigned=*/true, 32);
      const int64_t storage_type_max =
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed May 08 02:10:16 UTC 2024
    - 43.2K bytes
    - Viewed (0)
  10. tensorflow/compiler/mlir/lite/transforms/lower_static_tensor_list.cc

                                           PatternRewriter *rewriter) {
      // Create the start position of slice. This is done by concatenating
      // `start_index` and `partial_start_position` together.
      IntegerType shape_dtype = rewriter->getIntegerType(32);
      RankedTensorType position_type =
          tensorflow::GetTypeFromTFTensorShape({-1}, shape_dtype);
      Value partial_start_position =
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Jun 11 20:00:43 UTC 2024
    - 70.7K bytes
    - Viewed (0)
Back to top