class_docstr: A data iterator for XGBoost DMatrix.
  
  `reset` and `next` are required for any data iterator, other functions here
  are utilites for demonstration's purpose.
class_docstr_tok: ["A","data","iterator","for","XGBoost","DMatrix",".","`","reset","`","and","`","next","`","are","required","for","any","data","iterator",",","other","functions","here","are","utilites","for","demonstration","'s","purpose","."]
code: def as_array(self):
      return cupy.concatenate(self._data)
  
file_path: xgboost/demo/guide-python/quantile_data_iterator.py
imports: import cupy
  import numpy
  import xgboost
label_desc: Use image node_id 2 for calling the IterForDMatrixDemo obj's underlying member method code with example usage: obj.as_array() and returns: cupy