ptrepack几乎是我想要的,除了它只有覆盖或忽略重复路径的选项。下面的例子说明了我想用结构发生什么
输入文件一
/ (RootGroup) ''
/data_set_name (Group) 'group of images files'
/data_set_name_Set (EArray(7913, 128)) ''
/data_set_name/image_set_index (Table(3,)) ''
/data_set_name/i100 (Group) 'sift features and coordinates'
/data_set_name/i100/descriptors (Array(7913, 128)) 'sift descriptors'
/data_set_name/i100/locations (Array(7913, 4)) 'sift feature locations'
输入文件二
/ (RootGroup) ''
/data_set_name (Group) 'group of images files'
/data_set_name_Set (EArray(4328, 128)) ''
/data_set_name/image_set_index (Table(4,)) ''
/data_set_name/i1156 (Group) 'sift features and coordinates'
/data_set_name/i1156/descriptors (Array(4328, 128)) 'sift descriptors'
/data_set_name/i1156/locations (Array(4328, 4)) 'sift feature locations'
期望的输出
/ (RootGroup) ''
/data_set_name (Group) 'group of images files'
/data_set_name_Set (EArray(12241, 128)) ''
/data_set_name/image_set_index (Table(7,)) ''
/data_set_name/i100 (Group) 'sift features and coordinates'
/data_set_name/i100/descriptors (Array(7913, 128)) 'sift descriptors'
/data_set_name/i100/locations (Array(7913, 4)) 'sift feature locations'
/data_set_name/i1156 (Group) 'sift features and coordinates'
/data_set_name/i1156/descriptors (Array(4328, 128)) 'sift descriptors'
/data_set_name/i1156/locations (Array(4328, 4)) 'sift feature locations'
这样做的有效方法是什么?