Closed hgl71964 closed 1 year ago
Hi, I get the same error when executing the example
AttributeError Traceback (most recent call last)
Cell In[12], line 15
13 for i in range(3):
14 rec_x = hebo_seq.suggest(n_suggestions=1)
---> 15 hebo_seq.observe(rec_x, obj(rec_x))
16 print('After %d iterations, best obj is %.2f' % (i, opt.y.min()))
File ~/miniconda3/envs/bo-drl-2hp-env/lib/python3.10/site-packages/hebo/optimizers/hebo.py:201, in HEBO.observe(self, X, y)
199 XX = X.iloc[valid_id]
200 yy = y[valid_id].reshape(-1, 1)
--> 201 self.X = self.X.append(XX, ignore_index = True)
202 self.y = np.vstack([self.y, yy])
File ~/miniconda3/envs/bo-drl-2hp-env/lib/python3.10/site-packages/pandas/core/generic.py:5989, in NDFrame.__getattr__(self, name)
5982 if (
5983 name not in self._internal_names_set
5984 and name not in self._metadata
5985 and name not in self._accessors
5986 and self._info_axis._can_hold_identifiers_and_holds_name(name)
5987 ):
5988 return self[name]
-> 5989 return object.__getattribute__(self, name)
AttributeError: 'DataFrame' object has no attribute 'append'
I think it is because append is deprecated from pandas v.1.4.0 and completely removed from pandas v2.0.0
Thank you
This is fixed in 0.3.5, run pip install git+https://github.com/huawei-noah/HEBO.git#subdirectory=HEBO
to get the latest version
Hi,
I pull the repo and install via
then I run the Demo example, but it fails to execute with the following error
My guess is there is some data conversion wrong. Could anyone fix that?
Thanks!