Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Interface for using SMCPy without explicit model function #37

Open
bronevet-abc opened this issue Mar 11, 2024 · 1 comment
Open

Interface for using SMCPy without explicit model function #37

bronevet-abc opened this issue Mar 11, 2024 · 1 comment

Comments

@bronevet-abc
Copy link

Hi, I'd like to use SMCPy in a context where the "model to evaluate" is located on one or more remote machines. As such, I need to collect a set of samples to evaluate from SMCPy, send them over for remote evaluation and then get the outcomes and feed them back to SMCPy. It looks like this use-case can be supported via the sample() method in the samplers and direct calls to the methods of SMC. Is that correct? If so, is there an example I could follow to make this work? Thank you!

@peleser
Copy link
Collaborator

peleser commented Mar 12, 2024

Hey @bronevet-abc! Can you give me a little more detail on your problem? While it is technically possible to manually pass results between machines by breaking up some of the sampler functionality, I think this could be a pretty big headache. There are alternatives depending on your exact setup. For one, if you can use MPI to achieve your goal, SMCPy already supports this. See this example. If that doesn't work for you but you have some sort of automated pipeline (e.g., ssh-based) that allows you to send inputs to the machine and return results in an automated fashion, you could wrap that functionality in a model class or build a special MCMC class to handle this. If you're using a cluster with a job submission queue, you may be able to develop a model wrapper that submits jobs to the queue and waits, etc.

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

No branches or pull requests

2 participants