Skip to content

Add transform based sampler#40

Open
szabo137 wants to merge 2 commits into
QEDjl-project:devfrom
szabo137:add-transform-based-sampler
Open

Add transform based sampler#40
szabo137 wants to merge 2 commits into
QEDjl-project:devfrom
szabo137:add-transform-based-sampler

Conversation

@szabo137
Copy link
Copy Markdown
Member

@szabo137 szabo137 commented Apr 4, 2026

This PR adds an abstract sampler that operates by transforming random numbers into the sample space.

In this PR, this is based on two interface functions transforming values and weights

_transform_value(sampler,random_number)
_transform_weight(sampler, random_number, sample) 

Where random_number is a number, but also an SVector or NTuple.

To implement this in place, this PR introduces

_transform!(sampler, buffer, random_number_vector)

where buffer is a SampleBuffer.

The Interface is tested using a mock sampler MockTransformbasedSampler, which transforms every random number into a sample filled with a given number and the weight of one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant