NetKet 3.22.1__tar.gz → 3.22.3__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {netket-3.22.1 → netket-3.22.3}/PKG-INFO +1 -1
- {netket-3.22.1 → netket-3.22.3}/netket/_src/observable/vscore.py +62 -13
- {netket-3.22.1 → netket-3.22.3}/netket/_version.py +2 -2
- {netket-3.22.1 → netket-3.22.3}/netket/utils/_tips.py +2 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/model_frameworks/base.py +17 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/model_frameworks/equinox.py +13 -1
- {netket-3.22.1 → netket-3.22.3}/netket/utils/model_frameworks/nnx.py +5 -0
- {netket-3.22.1 → netket-3.22.3}/.gitignore +0 -0
- {netket-3.22.1 → netket-3.22.3}/LICENSE +0 -0
- {netket-3.22.1 → netket-3.22.3}/README.md +0 -0
- {netket-3.22.1 → netket-3.22.3}/docs/sphinx_extensions/netket_citations.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/callbacks/auto_chunk_size.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/callbacks/auto_slurm_requeue.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/callbacks/base.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/callbacks/callback_list.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/callbacks/convergence_stopping.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/callbacks/early_stopping.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/callbacks/invalid_loss_stopping.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/callbacks/legacy_wrappers.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/callbacks/observables.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/callbacks/progressbar.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/callbacks/save_state.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/callbacks/stop_at_time.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/callbacks/timeout.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/driver/abstract_dynamics_driver.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/driver/abstract_optimization_driver.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/driver/abstract_variational_driver.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/driver/abstract_variational_driver_old.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/driver/infidelity_sr.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/driver/vmc_sr.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/logging/base.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/logging/hdf5_log.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/logging/json_log.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/logging/mlflow_log.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/logging/runtime_log.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/logging/state_log.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/logging/tensorboard.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/ngd/kwargs.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/ngd/sr.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/ngd/sr_srt_common.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/ngd/srt.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/ngd/srt_onthefly.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/nn/apply_operator/functional.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/nn/apply_operator/linen.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/nn/apply_operator/nnx.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/nn/freeze/api.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/nn/freeze/common.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/nn/freeze/functional.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/nn/freeze/linen.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/nn/freeze/nnx.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/observable/correlator/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/observable/correlator/correlator.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/observable/correlator/expect.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/observable/infidelity/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/observable/infidelity/exact.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/observable/infidelity/expect.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/observable/infidelity/infidelity_operator.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/observable/renyi2/S2_operator.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/observable/renyi2/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/observable/renyi2/exact.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/observable/renyi2/expect.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/observable/variance/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/observable/variance/exact.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/observable/variance/expect.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/observable/variance/variance_operator.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/operator/normal_order_utils.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/operator/particle_number_conserving_fermionic/conversion.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/operator/particle_number_conserving_fermionic/fermihubbard.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/operator/particle_number_conserving_fermionic/kernels.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/operator/particle_number_conserving_fermionic/operator_data.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/operator/particle_number_conserving_fermionic/operators.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/operator/permutation/base.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/operator/permutation/construct.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/operator/permutation/fermion.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/operator/permutation/spin.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/operator/permutation/trace_utils.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/operator/pyscf_api.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/operator/pyscf_utils.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/operator/spin_flip.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/solvers/nan_fallback.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/stats/local_estimators.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/stats/online_stats/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/stats/online_stats/accumulator.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/stats/online_stats/accumulator_batch.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/stats/online_stats/kernels.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/stats/online_stats/operations.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/symmetry/canonical_representation.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/symmetry/labeled_representation.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/symmetry/labeled_representation_coset_filter.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/symmetry/representation.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/symmetry/representation_construction.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/symmetry/spin_flip_representation.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/symmetry/translation_coset_filter.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/symmetry/translation_representation.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/vqs/check_mc_convergence.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/vqs/expect_to_precision.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/vqs/fermion_mf/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/vqs/fermion_mf/expectation.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/vqs/fermion_mf/qgt.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/vqs/fermion_mf/state.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/vqs/freeze_vstate.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/vqs/plot_mc_convergence.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/_src/vqs/transformed_vstate.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/callbacks.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/driver/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/driver/steady_state.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/driver/vmc.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/errors.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/exact.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/driver/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/driver/tdvp.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/driver/tdvp_common.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/driver/tdvp_schmitt.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/dynamics/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/dynamics/_integrator.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/dynamics/_integrator_params.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/dynamics/_integrator_state.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/dynamics/_rk/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/dynamics/_rk/_solver.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/dynamics/_rk/_tableau.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/dynamics/_solver.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/dynamics/_utils.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/geometry/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/geometry/cell.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/hilbert/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/hilbert/continuous_hilbert.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/hilbert/particle.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/hilbert/random/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/hilbert/random/particle.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/logging/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/models/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/models/fast_rnn.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/models/rnn.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/nn/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/nn/rnn/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/nn/rnn/cells.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/nn/rnn/layers.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/nn/rnn/layers_fast.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/nn/rnn/ordering.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/observable/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/operator/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/operator/pyscf.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/qsr/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/qsr/dataset.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/qsr/driver.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/qsr/logic_helpers.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/vqs/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/experimental/vqs/io.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/graph/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/graph/_lattice_draw.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/graph/_lattice_edge_logic.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/graph/abstract_graph.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/graph/common_lattices.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/graph/graph.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/graph/lattice.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/graph/space_group.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/abstract_hilbert.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/constraint/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/constraint/base.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/constraint/multiple.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/constraint/sum.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/constraint/sum_partition.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/discrete_hilbert.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/doubled_hilbert.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/fock.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/homogeneous.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/index/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/index/base.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/index/constrained_generic.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/index/constrained_sum.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/index/constrained_sum_partitions.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/index/unconstrained.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/index/uniform_tensor.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/qubit.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/random/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/random/base.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/random/doubled.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/random/fock.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/random/homogeneous.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/random/qubit.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/random/tensor_hilbert.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/spin.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/spin_orbital_fermions.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/tensor_hilbert.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/hilbert/tensor_hilbert_discrete.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/_chunk_utils.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/_compat.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/_expect.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/_grad.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/_jacobian/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/_jacobian/default_mode.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/_jacobian/jacobian_dense.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/_jacobian/jacobian_pytree.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/_jacobian/logic.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/_math.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/_ntk/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/_ntk/logic.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/_ntk/utils.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/_scanmap.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/_sort.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/_sparse.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/_utils_dtype.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/_utils_random.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/_utils_tree.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/_vjp.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/_vjp_chunked.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/_vmap_chunked.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/lax.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/sharding/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/sharding/debug.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/sharding/fixed_sharding_decorator.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/sharding/fixed_sharding_utils.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/jax/sharding/flexible_sharding.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/logging.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/models/README.md +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/models/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/models/autoreg.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/models/deepset.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/models/equivariant.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/models/fast_autoreg.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/models/full_space.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/models/gaussian.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/models/jastrow.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/models/mlp.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/models/ndm.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/models/rbm.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/models/slater.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/models/tensor_networks/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/models/tensor_networks/mpdo.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/models/tensor_networks/mps.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/models/utils.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/nn/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/nn/activation.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/nn/apply_operator.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/nn/blocks/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/nn/blocks/deepset.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/nn/blocks/mlp.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/nn/blocks/symmetry_sum.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/nn/fast_masked_linear.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/nn/masked_linear.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/nn/symmetric_linear.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/nn/utils.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/observable.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_abstract_observable.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_abstract_operator.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_abstract_super_operator.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_bose_hubbard/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_bose_hubbard/base.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_bose_hubbard/jax.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_bose_hubbard/numba.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_continuous_operator.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_discrete_operator.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_discrete_operator_jax.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_embed/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_embed/base.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_embed/discrete_jax_operator.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_embed/discrete_operator.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_embed/operator.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_fermion2nd/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_fermion2nd/base.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_fermion2nd/jax.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_fermion2nd/numba.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_fermion2nd/utils.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_graph_operator.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_hamiltonian.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_heisenberg.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_ising/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_ising/base.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_ising/jax.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_ising/numba.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_kinetic.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_lazy.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_local_liouvillian.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_local_operator/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_local_operator/base.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_local_operator/compile_helpers.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_local_operator/convert.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_local_operator/helpers.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_local_operator/jax.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_local_operator/numba.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_pauli_strings/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_pauli_strings/base.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_pauli_strings/jax.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_pauli_strings/numba.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_potential.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_prod/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_prod/base.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_prod/discrete_jax_operator.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_prod/discrete_operator.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_prod/operator.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_sum/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_sum/base.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_sum/continuous.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_sum/discrete_jax_operator.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_sum/discrete_operator.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/_sum/operator.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/boson.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/fermion.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/permutation.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/operator/spin.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/optimizer/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/optimizer/linear_operator.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/optimizer/preconditioner.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/optimizer/qgt/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/optimizer/qgt/common.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/optimizer/qgt/default.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/optimizer/qgt/qgt_jacobian.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/optimizer/qgt/qgt_jacobian_common.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/optimizer/qgt/qgt_jacobian_dense.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/optimizer/qgt/qgt_jacobian_pytree.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/optimizer/qgt/qgt_onthefly.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/optimizer/qgt/qgt_onthefly_logic.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/optimizer/solver/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/optimizer/solver/solvers.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/optimizer/sr.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/sampler/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/sampler/autoreg.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/sampler/base.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/sampler/exact.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/sampler/metropolis.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/sampler/metropolis_numpy.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/sampler/parallel_tempering.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/sampler/rules/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/sampler/rules/base.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/sampler/rules/continuous_gaussian.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/sampler/rules/custom_numpy.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/sampler/rules/exchange.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/sampler/rules/fermion_2nd.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/sampler/rules/fixed.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/sampler/rules/global_flip_rule.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/sampler/rules/hamiltonian.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/sampler/rules/hamiltonian_numpy.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/sampler/rules/langevin.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/sampler/rules/local.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/sampler/rules/local_numpy.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/sampler/rules/multiple.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/sampler/rules/tensor.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/stats/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/stats/_autocorr.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/stats/mc_stats.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/stats/mc_stats_old.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/stats/mpi_stats.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/symmetry/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/symmetry/group/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/tools/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/tools/_common.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/tools/_cpu_info.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/tools/check_mpi.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/tools/djaxrun.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/tools/info.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/_dependencies_check.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/_serialization.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/api_utils.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/array.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/citations/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/citations/cli.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/citations/core.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/citations/docs.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/citations/internal_citations.bib +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/config_flags.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/deprecation.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/dispatch.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/display/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/display/repr.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/float.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/group/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/group/_group.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/group/_permutation_group.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/group/_point_group.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/group/_semigroup.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/group/axial.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/group/cubic.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/group/icosa.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/group/planar.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/history/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/history/accum.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/history/history.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/history/history_dict.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/holomorphic.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/iterators.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/jax.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/model_frameworks/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/model_frameworks/flax.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/model_frameworks/flax_bound.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/model_frameworks/haiku.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/model_frameworks/jax.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/model_frameworks/nnx_wrapped.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/moduletools.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/mpi/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/mpi/mpi.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/mpi/primitives.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/numbers.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/optional_deps.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/partial.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/seed.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/static_number.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/static_range.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/struct/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/struct/dataclass.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/struct/fields.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/struct/pytree.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/struct/pytree_serialization_sharding.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/struct/utils.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/summation.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/timing.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/tree_walk.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/types.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/utils/version_check.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/vqs/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/vqs/base.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/vqs/full_summ/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/vqs/full_summ/expect.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/vqs/full_summ/state.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/vqs/mc/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/vqs/mc/common.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/vqs/mc/kernels.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/vqs/mc/mc_mixed_state/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/vqs/mc/mc_mixed_state/expect.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/vqs/mc/mc_mixed_state/expect_chunked.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/vqs/mc/mc_mixed_state/expect_grad.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/vqs/mc/mc_mixed_state/state.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/vqs/mc/mc_state/__init__.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/vqs/mc/mc_state/expect.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/vqs/mc/mc_state/expect_chunked.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/vqs/mc/mc_state/expect_forces.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/vqs/mc/mc_state/expect_forces_chunked.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/vqs/mc/mc_state/expect_grad.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/vqs/mc/mc_state/expect_grad_chunked.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/vqs/mc/mc_state/local_estimators.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/netket/vqs/mc/mc_state/state.py +0 -0
- {netket-3.22.1 → netket-3.22.3}/pyproject.toml +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: NetKet
|
|
3
|
-
Version: 3.22.
|
|
3
|
+
Version: 3.22.3
|
|
4
4
|
Summary: Netket : Machine Learning toolbox for many-body quantum systems.
|
|
5
5
|
Project-URL: homepage, https://www.netket.org
|
|
6
6
|
Project-URL: documentation, https://netket.readthedocs.io/en/latest/#
|
|
@@ -20,6 +20,7 @@ import jax
|
|
|
20
20
|
import jax.numpy as jnp
|
|
21
21
|
|
|
22
22
|
from netket._src.stats.local_estimators import LocalEstimatorsBatch
|
|
23
|
+
from netket.jax import HashablePartial
|
|
23
24
|
from netket.operator import AbstractOperator
|
|
24
25
|
from netket.operator._abstract_observable import AbstractObservable
|
|
25
26
|
from netket.stats import Stats
|
|
@@ -34,27 +35,61 @@ from netket.vqs import (
|
|
|
34
35
|
from netket.vqs.mc.common import local_estimators
|
|
35
36
|
|
|
36
37
|
|
|
37
|
-
def _vscore_combinator(trace_diagonal: float):
|
|
38
|
-
|
|
39
|
-
return (mu[1] - mu[0] ** 2) / (mu[0] - trace_diagonal) ** 2
|
|
38
|
+
def _vscore_combinator(trace_diagonal: float, N: int, mu):
|
|
39
|
+
return N * (mu[1] - mu[0] ** 2) / (mu[0] - trace_diagonal) ** 2
|
|
40
40
|
|
|
41
|
-
|
|
41
|
+
|
|
42
|
+
def _vscore_n_dof(hilbert) -> int:
|
|
43
|
+
r"""Estimate the V-score normalisation :math:`N` (number of degrees of
|
|
44
|
+
freedom) for a given Hilbert space, following arXiv:2302.04919.
|
|
45
|
+
|
|
46
|
+
For spin, qubit and bosonic lattice models this is the number of sites/modes
|
|
47
|
+
(``hilbert.size``). For fermionic systems the V-score is normalised by the
|
|
48
|
+
total particle number, so we use ``SpinOrbitalFermions.n_fermions`` instead
|
|
49
|
+
of ``hilbert.size`` (which counts spin-orbitals).
|
|
50
|
+
"""
|
|
51
|
+
from netket.hilbert import SpinOrbitalFermions
|
|
52
|
+
|
|
53
|
+
if isinstance(hilbert, SpinOrbitalFermions):
|
|
54
|
+
if hilbert.n_fermions is None:
|
|
55
|
+
raise ValueError(
|
|
56
|
+
"Cannot infer the V-score normalisation `N` for a "
|
|
57
|
+
"SpinOrbitalFermions space with unfixed particle number. "
|
|
58
|
+
"Pass `N=...` explicitly to VScore: the V-score is normalised by "
|
|
59
|
+
"the total particle number (see arXiv:2302.04919)."
|
|
60
|
+
)
|
|
61
|
+
return hilbert.n_fermions
|
|
62
|
+
return hilbert.size
|
|
42
63
|
|
|
43
64
|
|
|
44
65
|
class VScore(AbstractObservable):
|
|
45
66
|
r"""
|
|
46
|
-
Observable computing the V-score of a quantum operator :math:`H
|
|
67
|
+
Observable computing the V-score of a quantum operator :math:`H`, as defined
|
|
68
|
+
in `Wu et al., arXiv:2302.04919 <https://arxiv.org/abs/2302.04919>`_:
|
|
47
69
|
|
|
48
70
|
.. math::
|
|
49
71
|
|
|
50
72
|
V_{\mathrm{score}} =
|
|
51
|
-
\frac{
|
|
73
|
+
\frac{N\,\mathrm{Var}(H)}{(\langle H \rangle - E_\infty)^2}
|
|
52
74
|
=
|
|
53
|
-
\frac{\langle H^2 \rangle - \langle H \rangle^2}
|
|
54
|
-
{(\langle H \rangle - \
|
|
75
|
+
\frac{N\,(\langle H^2 \rangle - \langle H \rangle^2)}
|
|
76
|
+
{(\langle H \rangle - E_\infty)^2}.
|
|
77
|
+
|
|
78
|
+
The ``trace_diagonal`` parameter is the infinite-temperature reference energy
|
|
79
|
+
:math:`E_\infty := \mathrm{Tr}(H) / \dim(\mathcal{H})` entering the denominator
|
|
80
|
+
(it is :math:`0` for traceless Hamiltonians, e.g. spin models built from Pauli
|
|
81
|
+
operators).
|
|
55
82
|
|
|
56
|
-
The
|
|
57
|
-
the
|
|
83
|
+
The prefactor :math:`N` is the number of degrees of freedom. By default it is
|
|
84
|
+
inferred from the Hilbert space:
|
|
85
|
+
|
|
86
|
+
* for spin, qubit and bosonic lattice models, ``N = hilbert.size`` (number of
|
|
87
|
+
sites/modes);
|
|
88
|
+
* for fermionic systems (:class:`~netket.hilbert.SpinOrbitalFermions`),
|
|
89
|
+
``N`` is the total particle number ``hilbert.n_fermions``.
|
|
90
|
+
|
|
91
|
+
For composite or exotic Hilbert spaces, or to use a different convention, pass
|
|
92
|
+
``N`` explicitly.
|
|
58
93
|
"""
|
|
59
94
|
|
|
60
95
|
def __init__(
|
|
@@ -62,6 +97,7 @@ class VScore(AbstractObservable):
|
|
|
62
97
|
operator: AbstractOperator,
|
|
63
98
|
*,
|
|
64
99
|
trace_diagonal: float,
|
|
100
|
+
N: int | None = None,
|
|
65
101
|
):
|
|
66
102
|
super().__init__(operator.hilbert)
|
|
67
103
|
|
|
@@ -72,6 +108,7 @@ class VScore(AbstractObservable):
|
|
|
72
108
|
self._operator = operator
|
|
73
109
|
self._operator_squared = operator @ operator
|
|
74
110
|
self._trace_diagonal = float(trace_diagonal)
|
|
111
|
+
self._N = int(N) if N is not None else _vscore_n_dof(operator.hilbert)
|
|
75
112
|
|
|
76
113
|
@property
|
|
77
114
|
def operator(self) -> AbstractOperator:
|
|
@@ -85,8 +122,16 @@ class VScore(AbstractObservable):
|
|
|
85
122
|
def trace_diagonal(self) -> float:
|
|
86
123
|
return self._trace_diagonal
|
|
87
124
|
|
|
125
|
+
@property
|
|
126
|
+
def N(self) -> int:
|
|
127
|
+
"""The number of degrees of freedom normalising the V-score."""
|
|
128
|
+
return self._N
|
|
129
|
+
|
|
88
130
|
def __repr__(self):
|
|
89
|
-
return
|
|
131
|
+
return (
|
|
132
|
+
f"VScore(op={self.operator}, trace_diagonal={self.trace_diagonal}, "
|
|
133
|
+
f"N={self.N})"
|
|
134
|
+
)
|
|
90
135
|
|
|
91
136
|
|
|
92
137
|
@local_estimators.dispatch
|
|
@@ -119,7 +164,9 @@ def vscore_local_estimators(
|
|
|
119
164
|
data = jnp.stack([O_loc, O2_loc], axis=-1).reshape(n_chains, -1, 2)
|
|
120
165
|
return LocalEstimatorsBatch(
|
|
121
166
|
data=data,
|
|
122
|
-
combinator=
|
|
167
|
+
combinator=HashablePartial(
|
|
168
|
+
_vscore_combinator, vscore_op.trace_diagonal, vscore_op.N
|
|
169
|
+
),
|
|
123
170
|
)
|
|
124
171
|
|
|
125
172
|
|
|
@@ -144,6 +191,7 @@ def expect(vstate: FullSumState, vscore_op: VScore): # noqa: F811
|
|
|
144
191
|
operator_mtrx,
|
|
145
192
|
operator_squared_mtrx,
|
|
146
193
|
vscore_op.trace_diagonal,
|
|
194
|
+
vscore_op.N,
|
|
147
195
|
)
|
|
148
196
|
|
|
149
197
|
|
|
@@ -156,6 +204,7 @@ def _expect_vscore_fs(
|
|
|
156
204
|
operator_mtrx,
|
|
157
205
|
operator_squared_mtrx,
|
|
158
206
|
trace_diagonal,
|
|
207
|
+
N,
|
|
159
208
|
):
|
|
160
209
|
W = {"params": params, **model_state}
|
|
161
210
|
|
|
@@ -164,6 +213,6 @@ def _expect_vscore_fs(
|
|
|
164
213
|
|
|
165
214
|
E_mean = (state.conj() @ (operator_mtrx @ state)).real
|
|
166
215
|
E2_mean = (state.conj() @ (operator_squared_mtrx @ state)).real
|
|
167
|
-
vscore = (E2_mean - E_mean**2) / (E_mean - trace_diagonal) ** 2
|
|
216
|
+
vscore = N * (E2_mean - E_mean**2) / (E_mean - trace_diagonal) ** 2
|
|
168
217
|
|
|
169
218
|
return Stats(mean=vscore, error_of_mean=0.0, variance=0.0)
|
|
@@ -18,7 +18,7 @@ version_tuple: tuple[int | str, ...]
|
|
|
18
18
|
commit_id: str | None
|
|
19
19
|
__commit_id__: str | None
|
|
20
20
|
|
|
21
|
-
__version__ = version = '3.22.
|
|
22
|
-
__version_tuple__ = version_tuple = (3, 22,
|
|
21
|
+
__version__ = version = '3.22.3'
|
|
22
|
+
__version_tuple__ = version_tuple = (3, 22, 3)
|
|
23
23
|
|
|
24
24
|
__commit_id__ = commit_id = None
|
|
@@ -18,6 +18,8 @@ import random
|
|
|
18
18
|
import sys
|
|
19
19
|
|
|
20
20
|
TIPS = [
|
|
21
|
+
# News
|
|
22
|
+
"NetKet 3.22 has plenty of new stuff! Check it out at https://www.netket.org/posts/07-netket322/",
|
|
21
23
|
# Drivers
|
|
22
24
|
"Prefer the new nk.driver.VMC_SR over VMC which supports minSR and SPRING.",
|
|
23
25
|
"Use driver.run(..., timeit=True) to know where your dominant cost is.",
|
|
@@ -31,6 +31,23 @@ class ModuleFramework(abc.ABC):
|
|
|
31
31
|
"""
|
|
32
32
|
return False
|
|
33
33
|
|
|
34
|
+
@staticmethod
|
|
35
|
+
def wrapped_model_class(static_model: Any) -> type:
|
|
36
|
+
"""
|
|
37
|
+
Returns the concrete user-defined model class, given the (possibly wrapped)
|
|
38
|
+
static module stored in :attr:`MCState._model`.
|
|
39
|
+
|
|
40
|
+
For flax-like frameworks the static module *is* the model, so this returns
|
|
41
|
+
its type. Frameworks that wrap the model into a static container (such as
|
|
42
|
+
``flax.nnx`` or ``equinox``) override this to peek inside the wrapper and
|
|
43
|
+
return the original class.
|
|
44
|
+
|
|
45
|
+
This lets serialization code recover the original model class without
|
|
46
|
+
unwrapping (which would require the variables), e.g. to dispatch on whether
|
|
47
|
+
a custom serializer is registered for that class.
|
|
48
|
+
"""
|
|
49
|
+
return type(static_model)
|
|
50
|
+
|
|
34
51
|
@staticmethod
|
|
35
52
|
@abc.abstractmethod
|
|
36
53
|
def is_loaded() -> bool:
|
|
@@ -56,7 +56,14 @@ class EquinoxWrapper:
|
|
|
56
56
|
module = self.recompose(variables)
|
|
57
57
|
fun = getattr(module, method)
|
|
58
58
|
|
|
59
|
-
|
|
59
|
+
# Only forward a `key` to the model if one was actually provided.
|
|
60
|
+
# Passing `key=None` unconditionally breaks Equinox modules whose
|
|
61
|
+
# `__call__` does not declare a `key` argument (e.g. simple models
|
|
62
|
+
# that do not use randomness).
|
|
63
|
+
if rngs is not None:
|
|
64
|
+
kwargs["key"] = rngs
|
|
65
|
+
|
|
66
|
+
return fun(*args, **kwargs)
|
|
60
67
|
|
|
61
68
|
def recompose(self, variables):
|
|
62
69
|
import equinox as eqx
|
|
@@ -94,6 +101,11 @@ class EquinoxFramework(ModuleFramework):
|
|
|
94
101
|
"""
|
|
95
102
|
return True
|
|
96
103
|
|
|
104
|
+
@staticmethod
|
|
105
|
+
def wrapped_model_class(static_model: "EquinoxWrapper") -> type:
|
|
106
|
+
# The static partition is an instance of the original equinox.Module class.
|
|
107
|
+
return type(static_model.static_module)
|
|
108
|
+
|
|
97
109
|
@staticmethod
|
|
98
110
|
def is_loaded() -> bool:
|
|
99
111
|
return "equinox" in sys.modules
|
|
@@ -107,6 +107,11 @@ class NNXFramework(ModuleFramework):
|
|
|
107
107
|
"""
|
|
108
108
|
return True
|
|
109
109
|
|
|
110
|
+
@staticmethod
|
|
111
|
+
def wrapped_model_class(static_model: "NNXWrapper") -> type:
|
|
112
|
+
# The original nnx.Module class is recorded in the graphdef.
|
|
113
|
+
return _get_graphdef_type(static_model.graphdef)
|
|
114
|
+
|
|
110
115
|
@staticmethod
|
|
111
116
|
def is_loaded() -> bool:
|
|
112
117
|
# this should be not necessary, as netket requires and loads
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{netket-3.22.1 → netket-3.22.3}/netket/_src/operator/particle_number_conserving_fermionic/kernels.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|