bq-nco
bq-nco copied to clipboard
Bug: Missing Integer Conversion when preparing kp dataset
Hello! I am trying to use BQ-NCO to solve my own combinatorial optimization problem. It's quite an excellent work! However, when I tried to use the code to generate a kp dataset, I found a small bug in prepare_kp_dataset.py
. The details are shown as follows:
Issue Description:
While parsing parameters in line 47
, there is a small bug where the variable capacity
is not properly converted to an integer type, potentially causing issues.
Proposed Solution:
I suggest explicitly performing integer conversion in the relevant part of the parameter parsing. Change Line 38
to: capacity = int(args.capacity * args.scale)
will fix it. I have tested this modification locally, and it resolves the issue without introducing any apparent side effects.