loadLayersModel调用触发此处描述的异常。 我正在尝试将保存的模型加载到浏览器中。
TensorFlow.js版本 1.2.2
浏览器版本 镀铬 版本75.0.3770.100
async function loadModel(sym) {
saved_model = await tf.loadLayersModel('localstorage://'+sym+'')
}
Error Description
-----------------
recurrent.ts:2236
Uncaught (in promise) TypeError: Cannot read property 'length' of
undefined
at e.fromConfig (recurrent.ts:2236)
at _p (generic_utils.ts:277)
at od (serialization.ts:31)
at e.fromConfig (recurrent.ts:2237)
at _p (generic_utils.ts:277)
at od (serialization.ts:31)
at e.fromConfig (recurrent.ts:836)
at _p (generic_utils.ts:277)
at od (serialization.ts:31)
at e.fromConfig (models.ts:1000)