Search Results for

    Show / Hide Table of Contents

    Simulated Annealing

    Performs metropolis dynamics on the model while gratually lowering ("annealing") the simulation temperature. As a result, the system settles in a low-cost state while still being allowed to escape local minima as the simulation progresses.

    • qiotoolkit's simulated annealing implementation allows the specification of an annealing schedule either as an explicit array of values or as a schedule-generator.

    • This (explicit or schedule-generated) list of numbers can be interpreted as inverse temperatures by specifying use_inverse_temperature = true.

    • Multiple restarts can be performed using the restarts parameter. These restarts are mutually independent.

    Note

    If you use the QIOtoolkit-comptaible parameters beta_start and beta_stop, the solver will attempt to infer the number of annealing steps from step_limit or its Qiotoolkit-alias sweeps.

    Example

    {
      "target": "simulated-annealing.qiotoolkit",
      "version": "1.0",
      "input_params": {
        "seed": 42,
        "schedule": {
          "type": "geometric",
          "initial_value": 3.0,
          "final_value": 0.2,
          "count": 128
        }
        "restarts": 8
      },
      "input_data_uri": "..."
    }
    

    This will perform 8 restarts of cooling the system from T=3.0 to T=0.2 in 128 steps spaced geometrically.

    Parameters Specification

    • List
    • Schema
    param type required/default description
    seed integer default: time-based
    schedule Schedule required How the temperature should be changed over time.
    use_inverse_temperature boolean default: false Whether to interpret schedule as inverse temperature.
    beta_start float >0 (QIO compatibility) Float specifying the starting inverse temperature.
    beta_stop float >beta_start (QIO compatibility) Float specifying the stopping inverse temperature.
    restarts integer > 0 default: 1 How many restarts to perform.
    {
      "$id": "solver/simulatedannealing.qiotoolkit.schema",
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "Simulated Annealing on CPU",
      "type": "object",
      "required": ["target", "input_params"],
      "properties": {
        "target": {
          "type": "string",
          "const": "simulatedannealing.qiotoolkit"
        },
        "input_params": {
          "type": "object",
          "oneOf": [
            {"requried": ["schedule"]},
            {"required": ["beta_start", "beta_stop"]},
          ],
          "properties": {
            "schedule": {
              "type": "object",
              "$ref": "../schedule/schedule.schema",
              "description": "How the temperature should be changed over time."
            },
            "use_inverse_temperature": {
              "type": "bool",
              "description": "Whether to interpret `schedule` as inverse temperature",
              "default": false
            },
            "beta_start": {
              "type": "number",
              "description": "float specifying the starting inverse temperature."
              "minimum": 0,
            },
            "beta_stop": {
              "type": "number",
              "description": "float specifying the stopping inverse temperature."
              "minimum": 0,
            },
            "restarts": {
              "type": "number",
              "description": "how many restarts to perform",
              "minimum": 1,
              "multipleOf": 1,
              "default": 1
            }
          },
        }
      }
    }
    
    In This Article
    Back to top Generated with Doxygen and DocFX