I have occasionally seen a bug where it says something like:
TypeError: 'int' (maybe float I forgot) object is not iterable
Which comes from:
g_dim = g_dim.cpu().squeeze().tolist()
for x, x_val in enumerate(g_dim):
I guess there is some weird case where g_dim is an int instead of a list. Sorry I can't reproduce it right now, but my hack fix was:
g_dim = g_dim.cpu().squeeze().tolist()
+ # Add to handle occasional case when g_dim isn't a list
+ if isinstance(g_dim, int):
+ g_dim = [g_dim]
for x, x_val in enumerate(g_dim):
The ideal solution is to understand the desired and actual shapes of:
Then fix it. My guess is that squeeze().tolist() on a tensor of shape (1,) or (1, 1) gives a value instead of a list, but maybe Balakumar knows the shapes and can update the squeeze appropriately. Could also be somethign related to torch.nonzero(ik_success).view(-1)[graph_result.success]
cuRobo installation mode (choose from [python, isaac sim, docker python, docker isaac sim]): python
In
src/curobo/wrap/reacher/motion_gen.py
:I have occasionally seen a bug where it says something like:
Which comes from:
I guess there is some weird case where g_dim is an int instead of a list. Sorry I can't reproduce it right now, but my hack fix was:
The ideal solution is to understand the desired and actual shapes of:
Then fix it. My guess is that squeeze().tolist() on a tensor of shape (1,) or (1, 1) gives a value instead of a list, but maybe Balakumar knows the shapes and can update the squeeze appropriately. Could also be somethign related to
torch.nonzero(ik_success).view(-1)[graph_result.success]
Issue Details