@lina128 Thank you . I converted the model to shard files and model.json. Then I loaded the graph model.
When I tried to run the following code to generate the image, it throws an error .
const noise = tf.randomNormal([512]).expandDims(0); let generatedImage = await generator.executeAsync(noise)
The error is that: util_base.ts:154 Uncaught (in promise) Error: Error in depthwiseConv2d: number of input channels (8) must match the inChannels dimension in filter 512.
at Object.assert (util_base.ts:154)
at depthwiseConv2d_ (depthwise_conv2d.ts:99)
at Object.depthwiseConv2d__op (operation.ts:51)
at Object.executeOp (convolution_executor.ts:195)
at operation_executor.ts:69
at engine.ts:467
at Engine.scopedRun (engine.ts:478)
at Engine.tidy (engine.ts:465)
at Object.tidy (globals.ts:192)
at operation_executor.ts:68