tensorboardX icon indicating copy to clipboard operation
tensorboardX copied to clipboard

add_mesh problem!

Open TrepangCat opened this issue 4 years ago • 2 comments

When I use add_mesh() many times with tag='train/mesh', I can't click the blue bar to change the mesh shown on the page.

TrepangCat avatar Sep 10 '21 03:09 TrepangCat

Hi, do you have any small reproducible code for the issue?

lanpa avatar Sep 12 '21 13:09 lanpa

For example

from tensorboardX import SummaryWriter import numpy as np import time import utils

vox = utils.load_binvox('/media/brl/dataDisk/WangRuowei/3d_2021/gan3d-wrw/data_sample/ShapeNetCore.v2/' '03001627/1a6f615e8b1b5ae4dbbc9440457e303e/models/model_normalized_solid_64.binvox') box = vox.as_boxes(colors=(255, 165, 0, 128)) vertices = box.vertices vertices = np.array(vertices).reshape([1, vertices.shape[0], vertices.shape[1]]) faces = box.faces faces = np.array(faces).reshape([1, faces.shape[0], faces.shape[1]])

config_dict = { 'camera': {'cls': 'PerspectiveCamera', 'fov': 75}, 'lights': [ { 'cls': 'AmbientLight', 'color': '#ffffff', 'intensity': 0.5, }, { 'cls': 'DirectionalLight', 'color': '#7cfc00', 'intensity': 1, 'position': [1.5, 3, 2.5], }, { 'cls': 'DirectionalLight', 'color': '#7cfc00', 'intensity': 1, 'position': [-1.5, -3, -2.5], }, ], 'material': { 'cls': 'MeshStandardMaterial', 'roughness': 0.5, 'metalness': 0, 'flatShading': True # 'wireframe': True, }, }

writer = SummaryWriter(logdir='./example')

writer.add_mesh(tag='test', vertices=vertices, faces=faces, config_dict=config_dict, global_step=1) writer.add_mesh(tag='test', vertices=vertices, faces=faces, config_dict=config_dict, global_step=2)

writer.close()

When you use add_mesh() at least twice, the blue bar doesn't work after rotating the mesh with the mouse. I mean that it is unable to click the blue bar after rotating the mesh with the mouse. You can change the box in the code to other meshes. I think the problem is reproducible.

TrepangCat avatar Sep 13 '21 01:09 TrepangCat