| The Gaudi Framework v28r2-patches (bc4ad17a)

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- Namespace List
- Namespace Members

Functions | Variables
prepareBenchmark Namespace Reference

## Functions
def | prepareConfig (template_filename, n_threads=10, n_parallel_events=10, n_parallel_algorithms=10)

## Variables
int | n_threads = 10
| config = prepareConfig("../options/BrunelScenario.py",n_threads=n_threads,n_parallel_events=n_events,n_parallel_algorithms=n_algos)

## Function Documentation

def prepareBenchmark.prepareConfig | ( |  | template_filename,
|  |  | n_threads = `10`,
|  |  | n_parallel_events = `10`,
|  |  | n_parallel_algorithms = `10`
| ) |  |

Definition at line 5 of file prepareBenchmark.py.

5 def prepareConfig(template_filename, n_threads=10, n_parallel_events=10,n_parallel_algorithms=10):
6 template = open(template_filename)
7 new_filename = "%s_%i_%i_%i.py" %(template_filename.rstrip(".py"),n_threads,n_parallel_events,n_parallel_algorithms)
8 new_config = open(new_filename,"w")
9 for line in template.readlines():
10 if line.startswith("n_threads"):
11 line = "n_threads = %i\n" %n_threads
12 elif line.startswith("n_parallel_events"):
13 line = "n_parallel_events = %i\n" %n_parallel_events
14 elif line.startswith("n_parallel_algorithms"):
15 line = "n_parallel_algorithms = %i\n" %n_parallel_algorithms
16 new_config.write(line)
17 new_config.close()
18 return new_filename
19
20
prepareBenchmark.prepareConfig
def prepareConfig(template_filename, n_threads=10, n_parallel_events=10, n_parallel_algorithms=10)
Definition: prepareBenchmark.py:5

## Variable Documentation

prepareBenchmark.config = prepareConfig("../options/BrunelScenario.py",n_threads=n_threads,n_parallel_events=n_events,n_parallel_algorithms=n_algos)

Definition at line 27 of file prepareBenchmark.py.

int prepareBenchmark.n_threads = 10

Definition at line 24 of file prepareBenchmark.py.