11

I was using a python package pdf2img, but I got an error asking me to check if I had installed poppler or not , so I ran "pip install python-poppler-qt5" in a code box in colab , but then I get the following error:

Collecting python-poppler-qt5 Using cached https://files.pythonhosted.org/packages/6a/7d/65a14ece5dd6a1564b576c1ca30b0f5639be64cc55b62b4d2b497159ed43/python-poppler-qt5-0.75.0.tar.gz
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.

can someone give me a solution to this?

Vadim Kotov
  • 8,084
  • 8
  • 48
  • 62
Akash
  • 195
  • 1
  • 3
  • 14

1 Answers1

18

Run a cell with the following command first:

!apt-get install poppler-utils 

Here's a complete example notebook that installs deps, downloads an example PDF, and then uses pdf2image to convert it to an image for display.

https://colab.research.google.com/drive/10doc9xwhFDpDGNferehBzkQ6M0Un-tYq

Bob Smith
  • 36,107
  • 11
  • 98
  • 91