我正在尝试使用 tesseract-ocr 在程序中读取照片中的文本,但当我尝试按照他们的说明进行操作时安装我尝试运行时不断收到错误
sudo apt-get install libpng-dev
和
sudo apt-get install libtiff5-dev
他们都做了类似的事情:
$ sudo apt install libpng-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
libpng-tools
The following NEW packages will be installed:
libpng-dev libpng-tools
0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
Need to get 203 kB of archives.
After this operation, 703 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
Ign:1 http://security.ubuntu.com/ubuntu bionic-security/main amd64 libpng-dev amd64 1.6.34-1ubuntu0.18.04.1
Ign:2 http://security.ubuntu.com/ubuntu bionic-security/main amd64 libpng-tools amd64 1.6.34-1ubuntu0.18.04.1
Err:1 http://archive.ubuntu.com/ubuntu bionic-security/main amd64 libpng-dev amd64 1.6.34-1ubuntu0.18.04.1
404 Not Found [IP: 2001:67c:1360:8001::17 80]
Err:2 http://archive.ubuntu.com/ubuntu bionic-security/main amd64 libpng-tools amd64 1.6.34-1ubuntu0.18.04.1
404 Not Found [IP: 2001:67c:1360:8001::17 80]
E: Failed to fetch http://archive.ubuntu.com/ubuntu/pool/main/libp/libpng1.6/libpng-dev_1.6.34-1ubuntu0.18.04.1_amd64.deb 404 Not Found [IP: 2001:67c:1360:8001::17 80]
E: Failed to fetch http://archive.ubuntu.com/ubuntu/pool/main/libp/libpng1.6/libpng-tools_1.6.34-1ubuntu0.18.04.1_amd64.deb 404 Not Found [IP: 2001:67c:1360:8001::17 80]
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?
当我尝试跟踪链接时,它似乎只是在寻找错误的版本。我该如何让它寻找正确的版本?
答案1
你提到
看起来它只是在寻找错误的版本
因此使用以下命令更新你的机器的软件存储库列表
sudo apt update
这将更新您的机器上列出的源可用的软件包列表(包括版本)(在/etc/apt/sources.list
&中找到的源sources.list.d/
)