You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
visualizer raise e wand.exceptions.PolicyError: attempt to perform an operation not allowed by the security policy `PDF' @ error/constitute.c/IsCoderAuthorized/408
#81
Open
eng-khaled1 opened this issue
Nov 12, 2020
· 1 comment
Describe the bug
as described in the max_storage_temp_tutorial i tried to display the candidates as follow :
vis = Visualizer(pdf_path)
# Get a list of candidates that match the FN[10] entity
fp_cands = entity_to_candidates(FP[10], test_cands[0])
# Display a candidate
vis.display_candidates([fp_cands[0]])
but it raises the following :
Error Logs/Screenshots
Traceback (most recent call last):
File "/home/khaled/PycharmProjects/pythonProject2/main.py", line 437, in <module>
vis.display_candidates([fp_cands[0]])
File "/home/khaled/.local/lib/python3.8/site-packages/fonduer/utils/visualizer.py", line 90, in display_candidates
imgs = self.display_boxes(pdf_file, boxes, alternate_colors=True)
File "/home/khaled/.local/lib/python3.8/site-packages/fonduer/utils/visualizer.py", line 60, in display_boxes
img = pdf_to_img(pdf_file, page_num)
File "/home/khaled/.local/lib/python3.8/site-packages/fonduer/utils/visualizer.py", line 168, in pdf_to_img
img = Image(filename=f"{pdf_file}[{page_num - 1}]")
File "/home/khaled/.local/lib/python3.8/site-packages/wand/image.py", line 8293, in __init__
self.read(filename=filename, resolution=resolution,
File "/home/khaled/.local/lib/python3.8/site-packages/wand/image.py", line 8774, in read
self.raise_exception()
File "/home/khaled/.local/lib/python3.8/site-packages/wand/resource.py", line 243, in raise_exception
raise e
wand.exceptions.PolicyError: attempt to perform an operation not allowed by the security policy `PDF' @ error/constitute.c/IsCoderAuthorized/408
Environment (please complete the following information):
OS: [ Ubuntu 20.04]
PostgreSQL Version: [ 12.0]
Poppler Utils Version: [ 0.86.1]
Fonduer Version: [0.8.3]
many thanks
The text was updated successfully, but these errors were encountered:
Describe the bug
as described in the max_storage_temp_tutorial i tried to display the candidates as follow :
but it raises the following :
Error Logs/Screenshots
Environment (please complete the following information):
many thanks
The text was updated successfully, but these errors were encountered: