Releases: tequilahub/tequila
v.1.9.7
Minor convenience changes
Major Performance improvements for wavefunction simulation (without using expecation values)
- Fix
U.export_to("path.png)"
syntax - Deepcopy gates in
__iadd__
ofQCircuit
(#360) - Simulation performance improvements (#359)
- Only apply keymap if necessary in
simulate
- Simplify comparison and only calculate index bitstring when necessary in
from_array
- Fix
numbering_out
parameter ininitialize_bitstring
and remove MSB2LSB/LSB2MSB keymap infrom_array
- Optimize
initialize_bitstring
- Update requirements.txt (no scipy version restriction, issue #361)
- rdm calculation more flexible (#363)
- Update version.py
RDM calculations:
calling the rdm function in the quantum chemistry module with evaluate=False
gives back a tq.QTensor
object
direct evaluation within compute_rdm
is however faster (no repetitions in the simulation)
rdm1, rdm2 = mol.compute_rdms(U=U, evaluate=False)
Performance improvements @ohuettenhofer
see the original pr: #359
no syntax changes
Co-authored-by: Oliver Huettenhofer oliver.huettenhofer@gmail.com
Co-authored-by: Oliver Hüttenhofer 168852439+ohuettenhofer@users.noreply.github.com
v.1.9.6
New functionality in chemistry module, smaller bug fixes, minor changes.
New functionality in Chemistry Module:
Orbital Rotation Circuits
UR = mol.get_givens_circuit(spatial_orbital_transformation_matrix)
Optimized compilation of Jordan-Wigner UCC excitation gates
According to: Yordanov et. al.
Unitary Conversion between Bravyi-Kitaev and Jordan-Wigner
U = mol.transformation.me_to_jw()
Transform molecular RDMS
e.g. freeze orbital 1 (in JW) explicitly.
rdm1, rdm2 = mol.compute_rdms(..., rdm_trafo=tq.paulis.X([0,1])
Otherwise
- dropping GPyOpt support (not updated to dependencies/new python versions)
- Qiskit translation updated to current qiskit version.
individual PRs
- Fixing Pyscf_mol.from_tq() (#342)
- Fixing Pyscf_mol.from_tq()
- RDMs transformation (#341)
- rdms transformation
- rdm_trafo default from False to None
- fix U.export_to() personalized (#344)
- Add Givens Methods (#343)
- add automatic construction of orbital rotation circuits
- control not passed form QubitExcitation to QubitExcitationImpl (#346)
- fixing error in the initialization of binary hamiltonians closes #394 (#351)
- Fermionic Excitation Implementation (#350)
- Fermionic Excitation Implementation
- made indices in Fermionic excitations more consistent
- Update chemistry_tools.py
- Update qc_base.from tequila (#353)
- Update simulator_qiskit.py (#354)
fixing u1, cu1 deprecation in qiskit - quantumchemistry: added encoding transformations (#345)
- quantum chemistry: added encoding transformations
- Update CI
- updating qiskit noise imports to latest versions (#355)
Co-authored-by: JdelArco98 javierdelarcosantos@gmail.com
Co-authored-by: Phillip W. K. Jensen 46899159+pwkj@users.noreply.github.com
Co-authored-by: JdelArco98 francisco.del.arco.santos@uni-a.de
Co-authored-by: Deadly Artist 44524817+DeadlyArtist@users.noreply.github.com
Co-authored-by: Benjamin Meyer 46791542+benni-tec@users.noreply.github.com
v.1.9.5
Tequila Version 1.9.5
- orbital names are better tracked through transformations (#338)
- keep basis info when re-initializing with mol.from_tequila
Example (Gaussian Basis Set)
needs
pip install pyscf
geom = "H 0.0 0.0 0.0\nH 0.0 0.0 1.5"
mol = tq.Molecule(geometry=geom, basis_set="sto-3g")
mol.print_basis_info()
gives
basis_name : sto-3g
orbital_type : hf
orthogonal basis : False
basis functions : 2
active orbitals : [0, 1]
reference : [0]
Current Orbitals
{idx_total:0, idx:0}
coefficients: [0.63074567 0.63074567]
{idx_total:1, idx:1}
coefficients: [ 0.82021585 -0.82021585]
change to "native orbitals", meaning in this case orthonormalized atomics
mol = mol.use_native_orbitals()
mol.print_basis_info()
gives
basis_name : sto-3g
orbital_type : orthonormalized-sto-3g-basis
orthogonal basis : False
basis functions : 2
active orbitals : [0, 1]
reference : [0]
Current Orbitals
{idx_total:0, idx:0}
coefficients: [ 1.02598473 -0.13397565]
{idx_total:1, idx:1}
coefficients: [-0.13397565 1.02598473]
Using the orbital optimization routine will now set the orbital coefficients w.r.t the original basis
U = mol.make_ansatz(name="SPA", edges=[(0,1)])
opt = tq.chemistry.optimize_orbitals(molecule=mol, circuit=U)
mol2 = opt.molecule
mol2.print_basis_info()
basis_name : sto-3g
orbital_type : optimized
orthogonal basis : False
basis functions : 2
active orbitals : [0, 1]
reference : [0]
Current Orbitals
{idx_total:0, idx:0}
coefficients: [-0.63074597 -0.63074537]
{idx_total:1, idx:1}
coefficients: [ 0.82021562 -0.82021608]
Example MRA-PNOs
MRA-PNOs from the madness module, need
pip install pyscf
conda install madtequila -c kottmann
geom = "H 0.0 0.0 0.0\nH 0.0 0.0 1.5"
mol = tq.Molecule(geometry=geom)
mol.print_basis_info()
basis_name : mra
orbital_type : pno
orthogonal basis : True
basis functions : 2
active orbitals : [0, 1]
reference : [0]
Current Orbitals
{idx_total:0, idx:0, occ:2.0, pair:(0, 0)}
coefficients: [1. 0.]
{idx_total:1, idx:1, occ:0.0425791, pair:(0, 0)}
coefficients: [0. 1.]
MRA-PNOs are the native basis, so mol.use_native_basis()
has no effect here. After calling the orbital-optimizer, coefficients of the optimized molecule are w.r.t the MRA-PNOs.
-
fixing syntax issue in post_init of dataclass (#327)
-
Support for phoenics optimizer dropped (dependency not maintained anymore and problems with downstream dependencies are piling up)
-
more convenient randomization initialization for orbital optimizer (e.g
initial_guess="near_zero"
) -
added methods to create annihilation, creation, sz, sp, sm and s2 operators in qubit representation (#336)
ak = mol.make_annihilation_op(k) # spin-orbital k
ck = mol.make_creation_op(k)
ck = ak.dagger()
S = mol.make_s2_op() # total-spin operator
Sz = mol.make_sz_op() # spin-polarization
Nk = mol.make_number_op(k)
Co-authored-by: davibinco 59845652+davibinco@users.noreply.github.com
v.1.9.4
v.1.9.3
v.1.9.2
v.1.9.1
v.1.9.0
- orbital optimizer more flexible with regards to qubit encodings (#305)
see https://arxiv.org/abs/2105.03836 for more on the "HCB" encoding
orbital optimization with circuits that respect HCB encodings now around a factor of 2 faster.
see tequilahub/quantum-valence-bond for an example in fileh6_spa.py
Example:
import tequila as tq
mol = tq.Molecule(geometry="H 0.0 0.0 1.0\nH 0.0 0.0 2.0\nH 0.0 0.0 3.0\nH 0.0 0.0 4.0")
U = mol.make_ansatz(name="HCB-SPA")
opt = tq.chemistry.optimize_orbitals(mol, U, use_hcb=True)
-
Structures for F3 circuit optimizations (#303)
-
Adding linear depth F3 circuit
-
Adding trotter error feature along testing data (#292)
-
Adding trotter error feature along testing data
-
iSWAP gate and Givens gate (#304)
-
Implement iSWAP gate.
-
Implement Givens gate and bugfix tests iSWAP.
-
Remove iSWAP from Cirq simulator.
-
Refactor
GeneralizedRotation
to generators with (possible) nullspace. (#306) -
Migrate shifted_gates method from QubitExcitation to GeneralizedRotation.
-
Bugfix: list of
GeneralizedRotationImpl
. -
Bugfix: target order matters in
QubitExcitation
. -
Add check for p0 in
GeneralizedRotation
. -
SWAP gate initialization updated to follow conventions
-
Refactor
mapped_qubits
to avoid duplicate code. -
added GenRot shortcut
-
Bugfix: change API to modularized
cirq
package. (#308) -
Refactor circuit build to
cirq_google
module. -
Add check for
cirq_google
, add test. -
Update ci_backends.yml
-
Some BugFixes (#311)
-
UpCCGSD mix_sd fixed
Co-authored-by: Praveen Jayakumar praveen91299@gmail.com
Co-authored-by: Praveen Jayakumar praveen.jayakumar@mail.utoronto.ca
Co-authored-by: lamq317 lamq317@gmail.com
Co-authored-by: Daria Van Hende 33431368+dariavh@users.noreply.github.com
Co-authored-by: JdelArco98 104641558+JdelArco98@users.noreply.github.com
v.1.8.9
-
better messages for madtequila (#291)
-
qubit encodings consistency (#294)
-
more consistency in HCB approximation and SPA wavefunctions (#295)
-
more consistency in HCB approximation and SPA wavefunctions
-
keeping up to date with pyscf and setting parse_arg=False in mol constructor (mainly blocks pytest commands)
-
added plot2cube support to madness interface (#296)
-
Update madness_interface.py
-
dropping noisy simulation support in qulacs -- no longer maintained
-
fixing small issue in tests regarding scipy 1.11 release
-
adding args/kwargs to psi4.compute_rdms function
-
adding return to call of base class in psi4.compute_rdms function
# create cube files form madness orbitals
mol = tq.Molecule(geometry="myfile.xyz")
mol.plot2cube(orbital=2) # plots active orbital 2 to a cube file
- preparing for hcb merge (#293)
mol.compute_rdms(use_hcb=True) is now enabled for spin-free matrices. Allows to compute RDMs with half the qubits (given that the circuit is in HCB encoding). - Implementing HCB rdm on general compute_rdms()
- consistency in rdm computation with hcb for reordered transformations
- fixes hcb_rdms and Tests rdms_hcb
Co-authored-by: Javier del Arco javierdelarcosantos@gmail.com
Co-authored-by: J. S. Kottmann jakob.kottmann@gmail.com
- enabled HCB in orbital optimization, can be done via tq.chemistry.opt… (#297)
- enabled HCB in orbital optimization, can be done via tq.chemistry.optimize_orbitals(...,use_hcb=True)
# orbital optimization with hardcore-boson circuits
U = mol.make_ansatz("HCB-UpCCD")
opt = tq.chemistry.optimize_orbitals(circuit=U, molecule=mol, initial_guess=guess, use_hcb=True)
- small issue in consistency test, silenced unnecesarry warning
- QASM string parsing bug (#298)
Co-authored-by: Praveen Jayakumar praveen.jayakumar@mail.utoronto.ca
- Update requirements.txt
- Fix NumPy float and int (#301)
Co-authored-by: JdelArco98 104641558+JdelArco98@users.noreply.github.com
Co-authored-by: Javier del Arco javierdelarcosantos@gmail.com
Co-authored-by: Praveen Jayakumar praveen91299@gmail.com
Co-authored-by: Praveen Jayakumar praveen.jayakumar@mail.utoronto.ca
Co-authored-by: Erik Kjellgren erikkjellgren@live.dk
v.1.8.8
Improvement on Measurement Optimization (Seonghoon Choi @schoi839 & Aranya Chakraborty @Aranya3003 ):
Addition of techniques from https://doi.org/10.22331/q-2023-01-03-889 (Izmaylov Group)
PR authored by: Seonghoon Choi and Aranya Chakraborty
-
Completed SVD (commit on behalf of Aranya Chakraborty).
-
Completed FFF (commit on behalf of Aranya Chakraborty).
-
Improved the efficiency of F3.
-
Truncated CISD containing only a few slater determinant terms is usedinstead of the full CISD.
-
F3 is performed only on a few large variance fragments.
-
Safer choice of minimum meas_alloc (1e-6) to avoid issues with allocating 0 shots.
-
Addressing minor comments.
-
Adding tests for Fermionic measurement optimization schemes.
-
Returning rotated (cartan form) obt and tbts after F3.
-
Changed OSI to ICS for consistency.
-
Circuit for fermionic measurement techniques:
-
Added circuit implementations of orbital rotations
-
Added test for orbital rotations.
-
Proper handling of non-symmetric fermionic Hamiltonian (happens when one obtains it from reverse_jordan_wigner of a qubit Hamiltonian).
-
Handling options in compile_groups to better deal with exceptions and
default options. -
get_fermionic_wise now correctly returns QubitHamiltonian rather than
openfermion QubitOperator. -
If suggested samples = 0, at least 1 sample (shot) is allocated for
that measurable fragment.
- Update psi4_interface.py
removed compute_x_body_integral functions as this migrated to qc_base - Update ci_pyquil.yml
deactivating for now, issues with forest-sdk docker file - Update pyscf_interface.py
allow charged molecules in pyscf backend
- allow molecule construction with basis= along with basis_set= as this was a common issue
- adding repr method to Variables class for easier serialization and evaluation
- made autograd the default in requirements -- less issues on M1/M2 chips and windows
- provided more information in autograd_imports
allow qpic export from circuit without having to specify the filename keyword explicitly
Co-authored-by: Aranya Chakraborty aranyac@iisc.ac.in
Co-authored-by: Seonghoon Choi seonghoon.choi@utoronto.ca
Co-authored-by: J. S. Kottmann jakob.kottmann@gmail.com