Is your ultimate goal to use the object detection model in TF.js? If that’s the case, please export the model as TFLite and use the TFLite Task Library for TF.js to run the model.

  
      

      js.tensorflow.org
  

  
    

TensorFlow.js

  A WebGL accelerated, browser based JavaScript library for training and deploying ML models