Utility for syncing training, validation, and evaluation data.
还没有人认领这个 Issue。
评估
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 新手友好度
- 25/100
- Issue 类型
- 功能
- 描述清晰度
- 基本清楚
- 活跃度
- 停滞
- 技术栈
- python
调研方向
首先定位 rs_trainer 的数据加载入口点,并检查 training、validation 和 evaluation 目录是如何匹配的。确定范围是一个独立的预处理工具、文档,还是一个用于忽略或删除未同步的掩码和切片的选项;完成意味着已针对不匹配的目录定义并验证所选行为。
由索引模型根据 Issue 内容生成。
描述
On most of the datasets I'm putting together, there is not always a 1-1 matching of masks to tiles. At the very least there should be clarification that the trainer needs a directory where all files are in sync. Even better would be to provide a simple pre-processing script for syncing the masks/tiles or in rs_trainer provide an option to ignore or remove un-synced masks/tiles.
Currently I just use a simple python script to sync the directory:
import os
import argparse
def dir_dict(dir: str) -> dict:
dd = {}
for subdir, dirs, files in os.walk(dir):
for file in files:
f = '/'.join(os.path.join(subdir, file).split("/")[-3:])
dd[f] = os.path.join(subdir, file)
return dd
def main():
parser = argparse.ArgumentParser()
parser.add_argument('dir1', type=str)
parser.add_argument('dir2', type=str)
args = parser.parse_args()
removed = []
dir1_dict = dir_dict(args.dir1)
dir2_dict = dir_dict(args.dir2)
for k, v in dir1_dict.items():
if not dir2_dict.get(k):
removed.append(v)
for k, v in dir2_dict.items():
if not dir1_dict.get(k):
removed.append(v)
for file in removed:
os.remove(file)
return len(removed)
if __name__ == "__main__":
print ( f"removed {main()} un-synced files" )
- 主要语言
- Python
- 星标
- 2.1k
- 派生
- 384
- PR 合并指标
- 30 天内没有已合并 PR
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 没有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
mapbox/robosat 的其他 Issue
-
难度 1/5 1 小时以内 新手友好度 35/100
-
难度 5/5 一周以上 新手友好度 20/100
-
难度 4/5 3-5 天 新手友好度 32/100
-
难度 3/5 1-2 天 新手友好度 30/100
-
Bringin own data未关闭
难度 5/5 一周以上 新手友好度 20/100
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 84/100
comet-ml/opik#9877 · 1 个 reaction ·
维护者通常 1 天内回复
-
resource-submission validation-passed
难度 1/5 1 小时以内 新手友好度 80/100
hesreallyhim/awesome-claude-code#3736 · 1 条评论 ·
-
area: trackers bug
难度 2/5 1-3 小时 新手友好度 82/100
维护者通常 1 天内回复
-
Review: WordPress copy/snapshot download media with no size cap and a hostname-only origin check未关闭performance product:quill
难度 2/5 1-3 小时 新手友好度 72/100
Community-Access/quill#2634 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 76/100
维护者通常 1 天内回复