MCPcopy Create free account
hub / github.com/allenai/molmo2 / test_time_sampling_basic

Function test_time_sampling_basic

tests/preprocessing/test_frame_sampling.py:6–9  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

4
5
6def test_time_sampling_basic():
7 ts = TimeSampler(max_frames=4, frame_sample_mode="uniform_last_frame")
8 assert np.allclose(ts(2)[1], [0, 2/3, 4/3, 2])
9 assert np.allclose(ts(2.1)[1], [0, 2.1/3, 2*2.1/3, 2.1])
10
11
12def test_time_sampling_max_1fps():

Callers

nothing calls this directly

Calls 1

TimeSamplerClass · 0.90

Tested by

no test coverage detected