Today I installed win10 LTSC 2019. I installed labelme using the pip command. I entered labelme in cmd, but it failed to start. The error is reported as follows:
It's strange, this problem did not exist on win10 home version 21H2 before. After searching the following online, some people said that going to the labelme installation directory to find the _main_.py file and running it with python can solve the problem. Reference link: Installation and use of the annotation tool labelme on Win10_Xiao Cui's blog in deep learning-CSDN blog_Win10 installation of labelme
So, I tried the following 3 methods:
Method 1:
Find the path of labelme.exe, for example, mine is C:\Users\Yan\AppData\Roaming\Python\Python37\Scripts, double-click to run it.
Method 2:
Find the installation path of labelme. For example, mine is C:\Users\Yan\AppData\Roaming\Python\Python37\site-packages\labelme. Go to the desktop to create a bat and copy the following content:
@echo off & title
cd /d %~dp0
C:
cd C:\Users\Yan\AppData\Roaming\Python\Python37\site-packages\labelme
start python __main__.py
exit
Then save it, which is equivalent to creating a desktop shortcut of labelme.exe. Double-click this bat to start labelme.
Method 3:
Find the path of labelme.exe, for example, mine is C:\Users\Yan\AppData\Roaming\Python\Python37\Scripts, go to the desktop to create a bat, and copy the following content: @echo off & title cd /
d
% ~dp0
C:
cd C:\Users\Yan\AppData\Roaming\Python\Python37\Scripts
start labelme.exe
exit
Then save it, which is equivalent to creating a desktop shortcut of labelme.exe. Double-click this bat to start labelme.