-
Notifications
You must be signed in to change notification settings - Fork 0
/
README
73 lines (56 loc) · 2.58 KB
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
TASK-DISTRIBUTOR v1.0 (August 8th 2014)
================
SYNOPSIS
--------
task-distributor-master.sh -n nodes -x width -y height -p path
DESCRIPTION
-----------
Task-Distributor is a collection of two bash scripts, which simplify the
parallel generation of images by using the ray tracing software POV-Ray by using
multiple worker nodes in parallel. POV-Ray supports to calculate just a part of
the final image (a limited number of rows).
REQUIREMENTS
------------
These software packages must be installed on all worker nodes:
- POV-Ray 3.7
- bash 4.2.37
- ImageMagick 6.7.7
- bc 1.06.95
A shared folder, which can be accessed by the master node and all
worker nodes must exist, because this shared folder is required to store the
lockfile and the image parts. The shared folder can be implemented via a
distributed file system or a protocol (e.g. NFS)
task-distributor-master.sh
--------------------------
This script creates a lockfile on a shared folder, which can be accessed by the
master node and all worker nodes.
As next step, the script starts via ssh a POV-Ray job on each worker node.
After the POV-Ray jobs have been started, the script checks in an infinite loop
if each worker node has placed its hostname into the lockfile. If this
condition is met, the script composes the image parts via the command line tool
convert from the ImageMagick project to create the final image.
task-distributor-worker.sh
--------------------------
This script must be located on each worker node because it executes the POV-ray
render job according to the instructions of the master node and stores the
resulting image part on a shared folder, which can be accessed by the master
node and all worker nodes.
It is possible with POV-Ray to render only a subset of *rows* but since POV-Ray
3.7 the output is always a full height image and not rendered rows are filled
with black pixels.
The script removes the black rows with the command line tool convert from the
ImageMagick project to reduce the network traffic and the amount of data which
needs the master to process finally for creating the final image.
Finally, the script writes the hostname of the worker node into the lockfile to
inform the master node that the image part of this worker node is now available.
EXAMPLE
-------
./task-distributor-master.sh -n 8 -x 800 -y 600 -p /glusterfs/povray
WEB SITE
--------
Visit the Task-Distributor web page for more information and the latest revision:
http://code.google.com/p/task-distributor
LICENSE
-------
GPLv2 or later.
http://www.gnu.org/licenses/gpl-2.0.html