数据标注工具label studio+sam

Label-Studio X SAM 半自动化标注

Label Studio 是一个开源的数据标注工具,支持标注多类型数据,输出多格式。包括标注音频、文本、图像、视频和时间序列数据,可输出mask图片、yolo、voc、coco等;可借助sam辅助标注

服务部署

docker环境构建

FROM ultralytics/yolov5:v6.1
RUN apt update 
RUN pip install  label-studio==1.7.3  -i  https://pypi.tuna.tsinghua.edu.cn/simple   
RUN pip install label-studio-ml==1.0.9 -i  https://pypi.tuna.tsinghua.edu.cn/simple  
RUN pip install  segment_anything_hq  -i  https://pypi.tuna.tsinghua.edu.cn/simple  
RUN pip install  timm  -i  https://pypi.tuna.tsinghua.edu.cn/simple  
相关下载路径
git clone https://github.com/open-mmlab/playground
wget https://dl.fbaipublicfiles.com/segment_anything/sam_vit_b_01ec64.pth
#### 分割的效果好使用 sam_vit_h_4b8939.pth
wget https://dl.fbaipublicfiles.com/segment_anything/sam_vit_l_0b3195.pth
wget https://dl.fbaipublicfiles.com/segment_anything/sam_vit_h_4b8939.pth

服务部署

cd /project/playground-main/label_anything
nohup label-studio-ml start sam --port 8003 --with \
sam_config=vit_b \
sam_checkpoint_file=/project/weights/sam_vit_b_01ec64.pth \
out_mask=True \
out_bbox=True \
out_poly=True \
device=cuda:0 &
sleep 10
export ML_TIMEOUT_SETUP=40
label-studio start

使用教程 服务地址: http://0.0.0.0:8080/

相关配置

<View>
  <Image name="image" value="$image" zoom="true"/>
  <KeyPointLabels name="KeyPointLabels" toName="image">
    <Label value="cat" smart="true" background="#e51515" showInline="true"/>
    <Label value="person" smart="true" background="#412cdd" showInline="true"/>
  </KeyPointLabels>
  <RectangleLabels name="RectangleLabels" toName="image">
   <Label value="cat" background="#FF0000"/>
   <Label value="person" background="#0d14d3"/>
  </RectangleLabels>
  <PolygonLabels name="PolygonLabels" toName="image">
   <Label value="cat" background="#FF0000"/>
   <Label value="person" background="#0d14d3"/>
  </PolygonLabels>
  <BrushLabels name="BrushLabels" toName="image">
   <Label value="cat" background="#FF0000"/>
   <Label value="person" background="#0d14d3"/>
  </BrushLabels>
</View>
  • 2
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值