@@ -158,24 +158,17 @@ def consumption(
158158 dimensions as `production`.
159159
160160 """
161- from muse .utilities import filter_with_template
162-
163- params = filter_with_template (
164- technologies [["fixed_inputs" , "flexible_inputs" , "fixed_outputs" ]],
165- production ,
166- )
167-
168161 # Calculate degree of technology activity
169- prod_amplitude = production_amplitude (production , params )
162+ prod_amplitude = production_amplitude (production , technologies )
170163
171164 # Calculate consumption of fixed commodities
172165 consumption_fixed = prod_amplitude * broadcast_timeslice (
173- params .fixed_inputs , level = timeslice_level
166+ technologies .fixed_inputs , level = timeslice_level
174167 )
175168 assert all (consumption_fixed .commodity .values == production .commodity .values )
176169
177170 # If there are no flexible inputs, then we are done
178- if not (params .flexible_inputs > 0 ).any ():
171+ if not (technologies .flexible_inputs > 0 ).any ():
179172 return consumption_fixed
180173
181174 # If prices are not given, then we can't consider flexible inputs, so just return
@@ -184,7 +177,7 @@ def consumption(
184177 return consumption_fixed
185178
186179 # Flexible inputs
187- flexs = broadcast_timeslice (params .flexible_inputs , level = timeslice_level )
180+ flexs = broadcast_timeslice (technologies .flexible_inputs , level = timeslice_level )
188181
189182 # Calculate the cheapest fuel for each flexible technology
190183 priceflex = prices * flexs
0 commit comments