Skip to content

Commit

Permalink
make distro
Browse files Browse the repository at this point in the history
  • Loading branch information
Kahsolt committed Aug 1, 2024
1 parent fc09a02 commit 018926f
Show file tree
Hide file tree
Showing 5 changed files with 43 additions and 19 deletions.
57 changes: 38 additions & 19 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,35 @@
This project is for the quantum challenge 2024 from [第一届“天衍”量子计算挑战先锋赛-大众组](https://qc.zdxlz.com/learn/#/megagame/megagameDetail?id=1801135605315321857&lang=zh)


#### Screenshot

⚪ CUI

![cui](./img/cui.png)

⚪ WebUI (⚠ still under development...)

![webui](./img/webui.png)


#### How to start

ℹ So far only the ugly CUI client works... 😓

- `cd server; python server.py`
- `cd client\cui; python start.py`
- enter `h` for command help
- run in debug mode: `python start.py --debug`


#### GamePlay

- You will face with a 5-qubits 10-clock **quantum logical circuit**, and an infinite sequence of random spawned **quantum logical gates**, mimicking the traditional Tetris board and pieces 🤔
- You are asked to select proper gates and **append** to the circuit, and the score is counted 😮
- When two rotation gates of the same axis meet, they'll be **merged** with a score ratio x1.5 😀
- You will face with a 5-qubits 10-clock **quantum logical circuit**, and an infinite sequence of random spawned **quantum logical gates**, mimicking the traditional Tetris board and pieces
- You are asked to select proper gates and **append** to the circuit, and the score is counted
- When two rotation gates of the same axis meet, they'll be **merged** with a score ratio x1.5
- When two gates inversion (dagger!) of each other meet, they will be **eliminated (Bingo!)** with score ratio x3 🎉🎉
- Every 5 bingos, you'll have an additional **removal token**. You can use it to remove an arbitrary gate! 🤗
- Note that SWAP is NOT the the quantum SWAP gate, it can swap locations of two single-qubit gates! 😈
- Every 5 bingos, you'll have an additional **removal token**. You can use it to remove an arbitrary gate!
- Note that SWAP is NOT the the quantum SWAP gate, it can swap locations of two single-qubit gates!

<details>
<summary>Notes for the 1st gameplay design draft :(</summary>
Expand All @@ -27,20 +48,6 @@ However, implementing this requires O(2^n) computations and is extremely annoyin

#### References

⚪ Citation

If you find this work useful, please give a star ⭐ and cite 📖~

```
@misc{kahsolt2024,
author = {Kahsolt},
title = {Quantum-Circuit-Elimination},
howpublished = {\url{https://github.com/Kahsolt/Quantum-Circuit-Elimination}}
month = {July},
year = {2024}
}
```

⚪ Other Tetris-inspired quantum games

- Quantum Games and Interactive Tools for Quantum Technologies Outreach and Education: https://arxiv.org/pdf/2202.07756.pdf
Expand All @@ -59,6 +66,18 @@ If you find this work useful, please give a star ⭐ and cite 📖~
- repo: https://github.com/darkknightgit/QuanTetrum
- demo video: https://www.youtube.com/watch?v=DlKU3qC7mQc

If you find this work useful, please give a star ⭐ and cite~

```
@misc{kahsolt2024,
author = {Kahsolt},
title = {Quantum-Circuit-Elimination},
howpublished = {\url{https://github.com/Kahsolt/Quantum-Circuit-Elimination}}
month = {July},
year = {2024}
}
```

----
by Armit
2024/07/07
3 changes: 3 additions & 0 deletions client/cui/start.py
Original file line number Diff line number Diff line change
Expand Up @@ -270,6 +270,9 @@ def print_panel_main():

print('Cur Gate:', playerdata.cur_gate)
print('Next Gate:', playerdata.nxt_gate)
print('===================================')
print('Score:', playerdata.score)
print('Token:', playerdata.token)
print()

def run():
Expand Down
2 changes: 2 additions & 0 deletions client/webui/README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
This is a basic WebUI client for the Quantum Circuit Elimination game :)

⚠ 目前实现不完整,UX实现暂时无法解决 两比特门的放置 和 SWAP动作的使用

### Quick start

- just open file [index.html](./index.html) in your favourite brower
Expand Down
Binary file added img/cui.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added img/webui.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 018926f

Please sign in to comment.