MCPcopy Create free account
hub / github.com/tensorflow/tfjs / constructor

Method constructor

tfjs-backend-webgpu/src/gather_webgpu.ts:31–39  ·  view source on GitHub ↗
(aShape: number[], outputShape: number[])

Source from the content-addressed store, hash-verified

29 size = true;
30
31 constructor(aShape: number[], outputShape: number[]) {
32 this.outputShape = aShape.slice();
33 this.aShape = aShape;
34 this.outputShape = outputShape;
35 this.dispatchLayout = flatDispatchLayout(this.outputShape);
36 this.dispatch = computeDispatch(
37 this.dispatchLayout, this.outputShape, this.workgroupSize);
38 this.shaderKey = `gather`;
39 }
40
41 getUserCode(): string {
42 const sourceCoords = getSourceCoords(this.aShape);

Callers

nothing calls this directly

Calls 3

flatDispatchLayoutFunction · 0.90
computeDispatchFunction · 0.90
sliceMethod · 0.65

Tested by

no test coverage detected