Skip to content

Commit

Permalink
Use bodies attribute of SingleArcSimulator to create dependent variab…
Browse files Browse the repository at this point in the history
…le dictionary
  • Loading branch information
alopezrivera committed Aug 5, 2024
1 parent b9aa321 commit 2665239
Showing 1 changed file with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -226,8 +226,7 @@ def asarray(self, key: VariableSettings) -> np.ndarray:


def create_dependent_variable_dictionary(
dynamics_simulator: numerical_simulation.SingleArcSimulator,
bodies: numerical_simulation.environment.SystemOfBodies
dynamics_simulator: numerical_simulation.SingleArcSimulator
) -> DependentVariableDictionary:
"""
Construct a dictionary-like object (`DependentVariableDictionary`) which maps which maps dependent variables
Expand Down Expand Up @@ -268,7 +267,7 @@ def create_dependent_variable_dictionary(
for ((i, m), dependent_variable) in dependent_variable_settings.items():

# Retrieve dependent variable shape
A, B = get_dependent_variable_shape(dependent_variable, bodies)
A, B = get_dependent_variable_shape(dependent_variable, dynamics_simulator.bodies)

# Save dependent variable history as a tensor of (A, B)-sized
# matrices with `n` entries, where `n` is the number of epochs
Expand Down

0 comments on commit 2665239

Please sign in to comment.