X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=gdcmPython%2Fdemo%2FReorganiseFiles.py;h=3db13f4dffb8331209e7a68b2bcfcd2936ab2c5d;hb=5655f7d550e6699077e79216cc42e8dba7eb2a3c;hp=1ba6178e04f28a796e7764bbb7561407468b4ebb;hpb=f978dcd25d35bb7dcd2e21f5ca192cc9aea4e8ec;p=gdcm.git diff --git a/gdcmPython/demo/ReorganiseFiles.py b/gdcmPython/demo/ReorganiseFiles.py index 1ba6178e..3db13f4d 100644 --- a/gdcmPython/demo/ReorganiseFiles.py +++ b/gdcmPython/demo/ReorganiseFiles.py @@ -1,4 +1,4 @@ -# Rename the dcm extension files of a given drectory according +# Rename the dcm extension files of a given directory according # to series and image number information extracted in each respective header. from gdcmPython import * @@ -30,7 +30,7 @@ SourceFiles=glob.glob(os.path.join(SourceDirectory, "*.dcm")) for file in SourceFiles: header = gdcmHeader(file) - info = header.GetPubElVal() + info = header.GetEntry() try: ImNum = info["Image Number"] if len(ImNum) == 0 or ImNum == "gdcm::Unfound":