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

Function importCoreStr

tfjs/tools/custom_module/esm_module_provider.ts:83–95  ·  view source on GitHub ↗
(forwardModeOnly: boolean)

Source from the content-addressed store, hash-verified

81// Exported for tests.
82export const esmImportProvider: ImportProvider = {
83 importCoreStr(forwardModeOnly: boolean) {
84 const importLines = [
85 `import {registerKernel} from '@tensorflow/tfjs-core/dist/base';`,
86 `import '@tensorflow/tfjs-core/dist/base_side_effects';`,
87 `export * from '@tensorflow/tfjs-core/dist/base';`
88 ];
89
90 if (!forwardModeOnly) {
91 importLines.push(
92 `import {registerGradient} from '@tensorflow/tfjs-core/dist/base';`);
93 }
94 return importLines.join('\n');
95 },
96
97 importConverterStr() {
98 return `export * from '@tensorflow/tfjs-converter';`;

Callers

nothing calls this directly

Calls 2

joinMethod · 0.80
pushMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…