Problem with export_fig - eps2pdf
조회 수: 3 (최근 30일)
이전 댓글 표시
I keep receiving the following error code when trying to use export_fig for .eps images. I have the latest copy of export_fig, Ghostscript, Xpdfreader/tools (pdftops), and I don't think I'm making any syntactical errors since I can save a .png without error.
Ghostscript error: perhaps C:\Users\-\AppData\Local\Temp\tp0529ef87_f6a2_44f2_bcb9_a061dc5608cf.pdf is open by another application
or maybe you have another gs executable in your system's path
Ghostscript options: -q -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -dPDFSETTINGS=/prepress -sOutputFile="C:\Users\-\AppData\Local\Temp\tp0529ef87_f6a2_44f2_bcb9_a061dc5608cf.pdf" -dEPSCrop -sFONTPATH="C:\Windows\Fonts" -f "C:\Users\-\AppData\Local\Temp\tp9407d70e_bf3a_43bd_b0f1_b3d1844f732e.eps"
export_fig error. Please ensure:
that you are using the latest version of export_fig
and that you have Ghostscript installed
and that you have pdftops installed
and that you do not have multiple versions of export_fig installed by mistake
and that you did not made a mistake in the expected input arguments
If the problem persists, then please report a new issue.
Error using eps2pdf (line 164)
Error: /syntaxerror in -file-
Operand stack:
Execution stack:
%interp_exit .runexec2 --nostringval-- --nostringval-- --nostringval-- 2 %stopped_push --nostringval-- --nostringval--
--nostringval-- false 1 %stopped_push 2015 1 3 %oparray_pop 2014 1 3 %oparray_pop --nostringval-- 1998 1 3
%oparray_pop 1884 1 3 %oparray_pop --nostringval-- %errorexec_pop .runexec2 --nostringval-- --nostringval--
--nostringval-- 2 %stopped_push
Dictionary stack:
--dict:996/1684(ro)(G)-- --dict:0/20(G)-- --dict:123/200(L)--
Current allocation mode is local
Last OS error: No such file or directory
Current file position is 7908
GPL Ghostscript 9.22: Unrecoverable error, exit code 1
Error in export_fig (line 674)
eps2pdf(tmp_nam, pdf_nam_tmp, 1, options.append, options.colourspace==2, options.quality, options.gs_options);
Error in Data_V1 (line 1288)
export_fig TEST -transparent -eps
I know it's a bit of a long shot, but I would appreciate any suggestions.
댓글 수: 0
답변 (1개)
Jan
2017년 10월 21일
Start with checking the error message:
C:\Users\-\AppData\Loca\Temp\tp0529ef87_f6a2_44f2_bcb9_a061dc5608cf.pdf
Is this really a "-" in the user name? Does the file exist? Is it opened by another process?
or maybe you have another gs executable in your system's path
Please check this also.
p = strsplit(getenv('PATH'), pathsep);
Are there several GhostScripts installed?
댓글 수: 2
Jan
2017년 10월 23일
You can check this without uninstalling MiKTeX: Only remove its folder from the PATH (of Windows, not of Matlab) temporarily and try it again.
The message "Last OS error: No such file or directory" looks important.
참고 항목
카테고리
Help Center 및 File Exchange에서 Get Started with MATLAB에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!