This project is folked from diffusors
- Install the required libraries:
pip install pytorch_lightning wandb
- Log in to Weights & Biases:
wandb login
Replace the TensorBoard logger with the Weights & Biases logger as follows:
import wandb
from pytorch_lightning.loggers import WandbLogger
# Initialize wandb
wandb.init(project='my-project', entity='my-entity')
# Create a WandbLogger
wandb_logger = WandbLogger()
Please replace 'my-project' and 'my-entity' with your actual project and entity names.
- Training
python diffusors/segmentation_diffuser_two.py --train_samples 500 \
--val_samples 200 \
--test_samples 100 \
--datadir . \
--epochs 200 \
--devices 1 \
--strategy ddp \
--batch_size 2 \
--accelerator gpu \
--logsdir . \
--precision 16 \
--is_use_cycle True
MIT