def fitnessUnitVector(vec,**kwargs):
    target = [1.0,1.0,1.0,1.0,1.0,1.0,1.0,1.0,1.0]
    sum_sq = 0.0
    for i in range(len(vec)):
        sum_sq += (target[i] - vec[i])**2
    score =  np.sqrt(sum_sq)
    #print "Score:",score
    return score
dataset/ETHPy150Open bolme/pyvision/src/pyvision/optimize/testsuite.py/fitnessUnitVector/original