Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Contrast agent ambiguity #35

Open
Jonas1312 opened this issue May 9, 2020 · 4 comments
Open

Contrast agent ambiguity #35

Jonas1312 opened this issue May 9, 2020 · 4 comments

Comments

@Jonas1312
Copy link
Contributor

Hi,

I noticed the following metadata in LIDC-IDRI-0132/1.3.6.1.4.1.14519.5.2.1.6279.6001.218658642102832118810712329678/1.3.6.1.4.1.14519.5.2.1.6279.6001.151647338241909635299641922057/000000.dcm:

[0040,0275]	RequestAttributesSequence		SQ	94
	[fffe,e000]	Item		na	78
		[0040,0007]	ScheduledProcedureStepDescription	CT, CHEST, W CONTRAST	LO	22

It's writtent W CONTRAST , yet pylidc returns contrast_used == False.

I think pylidc is correct since there's not Contrast/Bolus Agent dicom field, but i'm not sure...

any opinion?

thanks

@Jonas1312
Copy link
Contributor Author

Jonas1312 commented Jun 26, 2020

LIDC-IDRI-0086,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT, CHEST, W CONTRAST'
LIDC-IDRI-0094,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT,CHEST,W CONTRAST'
LIDC-IDRI-0095,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT,CHEST,W CONTRAST'
LIDC-IDRI-0098,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT, CHEST, W CONTRAST'
LIDC-IDRI-0101,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT,CHEST/ABDOMEN,W CONTRAST'
LIDC-IDRI-0103,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT, CHEST, W/O CONTRAST'
LIDC-IDRI-0110,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT,CHEST,W CONTRAST'
LIDC-IDRI-0119,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT,CHEST,W CONTRAST'
LIDC-IDRI-0127,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT, CHEST, W CONTRAST'
LIDC-IDRI-0130,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT, CHEST, W CONTRAST'
LIDC-IDRI-0132,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT, CHEST, W CONTRAST'
LIDC-IDRI-0136,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT, CHEST/ABDOMEN, WITH CONTRAST'
LIDC-IDRI-0141,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT,CHEST,W CONTRAST'
LIDC-IDRI-0142,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT,CHEST,W CONTRAST'
LIDC-IDRI-0151,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT,CHEST,W CONTRAST'
LIDC-IDRI-0303,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT, CHEST, W CONTRAST'
LIDC-IDRI-0358,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT,CHEST,W & W/O CONTRAST'
LIDC-IDRI-0435,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT, CHEST, W CONTRAST'
LIDC-IDRI-0436,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT, CHEST, W CONTRAST'
LIDC-IDRI-0468,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT,CHEST,W CONTRAST'
LIDC-IDRI-0546,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT,CHEST,W/O CONTRAST'
LIDC-IDRI-0648,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT, CHEST, WITHOUT CONTRAST'
LIDC-IDRI-0713,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT,CHEST,W CONTRAST'
LIDC-IDRI-0719,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT,CHEST,W CONTRAST'
LIDC-IDRI-0791,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT,CHEST,W CONTRAST'
LIDC-IDRI-0793,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT, CHEST, W CONTRAST'
LIDC-IDRI-0837,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT THORAX WO IV CONTRAST'
LIDC-IDRI-0883,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT,CHEST,W CONTRAST'
LIDC-IDRI-0962,(0040, 0007) Scheduled Procedure Step Descriptio LO: 'CT, CHEST, W CONTRAST'

@Jonas1312 Jonas1312 changed the title Contrast agent ambiguity LIDC-IDRI-0132 Contrast agent ambiguity Jun 26, 2020
@notmatthancock
Copy link
Owner

Thanks for pointing this out, @Jonas1312. My suggestion at this point would be to consider the DICOM files themselves as the source of truth for these types of attributes, and only use the pylidc / sqlalchemy layer for more basic attributes (e.g., slice thickness) or for annotation attributes (spiculation, etc).

@notmatthancock
Copy link
Owner

@Jonas1312 if you don't mind, I'll leave this open for greater visibility since I think I would still consider this an issue (albeit with a workaround of just using the DICOM directly for these attributes as suggested above)

@notmatthancock notmatthancock reopened this Jul 5, 2020
@Jonas1312
Copy link
Contributor Author

Jonas1312 commented Jul 6, 2020

Hi @notmatthancock ,

Yes we should keep this open (maybe add a "warning contrast_used labels not accurate" to the README.md?)

Unfortunately some DICOM tags for contrast agent are missing, especially in Philips dicoms. Absence of the "ContrastBolusAgent" tag doesn't mean there's not contrast agent.

A surgeon came to my office last week and gave me some tips to "read" a CT scan and detect if a patient has had an injection of intravenous contrast agent.

The best way to do that is to set a Hounsfield units window of [50HU ; 300HU] and if the aorta can be seen on the CT that means there is an IV contrast material. For oral/rectal contrast you have to look at the stomach and intestines.

LIDRI-IDRI-0033: (IV and probably oral/rectal)
0033

LIDC-IDRI-0346: nothing
0346

You can find the corrected labels here IV contrast.csv. For IV contrast only (oral/rectal is considered as contrast_used=False). I labelled the images myself but I'm not a certified radiologist! However I'm quite confident that my labels are more accurate than those generated this way:

contrast_used = any(['Contrast' in d for d in dir(img)]),

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants