https://github.com/geodynamics/citcoms
Tip revision: 7d64cb0fdcaf86bd73986331b367a830e15dce71 authored by Rajesh Kommu on 05 September 2014, 23:19:57 UTC
added benchmark files, Python scripts and workflow documentation to benchmarks folder
added benchmark files, Python scripts and workflow documentation to benchmarks folder
Tip revision: 7d64cb0
citcoms_datadir
#!/usr/bin/env python
def get_var():
# get your username on this machine, and make it upper case
import os
var = os.environ.get("USER")
return var.upper()
# invariant prefix of datadir
prefix = "/scratch/"
# invariant suffix of datadir
suffix = ""
# get the machine-dependent part of datadir
var_path = get_var()
# construct the full string for datadir
print "%s%s%s" % ( prefix, var_path, suffix )