MCPcopy Create free account
hub / github.com/MotrixLab/ViMoGen / get_image_size

Function get_image_size

datasets/aspect.py:467–475  ·  view source on GitHub ↗
(resolution, ar_ratio)

Source from the content-addressed store, hash-verified

465
466
467def get_image_size(resolution, ar_ratio):
468 if ar_ratio in ASPECT_RATIO_MAP:
469 ar_key = ASPECT_RATIO_MAP[ar_ratio]
470 else:
471 ar_key = ar_ratio
472 rs_dict = ASPECT_RATIOS[resolution][1]
473 assert (ar_key in rs_dict
474 ), f'Aspect ratio {ar_ratio} not found for resolution {resolution}'
475 return rs_dict[ar_key]
476
477
478NUM_FRAMES_MAP = {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected