Package apple.coreml

Class MLMultiArray

    • Constructor Detail

      • MLMultiArray

        protected MLMultiArray​(org.moe.natj.general.Pointer peer)
    • Method Detail

      • accessInstanceVariablesDirectly

        public static boolean accessInstanceVariablesDirectly()
      • allocWithZone

        public static java.lang.Object allocWithZone​(org.moe.natj.general.ptr.VoidPtr zone)
      • automaticallyNotifiesObserversForKey

        public static boolean automaticallyNotifiesObserversForKey​(java.lang.String key)
      • cancelPreviousPerformRequestsWithTarget

        public static void cancelPreviousPerformRequestsWithTarget​(java.lang.Object aTarget)
      • cancelPreviousPerformRequestsWithTargetSelectorObject

        public static void cancelPreviousPerformRequestsWithTargetSelectorObject​(java.lang.Object aTarget,
                                                                                 org.moe.natj.objc.SEL aSelector,
                                                                                 java.lang.Object anArgument)
      • classFallbacksForKeyedArchiver

        public static NSArray<java.lang.String> classFallbacksForKeyedArchiver()
      • classForKeyedUnarchiver

        public static org.moe.natj.objc.Class classForKeyedUnarchiver()
      • count

        public long count()
        Count of total number of elements
      • dataPointer

        public org.moe.natj.general.ptr.VoidPtr dataPointer()
        Unsafe pointer to underlying buffer holding the data
      • dataType

        public long dataType()
        Type of element held
      • debugDescription_static

        public static java.lang.String debugDescription_static()
      • description_static

        public static java.lang.String description_static()
      • hash_static

        public static long hash_static()
      • initWithShapeDataTypeError

        public MLMultiArray initWithShapeDataTypeError​(NSArray<? extends NSNumber> shape,
                                                       long dataType,
                                                       org.moe.natj.general.ptr.Ptr<NSError> error)
        Create by C-style contiguous array by allocating and managing the necessary memory
      • instanceMethodSignatureForSelector

        public static NSMethodSignature instanceMethodSignatureForSelector​(org.moe.natj.objc.SEL aSelector)
      • instancesRespondToSelector

        public static boolean instancesRespondToSelector​(org.moe.natj.objc.SEL aSelector)
      • isSubclassOfClass

        public static boolean isSubclassOfClass​(org.moe.natj.objc.Class aClass)
      • keyPathsForValuesAffectingValueForKey

        public static NSSet<java.lang.String> keyPathsForValuesAffectingValueForKey​(java.lang.String key)
      • new_objc

        public static java.lang.Object new_objc()
      • objectAtIndexedSubscript

        public NSNumber objectAtIndexedSubscript​(long idx)
        Get a value by its linear index (assumes C-style index ordering)
      • objectForKeyedSubscript

        public NSNumber objectForKeyedSubscript​(NSArray<? extends NSNumber> key)
        Get a value by its multidimensional index (NSArray)
      • resolveClassMethod

        public static boolean resolveClassMethod​(org.moe.natj.objc.SEL sel)
      • resolveInstanceMethod

        public static boolean resolveInstanceMethod​(org.moe.natj.objc.SEL sel)
      • setObjectAtIndexedSubscript

        public void setObjectAtIndexedSubscript​(NSNumber obj,
                                                long idx)
        Set a value by its linear index (assumes C-style index ordering)
      • setObjectForKeyedSubscript

        public void setObjectForKeyedSubscript​(NSNumber obj,
                                               NSArray<? extends NSNumber> key)
        Set a value by subindicies (NSArray)
      • setVersion_static

        public static void setVersion_static​(long aVersion)
      • shape

        public NSArray<? extends NSNumber> shape()
        An array containing the sizes of each dimension in the multiarray
      • strides

        public NSArray<? extends NSNumber> strides()
        An array containing the stride in memory for each dimension. The element referred to by a multidimensional index is located at an offset equal to sum_d index[d]*strides[d]. This offset is in the units of the specified dataType.
      • superclass_static

        public static org.moe.natj.objc.Class superclass_static()
      • version_static

        public static long version_static()
      • multiArrayByConcatenatingMultiArraysAlongAxisDataType

        public static MLMultiArray multiArrayByConcatenatingMultiArraysAlongAxisDataType​(NSArray<? extends MLMultiArray> multiArrays,
                                                                                         long axis,
                                                                                         long dataType)
        Concatenate MLMultiArrays to form a new MLMultiArray. All the source MLMultiArrays must have a same shape except the specified axis. The resultant MLMultiArray has the same shape as inputs except this axis, which dimension will be the sum of all the input dimensions of the axis. For example, \code // Swift let A = try MLMultiArray(shape: [2, 3], dataType: .int32) let B = try MLMultiArray(shape: [2, 2], dataType: .int32) let C = MLMultiArray(concatenating: [A, B], axis: 1, dataType: .int32) assert(C.shape == [2, 5]) \endcode \code // Obj-C MLMultiArray *A = [[MLMultiArray alloc] initWithShape:@[@2, @3] dataType:MLMultiArrayDataTypeInt32 error:NULL]; MLMultiArray *B = [[MLMultiArray alloc] initWithShape:@[@2, @2] dataType:MLMultiArrayDataTypeInt32 error:NULL]; MLMultiArray *C = [MLMultiArray multiArrayByConcatenatingMultiArrays:@[A, B] alongAxis:1 dataType:MLMultiArrayDataTypeInt32]; assert(C.shape == @[@2, @5]) \endcode Numeric data will be up or down casted as needed. The method raises NSInvalidArgumentException if the shapes of input multi arrays are not compatible for concatenation.
        Parameters:
        multiArrays - Array of MLMultiArray instances to be concatenated.
        axis - Axis index with which the concatenation will performed. The value is wrapped by the dimension of the axis. For example, -1 is the last axis.
        dataType - The data type of the resultant MLMultiArray
      • supportsSecureCoding

        public static boolean supportsSecureCoding()
      • _supportsSecureCoding

        public boolean _supportsSecureCoding()
        Description copied from interface: NSSecureCoding
        This property must return YES on all classes that allow secure coding. Subclasses of classes that adopt NSSecureCoding and override initWithCoder: must also override this method and return YES. The Secure Coding Guide should be consulted when writing methods that decode data.
        Specified by:
        _supportsSecureCoding in interface NSSecureCoding