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

Problems trying to use SGE with MappingSampler #627

Open
Quim98 opened this issue Jan 18, 2024 · 2 comments
Open

Problems trying to use SGE with MappingSampler #627

Quim98 opened this issue Jan 18, 2024 · 2 comments
Assignees

Comments

@Quim98
Copy link

Quim98 commented Jan 18, 2024

Hello,
I've been trying to upgrade my pyABC scripts from a parallel to a distributed execution of simulations and I've failed to do so for the moment. Since I will execute my script in a cluster that uses an UGE Batch System I thought the best approach would be to use pyabc.sge.SGE() with pyabc.sampler.MappingSampler(). In my code I have the following line:

abc = pyabc.ABCSMC(model, prior, cost_ABC, sampler=pyabc.sampler.MappingSampler(map_=pyabc.sge.SGE(tmp_directory="data/ABC_SMC/tmp", memory='5G', time_h=1, name='pyabc_inf_sim', queue='short-centos79,long-centos79', num_threads=1), mapper_pickles=True), population_size=pyabc.populationstrategy.AdaptivePopulationSize(start_nr_particles=pop_size_init, mean_cv=E_cv, max_population_size=pop_size_max))

Which obviously give the error 'SGE' object is not callable. Reading the documentation it seems i should use the .map(function, array) method after calling pyabc.sge.SGE but then I don't know which array should I input? Shouldn't this array be the different parameter inputs found in a population at a certain time step, so it's not an input I should specify now, no? Am I missing something else? Maybe it would be nice to have an example on how to implement pyabc.sge.SGE() with pyabc.sampler.MappingSampler(). For the rest of things I used pyABC I found the documentation to be very informative though so kudos to all the developers!! 💯

Thank you very much in advance,
Quim

@stephanmg
Copy link
Collaborator

Hi, could you post your ~/.parallel configuration file?

@stephanmg stephanmg self-assigned this Jan 24, 2024
@stephanmg
Copy link
Collaborator

Ping @Quim98

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

No branches or pull requests

2 participants