atlogger
Python decorator to log artifacts with mlflow, wandb, rerun, etc
Inspired by the talks with colleagues, frustrating nights and the python logging documentation I am attempting to develop a module to streamline the proper logging for model training and comparisons
How to use
export WANDB_API_KEY="wandb_key"
# main.py
from atlogger import ATLOGGER, WandbHandler
ATLOGGER.addHandler(
WandbHandler(
project="your_project_name",
config={"config":True},
level="DEBUG"
)
)
# lossFunc.py
from atlogger import log
@log
loss(x1,x2):
return abs(x1 - x2)
@log("euclidean distance")
calc_distance(x1,x2):
return sqrt(x1**2 - x2**2)
Principles
Ideally this project will have the following principles:
- Non-intrusive:
- Snippets used for logging shouldn't be in the middle of the code. Anyone should be able to import code from one project to another without having to go through and delete or change lines throughout the functions.
- Modular:
- Added visualizations should be easy to add and be defined on their own and reused anywhere needed.
- Explicit:
- Logging shall not happen under the hood. you should be able to define and easily recognize when information is being logged but also have sensible defaults as not to loose important information that is constantly ignored (i.e. logging hardware load during ML models training)
- Adaptable:
- I want to be able to use this tool for logging diverse kinds of code and easily change between them:
- Ml training
- Compression algorithms
- async algorithms
- I want to be able to use this tool for logging diverse kinds of code and easily change between them:
Known bugs
- if you use the decorator as @log instead of @log()the function will be passed as the variable "names" for some reason
- Curently not accepting multiple outputs from functions
- Creating the wandbhandler within config file for some reason does not get to this part of the login
wandb: Currently logged in as: <usr> to https://api.wandb.ai. Use `wandb login --relogin` to force relogin - running logger inside jupyter notebook ony works for one cell
Current Goals
- Add a basic implementation of mlflow, rerun, profiling
- Only uses packages you have installed
- Enable choice of what happens if logging fail: break, or ignore
- Continue experiments
- Log artifacts like images or models
- Pass custom logger and custom formatter per call
- add custom ENUMs instead of DEBUG, WARN, INFO...
Metadata
Release files for atlogger 0.0.3
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 | |
|---|---|---|---|---|
| atlogger-0.0.3.tar.gz | 6.1 kB | With provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| atlogger-0.0.3-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 12.5 kB
Release files / atlogger-0.0.3.tar.gz
| Download URL | atlogger-0.0.3.tar.gz |
|---|---|
| Size | 6.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ca08e76763e4b5002b65698cdd3ded1a83fbe45939e3fd8e1543f91f2b3d838b
|
|
BLAKE2b-256 checksum How to use checksums |
46e9898438e0947fd036289219d973fcd0836fd6e6cd55057eb351aef3feb4b1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 1, 2026.
Transparency logRelease files / atlogger-0.0.3-py3-none-any.whl
| Download URL | atlogger-0.0.3-py3-none-any.whl |
|---|---|
| Size | 6.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
17a2b4d1507ad303a4a5ab0229e153197b949d756222edf952b6c69560f9b9b7
|
|
BLAKE2b-256 checksum How to use checksums |
3abb7df36065000af3835a9f9226b3c5fc821a7c51d001aaddb2ba3c7a4015f4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 1, 2026.
Transparency logSecurity for atlogger 0.0.3
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.
Full provenance
All 2 files in this release have been uploaded with provenance metadata.
Attestation for atlogger-0.0.3.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 1, 2026.
Transparency logA 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.