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

Test and handle all tensor dtypes as images #1840

Merged
merged 12 commits into from
Apr 13, 2023
10 changes: 7 additions & 3 deletions examples/python/api_demo/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -329,17 +329,21 @@ def main() -> None:

parser = argparse.ArgumentParser(description="Logs rich data using the Rerun SDK.")
parser.add_argument(
"--demo", type=str, default="all", help="What demo to run", choices=["all"] + list(demos.keys())
"--demo", type=str, default="most", help="What demo to run", choices=["most", "all"] + list(demos.keys())
)

rr.script_add_args(parser)
args = parser.parse_args()

rr.script_setup(args, "api_demo")

if args.demo == "all":
print("Running all demos…")
if args.demo in ["most", "all"]:
print(f"Running {args.demo} demos…")
for name, demo in demos.items():
# Some demos are just a bit… too much
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

😆 👍

if args.demo == "most" and name in ["image_tensors"]:
continue

logging.info(f"Starting {name}")
demo()
else:
Expand Down