If you want to visualize annotation results, Tier4 supports some rendering methods as below.
>>> t4.render_scene()>>> instance_token = t4.instance[0].token
>>> t4.render_instance(instance_token)!!! NOTE You can also render multiple instances at once:
<!-- markdownlint-disable MD046 -->
```python
>>> instance_tokens = [inst.token for inst in t4.instance[:3]]
>>> t4.render_instance(instance_tokens)
```
>>> t4.render_pointcloud()!!! NOTE
In case of you want to ignore camera distortion, please specify ignore_distortion=True.
<!-- markdownlint-disable MD046 -->
```python
>>> t4.render_pointcloud(ignore_distortion=True)
```
You can save the rendering result as follows:
>>> t4.render_scene(scene_token, save_dir=<DIR_TO_SAVE>)When you specify save_dir, viewer will not be spawned on your screen.
If you want to visualize your components, such as boxes that your ML-model estimated, RerunViewer allows you to visualize these components.
For details, please refer to the API references.
>>> from t4_devkit.viewer import RerunViewer
# You need to specify `cameras` if you want to 2D spaces
>>> viewer = RerunViewer(app_id, cameras=<CAMERA_NAMES:[str;N]>)
# Rendering 3D boxes
>>> viewer.render_box3ds(seconds, box3ds)
# Rendering 2D boxes
>>> viewer.render_box2ds(seconds, box2ds)It allows you to render boxes by specifying elements of boxes directly.
# Rendering 3D boxes
>>> viewer.render_box3ds(seconds, centers, rotations, sizes, class_ids)
# Rendering 2D boxes
>>> viewer.render_box2ds(seconds, rois, class_ids)

