Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add cli arguments #47

Open
github-actions bot opened this issue Aug 11, 2024 · 0 comments
Open

add cli arguments #47

github-actions bot opened this issue Aug 11, 2024 · 0 comments
Assignees
Labels

Comments

@github-actions
Copy link

# TODO: add cli arguments

from pathlib import Path
import shutil

from bevy_zeroverse_dataloader import BevyZeroverseDataset


def generate_chunked_dataset(
        stage = "test",
        output_dir = Path("./data/zeroverse"),
        bytes_per_chunk = int(1e8),
        dataset = BevyZeroverseDataset(
            editor=False,
            headless=True,
            num_cameras=4,
            width=640,
            height=360,
            num_samples=10,
        )
    ) -> list:
    if output_dir.exists():
        shutil.rmtree(output_dir / stage)

    return dataset.chunk_and_save(
        output_dir / stage,
        bytes_per_chunk,
        n_workers=4,
    )


if __name__ == "__main__":
    # TODO: add cli arguments
    _data, chunk_paths = generate_chunked_dataset()

    print(f"chunks:\n{chunk_paths}")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant