gpt4 book ai didi

matlab - 如何提高 .png 输出中的横向图像分辨率?

转载 作者:行者123 更新时间:2023-12-04 18:54:30 25 4
gpt4 key购买 nike

情况:无法在 export_fig 的 .png 输出中增加横向分辨率
目标:每次迭代后获得越来越多的横向分辨率

我可以增加确定 y 轴方向的矩阵 (time) 中的点数。
时间轴在每次迭代中有 2 倍以上的点。 export_fig的输出在每次迭代中保持为正方形,导致峰值的幅度在每次迭代中越来越小。
伪代码

counter=1;
while (counter < 4);
potential=linspace(0,100, 200);
timeEndSeconds=counter*10;
time=linspace(0, timeEndSeconds, 2*timeEndSeconds);

% computere here anything to the presentation etc Sin
%Presentation = sin(time); % gives dimensions 1x20, but should be 1x200 i.e. asserted by potential`s linspace but not sure how to ensure it

width=50;
height=50;
figure('Position', [100 100 width height]);

imagesc(time, potential, Presentation);

filename=fullfile('/home/masi/Desktop/', counter);
% https://www.mathworks.com/matlabcentral/fileexchange/23629-export-fig
% TODO ensure here the specific resolution in time x potential for the image
export_fig(filename, '-png','-dpng', gcf);

counter=counter+1;
end

在研究选项时,我在文档中找不到有关 y 轴分辨率的任何信息。

基于 Suever 评论的提案

在循环中有以下内容,使图像分辨率加倍
% Use swap as described in http://askubuntu.com/q/799834/25388
if (counter > 1)
height=50;
width=50*counter;
set(gcf, 'Position', [100 100 width height]);
end

打开
  • linspace更好地集成到 Positionfigure ?

  • 系统:Linux Ubuntu 16.04 64 位
    MATLAB:2016a
    文档: here
    硬件:Macbook Air 2013-mid

    最佳答案

    Suever 的回答:调整身材的大小。
    动态情况有更好的环境,等在这些情况下使用 Mathematica。

    关于matlab - 如何提高 .png 输出中的横向图像分辨率?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/38460898/

    25 4 0
    Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
    广告合作:1813099741@qq.com 6ren.com