CheXmask: a large-scale dataset of anatomical segmentation masks for multi-center chest x-ray images
Paper
• 2307.03293 • Published
Error code: DatasetGenerationCastError
Exception: DatasetGenerationCastError
Message: An error occurred while generating the dataset
All the data files must have the same columns, but at some point there are 3 new columns ({'atelectasis, right&base', '0.1', '0.2'}) and 5 missing columns ({'Answer', 'Unnamed: 0', 'Instruction', 'ID', 'Task'}).
This happened while the csv dataset builder was generating data using
hf://datasets/MedHK23/IMT-CXR/MIMIC_classification-location_train.tsv (at revision a6a26a6d66a4972de315c142888742b404387ab8)
Please either edit the data files to have matching columns, or separate them into different configurations (see docs at https://hf.co/docs/hub/datasets-manual-configuration#multiple-configurations)
Traceback: Traceback (most recent call last):
File "/src/services/worker/.venv/lib/python3.9/site-packages/datasets/builder.py", line 1870, in _prepare_split_single
writer.write_table(table)
File "/src/services/worker/.venv/lib/python3.9/site-packages/datasets/arrow_writer.py", line 622, in write_table
pa_table = table_cast(pa_table, self._schema)
File "/src/services/worker/.venv/lib/python3.9/site-packages/datasets/table.py", line 2292, in table_cast
return cast_table_to_schema(table, schema)
File "/src/services/worker/.venv/lib/python3.9/site-packages/datasets/table.py", line 2240, in cast_table_to_schema
raise CastError(
datasets.table.CastError: Couldn't cast
0: int64
0.1: int64
0.2: int64
atelectasis, right&base: string
-- schema metadata --
pandas: '{"index_columns": [{"kind": "range", "name": null, "start": 0, "' + 710
to
{'Unnamed: 0': Value(dtype='int64', id=None), '0': Value(dtype='int64', id=None), 'ID': Value(dtype='int64', id=None), 'Instruction': Value(dtype='string', id=None), 'Answer': Value(dtype='string', id=None), 'Task': Value(dtype='string', id=None)}
because column names don't match
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/src/services/worker/src/worker/job_runners/config/parquet_and_info.py", line 1417, in compute_config_parquet_and_info_response
parquet_operations = convert_to_parquet(builder)
File "/src/services/worker/src/worker/job_runners/config/parquet_and_info.py", line 1049, in convert_to_parquet
builder.download_and_prepare(
File "/src/services/worker/.venv/lib/python3.9/site-packages/datasets/builder.py", line 924, in download_and_prepare
self._download_and_prepare(
File "/src/services/worker/.venv/lib/python3.9/site-packages/datasets/builder.py", line 1000, in _download_and_prepare
self._prepare_split(split_generator, **prepare_split_kwargs)
File "/src/services/worker/.venv/lib/python3.9/site-packages/datasets/builder.py", line 1741, in _prepare_split
for job_id, done, content in self._prepare_split_single(
File "/src/services/worker/.venv/lib/python3.9/site-packages/datasets/builder.py", line 1872, in _prepare_split_single
raise DatasetGenerationCastError.from_cast_error(
datasets.exceptions.DatasetGenerationCastError: An error occurred while generating the dataset
All the data files must have the same columns, but at some point there are 3 new columns ({'atelectasis, right&base', '0.1', '0.2'}) and 5 missing columns ({'Answer', 'Unnamed: 0', 'Instruction', 'ID', 'Task'}).
This happened while the csv dataset builder was generating data using
hf://datasets/MedHK23/IMT-CXR/MIMIC_classification-location_train.tsv (at revision a6a26a6d66a4972de315c142888742b404387ab8)
Please either edit the data files to have matching columns, or separate them into different configurations (see docs at https://hf.co/docs/hub/datasets-manual-configuration#multiple-configurations)Need help to make the dataset viewer work? Make sure to review how to configure the dataset viewer, and open a discussion for direct support.
Unnamed: 0 int64 | 0 int64 | ID int64 | Instruction string | Answer string | Task string |
|---|---|---|---|---|---|
0 | 1 | 0 | describe the image | extensive subcutaneous emphysema involving the entire chest and lower neck is unchanged . evaluation of the lungs is limited due to linear opacities from subcutaneous air collections . within this limitation, a small right apical pneumothorax likely persists . pleural fluid is small in amount, if any . there is increased opacification of the the right lung base, likely reflecting collapse . the cardiomediastinal contours are within normal limits . extensive pneumomediastinum is not significantly changed from . . persistent tiny right apical pneumothorax . . no significant change in pneumomediastinum . . extensive subcutaneous emphysema, similar to prior exam . | report generation |
1 | 2 | 1 | Is Mass in this image? | no Mass. | classification |
2 | 3 | 2 | describe the image | no focal consolidation is seen . there is minimal biapical pleural thickening . no pleural effusion or pneumothorax is seen . the cardiac and mediastinal silhouettes are unremarkable . external jewelry overlie the lower chest . no acute cardiopulmonary process . no focal consolidation to suggest pneumonia . | report generation |
3 | 4 | 3 | give the accurate bbox of Cardiomegaly | 342,539,690,729 | localization |
4 | 5 | 4 | describe the image | been no change since in moderate cardiomegaly, pulmonary vascular engorgement, and small bilateral pleural effusions . no pneumothorax . | report generation |
5 | 6 | 5 | describe the image | left chest wall pacer device is again seen with leads extending to the region of the right atrium and right ventricle unchanged and with an intact appearance . midline sternotomy wires and mediastinal clips are again noted . the cardiomediastinal silhouette remains prominent though not significantly changed . low lung volumes limit the assessment . there is mild pulmonary edema with probable small bilateral pleural effusions . no pneumothorax . bony structures are intact . cardiomegaly, mild edema, small bilateral pleural effusions . | report generation |
6 | 7 | 6 | describe the image | persistent cardiomegaly accompanied by worsening pulmonary vascular congestion and mild-to-moderate pulmonary edema as well as enlarging right pleural effusion, now moderate in size and associated with adjacent atelectasis in the right mid and lower lung regions . focal rounded opacity lateral to the left infrahilar region may represent a focus of coalescing edema, but differential diagnosis includes focal aspiration and developing infection . attention to this region on a short-term followup radiograph is suggested . | report generation |
7 | 8 | 7 | please segment the heart from the given image. | 203,319,196,299,197,278,202,256,207,233,210,213,216,199,227,192,238,187,249,187,261,187,271,186,285,194,304,209,329,229,354,246,374,265,386,291,384,317,367,335,344,345,320,350,295,350,271,349,248,345,222,335,203,319,196,299,197,278,202,256 | segmentation |
8 | 9 | 8 | give the accurate bbox of Cardiomegaly | 579,348,843,717 | localization |
Our OmniFM-Dr framework introduces a multi-task chest x-ray dataset, which is used for the joint training of disease classification, localization, segmentation, and report generation. This dataset comprises various publicly available datasets, such as MIMIC-CXR, VinDr-CXR, and ChestX-Det10. For each image, it can potentially contribute to multiple tasks, such as report generation and classification.
NOTE: Due to requirements related to data compliance and other regulations, the dataset is temporarily unavailable. However, for each task, we will provide a showcase of five samples.