Author: bugman Date: Fri Sep 18 19:20:15 2009 New Revision: 9543 URL: http://svn.gna.org/viewcvs/relax?rev=9543&view=rev Log: The 'reduction' data structure is now properly created from the XML file. Modified: 1.3/data/align_tensor.py 1.3/data/pipe_container.py Modified: 1.3/data/align_tensor.py URL: http://svn.gna.org/viewcvs/relax/1.3/data/align_tensor.py?rev=9543&r1=9542&r2=9543&view=diff ============================================================================== --- 1.3/data/align_tensor.py (original) +++ 1.3/data/align_tensor.py Fri Sep 18 19:20:15 2009 @@ -613,12 +613,18 @@ self.append(AlignTensorData(name)) - def from_xml(self, align_tensor_nodes): + def from_xml(self, align_tensor_super_node): """Recreate the alignment tensor data structure from the XML alignment tensor node. - @param align_tensor_nodes: The alignment tensor XML nodes. - @type align_tensor_nodes: list of xml.dom.minicompat.Element instances + @param align_tensor_super_node: The alignment tensor XML nodes. + @type align_tensor_super_node: xml.dom.minicompat.Element instance """ + + # Recreate all the alignment tensor data structures. + xml_to_object(align_tensor_super_node, self, blacklist=['align_tensor']) + + # Get the individual tensors. + align_tensor_nodes = align_tensor_super_node.getElementsByTagName('align_tensor') # Loop over the child nodes. for align_tensor_node in align_tensor_nodes: Modified: 1.3/data/pipe_container.py URL: http://svn.gna.org/viewcvs/relax/1.3/data/pipe_container.py?rev=9543&r1=9542&r2=9543&view=diff ============================================================================== --- 1.3/data/pipe_container.py (original) +++ 1.3/data/pipe_container.py Fri Sep 18 19:20:15 2009 @@ -128,16 +128,13 @@ self.diff_tensor.from_xml(diff_tensor_nodes[0]) # Get the alignment tensor data nodes and, if they exist, fill the contents. - align_tensor_super_node = relax_node.getElementsByTagName('align_tensors') - if align_tensor_super_node: - # Get the individual tensors. - align_tensor_nodes = align_tensor_super_node[0].getElementsByTagName('align_tensor') - + align_tensor_nodes = relax_node.getElementsByTagName('align_tensors') + if align_tensor_nodes: # Create the diffusion tensor object. self.align_tensors = AlignTensorList() # Fill its contents. - self.align_tensors.from_xml(align_tensor_nodes) + self.align_tensors.from_xml(align_tensor_nodes[0]) # Recreate the molecule, residue, and spin data structure. mol_nodes = relax_node.getElementsByTagName('mol')