# Issue with loading an eps file into a document

I'm having issue getting latex (Texworks on windows) to read in an eps file. I have had it working exactly as below before on an installation on different PC. Now I have installed tex and the interpreter on my laptop and the below no longer works. The error is related to some sort of draft setting:

! Package pdftex.def Error: File figures/TestingRecordedSignals_TEST-eps-conve


Anyone seen this before and have any suggestions?

\documentclass[superscriptaddress,aps,preprint,amsmath,amssymb,prb,floatfix,nobibnotes,10pt]{revtex4}
\usepackage{graphicx}
\usepackage{epstopdf}
\usepackage{float}
\begin{document}
\begin{figure}[H]
\centering
\includegraphics{figures/TestingRecordedSignals_TEST.eps}
\caption{Voltage Signals recorded during Wind Tunnel Testing}
\label{fig:PressureSignals}
\end{figure}
\end{document}

• Could you provide a download to the .eps file using Google Docs, Dropbox, or any other file sharing service? That way we can run the example code your provided. Which will hopefully help with finding the answer. – Flexo013 Jul 24 '18 at 12:26
• dropbox.com/s/ixbsh3lzkuegkeu/… – ARussell Jul 24 '18 at 12:41
• There's a link to the file. – ARussell Jul 24 '18 at 12:41
• The document works fine on my installation. I get this error message only if there is no subdirectory figure or if this directory does not contain TestingRecordedSignals_TEST.eps. Check whether the eps file is where LaTeX is looking for it. – gernot says Reinstate Monica Jul 24 '18 at 13:11
• do you have ghostscript installed on your machine? – David Carlisle Jul 24 '18 at 16:27

The draft mode is a fallback because the figure is not found. The missing TestingRecordedSignals_TEST-eps-converted-to.pdf is the pdf files suposed to be prodiced automatically, at compile time, by the package epspdf you loaded.

Are you sure that your .eps is actually in the "figure" subdirectory of the main folder, that is to say the folder containing your LaTeX file ?

I can't reproduce your error. Perhaps you could try:

• to put the .eps in the main directory
• or to convert the file "by hand" using ghostscript or ghostview or the ps2psf.exe utility provided by MikTeX with a command line like :

"C:\Program Files\MiKTeX 2.9\miktex\bin\x64\ps2pdf.exe" TestingRecordedSignals_TEST.eps TestingRecordedSignals_TEST.pdf

and then calling \includegraphics without extension:

\includegraphics{figures/TestingRecordedSignals_TEST}


Off-topic : there is no need of [H] here and hence not need for float.

Edit: (minimal) command to use wit ghostscript:

"C:\Program Files\gs\gs9.18\bin\gswin64c.exe"  -dEPSCrop -sDEVICE=pdfwrite  -o TestingRecorded.pdf TestingRecorded.eps


where the path to gswin64c.exe should be adapted to your installation.

• I tried putting it in the main directory and still the same error. I've downloaded ghostscript now but haven't figured out how to use it yet. – ARussell Jul 24 '18 at 14:51
• Is there a simple way to test eps2pdf is working outside of latex? As that seems to be the issue. – ARussell Jul 24 '18 at 14:56
• Fot ghostscript, see the edit in my answer. – Jhor Jul 24 '18 at 15:00
• Ok so I tested just using eps2pdf directly in command prompt (understood how that works more than gs tbh) and that worked fine. Placing the new pdf in the figure folder also worked fine when i remove the .eps at the end of it. Any suggestions as to how to get this to work in latex given that its definitely in the correct location and the epstopdf application works fine by itself? – ARussell Jul 24 '18 at 15:10
• eps2pdf is an utility based on ghostscript and TTBOMK it has nothing to do with the epspdf` package. So yout diagnostic is is not correct. Is your MikTeX up to date? – Jhor Jul 24 '18 at 15:19