Last change
on this file since 1325 was
1185,
checked in by Maciej Komosinski, 2 years ago
|
Renamed a module; new name is "evolalg_steps"
|
File size:
350 bytes
|
Line | |
---|
1 | import copy |
---|
2 | |
---|
3 | from evolalg_steps.repair.repair import Repair |
---|
4 | |
---|
5 | |
---|
6 | class ConstRepair(Repair): |
---|
7 | def __init__(self, value, excepted_size, *args, **kwargs): |
---|
8 | super(ConstRepair, self).__init__(excepted_size, *args, **kwargs) |
---|
9 | self.value = value |
---|
10 | |
---|
11 | def generate_new(self, population, missing_count): |
---|
12 | return copy.deepcopy(self.value) |
---|
Note: See
TracBrowser
for help on using the repository browser.