From e2355945c0abec01c12467e6ed265d1ae5206e66 Mon Sep 17 00:00:00 2001 From: Marko Petric <marko.petric@cern.ch> Date: Thu, 25 Jul 2019 12:59:25 +0200 Subject: [PATCH] use future division in ddsim --- DDG4/python/DDSim/DD4hepSimulation.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/DDG4/python/DDSim/DD4hepSimulation.py b/DDG4/python/DDSim/DD4hepSimulation.py index e736ea114..bc2cd6fa3 100644 --- a/DDG4/python/DDSim/DD4hepSimulation.py +++ b/DDG4/python/DDSim/DD4hepSimulation.py @@ -6,7 +6,7 @@ Based on M. Frank and F. Gaede runSim.py @version 0.1 """ -from __future__ import absolute_import, unicode_literals +from __future__ import absolute_import, unicode_literals, division __RCSID__ = "$Id$" from g4units import * import logging @@ -482,7 +482,7 @@ class DD4hepSimulation(object): logger.info("DDSim INFO Total Time: %3.2f s (User), %3.2f s (System)"% (totalTimeUser, totalTimeSys)) if self.numberOfEvents != 0: eventTime = totalTimeUser - startUpTime - perEventTime = eventTime / float(self.numberOfEvents) + perEventTime = eventTime / self.numberOfEvents logger.info("DDSim INFO StartUp Time: %3.2f s, Event Processing: %3.2f s (%3.2f s/Event) " \ % (startUpTime, eventTime, perEventTime)) -- GitLab