Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cleanup example notebooks and make them compile again #868

Merged
merged 5 commits into from
Jul 1, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ The backend for TaborAWGs requires packages that can be found [here](https://git
The data acquisition backend for AlazarTech cards needs a package that unfortunately is not open source (yet). If you need it or have questions contact <[email protected]>.

## Documentation
You can find documentation on how to use this library on [readthedocs](https://qupulse.readthedocs.io/en/latest/) and [IPython notebooks with examples in this repo](doc/source/examples). You can build it locally with `python setup.py build_sphinx`.
You can find documentation on how to use this library on [readthedocs](https://qupulse.readthedocs.io/en/latest/) and [IPython notebooks with examples in this repo](doc/source/examples). You can build it locally with `hatch run docs:html`.

### Folder Structure
The repository primarily consists of the folders `qupulse` (toolkit core code) and `tests` (toolkit core tests). Additional parts of the project reside in `MATLAB` (MATLAB interface) and `doc` (configuration and source files to build documentation)
Expand All @@ -70,6 +70,7 @@ Contents of `tests` mirror the structure of `qupulse`. For every `<module>` some
- `hatch build`: Build wheel and source tarball
- `hatch version X.X.X`: Set version
- `hatch run docs:html`: Build documentation (requires pandoc)
- `hatch run docs:clean-notebooks` to execute all example notebooks that start with 00-03 and clean all metadata.
- `hatch run changelog:draft` and `hatch run changelog:release` to preview or update the changelog.

## License
Expand Down
24 changes: 4 additions & 20 deletions doc/source/examples/00AbstractPulseTemplate.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,7 @@
{
"cell_type": "code",
"execution_count": 1,
"metadata": {
"scrolled": true
},
"metadata": {},
"outputs": [],
"source": [
"from qupulse.pulses import AbstractPT, FunctionPT, AtomicMultiChannelPT, PointPT\n",
Expand Down Expand Up @@ -46,7 +44,7 @@
"output_type": "stream",
"text": [
"The integral has been declared so we can get it\n",
"{'Y': Expression('a*b + sin(t_manip)'), 'X': Expression('t_init - cos(t_manip) + 2')}\n",
"{'X': ExpressionScalar('t_init/2 - cos(t_manip) + 2'), 'Y': ExpressionScalar('a*b + t_init/2 + sin(t_manip)')}\n",
"\n",
"We get an error that for the pulse \"readout\" the property \"duration\" was not specified:\n",
"NotSpecifiedError('readout', 'duration')\n"
Expand Down Expand Up @@ -84,7 +82,7 @@
"text": [
"With wrong integral value:\n",
"RuntimeError('Cannot link to target. Wrong value of property \"integral\"')\n",
"the linking worked. The new experiment has now a defined duration of Expression('t_init + t_manip + t_read') .\n"
"the linking worked. The new experiment has now a defined duration of ExpressionScalar('t_init + t_manip + t_read') .\n"
]
}
],
Expand All @@ -107,22 +105,8 @@
}
],
"metadata": {
"kernelspec": {
"display_name": "Python 3",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.7.2"
"name": "python"
}
},
"nbformat": 4,
Expand Down
Loading
Loading