code: public void loadModel(ModelReader reader) throws IOException {
          param = new Param(reader);
  
          nodes = new Node[param.num_nodes];
          for (int i = 0; i < param.num_nodes; i++) {
              nodes[i] = new Node(reader);
          }
  
          stats = new RTreeNodeStat[param.num_nodes];
          for (int i = 0; i < param.num_nodes; i++) {
              stats[i] = new RTreeNodeStat(reader);
          }
      }
docs: Loads model from stream.
  
  @param reader input stream
  @throws IOException If an I/O error occurs