netket.sampler.samples¶
-
netket.sampler.
samples
(sampler, machine, parameters, *, state=None, chain_length=1)[source]¶ Returns a generator sampling chain_length elements along the chains.
- Parameters
sampler (
Sampler
) – The Monte Carlo sampler.machine (
Union
[Callable
,Module
]) – The model or Callable to sample from (if it’s a function it should have the signaturef(parameters, σ) -> jnp.ndarray
).parameters (
Any
) – The PyTree of parameters of the model.state (
Optional
[SamplerState
]) – current state of the sampler. If None, then initialises it.chain_length (
int
) – (default=1), the length of the chains.
- Return type