docs: private void materializeKNNAndRKNNs(ArrayDBIDs ids, FiniteProgress progress) {
      // add an empty list to each rknn
      for(DBIDIter iter = ids.iter(); iter.valid(); iter.advance()) {
        if(materialized_RkNN.get(iter) == null) {
          materialized_RkNN.put(iter, new TreeSet<DoubleDBIDPair>());
        }
      }
  
      // knn query
      List<? extends KNNList> kNNList = knnQuery.getKNNForBulkDBIDs(ids, k);
      for(DBIDArrayIter id = ids.iter(); id.valid(); id.advance()) {
        KNNList kNNs = kNNList.get(id.getOffset());
        storage.put(id, kNNs);
        for(DoubleDBIDListIter iter = kNNs.iter(); iter.valid(); iter.advance()) {
          materialized_RkNN.get(iter).add(DBIDUtil.newPair(iter.doubleValue(), id));
        }
        LOG.incrementProcessed(progress);
      }
  
      LOG.ensureCompleted(progress);
    }