license import { backend_util , Conv3D , Conv3DAttrs , Conv3DInputs , KernelConfig , KernelFunc } from '@tensorflow/tfjs-core' ; import { MathBackendWebGL } from '../backend_webgl' ; import { Conv3DProgram } from '../conv_gpu' ; export function conv3D ( args ) { const { inputs , backend , attrs } = args ; const { x , filter } = inputs ; const { strides , pad , dilations } = attrs ; const convInfo = backend_util . computeConv3DInfo ( x . shape as [ number , number , number , number , number ] , filter . shape as [ number , number , number , number , number ] , strides , dilations , pad ) ; const program = new Conv3DProgram ( convInfo ) ; return backend . runWebGLProgram ( program , [ x , filter ] , 'float32' ) ; } export const conv3DConfig = { kernelName : Conv3D , backendName : 'webgl' , kernelFunc : conv3D as { } as KernelFunc , } ;