[Yade-dev] [Branch ~yade-dev/yade/trunk] Rev 3022: Omaga can contain more Scene instances

2012-02-13 Thread noreply

revno: 3022
committer: Jan Stransky _hon...@centrum.cz
branch nick: yade
timestamp: Mon 2012-02-13 11:36:56 +0100
message:
  Omaga can contain more Scene instances
modified:
  core/Omega.cpp
  core/Omega.hpp
  py/wrapper/yadeWrapper.cpp


--
lp:yade
https://code.launchpad.net/~yade-dev/yade/trunk

Your team Yade developers is subscribed to branch lp:yade.
To unsubscribe from this branch go to 
https://code.launchpad.net/~yade-dev/yade/trunk/+edit-subscription
=== modified file 'core/Omega.cpp'
--- core/Omega.cpp	2010-12-09 12:38:42 +
+++ core/Omega.cpp	2012-02-13 10:36:56 +
@@ -48,8 +48,28 @@
 
 const mapstring,DynlibDescriptor Omega::getDynlibsDescriptor(){return dynlibs;}
 
-const shared_ptrScene Omega::getScene(){return scene;}
-void Omega::resetScene(){ RenderMutexLock lock; scene = shared_ptrScene(new Scene);}
+const shared_ptrScene Omega::getScene(){return scenes.at(currentSceneNb);}
+void Omega::resetCurrentScene(){ RenderMutexLock lock; scenes.at(currentSceneNb) = shared_ptrScene(new Scene);}
+void Omega::resetScene(){ resetCurrentScene(); }//RenderMutexLock lock; scene = shared_ptrScene(new Scene);}
+void Omega::resetAllScenes(){
+	RenderMutexLock lock;
+	scenes.resize(1);
+	scenes[0] = shared_ptrScene(new Scene);
+	currentSceneNb=0;
+}
+int Omega::addScene(){
+	scenes.push_back(shared_ptrScene(new Scene));
+	return scenes.size()-1;
+}
+void Omega::switchToScene(unsigned int i) {
+	if (i0 || i=scenes.size()) {
+		LOG_ERROR(Scene i has not been created yet, no switch.);
+		return;
+	}
+	currentSceneNb=i;
+}
+
+
 
 Real Omega::getRealTime(){ return (microsec_clock::local_time()-startupLocalTime).total_milliseconds()/1e3; }
 time_duration Omega::getRealTime_duration(){return microsec_clock::local_time()-startupLocalTime;}
@@ -79,7 +99,8 @@
 
 void Omega::init(){
 	sceneFile=;
-	resetScene();
+	//resetScene();
+	resetAllScenes();
 	sceneAnother=shared_ptrScene(new Scene);
 	timeInit();
 	createSimulationLoop();
@@ -220,6 +241,9 @@
 	if(isMem  memSavedSimulations.count(f)==0) throw runtime_error(Cannot load nonexistent memory-saved simulation +f);
 	
 	if(!quiet) LOG_INFO(Loading file +f);
+	//shared_ptrScene scene = getScene();
+	shared_ptrScene scene = scenes[currentSceneNb];
+	//shared_ptrScene scene = getScene();
 	{
 		stop(); // stop current simulation if running
 		resetScene();
@@ -242,6 +266,9 @@
 void Omega::saveSimulation(const string f, bool quiet){
 	if(f.size()==0) throw runtime_error(f of file to save has zero length.);
 	if(!quiet) LOG_INFO(Saving file   f);
+	//shared_ptrScene scene = getScene();
+	shared_ptrScene scene = scenes[currentSceneNb];
+	//shared_ptrScene scene = getScene();
 	if(algorithm::starts_with(f,:memory:)){
 		if(memSavedSimulations.count(f)0  !quiet) LOG_INFO(Overwriting in-memory saved simulation f);
 		ostringstream oss;

=== modified file 'core/Omega.hpp'
--- core/Omega.hpp	2010-12-09 12:38:42 +
+++ core/Omega.hpp	2012-02-13 10:36:56 +
@@ -63,7 +63,8 @@
 	mapstring,DynlibDescriptor dynlibs; // FIXME : should store that in ClassFactory ?
 	void buildDynlibDatabase(const vectorstring dynlibsList); // FIXME - maybe in ClassFactory ?
 	
-	shared_ptrScene scene;
+	vectorshared_ptrScene  scenes;
+	unsigned int currentSceneNb;
 	shared_ptrScene sceneAnother; // used for temporarily running different simulation, in Omega().switchscene()
 
 	ptime startupLocalTime;
@@ -109,7 +110,11 @@
 		void saveSimulation(const string name, bool quiet=false);
 
 		void resetScene();
+		void resetCurrentScene();
+		void resetAllScenes();
 		const shared_ptrScene getScene();
+		int addScene();
+		void switchToScene(int i);
 		//! Return unique temporary filename. May be deleted by the user; if not, will be deleted at shutdown.
 		string tmpFilename();
 		Real getRealTime();

=== modified file 'py/wrapper/yadeWrapper.cpp'
--- py/wrapper/yadeWrapper.cpp	2011-12-19 17:02:15 +
+++ py/wrapper/yadeWrapper.cpp	2012-02-13 10:36:56 +
@@ -397,10 +397,14 @@
 	}
 
 	void reset(){Py_BEGIN_ALLOW_THREADS; OMEGA.reset(); Py_END_ALLOW_THREADS; }
-	void resetThisScene(){Py_BEGIN_ALLOW_THREADS; OMEGA.stop(); Py_END_ALLOW_THREADS; OMEGA.resetScene(); OMEGA.createSimulationLoop();}
+	void resetThisScene(){Py_BEGIN_ALLOW_THREADS; OMEGA.stop(); Py_END_ALLOW_THREADS; OMEGA.resetCurrentScene(); OMEGA.createSimulationLoop();}
+	void resetCurrentScene(){Py_BEGIN_ALLOW_THREADS; OMEGA.stop(); Py_END_ALLOW_THREADS; OMEGA.resetCurrentScene(); OMEGA.createSimulationLoop();}
 	void resetTime(){ OMEGA.getScene()-iter=0; OMEGA.getScene()-time=0; OMEGA.timeInit(); }
-	void switchScene(){ std::swap(OMEGA.scene,OMEGA.sceneAnother); }
+	void switchScene(){ std::swap(OMEGA.scenes[OMEGA.currentSceneNb],OMEGA.sceneAnother); }
+	void resetAllScenes(){Py_BEGIN_ALLOW_THREADS; OMEGA.stop(); Py_END_ALLOW_THREADS; OMEGA.resetAllScenes(); OMEGA.createSimulationLoop();}
 	shared_ptrScene scene_get(){ return OMEGA.getScene(); }
+	int addScene(){return 

[Yade-dev] buildbot failure in Yade on yade-full

2012-02-13 Thread buildbot
The Buildbot has detected a failed build of yade-full on Yade.
Full details are available at:
 http://yade-dem.org/buildbot/builders/yade-full/builds/1001

Buildbot URL: http://yade-dem.org/buildbot/

Buildslave for this Build: r0calcul10

Build Reason: 
Build Source Stamp: 3022
Blamelist: Jan Stransky _hon...@centrum.cz

BUILD FAILED: failed compile shell_5

sincerely,
 -The Buildbot


___
Mailing list: https://launchpad.net/~yade-dev
Post to : yade-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-dev
More help   : https://help.launchpad.net/ListHelp


[Yade-dev] [Branch ~yade-dev/yade/trunk] Rev 3023: Fix of previous commit

2012-02-13 Thread noreply

revno: 3023
committer: Jan Stransky _hon...@centrum.cz
branch nick: yade
timestamp: Mon 2012-02-13 12:17:02 +0100
message:
  Fix of previous commit
modified:
  core/Omega.cpp
  core/Omega.hpp


--
lp:yade
https://code.launchpad.net/~yade-dev/yade/trunk

Your team Yade developers is subscribed to branch lp:yade.
To unsubscribe from this branch go to 
https://code.launchpad.net/~yade-dev/yade/trunk/+edit-subscription
=== modified file 'core/Omega.cpp'
--- core/Omega.cpp	2012-02-13 10:36:56 +
+++ core/Omega.cpp	2012-02-13 11:17:02 +
@@ -61,8 +61,8 @@
 	scenes.push_back(shared_ptrScene(new Scene));
 	return scenes.size()-1;
 }
-void Omega::switchToScene(unsigned int i) {
-	if (i0 || i=scenes.size()) {
+void Omega::switchToScene(int i) {
+	if (i0 || i=int(scenes.size())) {
 		LOG_ERROR(Scene i has not been created yet, no switch.);
 		return;
 	}

=== modified file 'core/Omega.hpp'
--- core/Omega.hpp	2012-02-13 10:36:56 +
+++ core/Omega.hpp	2012-02-13 11:17:02 +
@@ -64,7 +64,7 @@
 	void buildDynlibDatabase(const vectorstring dynlibsList); // FIXME - maybe in ClassFactory ?
 	
 	vectorshared_ptrScene  scenes;
-	unsigned int currentSceneNb;
+	int currentSceneNb;
 	shared_ptrScene sceneAnother; // used for temporarily running different simulation, in Omega().switchscene()
 
 	ptime startupLocalTime;

___
Mailing list: https://launchpad.net/~yade-dev
Post to : yade-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-dev
More help   : https://help.launchpad.net/ListHelp


[Yade-dev] buildbot failure in Yade on yade-full

2012-02-13 Thread buildbot
The Buildbot has detected a failed build of yade-full on Yade.
Full details are available at:
 http://yade-dem.org/buildbot/builders/yade-full/builds/1002

Buildbot URL: http://yade-dem.org/buildbot/

Buildslave for this Build: r0calcul10

Build Reason: 
Build Source Stamp: 3023
Blamelist: Jan Stransky _hon...@centrum.cz

BUILD FAILED: failed shell_3 shell_5

sincerely,
 -The Buildbot


___
Mailing list: https://launchpad.net/~yade-dev
Post to : yade-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-dev
More help   : https://help.launchpad.net/ListHelp


[Yade-dev] [Branch ~yade-dev/yade/trunk] Rev 3024: Add speed-parameter to Scene and Omega

2012-02-13 Thread noreply

revno: 3024
committer: Anton Gladky gladky.an...@gmail.com
branch nick: yade
timestamp: Mon 2012-02-13 21:38:28 +0100
message:
  Add speed-parameter to Scene and Omega
modified:
  core/Scene.cpp
  core/Scene.hpp
  py/wrapper/yadeWrapper.cpp


--
lp:yade
https://code.launchpad.net/~yade-dev/yade/trunk

Your team Yade developers is subscribed to branch lp:yade.
To unsubscribe from this branch go to 
https://code.launchpad.net/~yade-dev/yade/trunk/+edit-subscription
=== modified file 'core/Scene.cpp'
--- core/Scene.cpp	2011-03-17 13:47:46 +
+++ core/Scene.cpp	2012-02-13 20:38:28 +
@@ -98,6 +98,16 @@
 			if(unlikely(TimingInfo_enabled)) {TimingInfo::delta now=TimingInfo::getNow(); e-timingInfo.nsec+=now-last; e-timingInfo.nExec+=1; last=now;}
 		}
 		// ** 3. ** epilogue
+		if (iter==0) {//For the first time
+			prevTime = boost::posix_time::microsec_clock::local_time();
+		} else {
+			boost::posix_time::ptime timeNow = boost::posix_time::microsec_clock::local_time();
+			boost::posix_time::time_duration duration = timeNow - prevTime;
+			long dif = duration.total_microseconds();
+			speed = 100.0 / dif;
+			prevTime = timeNow;
+		}
+		
 		iter++;
 		time+=dt;
 		subStep=-1;

=== modified file 'core/Scene.hpp'
--- core/Scene.hpp	2011-02-27 13:54:43 +
+++ core/Scene.hpp	2012-02-13 20:38:28 +
@@ -70,6 +70,7 @@
 		void setLocalCoords(bool d){ if(d) flags|=LOCAL_COORDS; else flags=~(LOCAL_COORDS); }
 		bool compressionNegative() const { return flags  COMPRESSION_NEGATIVE; }
 		void setCompressionNegative(bool d){ if(d) flags|=COMPRESSION_NEGATIVE; else flags=~(COMPRESSION_NEGATIVE); }
+		boost::posix_time::ptime prevTime; //Time value on the previous step
 
 
 	YADE_CLASS_BASE_DOC_ATTRS_CTOR_PY(Scene,Serializable,Object comprising the whole simulation.,
@@ -78,6 +79,7 @@
 		((bool,subStepping,false,,Whether we currently advance by one engine in every step (rather than by single run through all engines).))
 		((int,subStep,-1,Attr::readonly,Number of sub-step; not to be changed directly. -1 means to run loop prologue (cell integration), 0…n-1 runs respective engines (n is number of engines), n runs epilogue (increment step number and time.))
 		((Real,time,0,Attr::readonly,Simulation time (virtual time) [s]))
+		((Real,speed,0,Attr::readonly,Current calculation speed [iter/s]))
 		((long,stopAtIter,0,,Iteration after which to stop the simulation.))
 		#if 0
 			// not yet implemented

=== modified file 'py/wrapper/yadeWrapper.cpp'
--- py/wrapper/yadeWrapper.cpp	2012-02-13 10:36:56 +
+++ py/wrapper/yadeWrapper.cpp	2012-02-13 20:38:28 +
@@ -334,6 +334,7 @@
 
 	double time(){return OMEGA.getScene()-time;}
 	double realTime(){ return OMEGA.getRealTime(); }
+	double speed(){ return OMEGA.getScene()-speed; }
 	double dt_get(){return OMEGA.getScene()-dt;}
 	void dt_set(double dt){
 		Scene* scene=OMEGA.getScene().get();
@@ -535,6 +536,7 @@
 		.add_property(stopAtIter,pyOmega::stopAtIter_get,pyOmega::stopAtIter_set,Get/set number of iteration after which the simulation will stop.)
 		.add_property(time,pyOmega::time,Return virtual (model world) time of the simulation.)
 		.add_property(realtime,pyOmega::realTime,Return clock (human world) time the simulation has been running.)
+		.add_property(speed,pyOmega::speed,Return current calculation speed [iter/sec].)
 		.add_property(dt,pyOmega::dt_get,pyOmega::dt_set,Current timestep (Δt) value.\n\n* assigning negative value enables dynamic Δt (by looking for a :yref:`TimeStepper` in :yref:`O.engineOmega.engines`) and sets positive timestep ``O.dt=|Δt|`` (will be used until the timestepper is run and updates it)\n* assigning positive value sets Δt to that value and disables dynamic Δt (via :yref:`TimeStepper`, if there is one).\n\n:yref:`dynDtOmega.dynDt` can be used to query whether dynamic Δt is in use.)
 		.add_property(dynDt,pyOmega::dynDt_get,Whether a :yref:`TimeStepper` is used for dynamic Δt control. See :yref:`dtOmega.dt` on how to enable/disable :yref:`TimeStepper`.)
 		.add_property(dynDtAvailable,pyOmega::dynDtAvailable_get,Whether a :yref:`TimeStepper` is amongst :yref:`O.enginesOmega.engines`, activated or not.)

___
Mailing list: https://launchpad.net/~yade-dev
Post to : yade-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-dev
More help   : https://help.launchpad.net/ListHelp


[Yade-dev] [Bug 931263] Re: localhost info

2012-02-13 Thread Anton Gladky
I hope r3025 will fix the bug.

-- 
You received this bug notification because you are a member of Yade
developers, which is the registrant for Yade.
https://bugs.launchpad.net/bugs/931263

Title:
  localhost info

Status in Yet Another Dynamic Engine:
  Fix Released

Bug description:
  When running a simulation, which has already some pre-history (e.g.
  load a simulation which has done already 10 iterations and run
  some more simulations), in batch mode some information in localhost
  info are wrong. I guess the average iterations per seconds include the
  iterations from the loaded state. Therefore, the value is far to high
  and the estimate for the finishing time/date is as well wrong. When
  running without batch mode the controller is showing the correct
  value.

To manage notifications about this bug go to:
https://bugs.launchpad.net/yade/+bug/931263/+subscriptions

___
Mailing list: https://launchpad.net/~yade-dev
Post to : yade-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-dev
More help   : https://help.launchpad.net/ListHelp


[Yade-dev] [Bug 931263] Re: localhost info

2012-02-13 Thread Anton Gladky
** Changed in: yade
   Status: New = Fix Released

-- 
You received this bug notification because you are a member of Yade
developers, which is the registrant for Yade.
https://bugs.launchpad.net/bugs/931263

Title:
  localhost info

Status in Yet Another Dynamic Engine:
  Fix Released

Bug description:
  When running a simulation, which has already some pre-history (e.g.
  load a simulation which has done already 10 iterations and run
  some more simulations), in batch mode some information in localhost
  info are wrong. I guess the average iterations per seconds include the
  iterations from the loaded state. Therefore, the value is far to high
  and the estimate for the finishing time/date is as well wrong. When
  running without batch mode the controller is showing the correct
  value.

To manage notifications about this bug go to:
https://bugs.launchpad.net/yade/+bug/931263/+subscriptions

___
Mailing list: https://launchpad.net/~yade-dev
Post to : yade-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-dev
More help   : https://help.launchpad.net/ListHelp


[Yade-dev] [Bug 931263] Re: localhost info

2012-02-13 Thread Launchpad Bug Tracker
** Branch linked: lp:yade

-- 
You received this bug notification because you are a member of Yade
developers, which is the registrant for Yade.
https://bugs.launchpad.net/bugs/931263

Title:
  localhost info

Status in Yet Another Dynamic Engine:
  Fix Released

Bug description:
  When running a simulation, which has already some pre-history (e.g.
  load a simulation which has done already 10 iterations and run
  some more simulations), in batch mode some information in localhost
  info are wrong. I guess the average iterations per seconds include the
  iterations from the loaded state. Therefore, the value is far to high
  and the estimate for the finishing time/date is as well wrong. When
  running without batch mode the controller is showing the correct
  value.

To manage notifications about this bug go to:
https://bugs.launchpad.net/yade/+bug/931263/+subscriptions

___
Mailing list: https://launchpad.net/~yade-dev
Post to : yade-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-dev
More help   : https://help.launchpad.net/ListHelp


[Yade-dev] [Branch ~yade-dev/yade/trunk] Rev 3025: Fix calculation speed show in batch-system

2012-02-13 Thread noreply

revno: 3025
fixes bug: https://launchpad.net/bugs/931263
committer: Anton Gladky gladky.an...@gmail.com
branch nick: yade
timestamp: Mon 2012-02-13 22:06:43 +0100
message:
  Fix calculation speed show in batch-system
modified:
  core/main/yade-batch.in
  py/remote.py


--
lp:yade
https://code.launchpad.net/~yade-dev/yade/trunk

Your team Yade developers is subscribed to branch lp:yade.
To unsubscribe from this branch go to 
https://code.launchpad.net/~yade-dev/yade/trunk/+edit-subscription
=== modified file 'core/main/yade-batch.in'
--- core/main/yade-batch.in	2011-07-21 13:36:28 +
+++ core/main/yade-batch.in	2012-02-13 21:06:43 +
@@ -79,10 +79,10 @@
 			ret+='td'
 			if info['stopAtIter']0:
 ret+='nobr%2.2f%% done/nobrbr/nobrstep %d/%d/nobr'%(info['iter']*100./info['stopAtIter'],info['iter'],info['stopAtIter'])
-finishTime = str(time.ctime(time.time()+int(round(info['stopAtIter']/(info['iter']/info['realtime'])
+finishTime = str(time.ctime(time.time()+int((round(info['stopAtIter'] - info['iter'])*info['speed']
 ret+='br/font size=1nobr%s finishes/nobr/fontbr/'%finishTime
 			else: ret+='nobrstep %d/nobr'%(info['iter'])
-			if info['realtime']!=0: ret+='br/nobravg %g/sec/nobr'%(info['iter']/info['realtime'])
+			if info['realtime']!=0: ret+='br/nobrspeed %g/sec/nobr'%(info['speed'])
 			ret+='br/nobr%d bodies/nobrbr/nobr%d intrs/nobr'%(info['numBodies'],info['numIntrs'])
 			ret+='/td'
 		else:

=== modified file 'py/remote.py'
--- py/remote.py	2011-04-07 12:19:45 +
+++ py/remote.py	2012-02-13 21:06:43 +
@@ -25,7 +25,7 @@
 
 class InfoProvider:
 	def basicInfo(self):
-		ret=dict(iter=O.iter,dt=O.dt,stopAtIter=O.stopAtIter,realtime=O.realtime,time=O.time,id=O.tags['id'] if O.tags.has_key('id') else None,threads=os.environ['OMP_NUM_THREADS'] if os.environ.has_key('OMP_NUM_THREADS') else '0',numBodies=len(O.bodies),numIntrs=len(O.interactions))
+		ret=dict(iter=O.iter,dt=O.dt,stopAtIter=O.stopAtIter,speed=O.speed,realtime=O.realtime,time=O.time,id=O.tags['id'] if O.tags.has_key('id') else None,threads=os.environ['OMP_NUM_THREADS'] if os.environ.has_key('OMP_NUM_THREADS') else '0',numBodies=len(O.bodies),numIntrs=len(O.interactions))
 		sys.stdout.flush(); sys.stderr.flush()
 		return ret
 	def plot(self):

___
Mailing list: https://launchpad.net/~yade-dev
Post to : yade-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-dev
More help   : https://help.launchpad.net/ListHelp


[Yade-dev] buildbot failure in Yade on yade-full

2012-02-13 Thread buildbot
The Buildbot has detected a failed build of yade-full on Yade.
Full details are available at:
 http://yade-dem.org/buildbot/builders/yade-full/builds/1003

Buildbot URL: http://yade-dem.org/buildbot/

Buildslave for this Build: r0calcul10

Build Reason: 
Build Source Stamp: 3024
Blamelist: Anton Gladky gladky.an...@gmail.com

BUILD FAILED: failed shell_3 shell_5

sincerely,
 -The Buildbot


___
Mailing list: https://launchpad.net/~yade-dev
Post to : yade-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-dev] [Bug 931263] Re: localhost info

2012-02-13 Thread Klaus Thoeni
Hi Anton,

well done! The information shown by the localhost are fine now. The only thing 
which is still strange is that the estimated day/time when finished is wrong 
even if the iter/sec is more or less constant. It gives dates like 20 March 
whereas the simulation is finished in 5 minutes. Towards the end of the 
simulation (90%) it's getting more realistic. The same problem exists for 
simulations starting from the beginning.

Not sure how the time/date is estimated. But since value iter/sec is correct 
it shouldn't behave so strange.

Thanks,
Klaus

On Tue, 14 Feb 2012 08:07:57 AM Anton Gladky wrote:
 I hope r3025 will fix the bug.

-- 
You received this bug notification because you are a member of Yade
developers, which is the registrant for Yade.
https://bugs.launchpad.net/bugs/931263

Title:
  localhost info

Status in Yet Another Dynamic Engine:
  Fix Released

Bug description:
  When running a simulation, which has already some pre-history (e.g.
  load a simulation which has done already 10 iterations and run
  some more simulations), in batch mode some information in localhost
  info are wrong. I guess the average iterations per seconds include the
  iterations from the loaded state. Therefore, the value is far to high
  and the estimate for the finishing time/date is as well wrong. When
  running without batch mode the controller is showing the correct
  value.

To manage notifications about this bug go to:
https://bugs.launchpad.net/yade/+bug/931263/+subscriptions

___
Mailing list: https://launchpad.net/~yade-dev
Post to : yade-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-dev
More help   : https://help.launchpad.net/ListHelp


[Yade-dev] [Branch ~yade-dev/yade/trunk] Rev 3026: Fix prediction of finish time in batch-mode.

2012-02-13 Thread noreply

revno: 3026
committer: Anton Gladky gladky.an...@gmail.com
branch nick: yade
timestamp: Tue 2012-02-14 07:40:46 +0100
message:
  Fix prediction of finish time in batch-mode.
modified:
  core/main/yade-batch.in


--
lp:yade
https://code.launchpad.net/~yade-dev/yade/trunk

Your team Yade developers is subscribed to branch lp:yade.
To unsubscribe from this branch go to 
https://code.launchpad.net/~yade-dev/yade/trunk/+edit-subscription
=== modified file 'core/main/yade-batch.in'
--- core/main/yade-batch.in	2012-02-13 21:06:43 +
+++ core/main/yade-batch.in	2012-02-14 06:40:46 +
@@ -79,7 +79,7 @@
 			ret+='td'
 			if info['stopAtIter']0:
 ret+='nobr%2.2f%% done/nobrbr/nobrstep %d/%d/nobr'%(info['iter']*100./info['stopAtIter'],info['iter'],info['stopAtIter'])
-finishTime = str(time.ctime(time.time()+int((round(info['stopAtIter'] - info['iter'])*info['speed']
+finishTime = str(time.ctime(time.time()+int((round(info['stopAtIter'] - info['iter'])/info['speed']
 ret+='br/font size=1nobr%s finishes/nobr/fontbr/'%finishTime
 			else: ret+='nobrstep %d/nobr'%(info['iter'])
 			if info['realtime']!=0: ret+='br/nobrspeed %g/sec/nobr'%(info['speed'])

___
Mailing list: https://launchpad.net/~yade-dev
Post to : yade-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-dev] [Bug 931263] Re: localhost info

2012-02-13 Thread Anton Gladky
Hi Klaus,

it should be ok in r3026. There was a typo in a formulation.

Thanks for pointing that out.

Anton


2012/2/14 Klaus Thoeni 931...@bugs.launchpad.net:
 Hi Anton,

 well done! The information shown by the localhost are fine now. The only thing
 which is still strange is that the estimated day/time when finished is wrong
 even if the iter/sec is more or less constant. It gives dates like 20 March
 whereas the simulation is finished in 5 minutes. Towards the end of the
 simulation (90%) it's getting more realistic. The same problem exists for
 simulations starting from the beginning.

 Not sure how the time/date is estimated. But since value iter/sec is correct
 it shouldn't behave so strange.

 Thanks,
 Klaus

 On Tue, 14 Feb 2012 08:07:57 AM Anton Gladky wrote:
 I hope r3025 will fix the bug.

 --
 You received this bug notification because you are subscribed to Yade.
 https://bugs.launchpad.net/bugs/931263

 Title:
  localhost info

 Status in Yet Another Dynamic Engine:
  Fix Released

 Bug description:
  When running a simulation, which has already some pre-history (e.g.
  load a simulation which has done already 10 iterations and run
  some more simulations), in batch mode some information in localhost
  info are wrong. I guess the average iterations per seconds include the
  iterations from the loaded state. Therefore, the value is far to high
  and the estimate for the finishing time/date is as well wrong. When
  running without batch mode the controller is showing the correct
  value.

 To manage notifications about this bug go to:
 https://bugs.launchpad.net/yade/+bug/931263/+subscriptions

-- 
You received this bug notification because you are a member of Yade
developers, which is the registrant for Yade.
https://bugs.launchpad.net/bugs/931263

Title:
  localhost info

Status in Yet Another Dynamic Engine:
  Fix Released

Bug description:
  When running a simulation, which has already some pre-history (e.g.
  load a simulation which has done already 10 iterations and run
  some more simulations), in batch mode some information in localhost
  info are wrong. I guess the average iterations per seconds include the
  iterations from the loaded state. Therefore, the value is far to high
  and the estimate for the finishing time/date is as well wrong. When
  running without batch mode the controller is showing the correct
  value.

To manage notifications about this bug go to:
https://bugs.launchpad.net/yade/+bug/931263/+subscriptions

___
Mailing list: https://launchpad.net/~yade-dev
Post to : yade-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-dev
More help   : https://help.launchpad.net/ListHelp