views:

176

answers:

5

I am working on a simulation in Queueing Theory, within a wxPython GUI. (Project link.) What would be a good tool for visualizing the simulations? The visualization should consist of simple objects, such as clients, servers, a facility and a population. They should all be represented by simple boxes or something like that. There will be several queues in which clients will wait.

Since this is a visualization of a progressing simulation, objects will move around the screen, and it would be nice if they could move smoothly from one place to another, and not jump abruptly.

What would be a good tool to create that visualization? I could do it in native wxPython graphics. I could also use PyGame. But maybe someone here has something better to recommend?

A: 

Here's a list of some 2D Graphics packages you might consider:

http://www.vrplumber.com/py3d.py?category=graphics

tgray
A: 

wxPython has the OGL (Object Graphics Library) for doing this sort of thing. I have not used it so I don't know how useful or robust it is, but it should be easier than using raw wx graphics primitives.

It is in wx.lib.ogl.

Dave Kirby
Checked it out, development is dead.
cool-RR
+1  A: 

Have you considered using NS3? It may be a little more than what you're looking for, but it is the standard for open source queue simulations. Here's the documentation on Python bindings for NS3.

Shane
A: 

You could try using one of the Python bindings for GraphViz. I could see something like this http://www.graphviz.org/Gallery/directed/cluster.html being used to illustrate a queue simulation.

I use Pydot and its gret: http://code.google.com/p/pydot/

The only problem is that Pydot only writes the GraphViz files, you would have to use GraphViz itself or other renderer (such as Canviz http://www.ryandesign.com/canviz/) to obtain the graphics.

The advantage is that you just have to defined the structure of the graph and forget about time-consuming details such as line routing, drawing, etc.

Hope it helps

Fabio de Miranda
A: 

I would consider using VPython. You could also create a dynamic graphic in Java using Processing, and have the simulation send update messages through your network protocol of choice.

Paul McGuire