BioMedAI-UCSC / InverseSR

[Early Accepted at MICCAI 2023] Pytorch Code of "InverseSR: 3D Brain MRI Super-Resolution Using a Latent Diffusion Model"
http://arxiv.org/abs/2308.12465
Apache License 2.0
39 stars 6 forks source link

Question about the autocoder and training data #8

Open Adele0108 opened 6 months ago

Adele0108 commented 6 months ago

Hi, there is no details about the encoder and decoder in the paper and code. I would like to ask what the specific model structure of the autocoder? And what's the information of training data, do they include the super resolution ground truth? Looking forward to your reply, thanks~

wendy-xiaozong commented 6 months ago

Hi, for the model part of this project, I use the model from this Brain LDM paper. You can find the autoencoder architecture here. I use the images from the IXI dataset, which are high resolution, and we create low-resolution images from them.

Sorry for my late reply.

06Liz commented 2 weeks ago

from pathlib import Path

Use environment variables to auto-detect whether we are running an a Compute Canada cluster:

Thanks to https://github.com/DM-Berger/unet-learn/blob/master/src/train/load.py for this trick.

COMPUTECANADA = False TMP = os.environ.get("SLURM_TMPDIR")

if TMP: COMPUTECANADA = True

if COMPUTECANADA: INPUT_FOLDER = Path(str(TMP)).resolve() / "work" / "inputs" MASK_FOLDER = Path(str(TMP)).resolve() / "work" / "inputs" / "masks" PRETRAINED_MODEL_FOLDER = Path(str(TMP)).resolve() / "work" / "trained_models" PRETRAINED_MODEL_DDPM_PATH = ( Path(str(TMP)).resolve() / "work" / "trained_models" / "ddpm" ) PRETRAINED_MODEL_VAE_PATH = ( Path(str(TMP)).resolve() / "work" / "trained_models" / "vae" ) PRETRAINED_MODEL_DECODER_PATH = ( Path(str(TMP)).resolve() / "work" / "trained_models" / "decoder" ) PRETRAINED_MODEL_VGG_PATH = ( Path(str(TMP)).resolve() / "work" / "trained_models" / "vgg16.pt" ) OUTPUT_FOLDER = Path(str(TMP)).resolve() / "work" / "outputs" else: INPUT_FOLDER = Path(file).resolve().parent.parent.parent / "data" / "IXI" MASK_FOLDER = Path(file).resolve().parent.parent / "masks" OASIS_FOLDER = Path(file).resolve().parent.parent.parent / "data" / "OASIS" PRETRAINED_MODEL_FOLDER = ( Path(file).resolve().parent.parent.parent / "data" / "trained_models" ) 这些预训练模型和数据你是怎么处理和下载的 @Adele0108

06Liz commented 1 week ago

Where the decoder is downloaded from