[yt-dev] Change the default plot size?

Kacper Kowalik xarthisius.kk at gmail.com
Sun Mar 16 14:50:58 PDT 2014


On 16.03.2014 19:47, Nathan Goldbaum wrote:
> On Sun, Mar 16, 2014 at 11:42 AM, John Wise <jwise at physics.gatech.edu>wrote:
> 
>> Hi Nathan,
>>
>> I think the default image size is fine at 1000x1000px, which fits on a
>> 1920x1080 screen nicely.  Screen resolution is going to continue
>> increasing, and I don't think it's a good idea to decrease the default.  If
>> anything, it should increase in the future.  For data inspection, I'd
>> rather scroll around large (e.g. 4000x4000) image than zooming/re-centering
>> a 600x600 image numerous times.
>>
>> Also, I agree with Matt that we shouldn't be optimizing for notebook
>> operation yet.  Although notebooks are great for interactivity, I find it
>> painfully slow to edit and re-run scripts (even with keyboard shortcuts)
>> when compared to an editor + image viewer.
>>
>> Is there a way to make the plot window aware that it's embedded in a
>> notebook and adjust the default image size accordingly?  I think that would
>> be a good plan, if it's technically possible.
>>
> 
> Unfortunately no.  See this e-mail thread:
> http://mail.scipy.org/pipermail/ipython-dev/2014-February/013234.html
> 
> We could scale down the plot using css, but I don't think that's a good
> solution since it will make the axes text, tick marks, and colorbar label
> harder to read.

Hi Nathan,
you could make PlotWindow respect default figsize from InlineBackend.rc.
AFAIR, but of course this needs to be verified, this dict is defined
only for ipython notebook --inline, and the default figsize is 6' x 4'
Cheers,
Kacper

> 
>>
>> Cheers,
>> John
>>
>>
>> On 03/16/2014 01:42 PM, Nathan Goldbaum wrote:
>>
>>> Hi all,
>>>
>>> I recently opened a PR that fixes a number of bugs in yt's plotting
>>> code.  Hopefully this will fix many common visual issues that show up in
>>> yt plots.
>>>
>>> As part of the PR I decided to change the default size of yt plots from
>>> 8 inches to 6.  My justification is that the current default will create
>>> a plot that overflows an IPython notebook output cell, particularly on
>>> small displays.
>>>
>>> The PR is here:
>>> https://bitbucket.org/yt_analysis/yt/pull-request/723/
>>> fixing-some-longstanding-issues-with-plot/diff#comment-1433174
>>>
>>> The discussion about the figure size is here:
>>> https://bitbucket.org/yt_analysis/yt/pull-request/723/
>>> fixing-some-longstanding-issues-with-plot/diff#comment-1432943
>>>
>>> As I mention in the PR description I'm willing to back down on this
>>> change if the consensus is that this is a bad idea.
>>>
>>> Matt has already come out against the change, but before I revert it I
>>> wanted to bring it up here and get opinions from other people.
>>>
>>> Thanks for your help :)
>>>
>>> -Nathan
>>>
>>>
>>> _______________________________________________
>>> yt-dev mailing list
>>> yt-dev at lists.spacepope.org
>>> http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org
>>>
>>>
>> --
>> John Wise
>> Assistant Professor of Physics
>> Center for Relativistic Astrophysics, Georgia Tech
>> http://cosmo.gatech.edu
>>
>> _______________________________________________
>> yt-dev mailing list
>> yt-dev at lists.spacepope.org
>> http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org
>>
> 
> 
> 
> _______________________________________________
> yt-dev mailing list
> yt-dev at lists.spacepope.org
> http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org
> 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 901 bytes
Desc: OpenPGP digital signature
URL: <http://lists.spacepope.org/pipermail/yt-dev-spacepope.org/attachments/20140316/e66712b8/attachment.sig>


More information about the yt-dev mailing list