Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Jd/add psid example data #57

Merged
merged 5 commits into from
Jun 26, 2023
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Artifacts.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
git-tree-sha1 = "8ca703c3979927752c9ff77a32bd85f3c97d93b9"

[[CaseData.download]]
url = "https://github.com/NREL-Sienna/PowerSystemsTestData/archive/refs/tags/1.0.1.tar.gz"
url = "https://github.com/NREL-Sienna/PowerSystemsTestData/archive/refs/tags/1.0.2.tar.gz"
sha256 = "15d0e7a8c7e40e62ae2a77a4691fc83a2c6a60dc79774411bcf0bfb6ecea5a57"

[rts]
Expand Down
28 changes: 26 additions & 2 deletions src/library/psid_library.jl
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ function build_psid_4bus_multigen(; kwargs...)
dyr_file = joinpath(data_dir, "FourBus_multigen.dyr")

sys = System(raw_file, dyr_file; sys_kwargs...)
for l in get_components(PSY.PowerLoad, sys)
PSY.set_model!(l, PSY.LoadModels.ConstantImpedance)
for l in get_components(PSY.StandardLoad, sys)
transform_load_to_constant_impedance(l)
end
return sys
end
Expand All @@ -18,5 +18,29 @@ function build_psid_11bus_andes(; kwargs...)
raw_file = joinpath(data_dir, "11BUS_KUNDUR.raw")
dyr_file = joinpath(data_dir, "11BUS_KUNDUR_TGOV.dyr")
sys = System(raw_file, dyr_file; sys_kwargs...)
for l in get_components(PSY.StandardLoad, sys)
transform_load_to_constant_impedance(l)
end
return sys
end

function build_psid_omib(; kwargs...)
sys_kwargs = filter_kwargs(; kwargs...)
sys_file = joinpath(DATA_DIR, "psid_tests", "data_examples", "omib_sys.json")
sys = System(sys_file; sys_kwargs...)
return sys
end

function build_psid_3bus(; kwargs...)
sys_kwargs = filter_kwargs(; kwargs...)
sys_file = joinpath(DATA_DIR, "psid_tests", "data_examples", "threebus_sys.json")
sys = System(sys_file; sys_kwargs...)
return sys
end

function build_wecc_240_dynamic(; kwargs...)
sys_kwargs = filter_kwargs(; kwargs...)
sys_file = joinpath(DATA_DIR, "psid_tests", "data_tests", "WECC_240_dynamic.json")
sys = System(sys_file; sys_kwargs...)
return sys
end
2 changes: 1 addition & 1 deletion src/library/psidtest_library.jl
Original file line number Diff line number Diff line change
Expand Up @@ -788,7 +788,7 @@ function build_psid_test_threebus_multimachine_dynlines(; kwargs...)
add_component!(sys, dyn_line)
end

for l in get_components(PSY.StandardLoad, threebus_sys)
for l in get_components(PSY.StandardLoad, sys)
transform_load_to_constant_impedance(l)
end

Expand Down
20 changes: 19 additions & 1 deletion src/system_descriptor_data.jl
Original file line number Diff line number Diff line change
Expand Up @@ -1105,9 +1105,27 @@ const SYSTEM_CATALOG = [
),
SystemDescriptor(;
name = "2Area 5 Bus System",
description = "PSI test system with two areas connected with an HVDC Line", # Old Test 38
description = "PSI test system with two areas connected with an HVDC Line",
category = PSISystems,
raw_data = joinpath(DATA_DIR, "psy_data", "data_5bus_pu.jl"),
build_function = build_two_zone_5_bus,
),
SystemDescriptor(;
name = "OMIB System",
description = "OMIB case with 2 state machine for examples",
category = PSIDSystems,
build_function = build_psid_omib,
),
SystemDescriptor(;
name = "Three Bus Dynamic data Example System",
description = "Three Bus case for examples",
category = PSIDSystems,
build_function = build_psid_3bus,
),
SystemDescriptor(;
name = "WECC 240 Bus",
description = "WECC 240 Bus case dynamic data with some modifications",
category = PSIDSystems,
build_function = build_psid_3bus,
),
jd-lara marked this conversation as resolved.
Show resolved Hide resolved
]
Loading