Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
ISC4_IA_ML
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
kevineri.bonga
ISC4_IA_ML
Commits
f03af90c
Commit
f03af90c
authored
7 months ago
by
Kevin Bonga
Browse files
Options
Downloads
Patches
Plain Diff
editing extract_metadata by using different fields
parent
f148b245
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
exos/tp_final_ia/extract_metadata.py
+4
-1
4 additions, 1 deletion
exos/tp_final_ia/extract_metadata.py
with
4 additions
and
1 deletion
exos/tp_final_ia/extract_metadata.py
+
4
−
1
View file @
f03af90c
# 1. Préparation des données
# Extraction des métadonnées DICOM
# Utilisez le script suivant pour extraire les métadonnées des fichiers DICOM :
# Utilisation du script suivant pour extraire les métadonnées des fichiers DICOM :
# source des champs DICOM: https://dicom.innolitics.com/ciods/digital-x-ray-image/x-ray-acquisition-dose/00181153
# Patient, General study, DX Image, X-Ray Acquisition Dose
import
os
import
pydicom
...
...
@@ -20,6 +22,7 @@ def extract_metadata(directory):
"
KVP
"
:
dicom_data
.
get
(
"
KVP
"
,
"
N/A
"
),
"
XRayTubeCurrent
"
:
dicom_data
.
get
(
"
XRayTubeCurrent
"
,
"
N/A
"
),
"
ExposureTime
"
:
dicom_data
.
get
(
"
ExposureTime
"
,
"
N/A
"
),
"
Exposure in µAs
"
:
dicom_data
.
get
(
"
ExposureInuAs
"
,
"
N/A
"
),
"
ImageType
"
:
dicom_data
.
get
(
"
ImageType
"
,
"
N/A
"
),
}
metadata_list
.
append
(
metadata
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment