Dataset Preview
Duplicate
The full dataset viewer is not available (click to read why). Only showing a preview of the rows.
The dataset generation failed because of a cast error
Error code:   DatasetGenerationCastError
Exception:    DatasetGenerationCastError
Message:      An error occurred while generating the dataset

All the data files must have the same columns, but at some point there are 5 new columns ({'fdc_id', 'acquisition_date', 'state', 'treatment', 'market_class'}) and 2 missing columns ({'fdc_id_of_acquisition_food', 'fdc_id_of_sample_food'}).

This happened while the csv dataset builder was generating data using

hf://datasets/yvfu/FoodData_Central_csv_2025-04-24/agricultural_samples.csv (at revision 5cd3c77e60c49618efb835bfa6fb2f7893e3a413)

Please either edit the data files to have matching columns, or separate them into different configurations (see docs at https://hf.co/docs/hub/datasets-manual-configuration#multiple-configurations)
Traceback:    Traceback (most recent call last):
                File "/usr/local/lib/python3.12/site-packages/datasets/builder.py", line 1831, in _prepare_split_single
                  writer.write_table(table)
                File "/usr/local/lib/python3.12/site-packages/datasets/arrow_writer.py", line 714, in write_table
                  pa_table = table_cast(pa_table, self._schema)
                             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/local/lib/python3.12/site-packages/datasets/table.py", line 2272, in table_cast
                  return cast_table_to_schema(table, schema)
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/local/lib/python3.12/site-packages/datasets/table.py", line 2218, in cast_table_to_schema
                  raise CastError(
              datasets.table.CastError: Couldn't cast
              fdc_id: int64
              acquisition_date: string
              market_class: string
              treatment: string
              state: string
              -- schema metadata --
              pandas: '{"index_columns": [{"kind": "range", "name": null, "start": 0, "' + 854
              to
              {'fdc_id_of_sample_food': Value('int64'), 'fdc_id_of_acquisition_food': Value('int64')}
              because column names don't match
              
              During handling of the above exception, another exception occurred:
              
              Traceback (most recent call last):
                File "/src/services/worker/src/worker/job_runners/config/parquet_and_info.py", line 1455, in compute_config_parquet_and_info_response
                  parquet_operations = convert_to_parquet(builder)
                                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^
                File "/src/services/worker/src/worker/job_runners/config/parquet_and_info.py", line 1054, in convert_to_parquet
                  builder.download_and_prepare(
                File "/usr/local/lib/python3.12/site-packages/datasets/builder.py", line 894, in download_and_prepare
                  self._download_and_prepare(
                File "/usr/local/lib/python3.12/site-packages/datasets/builder.py", line 970, in _download_and_prepare
                  self._prepare_split(split_generator, **prepare_split_kwargs)
                File "/usr/local/lib/python3.12/site-packages/datasets/builder.py", line 1702, in _prepare_split
                  for job_id, done, content in self._prepare_split_single(
                                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/local/lib/python3.12/site-packages/datasets/builder.py", line 1833, in _prepare_split_single
                  raise DatasetGenerationCastError.from_cast_error(
              datasets.exceptions.DatasetGenerationCastError: An error occurred while generating the dataset
              
              All the data files must have the same columns, but at some point there are 5 new columns ({'fdc_id', 'acquisition_date', 'state', 'treatment', 'market_class'}) and 2 missing columns ({'fdc_id_of_acquisition_food', 'fdc_id_of_sample_food'}).
              
              This happened while the csv dataset builder was generating data using
              
              hf://datasets/yvfu/FoodData_Central_csv_2025-04-24/agricultural_samples.csv (at revision 5cd3c77e60c49618efb835bfa6fb2f7893e3a413)
              
              Please either edit the data files to have matching columns, or separate them into different configurations (see docs at https://hf.co/docs/hub/datasets-manual-configuration#multiple-configurations)

Need help to make the dataset viewer work? Make sure to review how to configure the dataset viewer, and open a discussion for direct support.

fdc_id_of_sample_food
int64
fdc_id_of_acquisition_food
int64
319,874
319,876
319,874
319,875
319,879
319,881
319,879
319,880
319,885
319,890
319,885
319,887
319,885
319,888
319,885
319,891
319,885
319,889
319,885
319,886
319,894
319,896
319,894
319,897
319,894
319,895
319,894
319,898
319,901
319,903
319,901
319,905
319,901
319,904
319,901
319,902
319,921
319,923
319,921
319,924
319,921
319,922
319,921
319,925
319,939
319,943
319,939
319,941
319,939
319,942
319,939
319,940
319,958
319,963
319,958
319,960
319,958
319,959
319,958
319,961
319,958
319,962
319,958
319,964
319,978
319,980
319,978
319,979
319,984
319,989
319,984
319,985
319,984
319,986
319,984
319,987
319,984
319,990
319,984
319,988
320,005
320,007
320,005
320,006
320,005
320,008
320,005
320,010
320,005
320,009
320,025
320,026
320,031
320,032
320,037
320,038
320,043
320,044
320,062
320,063
320,085
320,086
320,104
320,105
320,124
320,125
320,143
320,144
320,165
320,166
320,172
320,173
320,179
320,180
320,185
320,186
320,191
320,192
320,197
320,198
320,203
320,204
320,210
320,211
320,230
320,231
320,253
320,254
320,275
320,276
320,298
320,299
320,307
320,308
320,313
320,314
320,332
320,333
320,353
320,355
320,353
320,354
320,357
320,368
320,357
320,365
320,357
320,369
320,357
320,355
320,357
320,362
320,357
320,376
320,357
320,354
320,357
320,375
320,357
320,363
320,357
320,359
320,357
320,378
320,357
320,364
320,357
320,360
320,357
320,379
320,357
320,367
320,357
320,358
320,357
320,371
320,357
320,374
320,357
320,361
320,357
320,370
320,357
320,373
320,357
320,372
320,357
320,377
320,357
320,366
320,382
320,369
320,382
320,358
320,384
320,361
320,384
320,354
320,384
320,368
End of preview.

No dataset card yet

Downloads last month
28