BorisGuo commited on
Commit
bc43eae
·
verified ·
1 Parent(s): 581298e

Upload README.md with huggingface_hub

Browse files
Files changed (1) hide show
  1. README.md +181 -9
README.md CHANGED
@@ -1,10 +1,182 @@
1
  ---
2
- license: mit
3
- language:
4
- - en
5
- tags:
6
- - tactile
7
- - force
8
- - Multimodal
9
- - h5
10
- ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
+ configs:
3
+ - config_name: pose_data
4
+ data_files: "pose_data/metadata.jsonl"
5
+ - config_name: force_data
6
+ data_files: "force_data/metadata.jsonl"
7
+ - config_name: tacniq_gsmini
8
+ data_files: "tacniq_gsmini/metadata.jsonl"
9
+ - config_name: xela_9dtact
10
+ data_files: "xela_9dtact/metadata.jsonl"
11
+ ---
12
+
13
+ # PairTouch 13M Dataset
14
+
15
+ Multi-modal tactile dataset with pose, force, and tactile sensor data.
16
+
17
+ ## Configs
18
+
19
+ | Config | Description | Sensors |
20
+ |--------|-------------|---------|
21
+ | `pose_data` | Pose estimation data | tac02/xela + camera |
22
+ | `force_data` | Force measurement data | tac02/xela + gelsight |
23
+ | `tacniq_gsmini` | TacNIQ + GSMini data | tacniq + gsmini |
24
+ | `xela_9dtact` | XELA + 9DTact data | xela + 9dtact |
25
+
26
+ ## Usage
27
+
28
+ ```python
29
+ from datasets import load_dataset
30
+
31
+ # Load specific config
32
+ ds = load_dataset("BorisGuo/pair_touch_13m", "pose_data")
33
+ ```
34
+
35
+ ## Tactile Sensors
36
+
37
+ ### tac02 / tacniq
38
+
39
+ - **Taxel layout**: 11 x 6 = 66 taxels
40
+ - **Force type**: Z-axis normal force only
41
+ - **Dead taxels**: Index 0 (top-left) and 5 (top-right) always read 0, should be ignored
42
+
43
+ ```
44
+ Taxel indices:
45
+ [ 0][ 1][ 2][ 3][ 4][ 5] <- Row 0 (index 0, 5 are dead)
46
+ [ 6][ 7][ 8][ 9][10][11] <- Row 1
47
+ ...
48
+ [60][61][62][63][64][65] <- Row 10
49
+ ```
50
+
51
+ ### xela
52
+
53
+ - **Taxel layout**: 4 x 6 = 24 taxels
54
+ - **Force type**: 3D force (X, Y, Z axes), total 72 values (24 x 3)
55
+ - **Data format**: Flattened as [x0, y0, z0, x1, y1, z1, ..., x23, y23, z23]
56
+
57
+ ## Sampling Frequency
58
+
59
+ ### force_data (1 tactile sample per frame)
60
+
61
+ | Dataset | Frame Rate | Tactile Sensor |
62
+ |---------|------------|----------------|
63
+ | 9dtact_force_h5 | ~10 Hz | - |
64
+ | gelsight_force_h5 | ~25 Hz | - |
65
+ | tac02_force_h5 | ~200 Hz | tac02 |
66
+ | xela_force_h5 | ~100 Hz | xela |
67
+
68
+ ### pose_data (multiple tactile samples per frame)
69
+
70
+ | Dataset | Frame Rate | Samples/Frame | Effective Tactile Rate |
71
+ |---------|------------|---------------|------------------------|
72
+ | tac02_pose_h5 | ~7.5 Hz | 20 | ~150 Hz |
73
+ | xela_pose_h5 | ~7.5 Hz | 10 | ~75 Hz |
74
+ | gelsight_pose_h5 | ~7.5 Hz | - | - |
75
+ | 9dtact_pose_h5 | ~7.5 Hz | - | - |
76
+
77
+ ### Paired sensor data
78
+
79
+ | Dataset | Frame Rate | Sensors |
80
+ |---------|------------|---------|
81
+ | tacniq_gsmini | 10 Hz | tacniq + gsmini |
82
+ | xela_9dtact | 10 Hz | xela + 9dtact |
83
+
84
+ ## Data Fields
85
+
86
+ - `file_name`: Path to image file
87
+ - `episode_id`: Episode identifier
88
+ - `frame_idx`: Frame index within episode
89
+ - `timestamp`: Timestamp
90
+ - `rotation`: 3D rotation
91
+ - `translation`: 3D translation
92
+ - `tactile`: tac02 sensor matrix (11x6 taxels, Z-axis only)
93
+ - `xela`: XELA sensor matrix (4x6x3 taxels, 3D force)
94
+ - `tacniq`: TacNIQ sensor matrix (same as tac02)
95
+ - `video`: Episode video path
96
+
97
+ ## Data Dimensions
98
+
99
+ - `images`: (N, S, 224, 224, 3) - N frames, S samples per frame
100
+ - `tactile` (pose_data): (N, 20, 66) - N frames, 20Hz sampling, 66 taxels (11x6)
101
+ - `xela` (pose_data): (N, 10, 72) - N frames, 10Hz sampling, 72 values (4x6x3)
102
+ - `tactile/xela` (force_data): (N, 66) or (N, 72) - 1 sample per frame
103
+
104
+ ## Preprocessing
105
+
106
+ Use `preprocess.py` for data processing:
107
+
108
+ ```bash
109
+ # Parse H5 files to JSON/images
110
+ python preprocess.py extract
111
+
112
+ # Check H5 structure (without parsing)
113
+ python preprocess.py extract --check
114
+
115
+ # Update metadata (add heatmap/video paths)
116
+ python preprocess.py extract --update
117
+
118
+ # Generate heatmaps
119
+ python preprocess.py heatmap
120
+ python preprocess.py heatmap --test # Test mode
121
+ python preprocess.py heatmap --type tac02_pose # Specific type
122
+
123
+ # Generate xela marker flow (point displacement visualization)
124
+ python preprocess.py marker_flow
125
+ python preprocess.py marker_flow --test
126
+ python preprocess.py marker_flow --type xela_pose
127
+
128
+ # Generate videos
129
+ python preprocess.py video
130
+ python preprocess.py video --test
131
+
132
+ # Pack images into tar files (reduce file count for HF upload)
133
+ python preprocess.py pack # Pack only
134
+ python preprocess.py pack --delete # Pack and delete original PNGs
135
+
136
+ # Unpack images from tar files
137
+ python preprocess.py unpack # Unpack only
138
+ python preprocess.py unpack --delete # Unpack and delete tar files
139
+
140
+ # Clean up (delete all PNGs, keep only videos)
141
+ python preprocess.py clean
142
+
143
+ # Upload to Hugging Face
144
+ python preprocess.py upload # 只上传/更新,不删除远端文件
145
+ python preprocess.py upload --sync # 同步模式:删除远端存在但本地不存在的文件
146
+
147
+ # Full pipeline (extract -> heatmap -> video -> update)
148
+ python preprocess.py all
149
+ ```
150
+
151
+ ### Heatmap Types
152
+
153
+ | Type | Description |
154
+ |------|-------------|
155
+ | `tac02_pose` | pose_data/tac02_pose_h5 |
156
+ | `xela_pose` | pose_data/xela_pose_h5 |
157
+ | `pose` | All pose_data |
158
+ | `tac02_force` | force_data/tac02_force_h5 |
159
+ | `xela_force` | force_data/xela_force_h5 |
160
+ | `force` | All force_data |
161
+ | `tacniq_gsmini` | tacniq_gsmini |
162
+ | `xela_9dtact` | xela_9dtact |
163
+ | `all` | Everything |
164
+
165
+ ### Video Types
166
+
167
+ | Type | Description |
168
+ |------|-------------|
169
+ | `9dtact_force` | force_data/9dtact_force_h5 |
170
+ | `xela_force` | force_data/xela_force_h5 |
171
+ | `gelsight_force` | force_data/gelsight_force_h5 |
172
+ | `tac02_force` | force_data/tac02_force_h5 |
173
+ | `gelsight_pose` | pose_data/gelsight_pose_h5 |
174
+ | `9dtact_pose` | pose_data/9dtact_pose_h5 |
175
+ | `tac02_pose` | pose_data/tac02_pose_h5 |
176
+ | `xela_pose` | pose_data/xela_pose_h5 |
177
+ | `xela_pose_flow` | pose_data/xela_pose_h5 marker_flow (video_flow.mp4) |
178
+ | `xela_force_flow` | force_data/xela_force_h5 marker_flow (video_flow.mp4) |
179
+ | `xela_9dtact_flow` | xela_9dtact marker_flow (video_flow.mp4) |
180
+ | `tacniq_gsmini` | tacniq_gsmini (video_gsmini.mp4 + video_tacniq.mp4) |
181
+ | `xela_9dtact` | xela_9dtact (video_9dtact.mp4 + video_xela.mp4) |
182
+ | `all` | Everything |