I created a basic model with TensorFlow and converted the model to TensorFlowJs with: tfjs.converters.save_keras_model(model, './jfk_ewr')
and saved the converted model in google storage bucket.
When loading the model with 'Example 1' ("Load a model from an HTTP server") from the following link: https://js.tensorflow.org/api/latest/#loadLayersModel I get a CORS error.
model = await tf.loadLayersModel('https://console.cloud.google.com/storage/browser/jfk/ewr/model.json');
Error: Access to fetch at 'https://console.cloud.google.com/storage/browser/jfk/ewr/model.json' from origin 'null' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled.