HIPS / Spearmint

Spearmint Bayesian optimization codebase
Other
1.55k stars 329 forks source link

It is not possible to run several instances of spearmint simultaneously. #85

Open jogonba2 opened 8 years ago

jogonba2 commented 8 years ago

I'm trying to run several instances of spearmint in parallel at the same pc and only one of them work, the others are blocked showing "Using database at localhost".

¿Is there any method for execute spearmint in this way?. Thanks.

saleha1wer commented 2 years ago

You can do it if you specify a different port (for every run you need) in spearmint/utils/database/mongodb.py:

self.client = pymongo.MongoClient(database_address, port= 13786) // change 13786 to a different TCP port for every instance you want to run

Make sure you set the same port when you start the mongdb instance:

mongod --port 13786 --fork --logpath <path/to/logfile\> --dbpath <path/to/dbfolder\>