You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If this is a question, something isn't working or an idea please start a Q&A discussion in the Discussion tab
Open a bug report only if you can provide the details below
Describe the bug
A clear and concise description of what the bug is.
I have a problem with PSY TransmissionInterface, the get_direction_mapping would return a Dict(String,Int64)
PSY.get_direction_mapping
get_direction_mapping(
value::TransmissionInterface
) -> Dict{String, Int64}
But in PSI, when we try to _add_to_jump_expression!, the multiplier has to be a Float64 (which is direction here) so it always return an error. To Reproduce
Steps to reproduce the behavior:
Paste the code we can run to reproduce the error you are seeing
Expected behavior
A clear and concise description of what you expected to happen.
Screenshots
If applicable, add screenshots to help explain your problem.
If this is a question, something isn't working or an idea please start a Q&A discussion in the Discussion tab
Open a bug report only if you can provide the details below
Describe the bug
A clear and concise description of what the bug is.
I have a problem with PSY TransmissionInterface, the get_direction_mapping would return a Dict(String,Int64)
PSY.get_direction_mapping
get_direction_mapping(
value::TransmissionInterface
) -> Dict{String, Int64}
But in PSI, when we try to _add_to_jump_expression!, the multiplier has to be a Float64 (which is direction here) so it always return an error.
To Reproduce
Steps to reproduce the behavior:
Paste the code we can run to reproduce the error you are seeing
Expected behavior
A clear and concise description of what you expected to happen.
Screenshots
If applicable, add screenshots to help explain your problem.
Additional context
Add any other context about the problem here.
┌ Error: Simulation build failed
│ exception =
│ MethodError: no method matching _add_to_jump_expression!(::AffExpr, ::VariableRef, ::Int64)
│
│ Closest candidates are:
│ _add_to_jump_expression!(::T, ::VariableRef, ::Float64, ::Float64) where T<:AbstractJuMPScalar
│ @ PowerSimulations ~/.julia/packages/PowerSimulations/2yc8E/src/devices_models/devices/common/add_to_expression.jl:110
│ _add_to_jump_expression!(::T, ::VariableRef, ::Float64) where T<:AbstractJuMPScalar
│ @ PowerSimulations ~/.julia/packages/PowerSimulations/2yc8E/src/devices_models/devices/common/add_to_expression.jl:93
│ _add_to_jump_expression!(::T, ::Float64, ::Float64) where T<:AbstractJuMPScalar
│ @ PowerSimulations ~/.julia/packages/PowerSimulations/2yc8E/src/devices_models/devices/common/add_to_expression.jl:121
│ ...
│
│ Stacktrace:
│ [1] add_to_expression!(container::PowerSimulations.OptimizationContainer, ::Type{PowerSimulations.InterfaceTotalFlow}, ::Type{FlowActivePowerVariable}, service::TransmissionInterface, model::ServiceModel{TransmissionInterface, ConstantMaxInterfaceFlow})
│ @ PowerSimulations ~/.julia/packages/PowerSimulations/2yc8E/src/devices_models/devices/common/add_to_expression.jl:1301
│ [2] construct_service!(container::PowerSimulations.OptimizationContainer, sys::System, ::InfrastructureSystems.Optimization.ModelConstructStage, model::ServiceModel{TransmissionInterface, ConstantMaxInterfaceFlow}, devices_template::Dict{Symbol, DeviceModel}, incompatible_device_types::Set{DataType}, network_model::NetworkModel{PTDFPowerModel})
│ @ PowerSimulations ~/.julia/packages/PowerSimulations/2yc8E/src/services_models/services_constructor.jl:569
│ [3] construct_services!(container::PowerSimulations.OptimizationContainer, sys::System, stage::InfrastructureSystems.Optimization.ModelConstructStage, services_template::Dict{Tuple{String, Symbol}, ServiceModel}, devices_template::Dict{Symbol, DeviceModel}, network_model::NetworkModel{PTDFPowerModel})
│ @ PowerSimulations ~/.julia/packages/PowerSimulations/2yc8E/src/services_models/services_constructor.jl:74
│ [4] macro expansion
│ @ ~/.julia/packages/PowerSimulations/2yc8E/src/core/optimization_container.jl:739 [inlined]
The text was updated successfully, but these errors were encountered: