It would be quite practical to have the option to maintain an "additional information" list where, for example, the user could store the respective solutions.
nda = moarchiving.BiobjectiveNondominatedSortedList()
nda.add(fun2(x), info=x)
nda.add(fun2(xa), info={'x': xa, 'note': 'xa seems to rock'})
nda.add(fun2(xb))
assert nda.info is None or len(nda) == len(nda.info)
print(nda.info) # nda has an info property
[[0, 1, 2], {'x': [1, 2, 3], 'note': 'xa seems to rock'}, None]
Methods that need to be modified are
The list can be created only when an optional info argument is used for the first time to avoid always maintaining an info list of None elements.
It would be quite practical to have the option to maintain an "additional information" list where, for example, the user could store the respective solutions.
Methods that need to be modified are
addand_add_atremoveThe list can be created only when an optional
infoargument is used for the first time to avoid always maintaining an infolistofNoneelements.