Skip to content
Closed
Show file tree
Hide file tree
Changes from all 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
3 changes: 2 additions & 1 deletion Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ uuid = "2fff4b78-0b6c-428d-bac8-85ccea8c4bdf"
version = "0.4.0"

[deps]
DelimitedFiles = "8bb1440f-4735-579b-a4ab-409b98df4dab"
ExaModels = "1037b233-b668-4ce9-9b63-f9f681f55dd2"
ExaPowerIO = "14903efe-9500-4d7f-a589-7ab7e15da6de"
JSON = "682c06a0-de6a-54ab-a142-c8b1cf79cde6"
PowerIO = "05ed8b54-f668-4096-9d0d-e8c3dd9dc169"

[weakdeps]
ExaModelsCompiler = "3d1e9a26-5b74-4f0c-9a2b-7c8f4e11d3a7"
Expand All @@ -18,6 +18,7 @@ ExaModelsPowerExaModelsCompilerExt = "ExaModelsCompiler"
ExaModels = "0.11"
ExaPowerIO = "0.3"
JSON = "0.21"
PowerIO = "0.9"
julia = "1.11"

[sources]
Expand Down
9 changes: 4 additions & 5 deletions src/ExaModelsPower.jl
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
module ExaModelsPower

import ExaModels: ExaModels, ExaCore, @add_var, @add_par, @add_con, @add_obj, @add_con!, ExaModel, convert_array, solution
using DelimitedFiles
using ExaPowerIO
using ExaPowerIO # the bundled PGLib-OPF directory, and nothing else
using JSON
using PowerIO

# Parsers and data stay separate from the models that consume them.
include("parser.jl") # matpower -> the tables every model is built from
include("parser.jl") # case file -> the tables every model is built from
include("constraint.jl") # the algebraic expressions, shared by all three
include("goc3_parser.jl") # GOC3-specific parsing
include("sc_parser.jl") # "
include("sc_parser.jl") # GOC3-specific parsing

include("opf.jl") # static: polar, rect, DC
include("mpopf.jl") # multi-period: polar, rect, DC
Expand Down
7 changes: 3 additions & 4 deletions src/goc3.jl
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,11 @@ function goc3_model(


uc_data = JSON.parsefile(uc_filename)
data = get_data_from_file(filename)
data_json = JSON.parsefile(filename)
sc_data, lengths, producers_first = parse_sc_data(data, uc_data, data_json)
data = PowerIO.parse_goc3_json(filename)
sc_data, lengths, producers_first = parse_sc_data(data, uc_data)
@info "parsed data"

(L_J_xf, L_J_ln, L_J_ac, L_J_dc, L_J_br, L_J_cs,
(; L_J_xf, L_J_ln, L_J_ac, L_J_dc, L_J_br, L_J_cs,
L_J_pr, L_J_cspr, L_J_sh, I, L_T, L_N_p, L_N_q, L_W_en_min_pr,
L_W_en_min_cs, L_W_en_max_pr, L_W_en_max_cs, K) = lengths

Expand Down
105 changes: 0 additions & 105 deletions src/goc3_parser.jl

This file was deleted.

Loading