C3D file import error #37768

Closed
opened 2013-12-10 16:10:18 +01:00 by inactive account · 8 comments

System Information
Windows 8 64-bit

Blender Version
Blender 2.69 r60995

Short description of error
Importing the attached C3D file gives me an error. Trying to fix the error makes the importer do nothing at all.

Exact steps for others to reproduce the error

  • Enable the C3D importer addon
  • Load the attached C3D file 02_01.c3d

Check the console window

The error is:

  Traceback (most recent call last):
    File "C:\Program Files\Blender Foundation\Blender\2.69\scripts\addons\io_anim_c3d\__init__.py", line 221, in execute
      ms = import_c3d.read(self.properties.filepath, onlyHeader=True)
    File "C:\Program Files\Blender Foundation\Blender\2.69\scripts\addons\io_anim_c3d\import_c3d.py", line 266, in read
      return MarkerSet(filename, *a, **kw)
    File "C:\Program Files\Blender Foundation\Blender\2.69\scripts\addons\io_anim_c3d\import_c3d.py", line 88, in __init__
      self.identifyMarkerPrefix(stripPrefix)
    File "C:\Program Files\Blender Foundation\Blender\2.69\scripts\addons\io_anim_c3d\import_c3d.py", line 143, in identifyMarkerPrefix
      prefix = self.markerLabels[0]
  IndexError: list index out of range

This error can be circumvented by prefixing the offending line with something like this:

      if not self.markerLabels:
        # If there are no marker labels at all, there also is no common prefix.
          self.prefix = ''
          return

However, then the importer does nothing; no error, but also no imported data from the C3D file. Opening the C3D file in MotionBuilder shows that it contains moving motion capture markers, which should have been imported as keyframed empties. The exception shown above probably was caused by the same bug that prevents the data from getting imported.

The C3D file was obtained from Carnegie Mellon University: http://mocap.cs.cmu.edu/search.php?subjectnumber=2&trinum=1
That page also contains a AVI file that shows a virtual character following the motions of the mocap data.

**System Information** Windows 8 64-bit **Blender Version** Blender 2.69 r60995 **Short description of error** Importing the attached C3D file gives me an error. Trying to fix the error makes the importer do nothing at all. **Exact steps for others to reproduce the error** - Enable the C3D importer addon - Load the attached C3D file [02_01.c3d](https://archive.blender.org/developer/F38239/02_01.c3d) # Check the console window The error is: ``` Traceback (most recent call last): File "C:\Program Files\Blender Foundation\Blender\2.69\scripts\addons\io_anim_c3d\__init__.py", line 221, in execute ms = import_c3d.read(self.properties.filepath, onlyHeader=True) File "C:\Program Files\Blender Foundation\Blender\2.69\scripts\addons\io_anim_c3d\import_c3d.py", line 266, in read return MarkerSet(filename, *a, **kw) File "C:\Program Files\Blender Foundation\Blender\2.69\scripts\addons\io_anim_c3d\import_c3d.py", line 88, in __init__ self.identifyMarkerPrefix(stripPrefix) File "C:\Program Files\Blender Foundation\Blender\2.69\scripts\addons\io_anim_c3d\import_c3d.py", line 143, in identifyMarkerPrefix prefix = self.markerLabels[0] IndexError: list index out of range ``` This error can be circumvented by prefixing the offending line with something like this: ``` if not self.markerLabels: ``` # If there are no marker labels at all, there also is no common prefix. ``` self.prefix = '' return ``` However, then the importer does nothing; no error, but also no imported data from the C3D file. Opening the C3D file in MotionBuilder shows that it contains moving motion capture markers, which should have been imported as keyframed empties. The exception shown above probably was caused by the same bug that prevents the data from getting imported. The C3D file was obtained from Carnegie Mellon University: http://mocap.cs.cmu.edu/search.php?subjectnumber=2&trinum=1 That page also contains a AVI file that shows a virtual character following the motions of the mocap data.

Changed status to: 'Open'

Changed status to: 'Open'

Added subscriber: @sybrenstuvel

Added subscriber: @sybrenstuvel
Daniel M. Basso was assigned by Brecht Van Lommel 2013-12-10 16:53:23 +01:00

I fixed the problem (c3d.patch), but for some reason I'm not able to push my commit:

fatal: remote error: access denied or repository not exported: /blender-addons.git```
I added my SSH key around 30 minutes ago, is there anything else that I need to do?
I fixed the problem ([c3d.patch](https://archive.blender.org/developer/F38266/c3d.patch)), but for some reason I'm not able to push my commit: ```$ git push fatal: remote error: access denied or repository not exported: /blender-addons.git``` I added my SSH key around 30 minutes ago, is there anything else that I need to do?

Ok, the problem was I had not setup the submodule to use git@git.blender.org:blender-addons.git. Now the bug fix has been pushed, please check that it works.
@sybrenstuvel: you might find the CMU Mocap Browser addon interesting as well. It has not been accepted to be included in the release repository yet, but you can find it in contrib (and test builds).

Ok, the problem was I had not setup the submodule to use `git@git.blender.org:blender-addons.git`. Now the bug fix has been pushed, please check that it works. @sybrenstuvel: you might find the CMU Mocap Browser addon interesting as well. It has not been accepted to be included in the release repository yet, but you can find it in contrib (and test builds).

Added subscriber: @dmbasso

Added subscriber: @dmbasso

@dmbasso: Awesome, thanks for everything!

@dmbasso: Awesome, thanks for everything!

Yep, the data can now be imported, so this bug is fixed!

Yep, the data can now be imported, so this bug is fixed!

Changed status from 'Open' to: 'Resolved'

Changed status from 'Open' to: 'Resolved'
Sign in to join this conversation.
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender-addons#37768
No description provided.