mailr8224 - in /1.3: ./ generic_fns/ prompt/ specific_fns/ specific_fns/model_free/ test_suite/system_tests/ test_suite/system_t...


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by sebastien . morin . 1 on December 23, 2008 - 17:04:
Author: semor
Date: Tue Dec 23 17:04:48 2008
New Revision: 8224

URL: http://svn.gna.org/viewcvs/relax?rev=8224&view=rev
Log:
Many corrections of formatting.

These were found using the relax 'code_validator' script (E. d'Auvergne) and 
mainly include trailing
whitespaces and missing empty lines before functions.


Modified:
    1.3/generic_fns/spectrum.py
    1.3/physical_constants.py
    1.3/prompt/align_tensor.py
    1.3/prompt/dasha.py
    1.3/prompt/help.py
    1.3/prompt/interpreter.py
    1.3/prompt/spectrum.py
    1.3/relax_io.py
    1.3/specific_fns/base_class.py
    1.3/specific_fns/consistency_tests.py
    1.3/specific_fns/model_free/main.py
    1.3/specific_fns/n_state_model.py
    1.3/specific_fns/noe.py
    1.3/test_suite/system_tests/angles.py
    1.3/test_suite/system_tests/diffusion_tensor.py
    1.3/test_suite/system_tests/n_state_model.py
    1.3/test_suite/system_tests/peak_lists.py
    1.3/test_suite/system_tests/scripts/5_state_xz.py
    1.3/test_suite/system_tests/unit_vectors.py

Modified: 1.3/generic_fns/spectrum.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/generic_fns/spectrum.py?rev=8224&r1=8223&r2=8224&view=diff
==============================================================================
--- 1.3/generic_fns/spectrum.py (original)
+++ 1.3/generic_fns/spectrum.py Tue Dec 23 17:04:48 2008
@@ -465,7 +465,7 @@
 
     print ''
     print 'The following information was extracted from the intensity file 
(res_num, h_name, x_name, intensities).'
-    print '    ' + `res_num`, h_name, x_name, intensity 
+    print '    ' + `res_num`, h_name, x_name, intensity
 
     # Generate the spin identification string.
     spin_id = generate_spin_id_data_array(data=line, 
mol_name_col=mol_name_col, res_num_col=res_num_col, 
res_name_col=res_name_col, spin_num_col=spin_num_col, 
spin_name_col=spin_name_col)

Modified: 1.3/physical_constants.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/physical_constants.py?rev=8224&r1=8223&r2=8224&view=diff
==============================================================================
--- 1.3/physical_constants.py (original)
+++ 1.3/physical_constants.py Tue Dec 23 17:04:48 2008
@@ -143,10 +143,10 @@
 # Function for returning the desired gyromagnetic ratio.
 def return_gyromagnetic_ratio(nucleus=None):
     """Return the gyromagnetic ratio for the given nucleus type.
- 
+
     @keyword nucleus:   The nucleus type.
     @type nucleus:      str
-    @raises RelaxError: If the nucleus type is unknown.           
+    @raises RelaxError: If the nucleus type is unknown.
     @returns:           The desired gyromagnetic ratio.
     @rtype:             float
     """
@@ -194,7 +194,7 @@
 
     @keyword element:   The element type.
     @type element:      str
-    @raises RelaxError: If the element type is unknown.           
+    @raises RelaxError: If the element type is unknown.
     @returns:           The desired atomic mass.
     @rtype:             float
     """

Modified: 1.3/prompt/align_tensor.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/prompt/align_tensor.py?rev=8224&r1=8223&r2=8224&view=diff
==============================================================================
--- 1.3/prompt/align_tensor.py (original)
+++ 1.3/prompt/align_tensor.py Tue Dec 23 17:04:48 2008
@@ -215,7 +215,7 @@
             5:  {Azz, Axx-yy, Axy, Axz, Ayz}  (units of Hertz),
             6:  {Pxx, Pyy, Pxy, Pxz, Pyz}  (unitless),
             7:  {Pzz, Pxx-yy, Pxy, Pxz, Pyz}  (unitless),
- 
+
         Other formats may be added later.  The relationship between the 
Saupe order matrix S and the
         alignment tensor A is
 

Modified: 1.3/prompt/dasha.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/prompt/dasha.py?rev=8224&r1=8223&r2=8224&view=diff
==============================================================================
--- 1.3/prompt/dasha.py (original)
+++ 1.3/prompt/dasha.py Tue Dec 23 17:04:48 2008
@@ -162,7 +162,7 @@
         Keyword Arguments
         ~~~~~~~~~~~~~~~~~
 
-        dir:  The directory where the file 'dasha_results' is found. 
+        dir:  The directory where the file 'dasha_results' is found.
         """
 
         # Function intro text.

Modified: 1.3/prompt/help.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/prompt/help.py?rev=8224&r1=8223&r2=8224&view=diff
==============================================================================
--- 1.3/prompt/help.py (original)
+++ 1.3/prompt/help.py Tue Dec 23 17:04:48 2008
@@ -66,6 +66,7 @@
 to the help function built into the normal python interpreter.
     """
 
+
     def __repr__(self):
         return self.text
 

Modified: 1.3/prompt/interpreter.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/prompt/interpreter.py?rev=8224&r1=8223&r2=8224&view=diff
==============================================================================
--- 1.3/prompt/interpreter.py (original)
+++ 1.3/prompt/interpreter.py Tue Dec 23 17:04:48 2008
@@ -116,7 +116,7 @@
         self.__show_script = show_script
         self.__quit_flag = quit
         self.__raise_relax_error = raise_relax_error
-        
+
         # The prompts.
         sys.ps1 = 'relax> '
         sys.ps2 = 'relax| '
@@ -465,7 +465,7 @@
     except:
         raise
 
-    # Add an empty line to make exiting relax look better. 
+    # Add an empty line to make exiting relax look better.
     if show_script:
         sys.stdout.write("\n")
 

Modified: 1.3/prompt/spectrum.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/prompt/spectrum.py?rev=8224&r1=8223&r2=8224&view=diff
==============================================================================
--- 1.3/prompt/spectrum.py (original)
+++ 1.3/prompt/spectrum.py Tue Dec 23 17:04:48 2008
@@ -160,7 +160,7 @@
         If there are in addition to the replicated spectra loaded peak 
intensities which only
         consist of a single spectrum, i.e. not all spectra are replicated, 
then the variances of
         replicated replicated spectra sets will be averaged.  This will be 
used for the entire
-        experiment so that there will be only a single error value for all 
spins and for all 
+        experiment so that there will be only a single error value for all 
spins and for all
         spectra.
 
 

Modified: 1.3/relax_io.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/relax_io.py?rev=8224&r1=8223&r2=8224&view=diff
==============================================================================
--- 1.3/relax_io.py (original)
+++ 1.3/relax_io.py Tue Dec 23 17:04:48 2008
@@ -521,7 +521,7 @@
 
     def readlines(self):
         """Mimic the file object readlines() method.
-        
+
         This method works even if this dummy file object is closed!
 
 

Modified: 1.3/specific_fns/base_class.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/specific_fns/base_class.py?rev=8224&r1=8223&r2=8224&view=diff
==============================================================================
--- 1.3/specific_fns/base_class.py (original)
+++ 1.3/specific_fns/base_class.py Tue Dec 23 17:04:48 2008
@@ -209,7 +209,7 @@
         @type param:    str
         @param sim:     The Monte Carlo simulation index.
         @type sim:      None or int
-        @return:        The value and error corresponding to 
+        @return:        The value and error corresponding to
         @rtype:         tuple of length 2 of floats or None
         """
 
@@ -442,7 +442,7 @@
 
     def sim_return_param(self, spin, index):
         """Return the array of simulation parameter values.
- 
+
         @param spin:        The spin container.
         @type spin:         SpinContainer instance
         @param index:       The index of the parameter to return the array 
of values for.

Modified: 1.3/specific_fns/consistency_tests.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/specific_fns/consistency_tests.py?rev=8224&r1=8223&r2=8224&view=diff
==============================================================================
--- 1.3/specific_fns/consistency_tests.py (original)
+++ 1.3/specific_fns/consistency_tests.py Tue Dec 23 17:04:48 2008
@@ -251,7 +251,7 @@
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
         These default values are found in the file 'physical_constants.py'.
 
-         
______________________________________________________________________________________
 
+         
______________________________________________________________________________________
         |                                       |                    |       
                  |
         | Data type                             | Object name        | Value 
                  |
         
|_______________________________________|____________________|_________________________|

Modified: 1.3/specific_fns/model_free/main.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/specific_fns/model_free/main.py?rev=8224&r1=8223&r2=8224&view=diff
==============================================================================
--- 1.3/specific_fns/model_free/main.py (original)
+++ 1.3/specific_fns/model_free/main.py Tue Dec 23 17:04:48 2008
@@ -3054,7 +3054,7 @@
 
     def sim_return_param(self, model_index, index):
         """Return the array of simulation parameter values.
- 
+
         @param model_index: The model index.  This is zero for the global 
models or equal to the
                             global spin index (which covers the molecule, 
residue, and spin
                             indices).

Modified: 1.3/specific_fns/n_state_model.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/specific_fns/n_state_model.py?rev=8224&r1=8223&r2=8224&view=diff
==============================================================================
--- 1.3/specific_fns/n_state_model.py (original)
+++ 1.3/specific_fns/n_state_model.py Tue Dec 23 17:04:48 2008
@@ -191,7 +191,7 @@
 
         # No data is present.
         if not list:
-            raise RelaxError, "Neither RDC, PCS, nor alignment tensor data 
is present." 
+            raise RelaxError, "Neither RDC, PCS, nor alignment tensor data 
is present."
 
         # Return the list.
         return list
@@ -319,7 +319,7 @@
 
         As::
                     N-1
-                    \ 
+                    \
             pN = 1 - >  pc,
                     /__
                     c=1
@@ -1066,6 +1066,7 @@
         Note that setting the probability for state N will do nothing as it 
is equal to one minus
         all the other probabilities.
         """
+
         __docformat__ = "plaintext"
 
         # Get the current data pipe.
@@ -1398,7 +1399,7 @@
                     for rdc in spin.rdc:
                         if type(rdc) == float:
                             n = n + 1
-        
+
             # PCS data (skipping array elements set to None).
             if 'pcs' in data_types:
                 if hasattr(spin, 'pcs'):
@@ -1466,7 +1467,7 @@
                 exists = True
         if not exists:
             raise RelaxError, "The reference domain cannot be found within 
any of the loaded tensors."
-            
+
         # Set the reference domain.
         cdp.ref_domain = ref
 
@@ -1534,6 +1535,7 @@
         The objects corresponding to the object names are lists (or arrays) 
with each element
         corrsponding to each state.
         """
+
         __docformat__ = "plaintext"
 
         # Probability.
@@ -1662,6 +1664,7 @@
         To set the parameters for a specific state c (ranging from 0 for the 
first to N-1 for the
         last, the number c should be added to the end of the parameter name. 
 So the Euler angle
         gamma of the third state is specified using the string 'gamma2'.
+
         """
         __docformat__ = "plaintext"
 

Modified: 1.3/specific_fns/noe.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/specific_fns/noe.py?rev=8224&r1=8223&r2=8224&view=diff
==============================================================================
--- 1.3/specific_fns/noe.py (original)
+++ 1.3/specific_fns/noe.py Tue Dec 23 17:04:48 2008
@@ -105,12 +105,12 @@
                 if cdp.spectrum_type[i] == 'sat':
                     sat = sat + spin.intensities[i]
                     sat_err = sat_err + spin.intensity_err[i]
-            
+
                 # Ref spectra.
                 if cdp.spectrum_type[i] == 'ref':
                     ref = ref + spin.intensities[i]
                     ref_err = ref_err + spin.intensity_err[i]
-            
+
             # Calculate the NOE.
             spin.noe = sat / ref
 

Modified: 1.3/test_suite/system_tests/angles.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/test_suite/system_tests/angles.py?rev=8224&r1=8223&r2=8224&view=diff
==============================================================================
--- 1.3/test_suite/system_tests/angles.py (original)
+++ 1.3/test_suite/system_tests/angles.py Tue Dec 23 17:04:48 2008
@@ -48,7 +48,7 @@
         cdp = pipes.get_pipe()
 
         # Res info.
-        res_name = ['GLY', 'PRO', 'LEU', 'GLY', 'SER', 'MET', 'ASP', 'SER', 
'PRO', 'PRO', 'GLU', 'GLY', 'TYR', 'ARG', 'ARG'] 
+        res_name = ['GLY', 'PRO', 'LEU', 'GLY', 'SER', 'MET', 'ASP', 'SER', 
'PRO', 'PRO', 'GLU', 'GLY', 'TYR', 'ARG', 'ARG']
         spin_num = [1, 11, 28, 51, 59, 71, 91, 104, 116, 133, 150, 167, 
None, None, None]
         spin_name = ['N']*12 + [None]*3
         attached_atoms = [None, None, 'H', 'H', 'H', 'H', 'H', 'H', None, 
None, 'H', 'H', None, None, None]

Modified: 1.3/test_suite/system_tests/diffusion_tensor.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/test_suite/system_tests/diffusion_tensor.py?rev=8224&r1=8223&r2=8224&view=diff
==============================================================================
--- 1.3/test_suite/system_tests/diffusion_tensor.py (original)
+++ 1.3/test_suite/system_tests/diffusion_tensor.py Tue Dec 23 17:04:48 2008
@@ -47,7 +47,7 @@
         self.relax.interpreter._Sequence.read(file='Ap4Aase.seq', 
dir=sys.path[-1] + '/test_suite/shared_data/')
         self.relax.interpreter._Diffusion_tensor.init(10e-9, fixed=True)
         self.tmpfile_sphere = mktemp()
-        
+
         # Spheroid tensor initialization.
         self.relax.interpreter._Pipe.switch('spheroid')
         
self.relax.interpreter._Structure.read_pdb(file='Ap4Aase_res1-12.pdb', 
dir=sys.path[-1] + '/test_suite/shared_data/structures', model=1)

Modified: 1.3/test_suite/system_tests/n_state_model.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/test_suite/system_tests/n_state_model.py?rev=8224&r1=8223&r2=8224&view=diff
==============================================================================
--- 1.3/test_suite/system_tests/n_state_model.py (original)
+++ 1.3/test_suite/system_tests/n_state_model.py Tue Dec 23 17:04:48 2008
@@ -37,7 +37,6 @@
         """Reset the relax data storage object."""
 
         ds.__reset__()
-
 
 
     def test_5_state_xz(self):

Modified: 1.3/test_suite/system_tests/peak_lists.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/test_suite/system_tests/peak_lists.py?rev=8224&r1=8223&r2=8224&view=diff
==============================================================================
--- 1.3/test_suite/system_tests/peak_lists.py (original)
+++ 1.3/test_suite/system_tests/peak_lists.py Tue Dec 23 17:04:48 2008
@@ -33,23 +33,23 @@
 
 class Peak_lists(TestCase):
     """TestCase class for the functional tests for the support of different 
peak intensity files."""
-        
+
     def setUp(self):
         """Set up for all the functional tests."""
-        
+
         # Create a data pipe.
         self.relax.interpreter._Pipe.create('mf', 'mf')
-        
-        
+
+
     def tearDown(self):
         """Reset the relax data storage object."""
-        
+
         ds.__reset__()
-        
-        
+
+
     def test_read_peak_list_generic(self):
         """Test the reading of a generic peak intensity list."""
-        
+
         # Get the current data pipe.
         cdp = pipes.get_pipe()
 
@@ -60,7 +60,7 @@
         self.relax.interpreter._Residue.create(35)
         self.relax.interpreter._Residue.create(36)
         self.relax.interpreter._Spin.name(name='N')
-        
+
         # Read the peak list.
         
self.relax.interpreter._Spectrum.read_intensities(file="generic_intensity.txt",
 dir=sys.path[-1] + "/test_suite/shared_data/peak_lists", spectrum_id='test', 
int_method='height')
 
@@ -79,7 +79,7 @@
 
     def test_read_peak_list_generic2(self):
         """Test the reading of a generic peak intensity list (test number 
2)."""
-        
+
         # Get the current data pipe.
         cdp = pipes.get_pipe()
 
@@ -90,9 +90,9 @@
         self.relax.interpreter._Residue.create(35)
         self.relax.interpreter._Residue.create(36)
         self.relax.interpreter._Spin.name(name='N')
-        
+
         # Spectrum ids.
-        spectrum_ids=['0.0109016', '0.0218032', '0.0436064', '0.0436064', 
'0.0872128', '0.1744260', '0.3488510', '0.6977020', '1.3954000', '1.9949900']
+        spectrum_ids = ['0.0109016', '0.0218032', '0.0436064', '0.0436064', 
'0.0872128', '0.1744260', '0.3488510', '0.6977020', '1.3954000', '1.9949900']
 
         # Read the peak list.
         
self.relax.interpreter._Spectrum.read_intensities(file="generic_intensity2.txt",
 dir=sys.path[-1] + "/test_suite/shared_data/peak_lists", 
spectrum_id=spectrum_ids, int_col=range(2, 12), int_method='volume', 
mol_name_col=None, res_num_col=0, res_name_col=1, spin_num_col=None, 
spin_name_col=None)

Modified: 1.3/test_suite/system_tests/scripts/5_state_xz.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/test_suite/system_tests/scripts/5_state_xz.py?rev=8224&r1=8223&r2=8224&view=diff
==============================================================================
--- 1.3/test_suite/system_tests/scripts/5_state_xz.py (original)
+++ 1.3/test_suite/system_tests/scripts/5_state_xz.py Tue Dec 23 17:04:48 2008
@@ -30,7 +30,7 @@
 n_state_model.set_domain(tensor='chi4 C-dom', domain='C')
 n_state_model.set_domain(tensor='chi5 C-dom', domain='C')
 
-# Set that they are non-reduced tensors. 
+# Set that they are non-reduced tensors.
 n_state_model.set_type(tensor='chi1 C-dom', red=False)
 n_state_model.set_type(tensor='chi2 C-dom', red=False)
 n_state_model.set_type(tensor='chi3 C-dom', red=False)
@@ -60,7 +60,7 @@
 n_state_model.set_domain(tensor='chi4 N-dom', domain='N')
 n_state_model.set_domain(tensor='chi5 N-dom', domain='N')
 
-# Set that they are non-reduced tensors. 
+# Set that they are non-reduced tensors.
 n_state_model.set_type(tensor='chi1 N-dom', red=True)
 n_state_model.set_type(tensor='chi2 N-dom', red=True)
 n_state_model.set_type(tensor='chi3 N-dom', red=True)

Modified: 1.3/test_suite/system_tests/unit_vectors.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/test_suite/system_tests/unit_vectors.py?rev=8224&r1=8223&r2=8224&view=diff
==============================================================================
--- 1.3/test_suite/system_tests/unit_vectors.py (original)
+++ 1.3/test_suite/system_tests/unit_vectors.py Tue Dec 23 17:04:48 2008
@@ -78,7 +78,7 @@
 
         # Load the spins.
         self.relax.interpreter._Structure.load_spins(spin_id='@N')
-        
+
         # Remove the spin numbers.
         self.relax.interpreter._Spin.number()
 
@@ -106,7 +106,7 @@
 
         # Load the spins.
         self.relax.interpreter._Structure.load_spins(spin_id='@N')
-        
+
         # Calculate the unit vectors.
         self.relax.interpreter._Structure.vectors(attached='H')
 
@@ -131,7 +131,7 @@
 
         # Load the spins.
         self.relax.interpreter._Structure.load_spins(spin_id='@N')
-        
+
         # Remove the spin numbers.
         self.relax.interpreter._Spin.number()
 




Related Messages


Powered by MHonArc, Updated Tue Dec 23 17:20:02 2008