diff --git a/README.md b/README.md index ab231b51..c43de908 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ A paper introducing jMetalPy is available at: https://doi.org/10.1016/j.swevo.20 You can install the latest version of jMetalPy with `pip`, ```console -pip install jmetalpy +pip install jmetalpy # or "jmetalpy[distributed]" ```
Notes on installing with pip @@ -27,13 +27,13 @@ pip install jmetalpy jMetalPy includes features for parallel and distributed computing based on [pySpark](https://spark.apache.org/docs/latest/api/python/index.html) and [Dask](https://dask.org/). -These (extra) dependencies are automatically installed when running `pip`: +These (extra) dependencies are *not* automatically installed when running `pip`, which only comprises the core functionality of the framework (enough for most users): ```console pip install jmetalpy ``` -But you can also install the core functionality of the framework (which is often enough for most users): +This is the equivalent of running: ```console pip install "jmetalpy[core]" diff --git a/docs/_modules/index.html b/docs/_modules/index.html index 922a8940..97c8bd93 100644 --- a/docs/_modules/index.html +++ b/docs/_modules/index.html @@ -24,7 +24,6 @@ - @@ -73,8 +72,6 @@

Table Of Contents

  • Single-objective algorithms
  • Operators
  • Problems
  • -
  • Contributing
  • -
  • About
  • @@ -115,7 +112,6 @@

    All modules for which code is available

  • jmetal.algorithm.multiobjective.mocell
  • jmetal.algorithm.multiobjective.moead
  • jmetal.algorithm.multiobjective.nsgaii
  • -
  • jmetal.algorithm.multiobjective.nsgaiii
  • jmetal.algorithm.multiobjective.omopso
  • jmetal.algorithm.multiobjective.smpso
  • jmetal.algorithm.multiobjective.spea2
  • @@ -125,8 +121,10 @@

    All modules for which code is available

  • jmetal.algorithm.singleobjective.simulated_annealing
  • jmetal.core.observer
  • jmetal.core.problem
  • +
  • jmetal.lab.experiment
  • jmetal.lab.statistical_test.apv_procedures
  • jmetal.lab.statistical_test.bayesian
  • +
  • jmetal.lab.statistical_test.critical_distance
  • jmetal.lab.statistical_test.functions
  • jmetal.lab.visualization.chord_plot
  • jmetal.lab.visualization.interactive
  • diff --git a/docs/_modules/jmetal/algorithm/multiobjective/gde3.html b/docs/_modules/jmetal/algorithm/multiobjective/gde3.html index 5e6fbd7f..c7718d38 100644 --- a/docs/_modules/jmetal/algorithm/multiobjective/gde3.html +++ b/docs/_modules/jmetal/algorithm/multiobjective/gde3.html @@ -24,7 +24,6 @@ - @@ -74,8 +73,6 @@

    Table Of Contents

  • Single-objective algorithms
  • Operators
  • Problems
  • -
  • Contributing
  • -
  • About
  • @@ -112,18 +109,18 @@

    Table Of Contents

    Source code for jmetal.algorithm.multiobjective.gde3

    -from typing import TypeVar, List
    -
    -from jmetal.config import store
    -from jmetal.core.algorithm import EvolutionaryAlgorithm, DynamicAlgorithm
    -from jmetal.core.problem import Problem, DynamicProblem
    -from jmetal.core.solution import FloatSolution
    -from jmetal.operator import DifferentialEvolutionCrossover, RankingAndCrowdingDistanceSelection
    -from jmetal.operator.selection import DifferentialEvolutionSelection
    -from jmetal.util.comparator import Comparator, DominanceComparator
    -from jmetal.util.evaluator import Evaluator
    -from jmetal.util.generator import Generator
    -from jmetal.util.termination_criterion import TerminationCriterion
    +from typing import TypeVar, List
    +
    +from jmetal.config import store
    +from jmetal.core.algorithm import EvolutionaryAlgorithm, DynamicAlgorithm
    +from jmetal.core.problem import Problem, DynamicProblem
    +from jmetal.core.solution import FloatSolution
    +from jmetal.operator import DifferentialEvolutionCrossover, RankingAndCrowdingDistanceSelection
    +from jmetal.operator.selection import DifferentialEvolutionSelection
    +from jmetal.util.comparator import Comparator, DominanceComparator
    +from jmetal.util.evaluator import Evaluator
    +from jmetal.util.generator import Generator
    +from jmetal.util.termination_criterion import TerminationCriterion
     
     S = TypeVar('S')
     R = List[S]
    @@ -131,7 +128,7 @@ 

    Source code for jmetal.algorithm.multiobjective.gde3

    [docs]class GDE3(EvolutionaryAlgorithm[FloatSolution, FloatSolution]): - def __init__(self, + def __init__(self, problem: Problem, population_size: int, cr: float, @@ -215,7 +212,7 @@

    Source code for jmetal.algorithm.multiobjective.gde3

    [docs]class DynamicGDE3(GDE3, DynamicAlgorithm): - def __init__(self, + def __init__(self, problem: DynamicProblem, population_size: int, cr: float, diff --git a/docs/_modules/jmetal/algorithm/multiobjective/hype.html b/docs/_modules/jmetal/algorithm/multiobjective/hype.html index 69cc2ff6..32d9c76d 100644 --- a/docs/_modules/jmetal/algorithm/multiobjective/hype.html +++ b/docs/_modules/jmetal/algorithm/multiobjective/hype.html @@ -24,7 +24,6 @@ - @@ -74,8 +73,6 @@

    Table Of Contents

  • Single-objective algorithms
  • Operators
  • Problems
  • -
  • Contributing
  • -
  • About
  • @@ -112,20 +109,20 @@

    Table Of Contents

    Source code for jmetal.algorithm.multiobjective.hype

    -from typing import TypeVar, List
    -
    -from jmetal.algorithm.singleobjective.genetic_algorithm import GeneticAlgorithm
    -from jmetal.config import store
    -from jmetal.core.operator import Mutation, Crossover
    -from jmetal.core.problem import Problem
    -from jmetal.core.solution import Solution
    -from jmetal.operator import BinaryTournamentSelection
    -from jmetal.operator.selection import RankingAndFitnessSelection
    -from jmetal.util.comparator import Comparator
    -from jmetal.util.comparator import SolutionAttributeComparator
    -from jmetal.util.evaluator import Evaluator
    -from jmetal.util.generator import Generator
    -from jmetal.util.termination_criterion import TerminationCriterion
    +from typing import TypeVar, List
    +
    +from jmetal.algorithm.singleobjective.genetic_algorithm import GeneticAlgorithm
    +from jmetal.config import store
    +from jmetal.core.operator import Mutation, Crossover
    +from jmetal.core.problem import Problem
    +from jmetal.core.solution import Solution
    +from jmetal.operator import BinaryTournamentSelection
    +from jmetal.operator.selection import RankingAndFitnessSelection
    +from jmetal.util.comparator import Comparator
    +from jmetal.util.comparator import SolutionAttributeComparator
    +from jmetal.util.evaluator import Evaluator
    +from jmetal.util.generator import Generator
    +from jmetal.util.termination_criterion import TerminationCriterion
     
     S = TypeVar('S')
     R = TypeVar('R')
    @@ -133,7 +130,7 @@ 

    Source code for jmetal.algorithm.multiobjective.hype

    [docs]class HYPE(GeneticAlgorithm[S, R]): - def __init__(self, + def __init__(self, problem: Problem, reference_point: Solution, population_size: int, diff --git a/docs/_modules/jmetal/algorithm/multiobjective/ibea.html b/docs/_modules/jmetal/algorithm/multiobjective/ibea.html index 4f2de820..2abadca6 100644 --- a/docs/_modules/jmetal/algorithm/multiobjective/ibea.html +++ b/docs/_modules/jmetal/algorithm/multiobjective/ibea.html @@ -24,7 +24,6 @@ - @@ -74,8 +73,6 @@

    Table Of Contents

  • Single-objective algorithms
  • Operators
  • Problems
  • -
  • Contributing
  • -
  • About
  • @@ -112,20 +109,20 @@

    Table Of Contents

    Source code for jmetal.algorithm.multiobjective.ibea

    -from typing import TypeVar, List
    +from typing import TypeVar, List
     
     import numpy as np
     
    -from jmetal.algorithm.singleobjective.genetic_algorithm import GeneticAlgorithm
    -from jmetal.config import store
    -from jmetal.core.operator import Mutation, Crossover
    -from jmetal.core.problem import Problem
    -from jmetal.core.quality_indicator import EpsilonIndicator
    -from jmetal.operator import BinaryTournamentSelection
    -from jmetal.util.comparator import SolutionAttributeComparator
    -from jmetal.util.evaluator import Evaluator
    -from jmetal.util.generator import Generator
    -from jmetal.util.termination_criterion import TerminationCriterion
    +from jmetal.algorithm.singleobjective.genetic_algorithm import GeneticAlgorithm
    +from jmetal.config import store
    +from jmetal.core.operator import Mutation, Crossover
    +from jmetal.core.problem import Problem
    +from jmetal.core.quality_indicator import EpsilonIndicator
    +from jmetal.operator import BinaryTournamentSelection
    +from jmetal.util.comparator import SolutionAttributeComparator
    +from jmetal.util.evaluator import Evaluator
    +from jmetal.util.generator import Generator
    +from jmetal.util.termination_criterion import TerminationCriterion
     
     S = TypeVar('S')
     R = TypeVar('R')
    @@ -133,7 +130,7 @@ 

    Source code for jmetal.algorithm.multiobjective.ibea

    [docs]class IBEA(GeneticAlgorithm[S, R]): - def __init__(self, + def __init__(self, problem: Problem, population_size: int, offspring_population_size: int, diff --git a/docs/_modules/jmetal/algorithm/multiobjective/mocell.html b/docs/_modules/jmetal/algorithm/multiobjective/mocell.html index 9036703a..7f77fea6 100644 --- a/docs/_modules/jmetal/algorithm/multiobjective/mocell.html +++ b/docs/_modules/jmetal/algorithm/multiobjective/mocell.html @@ -24,7 +24,6 @@ - @@ -74,8 +73,6 @@

    Table Of Contents

  • Single-objective algorithms
  • Operators
  • Problems
  • -
  • Contributing
  • -
  • About
  • @@ -113,22 +110,22 @@

    Table Of Contents

    Source code for jmetal.algorithm.multiobjective.mocell

     import copy
    -from functools import cmp_to_key
    -from typing import TypeVar, List
    -
    -from jmetal.algorithm.singleobjective.genetic_algorithm import GeneticAlgorithm
    -from jmetal.config import store
    -from jmetal.core.operator import Mutation, Crossover, Selection
    -from jmetal.core.problem import Problem
    -from jmetal.operator import BinaryTournamentSelection
    -from jmetal.util.archive import BoundedArchive
    -from jmetal.util.density_estimator import CrowdingDistance, DensityEstimator
    -from jmetal.util.evaluator import Evaluator
    -from jmetal.util.generator import Generator
    -from jmetal.util.neighborhood import Neighborhood
    -from jmetal.util.ranking import FastNonDominatedRanking, Ranking
    -from jmetal.util.comparator import Comparator, MultiComparator
    -from jmetal.util.termination_criterion import TerminationCriterion
    +from functools import cmp_to_key
    +from typing import TypeVar, List
    +
    +from jmetal.algorithm.singleobjective.genetic_algorithm import GeneticAlgorithm
    +from jmetal.config import store
    +from jmetal.core.operator import Mutation, Crossover, Selection
    +from jmetal.core.problem import Problem
    +from jmetal.operator import BinaryTournamentSelection
    +from jmetal.util.archive import BoundedArchive
    +from jmetal.util.density_estimator import CrowdingDistance, DensityEstimator
    +from jmetal.util.evaluator import Evaluator
    +from jmetal.util.generator import Generator
    +from jmetal.util.neighborhood import Neighborhood
    +from jmetal.util.ranking import FastNonDominatedRanking, Ranking
    +from jmetal.util.comparator import Comparator, MultiComparator
    +from jmetal.util.termination_criterion import TerminationCriterion
     
     S = TypeVar('S')
     R = TypeVar('R')
    @@ -143,7 +140,7 @@ 

    Source code for jmetal.algorithm.multiobjective.mocell

    [docs]class MOCell(GeneticAlgorithm[S, R]): - def __init__(self, + def __init__(self, problem: Problem, population_size: int, neighborhood: Neighborhood, diff --git a/docs/_modules/jmetal/algorithm/multiobjective/moead.html b/docs/_modules/jmetal/algorithm/multiobjective/moead.html index ccbc42ad..8b4239f0 100644 --- a/docs/_modules/jmetal/algorithm/multiobjective/moead.html +++ b/docs/_modules/jmetal/algorithm/multiobjective/moead.html @@ -24,7 +24,6 @@ - @@ -74,8 +73,6 @@

    Table Of Contents

  • Single-objective algorithms
  • Operators
  • Problems
  • -
  • Contributing
  • -
  • About
  • @@ -114,24 +111,24 @@

    Table Of Contents

    Source code for jmetal.algorithm.multiobjective.moead

     import copy
     import random
    -from math import ceil
    -from typing import TypeVar, List, Generator
    +from math import ceil
    +from typing import TypeVar, List, Generator
     
     import numpy as np
     
    -from jmetal.algorithm.singleobjective.genetic_algorithm import GeneticAlgorithm
    -from jmetal.config import store
    -from jmetal.core.operator import Mutation
    -from jmetal.core.problem import Problem
    -from jmetal.operator import DifferentialEvolutionCrossover, NaryRandomSolutionSelection
    -from jmetal.util.aggregative_function import AggregativeFunction
    -from jmetal.util.constraint_handling import feasibility_ratio, \
    +from jmetal.algorithm.singleobjective.genetic_algorithm import GeneticAlgorithm
    +from jmetal.config import store
    +from jmetal.core.operator import Mutation
    +from jmetal.core.problem import Problem
    +from jmetal.operator import DifferentialEvolutionCrossover, NaryRandomSolutionSelection
    +from jmetal.util.aggregative_function import AggregativeFunction
    +from jmetal.util.constraint_handling import feasibility_ratio, \
         overall_constraint_violation_degree, is_feasible
    -from jmetal.util.density_estimator import CrowdingDistance
    -from jmetal.util.evaluator import Evaluator
    -from jmetal.util.neighborhood import WeightVectorNeighborhood
    -from jmetal.util.ranking import FastNonDominatedRanking
    -from jmetal.util.termination_criterion import TerminationCriterion, StoppingByEvaluations
    +from jmetal.util.density_estimator import CrowdingDistance
    +from jmetal.util.evaluator import Evaluator
    +from jmetal.util.neighborhood import WeightVectorNeighborhood
    +from jmetal.util.ranking import FastNonDominatedRanking
    +from jmetal.util.termination_criterion import TerminationCriterion, StoppingByEvaluations
     
     S = TypeVar('S')
     R = List[S]
    @@ -139,7 +136,7 @@ 

    Source code for jmetal.algorithm.multiobjective.moead

    [docs]class MOEAD(GeneticAlgorithm): - def __init__(self, + def __init__(self, problem: Problem, population_size: int, mutation: Mutation, @@ -268,7 +265,7 @@

    Source code for jmetal.algorithm.multiobjective.moead

    class MOEAD_DRA(MOEAD): - def __init__(self, problem, population_size, mutation, crossover, aggregative_function, + def __init__(self, problem, population_size, mutation, crossover, aggregative_function, neighbourhood_selection_probability, max_number_of_replaced_solutions, neighbor_size, weight_files_path, termination_criterion=store.default_termination_criteria, population_generator=store.default_generator, population_evaluator=store.default_evaluator): @@ -365,7 +362,7 @@

    Source code for jmetal.algorithm.multiobjective.moead

    class MOEADIEpsilon(MOEAD): - def __init__(self, + def __init__(self, problem: Problem, population_size: int, mutation: Mutation, @@ -506,7 +503,7 @@

    Source code for jmetal.algorithm.multiobjective.moead

    class Permutation: - def __init__(self, length: int): + def __init__(self, length: int): self.counter = 0 self.length = length self.permutation = np.random.permutation(length) diff --git a/docs/_modules/jmetal/algorithm/multiobjective/nsgaii.html b/docs/_modules/jmetal/algorithm/multiobjective/nsgaii.html index b1e46e68..7b3e7647 100644 --- a/docs/_modules/jmetal/algorithm/multiobjective/nsgaii.html +++ b/docs/_modules/jmetal/algorithm/multiobjective/nsgaii.html @@ -24,7 +24,6 @@ - @@ -74,8 +73,6 @@

    Table Of Contents

  • Single-objective algorithms
  • Operators
  • Problems
  • -
  • Contributing
  • -
  • About
  • @@ -113,26 +110,26 @@

    Table Of Contents

    Source code for jmetal.algorithm.multiobjective.nsgaii

     import time
    -from typing import TypeVar, List, Generator
    +from typing import TypeVar, List, Generator
     
     try:
         import dask
    -    from distributed import as_completed, Client
    +    from distributed import as_completed, Client
     except ImportError:
         pass
     
    -from jmetal.algorithm.singleobjective.genetic_algorithm import GeneticAlgorithm
    -from jmetal.config import store
    -from jmetal.core.algorithm import DynamicAlgorithm, Algorithm
    -from jmetal.core.operator import Mutation, Crossover, Selection
    -from jmetal.core.problem import Problem, DynamicProblem
    -from jmetal.operator import BinaryTournamentSelection
    -from jmetal.util.density_estimator import CrowdingDistance
    -from jmetal.util.evaluator import Evaluator
    -from jmetal.util.ranking import FastNonDominatedRanking
    -from jmetal.util.replacement import RankingAndDensityEstimatorReplacement, RemovalPolicyType
    -from jmetal.util.comparator import DominanceComparator, Comparator, MultiComparator
    -from jmetal.util.termination_criterion import TerminationCriterion
    +from jmetal.algorithm.singleobjective.genetic_algorithm import GeneticAlgorithm
    +from jmetal.config import store
    +from jmetal.core.algorithm import DynamicAlgorithm, Algorithm
    +from jmetal.core.operator import Mutation, Crossover, Selection
    +from jmetal.core.problem import Problem, DynamicProblem
    +from jmetal.operator import BinaryTournamentSelection
    +from jmetal.util.density_estimator import CrowdingDistance
    +from jmetal.util.evaluator import Evaluator
    +from jmetal.util.ranking import FastNonDominatedRanking
    +from jmetal.util.replacement import RankingAndDensityEstimatorReplacement, RemovalPolicyType
    +from jmetal.util.comparator import DominanceComparator, Comparator, MultiComparator
    +from jmetal.util.termination_criterion import TerminationCriterion
     
     S = TypeVar('S')
     R = TypeVar('R')
    @@ -148,7 +145,7 @@ 

    Source code for jmetal.algorithm.multiobjective.nsgaii

    [docs]class NSGAII(GeneticAlgorithm[S, R]): - def __init__(self, + def __init__(self, problem: Problem, population_size: int, offspring_population_size: int, @@ -218,7 +215,7 @@

    Source code for jmetal.algorithm.multiobjective.nsgaii

    [docs]class DynamicNSGAII(NSGAII[S, R], DynamicAlgorithm): - def __init__(self, + def __init__(self, problem: DynamicProblem[S], population_size: int, offspring_population_size: int, @@ -273,7 +270,7 @@

    Source code for jmetal.algorithm.multiobjective.nsgaii

    [docs]class DistributedNSGAII(Algorithm[S, R]): - def __init__(self, + def __init__(self, problem: Problem, population_size: int, mutation: Mutation, diff --git a/docs/_modules/jmetal/algorithm/multiobjective/omopso.html b/docs/_modules/jmetal/algorithm/multiobjective/omopso.html index 0dab4e7b..3072244d 100644 --- a/docs/_modules/jmetal/algorithm/multiobjective/omopso.html +++ b/docs/_modules/jmetal/algorithm/multiobjective/omopso.html @@ -24,7 +24,6 @@ - @@ -74,8 +73,6 @@

    Table Of Contents

  • Single-objective algorithms
  • Operators
  • Problems
  • -
  • Contributing
  • -
  • About
  • @@ -113,23 +110,23 @@

    Table Of Contents

    Source code for jmetal.algorithm.multiobjective.omopso

     import random
    -from copy import copy
    -from math import sqrt
    -from typing import TypeVar, List, Optional
    +from copy import copy
    +from math import sqrt
    +from typing import TypeVar, List, Optional
     
     import numpy
     
    -from jmetal.config import store
    -from jmetal.core.algorithm import ParticleSwarmOptimization
    -from jmetal.core.problem import FloatProblem
    -from jmetal.core.solution import FloatSolution
    -from jmetal.operator import UniformMutation
    -from jmetal.operator.mutation import NonUniformMutation
    -from jmetal.util.archive import BoundedArchive, NonDominatedSolutionsArchive
    -from jmetal.util.comparator import DominanceComparator, EpsilonDominanceComparator
    -from jmetal.util.evaluator import Evaluator
    -from jmetal.util.generator import Generator
    -from jmetal.util.termination_criterion import TerminationCriterion
    +from jmetal.config import store
    +from jmetal.core.algorithm import ParticleSwarmOptimization
    +from jmetal.core.problem import FloatProblem
    +from jmetal.core.solution import FloatSolution
    +from jmetal.operator import UniformMutation
    +from jmetal.operator.mutation import NonUniformMutation
    +from jmetal.util.archive import BoundedArchive, NonDominatedSolutionsArchive
    +from jmetal.util.comparator import DominanceComparator, EpsilonDominanceComparator
    +from jmetal.util.evaluator import Evaluator
    +from jmetal.util.generator import Generator
    +from jmetal.util.termination_criterion import TerminationCriterion
     
     R = TypeVar('R')
     
    @@ -144,7 +141,7 @@ 

    Source code for jmetal.algorithm.multiobjective.omopso

    [docs]class OMOPSO(ParticleSwarmOptimization): - def __init__(self, + def __init__(self, problem: FloatProblem, swarm_size: int, uniform_mutation: UniformMutation, diff --git a/docs/_modules/jmetal/algorithm/multiobjective/smpso.html b/docs/_modules/jmetal/algorithm/multiobjective/smpso.html index c97e96e2..34e469af 100644 --- a/docs/_modules/jmetal/algorithm/multiobjective/smpso.html +++ b/docs/_modules/jmetal/algorithm/multiobjective/smpso.html @@ -24,7 +24,6 @@ - @@ -74,8 +73,6 @@

    Table Of Contents

  • Single-objective algorithms
  • Operators
  • Problems
  • -
  • Contributing
  • -
  • About
  • @@ -114,22 +111,22 @@

    Table Of Contents

    Source code for jmetal.algorithm.multiobjective.smpso

     import random
     import threading
    -from copy import copy
    -from math import sqrt
    -from typing import TypeVar, List, Optional
    +from copy import copy
    +from math import sqrt
    +from typing import TypeVar, List, Optional
     
     import numpy
     
    -from jmetal.config import store
    -from jmetal.core.algorithm import ParticleSwarmOptimization, DynamicAlgorithm
    -from jmetal.core.operator import Mutation
    -from jmetal.core.problem import FloatProblem, DynamicProblem
    -from jmetal.core.solution import FloatSolution
    -from jmetal.util.archive import BoundedArchive, ArchiveWithReferencePoint
    -from jmetal.util.comparator import DominanceComparator
    -from jmetal.util.evaluator import Evaluator
    -from jmetal.util.generator import Generator
    -from jmetal.util.termination_criterion import TerminationCriterion
    +from jmetal.config import store
    +from jmetal.core.algorithm import ParticleSwarmOptimization, DynamicAlgorithm
    +from jmetal.core.operator import Mutation
    +from jmetal.core.problem import FloatProblem, DynamicProblem
    +from jmetal.core.solution import FloatSolution
    +from jmetal.util.archive import BoundedArchive, ArchiveWithReferencePoint
    +from jmetal.util.comparator import DominanceComparator
    +from jmetal.util.evaluator import Evaluator
    +from jmetal.util.generator import Generator
    +from jmetal.util.termination_criterion import TerminationCriterion
     
     R = TypeVar('R')
     
    @@ -144,7 +141,7 @@ 

    Source code for jmetal.algorithm.multiobjective.smpso

    [docs]class SMPSO(ParticleSwarmOptimization): - def __init__(self, + def __init__(self, problem: FloatProblem, swarm_size: int, mutation: Mutation, @@ -334,7 +331,7 @@

    Source code for jmetal.algorithm.multiobjective.smpso

    [docs]class DynamicSMPSO(SMPSO, DynamicAlgorithm): - def __init__(self, + def __init__(self, problem: DynamicProblem[FloatSolution], swarm_size: int, mutation: Mutation, @@ -388,7 +385,7 @@

    Source code for jmetal.algorithm.multiobjective.smpso

    [docs]class SMPSORP(SMPSO): - def __init__(self, + def __init__(self, problem: FloatProblem, swarm_size: int, mutation: Mutation, @@ -505,7 +502,7 @@

    Source code for jmetal.algorithm.multiobjective.smpso

    number_of_objectives = algorithm.problem.number_of_objectives while True: - print(f'Enter {number_of_reference_points}-points of dimension {number_of_objectives}: ') + print(f'Enter {number_of_reference_points}-points of dimension {number_of_objectives}: ') read = [float(x) for x in input().split()] # Update reference points diff --git a/docs/_modules/jmetal/algorithm/multiobjective/spea2.html b/docs/_modules/jmetal/algorithm/multiobjective/spea2.html index 1adcbf4b..f7257bdb 100644 --- a/docs/_modules/jmetal/algorithm/multiobjective/spea2.html +++ b/docs/_modules/jmetal/algorithm/multiobjective/spea2.html @@ -24,7 +24,6 @@ - @@ -74,8 +73,6 @@

    Table Of Contents

  • Single-objective algorithms
  • Operators
  • Problems
  • -
  • Contributing
  • -
  • About
  • @@ -112,20 +109,20 @@

    Table Of Contents

    Source code for jmetal.algorithm.multiobjective.spea2

    -from typing import TypeVar, List
    -
    -from jmetal.algorithm.singleobjective.genetic_algorithm import GeneticAlgorithm
    -from jmetal.config import store
    -from jmetal.core.operator import Mutation, Crossover
    -from jmetal.core.problem import Problem
    -from jmetal.operator import BinaryTournamentSelection
    -from jmetal.util.density_estimator import KNearestNeighborDensityEstimator
    -from jmetal.util.evaluator import Evaluator
    -from jmetal.util.generator import Generator
    -from jmetal.util.ranking import StrengthRanking
    -from jmetal.util.replacement import RankingAndDensityEstimatorReplacement, RemovalPolicyType
    -from jmetal.util.comparator import Comparator, MultiComparator
    -from jmetal.util.termination_criterion import TerminationCriterion
    +from typing import TypeVar, List
    +
    +from jmetal.algorithm.singleobjective.genetic_algorithm import GeneticAlgorithm
    +from jmetal.config import store
    +from jmetal.core.operator import Mutation, Crossover
    +from jmetal.core.problem import Problem
    +from jmetal.operator import BinaryTournamentSelection
    +from jmetal.util.density_estimator import KNearestNeighborDensityEstimator
    +from jmetal.util.evaluator import Evaluator
    +from jmetal.util.generator import Generator
    +from jmetal.util.ranking import StrengthRanking
    +from jmetal.util.replacement import RankingAndDensityEstimatorReplacement, RemovalPolicyType
    +from jmetal.util.comparator import Comparator, MultiComparator
    +from jmetal.util.termination_criterion import TerminationCriterion
     
     S = TypeVar('S')
     R = TypeVar('R')
    @@ -148,7 +145,7 @@ 

    Source code for jmetal.algorithm.multiobjective.spea2

    [docs]class SPEA2(GeneticAlgorithm[S, R]): - def __init__(self, + def __init__(self, problem: Problem, population_size: int, offspring_population_size: int, diff --git a/docs/_modules/jmetal/algorithm/singleobjective/evolution_strategy.html b/docs/_modules/jmetal/algorithm/singleobjective/evolution_strategy.html index 0b0dcf9c..a38b68fd 100644 --- a/docs/_modules/jmetal/algorithm/singleobjective/evolution_strategy.html +++ b/docs/_modules/jmetal/algorithm/singleobjective/evolution_strategy.html @@ -24,7 +24,6 @@ - @@ -74,8 +73,6 @@

    Table Of Contents

  • Single-objective algorithms
  • Operators
  • Problems
  • -
  • Contributing
  • -
  • About
  • @@ -112,15 +109,15 @@

    Table Of Contents

    Source code for jmetal.algorithm.singleobjective.evolution_strategy

    -from copy import copy
    -from typing import TypeVar, List
    +from copy import copy
    +from typing import TypeVar, List
     
    -from jmetal.core.algorithm import EvolutionaryAlgorithm
    -from jmetal.core.operator import Mutation
    -from jmetal.core.problem import Problem
    -from jmetal.util.evaluator import Evaluator, SequentialEvaluator
    -from jmetal.util.generator import Generator, RandomGenerator
    -from jmetal.util.termination_criterion import TerminationCriterion
    +from jmetal.core.algorithm import EvolutionaryAlgorithm
    +from jmetal.core.operator import Mutation
    +from jmetal.core.problem import Problem
    +from jmetal.util.evaluator import Evaluator, SequentialEvaluator
    +from jmetal.util.generator import Generator, RandomGenerator
    +from jmetal.util.termination_criterion import TerminationCriterion
     
     S = TypeVar('S')
     R = TypeVar('R')
    @@ -136,7 +133,7 @@ 

    Source code for jmetal.algorithm.singleobjective.evolution_strategy

    [docs]class EvolutionStrategy(EvolutionaryAlgorithm[S, R]): - def __init__(self, + def __init__(self, problem: Problem, mu: int, lambda_: int, diff --git a/docs/_modules/jmetal/algorithm/singleobjective/genetic_algorithm.html b/docs/_modules/jmetal/algorithm/singleobjective/genetic_algorithm.html index 2c38b0c3..7ff22c9d 100644 --- a/docs/_modules/jmetal/algorithm/singleobjective/genetic_algorithm.html +++ b/docs/_modules/jmetal/algorithm/singleobjective/genetic_algorithm.html @@ -24,7 +24,6 @@ - @@ -74,8 +73,6 @@

    Table Of Contents

  • Single-objective algorithms
  • Operators
  • Problems
  • -
  • Contributing
  • -
  • About
  • @@ -112,15 +109,15 @@

    Table Of Contents

    Source code for jmetal.algorithm.singleobjective.genetic_algorithm

    -from typing import TypeVar, List
    +from typing import TypeVar, List
     
    -from jmetal.config import store
    -from jmetal.core.algorithm import EvolutionaryAlgorithm
    -from jmetal.core.operator import Mutation, Crossover, Selection
    -from jmetal.core.problem import Problem
    -from jmetal.util.evaluator import Evaluator
    -from jmetal.util.generator import Generator
    -from jmetal.util.termination_criterion import TerminationCriterion
    +from jmetal.config import store
    +from jmetal.core.algorithm import EvolutionaryAlgorithm
    +from jmetal.core.operator import Mutation, Crossover, Selection
    +from jmetal.core.problem import Problem
    +from jmetal.util.evaluator import Evaluator
    +from jmetal.util.generator import Generator
    +from jmetal.util.termination_criterion import TerminationCriterion
     
     S = TypeVar('S')
     R = TypeVar('R')
    @@ -135,7 +132,7 @@ 

    Source code for jmetal.algorithm.singleobjective.genetic_algorithm

    [docs]class GeneticAlgorithm(EvolutionaryAlgorithm[S, R]): - def __init__(self, + def __init__(self, problem: Problem, population_size: int, offspring_population_size: int, diff --git a/docs/_modules/jmetal/algorithm/singleobjective/local_search.html b/docs/_modules/jmetal/algorithm/singleobjective/local_search.html index 44203514..76de77d3 100644 --- a/docs/_modules/jmetal/algorithm/singleobjective/local_search.html +++ b/docs/_modules/jmetal/algorithm/singleobjective/local_search.html @@ -24,7 +24,6 @@ - @@ -74,8 +73,6 @@

    Table Of Contents

  • Single-objective algorithms
  • Operators
  • Problems
  • -
  • Contributing
  • -
  • About
  • @@ -116,15 +113,15 @@

    Source code for jmetal.algorithm.singleobjective.local_search

    import random import threading import time -from typing import TypeVar, List +from typing import TypeVar, List -from jmetal.config import store -from jmetal.core.algorithm import Algorithm -from jmetal.core.operator import Mutation -from jmetal.core.problem import Problem -from jmetal.core.solution import Solution -from jmetal.util.comparator import Comparator -from jmetal.util.termination_criterion import TerminationCriterion +from jmetal.config import store +from jmetal.core.algorithm import Algorithm +from jmetal.core.operator import Mutation +from jmetal.core.problem import Problem +from jmetal.core.solution import Solution +from jmetal.util.comparator import Comparator +from jmetal.util.termination_criterion import TerminationCriterion S = TypeVar('S') R = TypeVar('R') @@ -140,7 +137,7 @@

    Source code for jmetal.algorithm.singleobjective.local_search

    [docs]class LocalSearch(Algorithm[S, R], threading.Thread): - def __init__(self, + def __init__(self, problem: Problem[S], mutation: Mutation, termination_criterion: TerminationCriterion = store.default_termination_criteria, diff --git a/docs/_modules/jmetal/algorithm/singleobjective/simulated_annealing.html b/docs/_modules/jmetal/algorithm/singleobjective/simulated_annealing.html index 6e8d2c57..6fabb7ae 100644 --- a/docs/_modules/jmetal/algorithm/singleobjective/simulated_annealing.html +++ b/docs/_modules/jmetal/algorithm/singleobjective/simulated_annealing.html @@ -24,7 +24,6 @@ - @@ -74,8 +73,6 @@

    Table Of Contents

  • Single-objective algorithms
  • Operators
  • Problems
  • -
  • Contributing
  • -
  • About
  • @@ -116,15 +113,15 @@

    Source code for jmetal.algorithm.singleobjective.simulated_annealing

    import random import threading import time -from typing import TypeVar, List +from typing import TypeVar, List import numpy -from jmetal.core.algorithm import Algorithm -from jmetal.core.operator import Mutation -from jmetal.core.problem import Problem -from jmetal.core.solution import Solution -from jmetal.util.termination_criterion import TerminationCriterion +from jmetal.core.algorithm import Algorithm +from jmetal.core.operator import Mutation +from jmetal.core.problem import Problem +from jmetal.core.solution import Solution +from jmetal.util.termination_criterion import TerminationCriterion S = TypeVar('S') R = TypeVar('R') @@ -140,7 +137,7 @@

    Source code for jmetal.algorithm.singleobjective.simulated_annealing

    [docs]class SimulatedAnnealing(Algorithm[S, R], threading.Thread): - def __init__(self, + def __init__(self, problem: Problem[S], mutation: Mutation, termination_criterion: TerminationCriterion): diff --git a/docs/_modules/jmetal/core/observer.html b/docs/_modules/jmetal/core/observer.html index 6b739ff4..0f3a67b4 100644 --- a/docs/_modules/jmetal/core/observer.html +++ b/docs/_modules/jmetal/core/observer.html @@ -24,7 +24,6 @@ - @@ -74,8 +73,6 @@

    Table Of Contents

  • Single-objective algorithms
  • Operators
  • Problems
  • -
  • Contributing
  • -
  • About
  • @@ -112,7 +109,7 @@

    Table Of Contents

    Source code for jmetal.core.observer

    -from abc import abstractmethod, ABC
    +from abc import abstractmethod, ABC
     
     """
     .. module:: Observable
    diff --git a/docs/_modules/jmetal/core/problem.html b/docs/_modules/jmetal/core/problem.html
    index 66da5994..612b63b4 100644
    --- a/docs/_modules/jmetal/core/problem.html
    +++ b/docs/_modules/jmetal/core/problem.html
    @@ -24,7 +24,6 @@
         
         
         
    -    
         
         
       
    @@ -74,8 +73,6 @@ 

    Table Of Contents

  • Single-objective algorithms
  • Operators
  • Problems
  • -
  • Contributing
  • -
  • About
  • @@ -114,11 +111,11 @@

    Table Of Contents

    Source code for jmetal.core.problem

     import logging
     import random
    -from abc import ABC, abstractmethod
    -from typing import Generic, TypeVar, List
    +from abc import ABC, abstractmethod
    +from typing import Generic, TypeVar, List
     
    -from jmetal.core.observer import Observer
    -from jmetal.core.solution import BinarySolution, FloatSolution, IntegerSolution, PermutationSolution
    +from jmetal.core.observer import Observer
    +from jmetal.core.solution import BinarySolution, FloatSolution, IntegerSolution, PermutationSolution
     
     LOGGER = logging.getLogger('jmetal')
     
    @@ -131,7 +128,7 @@ 

    Source code for jmetal.core.problem

         MINIMIZE = -1
         MAXIMIZE = 1
     
    -    def __init__(self):
    +    def __init__(self):
             self.number_of_variables: int = 0
             self.number_of_objectives: int = 0
             self.number_of_constraints: int = 0
    @@ -175,14 +172,14 @@ 

    Source code for jmetal.core.problem

     
    [docs]class BinaryProblem(Problem[BinarySolution], ABC): """ Class representing binary problems. """ - def __init__(self): + def __init__(self): super(BinaryProblem, self).__init__()
    [docs]class FloatProblem(Problem[FloatSolution], ABC): """ Class representing float problems. """ - def __init__(self): + def __init__(self): super(FloatProblem, self).__init__() self.lower_bound = [] self.upper_bound = [] @@ -202,7 +199,7 @@

    Source code for jmetal.core.problem

     
    [docs]class IntegerProblem(Problem[IntegerSolution], ABC): """ Class representing integer problems. """ - def __init__(self): + def __init__(self): super(IntegerProblem, self).__init__() self.lower_bound = None self.upper_bound = None @@ -223,7 +220,7 @@

    Source code for jmetal.core.problem

     
    [docs]class PermutationProblem(Problem[PermutationSolution], ABC): """ Class representing permutation problems. """ - def __init__(self): + def __init__(self): super(PermutationProblem, self).__init__()
    @@ -254,7 +251,7 @@

    Source code for jmetal.core.problem

                 .add_constraint(c1)\
                 .add_constraint(c2)
         """
    -    def __init__(self):
    +    def __init__(self):
             super(OnTheFlyFloatProblem, self).__init__()
             self.functions = []
             self.constraints = []
    diff --git a/docs/_modules/jmetal/lab/experiment.html b/docs/_modules/jmetal/lab/experiment.html
    index 8ee1bac0..6eb4eb19 100644
    --- a/docs/_modules/jmetal/lab/experiment.html
    +++ b/docs/_modules/jmetal/lab/experiment.html
    @@ -10,10 +10,9 @@
       
       
       
    -  
       
       
    -    jmetal.lab.experiment — jMetalPy 1.5.1 documentation
    +    jmetal.lab.experiment — jMetalPy 1.5.3 documentation
         
         
         
    @@ -22,8 +21,9 @@
         
         
         
    +    
         
    -    
    +    
         
         
       
    @@ -39,7 +39,7 @@ 

    Navigation

  • modules |
  • - +
    @@ -50,7 +50,16 @@

    Navigation

    + ../../../index.html" class="text-logo"> + jMetalPy 1.5.3 documentation +
    + + +