Skip to content

Bug in camera action processing #54

Description

@georgysavva

Hi, thank you for open-sourcing such an important research dataset! We've been using your dataset to build our Minecraft world model.

We took your dataloading code as is, and I believe I found a bug in the camera action post-processing logic. It implicitly converts any camera values to integers, so numbers like 5.625 become 5. Here I added a test that shows it: link. It outputs:

Mismatched elements: 2 / 2 (100%)
Max absolute difference: 0.625
Max relative difference: 0.11111111
 x: array([5, 5])
 y: array([5.625, 5.625], dtype=float32)

Meaning the function returns 5 whereas it should have been 5.625 == 37.5 * 360/2400. The bug stems from the way the camera numpy array is initialized here and here. It gets created as an integer array so that float numbers that later get assigned get converted to integers. It should be np.array([0.0, 0.0], dtype=np.float32) instead. Here is the fix: georgysavva@4ac7eb0. With it, the above test passes.

The implication of this bug is that camera actions get very inaccurate at lower values. For example, the relative error for 2.9 and 2.0 is 45%. Here is a histogram of the camera action distribution of the VPT dataset (X axis is the value in degrees):

Image

As you can see, most of the action values are in lower ranges, < 3.0, so the issue is well represented in the dataset.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions