midom 0.2.0__tar.gz → 0.3.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: midom
3
- Version: 0.2.0
3
+ Version: 0.3.0
4
4
  Summary: Concepts and relations to describe the process of DICOM deidentification
5
5
  Requires-Python: >=3.12
6
6
  Description-Content-Type: text/markdown
@@ -5,6 +5,7 @@ from dicomcriterion import Criterion
5
5
  from dicomcriterion.exceptions import CriterionError
6
6
  from pydantic import BaseModel, ConfigDict, field_validator
7
7
  from pydantic.functional_serializers import field_serializer
8
+ from pydicom.valuerep import VR
8
9
 
9
10
  from midom.constants import ActionCode, ActionCodes
10
11
  from midom.identifiers import (
@@ -73,6 +74,8 @@ class PrivateElement(BaseModel):
73
74
 
74
75
  identifier: Union[PrivateBlockTagIdentifier, str]
75
76
  description: str
77
+ value_representation: VR # any DICOM VR string
78
+ value_multiplicity: int = 1
76
79
 
77
80
  @field_serializer("identifier")
78
81
  def serialize_identifier(self, value, _info):
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: midom
3
- Version: 0.2.0
3
+ Version: 0.3.0
4
4
  Summary: Concepts and relations to describe the process of DICOM deidentification
5
5
  Requires-Python: >=3.12
6
6
  Description-Content-Type: text/markdown
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "midom"
3
- version = "0.2.0"
3
+ version = "0.3.0"
4
4
  description = "Concepts and relations to describe the process of DICOM deidentification"
5
5
  readme = "README.md"
6
6
  requires-python = ">=3.12"
@@ -14,6 +14,7 @@ def test_private_element():
14
14
  elem = PrivateElement(
15
15
  identifier="0029,[A private creator]10",
16
16
  description="A test description",
17
+ value_representation="LO",
17
18
  )
18
19
 
19
20
  as_json = elem.model_dump_json()
@@ -114,10 +114,13 @@ def a_protocol():
114
114
  PrivateElement(
115
115
  identifier='0075["company"]01',
116
116
  description="Amount of contrast used",
117
+ value_representation="LO",
117
118
  ),
118
119
  PrivateElement(
119
120
  identifier='0075["company"]02',
120
121
  description="algorithm settings",
122
+ value_representation="LO",
123
+ value_multiplicity=2,
121
124
  ),
122
125
  ],
123
126
  )
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes