Unverified 提交 b5d851d6 authored 作者: huntr.dev | the place to protect open source's avatar huntr.dev | the place to protect open source 提交者: GitHub

Security Fix for Arbitrary Code Execution - huntr.dev (#1962)

上级 18c25889
...@@ -59,7 +59,7 @@ def train(hyp, opt, device, tb_writer=None, wandb=None): ...@@ -59,7 +59,7 @@ def train(hyp, opt, device, tb_writer=None, wandb=None):
cuda = device.type != 'cpu' cuda = device.type != 'cpu'
init_seeds(2 + rank) init_seeds(2 + rank)
with open(opt.data) as f: with open(opt.data) as f:
data_dict = yaml.load(f, Loader=yaml.FullLoader) # data dict data_dict = yaml.load(f, Loader=yaml.SafeLoader) # data dict
with torch_distributed_zero_first(rank): with torch_distributed_zero_first(rank):
check_dataset(data_dict) # check check_dataset(data_dict) # check
train_path = data_dict['train'] train_path = data_dict['train']
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论