pip下载离线依赖包

2020-09-15  本文已影响0人  612twilight

激活conda的python=3.6环境,然后下载requirement.txt里面定义的资源
建立一个download.bat脚本文件

@echo off
call :CurDIR "%cd%"
pause
goto :eof
:CurDIR
    echo %~nx1
    set DirName=%~nx1
    call activate py36
    pip download -d %DirName% -r requirement.txt -i https://pypi.tuna.tsinghua.edu.cn/simple

requirement.txt里面可以类似如下的配置

transformers==3.1.0
上一篇 下一篇

猜你喜欢

热点阅读