mpl_sizes
A lightweight tool for setting figsize and font sizes in matplotlib, with support for:
- ICLR
- ICML
- NeurIPS
- Informatics thesis
Installation
Install via pip:
pip install mpl-sizes
Install from source:
git clone git@github.com:BayesWatch/mpl_sizes.git
cd mpl_sizes
python setup.py install
Usage
In your plotting script:
import matplotlib.pyplot as plt
from mpl_sizes import get_format
formatter = get_format("InfThesis") # options: ICLR, ICML, NeurIPS, InfThesis
fig, ax = plt.subplots(figsize=formatter.text_width_plot())
Formatters have two methods:
text_width_plot- for full pagewidth plots (e.g. in double column, this would be a full width plot)line_width_plot- for plots the width of the lines of text
and font size will automatically be set correctly.
A full example is given in example.py.
You can also set aspect ratio to be: "narrow", "normal", "wide", or "equal".
Aspect ratios
You can also set aspect ratio to be: "narrow", "normal", "wide", or "equal".
e.g.
A single column width plot for ICML:
A double column width plot in wide aspect ratio:
Metadata
Release files for mpl-sizes 0.0.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| mpl_sizes-0.0.2.tar.gz | 3.5 kB | Without provenance | Details for mpl_sizes-0.0.2.tar.gz |
Release files / mpl_sizes-0.0.2.tar.gz
| Download URL | mpl_sizes-0.0.2.tar.gz |
|---|---|
| Size | 3.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
8dbedc5b969f816a4463c49440d0c6df79526f4192a76d548896714c67859d19
|
|
BLAKE2b-256 checksum How to use checksums |
e462945634982561bc2cdd3b6d9710661bd8f9d60f088e7f2c89e2858b3f7096
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.1 importlib_metadata/4.5.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.1 CPython/3.8.10
|
Security for mpl-sizes 0.0.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.