TulipaEnergy/NearOptimalAlternatives.jl

Make the names more understandable

开放

#22 创建于 2024年6月4日

 (2 条评论) (0 个反应) (0 位负责人)Julia (4 个派生)auto 404
enhancementgood first issue

仓库指标

星标
 (2 个星标)
PR 合并指标
 (平均合并 8天 2小时) (30 天内合并 2 个 PR)

描述

Here are some (minor) suggestions that will improve the readability of the code while going through the repo.

https://github.com/TulipaEnergy/NearOptimalAlternatives.jl/blob/main/src/alternative-optimisation.jl:

  • l 23-25: maybe call them initial_objective* (or original*)
  • l 34: solution -> initial_solution
  • l 40: quite confusing to call a constraint original_objective, so original_objective -> optimality_gap_constraint
  • l 68: better to explain a bit more, e.g., by adding something like so the sum of the distance between the new solution and each of the previous solutions is maximized to the comment
  • l 69: solution -> previous_solution

https://github.com/TulipaEnergy/NearOptimalAlternatives.jl/blob/main/src/results.jl:

  • l 31: shouldn't it be push!(results.objective_values, objective_value(model))? What do we want to store here?

https://github.com/TulipaEnergy/NearOptimalAlternatives.jl/blob/2-mga-metaheuristics/src/generate-alternatives.jl:

  • l108: more explicit name?

贡献者指南