-
Notifications
You must be signed in to change notification settings - Fork 261
ValueError when saving model with ARD #125
Comments
yap, it seems like that is the issue. Do you mind having a look to it and make a PR? Should be just a check on the dimensions when saving the results. |
Hi Javier! It may be trickier than that. In
The issue is in the header as it does not contain the correct number of parameter names. |
Can you please post the whole output of the error, with the stack trace? That would clearly indicate where the error is coming from. |
Here is the output, but as I said the error actually comes from
|
Here is a minimal example:
I think @mozerfazer is correct in his diagnosis. The issue is that the parameters are collected and saved by GPyOpt by getting the underlying GPy models param_array. The param_array is an array of all the models parameters. For models with ARD a subset of this array will be the lengthscales of the model, unfortunately these are collected under one model parameter name 'Mat52.lengthscale'. It doesn't appear like it will be specific to ARD models, just any model parameters that are stored as a vector.
makes it clear what the issue is - you are currently unpacking 2 value of the lengthscale under one column name 'Mat52.lengthscale'. I'm not familiar with how the models are loaded in GPyOpt, but I believe simply replacing GPModel's function as below would help:
I can make a PR if that is helpful. |
@alansaul sounds about right. Please go for it! |
Hi! When saving an ARD=True model using the 'models_file' argument, I get a ValueError that reads:
ValueError: Wrong number of items passed 20, placement implies 4
This doesn't happen when ARD=False. My script is:
Maybe the saving function is not keeping into account the larger number of parameters when ARD=True.
The text was updated successfully, but these errors were encountered: