sklearn package with AttributeError: 'MissingValues' object has no attribute 'to_list' I am currently trying to reproduce this tutorial on building a CNN based time series classifier for human activity recognition.
My setup is:

Windows 10, Pycharm IDE with a new project for this tutorial, Python3.6, freshly installed the needed packages.

For reproducing, you need to download the activity data here and place it in the project directory under ./Data
The code executes the graphs well until this position:
df[LABEL] = le.fit_transform(df[&quot;activity&quot;].values.ravel())

and throws following error:
Traceback (most recent call last):
  File &quot;C:/Users/bobin/PycharmProjects/Mussel/cnn_musseltest.py&quot;, line 226, in &lt;module&gt;
    df[LABEL] = le.fit_transform(df[&quot;activity&quot;].values.ravel())
  File &quot;C:\Users\bobin\PycharmProjects\Mussel\venv\lib\site-packages\sklearn\preprocessing\_label.py&quot;, line 117, in fit_transform
    self.classes_, y = _unique(y, return_inverse=True)
  File &quot;C:\Users\bobin\PycharmProjects\Mussel\venv\lib\site-packages\sklearn\utils\_encode.py&quot;, line 31, in _unique
    return _unique_python(values, return_inverse=return_inverse)
  File &quot;C:\Users\bobin\PycharmProjects\Mussel\venv\lib\site-packages\sklearn\utils\_encode.py&quot;, line 133, in _unique_python
    uniques.extend(missing_values.to_list())
AttributeError: 'MissingValues' object has no attribute 'to_list'

Related threads that have not helped me so far:
Link1
Link2
The problem was with the pandas version. I've used Python3.6 as interpreter and pycharm would only let me install version 0.25 pandas. Now I am on Python3.8 and pandas 1.2.3 and the minimum code example provided by @Oxbowerce works now. I'll be more careful with checking the dependencies in future.
The sketch goes into the epochs now, there was just a minor labelling error:
Traceback (most recent call last):
  File &quot;C:/Users/bobin/PycharmProjects/Mussel/cnn_musseltest.py&quot;, line 348, in &lt;module&gt;
    plt.plot(history.history['acc'], &quot;g--&quot;, label=&quot;Accuracy of training data&quot;)
KeyError: 'acc'

Renaming 'acc' to 'accuracy' and val_acc to val_accuracy helped, as stated in the warning log.
WARNING:tensorflow:Early stopping conditioned on metric `acc` which is not available. Available metrics are: loss,accuracy,val_loss,val_accuracy