Retina+jpeg option?
还没有人认领这个 Issue。
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 35/100
- Issue 类型
- 功能
- 描述清晰度
- 需要澄清
- 活跃度
- 冷清
- 技术栈
- jupyter, jupyter-notebook
调研方向
该 issue 没有指明源文件或测试。首先跟踪 inline backend 如何处理 figure_format 设置和 Retina 尺寸调整,然后将 JPEG 的行为与链接的 Matplotlib issue 和 Stack Overflow 问题进行比较;完成的标准应是有一种定义明确且经过测试的方法,能够生成尺寸适当的 JPEG notebook 图片。
由索引模型根据 Issue 内容生成。
描述
I often work with complex matplotlib figures with millions of points, which I've been displaying in my notebooks using the ipython magic %config InlineBackend.figure_format = 'retina'. Unfortunately, these inline images are quite large in terms of file size.
I'm looking for general suggestions on how to reduce the size of my ipynb files, which can grow into the 10s or even hundreds of MB in size and become a bit unwieldy.
One thought I had was to switch to generating jpegs, but while it looks like I can meaningfully reduce the file size by switching the backend to jpeg and increasing the dpi to 2x:
from matplotlib import rcParams
%config InlineBackend.figure_format = 'jpeg'
rcParams['figure.dpi'] = 200
From this repo, it looks like I can dial in jpeg compression values, which should help reduce file size. However, I can't figure out how to size the jpegs appropriately for a retina display (they're twice as large as they should be, and slightly blurry). Is there a way to display jpegs in jupyter notebooks at similar resolution and size to the defaults provided by 'retina' mode?
See also:
Matplotlib issue
Stackoverflow question
- 主要语言
- Jupyter Notebook
- 星标
- 31
- 派生
- 39
- PR 合并指标
- 30 天内没有已合并 PR
贡献指南
这个仓库没有索引到贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
ipython/matplotlib-inline 的其他 Issue
-
难度 3/5 1-2 天 新手友好度 48/100
ipython/matplotlib-inline#61 ·
-
难度 3/5 1-2 天 新手友好度 35/100
ipython/matplotlib-inline#59 ·
-
难度 3/5 1-2 天 新手友好度 35/100
ipython/matplotlib-inline#57 · 1 个 reaction ·
-
难度 3/5 1-2 天 新手友好度 35/100
ipython/matplotlib-inline#54 · 1 条评论 ·
-
难度 2/5 1-3 小时 新手友好度 48/100
ipython/matplotlib-inline#44 · 1 条评论 ·
查看 ipython/matplotlib-inline 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 88/100
-
scope: charts status: waiting for maintainer
难度 2/5 1-3 小时 新手友好度 88/100
-
chore P3 plotly-internal size: 3 task
难度 2/5 1-3 小时 新手友好度 77/100
-
难度 2/5 1-3 小时 新手友好度 76/100
Live-Charts/LiveCharts2#2394 ·
-
难度 2/5 1-3 小时 新手友好度 65/100
jbkunst/highcharter#849 ·