Window Dataset - Optimization loop failed: CANCELLED: Operation was cancelled

Hi,

When I run the code below in PyCharm

for window_dataset in dataset:
print([item.numpy() for item in window_dataset])

I get the following message:
W tensorflow/core/data/root_dataset.cc:247] Optimization loop failed: CANCELLED: Operation was cancelled.

It works fine in Google Colab though.

Any suggestion?

Please try again using take API.