D-Wave Ocean SDK

Ocean software is a suite of tools D-Wave Systems provides on the D-Wave GitHub repository for solving hard problems with quantum computers. It is easy to use various features from Python.

  • imod (repo) – Shared API for binary quadratic samplers. Provides a binary quadratic model (BQM) class that contains Ising and quadratic unconstrained binary optimization (QUBO) models used by samplers such as the D-Wave system. Also provides utilities for constructing new samplers and composed samplers.
  • dwavebinarycsp (repo) – Library to construct a binary quadratic model from a constraint satisfaction problem with small constraints over binary variables.
  • dwave-cloud-client (repo) – Minimal implementation of the REST interface used to communicate with D-Wave Sampler API (SAPI) servers.
  • dwave-greedy (repo) – An implementation of a steepest descent solver for binary quadratic models.
  • dwave-hybrid (repo) – A general, minimal Python framework for building hybrid asynchronous decomposition samplers for quadratic unconstrained binary optimization (QUBO) problems.
  • dwave-inspector (repo) – A tool for visualizing problems submitted to, and answers received from, a D-Wave structured solver such as a D-Wave 2000Q quantum computer.
  • dwave-neal (repo) – An implementation of a simulated annealing sampler.
  • dwave-networkx (repo) – Extension of NetworkX—a Python language package for exploration and analysis of networks and network algorithms—for users of D-Wave Systems.
  • dwave-networkx provides tools for working with Chimera graphs and implementations of graph-theory algorithms on the D-Wave system and other binary quadratic model samplers.
  • dwave-ocean-sdk (repo) – Installer for D-Wave’s Ocean Tools.
  • dwave-system (repo) – Basic API for easily incorporating the D-Wave system as a sampler in the D-Wave Ocean software stack. It includes DWaveSampler, a dimod sampler that accepts and passes system parameters such as system identification and authentication down the stack. It also includes several useful composites—layers of pre- and post-processing—that can be used with DWaveSampler to handle minor-embedding, optimize chain strength, etc.
  • dwave-tabu (repo) – An implementation of the MST2 multistart tabu search algorithm for quadratic unconstrained binary optimization (QUBO) problems with a dimod Python wrapper.
  • penaltymodel (repo) – An approach to solve a constraint satisfaction problem (CSP) using an Ising model or a QUBO, is to map each individual constraint in the CSP to a ‘small’ Ising model or QUBO. Includes a local cache for penalty models and a factory that generates penalty models using SMT solvers.
  • minorminer (repo) – A tool for finding graph minor-embeddings, developed to embed Ising problems onto quantum annealers (QA). While it can be used to find minors in arbitrary graphs, it is particularly geared towards the state of the art in QA: problem graphs of a few to a few hundred variables, and hardware graphs of a few thousand qubits.
  • pyQUBO (repo)  – A package that helps you create QUBOs and Ising models from flexible mathematical expressions.
  • qbsolv (repo) – A decomposing solver that finds a minimum value of a large quadratic unconstrained binary optimization (QUBO) problem by splitting it into pieces. The pieces are solved using a classical solver running the tabu algorithm. qbsolv also enables configuring a D-Wave system as the solver.

Ocean SDK tutorial

Ocean SDK (Python) shouldbe used in virtual environment. To set up the required dependencies, run the following command from your terminal: pip install dwave-ocean-sdk && dwave setup.    Follow the script and  accept the terms and conditions, agree to create a configuration file, and answer the prompts to add your information to the config file.  Paste your API token into your terminal when prompted. You can find your API token on the Leap Dashboard.   Paste your Solver API Endpoint into your terminal when prompted.  You can also find this on the Leap Dashboard, towards the bottom of the page.  All other settings can be left blank for default settings by hitting “Enter”. You should now be able to connect to a D-Wave system. Verify with the following command: dwave ping.