Skip to content

Commit

Permalink
#1863 fix input_parameter expected size if no domain
Browse files Browse the repository at this point in the history
  • Loading branch information
martinjrobins committed Apr 5, 2022
1 parent 9a46550 commit f11ef1c
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion pybamm/discretisations/discretisation.py
Original file line number Diff line number Diff line change
Expand Up @@ -1036,7 +1036,10 @@ def _process_symbol(self, symbol):
return new_symbol

elif isinstance(symbol, pybamm.InputParameter):
expected_size = self._get_variable_size(symbol)
if symbol.domain != []:
expected_size = self._get_variable_size(symbol)
else:
expected_size = None
return symbol.create_copy(expected_size=expected_size)
else:
# Backup option: return the object
Expand Down

0 comments on commit f11ef1c

Please sign in to comment.