You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
renderer = nr.Renderer(camera_mode='projection', image_size=1024, anti_aliasing=False, near=0.1) #image_size is used up in rasterizing function
im = renderer(vertices[None, :, :], faces[None, :, :], mode='depth', K=K, R=R_tensor, t=t_tensor, orig_size=1024)
a = im[0].data.cpu().numpy()
plt.imsave(os.path.join(output_dir,'plane_depth.png'), a, cmap='gray')
in this code orig_size width =height=1024
The text was updated successfully, but these errors were encountered:
how to get the render if the image width != height?
for example
#K - K matrix, R - Rotation matrix, t = translation vector
vertices,faces=nr.load_obj(os.path.join(data_dir,'plane.obj'), normalization=False)
neural renderer
renderer = nr.Renderer(camera_mode='projection', image_size=1024, anti_aliasing=False, near=0.1) #image_size is used up in rasterizing function
im = renderer(vertices[None, :, :], faces[None, :, :], mode='depth', K=K, R=R_tensor, t=t_tensor, orig_size=1024)
a = im[0].data.cpu().numpy()
plt.imsave(os.path.join(output_dir,'plane_depth.png'), a, cmap='gray')
in this code orig_size width =height=1024
The text was updated successfully, but these errors were encountered: