Felipe | 8 Jul 01:04
Picon

Pausing a simulation

Hello,
 
being new to this list I would first like to say hi to everyone and a few words to explain what I am looking for .
I started using SimPy to simulate and compare two Business Processes.
I want to do a visualization as the simulation unfolds, but for this I would need the Simulation to pause while I render the situation, and then resume again.
In effect, pausing the Simulation time.
 
How can I achieve this? I was looking for a method pause() or something like that, but to no avail.
 
Thanks in advance for your input.
 
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Simpy-users mailing list
Simpy-users <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/simpy-users
Deborah Loach | 8 Jul 03:19
Picon

Re: Pausing a simulation

Hi,

   I'm currently finishing up a simulation of an inventory system that links to a graphical display with a few other people.  The logic of the code linking to the display is that it keeps track of the time from simPy at which each event executes, and then puts the events into an event list (created by you) to buffer them, so that they can later be read from this list for visualization purposes.  We're planning to post all of our code for this simulation on the SimPy wiki when we finish it.  We'll probably be done by early next week.

Welcome to the list - I just joined last week.

Hope this is helpful.

Deborah

On 7/7/07, Felipe <feli.hp <at> gmail.com > wrote:
Hello,
 
being new to this list I would first like to say hi to everyone and a few words to explain what I am looking for .
I started using SimPy to simulate and compare two Business Processes.
I want to do a visualization as the simulation unfolds, but for this I would need the Simulation to pause while I render the situation, and then resume again.
In effect, pausing the Simulation time.
 
How can I achieve this? I was looking for a method pause() or something like that, but to no avail.
 
Thanks in advance for your input.
 

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Simpy-users mailing list
Simpy-users <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/simpy-users


-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Simpy-users mailing list
Simpy-users <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/simpy-users
Felipe | 8 Jul 03:46
Picon

Re: Shift schedules for several concurrent processes

 
Hi Deborah,
 
assuming each area is modeled with a process instance, an idea to account for shifts could be to create two events (or more, for breaks) for each shift that you need, one firing when the shift starts, the other when it ends. (you would have to figure out how to make them fire, evaluating now() against some function, depending on your time units) 
The processes would be listening for those events, activating or interrupting their process execution when receiving the event.
If the processes are objects of the same class, you would have to pass an argument when you create them that defines what shift they ought to have, adjusting your event listener accordingly.
 
Like those horns that were used in those mass-production line factories :)
 
Hope it helps somehow..
Kind regards
 
Felipe
 

Date: Sat, 23 Jun 2007 10:45:23 +1200
From: "Tony Vignaux" < vignaux <at> gmail.com>
Subject: [Simpy-users] Fwd: Simulation help
To: "SimPy Users" <simpy-users <at> lists.sourceforge.net>
Cc: Loach Deb < loach1 <at> uwindsor.ca>
Message-ID:
       <4ff53b1b0706221545g123eb736s98ad876f54ca41f3 <at> mail.gmail.com >
Content-Type: text/plain; charset="iso-8859-1"

Forwarded from Deb Loach. Any ideas?

  I'm currently completing a rather large simulation of a pull-based
inventory control system for General Motors in Windsor, ON and was wondering
if you could help me out a bit.  I've learned how to use SimEvents to send
signals in the program, but am having trouble determining how to account for
shift schedules.  I am simulating two areas simultaneously in the company
and they have different shift/break schedules.  Do you have any example
simulations where shift schedules are taken into account?  If so, could you
send me a copy of one.  Otherwise, what do you think is the best way to
account for shifts?

Thanks!

Deborah
-------------- next part --------------
An HTML attachment was scrubbed...

------------------------------


-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Simpy-users mailing list
Simpy-users <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/simpy-users
Klaus Muller | 8 Jul 06:34
Picon
Picon
Favicon

Re: Pausing a simulation

Hi Felipe,
Welcome to the list!
I am not quite sure what you want to do to render the visualization.
 
If you want to synchronize the simulation time with wall clock time, you can use SimulationRT. If you want to get control back at each event, you can use SimulationStep.
 
Could you provide more detail, please?
 
Klaus Muller

From: simpy-users-bounces <at> lists.sourceforge.net [mailto:simpy-users-bounces <at> lists.sourceforge.net] On Behalf Of Felipe
Sent: Sunday, July 08, 2007 1:05 AM
To: simpy-users <at> lists.sourceforge.net
Subject: [Simpy-users] Pausing a simulation

Hello,
 
being new to this list I would first like to say hi to everyone and a few words to explain what I am looking for .
I started using SimPy to simulate and compare two Business Processes.
I want to do a visualization as the simulation unfolds, but for this I would need the Simulation to pause while I render the situation, and then resume again.
In effect, pausing the Simulation time.
 
How can I achieve this? I was looking for a method pause() or something like that, but to no avail.
 
Thanks in advance for your input.
 
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Simpy-users mailing list
Simpy-users <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/simpy-users
RCRamsdell | 9 Jul 21:25
Favicon

Re: Pausing a simulation

Hi Felipe,

I had to do something like this.  What I came up with was a simpy
Process (CheckStatus shown below) that updates the gui (visualization)
at a given simulation time period.  In my gui class, I instantiate and
activate this process before calling simulate().  As Klaus suggested, I
use SimulationRT and give the user the option to run in real-time or
flat-out.  The simulation does not exactly pause, but nothing else
happens while the CheckStatus is active, during which time it calls the
function(s) to update the gui.

from SimPy.SimulationRT import *

class CheckStatus(Process):
    """CheckStatus - perodically update the gui with the status of the
    simulation.
    """
    def __init__(self, args, updateFunc, resultsFunc):
        Process.__init__(self, name='StatusChecker')
        self.updateRate = 1     #How often the gui is updated in sim
time
        self.updateFunc = updateFunc  #A function that shows the status
of the sims  
        self.resultsFunc = resultsFunc#A function that shows the results
to date
    def updater(self):
        self.updateFunc(time=0)
        while True:
            yield hold, self, self.updateRate
            self.updateFunc(time=now())
            self.resultsFunc()

class HopperDisplay(wx.Frame):
    def __init__(self, title='OBOSim Controls', setup=None, stats=None,
                 argv=None):
        ...

    def mnuRunSimulation(self, e):
        """
        mnuRunSimulation - Run the simulation and display results
        """
        self.simObjects = self.setupSim(self.args)
        Dredges, riser, project = self.simObjects
        if self.args['real_time']:
            cs = CheckStatus(self.args, self.showDredgeStatus,
self.showSimulationResults)
            activate(cs, cs.updater())
        simulate(until=1440*10000, real_time=self.args['real_time'],
                 rel_speed=self.args['rel_speed'])
        self.showSimulationResults()

Robert

________________________________

	From: simpy-users-bounces <at> lists.sourceforge.net
[mailto:simpy-users-bounces <at> lists.sourceforge.net] On Behalf Of Felipe
	Sent: Saturday, July 07, 2007 6:05 PM
	To: simpy-users <at> lists.sourceforge.net
	Subject: [Simpy-users] Pausing a simulation
	
	
	Hello,
	 
	being new to this list I would first like to say hi to everyone
and a few words to explain what I am looking for .
	I started using SimPy to simulate and compare two Business
Processes.
	I want to do a visualization as the simulation unfolds, but for
this I would need the Simulation to pause while I render the situation,
and then resume again.
	In effect, pausing the Simulation time.
	 
	How can I achieve this? I was looking for a method pause() or
something like that, but to no avail.
	 
	Thanks in advance for your input.

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
Tony Vignaux | 22 Jul 01:49
Picon
Gravatar

Re: Installing SImpy

Adolfo,

Klaus Muller is away at the moment so I am replying.

I assume you have installed Python. If so, having extracted SimPyfrom the distribution, you need to run python setup.py install in the SimPy directory.  Here is an extract from the SimPy home page

Download URL 

SimPy can be downloaded from the SimPy download page at SourceForge.net.

The download formats are Python source distributions in zip for Windows and tar.gz for Unix etc.

After unpacking, SimPy can be installed by executing 
"python setup.py install".

(This reply is copied to the simpy-users list)

Tony Vignaux


On 7/22/07, Adolfo Aguirre <aguirre.adolfo <at> gmail.com > wrote:
Hi: I am  very newbie to Linux and I want to install SimPy. I downloaded a tar.gz file from souerceforge, I extracted it and have a folder named Simpy with all contents. Whats next? 
I am running Ubuntu 7.04 for x64 with 1 gigi of Ram

Appreciating your attention,

Adolfo Aguirre

-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >>  http://get.splunk.com/
_______________________________________________
Simpy-users mailing list
Simpy-users <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/simpy-users

Gmane