Skip to content

Commit

Permalink
Merge pull request #1211 from NREL-Sienna/jd/change_axes_checks
Browse files Browse the repository at this point in the history
Jd/change axes checks
  • Loading branch information
jd-lara authored Jan 8, 2025
2 parents 59d10f3 + 256029e commit 74accff
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion src/simulation/simulation_state.jl
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,16 @@ function _initialize_system_states!(
dm_cols = get_column_names(key, get_dataset(decision_states, key))
if has_dataset(emulator_states, key)
em_cols = get_column_names(key, get_dataset(emulator_states, key))
@assert_op dm_cols == em_cols
if length(dm_cols) != length(em_cols)
error(
"The number of dimensions between the decision states and emulator states don't match",
)
end
if !isempty(symdiff(first(dm_cols), first(em_cols)))
error(
"Mismatch in column names for dataset $key: $(symdiff(dm_cols, em_cols))",
)
end
continue
end

Expand Down

0 comments on commit 74accff

Please sign in to comment.