MCPcopy Create free account
hub / github.com/OpenImagingLab/FlashVSR / __getitem__

Method __getitem__

diffsynth/data/video.py:120–126  ·  view source on GitHub ↗
(self, item)

Source from the content-addressed store, hash-verified

118 return height, width
119
120 def __getitem__(self, item):
121 frame = self.data.__getitem__(item)
122 width, height = frame.size
123 if self.height is not None and self.width is not None:
124 if self.height != height or self.width != width:
125 frame = crop_and_resize(frame, self.height, self.width)
126 return frame
127
128 def __del__(self):
129 pass

Callers 3

raw_dataMethod · 0.95
shapeMethod · 0.95
save_imagesMethod · 0.95

Calls 1

crop_and_resizeFunction · 0.85

Tested by

no test coverage detected