Issue #3 resolved

Segmentation fault using Hegde and HedgeRandom

kiudee
created an issue

Using the combined criteria cHedge and cHedgeRandom will result in a Segmentation fault on some experiments.

Example with two parameters in [1e-6, 10]:

params['n_iterations'] = 500
params['n_init_samples'] = 10
params['sigma_s'] = 100
params['n_iter_relearn'] = 50
params['crit_name'] = "cHedgeRandom(cEI, cOptimisticSampling, cLCB)"
params['crit_params'] = [1.0, 0.1]
params['surr_name'] = "sStudentTProcessNIG"

Log:

- 20:35:01.287157 INFO: Bounds: 
- 20:35:01.287339 INFO: [2](1e-06,1e-06)
- 20:35:01.287584 INFO: [2](10,10)
X: [ 8.90245971  1.85811447], Result: 492
X: [ 4.45277996  5.99521692], Result: 294
X: [ 7.72150201  4.57823926], Result: 413
X: [ 6.81161834  2.8875362 ], Result: 204
X: [ 1.45311934  6.08426487], Result: 431
X: [ 2.0071195   7.36023691], Result: 1019
X: [ 3.04249387  3.20779335], Result: 208
X: [ 9.00353877  0.12157034], Result: 673
X: [ 5.03511196  8.04050777], Result: 861
X: [ 0.03230606  9.49633737], Result: 2969
- 20:36:44.186041 INFO: cOptimisticSampling was selected.
X: [ 5.53497987  3.51851917], Result: 204
- 20:36:54.155929 INFO: Iteration: 1 of 500 | Total samples: 11
- 20:36:54.156056 INFO: Query: [2](5.53498,3.51852)
- 20:36:54.156133 INFO: Query outcome: 204
- 20:36:54.156180 INFO: Best query: [2](6.81162,2.88754)
- 20:36:54.156258 INFO: Best outcome: 204
- 20:36:54.165253 INFO: cLCB was selected.
X: [ 2.85348228  4.57552797], Result: 129
- 20:37:04.078862 INFO: Iteration: 2 of 500 | Total samples: 12
- 20:37:04.079067 INFO: Query: [2](2.85348,4.57553)
- 20:37:04.079154 INFO: Query outcome: 129
- 20:37:04.079230 INFO: Best query: [2](2.85348,4.57553)
- 20:37:04.079286 INFO: Best outcome: 129
Segmentation fault (core dumped)

The target function is the result of a larger simulation, so I cannot include it, but the data points are included in the log.

Comments (6)

  1. Ruben Martinez-Cantin repo owner

    Please, check if the problem has been solved with the last commit (95af9d9).

    For something unrelated, according to literature and my personal experience, the best parameters for LCB are in usually in the range [1.0 - 5.0]. Your selection of 0.1 might be too small (almost no exploration), but this is only in terms of performance.

  2. kiudee reporter

    Sorry for answering so late.

    I’ve used HedgeRandom for several optimization problems now and this error is not occuring anymore. I assume it is fixed.

  3. Log in to comment