Closed mrjchen closed 4 months ago
Hi, below is one example.
from plyfile import PlyData, PlyElement pts = tp_input['vertices'][0] x, y, z = pts[:, 0], pts[:, 1], pts[:, 2] pts = list(zip(x, y, z)) vertex = np.array(pts, dtype=[('x', 'f4'), ('y', 'f4'), ('z', 'f4')]) el = PlyElement.describe(vertex, 'vertex') PlyData([el], text='target_vertex').write('target_vertex.ply')
Thank you for your response,but I mean that how to use the pre-trained NeRF weights to reconstruct a 3D mesh model with surfaces and textures? Input is a image.
Hi, below is one example.
from plyfile import PlyData, PlyElement pts = tp_input['vertices'][0] x, y, z = pts[:, 0], pts[:, 1], pts[:, 2] pts = list(zip(x, y, z)) vertex = np.array(pts, dtype=[('x', 'f4'), ('y', 'f4'), ('z', 'f4')]) el = PlyElement.describe(vertex, 'vertex') PlyData([el], text='target_vertex').write('target_vertex.ply')
gen_sample.py seems to implement this functionality, but it appears to be incomplete.
Hi, we did not implement this part. You can refer to marching cude to extract 3D mesh.
Hi, below is one example.
from plyfile import PlyData, PlyElement pts = tp_input['vertices'][0] x, y, z = pts[:, 0], pts[:, 1], pts[:, 2] pts = list(zip(x, y, z)) vertex = np.array(pts, dtype=[('x', 'f4'), ('y', 'f4'), ('z', 'f4')]) el = PlyElement.describe(vertex, 'vertex') PlyData([el], text='target_vertex').write('target_vertex.ply')