Update README.md
Browse files
README.md
CHANGED
|
@@ -70,24 +70,106 @@ These categories can be used for dataset balancing, conditional models, or evalu
|
|
| 70 |
|
| 71 |
## Data Format
|
| 72 |
|
| 73 |
-
|
| 74 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 75 |
```json
|
| 76 |
-
{
|
| 77 |
-
"
|
| 78 |
-
|
| 79 |
-
"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 80 |
},
|
| 81 |
-
"
|
| 82 |
-
"
|
| 83 |
-
"
|
|
|
|
|
|
|
| 84 |
},
|
| 85 |
-
"
|
| 86 |
-
|
| 87 |
-
|
| 88 |
-
|
| 89 |
-
"unit": "meters"
|
| 90 |
-
}
|
| 91 |
}
|
| 92 |
```
|
| 93 |
|
|
|
|
| 70 |
|
| 71 |
## Data Format
|
| 72 |
|
| 73 |
+
### Root Structure
|
| 74 |
+
The JSON file has two main top-level objects:
|
| 75 |
+
|
| 76 |
+
| Field | Type | Description |
|
| 77 |
+
|-------|------|-------------|
|
| 78 |
+
| `metadata` | object | Contains general information about the export |
|
| 79 |
+
| `bones` | object | Dictionary of bone objects keyed by bone names |
|
| 80 |
+
|
| 81 |
+
### Metadata Object
|
| 82 |
+
|
| 83 |
+
| Field | Type | Description |
|
| 84 |
+
|-------|------|-------------|
|
| 85 |
+
| `armature_name` | string | Name of the armature (e.g., "KIM_caucasian_male") |
|
| 86 |
+
| `export_time` | string | ISO 8601 timestamp of export |
|
| 87 |
+
| `blender_version` | string | Version of Blender used for export |
|
| 88 |
+
| `bone_count` | integer | Total number of bones in the armature |
|
| 89 |
+
| `end_bone_count` | integer | Number of end bones (bones without children) |
|
| 90 |
+
| `spaces_included` | array[string] | List of coordinate spaces included in the export |
|
| 91 |
+
| `note` | string | Usage note (e.g., replay instructions) |
|
| 92 |
+
|
| 93 |
+
### Bones Object
|
| 94 |
+
The `bones` object contains a dictionary where keys are bone names and values are bone objects.
|
| 95 |
+
|
| 96 |
+
#### Bone Object Structure
|
| 97 |
+
|
| 98 |
+
| Field | Type | Description |
|
| 99 |
+
|-------|------|-------------|
|
| 100 |
+
| `name` | string | Name of the bone (duplicates the dictionary key) |
|
| 101 |
+
| `local` | object | Transform data in bone's local space |
|
| 102 |
+
| `armature_space` | object | Transform data in armature space |
|
| 103 |
+
| `world_space` | object | Transform data in world space |
|
| 104 |
+
| `bone_length_armature_space` | float | Length of the bone in armature space |
|
| 105 |
+
| `parent` | string or null | Name of parent bone (null for root) |
|
| 106 |
+
| `has_children` | boolean | Whether this bone has child bones |
|
| 107 |
+
| `is_end_bone` | boolean | Whether this bone is an end bone (no children) |
|
| 108 |
+
|
| 109 |
+
#### Local Transform Object
|
| 110 |
+
|
| 111 |
+
| Field | Type | Description |
|
| 112 |
+
|-------|------|-------------|
|
| 113 |
+
| `location` | object | Translation vector as `{x, y, z}` |
|
| 114 |
+
| `rotation_quaternion` | object | Rotation as quaternion `{w, x, y, z}` |
|
| 115 |
+
| `scale` | object | Scale vector as `{x, y, z}` |
|
| 116 |
+
| `matrix_basis` | 4x4 array | 4x4 transformation matrix for pose |
|
| 117 |
+
| `rotation_mode` | string | Rotation representation method (always "QUATERNION") |
|
| 118 |
+
|
| 119 |
+
#### Armature Space Object
|
| 120 |
+
|
| 121 |
+
| Field | Type | Description |
|
| 122 |
+
|-------|------|-------------|
|
| 123 |
+
| `head` | object | Start point of bone as `{x, y, z}` |
|
| 124 |
+
| `tail` | object | End point of bone as `{x, y, z}` |
|
| 125 |
+
|
| 126 |
+
#### World Space Object
|
| 127 |
+
|
| 128 |
+
| Field | Type | Description |
|
| 129 |
+
|-------|------|-------------|
|
| 130 |
+
| `head` | object | Start point in world coordinates `{x, y, z}` |
|
| 131 |
+
| `tail` | object | End point in world coordinates `{x, y, z}` |
|
| 132 |
+
| `rotation_quaternion` | object | World rotation as quaternion `{w, x, y, z}` |
|
| 133 |
+
| `matrix` | 4x4 array | Complete 4x4 world transformation matrix |
|
| 134 |
+
|
| 135 |
+
### Coordinate Spaces Explanation
|
| 136 |
+
|
| 137 |
+
1. **LOCAL_CHANNELS**: Bone transformations relative to its rest pose (as shown in Blender's Transform panel)
|
| 138 |
+
2. **ARMATURE_SPACE**: Bone positions relative to armature origin
|
| 139 |
+
3. **WORLD_SPACE**: Bone positions in global scene coordinates
|
| 140 |
+
|
| 141 |
+
### Important Notes
|
| 142 |
+
|
| 143 |
+
- The `local.matrix_basis` field contains the exact pose transformation and should be used for precise pose replication
|
| 144 |
+
- Quaternion format uses `w` as the scalar component and `(x, y, z)` as the vector components
|
| 145 |
+
- All transformation matrices are 4x4 and stored in row-major order
|
| 146 |
+
- The `spaces_included` array indicates which coordinate spaces are available in the export
|
| 147 |
+
|
| 148 |
+
### Example Bone Entry
|
| 149 |
```json
|
| 150 |
+
"Root": {
|
| 151 |
+
"name": "Root",
|
| 152 |
+
"local": {
|
| 153 |
+
"location": {"x": 0.0, "y": 0.0, "z": 0.0},
|
| 154 |
+
"rotation_quaternion": {"w": 0.9998, "x": 0.0068, "y": -0.0153, "z": -0.0092},
|
| 155 |
+
"scale": {"x": 1.0, "y": 1.0, "z": 1.0},
|
| 156 |
+
"matrix_basis": [[...4x4 matrix...]],
|
| 157 |
+
"rotation_mode": "QUATERNION"
|
| 158 |
+
},
|
| 159 |
+
"armature_space": {
|
| 160 |
+
"head": {"x": 0.0, "y": 0.0707, "z": -0.0096},
|
| 161 |
+
"tail": {"x": 0.0013, "y": -0.0001, "z": -0.0010}
|
| 162 |
},
|
| 163 |
+
"world_space": {
|
| 164 |
+
"head": {"x": 0.0, "y": 0.1340, "z": 0.9403},
|
| 165 |
+
"tail": {"x": 0.0013, "y": 0.0631, "z": 0.9489},
|
| 166 |
+
"rotation_quaternion": {"w": 0.0606, "x": 0.9980, "y": 0.0082, "z": -0.0159},
|
| 167 |
+
"matrix": [[...4x4 world matrix...]]
|
| 168 |
},
|
| 169 |
+
"bone_length_armature_space": 0.0714,
|
| 170 |
+
"parent": null,
|
| 171 |
+
"has_children": true,
|
| 172 |
+
"is_end_bone": false
|
|
|
|
|
|
|
| 173 |
}
|
| 174 |
```
|
| 175 |
|