Enum BopParameters.ThreadSynchronizationType

  • All Implemented Interfaces:
    com.google.protobuf.Internal.EnumLite, com.google.protobuf.ProtocolMessageEnum, java.io.Serializable, java.lang.Comparable<BopParameters.ThreadSynchronizationType>
    Enclosing class:
    BopParameters

    public static enum BopParameters.ThreadSynchronizationType
    extends java.lang.Enum<BopParameters.ThreadSynchronizationType>
    implements com.google.protobuf.ProtocolMessageEnum
     Defines how the different solvers are synchronized during the search.
     Note that the synchronization (if any) occurs before each call to an
     optimizer (the smallest granularity of the solver in a parallel context).
     
    Protobuf enum operations_research.bop.BopParameters.ThreadSynchronizationType
    • Enum Constant Detail

      • NO_SYNCHRONIZATION

        public static final BopParameters.ThreadSynchronizationType NO_SYNCHRONIZATION
         No synchronization. The solvers run independently until the time limit
         is reached; Then learned information from each solver are aggregated.
         The final solution is the best of all found solutions.
         Pros: - No need to wait for another solver to complete its task,
               - Adding a new solver always improves the final solution (In the
                 current implementation it still depends on the machine load and
                 the time limit).
         Cons: - No learning between solvers.
         
        NO_SYNCHRONIZATION = 0;
      • SYNCHRONIZE_ALL

        public static final BopParameters.ThreadSynchronizationType SYNCHRONIZE_ALL
         Synchronize all solvers. Each solver waits for all other solvers to
         complete the previous optimizer run, before running again.
         The final solution is the best of all found solutions.
         Pros: - Full learning between solvers.
         Cons: - A lot of waiting time when solvers don't run at the exact same
                 speed,
               - The quality of the final solution depends on the number of
                 solvers, adding one more solver might lead to poorer results
                 because the search goes on a different path.
         
        SYNCHRONIZE_ALL = 1;
      • SYNCHRONIZE_ON_RIGHT

        public static final BopParameters.ThreadSynchronizationType SYNCHRONIZE_ON_RIGHT
         Solver i synchronizes with solvers 0..i-1.
         This is a good tradeoff between NO_SYNCHRONIZATION and SYNCHRONIZE_ALL:
         communication while keeping a relative determinism on the result even
         when the number of solvers increases.
         The final solution is the best of all found solutions.
         Pros: - Solver i learns from i different solvers,
               - Adding a new solver always improves the final solution (In the
                 current implementation it still depends on the machine load and
                 the time limit).
         Cons: - No full learning,
               - Some solvers need to wait for synchronization.
         
        SYNCHRONIZE_ON_RIGHT = 2;
    • Field Detail

      • NO_SYNCHRONIZATION_VALUE

        public static final int NO_SYNCHRONIZATION_VALUE
         No synchronization. The solvers run independently until the time limit
         is reached; Then learned information from each solver are aggregated.
         The final solution is the best of all found solutions.
         Pros: - No need to wait for another solver to complete its task,
               - Adding a new solver always improves the final solution (In the
                 current implementation it still depends on the machine load and
                 the time limit).
         Cons: - No learning between solvers.
         
        NO_SYNCHRONIZATION = 0;
        See Also:
        Constant Field Values
      • SYNCHRONIZE_ALL_VALUE

        public static final int SYNCHRONIZE_ALL_VALUE
         Synchronize all solvers. Each solver waits for all other solvers to
         complete the previous optimizer run, before running again.
         The final solution is the best of all found solutions.
         Pros: - Full learning between solvers.
         Cons: - A lot of waiting time when solvers don't run at the exact same
                 speed,
               - The quality of the final solution depends on the number of
                 solvers, adding one more solver might lead to poorer results
                 because the search goes on a different path.
         
        SYNCHRONIZE_ALL = 1;
        See Also:
        Constant Field Values
      • SYNCHRONIZE_ON_RIGHT_VALUE

        public static final int SYNCHRONIZE_ON_RIGHT_VALUE
         Solver i synchronizes with solvers 0..i-1.
         This is a good tradeoff between NO_SYNCHRONIZATION and SYNCHRONIZE_ALL:
         communication while keeping a relative determinism on the result even
         when the number of solvers increases.
         The final solution is the best of all found solutions.
         Pros: - Solver i learns from i different solvers,
               - Adding a new solver always improves the final solution (In the
                 current implementation it still depends on the machine load and
                 the time limit).
         Cons: - No full learning,
               - Some solvers need to wait for synchronization.
         
        SYNCHRONIZE_ON_RIGHT = 2;
        See Also:
        Constant Field Values
    • Method Detail

      • values

        public static BopParameters.ThreadSynchronizationType[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (BopParameters.ThreadSynchronizationType c : BopParameters.ThreadSynchronizationType.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static BopParameters.ThreadSynchronizationType valueOf​(java.lang.String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
        java.lang.NullPointerException - if the argument is null
      • getNumber

        public final int getNumber()
        Specified by:
        getNumber in interface com.google.protobuf.Internal.EnumLite
        Specified by:
        getNumber in interface com.google.protobuf.ProtocolMessageEnum
      • valueOf

        @Deprecated
        public static BopParameters.ThreadSynchronizationType valueOf​(int value)
        Deprecated.
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        value - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
        java.lang.NullPointerException - if the argument is null
      • forNumber

        public static BopParameters.ThreadSynchronizationType forNumber​(int value)
        Parameters:
        value - The numeric wire value of the corresponding enum entry.
        Returns:
        The enum associated with the given numeric wire value.
      • getValueDescriptor

        public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor()
        Specified by:
        getValueDescriptor in interface com.google.protobuf.ProtocolMessageEnum
      • getDescriptorForType

        public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType()
        Specified by:
        getDescriptorForType in interface com.google.protobuf.ProtocolMessageEnum
      • getDescriptor

        public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor()
      • valueOf

        public static BopParameters.ThreadSynchronizationType valueOf​(com.google.protobuf.Descriptors.EnumValueDescriptor desc)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        desc - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
        java.lang.NullPointerException - if the argument is null