tensorspace icon indicating copy to clipboard operation
tensorspace copied to clipboard

Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'setShape')

Open hst45 opened this issue 3 years ago • 0 comments

@CharlesLiuyx Hi, I met with some problems when I was trying to visualize the LeNet model in the examples. I used the tensorspacejs_converter to preprocess the model first, and it seemed that the preprocessing was completed successfully, here is the output of the preprocessing in the terminal:

2022-04-24 14:57:46.833002: I tensorflow/core/platform/cpu_feature_guard.cc:141] Your CPU supports instructions that this TensorFlow binary was not compiled to use: AVX2 FMA Saving enc_model... Saving converted tfjs model... Removing enc_model file... Mission Complete!!!

And the following is the javascript problem I met when I was trying to use the converted model.json in the HTML

Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'setShape') at R.configureLayerShape (Sequential.js:333:25) at R.initTSPModel (Sequential.js:155:9) at AbstractModel.js:312:10

I also tried to use the model.json and mnist.weights.bin downloaded from the tensorspace-website project, and it worked. So I assume that there might be something wrong with my preprocessing. Could you please help me with it?

hst45 avatar Apr 24 '22 08:04 hst45