필터 지우기
필터 지우기

Creting EPS file takes so much time

조회 수: 12 (최근 30일)
JAY PATEL
JAY PATEL 2023년 12월 28일
답변: Dinesh 2023년 12월 29일
I have attached the matlab figure. I have used following commands as well as "save as" option in the window.
exportgraphics(gcf,'myVectorFile.eps','BackgroundColor','none','ContentType','vector')
saveas(figure(1), 'Fig.eps', 'epsc')
It takes more than 5-6 hours or may be even more (I couldn't create one yet, it shows that it is in the process). MATLAB gets hanged.
Same goes for svg. svg can't be made either.
Without "painters" the figure looks very bad with very low resolution. I have given link to the matlab figure of my drive since it is 16 mb file.
https://drive.google.com/file/d/13YVgVgTZ2xlR-C2ofqlGMpGNdQvsbOVC/view?usp=drive_link

답변 (1개)

Dinesh
Dinesh 2023년 12월 29일
Hi Jay,
The figure appears to be a dense contour plot or a heatmap with a high number of data points. Such plots can be very resource-intensive to render as vector graphics. This is because vector graphics are rendered based on paths, which are defined by mathematical equations. A dense plot with many data points requires a large number of paths to be calculated and drawn. Each data point or line segment in the plot translates to a path in vector graphics. When there are thousands or millions of these, the file becomes very complex, making rendering, processing, and exporting very time consuming.
To render it faster, the complexity of the image needs to be reduced if you want to export everything as a vector.
You could also try approaches to rasterize some parts while keeping the other parts as vectors to speed up the rendering process, but as far as I know, MATLAB doesn't inherently support it. You might need to export the vector content and raster content separately after which you can combine them.
The following MATLAB File Exchange contribution might also help you:

카테고리

Help CenterFile Exchange에서 Printing and Saving에 대해 자세히 알아보기

태그

제품


릴리스

R2023a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by