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
I could use type numpy.ndarray or pandas.DataFrame for state variable from #12.
Unfortunately, the patch of #12 was canceled by ed97524.
There seems to be a little confusion.
To start annealing, I think only two things are required in __init__().
First, either initial_state or load_state is given.
Second, the given object is copyable. The definition of "copyable" can be custmized by overriding copy_state().
Therefore, all we have to do in __init__() is to check whether initial_state is given or not.
Other conditions about state can be handled by move() and energey(), so it doesn't matter if initial_state itself is evaluated as false like an empty list.
The text was updated successfully, but these errors were encountered:
I could use type numpy.ndarray or pandas.DataFrame for state variable from #12.
Unfortunately, the patch of #12 was canceled by ed97524.
There seems to be a little confusion.
I have a suggestion about this code.
To start annealing, I think only two things are required in
__init__()
.First, either
initial_state
orload_state
is given.Second, the given object is copyable. The definition of "copyable" can be custmized by overriding
copy_state()
.Therefore, all we have to do in
__init__()
is to check whetherinitial_state
is given or not.Other conditions about state can be handled by
move()
andenergey()
, so it doesn't matter ifinitial_state
itself is evaluated as false like an empty list.The text was updated successfully, but these errors were encountered: