Skip to content

Parallel evaluations #212

Closed as not planned
Closed as not planned

Description

@samyip123

Referencing issue #138, i tried to implement the code mentioned in concurrent.futures and ran into trouble with the code not completing , may i ask if it is possible to implement on concurrent.futures instead of asyncio as referenced by async bayesian optimization example

class hyper_class():

    def __init__(self):
        self.result = None
        self.point = None

    def step(self, input):
       optimizer = input[0]
       model = input[1]
        if self.result is not None:
            optimizer.register(self.point, self.result)
        self.point = optimizer.suggest(utility)
        self.result = model(self.point)

        return None

with concurrent.futures.ProcessPoolExecutor() as executor:
    for _ in range(16):
       executor.submit(hyper_class().step, [optimizer, model])

Activity

  1. fmfn commented on May 1, 2020

    @fmfn
    Member

    Unfortunately I don't currently have the bandwidth to do it, but PRs are more than welcome.

  2. yinrong commented on Jun 15, 2022

    @yinrong

    +1 request this

  3. mrsmee4924 commented on Apr 26, 2024

    @mrsmee4924

    Is this something that is still being worked on or may I take a stab at this? I'm familiar with Dask and learning Ray now so it could be something to look into? Was also looking into the #381 issue as well.

  4. t-muser commented on Apr 27, 2024

    @t-muser
    Member

    Hey @mrsmee4924,

    parallelizing BO is non-trivial as it's generally a sequential algorithm. Before looking into a specific technical implementation, we would need to figure out how to parallelize the suggestion step in a meaningful way. There are related discussions/implementations for this already (#347, #365, #447). Though I think this is probably not the optimal approach (GPyOpt, for example, seems to use this method which might work better.

    All in all, I think some literature review is needed here, before we move forward. Would you be interested in taking this on, too?

  5. t-muser commented on Sep 20, 2024

    @t-muser
    Member

    I currently don't see the value of having such an example. Feel free to re-open if there's a specific need that this would address.

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

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions