Log In | Get Help   
Home My Page Projects Code Snippets Project Openings BonFIRE VCOC Demonstration Kit
Summary Activity SCM Files Wiki
[bonfiredemokit] View of /ea/submit_file.py
[bonfiredemokit] / ea / submit_file.py Repository:
ViewVC logotype

View of /ea/submit_file.py

Parent Directory Parent Directory | Revision Log Revision Log


Revision 18 - (download) (as text) (annotate)
Tue Oct 9 16:17:03 2012 UTC (11 years, 7 months ago) by agomez
File size: 1530 byte(s)
Changed comments to English and test
#
# BonFIRE Virtual Clusters on Federated Clouds Demonstration Kit
#
# Copyright (c) Fundacion Centro Tecnologico de Supercomputacion de Galicia 2012
# 
# License Apache Software
#
# The research leading to these results has received funding from 
# the European Community's Seventh Framework Programme (FP7/2007-2013) 
# under agreement number 257386
#
# This software is provided with ABSOLUTELY NO WARRANTY
# 
'''
Created on 20/03/2012

@author: R. Valin
'''

#import matplotlib.pyplot as plt
import time
import json
import os
import sys
import random
#from exp.ea 
#import experiment_type as expt
#from exp.ea
import ea_bonfire as ea


#print 'Path to Json:'
#filej=raw_input()
if len(sys.argv) < 2:
    sys.stderr.write('A JSON file is needed')
    #sys.stderr.write('Usage: sys.argv[0] ')
    sys.exit(1)

filej="../examples/"+sys.argv[1]
if not os.path.exists(filej):
    sys.stderr.write('ERROR: file '+filej+ 'does not exist!')
    sys.exit(1)

print '----------------'
print 'Json PATH:',filej
print '----------------'

if os.path.exists(filej):
    jsonf=open(filej, 'r')
    exper=json.loads(jsonf.read())
    print exper
    jsonf.close()
else:
    print "File doesn't exist"
    

#duration = 120
#Number of repetitions

multi = 1

#for i in exp:
#    print i
#    m=str(i)
j=0
while j < multi:
    #save(locations)
    #location=info_location[m]
    #instance=info_instance[m]
    #store=info_storage[m]
    print 'Repetition before ea:', j
    j=ea.ea_bf(exper,j)
    j=j+1
    #time.sleep(float(130))
    

     

root@forge.cesga.es
ViewVC Help
Powered by ViewVC 1.0.0  

Powered By FusionForge