Let your code take comprehensive notes and publish notes and figures as a beautiful consolidated PDF document.
Project description
Magazine
Let your code take comprehensive notes and publish notes and figures as a beautiful consolidated PDF document.
Idea
The magazine package helps you to create beautiful PDF reports of what has been done during the execution of your app.
- Your scripts or submodules can write Stories in plain human-readable text, which could also include numerical results or figures, for instance.
- The collection of stories can be used to Publish a glossy PDF document.
Example
from magazine import Story, Publish
E = 42
Story.report("Experiment", "The analysis found that energy equals {} Joule.", E)
Story.cite("10.1002/andp.19163540702")
with Publish("Report.pdf", "My physics report", info="Version 0.1") as M:
M.add_story("Experiment")
M.add_references()
- View the resulting magazine in output/Report.pdf.
- Check also
example.py
for more examples.
Install
pip install magazine
Requires:
- fpdf2
- habanero (for academic citations)
- neatlogger (wrapper for loguru)
Acknowledgements
- Uses the Google font Roboto as it just looks great in PDFs.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
magazine-0.2.2.tar.gz
(289.3 kB
view details)
Built Distribution
magazine-0.2.2-py3-none-any.whl
(291.3 kB
view details)
File details
Details for the file magazine-0.2.2.tar.gz
.
File metadata
- Download URL: magazine-0.2.2.tar.gz
- Upload date:
- Size: 289.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.4 CPython/3.10.11 Windows/10
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e10c61969f26782a8495889b53185662251fa771e09357a6d681ab2a013c6c8d |
|
MD5 | 6c25a45f1d225bb592ee07fbc8f5ba8d |
|
BLAKE2b-256 | 87b14898ac6a1c369fb7205888ab071713bbfd3e28f8b5201bf517f9831be74f |
File details
Details for the file magazine-0.2.2-py3-none-any.whl
.
File metadata
- Download URL: magazine-0.2.2-py3-none-any.whl
- Upload date:
- Size: 291.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.4 CPython/3.10.11 Windows/10
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1326fcd131f1ca4f99fb6a428527e63ce24ee52ef6ea0a213781f0a3d4ce3a24 |
|
MD5 | 4e569496d87ce7c4db529a99488832be |
|
BLAKE2b-256 | d903e19ad0898dc7ce5a0ed080146103ff4523a5b545b296dca4c473305e140a |