├── .gitignore ├── LICENSE ├── README.md ├── checkpoints ├── .gitkeep ├── distilgpt2 │ └── .gitkeep ├── iu_x_ray_chen │ └── cvt_21_to_gpt2 │ │ └── .gitkeep ├── microsoft │ └── CvT │ │ └── .gitkeep └── mimic_cxr_jpg_chen │ └── cvt_21_to_gpt2 │ └── .gitkeep ├── config ├── test_iu_x_ray_chen_cvt2distilgpt2.yaml ├── test_mimic_cxr_chen_cvt2distilgpt2.yaml ├── train_iu_x_ray_chen_cvt2distilgpt2.yaml └── train_mimic_cxr_chen_cvt2distilgpt2.yaml ├── cvt2distilgpt2_iu_x_ray_chen.py ├── cvt2distilgpt2_mimic_cxr_chen.py ├── dataset ├── iu_x-ray_chen │ └── .gitkeep ├── mimic_cxr_chen │ └── .gitkeep └── mimic_cxr_jpg │ └── .gitkeep ├── docs ├── example.png └── figure.png ├── experiment ├── iu_x_ray_chen │ └── test_iu_x_ray_chen_cvt2distilgpt2 │ │ └── trial_0 │ │ └── generated_reports │ │ └── test_reports_epoch-0_16-05-2023_12-46-42.csv └── mimic_cxr_chen │ └── test_mimic_cxr_chen_cvt2distilgpt2 │ └── trial_0 │ └── generated_reports │ └── test_reports_epoch-0_16-05-2023_10-20-48.csv ├── requirements.txt ├── stages.py └── tools ├── chexbert.py ├── cvt.py ├── dataset ├── dataset.py ├── iu_x_ray_chen.py ├── iu_x_ray_chen_tokenizer.py ├── mimc_cxr_chen.py └── mimic_cxr_chen_tokenizer.py ├── encoder_projection.py ├── ext └── cvt │ ├── config │ ├── __init__.py │ └── default.py │ ├── core │ ├── evaluate.py │ ├── function.py │ └── loss.py │ ├── dataset │ ├── __init__.py │ ├── build.py │ ├── imagenet │ │ └── real_labels.py │ ├── samplers │ │ ├── __init__.py │ │ └── ra_sampler.py │ └── transformas │ │ ├── __init__.py │ │ └── build.py │ ├── experiments │ └── imagenet │ │ └── cvt │ │ ├── cvt-13-224x224.yaml │ │ ├── cvt-13-384x384.yaml │ │ ├── cvt-21-224x224.yaml │ │ ├── cvt-21-384x384.yaml │ │ └── cvt-w24-384x384.yaml │ ├── models │ ├── __init__.py │ ├── build.py │ ├── cls_cvt.py │ └── registry.py │ ├── optim │ ├── __init__.py │ └── build.py │ ├── scheduler │ ├── __init__.py │ └── build.py │ └── utils │ ├── comm.py │ └── utils.py ├── metrics ├── chexbert.py ├── coco.py ├── natural_language.py └── report_logger.py ├── multi_image.py └── utils.py /.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/.gitignore -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/LICENSE -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/README.md -------------------------------------------------------------------------------- /checkpoints/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /checkpoints/distilgpt2/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /checkpoints/iu_x_ray_chen/cvt_21_to_gpt2/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /checkpoints/microsoft/CvT/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /checkpoints/mimic_cxr_jpg_chen/cvt_21_to_gpt2/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /config/test_iu_x_ray_chen_cvt2distilgpt2.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/config/test_iu_x_ray_chen_cvt2distilgpt2.yaml -------------------------------------------------------------------------------- /config/test_mimic_cxr_chen_cvt2distilgpt2.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/config/test_mimic_cxr_chen_cvt2distilgpt2.yaml -------------------------------------------------------------------------------- /config/train_iu_x_ray_chen_cvt2distilgpt2.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/config/train_iu_x_ray_chen_cvt2distilgpt2.yaml -------------------------------------------------------------------------------- /config/train_mimic_cxr_chen_cvt2distilgpt2.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/config/train_mimic_cxr_chen_cvt2distilgpt2.yaml -------------------------------------------------------------------------------- /cvt2distilgpt2_iu_x_ray_chen.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/cvt2distilgpt2_iu_x_ray_chen.py -------------------------------------------------------------------------------- /cvt2distilgpt2_mimic_cxr_chen.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/cvt2distilgpt2_mimic_cxr_chen.py -------------------------------------------------------------------------------- /dataset/iu_x-ray_chen/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /dataset/mimic_cxr_chen/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /dataset/mimic_cxr_jpg/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /docs/example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/docs/example.png -------------------------------------------------------------------------------- /docs/figure.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/docs/figure.png -------------------------------------------------------------------------------- /experiment/iu_x_ray_chen/test_iu_x_ray_chen_cvt2distilgpt2/trial_0/generated_reports/test_reports_epoch-0_16-05-2023_12-46-42.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/experiment/iu_x_ray_chen/test_iu_x_ray_chen_cvt2distilgpt2/trial_0/generated_reports/test_reports_epoch-0_16-05-2023_12-46-42.csv -------------------------------------------------------------------------------- /experiment/mimic_cxr_chen/test_mimic_cxr_chen_cvt2distilgpt2/trial_0/generated_reports/test_reports_epoch-0_16-05-2023_10-20-48.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/experiment/mimic_cxr_chen/test_mimic_cxr_chen_cvt2distilgpt2/trial_0/generated_reports/test_reports_epoch-0_16-05-2023_10-20-48.csv -------------------------------------------------------------------------------- /requirements.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/requirements.txt -------------------------------------------------------------------------------- /stages.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/stages.py -------------------------------------------------------------------------------- /tools/chexbert.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/chexbert.py -------------------------------------------------------------------------------- /tools/cvt.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/cvt.py -------------------------------------------------------------------------------- /tools/dataset/dataset.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/dataset/dataset.py -------------------------------------------------------------------------------- /tools/dataset/iu_x_ray_chen.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/dataset/iu_x_ray_chen.py -------------------------------------------------------------------------------- /tools/dataset/iu_x_ray_chen_tokenizer.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/dataset/iu_x_ray_chen_tokenizer.py -------------------------------------------------------------------------------- /tools/dataset/mimc_cxr_chen.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/dataset/mimc_cxr_chen.py -------------------------------------------------------------------------------- /tools/dataset/mimic_cxr_chen_tokenizer.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/dataset/mimic_cxr_chen_tokenizer.py -------------------------------------------------------------------------------- /tools/encoder_projection.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/encoder_projection.py -------------------------------------------------------------------------------- /tools/ext/cvt/config/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/config/__init__.py -------------------------------------------------------------------------------- /tools/ext/cvt/config/default.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/config/default.py -------------------------------------------------------------------------------- /tools/ext/cvt/core/evaluate.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/core/evaluate.py -------------------------------------------------------------------------------- /tools/ext/cvt/core/function.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/core/function.py -------------------------------------------------------------------------------- /tools/ext/cvt/core/loss.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/core/loss.py -------------------------------------------------------------------------------- /tools/ext/cvt/dataset/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/dataset/__init__.py -------------------------------------------------------------------------------- /tools/ext/cvt/dataset/build.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/dataset/build.py -------------------------------------------------------------------------------- /tools/ext/cvt/dataset/imagenet/real_labels.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/dataset/imagenet/real_labels.py -------------------------------------------------------------------------------- /tools/ext/cvt/dataset/samplers/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/dataset/samplers/__init__.py -------------------------------------------------------------------------------- /tools/ext/cvt/dataset/samplers/ra_sampler.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/dataset/samplers/ra_sampler.py -------------------------------------------------------------------------------- /tools/ext/cvt/dataset/transformas/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/dataset/transformas/__init__.py -------------------------------------------------------------------------------- /tools/ext/cvt/dataset/transformas/build.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/dataset/transformas/build.py -------------------------------------------------------------------------------- /tools/ext/cvt/experiments/imagenet/cvt/cvt-13-224x224.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/experiments/imagenet/cvt/cvt-13-224x224.yaml -------------------------------------------------------------------------------- /tools/ext/cvt/experiments/imagenet/cvt/cvt-13-384x384.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/experiments/imagenet/cvt/cvt-13-384x384.yaml -------------------------------------------------------------------------------- /tools/ext/cvt/experiments/imagenet/cvt/cvt-21-224x224.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/experiments/imagenet/cvt/cvt-21-224x224.yaml -------------------------------------------------------------------------------- /tools/ext/cvt/experiments/imagenet/cvt/cvt-21-384x384.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/experiments/imagenet/cvt/cvt-21-384x384.yaml -------------------------------------------------------------------------------- /tools/ext/cvt/experiments/imagenet/cvt/cvt-w24-384x384.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/experiments/imagenet/cvt/cvt-w24-384x384.yaml -------------------------------------------------------------------------------- /tools/ext/cvt/models/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/models/__init__.py -------------------------------------------------------------------------------- /tools/ext/cvt/models/build.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/models/build.py -------------------------------------------------------------------------------- /tools/ext/cvt/models/cls_cvt.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/models/cls_cvt.py -------------------------------------------------------------------------------- /tools/ext/cvt/models/registry.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/models/registry.py -------------------------------------------------------------------------------- /tools/ext/cvt/optim/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/optim/__init__.py -------------------------------------------------------------------------------- /tools/ext/cvt/optim/build.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/optim/build.py -------------------------------------------------------------------------------- /tools/ext/cvt/scheduler/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/scheduler/__init__.py -------------------------------------------------------------------------------- /tools/ext/cvt/scheduler/build.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/scheduler/build.py -------------------------------------------------------------------------------- /tools/ext/cvt/utils/comm.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/utils/comm.py -------------------------------------------------------------------------------- /tools/ext/cvt/utils/utils.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/ext/cvt/utils/utils.py -------------------------------------------------------------------------------- /tools/metrics/chexbert.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/metrics/chexbert.py -------------------------------------------------------------------------------- /tools/metrics/coco.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/metrics/coco.py -------------------------------------------------------------------------------- /tools/metrics/natural_language.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/metrics/natural_language.py -------------------------------------------------------------------------------- /tools/metrics/report_logger.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/metrics/report_logger.py -------------------------------------------------------------------------------- /tools/multi_image.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/multi_image.py -------------------------------------------------------------------------------- /tools/utils.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aehrc/cvt2distilgpt2/HEAD/tools/utils.py --------------------------------------------------------------------------------