Dataset Preview
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 ({'avg_shipment_cost_per_km', 'total_fuel_brl', 'total_freight_brl', 'fuel_surcharge_ratio', 'year_month'}) and 1 missing columns ({'carrier'}).
This happened while the csv dataset builder was generating data using
hf://datasets/toolathon123/south-america-logistics-costs-monthly/data/monthly_summary.csv (at revision 4b1d7186b219fde027535d94a3b15b3e6e8940a4), ['hf://datasets/toolathon123/south-america-logistics-costs-monthly@4b1d7186b219fde027535d94a3b15b3e6e8940a4/data/carrier_analysis.csv', 'hf://datasets/toolathon123/south-america-logistics-costs-monthly@4b1d7186b219fde027535d94a3b15b3e6e8940a4/data/monthly_summary.csv', 'hf://datasets/toolathon123/south-america-logistics-costs-monthly@4b1d7186b219fde027535d94a3b15b3e6e8940a4/data/south_america_logistics_costs_cleaned.csv', 'hf://datasets/toolathon123/south-america-logistics-costs-monthly@4b1d7186b219fde027535d94a3b15b3e6e8940a4/data/top_high_cost_routes.csv']
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.14/site-packages/datasets/builder.py", line 1837, in _prepare_split_single
writer.write_table(table)
~~~~~~~~~~~~~~~~~~^^^^^^^
File "/usr/local/lib/python3.14/site-packages/datasets/arrow_writer.py", line 765, in write_table
self._write_table(pa_table, writer_batch_size=writer_batch_size)
~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.14/site-packages/datasets/arrow_writer.py", line 773, in _write_table
pa_table = table_cast(pa_table, self._schema)
File "/usr/local/lib/python3.14/site-packages/datasets/table.py", line 2369, in table_cast
return cast_table_to_schema(table, schema)
File "/usr/local/lib/python3.14/site-packages/datasets/table.py", line 2297, in cast_table_to_schema
raise CastError(
...<3 lines>...
)
datasets.table.CastError: Couldn't cast
year_month: string
region: string
shipment_count: int64
total_distance_km: double
total_freight_brl: double
total_fuel_brl: double
total_cost_brl: double
avg_shipment_cost_per_km: double
avg_cost_per_km_brl: double
fuel_surcharge_ratio: double
-- schema metadata --
pandas: '{"index_columns": [{"kind": "range", "name": null, "start": 0, "' + 1591
to
{'region': Value('string'), 'carrier': Value('string'), 'shipment_count': Value('int64'), 'total_distance_km': Value('float64'), 'total_cost_brl': Value('float64'), 'avg_cost_per_km_brl': Value('float64')}
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 1369, in compute_config_parquet_and_info_response
parquet_operations, partial, estimated_dataset_info = stream_convert_to_parquet(
~~~~~~~~~~~~~~~~~~~~~~~~~^
builder, max_dataset_size_bytes=max_dataset_size_bytes
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
)
^
File "/src/services/worker/src/worker/job_runners/config/parquet_and_info.py", line 948, in stream_convert_to_parquet
builder._prepare_split(split_generator=splits_generators[split], file_format="parquet")
~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.14/site-packages/datasets/builder.py", line 1683, in _prepare_split
for job_id, done, content in self._prepare_split_single(
~~~~~~~~~~~~~~~~~~~~~~~~~~^
gen_kwargs=gen_kwargs, job_id=job_id, **_prepare_split_args
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
):
^
File "/usr/local/lib/python3.14/site-packages/datasets/builder.py", line 1839, in _prepare_split_single
raise DatasetGenerationCastError.from_cast_error(
...<4 lines>...
)
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 ({'avg_shipment_cost_per_km', 'total_fuel_brl', 'total_freight_brl', 'fuel_surcharge_ratio', 'year_month'}) and 1 missing columns ({'carrier'}).
This happened while the csv dataset builder was generating data using
hf://datasets/toolathon123/south-america-logistics-costs-monthly/data/monthly_summary.csv (at revision 4b1d7186b219fde027535d94a3b15b3e6e8940a4), ['hf://datasets/toolathon123/south-america-logistics-costs-monthly@4b1d7186b219fde027535d94a3b15b3e6e8940a4/data/carrier_analysis.csv', 'hf://datasets/toolathon123/south-america-logistics-costs-monthly@4b1d7186b219fde027535d94a3b15b3e6e8940a4/data/monthly_summary.csv', 'hf://datasets/toolathon123/south-america-logistics-costs-monthly@4b1d7186b219fde027535d94a3b15b3e6e8940a4/data/south_america_logistics_costs_cleaned.csv', 'hf://datasets/toolathon123/south-america-logistics-costs-monthly@4b1d7186b219fde027535d94a3b15b3e6e8940a4/data/top_high_cost_routes.csv']
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.
region string | carrier string | shipment_count int64 | total_distance_km float64 | total_cost_brl float64 | avg_cost_per_km_brl float64 |
|---|---|---|---|---|---|
Argentina | Via Cargo | 43 | 33,180 | 84,365.134618 | 2.54265 |
Argentina | Andreani | 45 | 29,530 | 63,977.765572 | 2.166535 |
Argentina | OCA | 54 | 37,570 | 78,297.467286 | 2.084042 |
Argentina | Transportes Barraca | 39 | 26,290 | 52,676.359013 | 2.003665 |
Argentina | Río Uruguay | 44 | 27,690 | 54,265.602896 | 1.959755 |
Argentina | Fandango | 47 | 32,830 | 62,893.26217 | 1.915725 |
Argentina | Loginter | 29 | 19,100 | 36,431.141906 | 1.90739 |
Argentina | Cargo Express | 39 | 24,400 | 39,597.399985 | 1.622844 |
Brazil | TransBrasil | 34 | 31,305 | 69,927.359284 | 2.233744 |
Brazil | Translovato | 45 | 42,925 | 72,683.091586 | 1.693258 |
Brazil | Sebral | 56 | 45,290 | 75,145.098243 | 1.659198 |
Brazil | JSL Logística | 48 | 37,155 | 60,592.747986 | 1.63081 |
Brazil | Vamos | 46 | 39,600 | 64,548.986238 | 1.630025 |
Brazil | Loggi Cargo | 39 | 33,545 | 54,419.526403 | 1.622284 |
Brazil | Rodonorte | 41 | 34,090 | 54,516.767695 | 1.599201 |
Brazil | Expresso N. | 37 | 37,665 | 60,183.757045 | 1.59787 |
Brazil | Rumo Log | 43 | 36,000 | 57,361.281132 | 1.593369 |
Brazil | Brado | 31 | 26,285 | 40,472.2673 | 1.539748 |
Argentina | null | 123 | 85,750 | 176,076.396218 | 2.053369 |
Brazil | null | 153 | 129,940 | 220,872.086811 | 1.699801 |
Argentina | null | 116 | 78,020 | 155,394.324138 | 1.991724 |
Brazil | null | 145 | 126,490 | 209,654.194736 | 1.657476 |
Argentina | null | 101 | 66,820 | 141,033.413089 | 2.110647 |
Brazil | null | 122 | 107,430 | 179,324.601364 | 1.669223 |
Brazil | Expresso N. | null | null | 1,300.19 | null |
Brazil | Loggi Cargo | null | null | 740.35 | null |
Brazil | TransBrasil | null | null | 1,426.47 | null |
Brazil | Expresso N. | null | null | 2,269.75 | null |
Brazil | Rumo Log | null | null | 584.97 | null |
Brazil | JSL Logística | null | null | 2,403.39 | null |
Brazil | Sebral | null | null | 1,616.91 | null |
Brazil | Rumo Log | null | null | 515.93 | null |
Brazil | Sebral | null | null | 2,112.443897 | null |
Brazil | Brado | null | null | 502.79 | null |
Brazil | Translovato | null | null | 2,225.44 | null |
Brazil | Rumo Log | null | null | 885.61 | null |
Brazil | Vamos | null | null | 763.32 | null |
Brazil | JSL Logística | null | null | 771 | null |
Brazil | Sebral | null | null | 727.8 | null |
Brazil | Sebral | null | null | 1,091.4 | null |
Brazil | Vamos | null | null | 753.67 | null |
Brazil | Rodonorte | null | null | 161.698479 | null |
Brazil | Rodonorte | null | null | 1,866.95 | null |
Brazil | Sebral | null | null | 1,194.55 | null |
Brazil | JSL Logística | null | null | 1,790.11 | null |
Brazil | Loggi Cargo | null | null | 600.448148 | null |
Brazil | Brado | null | null | 1,064.76 | null |
Brazil | Expresso N. | null | null | 1,835.83 | null |
Brazil | Vamos | null | null | 969.29 | null |
Brazil | Rodonorte | null | null | 764.23 | null |
Brazil | Loggi Cargo | null | null | 1,224.69 | null |
Brazil | Expresso N. | null | null | 3,193.73 | null |
Brazil | Sebral | null | null | 621.02 | null |
Brazil | Vamos | null | null | 1,772.13 | null |
Brazil | Loggi Cargo | null | null | 1,101.98 | null |
Brazil | Expresso N. | null | null | 679.94 | null |
Brazil | Brado | null | null | 3,476.3 | null |
Brazil | Sebral | null | null | 2,590.9 | null |
Brazil | Expresso N. | null | null | 816.31 | null |
Brazil | Brado | null | null | 922.97 | null |
Brazil | Rumo Log | null | null | 1,557.002005 | null |
Brazil | Sebral | null | null | 861.89809 | null |
Brazil | TransBrasil | null | null | 2,995.34 | null |
Brazil | TransBrasil | null | null | 3,893.82 | null |
Brazil | Loggi Cargo | null | null | 1,212.18 | null |
Brazil | Brado | null | null | 802.71 | null |
Brazil | Rumo Log | null | null | 757.74 | null |
Brazil | Brado | null | null | 772.6 | null |
Brazil | JSL Logística | null | null | 1,644.47 | null |
Brazil | TransBrasil | null | null | 1,637.85 | null |
Brazil | Translovato | null | null | 1,267.448591 | null |
Brazil | Rodonorte | null | null | 703.63 | null |
Brazil | Vamos | null | null | 1,482.62 | null |
Brazil | Expresso N. | null | null | 2,044.72 | null |
Brazil | JSL Logística | null | null | 1,736.94 | null |
Brazil | Loggi Cargo | null | null | 1,022.82 | null |
Brazil | Translovato | null | null | 909.11 | null |
Brazil | Brado | null | null | 748.9 | null |
Brazil | Rodonorte | null | null | 973.17 | null |
Brazil | Vamos | null | null | 910.84 | null |
Brazil | JSL Logística | null | null | 756.4 | null |
Brazil | Translovato | null | null | 554.72 | null |
Brazil | Vamos | null | null | 1,758.19 | null |
Brazil | Rodonorte | null | null | 1,141.97 | null |
Brazil | Loggi Cargo | null | null | 3,320.729576 | null |
Brazil | Expresso N. | null | null | 5,017.6 | null |
Brazil | Vamos | null | null | 2,179.52 | null |
Brazil | Vamos | null | null | 813.89 | null |
Brazil | Rodonorte | null | null | 1,338.65 | null |
Brazil | Rodonorte | null | null | 3,030.46 | null |
Brazil | Expresso N. | null | null | 844.46 | null |
Brazil | JSL Logística | null | null | 1,362.27 | null |
Brazil | TransBrasil | null | null | 1,519.85 | null |
Brazil | Vamos | null | null | 1,915.61 | null |
Brazil | Loggi Cargo | null | null | 1,024.46 | null |
Brazil | Rumo Log | null | null | 1,813.2 | null |
Brazil | TransBrasil | null | null | 1,636.4 | null |
Brazil | Loggi Cargo | null | null | 459.92 | null |
Brazil | Rodonorte | null | null | 1,766.73 | null |
Brazil | Rodonorte | null | null | 1,364.15783 | null |
End of preview.
South America Logistics Costs — Monthly
Merged, cleaned, deduplicated Brazil + Argentina logistics cost dataset. All monetary values converted to BRL (R$).
Contents
data/south_america_logistics_costs_cleaned.{csv,parquet}— final detailed dataset (unified schema, BRL, imputation flags).data/monthly_summary.{csv,parquet}— monthly × region aggregates (total cost, avg BRL/km, fuel share).data/top_high_cost_routes.{csv,parquet}— top-5 high-cost routes per month & region.data/carrier_analysis.csv— cost per km by carrier.cost_optimization_report.md— cost-optimisation recommendations.pipeline_log.md— full audit log of the run.scripts/— reproducible pipeline scripts.
Methodology
- Source:
toolathon123/brazil-logistics-costs(BRL) andtoolathon123/argentina-logistics-costs(ARS/USD). - FX: fixed monthly rates 1 USD = 4.95 BRL, 1 ARS = 0.025 BRL; a record's own
exchange_rate_to_brltakes precedence when present. - Missing values: fuel_surcharge → region+month mean; distance_km → route mean; freight_cost → distance × regional avg BRL/km.
- Deduplication: exact duplicates and duplicate shipment_id removed (keep first).
Columns (cleaned dataset)
shipment_id, origin, destination, carrier, distance_km, fuel_surcharge_brl, freight_cost_brl, total_cost_brl, cost_per_km_brl, original_freight_cost, original_fuel_surcharge, original_currency, exchange_rate_used, year_month, timestamp, region, fuel_imputed, distance_imputed, freight_imputed, anomaly_flag
- Downloads last month
- 65