AI4OPT / AI4OPT/PGLearn.jl

Remove `formulation` key from metadata

未關閉
#178 4 則留言 0 個 reaction 已指派 0 人 在 GitHub 檢視
主要語言
Julia
星號
7
分支
5
PR 合併指標
30 天內沒有已合併 PR

描述

...or implement `JuMP.copy_extension_data`, since

```julia
opf = OPFGenerator.build_opf(...)
copy_model(opf.model)
```
gives
```julia
┌ Warning: Model contains extension data of type DataType that we do not know how to copy.

│ If you are using a JuMP extension and you did not add data to the `model.ext` dictionary. Please open an issue on the GitHub repository of the JuMP extension and tell them to implement `JuMP.copy_extension_data`.

│ If you added things to `model.ext`, they have not been copied.
└ @ JuMP ~/.julia/packages/JuMP/xlp0s/src/copy.jl:23
```

The `formulation` key in the metadata is [the only place](https://github.com/AI4OPT/OPFGenerator/blob/bf0f0368fa951c62b715f1e9de912db71fe2505e/src/opf/utils.jl#L89) we access `model.ext[:opf_model]`, and removing it would also save some space in the final files.

貢獻指南

這個儲存庫沒有索引到貢獻指南

評估

這個 Issue 還沒有評估資料。

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。