Releases: XanaduAI/blackbird
Release v0.5.0
New features since last release
- Rebuilds the grammar using ANTLR
v4.9.2
(#51)
Documentation
- Updates ANTLR
v4.9.2
version on the compiling grammar section.
(#51)
Contributors
This release contains contributions from (in alphabetical order):
Kshitij Chhabra (@kshitijc), Sebastián Duque Mesa (@sduquemesa)
Release 0.4.0
Improvements
-
Remove support for Python 3.5. (#38)
-
Add support for Python 3.8 and 3.9. (#40)
-
Add public method to retrieve Blackbird program variables via
prog.variables
. (#47) -
Improve
match_template
to automatically return matched parameters with their array values,
rather than their array names (p0, p1, etc.) (#47) -
Remove p-type parameters from
prog.parameters
since they're only needed there internally and
are otherwise stored inprog.variables
. This also changes TDM programs to not be templates
(prog.is_template
now returnsFalse
). (#47)
Bug fixes
-
Fix bool or string objects in for-loop iterators not working correctly. (#41)
-
Update the NumPy scalar types in the Blackbird listener due to being deprecated in NumPy 1.20. (#43)
-
Add access to the symbolic expression used when creating a
RegRefTransform
,
as a class attribute. (#46)
Contributors
This release contains contributions from (in alphabetical order):
Theodor Isacsson
Release 0.3.0
New features since last release
-
Arrays and variables now support being defined as parameters (using braces) in a Blackbird template. (#34)
-
Time-domain multiplexing programs are now supported, using the syntax
type tdm (temporal_modes=3, copies=1)
. (#30) -
For-loops are supported inside Blackbird scripts. (#24)
They can be defined using ranges via the syntax
from:to:step
:for float v in 2:10:3 MZgate(v, v/2) | [0, 1]
or lists
for int m in [0, 2, 4] MeasureFock() | m
-
Keyword arguments are supported inside operations; for example,
MeasureHomodyne(select=[0, 1])
orMeasureFock(dark_counts=[1, 0.5, 3])
. (#23) -
Indexing is supported inside both modes and arguments; for example,
MZgate(list[2], list[0]) | [list[3], list[1]]))
. All indices allow expressions such asphases[-3 + 2*2]
. (#23)
Bug fixes
- Templates are no longer changed when calling them and replacing the parameters with actual values. (#34)
Documentation
- TDM programs, for-loops and array indexing is added to the docs, along with other minor updates. (#28)
This release contains contributions from (in alphabetical order):
Theodor Isacsson
Release 0.2.4
Minor updates release. Changes include:
- Updating
antlr4-python3-runtime
requirement to version 4.7.2 - Updating URL to correct Blackbird website
Release 0.2.1
Minor bug fix release. Changes include:
- Parsing error now correctly raises a
BlackbirdSyntaxError
, rather than aSystemError
.
Release 0.2
New features
- Adds parametrized template support (#13)
Release 0.1
Initial release.