Caltech-AMBER / ambersim

In-house tools built on GPU-accelerated simulation
MIT License
7 stars 2 forks source link

Tensorboard logging #36

Closed vincekurtz closed 12 months ago

vincekurtz commented 12 months ago

Enables pretty plots for RL training like this one: image

ivandariojr commented 12 months ago

I don't think its a good idea to hardcode a particular logging platform. Tensorboard is kinda barebones and there are other alternatives that may fit better depending on the use case. Here are just a few options:

  1. https://wandb.ai
  2. https://mlflow.org/
  3. https://neptune.ai/
  4. https://www.comet.com/site/

I personally prefer wandb, but I think that depends on the particular project. It may be better to make logging something the user manages.

I think there are two choices for implementing some sort of generic logging interface:

  1. Implement a logging API with different backends (see pytorch lightning).
  2. Let the user manage logging of the metrics themselves.

A key issue that we would have to deal with is how exactly to display the metrics. Are they a time series? A plot? A heat map? What about logging a heat map every time step? Not every logging back-end supports the same things in the same way either so option 2 will have to have a limited scope similarly to the pytorch lightning implementation.

vincekurtz commented 12 months ago

I don't think its a good idea to hardcode a particular logging platform.

Agreed that we should let users determine the best way to log data for their application. The goal of this PR is just to provide a simple example of doing something a bit fancier than the hard-coded matplotlib in the MJX tutorial.