From ecc38ec453e677ebba6b2e8586e5667f42981068 Mon Sep 17 00:00:00 2001 From: pi <73870161+binh120702@users.noreply.github.com> Date: Mon, 25 Nov 2024 05:50:14 +0700 Subject: [PATCH] Update ox.py (#646) - Fix typo in None check --- pymoo/operators/crossover/ox.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pymoo/operators/crossover/ox.py b/pymoo/operators/crossover/ox.py index c1716683f..f326467a5 100644 --- a/pymoo/operators/crossover/ox.py +++ b/pymoo/operators/crossover/ox.py @@ -36,7 +36,7 @@ def ox(receiver, donor, seq=None, shift=False): assert len(donor) == len(receiver) # the sequence which shall be use for the crossover - seq = seq if not None else random_sequence(len(receiver)) + seq = seq if seq is not None else random_sequence(len(receiver)) start, end = seq # the donation and a set of it to allow a quick lookup