Windows 10에서 Ghostscript 가져 오기

Jan 06 2021

ghostscriptPython 으로 가져 오려고합니다.

를 입력 import ghostscript하면 다음과 같은 오류 메시지가 나타납니다.

역 추적 (최근 호출 마지막) : 파일 "<pyshell # 0>", 줄 1, 가져 오기 ghostscript 파일 "C : \ Users ... \ AppData \ Local \ Programs \ Python \ Python38-32 \ lib \ site-packages \ ghostscript_ init _.py ", 35 행,. import _gsprint as gs File "C : \ Users ... \ AppData \ Local \ Programs \ Python \ Python38-32 \ lib \ site-packages \ ghostscript_gsprint.py", line 505, in raise RuntimeError ( 'Can not find Ghostscript DLL 레지스트리에서 ') 런타임 오류 : 레지스트리에서 Ghostscript DLL을 찾을 수 없습니다.

Windows 10을 사용하고 있습니다.

Python 3.8.3, 32 비트를 사용하고 있음을 확인했습니다.

이 글타래를 찾았습니다 : Importing Ghostscript in Python on Windows 8 이지만별로 도움이되지 않았습니다.

어떤 제안?

고스트 스크립트 버전 32 비트 또는 64 비트를 사용하고 있는지 확인하는 방법을 잘 모르겠습니다.

편집 # 1 :

다음을 수행하여 Ghostscript를 설치했습니다. python -m pip install ghostscript

답변

1 JaapJorisVens Jan 06 2021 at 05:42

에 따르면 문서 는 ghostscriptPyPi 패키지는 고스트 스크립트의 기존 설치가 필요합니다

python-ghostscript에는

  • Python 2.7 이상 (Python 2.7, 3.4, 3.6 및 3.6에서 테스트 됨)
  • 설치를위한 설정 도구 (아래 참조)
  • Ghostscript 버전 8.x 이상 (9.x로 테스트 됨)

여기에서 Windows 용 Ghostscript를 다운로드 할 수 있습니다 .