torch
    Preparing search index...

    Class GPU

    Index

    Constructors

    • Parameters

      • Optionalsettings: IGPUSettings

      Returns GPU

    Properties

    canvas: any
    context: any
    functions: GPUFunction<ThreadKernelVariable[], {}>[]
    Kernel: typeof Kernel
    mode: string
    nativeFunctions: IGPUNativeFunction[]
    isCanvasSupported: boolean
    isGPUHTMLImageArraySupported: boolean
    isGPUSupported: boolean
    isHeadlessGLSupported: boolean
    isKernelMapSupported: boolean
    isOffscreenCanvasSupported: boolean
    isSinglePrecisionSupported: boolean
    isWebGL2Supported: boolean
    isWebGLSupported: boolean

    Methods

    • Type Parameters

      • ArgTypes extends ThreadKernelVariable[] = ThreadKernelVariable[]
      • ConstantsType = {}

      Parameters

      Returns this

    • Parameters

      • name: string
      • source: string
      • Optionalsettings: IGPUFunctionSettings

      Returns this

    • Parameters

      • ...kernels: KernelFunction<ThreadKernelVariable[], {}>[]

      Returns IKernelRunShortcut

    • Type Parameters

      • KF extends KernelFunction<ThreadKernelVariable[], {}>

      Parameters

      • ...kernels: KF[]

      Returns (
          ...args: Parameters<KF>,
      ) =>
          | void
          | Texture
          | ReturnType<KF>[]
          | ReturnType<KF>[][]
          | ReturnType<KF>[][][] & IKernelRunShortcutBase<KernelOutput>

    • Type Parameters

      • ArgTypes extends ThreadKernelVariable[]
      • ConstantsT extends IConstantsThis

      Parameters

      Returns IKernelRunShortcut

    • Type Parameters

      • KernelType extends KernelFunction<ThreadKernelVariable[], {}>

      Parameters

      • kernel: KernelType
      • Optionalsettings: IGPUKernelSettings

      Returns (
          ...args: Parameters<KernelType>,
      ) =>
          | void
          | Texture
          | ReturnType<KernelType>[]
          | ReturnType<KernelType>[][]
          | ReturnType<KernelType>[][][] & IKernelRunShortcutBase<KernelOutput>

    • Type Parameters

      • ArgTypes extends ThreadKernelVariable[]
      • ConstantsType = null

      Parameters

      • subKernels: ISubKernelObject
      • rootKernel: ThreadFunction<ArgTypes, ConstantsType>
      • Optionalsettings: IGPUKernelSettings

      Returns (
          this: IKernelFunctionThis<ConstantsType>,
          ...args: ArgTypes,
      ) => IMappedKernelResult & IKernelMapRunShortcut<ISubKernelObject>

    • Returns Promise<void>

    • Parameters

      • flag: any

      Returns this

    • Parameters

      • flag: IGPUNativeFunction[]

      Returns this