天天看点

windows下mmcv-full安装

主要是遇到这个问题:

ModuleNotFoundError: No module named ‘mmcv._ext‘

error: a member with an in-class initializer must be const

请使用:pytorch1.8.0   cuda11.1

安装步骤:

①设置 MSVC 编译器:下载Visual Studio2017和2019

    设置环境变量。添加 `C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.27.29110\bin\Hostx86\x64` 到 `PATH`。

    为了兼容性,我们使用 x86-hosted 以及 x64-targeted 版本,即路径中的 `Hostx86\x64` 。

    在cmd中运行cl

(base) PS C:\Users> cl
Microsoft (R) C/C++ Optimizing Compiler Version 19.27.29111 for x64
Copyright (C) Microsoft Corporation. All rights reserved.

usage: cl [ option... ] filename... [ /link linkoption... ]
           

②将系统语言更改为英语。控制面板 -> 地区-> 管理-> 非 Unicode 来进行语言转换.

继续阅读