diff options
author | Mac Mollison <mollison@cs.unc.edu> | 2010-03-13 12:12:37 -0500 |
---|---|---|
committer | Mac Mollison <mollison@cs.unc.edu> | 2010-03-13 12:12:37 -0500 |
commit | 122f457226f54ad23b7cd138512502e430e704dc (patch) | |
tree | fee0690936c3ae95255e559cd0fd09f0fa8c2ad4 /unit_trace/visualizer.py | |
parent | 14a40b99735f09f6e70b8e897acbb622f9115ca3 (diff) |
Further restructuring to create 'unit_trace' pkg
The unit_trace folder should be placed in
/usr/local/lib/pythonX.Y/site-packages.
This makes unit-trace submodules available from anywhere
on the system.
Diffstat (limited to 'unit_trace/visualizer.py')
-rwxr-xr-x | unit_trace/visualizer.py | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/unit_trace/visualizer.py b/unit_trace/visualizer.py new file mode 100755 index 0000000..c15bf51 --- /dev/null +++ b/unit_trace/visualizer.py | |||
@@ -0,0 +1,11 @@ | |||
1 | #!/usr/bin/python | ||
2 | import gtk | ||
3 | import viz | ||
4 | |||
5 | def visualizer(stream): | ||
6 | sched = viz.convert.convert_trace_to_schedule(stream) | ||
7 | sched.scan(10000000) | ||
8 | renderer = viz.renderer.Renderer(sched) | ||
9 | renderer.prepare_task_graph(attrs=viz.format.GraphFormat(time_per_maj=10000000)) | ||
10 | viz.viewer.MainWindow(renderer) | ||
11 | gtk.main() | ||