Skip to content

Commit

Permalink
Paper: address review comments (#98)
Browse files Browse the repository at this point in the history
  • Loading branch information
IceKhan13 authored Aug 23, 2023
1 parent 53c149c commit 6a23a15
Show file tree
Hide file tree
Showing 4 changed files with 33 additions and 2 deletions.
4 changes: 2 additions & 2 deletions client/purplecaffeine/widget.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,9 +110,9 @@ def render_trails_list(self):
We render one button per each trial
"""
buttons = []
for trial in self.trials:
for idx, trial in enumerate(self.trials):
button = widgets.Button(
description=f"{trial.name} | {trial.uuid}"[:30],
description=f"{self.offset + idx + 1}. {trial.name}"[:30],
disabled=False,
button_style="",
tooltip=trial.uuid,
Expand Down
4 changes: 4 additions & 0 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,4 +59,8 @@
nbsphinx_timeout = 180
nbsphinx_execute = "never"
nbsphinx_widgets_path = ""
nbsphinx_thumbnails = {
"**": "_static/images/logo.png",
}

exclude_patterns = ["_build", "**.ipynb_checkpoints"]
14 changes: 14 additions & 0 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,20 @@ Step 2: visualize tracked data

------------

**Serialization**

Trials are serialized using Python `json` module. We've implemented
custom `json.JSONEncoder` and `json.JSONDecoder` to handle quantum computing objects
like `QuantumCircuit`, `Backend`, `Operator`, etc.

Encoders and decoders are using `pickle` module to serialize some classes (`Backend`).
The pickle module is not secure. Only unpickle data you trust.
It is possible to construct malicious pickle data which will
execute arbitrary code during unpickling. Never unpickle data that
could have come from an untrusted source, or that could have been tampered with.

------------

**Content**

.. toctree::
Expand Down
13 changes: 13 additions & 0 deletions docs/paper/paper.md
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,19 @@ providing a convenient and interactive environment for researchers.

![Widget.\label{fig:widget}](./images/widget_updated.png)

## Serialization

`Trial`s are serialized using Python's `json` module. We've implemented
custom `json.JSONEncoder` and `json.JSONDecoder` to handle quantum computing objects
like `QuantumCircuit`, `Backend`, `Operator`, etc.

Encoders and decoders are using `pickle` module to serialize some classes (`Backend`).
The pickle module is not secure. Only unpickle data you trust.
It is possible to construct malicious pickle data which will
execute arbitrary code during unpickling. Never unpickle data that
could have come from an untrusted source, or that could have been tampered with.


# Acknowledgements

We would like to express our sincere gratitude to the Qiskit Advocates Mentorship
Expand Down

0 comments on commit 6a23a15

Please sign in to comment.