Pandarallel支持很好的进度小部件。但是,在使用Google Colab时,我无法让它们出现。我得到的输出是这样的:

这段本应启用小部件的代码在我的笔记本中成功运行(在我使用任何并行调用之前):
%pip install pandas librosa pandarallel jupyterlab jupyter_contrib_nbextensions jupyter-client -U
!jupyter nbextension enable --py widgetsnbextension
!jupyter labextension install @jupyter-widgets/jupyterlab-manager --no-build我遗漏了什么?
更新:当我将Google Colab连接到本地Jupyter实例时,我看到了正确的小部件。只有在Google Jupyter实例上运行时才会出现问题。
发布于 2020-11-14 08:13:12
is_notebook_lab检查范围太窄,您可以覆盖它并强制为true:
from pandarallel.utils import progress_bars
progress_bars.is_notebook_lab = lambda : True对于安装,你应该只需要做%pip install pandarallel-上面的扩展安装步骤应该是不需要的。
https://stackoverflow.com/questions/64754814
复制相似问题