MCPcopy
hub / github.com/Vchitect/Latte / _load_raw_image

Method _load_raw_image

tools/utils/dataset.py:226–233  ·  view source on GitHub ↗
(self, raw_idx)

Source from the content-addressed store, hash-verified

224 return dict(super().__getstate__(), _zipfile=None)
225
226 def _load_raw_image(self, raw_idx):
227 fname = self._image_fnames[raw_idx]
228
229 with self._open_file(fname) as f:
230 use_pyspng = pyspng is not None and self._file_ext(fname) == '.png'
231 image = load_image_from_buffer(f, use_pyspng=use_pyspng)
232
233 return image
234
235 def _load_raw_labels(self):
236 fname = 'dataset.json'

Callers 1

__init__Method · 0.95

Calls 3

_open_fileMethod · 0.95
load_image_from_bufferFunction · 0.85
_file_extMethod · 0.80

Tested by

no test coverage detected