예제 #1
0
def visualize(files):
    output = []
    for fn in files:
        pf = load(fn)
        for field in FIELDS:
            slc = SlicePlot(pf, 'z', field)
            if field == "prei":
                slc.set_cmap(field, 'gist_stern')
            output.append(slc.save(fn.replace('.h5', '_%s.png' % field))[0])
    return output
예제 #2
0
def visualize(files):
    output = []
    for fn in files:
        pf = load(fn)
        for field in FIELDS:
            slc = SlicePlot(pf, 'z', field)
            if field == "prei":
                slc.set_cmap(field, 'gist_stern')
            output.append(slc.save(fn.replace('.h5', '_%s.png' % field))[0])
    return output
예제 #3
0
def visualize(files):
    output = []
    for fn in parallel_objects(files, njobs=-1):
        pf = load(fn)
        for field in FIELDS:
            slc = SlicePlot(pf, 'z', field)
            if field == 'curz':
                slc.set_cmap(field, 'bwr')
                maxabs = abs(slc._frb[field]).max()
                slc.set_log(field, False)
                slc.set_zlim(field, -maxabs, maxabs)
            output.append(slc.save(fn.replace('.h5', '_%s.png' % field))[0])
    return output