befelix / SafeOpt

Safe Bayesian Optimization

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

plot_3d=True

pengz1234 opened this issue · comments

Hi. Your algorithm is pretty good and it's very useful in many cases.
But,there is an error:"TypeError: object of type 'numpy.float64' has no len()." when i try to change plot_3d=False to True in 2d_example.n
It's not a big matter in Jupyter notebook(In jupyter it can still display the 3D function images),but it is unexecutable in Pycham.
Do you know how to make it?
Thanks.

I'm confused - so the code works in the notebook but fails in Pycharm? If so, it's probably a problem with the matplotlib backend.

I'm confused - so the code works in the notebook but fails in Pycharm? If so, it's probably a problem with the matplotlib backend.

There is the same error in both Jupyter notebook and Pycharm,but it can still display the 3D function image in notebook and it's dosen‘t work in Pycharm.
I change '.ipynb' to '.py' so that i can excute the code in Pycharm,but it stopped when it occured the error.