Changeset 3279

Show
Ignore:
Timestamp:
01/26/12 21:07:05 (4 months ago)
Author:
erkn
Message:

More informative progress info

Location:
branches/mcxtrace-1.0/src/mcrun2
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • branches/mcxtrace-1.0/src/mcrun2/mcstas.py

    r3275 r3279  
    145145        # Run McStas 
    146146        if not mpi: 
    147             LOG.info('Running: %s', self.binpath) 
     147            LOG.debug('Running: %s', self.binpath) 
    148148            return Process(self.binpath).run(args, pipe=pipe) 
    149149        else: 
    150             LOG.info('Running via MPI: %s', self.binpath) 
     150            LOG.debug('Running via MPI: %s', self.binpath) 
    151151            mpi_args = ['-np', str(options.mpi), self.binpath] 
    152152            mpi_args += args 
  • branches/mcxtrace-1.0/src/mcrun2/optimisation.py

    r3274 r3279  
    111111                par_values.append(point[key]) 
    112112 
     113            is_decimal = lambda x: type(x) == Decimal 
     114            to_string = lambda x: is_decimal(x) and '%.4f' % x \ 
     115                                                or x 
     116            LOG.info(', '.join('%s: %s' % (a, to_string(b)) 
     117                               for (a, b) in point.items())) 
    113118            out = self.mcstas.run(pipe=True) 
    114119            dets = sorted(McStasResult(out).get_detectors(),