MCPcopy
hub / github.com/tensorflow/tfjs / formatShape

Function formatShape

tfjs-vis/src/show/model.ts:193–202  ·  view source on GitHub ↗
(shape: number[])

Source from the content-addressed store, hash-verified

191}
192
193function formatShape(shape: number[]): string {
194 const oShape: Array<number|string> = shape.slice();
195 if (oShape.length === 0) {
196 return 'Scalar';
197 }
198 if (oShape[0] === null) {
199 oShape[0] = 'batch';
200 }
201 return `[${oShape.join(',')}]`;
202}
203
204function addHistogramSelector(
205 items: string[], parent: HTMLElement,

Callers 2

getLayerSummaryFunction · 0.85
getLayerDetailsFunction · 0.85

Calls 2

joinMethod · 0.80
sliceMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…