Skip to content

Commit

Permalink
fix: support fix from test
Browse files Browse the repository at this point in the history
  • Loading branch information
Gean committed Apr 4, 2024
1 parent 1ceddd0 commit 849bc5a
Showing 1 changed file with 10 additions and 8 deletions.
18 changes: 10 additions & 8 deletions nerfstudio/scripts/render.py
Original file line number Diff line number Diff line change
Expand Up @@ -166,14 +166,16 @@ def _render_trajectory_video(
.numpy()
)
render_image.append(output_image)
render_image = np.concatenate(render_image, axis=1)
if output_format == "images":
if image_format == "png":
media.write_image(output_image_dir / f"{camera_idx:05d}.png", render_image, fmt="png")
if image_format == "jpeg":
media.write_image(
output_image_dir / f"{camera_idx:05d}.jpg", render_image, fmt="jpeg", quality=jpeg_quality
)
if not is_depth:
render_image = np.concatenate(render_image, axis=1)

if output_format == "images":
if image_format == "png":
media.write_image(output_image_dir / f"{camera_idx:05d}.png", render_image, fmt="png")
if image_format == "jpeg":
media.write_image(
output_image_dir / f"{camera_idx:05d}.jpg", render_image, fmt="jpeg", quality=jpeg_quality
)
if output_format == "video":
if writer is None:
render_width = int(render_image.shape[1])
Expand Down

0 comments on commit 849bc5a

Please sign in to comment.