Skip to content
This repository was archived by the owner on Feb 20, 2026. It is now read-only.

Commit 028b909

Browse files
committed
IndexMaps in files with namespaces were being ignored. Fixed.
1 parent e985041 commit 028b909

File tree

2 files changed

+8
-3
lines changed

2 files changed

+8
-3
lines changed

python/aces/clf/LUT1D.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ def readChild(self, element):
129129
child.setValuesAreIntegers(integers)
130130

131131
self._array = child
132-
elif element.tag == 'IndexMap':
132+
elif elementType == 'IndexMap':
133133
child = IndexMap()
134134
child.read(element)
135135
self._indexMaps.append( child )
@@ -169,12 +169,12 @@ def process(self, values, stride=0, verbose=False):
169169
outValue = values[p*stride:(p+1)*stride]
170170

171171
for i in range(min(3, stride)):
172-
# Run through single Index Map then normalize
172+
# Run through per-channel Index Map then normalize
173173
if len(self._indexMaps) > 1:
174174
outValue[i] = self._indexMaps[i].process(outValue[i])
175175
outValue[i] /= float(dimensions[0]-1)
176176

177-
# Run through per-channel Index Map then normalize
177+
# Run through single Index Map then normalize
178178
elif len(self._indexMaps) > 0:
179179
outValue[i] = self._indexMaps[0].process(outValue[i])
180180
outValue[i] /= float(dimensions[0]-1)

python/aces/clf/ProcessList.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -272,6 +272,11 @@ def setName(self, name):
272272
def getName(self):
273273
return self.getAttribute('name')
274274

275+
def setNamespace(self, name):
276+
self.setAttribute('xmlns', name)
277+
def getNamespace(self):
278+
return self.getAttribute('xmlns')
279+
275280
def setID(self, name):
276281
self.setAttribute('id', name)
277282
def getID(self):

0 commit comments

Comments
 (0)