Skip to content

Commit

Permalink
Merge pull request #1278 from CQCL/release/1.26.0
Browse files Browse the repository at this point in the history
Release/1.26.0
  • Loading branch information
cqc-alec authored Mar 19, 2024
2 parents 0ec6039 + 1ed6606 commit 4f68f92
Show file tree
Hide file tree
Showing 79 changed files with 2,873 additions and 221 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build-with-nix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,6 @@ jobs:
runs-on: ${{matrix.os}}
steps:
- uses: actions/checkout@v4
- uses: cachix/install-nix-action@v25
- uses: cachix/install-nix-action@v26
- name: Build and test tket
run: nix flake check -L
8 changes: 4 additions & 4 deletions .github/workflows/build_and_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
- uses: actions/setup-python@v5
with:
python-version: '3.12'
- uses: dorny/[email protected].0
- uses: dorny/[email protected].2
id: filter
with:
base: ${{ github.ref }}
Expand Down Expand Up @@ -88,7 +88,7 @@ jobs:
- name: Check C++ code formatting
run: |
brew update
brew install clang-format@17
brew install clang-format@18
git ls-files "*.cpp" "*.hpp" | xargs clang-format -style=file --dry-run --Werror
build_test_tket:
Expand Down Expand Up @@ -189,7 +189,7 @@ jobs:
ccache --set-config namespace=WITH_TESTS
ccache -p
- name: Get current time
uses: josStorer/[email protected].1
uses: josStorer/[email protected].2
id: current_time
with:
format: YYYYMMDDHHmmss
Expand Down Expand Up @@ -456,7 +456,7 @@ jobs:
ccache --set-config namespace=WITH_TESTS
ccache -p
- name: Get current time
uses: josStorer/[email protected].1
uses: josStorer/[email protected].2
id: current_time
with:
format: YYYYMMDDHHmmss
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/build_libs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
libs: ${{ steps.filter.outputs.changes }}
steps:
- uses: actions/checkout@v4
- uses: dorny/[email protected].0
- uses: dorny/[email protected].2
id: filter
with:
base: ${{ github.ref }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
tket: ${{ steps.filter.outputs.tket }}
steps:
- uses: actions/checkout@v4
- uses: dorny/[email protected].0
- uses: dorny/[email protected].2
id: filter
with:
base: ${{ github.ref }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test_libs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
libs: ${{ steps.filter.outputs.changes }}
steps:
- uses: actions/checkout@v4
- uses: dorny/[email protected].0
- uses: dorny/[email protected].2
id: filter
with:
base: ${{ github.ref }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/valgrind.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
tket: ${{ steps.filter.outputs.tket }}
steps:
- uses: actions/checkout@v4
- uses: dorny/[email protected].0
- uses: dorny/[email protected].2
id: filter
with:
base: ${{ github.ref }}
Expand Down
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ repo.
C++20 features may be used whenever they are supported by all the compilers
used on the CI (listed in the README).

All C++ code should be formatted with `clang-format` (v17) using the
All C++ code should be formatted with `clang-format` (v18) using the
configuration file `.clang-format` in the root directory. This is checked on
the CI. The script `do-clang-format` will run this over all C++ files in the
repository and fix them up.
Expand Down
49 changes: 32 additions & 17 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,27 +1,53 @@
# tket

[![Slack](https://img.shields.io/badge/Slack-4A154B?style=for-the-badge&logo=slack&logoColor=white)](https://tketusers.slack.com/join/shared_invite/zt-18qmsamj9-UqQFVdkRzxnXCcKtcarLRA#)
[![Stack Exchange](https://img.shields.io/badge/StackExchange-%23ffffff.svg?style=for-the-badge&logo=StackExchange)](https://quantumcomputing.stackexchange.com/tags/pytket)
[![PyPI version](https://badge.fury.io/py/pytket.svg)](https://badge.fury.io/py/pytket)

## Introduction

This repository contains the full source code for tket, a quantum SDK.
TKET (pronounced "ticket") is a high-performance quantum compiler that can optimise circuits for a wide range of quantum computing architectures.

This repository contains the full source code for TKET and its python bindings.

The standard way of using TKET is via its pytket python API.

If you just want to use tket via Python, the easiest way is to install it with
If you just want to use TKET via Python, the easiest way is to install pytket with
`pip`:

```shell
pip install pytket
```

For full API documentation, as well as a comprehensive user manual and a
selection of example notebooks, please follow the links from the
[pytket](https://github.com/CQCL/pytket) main page.
As well as being an interface to the TKET compiler, pytket also provides an extensive API for other quantum computing tasks. These include constructing quantum circuits and handling the execution of experiments on devices and simulators.

## Documentation

The `tket` (C++) API documentation (generated with `doxygen`, and still rather
patchy) is available
[here](https://cqcl.github.io/tket/tket/api/index.html).

The `pytket` (Python) API documentation is available
[here](https://tket.quantinuum.com/api-docs).

For getting started using pytket, check out the user manual and notebook examples.

- User manual - https://tket.quantinuum.com/user-manual/
- Notebook examples - https://tket.quantinuum.com/examples/

The source content for the manual and notebook examples can be found in the [pytket-docs repository](https://github.com/CQCL/pytket-docs).

## Extensions

In addition to the core pytket package there are pytket extension modules which allow pytket to interface with quantum devices and simulators. Some extensions also provide interoperability with other software libraries such as qiskit, cirq and pennylane.

For a list of available pytket extensions see the [extensions index page](https://tket.quantinuum.com/api-docs/extensions).

These extensions are installed as separate python packages and the source code for each extension lives in its own github repository.

If you would like to build tket yourself and help to improve it, read on!
## How to build TKET and pytket

If you would like to build TKET yourself and help to improve it, read on!

The codebase is split into two main projects:
- [tket](tket): the core functionality of tket, optimised for execution speed
Expand All @@ -32,8 +58,6 @@ The codebase is split into two main projects:
used by the extension modules such as the `Backend` and `BackendResult` classes,
as well as various other utilities.

## How to build tket and pytket

### Prerequisites

#### Build tools
Expand Down Expand Up @@ -129,12 +153,3 @@ building and testing pytket.
Tket and pytket are available as a Nix flake, with support for Linux and Apple Silicon systems.
See the [README](nix-support/README.md) in the `nix-support` directory for instructions
on building and testing tket and pytket through Nix, and on how to use it within a Nix project.

## API documentation

The `tket` (C++) API documentation (generated with `doxygen`, and still rather
patchy) is available
[here](https://cqcl.github.io/tket/tket/api/index.html).

The `pytket` (Python) API documentation is available
[here](https://cqcl.github.io/tket/pytket/api/index.html).
4 changes: 2 additions & 2 deletions libs/tklog/src/TketLog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,8 @@ void Logger::log(const char *levstr, const std::string &s, std::ostream &os) {
#else
plt = std::localtime(&t);
#endif
os << "[" << std::put_time(plt, "%Y-%m-%d %H:%M:%S") << "]"
<< " [tket] [" << levstr << "] " << s << std::endl;
os << "[" << std::put_time(plt, "%Y-%m-%d %H:%M:%S") << "]" << " [tket] ["
<< levstr << "] " << s << std::endl;
}

void Logger::set_level(LogLevel lev) { level = lev; }
Expand Down
1 change: 1 addition & 0 deletions pytket/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,7 @@ set(HEADER_FILES
binders/include/add_gate.hpp
binders/include/binder_json.hpp
binders/include/binder_utils.hpp
binders/include/circuit_registers.hpp
binders/include/deleted_hash.hpp
binders/include/py_operators.hpp
binders/include/typecast.hpp
Expand Down
Loading

0 comments on commit 4f68f92

Please sign in to comment.