def display(g, light=False, isolated=True, illuminated=None):
    if not light:
        scene = create_scene_from_mtg(g)
        pgl.Viewer.display(scene)
    else:
        if illuminated is None:
            cs, raw, agg = illuminate(g, isolated=isolated)
        else:
            cs, raw, agg = illuminated
        cs.plot(raw['Ei'], minval=0, maxval=1)
Esempio n. 2
0
def display(g, light=False, illumination=None, **kwds):
    if not light:
        scene = create_scene_from_mtg(g)
        pgl.Viewer.display(scene)
    else:
        if illumination is None:
            cs, raw, agg = illuminate(g, **kwds)
        else:
            cs, raw, agg = illumination
        cs.plot(raw['Ei'], minval=0, maxval=1)
Esempio n. 3
0
def display_res(row, light=False):
    g_pars = ['plant_area', 'phytomer', 'seed', 'plant_height', 'rmax', 'skew', 'wl_slp', 'w0_slp', 'lm_slp',
              'incli_top', 'incli_base', 'infl', 'phyllotactic_angle', 'phyllotactic_deviation', 'stage']
    output = ['Ei', 'Ei_leaf', 'Area', 'Area_leaf']
    g = generate_mtg(**row[row.index[row.index.isin(g_pars)]].to_dict())
    if not light:
        scene = create_scene_from_mtg(g)
        pgl.Viewer.display(scene)
    else:
        kwds = row[row.index[~row.index.isin(g_pars + output)]].to_dict()
        cs, raw, agg = illuminate(g, **kwds)
        cs.plot(raw['Ei'], minval=0, maxval=1)