max_hours = 6,
                efficiency_store=0.95,
                efficiency_dispatch=0.95)
    else:
        network.add("Generator",bus_name + " " + tech_name,
                bus=bus_name,p_nom=1000*cap[(bus_name,tech_name)],
                marginal_cost=m_costs.get(tech_name,default_cost),
                source=tech_name)   

## Add renewables

import generation.germany as DEgen

reload(DEgen)

generation = DEgen.timeseries_eeg(graph)


generation.items

#Kill the Timezone information to avoid pandas bugs
generation.major_axis = generation.major_axis.values

generation.loc[["wind","solar"],network.snapshots,:].sum(axis=2).plot()

solar = generation.loc["solar",network.snapshots,:].sum(axis=1)
solar.describe()

#make sure the ordering of the minor axis is correc
generation.minor_axis = graph.nodes()
                    efficiency_dispatch=0.95)
    else:
        network.add("Generator",
                    bus_name + " " + tech_name,
                    bus=bus_name,
                    p_nom=1000 * cap[(bus_name, tech_name)],
                    marginal_cost=m_costs.get(tech_name, default_cost),
                    carrier=tech_name)

## Add renewables

import generation.germany as DEgen

reload(DEgen)

generation = DEgen.timeseries_eeg(graph)

generation.items

#Kill the Timezone information to avoid pandas bugs
generation.major_axis = generation.major_axis.values

generation.loc[["wind", "solar"], network.snapshots, :].sum(axis=2).plot()

solar = generation.loc["solar", network.snapshots, :].sum(axis=1)
solar.describe()

#make sure the ordering of the minor axis is correc
generation.minor_axis = graph.nodes()

## Get the capacities correct