Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
C
cloud-orbit
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Katerina Roukounaki
cloud-orbit
Commits
b977756a
Commit
b977756a
authored
Jan 15, 2015
by
Aggelos Giantsios
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Document script that runs distributed orbit
parent
eb061331
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
50 additions
and
5 deletions
+50
-5
README.md
README.md
+29
-0
dist.py
dist.py
+21
-5
No files found.
README.md
View file @
b977756a
...
@@ -106,6 +106,35 @@ Python 2.x is needed in order to run the scripts.
...
@@ -106,6 +106,35 @@ Python 2.x is needed in order to run the scripts.
```
```
-
Distributed Orbit
```bash
python dist.py
```
Variables that can be tweaked with their default values.
```python
# Path to the file that will hold the results.
fname = 'dist.log'
# Number of repetitions per configuration.
reps = 1
# List of versions.
versions = ["short", "intermediate", "long"]
# Perform parallel image computations.
iwps = [False, True]
# No of cores used by each worker node.
cores = [1]
# Ratio of No of workers to No of cores in each worker node.
workersPerCore = 1
# Master node information
master = {"host": "127.0.0.1", "port": 5050}
# Maximum number of workers nodes
maxSlaves = 60
# No of workers nodes to add after each iteration
step = 2
# Port of the 1st worker node (Assume that the host will be localhost).
workerPort = 5051
```
Memory Profiling
Memory Profiling
----------------
----------------
...
...
dist.py
View file @
b977756a
...
@@ -4,6 +4,7 @@
...
@@ -4,6 +4,7 @@
from
__future__
import
print_function
from
__future__
import
print_function
import
sys
,
subprocess
,
time
,
os
.
path
import
sys
,
subprocess
,
time
,
os
.
path
# Path to the file that will hold the results.
fname
=
'dist.log'
fname
=
'dist.log'
fexists
=
os
.
path
.
isfile
(
fname
)
fexists
=
os
.
path
.
isfile
(
fname
)
if
fexists
:
if
fexists
:
...
@@ -19,15 +20,30 @@ def print_all(s):
...
@@ -19,15 +20,30 @@ def print_all(s):
f
.
flush
()
f
.
flush
()
print
(
s
,
file
=
sys
.
stdout
)
print
(
s
,
file
=
sys
.
stdout
)
# Number of repetitions per configuration.
reps
=
1
reps
=
1
# List of versions.
versions
=
[
"short"
,
"intermediate"
,
"long"
]
versions
=
[
"short"
,
"intermediate"
,
"long"
]
# Perform parallel image computations.
iwps
=
[
False
,
True
]
iwps
=
[
False
,
True
]
# No of cores used by each worker node.
cores
=
[
1
]
cores
=
[
1
]
# Ratio of No of workers to No of cores in each worker node.
workersPerCore
=
1
workersPerCore
=
1
# Master node information
master
=
{
"host"
:
"127.0.0.1"
,
"port"
:
5050
}
master
=
{
"host"
:
"127.0.0.1"
,
"port"
:
5050
}
# Maximum number of workers nodes
maxSlaves
=
60
# No of workers nodes to add after each iteration
step
=
2
# Port of the 1st worker node (Assume that the host will be localhost).
workerPort
=
5051
allAvailableSlaves
=
[]
for
port
in
range
(
workerPort
,
workerPort
+
maxSlaves
):
allAvailableSlaves
.
append
({
"host"
:
"127.0.0.1"
,
"port"
:
port
})
slaves
=
[]
slaves
=
[]
for
port
in
range
(
5051
,
5051
+
64
):
for
n
in
range
(
2
,
maxSlaves
+
1
,
step
):
slaves
.
append
(
{
"host"
:
"127.0.0.1"
,
"port"
:
port
}
)
slaves
.
append
(
allAvailableSlaves
[
0
:
n
]
)
if
len
(
ls
)
==
0
:
if
len
(
ls
)
==
0
:
print_all
(
"Parallel Orbit"
)
print_all
(
"Parallel Orbit"
)
...
@@ -38,17 +54,17 @@ if len(ls) == 0:
...
@@ -38,17 +54,17 @@ if len(ls) == 0:
print_all
(
"Using Cores:
%
s"
%
cores
)
print_all
(
"Using Cores:
%
s"
%
cores
)
print_all
(
"Workers Per Core:
%
s"
%
workersPerCore
)
print_all
(
"Workers Per Core:
%
s"
%
workersPerCore
)
print_all
(
"Master @
%
s"
%
master
)
print_all
(
"Master @
%
s"
%
master
)
print_all
(
"Slaves @
%
s"
%
slaves
)
print_all
(
"Slaves @
%
s"
%
[
len
(
xs
)
for
xs
in
slaves
]
)
print_all
(
"======================================================================"
)
print_all
(
"======================================================================"
)
for
iwp
in
iwps
:
for
iwp
in
iwps
:
for
vsn
in
versions
:
for
vsn
in
versions
:
for
n
in
range
(
2
,
60
+
1
,
2
)
:
for
slvs
in
slaves
:
for
core
in
cores
:
for
core
in
cores
:
for
rep
in
range
(
reps
):
for
rep
in
range
(
reps
):
workers
=
workersPerCore
*
core
workers
=
workersPerCore
*
core
slvs
=
slaves
[
0
:
n
]
n
=
len
(
slvs
)
l
=
"Slaves:
%
s, Version:
%
s, IWP:
%
s, Cores:
%
s, Workers:
%
s, Execution:
%
s"
%
(
n
,
vsn
,
iwp
,
core
,
workers
,
rep
)
l
=
"Slaves:
%
s, Version:
%
s, IWP:
%
s, Cores:
%
s, Workers:
%
s, Execution:
%
s"
%
(
n
,
vsn
,
iwp
,
core
,
workers
,
rep
)
if
l
in
ls
:
if
l
in
ls
:
continue
continue
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment