According to PS 3.15-2008, basic application level
        De-Indentification of a DICOM file requires replacing the values of a
        set of data elements

def anonymize(self):
        """ According to PS 3.15-2008, basic application level
        De-Indentification of a DICOM file requires replacing the values of a
        set of data elements"""
        self._anon_obj = gdcm.Anonymizer()
        self._anon_obj.SetFile(self._file)
        self._anon_obj.RemoveGroupLength()

        if self._anon_tags is None:
            self._anon_tags = get_anon_tags()

        for tag in self._anon_tags:
            cur_tag = tag['Tag'].replace("(", "")
            cur_tag = cur_tag.replace(")", "")
            name = tag["Attribute Name"].replace(" ", "").encode("utf8")
            group, element = cur_tag.split(",", 1)

            # TODO expand this 50xx, 60xx, gggg, eeee
            if ("xx" not in group
                and "gggg" not in group
                and "eeee" not in group):
                    group = int(group, 16)
                    element = int(element, 16)
                    if self.find(group=group, element=element):
                        self._anon_obj.Replace(
                            gdcm.Tag(group, element), "Anon" + name)

        return self._anon_obj