layerai-archive/sdk

Feature request: LayerLogger for Pytorch Lightning

Closed this issue ยท 5 comments

Pytorch Lightning is the most accepted model training framework among Pytorch community.

Currently it includes logger wrappers for MLFlow, Neptune, Tensorboard, WANDB etc: https://pytorch-lightning.readthedocs.io/en/stable/common/loggers.html

Would be great if LayerLogger class could be added.

Should be pretty straightforward to implement as we already have some callback loggers. Anything specific you want to see in the logs? @fcakyon

Being able to log hyperparams at the start, epoch-based metrics, predictions images/videos per epoch, confusion matrix images per epoch, and checkpoint files are the most essential functions for me.

This PR solves this issue I believe: #312 How to import the LayerLogger class?

I'm working on a notebook, I'll link it here shortly @fcakyon

@fcakyon Here you go:

from pytorch_lightning import Trainer

from layer import PytorchLightningLogger
layer_logger = PytorchLightningLogger(project_name='MNIST', api_key='[YOUR_API_KEY]')

trainer = Trainer(
        logger=layer_logger,
        accelerator='gpu', devices=1)  
trainer.fit(model, training_loader, validation_loader)

Notebook:
https://colab.research.google.com/drive/1ygiC7R-mozacXq_tSCAj8wBbUE05xTpN?usp=sharing