Datasets:

Languages:
English
License:

Dataset Viewer issue

#1
by albertvillanova HF staff - opened
BigScience Biomedical Datasets org

The dataset viewer is not working.

Error details:

Error code:   SplitsNamesError
Exception:    ModuleNotFoundError
Message:      No module named 'datasets_modules.datasets.bigscience-biomedical--geokhoj_v1'
Traceback:    Traceback (most recent call last):
                File "/src/workers/datasets_based/src/datasets_based/workers/splits.py", line 127, in compute_splits_response
                  split_full_names = get_dataset_split_full_names(dataset=dataset, use_auth_token=use_auth_token)
                File "/src/workers/datasets_based/src/datasets_based/workers/splits.py", line 89, in get_dataset_split_full_names
                  for config in sorted(get_dataset_config_names(path=dataset, use_auth_token=use_auth_token))
                File "/src/workers/datasets_based/.venv/lib/python3.9/site-packages/datasets/inspect.py", line 317, in get_dataset_config_names
                  builder_cls = import_main_class(dataset_module.module_path)
                File "/src/workers/datasets_based/.venv/lib/python3.9/site-packages/datasets/load.py", line 115, in import_main_class
                  module = importlib.import_module(module_path)
                File "/usr/local/lib/python3.9/importlib/__init__.py", line 127, in import_module
                  return _bootstrap._gcd_import(name[level:], package, level)
                File "<frozen importlib._bootstrap>", line 1030, in _gcd_import
                File "<frozen importlib._bootstrap>", line 1007, in _find_and_load
                File "<frozen importlib._bootstrap>", line 972, in _find_and_load_unlocked
                File "<frozen importlib._bootstrap>", line 228, in _call_with_frames_removed
                File "<frozen importlib._bootstrap>", line 1030, in _gcd_import
                File "<frozen importlib._bootstrap>", line 1007, in _find_and_load
                File "<frozen importlib._bootstrap>", line 972, in _find_and_load_unlocked
                File "<frozen importlib._bootstrap>", line 228, in _call_with_frames_removed
                File "<frozen importlib._bootstrap>", line 1030, in _gcd_import
                File "<frozen importlib._bootstrap>", line 1007, in _find_and_load
                File "<frozen importlib._bootstrap>", line 984, in _find_and_load_unlocked
              ModuleNotFoundError: No module named 'datasets_modules.datasets.bigscience-biomedical--geokhoj_v1'

I have forced the refresh and I get this error.

cc @severo , any hint?

There was a temporary issue, you're right. I think it's fixed now, I refreshed the dataset manually.

Capture d’écran 2022-12-09 à 00.38.46.png

BigScience Biomedical Datasets org
edited Dec 9, 2022

The underlying issue is still present, we're looking at it.

It should now be fixed. We're updating all the remaining affected datasets.

BigScience Biomedical Datasets org

@severo there is still an issue with the viewer for the configuration "geokhoj_v1_source": https://huggingface.co/datasets/bigscience-biomedical/geokhoj_v1/viewer/geokhoj_v1_source/train

Dict key must be str

Error code:   UnexpectedError

I'm not able to reproduce this issue locally...

The issue comes when the features are converted as JSON, in particular:

"label": datasets.features.ClassLabel(
  names={0: "control", 1: "perturbation"}
),

https://huggingface.co/datasets/bigbio/geokhoj_v1/blob/main/geokhoj_v1.py#L102

In JSON, the keys must be strings, and here they are numbers, which makes ORJSON fail when dumping the JSON.

I understand that it could be fixed with:

"label": datasets.features.ClassLabel(
  names=["control", "perturbation"]
),
BigScience Biomedical Datasets org

Thanks for the fix, @severo .
And sorry: I misunderstood it was exclusively an issue with the viewer, not with the loading script...
Once merged, your PR should fix this issue.

I think there may be a few datasets that are still not working and could benefit from the same refresh?

It's OK now. One has an error, but it seems to be due to its hosting (https://huggingface.co/datasets/bigbio/chia/viewer/chia_bigbio_kb/train - cc @albertvillanova ). Anyway, better to discuss it on that repo instead of here.

BigScience Biomedical Datasets org

Closed by #2.

albertvillanova changed discussion status to closed

Sign up or log in to comment