html_url
stringlengths 48
51
| title
stringlengths 5
268
| comments
stringlengths 63
51.8k
| body
stringlengths 0
36.2k
⌀ | comment_length
int64 16
1.52k
| text
stringlengths 164
54.1k
| embeddings
sequence |
---|---|---|---|---|---|---|
https://github.com/huggingface/datasets/issues/3473 | Iterating over a vision dataset doesn't decode the images | Thanks @NielsRogge for the context.
So IMO everything is working as expected.
I'm closing this issue. Feel free to reopen it again if further changes of the specs should be addressed. | ## Describe the bug
If I load `mnist` and I iterate over the dataset, the images are not decoded, and the dictionary with the bytes is returned.
## Steps to reproduce the bug
```python
from datasets import load_dataset
import PIL
mnist = load_dataset("mnist", split="train")
first_image = mnist[0]["image"]
assert isinstance(first_image, PIL.PngImagePlugin.PngImageFile) # passes
first_image = next(iter(mnist))["image"]
assert isinstance(first_image, PIL.PngImagePlugin.PngImageFile) # fails
```
## Expected results
The image should be decoded, as a PIL Image
## Actual results
We get a dictionary
```
{'bytes': b'\x89PNG\r\n\x1a\n\x00..., 'path': None}
```
## Environment info
- `datasets` version: 1.17.1.dev0
- Platform: Darwin-20.6.0-x86_64-i386-64bit
- Python version: 3.7.2
- PyArrow version: 6.0.0
The bug also exists in 1.17.0
## Investigation
I think the issue is that decoding is disabled in `__iter__`:
https://github.com/huggingface/datasets/blob/dfe5b73387c5e27de6a16b0caeb39d3b9ded66d6/src/datasets/arrow_dataset.py#L1651-L1661
Do you remember why it was disabled in the first place @albertvillanova ?
Also cc @mariosasko @NielsRogge
| 31 | Iterating over a vision dataset doesn't decode the images
## Describe the bug
If I load `mnist` and I iterate over the dataset, the images are not decoded, and the dictionary with the bytes is returned.
## Steps to reproduce the bug
```python
from datasets import load_dataset
import PIL
mnist = load_dataset("mnist", split="train")
first_image = mnist[0]["image"]
assert isinstance(first_image, PIL.PngImagePlugin.PngImageFile) # passes
first_image = next(iter(mnist))["image"]
assert isinstance(first_image, PIL.PngImagePlugin.PngImageFile) # fails
```
## Expected results
The image should be decoded, as a PIL Image
## Actual results
We get a dictionary
```
{'bytes': b'\x89PNG\r\n\x1a\n\x00..., 'path': None}
```
## Environment info
- `datasets` version: 1.17.1.dev0
- Platform: Darwin-20.6.0-x86_64-i386-64bit
- Python version: 3.7.2
- PyArrow version: 6.0.0
The bug also exists in 1.17.0
## Investigation
I think the issue is that decoding is disabled in `__iter__`:
https://github.com/huggingface/datasets/blob/dfe5b73387c5e27de6a16b0caeb39d3b9ded66d6/src/datasets/arrow_dataset.py#L1651-L1661
Do you remember why it was disabled in the first place @albertvillanova ?
Also cc @mariosasko @NielsRogge
Thanks @NielsRogge for the context.
So IMO everything is working as expected.
I'm closing this issue. Feel free to reopen it again if further changes of the specs should be addressed. | [
-0.0911608562,
-0.3595888913,
-0.050832998,
0.408655256,
0.1412411779,
-0.0136508355,
0.12589553,
0.0593585148,
-0.006152519,
0.1949329674,
0.1792143136,
0.5321470499,
-0.0439153425,
-0.1239933521,
-0.0646307319,
-0.156975314,
0.0175925158,
0.2997390926,
0.0252632573,
-0.1067634597,
-0.2367453128,
0.1048494056,
-0.3097245693,
-0.2923023403,
0.0453219451,
-0.0297626648,
-0.2835354209,
0.0016703041,
-0.1749753654,
-0.4527779222,
0.0106979925,
0.0525575504,
0.106474258,
0.3387383521,
-0.0001223067,
0.1524630189,
0.3982886076,
-0.036361523,
-0.2432939112,
-0.0822822899,
-0.1017011702,
-0.2396052927,
0.1475265771,
-0.2043798715,
-0.1358155608,
-0.5493178964,
0.0961470082,
-0.1692907959,
0.2917227447,
0.0498822443,
0.1059623063,
0.0853291675,
0.0628653839,
0.5347549319,
0.1060520038,
0.2336910367,
-0.1704912633,
0.3712293804,
-0.1107614711,
0.1593019366,
-0.1882726252,
0.3761419058,
-0.0737327114,
0.1669455022,
0.0354020931,
0.2564544082,
-0.0318812951,
-0.4047653973,
-0.2371650785,
-0.0527555831,
0.350736618,
-0.1313531101,
-0.4559845924,
-0.3025561869,
-0.1228605807,
-0.4613290429,
0.3491021991,
0.2087191939,
-0.2571617067,
0.0707955137,
0.0135818599,
0.0929713175,
-0.2530212402,
0.1994621456,
-0.3653829396,
-0.1408729702,
-0.0832649544,
0.1692871898,
0.3491601348,
0.0227987245,
0.3840201795,
-0.0553717017,
-0.1696824431,
-0.234855935,
-0.4050032198,
-0.1098937094,
-0.0418723337,
0.0936925486,
-0.0782495439,
0.0987875909,
0.0812917799,
0.018590169,
-0.2000338435,
0.2009765059,
0.2716214359,
0.0429743119,
-0.2058278918,
0.569375515,
0.1119408384,
0.1324677169,
-0.1616629958,
-0.0997978523,
-0.0698541477,
-0.1237010285,
0.1229671985,
-0.0359727219,
0.3391929567,
-0.059326686,
-0.1868901253,
-0.2733954787,
-0.6796954274,
-0.1522934139,
-0.0266723167,
0.0285299085,
0.3164392114,
0.2817383111,
0.2265048772,
0.1340815127,
-0.2488737702,
-0.3376649022,
-0.104562737,
-0.0530946665,
-0.2234990597,
0.0431535356,
0.0859728381,
0.1988490224,
-0.0849196464,
-0.0349663273,
-0.0414971597,
-0.2844217122,
0.1692169309,
-0.4114148617,
0.727887094,
0.2451031655,
-0.2046801746,
-0.0599258728,
0.0205788426,
-0.1148970425,
-0.0864229426,
0.1402484626,
-0.2274929583,
0.2030459344,
0.054821115,
-0.0041932338,
-0.3438706696,
-0.3087537289,
-0.0886715055,
0.2518980205,
0.0434998758,
-0.2548526824,
0.1877718568,
-0.2359255999,
-0.2585910559,
-0.1744618416,
0.3156965375,
0.3751045465,
-0.5280712247,
0.2404892296,
-0.0253315214,
-0.2566176951,
0.26598984,
0.3764413297,
-0.0824031383,
0.0788736269,
-0.4481166303,
0.0594564155,
0.057956893,
-0.3490836024,
-0.5716888309,
0.3678844273,
0.3008444309,
0.4581704736,
0.0607154109,
0.1693109572,
0.0652857274,
-0.0700075328,
-0.3946209252,
0.2477510422,
-0.1886060089,
-0.1533149928,
-0.221703425,
0.1093064025,
0.3931859434,
0.3083884716,
0.1736363322,
0.1508385539,
0.0663973242,
-0.1880116612,
0.4236243963,
-0.0763437673,
0.1011086479,
-0.0191543158,
0.1315477341,
-0.153348282,
0.5154821277,
-0.0131916646,
0.0228840113,
0.2377530932,
0.1587820351,
-0.1194873303,
-0.4076039493,
0.0624832176,
0.2453977019,
0.0540886447,
-0.6149252653,
-0.1257506162,
0.1096826643,
0.3666635454,
-0.1173380613,
0.095561184,
-0.2539736629,
0.1744341552,
-0.2745246291,
-0.0256791022,
-0.0797450915,
0.3857544959,
0.0923131704,
-0.1475057751,
-0.2950838506,
0.144488886,
-0.0473524854,
-0.2182923704,
0.0022063288,
0.2441834807,
0.4047062993,
0.1732900292,
-0.0832951888,
0.0262282956,
0.3780457973,
-0.8003010154,
-0.0965069979,
0.1252141297,
0.0924559534,
-0.0296925288,
0.1963573098,
-0.0080182115,
0.1075181365,
0.4401963353,
-0.0773386434,
0.0582293831,
0.0414634421,
-0.0852361396,
-0.3500138819,
-0.1823793352,
0.0994293317,
-0.2844879329,
0.061233528,
-0.1354646683,
-0.31161955,
0.0598554276,
0.3767959476,
-0.0289664119,
0.0061142035,
-0.0221033804,
-0.133380428,
0.1847705394,
0.2215426564,
0.0749277323,
0.285879463,
-0.035729643,
0.108683385,
0.0946680233,
-0.0629881844,
0.1246675178,
0.1014804393,
0.5285308361,
0.508018136,
0.0885706842,
0.1533772647,
0.0564636774,
-0.4357742667,
-0.4007242322,
0.0216769315,
0.0007945703,
-0.0270489492,
0.5111714602,
-0.4568687975,
-0.6644816995,
-0.1626346856,
0.2539758086,
-0.1542431116,
-0.3112697005,
-0.3570477664,
0.1398817003,
0.0995429456,
-0.0049346131,
-0.1207467914,
0.0916077644,
0.1518121213,
-0.109824121,
-0.4499152601,
-0.1213229746,
-0.0881965533,
-0.0589497685,
0.3093397021,
-0.4779466093,
0.330090493,
-0.139273569,
-0.1544647813,
-0.2941296101,
-0.3996732831,
0.4428441823,
-0.3422986269,
0.2650538981,
0.1150618792,
-0.011508448,
-0.161580354,
0.1639093012,
0.2919083834,
-0.0104991021,
-0.2537606061,
0.0495128147,
-0.1142215505,
-0.1066485792,
-0.1671769917,
0.0319861807,
-0.0970015898,
-0.2107329518,
0.2991689742,
0.179454267,
0.1658943892,
0.5234157443,
0.0443230085,
0.1026446149,
-0.2546550035,
-0.0407922454,
-0.0390503965,
0.0732251257,
0.0950060263,
-0.0637253374,
-0.3026873767,
0.1027854159,
-0.1231298,
0.2993483245,
0.2342745215,
-0.5083343983,
-0.0858053416,
-0.1998249441,
-0.0131619154,
-0.2161603719,
-0.1364508718,
-0.107012257,
-0.0125703504,
0.0652889535,
-0.2897031009,
-0.1108058915,
0.0539295413,
0.1998975128,
0.3998769522,
0.3275474012,
0.1469459385,
0.4360582829,
0.3380974233,
0.3946785331,
-0.1318712831,
0.5188969374,
-0.3391311169,
0.2213440984,
0.0602632277,
-0.2288511395,
0.1625664532,
-0.0446474217,
-0.2180657685,
0.0018212019,
-0.1937781423,
-0.5257053971,
-0.1841742098,
-0.0343146026,
-0.4484811127,
-0.3438020051,
-0.0203596745,
-0.1573280245,
0.0319387093,
-0.1707955301,
0.2422425151,
0.1145544723,
-0.0871438235,
0.0541273095,
0.2889104486,
0.314604789,
0.0307367854,
-0.1667642295,
-0.5435647964,
-0.0197069533,
-0.1242483407,
0.0290879477,
0.6805778146,
0.0394351184,
-0.1197524816,
0.3330440223,
-0.2112767398,
0.9808092713,
-0.1805993021,
-0.0671911463,
0.0428495407,
-0.1794054806,
-0.0958260819,
-0.0486563928,
-0.27178967,
0.1259339005,
-0.0206628498,
0.1730512083,
-0.133623153,
-0.1384020895,
0.3206467927,
0.2339528054,
-0.081492804,
-0.3093907535,
-0.4057844579,
-0.2177325338,
-0.2486927807,
-0.1495037824,
0.0287437607,
0.0409862921,
-0.0552148782,
0.058921352,
-0.2216670662,
-0.0720446929,
0.1044866368,
0.1710736603,
0.3220690191,
-0.1027527153,
0.1121052429,
0.5169764757,
0.3116583526,
0.2337014824,
0.7072021961,
0.3447485864,
-0.3077132106,
0.1928237975,
-0.108669892,
0.3674254417,
0.3449735045,
-0.3707821071,
-0.1881162226,
0.0623155609,
-0.0833588094,
-0.5213639736,
0.0102198767,
0.531658411,
-0.1023125276,
-0.3069269061,
-0.1918424219,
0.4711439013,
0.1223413199,
0.0644235015,
0.3382718265,
0.2077241838,
-0.1231693476,
0.4499666989,
0.276021421,
0.8663901687,
-0.0060537322,
0.1723111719,
0.3806504905,
0.3373433948,
0.3749446571,
0.3325274587,
0.4743904173,
-0.1471263617,
-0.3070941269,
-0.0975668877,
-0.1063876525,
0.291374445,
-0.2267370373,
-0.2199011445,
0.0571038499,
0.2303806096,
0.0066519412,
0.2203778028,
0.0861149356,
-0.0941327065,
-0.0020605261,
0.1962225586,
0.0830782056,
0.0315163732,
0.1906033307,
0.0252612866,
-0.2889955044,
-0.0846732333,
0.0137525536,
-0.1263038963,
0.3221428096,
-0.1931633353,
-0.0263387691,
-0.0759809837,
-0.4138152897,
0.0584764145,
0.1625745296,
0.0298568625,
-0.2241826952,
-0.1887601763,
0.1732988358,
0.1654722542,
-0.1482759863,
0.1040084586,
-0.222683996,
0.3105813265,
0.0620464608,
-0.1688801944,
-0.1624930054,
0.1238235906,
-0.1002463326,
-0.1042133719,
0.1147232503,
-0.0002196157,
0.0367585979,
0.1320659816,
-0.0823716223,
-0.2347564697,
-0.0503295697,
0.0580433644,
0.0062350021,
-0.0264626965,
0.2759627104,
-0.1142352,
-0.2275209278,
-0.0199868567,
0.1952711642,
-0.0251422767,
-0.0396064855,
0.4516369402,
0.1525737196,
-0.1444462538,
-0.1424968839,
-0.0919724628,
-0.2102077454,
-0.3577530086,
0.0950438902,
-0.0813243464,
0.3669191897,
0.0376154035,
0.1914721876,
-0.0917605311,
-0.3418789208,
-0.364569366,
-0.2912634313,
0.0502336733,
0.2284908444,
-0.3127470613,
0.2925331593,
-0.246340543,
0.0680038407,
0.000035483,
-0.1631993353,
-0.1895995438,
0.0203459058,
-0.1628998965,
0.0993507504,
-0.1030662805,
0.1656354666,
0.2797442675,
0.1102507859,
0.116146341,
0.3283220828,
0.1378101259,
-0.0422889553,
-0.1859445572,
0.1524449885,
0.232272476,
-0.2003205419,
0.0312729105,
-0.321841985,
-0.1570551097,
-0.2128009945,
-0.1009964943,
-0.1378445476,
-0.0418992192,
0.4225997925,
0.0131716598,
0.1641298234,
0.1668526083,
-0.0381441824,
-0.0705903545,
0.2891506553,
0.1770520955,
0.2319793999,
0.0894365087,
0.0913065672,
-0.0221998785,
0.0281238332,
-0.0636826903,
-0.0202710927,
0.4187356234,
-0.15285936,
0.2202700078,
-0.112974979,
0.6022439003,
0.5080569983,
-0.2141415924,
-0.1377756596,
0.0200745724,
0.0665278062,
-0.1378826052,
0.1980514526,
0.4402068555,
0.0765052438,
0.0394863375,
0.4424023926,
0.1340303272,
0.3094475865,
-0.1248949096,
-0.1568091065,
0.2621465623,
-0.2521362603,
0.0377340391,
0.2930392623,
-0.0745740905,
0.0913480371,
0.3533052206,
0.221382767,
0.1470437348,
0.8439808488,
-0.2774690092,
0.2470226288,
0.0096221892,
0.0669854879,
0.113699019,
-0.2494929433,
0.1774074733,
-0.0990597159,
0.1901783049,
0.2482226789,
-0.2097835392,
0.0338776596,
0.1154541448,
-0.0814946443,
-0.0588687733,
0.1741530001,
0.0038382087,
0.196573928,
-0.5081726909,
-0.0490317345,
-0.2284851968,
-0.1811755002,
0.1343643218,
-0.3724871874,
0.3422926962,
0.4122366309,
0.0438051671,
-0.3413385153,
-0.2342539579,
-0.0593588948,
0.4301451445,
-0.3519630134,
0.2631873488,
0.1422848552,
0.0749108195,
0.1978943646,
0.2588697672,
0.293590188,
0.2636402547,
-0.1969093978,
0.0306733623,
-0.3210825324,
-0.2470924705,
-0.2050416768,
0.373069495,
-0.0852809027,
0.1789830476,
0.4443306923,
-0.0054424792,
0.0326332822,
-0.2417890728,
0.0772523433,
0.1295416057,
-0.3881368339,
0.3345747292,
-0.3152942955,
0.2162450701,
-0.0212629102,
-0.2296561748,
-0.3958540261,
-0.2502171099,
0.2272841483,
-0.113060303,
0.1419254392,
0.0458015501,
0.0046321438,
-0.3815216422,
0.1561970413,
0.5473835468,
0.3422602713,
-0.0621965937,
0.0921033695,
-0.3612249196,
0.1420255154,
-0.1916941255,
-0.5103560686,
0.0155929541,
0.440492481,
0.0363347344,
0.1330946684,
0.4075900614,
-0.0376903787,
0.5223021507,
0.3924883306,
-0.1819741726,
-0.4991635382,
0.1150394678,
0.0088709639,
-0.1647741646,
-0.2603871822,
0.2566080689,
-0.4302844703,
0.0005752136,
-0.0190438628,
-0.2932743728,
0.0287362691,
-0.3983387053,
0.5557389855,
0.3279883265,
0.3863871694,
-0.1723319739,
-0.3796057105,
-0.2869483829,
-0.1866806597,
-0.3287952244,
0.2423841208,
-0.0368449464,
0.5559114814,
-0.1636164635,
0.1269494295,
-0.2294999957,
-0.0244879015,
0.0333731547,
-0.0712006837,
-0.3853932321,
0.3977552354,
-0.1112011522,
0.2107682824,
0.0277675018,
0.3098837733,
0.0827976242,
0.1594417989,
-0.3639880717,
-0.460537225,
0.4134663939,
-0.6467501521,
-0.0874282494,
0.2697851658,
-0.1309459955,
-0.0036785705,
0.1372690499,
-0.3963897228,
-0.1853097379,
0.255687207,
-0.0962005407,
-0.1437842995,
0.2311588079,
0.2066200823,
0.0765028298,
-0.0979114845,
0.3814718127,
0.2589195669,
-0.1501254439,
0.2233729213,
0.0587346554
] |
https://github.com/huggingface/datasets/issues/3473 | Iterating over a vision dataset doesn't decode the images | Thanks for the details :)
I still think that it's unexpected to get different results when doing
```python
for i in range(len(dataset)):
sample = dataset[i]
```
and
```python
for sample in dataset:
pass
```
even though I understand that if you don't need to decode the data, then decoding image or audio data when iterating is a waste of time and resources.
But in this case users can still drop the column that need decoding to get the full speed back no ? | ## Describe the bug
If I load `mnist` and I iterate over the dataset, the images are not decoded, and the dictionary with the bytes is returned.
## Steps to reproduce the bug
```python
from datasets import load_dataset
import PIL
mnist = load_dataset("mnist", split="train")
first_image = mnist[0]["image"]
assert isinstance(first_image, PIL.PngImagePlugin.PngImageFile) # passes
first_image = next(iter(mnist))["image"]
assert isinstance(first_image, PIL.PngImagePlugin.PngImageFile) # fails
```
## Expected results
The image should be decoded, as a PIL Image
## Actual results
We get a dictionary
```
{'bytes': b'\x89PNG\r\n\x1a\n\x00..., 'path': None}
```
## Environment info
- `datasets` version: 1.17.1.dev0
- Platform: Darwin-20.6.0-x86_64-i386-64bit
- Python version: 3.7.2
- PyArrow version: 6.0.0
The bug also exists in 1.17.0
## Investigation
I think the issue is that decoding is disabled in `__iter__`:
https://github.com/huggingface/datasets/blob/dfe5b73387c5e27de6a16b0caeb39d3b9ded66d6/src/datasets/arrow_dataset.py#L1651-L1661
Do you remember why it was disabled in the first place @albertvillanova ?
Also cc @mariosasko @NielsRogge
| 83 | Iterating over a vision dataset doesn't decode the images
## Describe the bug
If I load `mnist` and I iterate over the dataset, the images are not decoded, and the dictionary with the bytes is returned.
## Steps to reproduce the bug
```python
from datasets import load_dataset
import PIL
mnist = load_dataset("mnist", split="train")
first_image = mnist[0]["image"]
assert isinstance(first_image, PIL.PngImagePlugin.PngImageFile) # passes
first_image = next(iter(mnist))["image"]
assert isinstance(first_image, PIL.PngImagePlugin.PngImageFile) # fails
```
## Expected results
The image should be decoded, as a PIL Image
## Actual results
We get a dictionary
```
{'bytes': b'\x89PNG\r\n\x1a\n\x00..., 'path': None}
```
## Environment info
- `datasets` version: 1.17.1.dev0
- Platform: Darwin-20.6.0-x86_64-i386-64bit
- Python version: 3.7.2
- PyArrow version: 6.0.0
The bug also exists in 1.17.0
## Investigation
I think the issue is that decoding is disabled in `__iter__`:
https://github.com/huggingface/datasets/blob/dfe5b73387c5e27de6a16b0caeb39d3b9ded66d6/src/datasets/arrow_dataset.py#L1651-L1661
Do you remember why it was disabled in the first place @albertvillanova ?
Also cc @mariosasko @NielsRogge
Thanks for the details :)
I still think that it's unexpected to get different results when doing
```python
for i in range(len(dataset)):
sample = dataset[i]
```
and
```python
for sample in dataset:
pass
```
even though I understand that if you don't need to decode the data, then decoding image or audio data when iterating is a waste of time and resources.
But in this case users can still drop the column that need decoding to get the full speed back no ? | [
-0.0234937239,
-0.3361244798,
-0.1152203232,
0.4020479321,
0.1095666438,
-0.0673545823,
0.1837366521,
0.0540369786,
-0.0070808269,
0.2113573551,
0.1559633166,
0.5565046668,
-0.0202431064,
-0.1345619261,
-0.0524968803,
-0.1830283254,
0.0578490198,
0.2923582494,
-0.0028657613,
-0.204117164,
-0.1988761574,
0.0604528673,
-0.3156466782,
-0.2815859318,
0.0706922635,
-0.0508689061,
-0.2603249848,
-0.0414553769,
-0.1578268856,
-0.480784893,
0.0064169415,
0.0626600832,
0.0977134705,
0.3476985395,
-0.0001239544,
0.1797286719,
0.3697611094,
-0.0600922927,
-0.2316691279,
-0.062064603,
-0.0670432225,
-0.2336891145,
0.1844453961,
-0.2357016951,
-0.107823953,
-0.5691389441,
0.0634718239,
-0.2426802963,
0.1982856393,
0.0299339071,
0.1044545397,
0.1374369562,
-0.082186088,
0.4861967564,
0.0990635976,
0.1997205168,
-0.1434843689,
0.3341660798,
-0.0854218453,
0.1146870404,
-0.173970893,
0.4096754193,
-0.0411364958,
0.1984057575,
0.0472219214,
0.2659731209,
-0.0231734477,
-0.4276508093,
-0.2290641963,
-0.0319039263,
0.2555896044,
-0.0642954633,
-0.4854048491,
-0.2815859914,
-0.189643681,
-0.4356888831,
0.2507334352,
0.2384615093,
-0.262766242,
0.0587501563,
-0.0392666534,
0.1666992158,
-0.2242993563,
0.2101665735,
-0.4287172258,
-0.0771843866,
-0.083952643,
0.2104039341,
0.323154062,
0.0519092605,
0.3572217822,
-0.1034022644,
-0.1309682578,
-0.2421122044,
-0.3684845567,
-0.1100836769,
0.0147398319,
0.0731808022,
-0.116535157,
0.1041941047,
0.1032308415,
0.0007172816,
-0.1779518276,
0.1134223863,
0.2612884939,
0.0626056567,
-0.2059274018,
0.5471674204,
0.0654840171,
0.1705536097,
-0.2201612592,
-0.0833314359,
0.0185403395,
-0.1567068696,
0.136312604,
0.0035690232,
0.350402534,
-0.0872907341,
-0.2631848752,
-0.2911524773,
-0.7114157081,
-0.1818784028,
-0.0205357876,
0.0244925153,
0.2793690264,
0.2959498167,
0.1611350179,
0.1303563714,
-0.2619990408,
-0.2456377298,
-0.1303814948,
-0.0453061983,
-0.2053301632,
0.0287904404,
0.0614896826,
0.2032850832,
-0.0567298904,
0.0220165905,
0.0002550863,
-0.262011081,
0.1870388389,
-0.3853565156,
0.8205065131,
0.2273033112,
-0.1830673814,
-0.0129618077,
0.003157076,
-0.1114745513,
-0.1290117651,
0.1420634389,
-0.1933177412,
0.2060518265,
0.07508488,
0.0160456952,
-0.2894886732,
-0.252046138,
-0.0894332603,
0.2164535522,
-0.0007524192,
-0.1945302635,
0.2351791114,
-0.2445407957,
-0.2447899878,
-0.1964251548,
0.2565388978,
0.3249501884,
-0.529468596,
0.2342916578,
0.0103512146,
-0.1889149994,
0.2224579453,
0.3856261075,
-0.1493367702,
0.1515868604,
-0.5117512345,
0.0323728099,
0.1189809144,
-0.4190916717,
-0.5537782311,
0.3360392153,
0.3010099232,
0.4762021005,
0.1365036219,
0.1696669161,
0.1061723307,
-0.0448734351,
-0.3553395271,
0.2338251024,
-0.1655225307,
-0.1094731092,
-0.1788869053,
0.0709705353,
0.4124054909,
0.2405238748,
0.1404346377,
0.1629984677,
0.1313119233,
-0.2226354182,
0.4608112276,
-0.1421097666,
0.0387568362,
-0.0044446154,
0.0459867232,
-0.1517652571,
0.4703567624,
0.0369949192,
0.0640165955,
0.2233190686,
0.1435666233,
-0.0603480823,
-0.423355788,
0.0320126563,
0.2202592492,
0.0322567523,
-0.5997847319,
-0.1970522553,
0.1258282214,
0.4092453122,
-0.0758431405,
0.0994010344,
-0.1898169219,
0.1650002301,
-0.2649020255,
-0.039974235,
-0.1172801852,
0.4144607782,
0.1425812095,
-0.0906681493,
-0.3539786935,
0.1236361563,
-0.0238612406,
-0.237457633,
0.0008115088,
0.1729074419,
0.423926115,
0.1968385279,
-0.1127214283,
0.0101171853,
0.3677068055,
-0.7532385588,
-0.0211653523,
0.1671845764,
0.1519617587,
-0.0153462077,
0.2026370764,
0.0550213382,
0.1170961931,
0.4938750863,
-0.036159426,
-0.003891032,
0.0230030399,
-0.0382534899,
-0.4000651538,
-0.2207865268,
0.0610154718,
-0.1868431568,
0.1420648843,
-0.0844788253,
-0.2543901801,
0.0977451131,
0.4000328481,
-0.0576376095,
-0.0496941023,
-0.0889267772,
-0.0906797275,
0.1964714378,
0.2205051929,
0.0938545391,
0.3501237333,
-0.0284748469,
0.133380115,
0.0484169833,
-0.073995851,
0.0858779773,
0.1334930062,
0.5782443881,
0.463059932,
0.0481866859,
0.1683954149,
0.0435121991,
-0.4422195554,
-0.4519512653,
-0.0332035534,
-0.0213230066,
0.0298749097,
0.536924839,
-0.4395079613,
-0.6671123505,
-0.2282713503,
0.2201485038,
-0.1040662974,
-0.2639160156,
-0.4156984687,
0.080805406,
0.0840737149,
-0.0574167147,
-0.0967530087,
0.0932798982,
0.1806041747,
-0.0732326284,
-0.375774473,
-0.0778237432,
-0.1428256482,
-0.0618658736,
0.2412936091,
-0.4702972472,
0.3342758119,
-0.1751321554,
-0.2196708173,
-0.3098739982,
-0.4495578706,
0.4461214542,
-0.2912872136,
0.280533433,
0.1335656941,
-0.0281273853,
-0.0904943049,
0.1323567033,
0.2416997254,
0.0652606413,
-0.2522412241,
-0.0285709575,
-0.1227763668,
-0.0927900225,
-0.143141225,
-0.0315606482,
-0.1643955261,
-0.2141999006,
0.2830533087,
0.2059316635,
0.169560492,
0.4932220578,
0.0340704024,
0.0465541445,
-0.220438689,
0.0601628758,
-0.0551540479,
0.07680168,
0.0837127566,
-0.0949174389,
-0.3210145533,
0.0083414773,
-0.1933165789,
0.3068574667,
0.2551884651,
-0.535349369,
-0.1574673802,
-0.2421327829,
-0.0183110572,
-0.1570775807,
-0.0729088411,
-0.0670791119,
-0.0259783529,
0.0689643323,
-0.2773470581,
-0.1267387569,
0.0135351615,
0.1845145822,
0.297039032,
0.3197332621,
0.1418926418,
0.3920771778,
0.3586410582,
0.4529589713,
-0.1417458355,
0.5425727367,
-0.3056810796,
0.2285239697,
-0.0003578217,
-0.2642246485,
0.1242552102,
0.0056967852,
-0.2451540381,
0.0259367414,
-0.1982394457,
-0.5317398906,
-0.1564096659,
-0.0405075476,
-0.4192202389,
-0.3382885456,
-0.0319579579,
-0.1646830291,
0.0040249936,
-0.159980461,
0.3140943646,
0.0597805306,
-0.0306343064,
0.0622879378,
0.26689592,
0.2811965048,
0.0337612443,
-0.2442508936,
-0.5483960509,
-0.0478150919,
-0.109983623,
0.0940203145,
0.6502254605,
0.1011737436,
-0.1530685574,
0.3532949984,
-0.169388935,
0.9698776007,
-0.168799147,
-0.0587971583,
0.0549829379,
-0.2719101012,
-0.1153708547,
-0.0871402249,
-0.3302236497,
0.1092316881,
-0.0299321935,
0.2144999951,
-0.0940628424,
-0.1655836105,
0.3453619778,
0.2768299878,
-0.0531517752,
-0.2493760139,
-0.3809150755,
-0.2441886812,
-0.2114200294,
-0.169664219,
0.0064072493,
0.0642482564,
-0.1457093805,
0.0311311148,
-0.2183039486,
-0.0517946854,
0.0945497081,
0.2018722147,
0.3308178186,
-0.1110589579,
0.0573489219,
0.477576524,
0.3214190006,
0.1896197349,
0.6968442798,
0.2392142415,
-0.3270980716,
0.2334610224,
-0.107989274,
0.3428318202,
0.4110727906,
-0.3313499093,
-0.1545266956,
0.0069373595,
-0.0782926604,
-0.5115798116,
0.0084741013,
0.5992896557,
-0.037533246,
-0.2583073676,
-0.2781049609,
0.4663536847,
0.169316709,
0.0169309936,
0.3580373526,
0.1358114779,
-0.1751042455,
0.4864670336,
0.228834033,
0.8455576897,
0.1209962592,
0.2939697802,
0.4224259853,
0.3353191614,
0.3801471591,
0.3566530049,
0.4553161263,
-0.1395437866,
-0.3074578047,
-0.0979816392,
-0.1295251548,
0.267428726,
-0.2120199949,
-0.1963583827,
0.1333647668,
0.1920779496,
0.0173898749,
0.1891670674,
0.0591910109,
-0.1576901674,
0.0261477381,
0.1478755325,
0.0594600774,
0.1096005589,
0.2237093598,
-0.0316241607,
-0.2756040692,
-0.1601117998,
-0.033203207,
-0.0692449212,
0.2857002318,
-0.1597458422,
0.0567595847,
-0.0927287862,
-0.4266738892,
-0.0010148826,
0.1744379997,
0.0568840392,
-0.2200216949,
-0.0896201283,
0.1542308182,
0.168826133,
-0.0223020297,
0.1710251123,
-0.3031279147,
0.387878865,
0.0805061311,
-0.1671567857,
-0.1760260463,
0.1087598428,
-0.1240904182,
-0.2052264959,
0.2027304024,
0.0415163711,
-0.0058282102,
0.134045288,
-0.0713784844,
-0.2333335727,
-0.057930503,
0.0386290886,
0.0046551195,
-0.0550559424,
0.3446244597,
-0.0592515841,
-0.3210851848,
0.0004685084,
0.1963219792,
0.0532658584,
-0.0455546193,
0.4408788383,
0.0655926988,
-0.1315326393,
-0.1376132071,
-0.0584696047,
-0.2034247518,
-0.3570270538,
0.1680188477,
-0.1583170593,
0.3663455248,
0.0292020608,
0.2343738824,
-0.0862145573,
-0.2577081919,
-0.3752186596,
-0.3225066662,
0.1021640524,
0.2387773395,
-0.2893354595,
0.3101855516,
-0.2281771153,
0.0394172147,
-0.0403806046,
-0.217087701,
-0.1792784482,
0.0203513745,
-0.0998893306,
0.1382425725,
-0.1023778096,
0.1446611285,
0.2018764019,
0.1554449946,
0.1286728382,
0.3066834509,
0.118536666,
-0.0426075421,
-0.2281301767,
0.1551572233,
0.2180823237,
-0.2419922948,
0.0456488729,
-0.3219560385,
-0.0613145158,
-0.2338880897,
-0.044587031,
-0.136172384,
-0.0048175124,
0.3961289525,
0.0188780613,
0.1724835187,
0.14394328,
0.0578872301,
-0.1228662282,
0.3033450842,
0.2065384835,
0.2804700732,
0.0630804822,
0.0815747976,
0.0110293403,
0.0231310762,
-0.0801139548,
0.032849323,
0.3478945494,
-0.1121951863,
0.2336420715,
-0.1369083226,
0.5862511992,
0.5209833384,
-0.24800542,
-0.1729686856,
-0.0361253843,
0.0867233127,
-0.1164368913,
0.1297269017,
0.4025743902,
0.1255043149,
0.1042471379,
0.5003467798,
0.1350826025,
0.2695039213,
-0.0576915406,
-0.2089366764,
0.2463546991,
-0.1895342916,
0.0843628645,
0.3155271709,
-0.0960966423,
0.0895769596,
0.3168870807,
0.2039321512,
0.1217236146,
0.8885148764,
-0.2448637038,
0.2934722006,
0.0139344046,
0.0318382755,
0.1547065377,
-0.1831746995,
0.2279590964,
-0.0922506675,
0.1433863044,
0.2621078193,
-0.1594635397,
-0.0532818884,
0.1269477159,
-0.0946944207,
-0.0596776977,
0.1467305422,
-0.017019812,
0.1761891246,
-0.5308385491,
-0.102555953,
-0.1844325662,
-0.1603719145,
0.1274783611,
-0.3817277551,
0.3352485895,
0.4168066382,
0.0195733197,
-0.3106604517,
-0.2493772656,
-0.0895046815,
0.4062492847,
-0.310041517,
0.2735872269,
0.2185860425,
0.1261631697,
0.2176539004,
0.2808022201,
0.3189855516,
0.2950964272,
-0.1773297489,
-0.0031988644,
-0.2101048231,
-0.2451656908,
-0.2312411815,
0.3012098968,
-0.1426053345,
0.203103438,
0.4468165338,
0.0076993294,
0.0266683139,
-0.2484324574,
0.0967314392,
0.0449315496,
-0.4837929904,
0.4015931189,
-0.3121537268,
0.2306332588,
-0.0080159791,
-0.1881865114,
-0.4608894289,
-0.3066643476,
0.2317482382,
-0.1269942969,
0.1852081418,
0.0438133404,
0.0027230179,
-0.3784215748,
0.1718917638,
0.4974240959,
0.3708814979,
-0.0782346874,
0.1017653495,
-0.3792223334,
0.1070066914,
-0.1793292761,
-0.472638011,
-0.0823605657,
0.4863888323,
0.039982412,
0.0967359468,
0.4376549721,
-0.028484527,
0.5050327182,
0.3949063122,
-0.2051971704,
-0.4761006534,
0.131086722,
-0.0181675367,
-0.1828557253,
-0.3395167589,
0.236920014,
-0.4530845881,
0.0146071604,
-0.0369776115,
-0.2728770077,
0.0934363902,
-0.3673613369,
0.5490912795,
0.360443294,
0.4190846384,
-0.1603540927,
-0.445002228,
-0.2884740829,
-0.131062299,
-0.3096882403,
0.2710428238,
-0.0597963929,
0.5430458188,
-0.1812533587,
0.1232454255,
-0.1973505467,
0.024798017,
0.0610899739,
-0.0757194012,
-0.3415011466,
0.3965411484,
-0.1850146204,
0.171698764,
0.0358286239,
0.3281031549,
0.0887417123,
0.161083445,
-0.2951650023,
-0.4786057472,
0.3932519853,
-0.685706377,
-0.1231316775,
0.2091217041,
-0.1389036626,
-0.0273800995,
0.1229156479,
-0.3377478123,
-0.1895880103,
0.3041598797,
-0.1479600221,
-0.1092422754,
0.2683527768,
0.2344472706,
0.0557444245,
-0.1065995023,
0.3324823976,
0.2427684516,
-0.1845074445,
0.2475114167,
-0.0360292345
] |
https://github.com/huggingface/datasets/issues/3465 | Unable to load 'cnn_dailymail' dataset | Hi @talha1503, thanks for reporting.
It seems there is an issue with one of the data files hosted at Google Drive:
```
Google Drive - Quota exceeded
Sorry, you can't view or download this file at this time.
Too many users have viewed or downloaded this file recently. Please try accessing the file again later. If the file you are trying to access is particularly large or is shared with many people, it may take up to 24 hours to be able to view or download the file. If you still can't access a file after 24 hours, contact your domain administrator.
```
As you probably know, Hugging Face does not host the data, and in this case the data owner decided to host their data at Google Drive, which has quota limits.
Is there anything we could do, @lhoestq @mariosasko? | ## Describe the bug
I wanted to load cnn_dailymail dataset from huggingface datasets on Google Colab, but I am getting an error while loading it.
## Steps to reproduce the bug
```python
from datasets import load_dataset
dataset = load_dataset('cnn_dailymail', '3.0.0', ignore_verifications = True)
```
## Expected results
Expecting to load 'cnn_dailymail' dataset.
## Actual results
`NotADirectoryError: [Errno 20] Not a directory: '/root/.cache/huggingface/datasets/downloads/1bc05d24fa6dda2468e83a73cf6dc207226e01e3c48a507ea716dc0421da583b/cnn/stories'`
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.16.1
- Platform: Linux-5.4.104+-x86_64-with-Ubuntu-18.04-bionic
- Python version: 3.7.12
- PyArrow version: 3.0.0
| 141 | Unable to load 'cnn_dailymail' dataset
## Describe the bug
I wanted to load cnn_dailymail dataset from huggingface datasets on Google Colab, but I am getting an error while loading it.
## Steps to reproduce the bug
```python
from datasets import load_dataset
dataset = load_dataset('cnn_dailymail', '3.0.0', ignore_verifications = True)
```
## Expected results
Expecting to load 'cnn_dailymail' dataset.
## Actual results
`NotADirectoryError: [Errno 20] Not a directory: '/root/.cache/huggingface/datasets/downloads/1bc05d24fa6dda2468e83a73cf6dc207226e01e3c48a507ea716dc0421da583b/cnn/stories'`
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.16.1
- Platform: Linux-5.4.104+-x86_64-with-Ubuntu-18.04-bionic
- Python version: 3.7.12
- PyArrow version: 3.0.0
Hi @talha1503, thanks for reporting.
It seems there is an issue with one of the data files hosted at Google Drive:
```
Google Drive - Quota exceeded
Sorry, you can't view or download this file at this time.
Too many users have viewed or downloaded this file recently. Please try accessing the file again later. If the file you are trying to access is particularly large or is shared with many people, it may take up to 24 hours to be able to view or download the file. If you still can't access a file after 24 hours, contact your domain administrator.
```
As you probably know, Hugging Face does not host the data, and in this case the data owner decided to host their data at Google Drive, which has quota limits.
Is there anything we could do, @lhoestq @mariosasko? | [
0.0230112392,
-0.2250259519,
-0.0139150498,
0.5434482098,
0.193967402,
0.155185923,
0.3652308881,
-0.1235437617,
0.1347780377,
0.3054012954,
-0.2102699578,
-0.1074482426,
-0.3181639016,
0.3879696429,
0.0041485336,
-0.0061607179,
-0.0407173187,
-0.131753847,
0.169201389,
0.0624725521,
-0.2353702188,
0.4150596261,
-0.2294250429,
-0.0838035792,
-0.4770189226,
-0.1755900681,
0.1128521264,
0.3310137093,
-0.0377258472,
-0.0648799688,
0.2543582022,
-0.1035666242,
0.1995365471,
0.5372695327,
-0.0001254998,
-0.0555215627,
0.3967917562,
-0.0005925116,
-0.5252461433,
-0.371539861,
0.172691226,
-0.3304091692,
0.185120672,
0.0218205713,
-0.0387996994,
0.0655032694,
0.1637998819,
0.0114585012,
0.481193006,
0.2550406754,
0.1010259315,
0.0352416411,
0.2433707118,
0.0704188347,
-0.0020349259,
-0.0124463951,
-0.0387878269,
0.7515339851,
-0.0503057428,
-0.0454492196,
0.3414473236,
0.1512460113,
-0.138803497,
-0.0447145328,
0.1979107708,
0.1772915572,
-0.2959626913,
-0.5034222007,
0.2351294905,
0.1063975319,
0.3145456314,
-0.0675583109,
-0.2313409597,
-0.3294519782,
0.095032081,
-0.1341523379,
0.3958298266,
0.3932414353,
-0.2202925682,
0.143406868,
-0.4104233384,
-0.2003125101,
-0.156899184,
0.268776685,
-0.2365627885,
0.0405124873,
-0.2253817469,
0.0834423229,
0.220682323,
-0.1398703456,
0.3458630443,
-0.0576565526,
0.1683301479,
0.1789550781,
-0.1392947137,
0.2394211441,
0.0945104212,
0.3798232973,
0.1144431159,
-0.0593501925,
0.0062104426,
-0.1760040075,
-0.2923935652,
0.1631810814,
0.2653345764,
0.2462628037,
-0.1383962482,
0.1303694993,
0.2692581713,
0.4706643522,
-0.0062936773,
-0.1149025783,
-0.233252272,
-0.1110918894,
-0.1398420185,
-0.1631757915,
0.4632208049,
-0.1027576923,
-0.3627827168,
0.0974245742,
-0.480166167,
0.120421648,
0.259185642,
0.4501114786,
-0.1253007203,
-0.3054505289,
0.0464824401,
0.0186543446,
-0.013865266,
0.0258602351,
-0.1992219388,
0.19674851,
-0.0810763612,
0.3058436513,
0.2914205194,
-0.5062553287,
0.1622044146,
-0.0972942486,
0.424696058,
-0.2943908274,
-0.1976757199,
-0.1862357408,
-0.2110635489,
0.4570817947,
0.0382620618,
0.1559117287,
0.1811482906,
-0.1450173706,
-0.1126013249,
0.2071551681,
-0.4280308187,
-0.5033729076,
0.2137934268,
0.0317512713,
-0.3086360097,
-0.0129838362,
-0.3929104209,
0.1536565572,
-0.02076439,
-0.2166943997,
-0.1443377137,
0.1148529276,
-0.2740401924,
-0.2169231474,
0.3172529936,
0.742406249,
-0.3934477866,
-0.0715921745,
-0.1910043061,
-0.088080205,
0.1371551156,
0.4123043716,
-0.1544851512,
-0.0682029426,
-0.3380495608,
-0.2568275034,
-0.1611900181,
-0.1022491232,
-0.6697843075,
-0.0635760874,
-0.177850157,
0.2048619241,
-0.0379864462,
-0.0530771837,
-0.1901345104,
-0.053888768,
0.3706637621,
0.3607908785,
-0.027159417,
0.0379077047,
-0.2132963091,
-0.2990060151,
-0.05113272,
0.2017906755,
0.1830849349,
0.1509729028,
0.1484084576,
-0.1326339841,
0.0311850123,
-0.0587780848,
-0.1522221118,
0.2634431124,
0.3047015965,
0.044364538,
-0.0147395069,
0.1549904644,
-0.5649026632,
0.1647636592,
0.0730359033,
0.0641485751,
-0.1525344998,
-0.0473678,
-0.2791848481,
0.164805457,
0.0489795804,
-0.0516735688,
-0.0341663621,
0.070538111,
-0.0238654763,
0.1793436557,
-0.0804403499,
0.5021485686,
-0.1490390301,
0.0923116505,
-0.378734082,
0.5213672519,
-0.1040111184,
-0.1225111112,
0.0737372041,
0.1268048286,
0.2142615616,
-0.1718752682,
-0.0749874786,
0.0761469901,
-0.0529296473,
0.3394693732,
0.0592220984,
0.1186387613,
0.2243255973,
-0.145850718,
0.0773984566,
0.2169711888,
0.0589153208,
0.1218710691,
-0.113860406,
0.3146370053,
-0.1091658995,
0.1290401071,
0.0641204715,
-0.047632847,
0.04639275,
0.0392925404,
0.1575432569,
-0.0965402573,
0.3605920374,
0.0205586348,
0.3672628403,
0.0420412607,
-0.2838921845,
0.129020378,
0.1141857803,
-0.1277034581,
-0.0297754854,
0.2732397318,
-0.2875919044,
-0.1847157031,
-0.0308264177,
0.2713724077,
0.2499833703,
0.1059540808,
0.0103190653,
0.080488801,
0.3138589263,
-0.1738961935,
0.1642559171,
0.2570934892,
0.1052148268,
0.1125634536,
0.2179976255,
0.0634158701,
-0.3104629517,
-0.2177763134,
0.1112924144,
0.402770102,
-0.3929148316,
0.1998315901,
0.0058504269,
-0.2730061412,
0.0712344944,
-0.2157378942,
-0.3645641506,
-0.1664580852,
-0.0500364676,
0.3437080085,
0.1183916256,
-0.1574751437,
0.3576327562,
0.476180166,
0.0891631171,
-0.164345488,
-0.2879025638,
0.0644492358,
-0.129393816,
-0.0842645168,
0.4242931306,
-0.2705403864,
0.1854596734,
-0.0588538237,
-0.1219885424,
-0.271402508,
-0.1778676212,
0.1126490608,
0.053753823,
0.6729847789,
-0.1541174799,
0.3009420931,
-0.3657963574,
-0.0313788466,
0.0215454623,
0.0066656307,
-0.0682364032,
-0.0517067648,
-0.0092733549,
0.185694918,
-0.011389479,
0.0836858451,
-0.5145084858,
-0.2973094285,
0.281797111,
0.0171647351,
0.1146263033,
0.3267268538,
0.0678988174,
0.0973063856,
0.1269857138,
-0.0789710805,
-0.3093142211,
-0.4290425479,
0.3675901294,
-0.2903367281,
-0.3825683594,
0.080325678,
0.1156312451,
-0.1954658777,
-0.1027659029,
-0.5431512594,
-0.4884875119,
-0.1517882645,
-0.2819659114,
-0.2013483196,
-0.1382389814,
-0.0120681832,
-0.1885020882,
0.0793197304,
0.1610140353,
-0.4690048099,
-0.2041217387,
0.2485724837,
-0.000231172,
0.1237238124,
0.2695484161,
-0.1540245265,
0.4549061358,
0.2180375904,
0.122516565,
0.4726418257,
-0.0433106869,
0.3131795526,
-0.0419953428,
-0.4830942452,
0.1025139242,
0.1508880854,
-0.4315978885,
0.3981680572,
0.1568837911,
-0.0357066058,
-0.1791842133,
-0.4299519658,
-0.4629656374,
-0.1877419353,
0.1392081678,
0.4094994962,
0.0855225027,
0.1021153256,
-0.1479937732,
-0.0458546169,
-0.3708622754,
-0.2171781361,
0.3612805307,
0.2815314531,
0.0573716089,
0.5227063298,
-0.1753107905,
-0.4835708141,
0.3320505321,
-0.0750573352,
0.0044236016,
-0.2176563293,
0.2240891159,
0.3493005037,
0.018338928,
0.6729198694,
0.0860197097,
0.1230908781,
-0.165053159,
-0.0596665218,
-0.2428670973,
-0.0638099685,
-0.1544883847,
0.2189410925,
0.1280116439,
0.5671950579,
-0.2204650044,
0.0818491727,
0.3434484601,
0.2735311985,
-0.2851184607,
-0.3201811612,
-0.2834717929,
-0.4377007186,
-0.3728218079,
-0.1668748558,
-0.0708594397,
0.3536805212,
0.0790855363,
-0.1088425145,
0.0957783014,
-0.0528090969,
0.1900837868,
-0.014435729,
0.3425257206,
0.2978557944,
0.044555001,
0.2427717894,
-0.149389267,
0.4773953557,
0.8022812009,
0.1604093611,
-0.0778871328,
0.1726851016,
0.2413397133,
-0.0293302257,
0.5245705843,
-0.3356829584,
-0.2805913389,
0.1082376763,
0.4289918244,
0.104542993,
0.0043655401,
0.0987800807,
0.0036993213,
-0.4599878192,
-0.2866397202,
0.6193216443,
0.0905611292,
-0.0058585932,
0.1339650154,
0.2783890665,
-0.0826490223,
0.2076689452,
-0.0580713414,
1.1685863733,
-0.333717376,
0.0280351024,
0.3665155172,
0.2228088826,
0.6446738243,
-0.2638379335,
0.0471947342,
-0.1643414199,
-0.4541432261,
-0.1057163328,
-0.1120788977,
-0.1656373143,
0.1780627668,
0.0196444374,
0.2112546265,
-0.2392373532,
-0.0455429815,
0.1773397923,
0.1924790591,
-0.2600633204,
-0.0375723764,
-0.4765172601,
-0.0473900922,
-0.1301769465,
0.3917047977,
-0.1993466914,
0.0092599448,
-0.1568053514,
-0.0890870988,
-0.3677794635,
0.0306198318,
-0.4243729115,
0.037934497,
-0.0695433766,
-0.4833182693,
-0.0826179832,
0.2519901395,
0.0742538422,
0.0512145199,
-0.2707873285,
0.0000841932,
-0.3628006279,
-0.337038517,
-0.3055316806,
-0.0772114024,
0.3080633581,
-0.0920216814,
-0.1391798854,
-0.1263867021,
-0.0123577742,
-0.1751523465,
-0.0061063166,
0.4029521048,
-0.2140069455,
-0.0818587169,
-0.4091351628,
-0.20375745,
0.0610224344,
-0.0812991858,
-0.0013720918,
0.0907179192,
-0.0344983339,
-0.1233320907,
0.0831752345,
-0.2104346454,
-0.1372809708,
0.331594646,
-0.0808468685,
-0.1224198118,
0.4333912432,
0.3078630865,
-0.118194513,
-0.0067003886,
0.0257216897,
-0.0067794411,
-0.3567312956,
0.3901322484,
0.1107610613,
0.3732691407,
-0.222583577,
0.3416835368,
0.4164263308,
-0.0237320252,
-0.0489094481,
-0.7265585661,
-0.09988866,
0.2330420017,
-0.1408514678,
-0.0315152183,
0.1510657966,
-0.0624876693,
0.1577699929,
-0.1688766927,
-0.1696689874,
0.3009059131,
-0.2748534083,
-0.2980515063,
0.4028091133,
-0.0531705543,
0.5605329275,
-0.06297791,
-0.0146392267,
0.0135049578,
0.049541492,
-0.1616690159,
-0.0712985024,
0.2309400737,
0.1091753393,
-0.107904084,
-0.1350670755,
-0.0955625996,
-0.0785979256,
-0.1818812788,
0.2442010194,
0.3197699189,
0.1826762557,
-0.3261145055,
0.060491845,
0.072457999,
-0.2569792867,
0.1787572354,
0.0670899972,
0.3380453289,
0.3052426875,
0.1743869931,
0.2268178761,
0.0749698803,
-0.1234937757,
-0.0257084705,
0.0455030017,
-0.0036689667,
0.1659995615,
-0.3080082834,
-0.0510748811,
0.0870931745,
0.2065155655,
0.2210083008,
-0.3074331582,
0.0601546094,
0.2663276792,
-0.0294282045,
-0.1425258964,
-0.1188140288,
0.3300028443,
-0.0366300531,
-0.0521070845,
0.4091111422,
0.0508265011,
0.1052067801,
-0.2362134606,
0.0671382174,
0.5380592942,
0.3395126462,
0.054163184,
-0.0026138672,
-0.0058668694,
0.1817464828,
0.2804040015,
0.1739379615,
0.3209274113,
0.2563081086,
-0.2444178015,
-0.1060096174,
-0.2329495102,
0.1747534871,
0.0626814514,
-0.785079658,
0.2555248439,
0.2741450965,
-0.0813732296,
0.0664628223,
-0.1280222088,
0.5216854811,
-0.2403289527,
0.1654502153,
-0.3090310693,
0.3976143897,
0.0113732694,
0.144932434,
0.4864100218,
-0.2026474029,
-0.1260928959,
0.311273098,
0.1746411175,
-0.5492194295,
0.1355056763,
0.2509671152,
-0.3275170922,
-0.0062311268,
-0.0527078211,
0.5133515596,
0.0514747724,
-0.1854082942,
0.2921259403,
-0.0837785602,
-0.0424105301,
-0.0107778572,
0.3013875782,
0.4020623267,
0.1962006837,
0.1805117726,
0.1986573189,
0.0188407749,
-0.0096818246,
-0.0948885307,
0.1434370875,
0.2740193307,
0.2370835543,
0.0776501969,
0.0536524206,
-0.139192149,
0.0407775156,
0.0933568031,
0.1644346416,
-0.3744286001,
-0.0005316097,
-0.397377938,
-0.0740772262,
-0.2731116116,
-0.2424464524,
-0.4610730112,
0.0992190838,
0.0816298425,
-0.0755861104,
0.0778957531,
0.1260101497,
-0.02198424,
-0.035294231,
0.3492086232,
0.5010406375,
0.5173603296,
-0.2998112738,
-0.1671911776,
-0.7030151486,
0.2775581777,
-0.0495375991,
0.1515673697,
0.0361125134,
-0.0840073004,
-0.2369025648,
0.0658254474,
0.0516816005,
0.2019709051,
0.0216426272,
-0.1019746885,
-0.1868080795,
-0.2806376815,
0.1594229788,
-0.1355352998,
-0.1254737973,
-0.2357931137,
0.1472264975,
-0.6363112926,
-0.1875900924,
-0.0583523884,
-0.0263241213,
-0.3959384561,
-0.0814173073,
0.5767704248,
0.1684847027,
0.4447923005,
-0.0101942616,
-0.1143373102,
-0.2473177612,
-0.1398468912,
-0.174427405,
0.2723055184,
0.1667646319,
0.2467364967,
-0.2468883395,
-0.3459103405,
-0.2486265302,
0.3300250471,
-0.0151248276,
0.0133941174,
-0.0521786734,
-0.0897432566,
-0.1953429282,
0.1547024995,
0.1033101603,
0.1938563138,
-0.0699016675,
0.0693825334,
-0.1832973957,
-0.2304178327,
0.6169713736,
-0.3983101249,
-0.1480482817,
0.2376838624,
0.2703152597,
0.2415257841,
-0.3101540208,
-0.3595016599,
0.1901289225,
0.2610164881,
0.1175692379,
-0.2685656846,
0.137209177,
-0.2138935477,
-0.1010649353,
-0.0171547905,
0.2757959664,
0.2763234377,
-0.2513564527,
0.2019842416,
-0.0778160468
] |
https://github.com/huggingface/datasets/issues/3464 | struct.error: 'i' format requires -2147483648 <= number <= 2147483647 | Hi ! Can you try setting `datasets.config.MAX_TABLE_NBYTES_FOR_PICKLING` to a smaller value than `4 << 30` (4GiB), for example `500 << 20` (500MiB) ? It should reduce the maximum size of the arrow table being pickled during multiprocessing.
If it fixes the issue, we can consider lowering the default value for everyone. | ## Describe the bug
A clear and concise description of what the bug is.
using latest datasets=datasets-1.16.1-py3-none-any.whl
process my own multilingual dataset by following codes, and the number of rows in all dataset is 306000, the max_length of each sentence is 256:
![image](https://user-images.githubusercontent.com/30341159/146865779-3d25d011-1f42-4026-9e1b-76f6e1d172e9.png)
then I get this error:
![image](https://user-images.githubusercontent.com/30341159/146865844-e60a404c-5f3a-403c-b2f1-acd943b5cdb8.png)
I have seen the issue in #2134 and #2150, so I don't understand why latest repo still can't deal with big dataset.
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version:
- Platform: linux docker
- Python version: 3.6
| 51 | struct.error: 'i' format requires -2147483648 <= number <= 2147483647
## Describe the bug
A clear and concise description of what the bug is.
using latest datasets=datasets-1.16.1-py3-none-any.whl
process my own multilingual dataset by following codes, and the number of rows in all dataset is 306000, the max_length of each sentence is 256:
![image](https://user-images.githubusercontent.com/30341159/146865779-3d25d011-1f42-4026-9e1b-76f6e1d172e9.png)
then I get this error:
![image](https://user-images.githubusercontent.com/30341159/146865844-e60a404c-5f3a-403c-b2f1-acd943b5cdb8.png)
I have seen the issue in #2134 and #2150, so I don't understand why latest repo still can't deal with big dataset.
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version:
- Platform: linux docker
- Python version: 3.6
Hi ! Can you try setting `datasets.config.MAX_TABLE_NBYTES_FOR_PICKLING` to a smaller value than `4 << 30` (4GiB), for example `500 << 20` (500MiB) ? It should reduce the maximum size of the arrow table being pickled during multiprocessing.
If it fixes the issue, we can consider lowering the default value for everyone. | [
-0.5384347439,
-0.0822646469,
-0.0349175334,
0.2288364023,
0.1133689433,
-0.1969540268,
0.201079458,
0.4309723377,
-0.0918042138,
0.3907878697,
0.1387392133,
0.1428714097,
0.1288889349,
0.2428794503,
-0.0235357638,
-0.0707039982,
0.1808978468,
0.0859175995,
-0.1746377945,
0.1659533381,
-0.2032332569,
-0.0278888475,
-0.1630536914,
-0.1536658406,
-0.5480694175,
0.0005016553,
-0.0620194711,
-0.0101390649,
-0.4876845777,
-0.3528680205,
0.2218103409,
0.088629514,
0.0819905773,
0.4113059938,
-0.0001241034,
-0.026836263,
0.5084323287,
-0.2209366262,
-0.2780166864,
-0.2772828341,
-0.2406198531,
-0.5049485564,
-0.1133875027,
-0.173750639,
0.077378951,
-0.0634901524,
-0.2675308585,
-0.056267485,
0.1371560097,
0.2442339063,
0.1534084678,
0.2857001424,
0.5780898333,
-0.0958923027,
0.297857821,
0.0326470546,
-0.0568411127,
0.3053092062,
0.4750717282,
0.0986062437,
0.0511922576,
0.3523118198,
0.1782510132,
0.1202767044,
-0.2894182503,
-0.2593256831,
-0.0948943123,
-0.2375608087,
0.34313187,
0.4392082393,
0.6009663939,
-0.1090551838,
-0.5246440768,
0.0183105897,
-0.0566378199,
-0.3611830175,
0.0663551241,
0.4359689057,
0.0446290188,
0.0774465725,
-0.1200003773,
-0.1919210106,
-0.3403610885,
0.109906964,
-0.2807949185,
0.508451283,
-0.0002367606,
0.3241046667,
0.2691236138,
-0.295452863,
-0.1417986006,
0.3741222024,
-0.1445259452,
-0.0082145482,
-0.2889167368,
-0.170432955,
0.0287266355,
-0.3917068839,
0.2970862687,
0.031883914,
-0.2691435516,
0.2176343948,
-0.0289137289,
0.029906936,
0.3956596851,
0.0280892067,
-0.1726853997,
0.2038864791,
0.28403458,
-0.0760360286,
0.0302336365,
-0.1068551764,
0.0657008067,
-0.0927905738,
-0.2750658095,
-0.0823733583,
0.2654270828,
-0.0890703276,
-0.1347195655,
0.1500898153,
-0.332803309,
0.0396794081,
-0.0050683012,
0.2159717828,
0.1468573362,
0.5722495317,
-0.2010577172,
0.2948307693,
-0.2154138088,
-0.3623835444,
-0.0753926635,
-0.0884771571,
-0.0378602408,
-0.242165193,
-0.0638363659,
0.1438659728,
-0.1002694443,
0.0481153391,
0.2022010386,
-0.2782199085,
0.0053422842,
-0.5713707209,
0.1368835121,
0.4288008213,
-0.0164544843,
-0.0347851552,
0.0232266113,
-0.1983046234,
-0.0827634335,
0.2273741663,
-0.4137198925,
-0.5578959584,
-0.3266726136,
0.0692638457,
-0.1159464195,
0.1039782837,
-0.2318882793,
0.0662801415,
0.3114069104,
-0.018980803,
0.0655409172,
-0.4752935171,
-0.013573668,
-0.0178753231,
0.0015024985,
0.26787889,
-0.3704152107,
0.2438281029,
-0.0039738053,
0.0112630809,
0.4659639895,
0.3013342917,
-0.1010149494,
0.089778848,
-0.0275957789,
0.1961849928,
0.2273397744,
-0.2005074173,
-0.5950258374,
0.2643864751,
-0.0811967477,
-0.1140886396,
0.1650772691,
-0.1253836304,
0.1965023726,
-0.0783479363,
-0.1940754801,
0.240680784,
-0.1089028344,
0.1000355333,
-0.1870463789,
-0.4390316308,
-0.1266912222,
0.0379237235,
0.3180192411,
-0.3492605984,
0.1569744498,
-0.024775682,
0.3511512876,
-0.2750968337,
0.3789659142,
0.1059781536,
0.4924575686,
0.0885806084,
0.0620697141,
-0.314127326,
-0.0675398111,
0.2233371586,
0.2673791945,
0.0586742051,
-0.1972018331,
-0.0379452333,
0.0222493056,
0.2262369692,
0.0138760051,
0.0445034318,
-0.0457620323,
0.124109894,
-0.0064022299,
-0.2182147056,
-0.0899345651,
-0.1526757628,
-0.4419277906,
-0.045766294,
0.1152385324,
0.2027308941,
-0.2154668868,
-0.2418033034,
0.0766714439,
0.1940672547,
0.0593014397,
-0.2730768919,
-0.0282814987,
0.1213709563,
0.2589590251,
-0.198790133,
-0.3149820566,
0.1099882871,
-0.0317594782,
-0.1137709022,
0.0759523511,
0.0197080355,
0.0771822259,
-0.0658857375,
-0.0541399941,
0.27415061,
-0.0583594069,
0.4708829224,
0.0479383245,
-0.0793488249,
0.5058754683,
0.0772911534,
0.1070794016,
-0.4674158394,
-0.0611864589,
-0.2018247396,
0.1449434906,
-0.1993955076,
-0.5295600891,
0.2134784609,
0.6119220257,
0.2000370473,
0.2246791571,
0.4339172244,
0.174369663,
-0.076371789,
0.1137667596,
0.2270752937,
0.2086992413,
0.1714583039,
-0.0626734719,
-0.2532311678,
0.0923594087,
-0.127548039,
0.1618091315,
0.0539892167,
0.3573838174,
0.287314713,
0.3187532723,
-0.1501568258,
-0.2116696537,
-0.1474033594,
0.0437047742,
0.2525758147,
-0.1025980189,
0.313988179,
-0.3828184903,
-0.2048491091,
-0.3216044903,
-0.4308439493,
-0.0579518117,
-0.1950393468,
-0.2190294266,
0.1713604927,
-0.1697763801,
0.0281076618,
0.1976945698,
0.1917213053,
0.1490097493,
0.1287997961,
0.0231580827,
-0.1631803364,
-0.1982566714,
-0.0015913964,
0.3123295009,
-0.2358710319,
0.2853460312,
0.0015745123,
-0.0418018848,
-0.1202196181,
-0.5259143114,
0.1528807133,
-0.0606180131,
0.0873551071,
0.1366587728,
0.2795855701,
0.1262057722,
0.1552205086,
0.2027642578,
-0.1644734591,
-0.1822625995,
-0.0118763642,
-0.2220064104,
-0.1325577199,
-0.1650479883,
-0.094310306,
-0.2029576004,
-0.4268335104,
0.5911214352,
0.1336918026,
0.3321899176,
-0.0247484893,
0.5224890113,
0.2492329478,
0.1395518929,
-0.0767246112,
0.0294441283,
0.1448996961,
0.1411738992,
0.0349970609,
-0.3560548723,
-0.1640522629,
0.1744731963,
0.1618974507,
0.2223564386,
-0.4293689132,
0.0939312875,
-0.4254790843,
0.2123131007,
-0.2394696325,
0.3795749247,
0.2940498888,
-0.0471875966,
-0.0419976413,
-0.1430197805,
0.0739415959,
-0.0580585375,
0.2688376904,
-0.0045851064,
0.1756287366,
0.5213538408,
0.1682528257,
0.6480834484,
0.2791674435,
0.0852251574,
0.3997262716,
0.2305714935,
0.330825448,
-0.5880966187,
-0.1565574855,
0.1712594777,
-0.1718951166,
0.1985255033,
0.1146781743,
-0.0137246661,
-0.1543588936,
0.2102100104,
0.0113799581,
0.2315407395,
0.0026388138,
0.4415616095,
-0.0638543069,
0.0689285398,
-0.1660569757,
-0.154517144,
-0.1380165964,
-0.2316998243,
-0.3195539415,
-0.1463939995,
-0.0342674293,
0.2602034807,
-0.1800633222,
-0.2106131017,
-0.25551036,
0.2091888636,
0.2654499412,
0.613049686,
0.085103102,
0.0828496963,
0.1122368351,
-0.340632081,
0.4482613504,
-0.0624946021,
0.0060886038,
0.1198295131,
-0.0757918209,
-0.3448084593,
-0.0316129811,
-0.291763097,
0.4412479103,
0.4050803185,
0.6304172277,
-0.2338057458,
-0.0778531134,
0.1629497707,
0.3138386011,
0.0663182586,
-0.1264612824,
-0.3967801034,
-0.355589956,
-0.5074554086,
0.3222976923,
0.2625384629,
0.2309900373,
-0.1738268733,
0.0639274865,
-0.2294196039,
-0.5289065838,
-0.3108128011,
-0.1100471243,
0.14200975,
-0.0180922188,
-0.0319796577,
-0.095527105,
-0.1090257391,
0.6083317995,
0.6386574507,
0.1554345489,
-0.1162251905,
-0.0563940778,
-0.324078083,
0.1706537157,
0.4756177366,
0.1610377282,
0.2933528423,
-0.1021980718,
0.2594384849,
-0.0920309722,
0.0432947762,
-0.0001342269,
0.2639670372,
-0.3785118163,
-0.2899216115,
0.3723517954,
-0.0285287406,
0.1010925993,
0.3849809468,
0.4595189393,
-0.2238564044,
0.3124081194,
0.2094329,
0.96128124,
0.0957588553,
-0.0811018199,
-0.1574026495,
-0.4068515599,
0.3147561252,
-0.1918753386,
0.2395380288,
-0.3074727058,
0.028767271,
0.0047581177,
-0.1958364546,
0.2242917866,
0.086464107,
-0.1651848555,
0.0248681717,
-0.1835017353,
0.0373843387,
0.222611323,
0.4805130959,
-0.2222173363,
-0.0683258772,
-0.0198943727,
0.0701176599,
-0.1918662935,
-0.3475186825,
-0.1434644312,
0.0564169884,
-0.0887257606,
-0.331153959,
-0.6009178758,
-0.0501521714,
-0.1913472712,
0.4850848615,
0.1111148596,
-0.2596918941,
0.3312962949,
0.0992868617,
-0.2224989086,
0.2426911145,
-0.1968048066,
0.044978857,
0.2140596956,
-0.2179249525,
0.1713900864,
-0.2333965898,
0.2718837559,
-0.1839514375,
-0.5272607207,
-0.2345169485,
-0.020028919,
-0.1744033396,
0.0382145457,
0.3440024555,
0.2743944228,
0.112194404,
-0.1713794619,
-0.0288368277,
-0.1310868412,
-0.2223452926,
0.0218244419,
-0.0471958704,
0.0294145718,
0.2574279308,
0.1421973407,
-0.2220790237,
-0.1245333552,
0.1820690036,
0.2475413829,
0.3437626064,
0.4252687991,
0.2528610826,
-0.2143445611,
-0.1560688019,
0.25361076,
0.0218445789,
-0.3301753104,
0.1430631429,
-0.2989763916,
-0.1679290086,
-0.0937651247,
0.0633061901,
0.1262496263,
0.0802868158,
-0.2944082022,
-0.4541395009,
-0.2288052142,
-0.0417727455,
-0.1418337375,
0.021634331,
-0.3180625439,
0.1263810396,
-0.018772224,
0.3844796121,
-0.1748156548,
0.1040854678,
-0.1337421089,
0.2777832747,
0.1074284241,
-0.0931338742,
-0.0579853505,
-0.132804215,
-0.1241667643,
0.1625743359,
-0.1911480278,
-0.0788548067,
-0.2251809537,
0.1440880895,
0.0948171243,
-0.2794017792,
0.128097862,
-0.2697423398,
-0.1288551241,
-0.1369848996,
0.1392014623,
-0.0961069018,
-0.1640239805,
-0.1003506258,
0.3733714521,
0.0355077013,
0.0213679839,
0.1051607579,
-0.0087261563,
0.4144380391,
0.0038589351,
0.2983624339,
0.5804485679,
0.0532241389,
-0.0902258307,
0.1611072719,
0.068201445,
-0.1521322876,
0.1867899001,
-0.289539665,
0.0782116577,
0.0470758118,
0.3464839756,
0.3356711566,
-0.1035062075,
-0.1838404387,
0.2392095327,
0.1078552455,
-0.132602945,
-0.1680008322,
0.0845109522,
0.0183658749,
0.005843624,
0.3587918282,
0.326061368,
-0.2113942355,
-0.2410438508,
0.3125891089,
0.1475421637,
-0.3422189951,
0.0233267285,
-0.0170056112,
-0.1622276604,
0.004982376,
0.3635739088,
0.0256411731,
0.236177966,
0.4685514569,
0.1331338584,
0.3298617005,
0.4911170006,
0.0098737497,
0.163454175,
-0.3723644316,
0.169895038,
0.0849265009,
-0.0115780793,
-0.0875187218,
-0.0485095233,
0.2182403952,
-0.0967289656,
-0.1409267932,
-0.1753231287,
-0.0972783342,
-0.3651028872,
-0.0863156691,
-0.255702436,
-0.0964436084,
-0.0595956631,
0.1029494926,
-0.1162594482,
0.121709384,
0.4200067818,
0.1461431831,
-0.1482480019,
-0.4839357734,
-0.0266572386,
-0.1087284237,
0.2618159652,
-0.6033571959,
0.4872021973,
0.4559691846,
-0.0345287696,
-0.0850650743,
0.1882729083,
0.7432591319,
0.5262534618,
0.0642971098,
-0.0021285533,
-0.1307005584,
-0.2615398169,
-0.2165697813,
0.2877939641,
0.1492644548,
0.043577984,
0.3110482991,
0.0132789239,
-0.1400217712,
0.114647992,
0.3183703721,
0.110832721,
-0.133371532,
-0.0349001996,
-0.0982276425,
-0.2503274679,
-0.0631459504,
0.171307385,
-0.4782578647,
0.1083385274,
0.5739856362,
-0.2541250885,
0.0296152811,
-0.0160229933,
0.0190228913,
-0.159303084,
0.7228504419,
0.2624229193,
-0.1889559776,
-0.1090067402,
-0.1309484392,
-0.1089020669,
-0.0503535904,
-0.6927179098,
0.160833478,
-0.0717213601,
0.3882656991,
0.132764712,
0.149345383,
0.1779623777,
0.0642035753,
0.0814509913,
-0.0017051277,
-0.5035834908,
-0.1008044481,
0.1118113697,
0.1070262119,
0.0183788314,
-0.4159671366,
0.3146508634,
-0.2056362331,
0.0564259626,
-0.2436050922,
-0.0442941673,
0.2117047459,
-0.0466813967,
0.1619034857,
0.2872759104,
0.6424854398,
-0.0846304223,
-0.2923576236,
-0.3063107431,
-0.0576023683,
-0.3024797142,
0.3628548682,
0.0993554369,
0.5712060332,
-0.1795850992,
-0.0320146419,
-0.1618715674,
-0.0025192858,
-0.2842956483,
0.3534345627,
0.1879076958,
0.0495422073,
-0.2215997428,
-0.1482675374,
-0.1878611594,
0.1996888816,
0.1761575937,
-0.2071962506,
-0.2979274988,
-0.4424749017,
0.2117962986,
-0.1515697092,
-0.5198546052,
-0.206207186,
0.0546856523,
-0.0049786041,
0.0611270145,
-0.4784041345,
0.2362546474,
0.2158427536,
0.1657815576,
-0.4713754058,
0.3350247145,
0.0848047435,
0.1050149873,
-0.1312925369,
0.5305572748,
-0.0566521361,
-0.3473211229,
-0.1376601011,
-0.0916105434
] |
https://github.com/huggingface/datasets/issues/3457 | Add CMU Graphics Lab Motion Capture dataset | This dataset has files in ASF/AMC format. [ The skeleton file is the ASF file (Acclaim Skeleton File). The motion file is the AMC file (Acclaim Motion Capture data). ]
Some questions :
1. How do we go about representing these features using datasets.Features and generate examples ?
2. The dataset download link for ASF/AMC files does not have metadata information, for eg : category and subcategory information. We will need to crawl the website for this information. The authors mention "Please don't crawl this database for all motions." Can we mail the authors for this information ?
The dataset structure is as follows :
```
subjects
- 01
- 01_01.amc
- 01_02.amc
.
.
.
- 01.asf
- 02
- 02_01.amc
- 02_02.amc
.
.
.
- 02.asf
```
There is no metadata regarding the category, sub-category and motion description.
Need your inputs. @mariosasko / @lhoestq
Thank you.
| ## Adding a Dataset
- **Name:** CMU Graphics Lab Motion Capture database
- **Description:** The database contains free motions which you can download and use.
- **Data:** http://mocap.cs.cmu.edu/
- **Motivation:** Nice motion capture dataset
Instructions to add a new dataset can be found [here](https://github.com/huggingface/datasets/blob/master/ADD_NEW_DATASET.md). | 149 | Add CMU Graphics Lab Motion Capture dataset
## Adding a Dataset
- **Name:** CMU Graphics Lab Motion Capture database
- **Description:** The database contains free motions which you can download and use.
- **Data:** http://mocap.cs.cmu.edu/
- **Motivation:** Nice motion capture dataset
Instructions to add a new dataset can be found [here](https://github.com/huggingface/datasets/blob/master/ADD_NEW_DATASET.md).
This dataset has files in ASF/AMC format. [ The skeleton file is the ASF file (Acclaim Skeleton File). The motion file is the AMC file (Acclaim Motion Capture data). ]
Some questions :
1. How do we go about representing these features using datasets.Features and generate examples ?
2. The dataset download link for ASF/AMC files does not have metadata information, for eg : category and subcategory information. We will need to crawl the website for this information. The authors mention "Please don't crawl this database for all motions." Can we mail the authors for this information ?
The dataset structure is as follows :
```
subjects
- 01
- 01_01.amc
- 01_02.amc
.
.
.
- 01.asf
- 02
- 02_01.amc
- 02_02.amc
.
.
.
- 02.asf
```
There is no metadata regarding the category, sub-category and motion description.
Need your inputs. @mariosasko / @lhoestq
Thank you.
| [
-0.1400220692,
-0.0276257154,
0.0362781696,
0.1367378086,
0.2119433433,
0.2255604565,
0.1493569613,
0.0857909173,
-0.4835159481,
-0.1561218351,
-0.0873227566,
0.0038940383,
-0.2831748128,
0.2164120823,
0.0632067174,
-0.3122251928,
-0.0616576299,
-0.1458100677,
-0.0537849516,
-0.2758546472,
-0.0898389742,
-0.1037116721,
0.0159962904,
-0.0323653594,
-0.6374860406,
-0.0654065982,
-0.3875577748,
0.2147615999,
-0.2260103524,
-0.4087277949,
-0.3373528123,
0.2072522044,
0.4068498015,
0.576507628,
-0.0001131307,
-0.4016377032,
0.0653205812,
-0.2132931799,
-0.1151431724,
0.1641811579,
-0.231039688,
-0.1535726935,
-0.0636353642,
-0.2122583687,
0.0311887581,
-0.3918625414,
-0.0085227638,
-0.3635860384,
-0.1860735416,
0.2949460447,
0.1244692057,
-0.0005026365,
-0.364122659,
-0.1241852343,
0.1355756223,
0.52011621,
-0.2748971879,
0.2489983141,
0.7377387881,
0.1898404807,
-0.2848304808,
0.3149987161,
-0.0378085859,
-0.1511327177,
0.510383904,
0.1605924666,
0.3241169751,
-0.363083303,
0.1048902869,
0.3407910764,
0.8395399451,
-0.2183960825,
-0.2629058957,
-0.1564946771,
0.177472949,
0.1476415545,
-0.1722436696,
0.6073666811,
-0.0209429413,
-0.0168479774,
-0.3747270405,
-0.0319345295,
-0.4083561897,
0.0605072714,
0.0779447854,
-0.0795107558,
-0.2194829434,
0.0350987017,
-0.2649665177,
-0.1569717824,
0.252910614,
-0.2321330756,
0.1644409746,
0.1635805666,
0.1147710532,
-0.1625461727,
-0.0378796048,
0.2688343823,
0.1383372694,
0.2765680254,
0.1975001246,
-0.1224121675,
-0.1890544593,
0.0904500857,
0.0273206439,
-0.058900293,
-0.0227348153,
0.072842285,
0.1150964499,
0.2436123043,
-0.1930197477,
-0.1006023586,
-0.2753274739,
0.1365773231,
-0.1668399125,
0.1390445381,
0.3570899367,
-0.1142525524,
-0.1180442944,
0.1934362054,
-0.0019466864,
-0.0501266308,
0.0684210211,
0.4002505839,
-0.160664022,
-0.1128859445,
-0.1889219731,
0.4748839438,
0.2344406992,
-0.2148489058,
-0.1953553408,
0.1008569971,
-0.327157557,
0.1681254953,
0.3198532164,
0.0254490618,
0.2317335606,
-0.0604691766,
0.1867728978,
0.1004098877,
0.162472859,
-0.1115135401,
0.4061921835,
0.0452840962,
0.0603466406,
0.1594375521,
0.0224959459,
0.2701932788,
-0.2322195917,
-0.0118182311,
0.0611281991,
-0.0307678171,
0.0289253443,
0.1225893945,
-0.0503243878,
-0.0273969509,
-0.1090964898,
0.4404790998,
-0.4700840116,
0.3461493254,
0.2209820598,
0.4172137976,
-0.0245637596,
-0.4634301066,
-0.0932593942,
0.6238136292,
-0.0927883238,
-0.0393049791,
0.0144297201,
0.1332086027,
0.1300578713,
0.1097681969,
-0.043687012,
0.1013089791,
-0.2751731873,
-0.0506909862,
0.0825121105,
-0.2171298414,
-0.0297950413,
0.0677351952,
-0.1304370612,
-0.1525134891,
0.2268569022,
0.2241497934,
0.1370595098,
-0.3030343354,
-0.2862596214,
0.2341411859,
-0.4007502794,
-0.0824843347,
0.156196624,
-0.2114047259,
0.0604808144,
0.134758845,
0.1436563283,
0.1295100302,
0.2639017999,
-0.2452560067,
0.1549333632,
-0.0552619658,
0.0129809771,
-0.1553340554,
0.0980349034,
0.1490193009,
0.1041383147,
-0.1278230697,
-0.4800176322,
0.2161592692,
0.254750222,
0.0406543463,
-0.1503541917,
-0.3730543554,
-0.2745630145,
-0.2620145977,
-0.037265107,
-0.2534670234,
0.176848039,
0.0720309839,
-0.2099178582,
-0.0346773453,
-0.2814797759,
0.1846442074,
-0.1760547161,
-0.02222923,
0.1052461863,
0.3814590275,
0.0925475359,
-0.1060566679,
0.0855626836,
0.3382660747,
0.1607359946,
0.0136168608,
0.0365481861,
0.3229470253,
-0.148742944,
0.4442759454,
0.3780817389,
0.5033134818,
0.294251591,
-0.58589077,
0.5324745774,
-0.3263151348,
0.231619373,
-0.1853383631,
-0.3577287495,
0.123112902,
-0.2889224291,
0.048882965,
0.3499812186,
0.1409685314,
0.0006647895,
0.0613107458,
-0.1616209298,
-0.2185157537,
0.0483856089,
0.2592022121,
-0.1210569739,
-0.0613989271,
-0.3294606805,
0.2543337047,
0.4596469402,
-0.2020507157,
0.1267013699,
-0.1662967205,
-0.699955821,
0.3093130589,
0.2173113525,
0.1033370122,
0.1290133744,
0.2238806188,
0.0963222012,
0.1051131636,
-0.007149078,
-0.0417907126,
-0.020643618,
0.1765353233,
-0.0778209046,
0.0669112429,
-0.1640238166,
0.102993384,
-0.1681706309,
-0.411362648,
0.1688839942,
0.053103067,
-0.3054961562,
-0.2473196238,
-0.0100065814,
-0.2244973034,
-0.0397959873,
-0.0932987779,
0.0178052206,
-0.0389636457,
-0.1140251011,
-0.0812718794,
-0.008412024,
0.0522595532,
-0.7297085524,
0.3797697723,
-0.2959038913,
0.3477703035,
0.1200915799,
-0.0779193193,
0.2251711488,
0.1344409734,
0.1049792096,
0.4389452636,
0.3485678136,
-0.1841530353,
0.7457010746,
-0.5460294485,
-0.2688455284,
0.2574370801,
0.0516890101,
-0.0050662905,
0.1130554602,
-0.0624813437,
-0.1427012831,
0.0007245997,
0.051383689,
-0.2489317656,
-0.0135421241,
-0.0334207155,
-0.1615209579,
-0.3636421263,
-0.0555205606,
-0.0418726653,
-0.050186079,
-0.263907373,
0.0857779905,
0.1531990916,
0.1020027176,
0.2329884022,
-0.1441216469,
0.3608809114,
0.0188693926,
0.2020854652,
-0.276552856,
-0.2311447859,
0.4899628758,
-0.3443777859,
-0.36774683,
0.4210940003,
-0.2119158357,
-0.045455616,
0.1211022511,
-0.0331723243,
-0.1129574478,
-0.2030468732,
0.1302262694,
0.2275917083,
0.1409726292,
0.1904389411,
-0.1411192566,
0.0146395648,
-0.3243466616,
-0.1377447844,
0.1571761072,
0.5568601489,
-0.0669747889,
-0.1256693304,
0.1755598634,
0.0075396029,
0.6380573511,
-0.0577069297,
-0.1499280185,
0.0836146921,
-0.1510769576,
0.1722678244,
0.5456946492,
-0.2156188041,
0.2823482752,
-0.0073133195,
0.0080044195,
0.2393349558,
0.2225772142,
0.1308685243,
-0.121445708,
0.4486290216,
-0.2360796034,
-0.1106454879,
0.0510007292,
0.0674108341,
0.2586898208,
-0.1533031166,
-0.0487310253,
0.0132399444,
-0.0175343566,
0.3076435924,
0.5337830782,
0.1167334393,
0.0030440241,
-0.5993986726,
-0.0068742754,
-0.3679162562,
0.1135574877,
0.139602378,
-0.0844659433,
-0.1076084077,
-0.0514925309,
-0.0450669192,
0.3012185991,
0.3057685494,
-0.6447005868,
-0.1499857605,
0.1341075897,
0.3157890439,
-0.0882883444,
0.0893208981,
-0.3558134139,
0.1763004959,
-0.2218049765,
-0.1696107686,
0.1633060426,
-0.1090830564,
-0.0262482557,
-0.1328303069,
-0.0985751972,
0.0646383613,
0.1433830559,
-0.1639798135,
-0.198723495,
-0.1069783121,
0.2425372303,
-0.4850977957,
-0.0921277404,
-0.221663326,
-0.1551408023,
0.0543943048,
0.4239217043,
0.1562056541,
0.2953242064,
0.3770045936,
0.0826738775,
0.4288123846,
0.3140770793,
0.4876483679,
0.6595791578,
-0.1697886586,
-0.3505460322,
0.4058397114,
-0.4286093414,
0.4908945858,
0.5479184389,
0.0407132618,
0.0441747271,
-0.0784068108,
-0.2023851722,
-0.4696089029,
0.2770144045,
0.1142468899,
-0.1726688147,
0.087333478,
-0.4533536136,
0.2873798311,
-0.0003239668,
-0.1225006357,
-0.2410083413,
0.294113189,
-0.2272094786,
-0.1477145553,
0.2172071785,
1.1629143953,
-0.0229266044,
0.0151167661,
0.0477454141,
-0.0521005169,
0.2330554277,
0.0574891269,
-0.1515882015,
-0.1777459383,
-0.3672994375,
-0.2974106669,
-0.2887093127,
0.3044138849,
0.2415670604,
-0.4143630266,
0.0050611151,
-0.3091374338,
0.0382292718,
0.0887568742,
0.3517166376,
-0.1257402897,
-0.337236166,
-0.0697268769,
0.102858074,
-0.0074516116,
-0.0985338911,
0.118822895,
-0.0501227416,
-0.3611207306,
0.3339399695,
-0.2996918857,
-0.00597669,
-0.3160234988,
-0.2957884967,
-0.226106748,
0.0362944007,
0.3749169707,
0.0005717787,
0.290604949,
-0.3072078824,
-0.2342634648,
0.2332038134,
0.2528029978,
0.0668867677,
0.1687255949,
-0.0613381937,
0.4459927678,
-0.0581606403,
0.1080881804,
0.4354995191,
0.2439808995,
0.1205548048,
-0.2132981122,
-0.3124350905,
0.4073857069,
-0.2161107808,
-0.2671761215,
-0.0586874783,
-0.2213077098,
0.1378094554,
0.0332862735,
0.5117917061,
-0.031011017,
0.0426626392,
0.2298552096,
-0.0764229149,
-0.0032714375,
0.0186794531,
0.0669961497,
-0.3760606945,
-0.0270141196,
0.3007606268,
-0.016087044,
-0.0972943753,
0.005126487,
0.2591744065,
-0.6797744632,
-0.1405083686,
-0.1344067603,
-0.0637834668,
0.0494533479,
0.1791529953,
0.2365086526,
-0.0138496235,
-0.1725867987,
-0.1695687771,
-0.5211241841,
0.2532181442,
-0.1697076112,
0.1158556417,
-0.3727280498,
-0.2445128858,
0.1235667095,
0.012144804,
-0.3232446611,
0.1068828478,
0.1717084795,
0.183752045,
0.0996295288,
-0.0840656459,
-0.0398074463,
-0.2063751668,
-0.0111202411,
-0.140601337,
-0.2030585557,
-0.0648745224,
-0.1896647215,
0.2068103552,
0.0558875129,
-0.231637612,
-0.1772008687,
-0.1429309547,
-0.2675246298,
-0.0359591357,
-0.014464261,
0.0381342582,
-0.0312439818,
-0.0738610104,
0.1322151423,
-0.2509718537,
-0.3197401166,
-0.2264546007,
0.2013913095,
0.189643681,
0.3783848286,
-0.1198258325,
-0.2531087995,
-0.0977045372,
0.4008127749,
0.3114432693,
-0.0682551637,
0.1752153337,
0.3891297281,
0.0664002374,
0.4107885063,
0.4305835664,
-0.0033735081,
0.1318310201,
-0.2263220698,
-0.1581483334,
0.2349781245,
0.1559954435,
-0.0946479514,
0.0490452796,
-0.1669889688,
0.0193838645,
0.2121371776,
0.3548788726,
0.228877455,
0.3752592206,
-0.245819509,
0.0876132175,
0.0316442847,
0.2959958613,
0.1760200858,
0.1787880957,
0.0076833162,
0.2682540715,
0.1886440516,
0.4195557237,
0.1102671698,
0.0495272242,
0.0817354843,
0.0284803957,
0.379276067,
-0.0127104297,
0.5468868017,
-0.3492638767,
0.0695230737,
0.2495419383,
-0.0813832283,
0.4765527248,
-0.0593012199,
-0.2268984467,
0.2248102278,
-0.2353933007,
0.08234597,
-0.25824368,
0.0882218853,
0.085045591,
-0.0233924724,
-0.2566666901,
-0.3978009224,
-0.2382591516,
-0.1725514978,
-0.1391808987,
-0.0878851339,
-0.2583503425,
0.0394082852,
-0.1023987681,
-0.1514160782,
0.2922495008,
0.3550773263,
-0.1412696093,
0.0024261845,
0.0921459123,
-0.1550146788,
0.3504988849,
0.1131803766,
0.0115723861,
0.1338716596,
-0.1975934356,
0.4691576064,
0.1254766881,
-0.1176780984,
0.3260781169,
0.0475211367,
0.2183053195,
-0.3572711945,
0.2562500834,
0.0896415561,
0.0017936401,
-0.0535724014,
-0.0050206236,
0.0901011303,
-0.0599305667,
0.0950343013,
-0.1876410544,
0.0171620082,
-0.0804092661,
-0.1189789996,
-0.1931008846,
-0.6167590618,
0.4490897954,
-0.3531364501,
-0.0497385971,
-0.2371408045,
0.0667677075,
-0.0753708482,
0.3601908684,
0.4781441987,
0.0641666502,
-0.1417952031,
-0.2403577268,
-0.583314836,
-0.0384929813,
0.1599390209,
-0.465985924,
0.3483220637,
0.2088966221,
0.0624867566,
0.1557746083,
0.2750786543,
0.2095019221,
0.2989641428,
0.2641576827,
-0.1683988124,
-0.2073667794,
0.0347102508,
0.4168826938,
-0.1402384192,
0.1490642279,
-0.0740271956,
-0.2080043256,
0.0010350244,
-0.1217720062,
-0.2183111012,
-0.051166188,
0.3540074825,
0.2358196229,
-0.236860767,
0.3890250325,
-0.0432602316,
-0.1017323583,
-0.1918831021,
-0.0598159917,
-0.1104504243,
0.0020398761,
0.12104626,
0.4779066443,
-0.1188739687,
0.2983418107,
-0.0837401822,
0.166615501,
0.2862342298,
-0.3958069682,
-0.4471930563,
0.4601154327,
-0.3136472404,
0.1418802738,
0.2772652507,
0.1144993603,
-0.0272719376,
0.1191150248,
0.1145471409,
-0.2786544263,
0.6339526176,
-0.0931141675,
-0.3489547968,
-0.0762698427,
0.2668262124,
0.0075241961,
0.3862506747,
-0.3276914358,
-0.1622257382,
0.2262345552,
0.0837215483,
-0.0330065824,
0.1784435064,
-0.008183877,
-0.2415609807,
-0.14540039,
0.0157449171,
-0.0918092132,
-0.159321323,
-0.1536737829,
-0.2729388177
] |
https://github.com/huggingface/datasets/issues/3457 | Add CMU Graphics Lab Motion Capture dataset | Hi @dnaveenr! Thanks for working on this!
1. We can use the `Sequence(Value("string"))` feature type for the subject's AMC files and `Value("string")` for the subject's ASF file (`Value("string")` represents the file paths) + the types for categories/subcategories and descriptions.
2. We can use this URL to download the motion descriptions: http://mocap.cs.cmu.edu/search.php?subjectnumber=<subject_number>&motion=%%%&maincat=%&subcat=%&subtext=yes where `subject_number` is the number between 1 and 144. And to get categories/subcategories, feel free to contact the authors (they state in the FAQ they are happy to help) and ask them if they can provide the mapping from categories/subcategories to the AMC files to avoid crawling. You can also mention that your goal is to make their dataset more accessible by adding its loading script to the Hub.
The AMC files are also available in the tvd, c3d, mpg and avi formats (the links are in the [FAQ](http://mocap.cs.cmu.edu/faqs.php) section), so it would be nice to have one config for each of these additional formats.
And additionally, we can add a `Data Preprocessing` section to the card where we explain how to load/process the files. I can help with that. | ## Adding a Dataset
- **Name:** CMU Graphics Lab Motion Capture database
- **Description:** The database contains free motions which you can download and use.
- **Data:** http://mocap.cs.cmu.edu/
- **Motivation:** Nice motion capture dataset
Instructions to add a new dataset can be found [here](https://github.com/huggingface/datasets/blob/master/ADD_NEW_DATASET.md). | 181 | Add CMU Graphics Lab Motion Capture dataset
## Adding a Dataset
- **Name:** CMU Graphics Lab Motion Capture database
- **Description:** The database contains free motions which you can download and use.
- **Data:** http://mocap.cs.cmu.edu/
- **Motivation:** Nice motion capture dataset
Instructions to add a new dataset can be found [here](https://github.com/huggingface/datasets/blob/master/ADD_NEW_DATASET.md).
Hi @dnaveenr! Thanks for working on this!
1. We can use the `Sequence(Value("string"))` feature type for the subject's AMC files and `Value("string")` for the subject's ASF file (`Value("string")` represents the file paths) + the types for categories/subcategories and descriptions.
2. We can use this URL to download the motion descriptions: http://mocap.cs.cmu.edu/search.php?subjectnumber=<subject_number>&motion=%%%&maincat=%&subcat=%&subtext=yes where `subject_number` is the number between 1 and 144. And to get categories/subcategories, feel free to contact the authors (they state in the FAQ they are happy to help) and ask them if they can provide the mapping from categories/subcategories to the AMC files to avoid crawling. You can also mention that your goal is to make their dataset more accessible by adding its loading script to the Hub.
The AMC files are also available in the tvd, c3d, mpg and avi formats (the links are in the [FAQ](http://mocap.cs.cmu.edu/faqs.php) section), so it would be nice to have one config for each of these additional formats.
And additionally, we can add a `Data Preprocessing` section to the card where we explain how to load/process the files. I can help with that. | [
-0.4960854053,
-0.1240224764,
0.0027483257,
-0.1107788831,
0.154397741,
0.113965854,
0.1740245968,
0.3626153171,
-0.2517265975,
0.013264128,
-0.0316175297,
0.201133877,
-0.2203564793,
0.2996661961,
0.1233676746,
-0.2626331747,
-0.1171883643,
0.0168646649,
0.0039789062,
0.0507580303,
-0.0486090891,
-0.09080033,
0.064202562,
-0.0518020764,
-0.5443968177,
-0.0713108703,
-0.1362726539,
0.0050749532,
-0.041119583,
-0.3882618546,
-0.2753124833,
0.2596597672,
0.3541997671,
0.3954925239,
-0.0000942396,
-0.4407470226,
0.1040876061,
-0.2074262351,
-0.0074812351,
0.1970567405,
-0.1303725392,
0.1150809079,
-0.0425808392,
-0.0578826778,
-0.0772629306,
-0.0508241542,
0.174235642,
-0.393612653,
-0.0886779055,
0.1971293688,
0.2805769742,
0.0744218901,
-0.4238091111,
-0.1916280389,
0.1947311312,
0.3632389903,
-0.2272345126,
0.2694556117,
0.6113547087,
0.0367121287,
-0.2882373035,
0.4228579104,
0.0240166429,
-0.2793121934,
0.3041776419,
0.1647535563,
0.3565841615,
-0.2218878567,
0.0705246329,
0.4010548294,
0.3263353109,
-0.2416437715,
-0.1196281239,
-0.2067327946,
0.240084514,
0.0542623512,
-0.1944371164,
0.5154286027,
-0.1349855959,
-0.0479199477,
-0.3454515934,
0.1247226,
-0.3052942753,
0.0254052561,
0.1995279789,
0.0214101672,
-0.0483035296,
-0.1748407781,
-0.1150875837,
-0.139890343,
0.2983127236,
-0.058701463,
-0.0626484901,
-0.0582958423,
-0.0554747023,
-0.2594683766,
-0.126007244,
0.4815653861,
-0.0119525688,
0.1876194328,
0.3063396811,
-0.0035261007,
0.0295170732,
0.1449314654,
-0.0118337208,
-0.1040926501,
-0.1355748624,
-0.1600267291,
0.1189804301,
0.3818282485,
-0.1906793267,
-0.0075770682,
-0.0787907019,
0.1291137338,
-0.4579194486,
0.1056649983,
-0.0048453622,
-0.0107591739,
-0.0761230737,
-0.0570747256,
0.0409742966,
0.1874068677,
0.1004200801,
0.4281873107,
-0.1500754058,
0.1554810107,
-0.1164337918,
0.222995922,
0.1760846078,
-0.1158045828,
-0.2115876228,
0.141041711,
-0.3126333952,
0.1814248711,
0.3142627478,
0.0606073178,
0.0352777019,
-0.1999576837,
0.3241237998,
0.2059709579,
0.0892291293,
0.0497039594,
0.3995544016,
-0.0072816289,
0.1379191279,
-0.0983865559,
0.0284083728,
0.1417238563,
-0.2292371988,
-0.1853695363,
-0.0508883931,
-0.0676305741,
-0.0504439995,
0.3033753932,
0.1704795063,
-0.097574845,
0.0071800346,
0.3797612786,
-0.4973150194,
0.0725155696,
0.0464037322,
0.4011537731,
-0.1499672681,
-0.2507195473,
-0.1470707953,
0.3850393593,
-0.136705175,
-0.069868125,
-0.0400625169,
0.3181883991,
-0.0719226748,
-0.0772347301,
-0.1889237761,
-0.0696230233,
-0.21979855,
0.0342227742,
0.0018689159,
-0.4552360773,
0.0243482329,
0.1252510697,
-0.2199873477,
-0.2266080379,
0.3096723855,
0.3534069061,
0.2409878224,
-0.3401843309,
-0.0765697733,
0.2426418811,
-0.3257288039,
0.07454779,
0.0188994911,
-0.2514093518,
-0.1175462231,
0.2180512697,
0.1328674257,
-0.0833579823,
0.107225731,
0.0052414914,
0.3301072121,
-0.061476998,
0.0904086754,
-0.1720048189,
0.1140381545,
-0.0116572315,
-0.1017304137,
-0.0878666341,
-0.2407267094,
-0.1125451177,
-0.0426260307,
0.145875901,
0.0209233817,
-0.369290024,
-0.0115992501,
-0.3396852016,
-0.13177751,
-0.186818406,
0.3590086401,
0.17514579,
-0.0809748098,
-0.101005286,
-0.1108252928,
0.287320137,
-0.1093781665,
-0.1063146219,
-0.0613695383,
0.2973018885,
-0.1271396577,
-0.1250882745,
0.1705498844,
0.1214660928,
0.1366879791,
0.1781124324,
0.1175426394,
0.3785559237,
-0.2778995037,
0.5389202833,
0.1986458004,
0.3418377936,
0.331418246,
-0.4729326665,
0.3213381171,
-0.1990243345,
0.1060937867,
-0.0926864296,
-0.3011716604,
0.2251748145,
-0.232929796,
0.0370854102,
0.3080088198,
0.0483624563,
0.0822503343,
0.0542126335,
-0.1415448338,
-0.3039552867,
0.0222144872,
0.5489256978,
-0.281976223,
-0.1075938269,
-0.1715847999,
0.363714695,
0.5353631973,
-0.0161633976,
0.0730183572,
-0.0080768401,
-0.5193976164,
0.0882324576,
0.1959293783,
0.2436046451,
0.0430635847,
0.3839612603,
0.0149542363,
0.075084798,
-0.0993359014,
-0.2369472533,
0.0534880422,
0.0799021125,
-0.0735697523,
0.1495937556,
-0.0494702272,
-0.0258464292,
-0.2619703412,
-0.3784792721,
0.0512228608,
-0.1690787226,
-0.0857623518,
-0.1907034516,
-0.1058874726,
-0.2423505634,
-0.0114483265,
-0.1548277438,
0.0895423591,
-0.1461915374,
0.1556955874,
0.0663290024,
-0.1862786561,
0.2463084906,
-0.5872699618,
0.4227310419,
-0.2755743861,
0.2455541044,
0.0298237372,
-0.3227598667,
0.1865067631,
0.3210698962,
0.1494895518,
0.0533523262,
0.3413958549,
-0.1991030723,
0.5412057042,
-0.3576000929,
-0.2640684545,
0.3640882671,
-0.0042330986,
-0.1462612897,
0.0629446432,
0.0328093469,
-0.0039041755,
-0.2070295215,
0.0099982591,
-0.427573204,
0.0741156042,
-0.0880540311,
-0.1762161255,
-0.2951574922,
-0.2209255099,
-0.1209932938,
-0.0588040613,
-0.4365813434,
0.073749356,
0.1481366605,
-0.0295699798,
0.0888269469,
-0.062670812,
0.1286015362,
-0.2705945969,
0.2606354952,
-0.2722081244,
-0.3457013071,
0.3824455738,
-0.5332672596,
-0.362177074,
0.2659264207,
-0.1266624629,
0.1888106614,
-0.0256772954,
-0.041487921,
-0.1940092593,
-0.0452971123,
-0.094729878,
0.1875897199,
-0.0183683559,
0.3262372911,
0.0046384726,
-0.1873565763,
-0.150815025,
-0.1254445016,
0.1153444797,
0.4868926108,
-0.1008882448,
-0.0939440802,
0.0585150383,
0.1076358408,
0.3617961705,
0.0160430036,
-0.1585392654,
0.1721088886,
-0.1032316759,
0.2155788839,
0.2069043815,
-0.0222557001,
0.1921561211,
-0.1155594811,
0.0149870869,
0.3832196295,
0.121923469,
-0.1273760796,
-0.2448276728,
0.3813431263,
-0.2759685218,
-0.1896432936,
0.0188516565,
0.0852705464,
0.0079973182,
-0.0738613978,
-0.0204794984,
0.0016852977,
-0.1319514215,
0.5442470312,
0.4004920423,
-0.0312315412,
-0.1036481857,
-0.4687808156,
-0.0596435331,
-0.2397470921,
0.1898954213,
0.2802732885,
-0.1560915112,
-0.1638846993,
-0.1868707687,
-0.0834687203,
0.1278959364,
0.2334388345,
-0.4945238233,
-0.0781515241,
0.1691935062,
0.1709520966,
-0.1692001075,
0.179111883,
-0.3137456477,
-0.1837589741,
-0.1008017883,
-0.0262727663,
0.094818987,
-0.0743513033,
0.0871989802,
-0.2645657361,
-0.0007751613,
0.1437350512,
0.090144448,
0.1389899254,
-0.2949698865,
0.0525012314,
0.1638968289,
-0.2493498623,
0.0176995806,
-0.2976716757,
-0.0039748154,
-0.121231176,
0.2790182233,
0.1926126182,
0.2961012721,
0.3979200721,
0.1289870739,
0.1118291989,
0.3236812651,
0.165072605,
0.363840878,
0.0118269781,
-0.027590856,
0.3764973879,
-0.2336544991,
0.2946546376,
0.4478747249,
0.1292457581,
0.1200048476,
0.0576323792,
0.0303745195,
-0.62376827,
0.2908634543,
0.0126278959,
-0.3243662417,
-0.0179196112,
-0.2518371642,
0.1986857355,
-0.0528570041,
-0.0580774397,
-0.0089900875,
0.2418303043,
-0.2185545862,
0.0104455091,
0.2213758081,
1.108541131,
0.0012927717,
0.2407616526,
0.0171606038,
-0.1200593635,
0.0969625488,
-0.0380871035,
0.1170166656,
-0.2427046746,
-0.234347567,
-0.2497735769,
-0.0810650736,
0.0142907519,
0.1326113343,
-0.4734959006,
-0.073577635,
-0.0487354323,
0.1567146331,
-0.1438163817,
0.2744050622,
-0.1403908134,
-0.6009947062,
-0.4170412123,
0.2707118392,
0.076452665,
-0.1434634924,
0.0560955927,
-0.1173604056,
-0.1082690433,
0.3302994967,
-0.1903031617,
0.0903309733,
-0.2332307994,
-0.2333885729,
-0.4367323816,
0.088635169,
0.0867816731,
-0.0555099063,
0.0908953622,
-0.1312744766,
-0.3130729496,
0.387455523,
-0.0014822254,
-0.1022512689,
0.0607484169,
-0.065333344,
0.3169906437,
-0.1732249409,
0.1475635767,
0.3936143816,
0.3661575615,
-0.0503917821,
-0.0591099635,
-0.2059929818,
0.4328360558,
0.0166166555,
-0.0811494887,
-0.1242232695,
-0.2755230963,
-0.0822486281,
0.2185585201,
0.2193110883,
-0.0407076925,
-0.0105121937,
0.3121180832,
-0.1308573931,
-0.0764417723,
0.1552349329,
0.1063674465,
-0.1863911748,
-0.0582273155,
0.303815186,
-0.1289128065,
-0.3863286078,
-0.0365998335,
0.0948891565,
-0.6112645268,
-0.1312743127,
0.1002418026,
-0.274576515,
0.1593018919,
0.101096414,
0.1385622472,
-0.1077754423,
-0.0966940522,
0.0738788769,
-0.5158709884,
0.2537687719,
-0.1696244925,
0.342782259,
-0.0552546941,
-0.135517478,
0.0862836167,
-0.0912517235,
-0.4881832004,
-0.0905259773,
0.0102407942,
0.1038710326,
-0.2100794911,
-0.088749446,
0.1713843197,
-0.006696681,
0.1595767885,
0.0736357272,
-0.3078453243,
-0.2523486912,
-0.1543724537,
0.1101027802,
0.1867503822,
-0.0997976884,
-0.1856649667,
0.0812871531,
-0.3509815931,
-0.0353864618,
0.04447354,
0.0106888227,
-0.0747449622,
-0.120574154,
0.0804332495,
-0.3820144236,
0.0125901196,
-0.0570651926,
0.1415207535,
0.2092227489,
0.2700676024,
-0.12727575,
-0.2451881021,
-0.2348320931,
0.3936534524,
0.5681813359,
0.1152485982,
0.190570876,
0.2002146095,
0.2274111956,
0.1239670292,
0.3676668108,
0.0636024177,
-0.1252996922,
-0.1575527638,
-0.13971591,
0.2031945288,
0.3428509831,
-0.1949825883,
0.0820263401,
-0.1840544194,
-0.2202232927,
0.4531171918,
0.2394420654,
0.1885692626,
0.2523700297,
-0.1068834066,
0.1268672049,
-0.0251775831,
0.0321559273,
0.245156005,
0.0120974239,
0.1267818511,
0.1916380525,
0.0179330353,
0.2917596698,
0.135900721,
0.039667692,
-0.1623204499,
0.1539540142,
0.3154412508,
-0.0930712968,
0.4449161887,
-0.1029330865,
0.0237800535,
0.1985467672,
-0.2276951522,
0.4463503361,
0.1224549785,
-0.1889591068,
0.2186997384,
-0.2271467596,
-0.0564024188,
-0.1331137419,
0.0427548997,
-0.0128118414,
-0.1309313625,
-0.1844774485,
-0.3811252415,
-0.0172307044,
0.0941181183,
0.0367271565,
0.0094249351,
-0.0220215358,
0.132850036,
0.0568824261,
-0.1112253666,
0.1669201404,
0.4343432486,
-0.0501131564,
0.0482324511,
0.0783354715,
-0.0135479141,
0.4833622277,
0.0719670355,
0.1386295557,
0.1012151018,
-0.221717,
0.3230463862,
0.1362683624,
-0.1225451604,
0.0212101676,
0.0305010621,
0.2209732085,
-0.1251274794,
0.2986629605,
0.3162180483,
-0.2335741967,
-0.1354325563,
0.0102709783,
0.133191213,
0.1165408641,
-0.0188158527,
0.0033099693,
0.1084876433,
-0.2722472548,
0.0384939089,
-0.3654899299,
-0.3475312293,
0.2433826625,
-0.5024809241,
0.0031841381,
-0.2355454862,
0.1933076084,
0.1299191564,
0.4750695825,
0.1309796721,
-0.1104640588,
-0.0932180882,
-0.3042043149,
-0.4219848812,
-0.0164361801,
0.2835510671,
-0.1535948515,
-0.0013665082,
0.1643702239,
0.1309680641,
0.1705208272,
0.2187239379,
-0.0048373654,
0.3497531712,
0.1816096753,
-0.1584928334,
0.0838346928,
0.1723631173,
0.2854525447,
0.0115283029,
-0.0018518143,
-0.0259588938,
-0.1865867823,
0.2298714221,
-0.0504493266,
-0.1327738911,
-0.1473807693,
-0.0038491555,
0.3505349457,
-0.2520024478,
0.2434978336,
-0.2048177123,
-0.1262503713,
-0.167133078,
-0.0229042843,
-0.2598845363,
-0.2505699396,
0.1656362414,
0.4776186943,
0.0364843272,
0.1901198328,
-0.0684198514,
0.1247022822,
0.2557872236,
-0.0830499977,
-0.3902440071,
0.3530349135,
-0.0548159182,
0.1700610667,
0.187585175,
0.1791374236,
-0.0199597254,
0.0822720677,
0.0317265876,
-0.4584235549,
0.5294393897,
-0.1083583906,
-0.2254054248,
0.0254483279,
0.1575596482,
-0.1609745771,
0.4261796474,
-0.2955023646,
0.0526700243,
0.0810690746,
0.0493337363,
0.0522255599,
0.2802129388,
-0.2052280605,
-0.1473439187,
-0.2166474462,
-0.0958976969,
0.2196721733,
-0.1958374679,
-0.1717415154,
-0.2900111079
] |
https://github.com/huggingface/datasets/issues/3457 | Add CMU Graphics Lab Motion Capture dataset | Hi @mariosasko ,
1. Thanks for this, so we can add the file paths.
2. Yes, I had already mailed the authors a couple of days back actually, asking for the metadata details[ i.e category, sub-category and motion description] . They are yet to respond though, I will wait for a couple of days and try to follow up with them again. :) Else we can use the workaround solution.
Yes. Supporting all the formats would be helpful.
> And additionally, we can add a Data Preprocessing section to the card where we explain how to load/process the files. I can help with that.
Okay. Got it. | ## Adding a Dataset
- **Name:** CMU Graphics Lab Motion Capture database
- **Description:** The database contains free motions which you can download and use.
- **Data:** http://mocap.cs.cmu.edu/
- **Motivation:** Nice motion capture dataset
Instructions to add a new dataset can be found [here](https://github.com/huggingface/datasets/blob/master/ADD_NEW_DATASET.md). | 107 | Add CMU Graphics Lab Motion Capture dataset
## Adding a Dataset
- **Name:** CMU Graphics Lab Motion Capture database
- **Description:** The database contains free motions which you can download and use.
- **Data:** http://mocap.cs.cmu.edu/
- **Motivation:** Nice motion capture dataset
Instructions to add a new dataset can be found [here](https://github.com/huggingface/datasets/blob/master/ADD_NEW_DATASET.md).
Hi @mariosasko ,
1. Thanks for this, so we can add the file paths.
2. Yes, I had already mailed the authors a couple of days back actually, asking for the metadata details[ i.e category, sub-category and motion description] . They are yet to respond though, I will wait for a couple of days and try to follow up with them again. :) Else we can use the workaround solution.
Yes. Supporting all the formats would be helpful.
> And additionally, we can add a Data Preprocessing section to the card where we explain how to load/process the files. I can help with that.
Okay. Got it. | [
-0.4981459677,
-0.0221617501,
-0.0469948798,
0.0064928937,
0.1337008923,
0.0644237995,
0.1049067527,
0.4042607248,
-0.2334994823,
-0.0190540943,
0.0281625725,
0.1850056797,
-0.1908474416,
0.3392908275,
0.1693346649,
-0.3363628685,
-0.0530750602,
0.1396868527,
-0.0843887553,
0.043174345,
-0.0702569708,
-0.0249850117,
0.0503046475,
-0.0793321133,
-0.5730772018,
-0.0366109684,
-0.2418303639,
0.0657719448,
-0.2355056405,
-0.3812154233,
-0.151589483,
0.2230670899,
0.2959676683,
0.5824577808,
-0.0000948434,
-0.3243023455,
0.0629592389,
-0.2588099837,
0.0887473226,
0.1055803448,
-0.2039961219,
0.0784148276,
-0.1515658796,
-0.055924926,
-0.1220609322,
-0.2471211851,
0.0467005707,
-0.3461385071,
-0.0075521246,
0.207325995,
0.3116970658,
-0.0035008015,
-0.3139147758,
-0.1816879809,
0.2378663868,
0.4768873751,
-0.2770292759,
0.1410594583,
0.5510948896,
-0.126786992,
-0.1734279692,
0.299772203,
0.0554612577,
-0.1801772118,
0.2177938223,
0.1132785901,
0.249876067,
-0.1715003252,
0.0992956311,
0.322006464,
0.3295996487,
-0.1652961224,
-0.0957682803,
-0.0678416491,
0.2257675678,
-0.17498146,
-0.1236646846,
0.4608752131,
-0.0922928974,
-0.0565486029,
-0.2547587752,
0.201528728,
-0.3605988622,
-0.0423741639,
0.1869171113,
0.0455614887,
-0.0124093154,
-0.1918714195,
-0.0284665897,
0.0617092289,
0.2081515193,
0.1267123818,
-0.1763557494,
-0.1029744744,
0.056852486,
-0.0996602476,
-0.1523742676,
0.3770134151,
0.0109924143,
0.1968973279,
0.3070928752,
-0.0243737735,
0.3053175807,
0.1624314785,
-0.0006434309,
-0.1145503446,
-0.2630260885,
-0.1508609205,
0.1786682904,
0.2597839832,
-0.1624659151,
-0.0230552908,
-0.0135349482,
0.0289580524,
-0.459138006,
0.0789212808,
0.0146382805,
-0.0959379748,
-0.0621488281,
-0.0679320842,
0.1116765738,
0.1956792921,
0.026022248,
0.4270822108,
-0.1568955183,
0.070619449,
0.0227914937,
0.2247105837,
0.1465117484,
-0.1015082821,
-0.1933489144,
0.141706422,
-0.3106880188,
0.09767773,
0.2765744925,
-0.0457045622,
0.1038154438,
-0.1878250837,
0.2486882359,
0.2369479984,
0.2115860134,
0.0906981751,
0.4239701331,
0.0147600705,
0.2386052459,
-0.1235824749,
0.0555839539,
0.1949055642,
-0.1912540644,
-0.0044819405,
-0.1302087158,
-0.138467446,
-0.2769139111,
0.309391737,
0.1564318836,
-0.1223628446,
-0.0473069362,
0.3197386861,
-0.5377839804,
-0.0426516831,
0.0975980237,
0.3489636779,
-0.0806641206,
-0.2303363383,
-0.0629605725,
0.2824793756,
-0.2477250844,
-0.0679351017,
-0.021243494,
0.1074494347,
0.1620384157,
-0.0918608159,
-0.1870148927,
-0.0562132224,
-0.3052000105,
0.067955181,
0.1537096053,
-0.3336901367,
-0.0161791705,
0.0015800395,
-0.3141984344,
-0.2627300918,
0.3646116257,
0.3498815596,
0.1459097266,
-0.2555578053,
-0.056800317,
0.2189995199,
-0.31301108,
0.1148036942,
-0.0564020313,
-0.296385318,
-0.1078087762,
0.2544270158,
0.1566589177,
-0.1082589477,
0.0742669031,
0.0215124823,
0.3067342043,
-0.1496973187,
0.080915004,
-0.0753704607,
0.3620778322,
0.0892869309,
-0.1412519217,
0.0060099452,
-0.1464471966,
-0.0223637335,
0.0065398379,
0.0853071958,
0.0643666536,
-0.3977825046,
0.0161000006,
-0.2690814435,
-0.2272782177,
-0.1461430937,
0.3753950298,
0.1250144839,
-0.0582856499,
-0.0789870322,
-0.1650187373,
0.2836884856,
-0.1146520078,
-0.1271134019,
0.118040286,
0.2153397202,
-0.2561338246,
-0.2255678177,
0.1270808876,
0.0138944695,
0.1521248668,
0.0369725488,
0.1092168018,
0.3439687192,
-0.1316239685,
0.4132358134,
0.3029045761,
0.2882445753,
0.2750084698,
-0.2853956819,
0.1959353089,
-0.2214491069,
0.0465582237,
-0.0797014385,
-0.2311279476,
0.2224489301,
-0.3138032854,
-0.1442582458,
0.2498954087,
-0.0051120734,
0.1240687221,
-0.0120052733,
-0.0642858222,
-0.2163312435,
0.095880188,
0.4152864516,
-0.2925168276,
-0.1605743766,
-0.2114544213,
0.1853244305,
0.5400575399,
0.0621565804,
0.1041006967,
0.0423918404,
-0.4080938697,
0.0643936321,
0.2109223157,
0.251000464,
0.1540824026,
0.4482448697,
0.0528490953,
0.0633646473,
-0.0755686685,
-0.2184040099,
0.1686783284,
0.0303388983,
-0.1039148644,
0.1220473945,
-0.0763756037,
-0.0978104398,
-0.3262308836,
-0.2480409443,
0.0914746448,
-0.0281622894,
-0.0665826946,
-0.2283032238,
-0.1500044167,
-0.2582572401,
0.0508248173,
-0.2095878273,
0.2133725137,
-0.1467850655,
0.1812415272,
0.1492545307,
-0.1757300645,
0.2535951138,
-0.5214285851,
0.4311157167,
-0.1774577051,
0.0234693028,
-0.0076993708,
-0.2500822842,
0.0944264531,
0.3460312784,
0.2047760189,
-0.0006258689,
0.4760362506,
-0.1944999248,
0.5204679966,
-0.2987228632,
-0.3560858369,
0.3346391916,
-0.0788153857,
-0.0897705182,
0.0361747891,
0.0696805418,
-0.0106488969,
-0.1186570227,
0.0638789237,
-0.4273793101,
0.0294525698,
-0.111875698,
-0.2443004549,
-0.2413523048,
-0.3961723447,
-0.095948793,
-0.019752264,
-0.4302155375,
0.2168924361,
0.1528257728,
0.0230277777,
-0.0164603274,
0.1332618445,
0.2773319185,
-0.2705038786,
0.1880261302,
-0.235677436,
-0.4563956261,
0.3951852024,
-0.4901809692,
-0.5214024782,
0.3873628676,
0.0478593037,
0.2386882603,
0.0260635484,
-0.2218926102,
-0.4051900208,
0.0296938643,
0.0997682214,
0.2026605457,
-0.018096514,
0.3315910101,
0.0010502026,
-0.2476577312,
-0.1438534856,
-0.1208206564,
0.1242232099,
0.44462955,
-0.0463532209,
-0.1026804224,
0.0793125406,
0.1683975458,
0.4410664737,
-0.0320553258,
-0.2071597576,
0.3174206913,
-0.1695321947,
0.359452337,
0.1103768125,
-0.064102456,
0.1890426725,
-0.1180913597,
0.0867204964,
0.2784187496,
0.047505606,
-0.1074870005,
-0.2736446857,
0.4452970624,
-0.2581878603,
-0.0813364908,
0.067683503,
0.31480968,
0.0224580429,
-0.1578658372,
-0.0584322028,
-0.0678370297,
-0.0944355428,
0.4008513093,
0.3284713626,
0.007731352,
-0.1011018679,
-0.2416616529,
-0.0167202,
-0.2458801568,
0.1614595801,
0.1971073002,
-0.1583255529,
-0.3040864468,
-0.1170393303,
-0.1354713589,
-0.0289391782,
0.2356174886,
-0.3629027009,
-0.200876534,
0.1373879611,
0.0343950652,
-0.1175501943,
0.1646424234,
-0.2988250852,
-0.1864203066,
0.0671224892,
-0.1384129375,
0.1025162488,
-0.040588785,
0.0908015147,
-0.2036064565,
0.0177601185,
0.2049250752,
-0.0936105922,
-0.120983094,
-0.3028218448,
0.025915049,
0.2102893442,
-0.2635056376,
-0.0190954097,
-0.3956123888,
-0.0603008941,
-0.0962088853,
0.1936392784,
0.0927493349,
0.320461303,
0.3040803969,
0.1252210438,
0.0745875686,
0.3327772021,
0.2757568657,
0.3697274327,
0.0301840696,
0.0612757728,
0.4010867178,
-0.3919589221,
0.2447293103,
0.4409743845,
0.0677682981,
0.1185602024,
-0.0363087431,
-0.0063800844,
-0.6367417574,
0.265447408,
0.1805048138,
-0.3092830479,
0.0164579693,
-0.2375608683,
0.1362698525,
0.1863716096,
0.0184924398,
0.1714741737,
0.351467967,
-0.2453958839,
-0.0280705616,
0.2372061908,
1.053580761,
0.0326750576,
0.2451224774,
0.1623169929,
-0.2882584035,
0.1057286784,
-0.0090015549,
0.1452751756,
-0.1409509182,
-0.39559111,
-0.2475779504,
-0.0850289464,
0.0812193304,
-0.0106933275,
-0.3267762363,
-0.1021172628,
-0.0976723209,
0.0858289599,
-0.297306776,
0.1253277212,
0.0704333559,
-0.4963201284,
-0.3335978389,
0.3168886602,
-0.0061915377,
-0.2017475516,
-0.0058564479,
-0.1993376464,
-0.2374638468,
0.2830946743,
-0.2167648226,
-0.019403616,
-0.2298243046,
-0.1285089552,
-0.5259346962,
0.0703254864,
-0.0299549624,
-0.0171473473,
0.1196539626,
-0.2043017596,
-0.3086934388,
0.43629691,
0.057718467,
-0.1706662476,
-0.0261318367,
-0.0143421777,
0.2610283792,
-0.2523220181,
0.1918157339,
0.3350824416,
0.2344865799,
-0.1130547449,
-0.1336044371,
-0.127976194,
0.3639210463,
0.1489036083,
-0.1618268937,
-0.1140880808,
-0.2364190072,
-0.1223177016,
0.2600028217,
0.186883539,
0.0126469657,
0.0465547405,
0.3171847463,
-0.1280955076,
-0.2116753906,
0.2613476813,
-0.0030057409,
-0.1622178853,
0.0249412078,
0.2477928996,
-0.1299535185,
-0.3521891534,
0.0235981066,
0.1859034747,
-0.6631186604,
-0.1681926548,
0.0998366326,
-0.232285887,
0.2543453872,
0.1998261958,
0.175053075,
-0.031700734,
0.0170701239,
0.1343874186,
-0.54510355,
0.1543363035,
-0.1149066687,
0.4261522591,
-0.0342209525,
-0.0537143759,
0.1247992963,
-0.123224251,
-0.5097932816,
-0.0495034158,
-0.0075356192,
0.0256493688,
-0.02602157,
0.019823065,
0.1881040931,
0.0266530253,
0.1867740452,
0.1738081723,
-0.2756907046,
-0.2702614069,
-0.1343599111,
0.086816363,
0.1722380221,
-0.0520129763,
-0.1265032738,
0.0235283244,
-0.4784805179,
0.0787601024,
0.0948122963,
0.0044172085,
-0.1199800074,
-0.0850050449,
-0.03998762,
-0.2794698477,
0.1035719141,
-0.1388892084,
0.1874290109,
0.2987604737,
0.2677228153,
-0.2051648349,
-0.234593451,
-0.2769678831,
0.3851964176,
0.4047549069,
0.1036165431,
0.1641522199,
0.2825236619,
0.1279975325,
0.1906344444,
0.2983244658,
0.1491779089,
-0.1074501649,
-0.1547825634,
-0.0585483089,
0.210744828,
0.3578924239,
-0.2613475025,
0.078737326,
-0.2596659958,
-0.1505023986,
0.4147766232,
0.2902668417,
0.2385204583,
0.1674108207,
-0.1771484166,
0.1864013672,
-0.091129154,
-0.0740938261,
0.2044271082,
-0.0079079056,
-0.0185522288,
0.210881263,
-0.028519148,
0.3371384442,
0.1441157907,
0.0495801792,
-0.1491965652,
0.2137406021,
0.2753823996,
-0.011261316,
0.3784824014,
-0.108543314,
0.0649200082,
0.2509159744,
-0.1566673368,
0.4367682338,
0.1564632505,
-0.0029235871,
-0.0196293984,
-0.254141897,
-0.1574971527,
-0.0819638222,
-0.0739363432,
0.133266896,
-0.1905258447,
-0.1823438108,
-0.3153083622,
0.0087433308,
0.1235559583,
0.2256933451,
-0.080595389,
0.0239891578,
0.1356747448,
0.0858047828,
-0.2443253845,
0.1988029629,
0.3787091076,
-0.0605120398,
-0.0009519124,
0.1696287692,
-0.1706080586,
0.3750404418,
0.1452138871,
0.178558439,
0.1190963238,
-0.0969479829,
0.2154177576,
0.1735904217,
-0.1212535948,
0.0444787405,
0.0441823937,
0.3186238706,
-0.1017046645,
0.2721760869,
0.3335109651,
-0.2457288355,
-0.0619577132,
-0.0051524262,
0.2139904499,
0.0654027387,
-0.005005301,
-0.0637109727,
0.0279748738,
-0.251109302,
-0.0424283333,
-0.3485777378,
-0.3312907815,
0.176731199,
-0.3609602153,
0.0231657885,
-0.177825883,
0.1662210226,
0.1645126343,
0.4390017092,
0.0058189034,
-0.1416241229,
-0.1145609766,
-0.340605706,
-0.462654233,
-0.0082429945,
0.1839261055,
-0.093085736,
-0.0873885602,
0.1009476557,
0.1296523511,
-0.0046030632,
0.260785073,
-0.1077525988,
0.4365914166,
0.1740773171,
-0.3027223647,
0.0833589137,
0.1347624809,
0.2320234776,
0.0170097221,
-0.0520065278,
-0.0065303072,
-0.1595992297,
0.2837765217,
-0.1029290706,
-0.1399220526,
-0.2374260277,
0.1485283524,
0.4250472188,
-0.2670220137,
0.243928358,
-0.2082726657,
-0.1305872798,
-0.2570018768,
0.0045929109,
-0.1960386634,
-0.0725673139,
0.2311650217,
0.4491164684,
0.0108414777,
0.0570780821,
-0.2032625228,
0.2054232508,
0.2005842328,
-0.1065106764,
-0.3061921597,
0.3700145185,
-0.0013206012,
0.0575389266,
0.2504618764,
0.1457061321,
0.0351060592,
-0.0440372415,
-0.156313628,
-0.3766331077,
0.4887990057,
-0.1170796528,
-0.139901191,
0.0713613182,
0.113522239,
0.0000972272,
0.4632804394,
-0.2937794328,
0.0871310607,
-0.002227132,
0.0793127716,
0.0209534522,
0.2894107997,
-0.2830007672,
-0.0225563645,
-0.1809016615,
0.0229134951,
0.1613391489,
-0.1715416312,
-0.1472673416,
-0.2375181317
] |
https://github.com/huggingface/datasets/issues/3455 | Easier information editing | Hi ! I guess you are talking about the dataset cards that are in this repository on github ?
I think github allows to submit a PR even for 1 line though the `Edit file` button on the page of the dataset card.
Maybe let's mention this in `CONTRIBUTING.md` ? | **Is your feature request related to a problem? Please describe.**
It requires a lot of effort to improve a datasheet.
**Describe the solution you'd like**
UI or at least a link to the place where the code that needs to be edited is (and an easy way to edit this code directly from the site, without cloning, branching, makefile etc.)
**Describe alternatives you've considered**
The current Ux is to have the 8 steps for contribution while One just wishes to change a line a type etc.
| 50 | Easier information editing
**Is your feature request related to a problem? Please describe.**
It requires a lot of effort to improve a datasheet.
**Describe the solution you'd like**
UI or at least a link to the place where the code that needs to be edited is (and an easy way to edit this code directly from the site, without cloning, branching, makefile etc.)
**Describe alternatives you've considered**
The current Ux is to have the 8 steps for contribution while One just wishes to change a line a type etc.
Hi ! I guess you are talking about the dataset cards that are in this repository on github ?
I think github allows to submit a PR even for 1 line though the `Edit file` button on the page of the dataset card.
Maybe let's mention this in `CONTRIBUTING.md` ? | [
-0.0376411676,
0.1618793309,
-0.1659287065,
-0.3433541059,
0.0584444888,
0.0013939644,
0.0719456673,
0.2496085018,
-0.3263020217,
0.4076212943,
0.2005190998,
0.3080872297,
0.3768406808,
0.224368006,
0.0078362301,
-0.0981670469,
-0.0289735068,
0.092659533,
0.1429606527,
0.1426796466,
0.0083576078,
-0.4900423586,
-0.1506216973,
-0.1997097284,
0.0426089056,
0.032349363,
-0.0813139603,
-0.1380000859,
-0.1716804206,
-0.4877368808,
-0.0837930366,
0.5929232836,
-0.0392674357,
-0.1026618183,
-0.0001048123,
-0.2484721541,
0.239966467,
0.193002373,
-0.7146852612,
0.0284292605,
-0.3298746943,
-0.7772538662,
0.0408365056,
-0.1284901947,
0.1622776389,
-0.192964077,
0.1316077411,
0.2240618765,
0.1259078979,
-0.0216233581,
0.2170009464,
0.0092507759,
0.1017046198,
-0.1481402218,
0.4204467833,
0.4576366246,
0.0311324336,
0.069882974,
0.3041938543,
0.2314531505,
0.4975993633,
0.2742645442,
0.0498784296,
-0.2075839788,
0.289393127,
-0.0332882814,
0.2670797408,
-0.168239221,
0.2650388479,
0.0089247338,
0.6614789367,
-0.1992475092,
-0.5432671905,
-0.4392225742,
0.4129655957,
0.012376776,
0.0117242383,
0.1170536503,
-0.2445991039,
0.0464601852,
-0.2607312202,
-0.4110343754,
-0.1743327826,
-0.1048055366,
0.3069656789,
-0.0091235023,
0.1074990183,
-0.0575715527,
-0.0017220335,
-0.2268238813,
0.1015786603,
0.0969841182,
-0.1468191296,
0.1550701559,
0.0876991376,
-0.3318443894,
-0.1302842945,
-0.2116251886,
0.0646421537,
0.1167239025,
0.1593087316,
0.0652680695,
-0.002476763,
-0.0432494543,
0.2950122654,
-0.2261423022,
-0.0330238119,
0.2454858571,
0.174922049,
-0.0459384918,
0.1685428172,
-0.1163850054,
-0.0733171329,
0.0542846546,
0.0616901517,
0.1964251101,
0.0221721455,
-0.2382313907,
-0.1659510136,
0.0349431857,
0.0874827281,
-0.0284832437,
-0.1857812256,
0.1435585022,
-0.1561225057,
0.1077514216,
0.0767792538,
-0.2573045492,
-0.0058030272,
-0.1842056513,
0.1645395309,
-0.07742434,
-0.0619925149,
-0.0275534298,
0.0853302851,
-0.1021959484,
0.0027648248,
0.4917529225,
0.0545424372,
-0.2234341204,
-0.0374462083,
-0.0487718508,
0.0908261836,
0.1974118501,
-0.0285954718,
-0.0140324123,
-0.2229216844,
-0.2939278185,
-0.0968127623,
0.3105973601,
-0.1853943318,
0.0246253815,
-0.2488018721,
0.2157281786,
0.4474570751,
-0.0810486227,
0.1169211045,
0.1983770281,
-0.2734043002,
-0.1229819879,
0.1408050805,
0.1524150223,
0.2626092136,
-0.0556622222,
0.2770348489,
0.3601511419,
0.0203022826,
0.0982376114,
-0.0905256271,
0.2170908749,
0.1514931023,
-0.0964977145,
-0.2910918295,
0.2124521434,
0.2339582443,
0.021737678,
0.6176632643,
-0.3237293959,
-0.2892946303,
0.259286046,
-0.1970508695,
-0.3348006904,
0.0891132653,
0.3588137925,
0.3893799484,
0.0661636367,
-0.0216709524,
-0.0623909831,
-0.152560994,
0.2311883122,
-0.3256168067,
-0.028659204,
-0.2298299968,
0.1148249209,
-0.4697839022,
0.2739394605,
0.3435224295,
0.1751213223,
0.5124211311,
-0.1835970283,
-0.086643599,
0.0644402206,
0.4260262251,
0.1651355922,
-0.2933759093,
-0.1958615631,
-0.1868765801,
-0.160364151,
0.1507478058,
0.0695770085,
0.2723527551,
-0.4638181329,
-0.1709883213,
0.062666893,
0.242990151,
-0.2944290042,
0.1648152769,
0.0373299979,
-0.3071370721,
-0.5662338734,
-0.1876046956,
0.1378331184,
-0.1676109433,
0.1212397069,
0.241038993,
-0.2540724874,
0.0106810611,
-0.0842843279,
0.2387461662,
0.0861738548,
0.0052945972,
0.1734620631,
-0.0504490994,
0.2396802604,
-0.1623971164,
0.0115688369,
0.4061570168,
0.2187982649,
0.1349237561,
0.0492925271,
0.1163873449,
-0.0489853472,
-0.0840738639,
0.2033610195,
-0.7643204331,
0.263538152,
-0.2321475595,
0.0813608691,
0.1083794236,
0.008261133,
-0.0132171754,
0.0228673257,
-0.0797158405,
-0.2300080806,
-0.0121000819,
0.3750604987,
0.0418842584,
0.0735844448,
-0.3347531259,
0.5843570232,
0.2567123473,
0.0963591933,
-0.1718487591,
0.0517390184,
-0.0930098444,
-0.0332012735,
0.0828385726,
0.3268024921,
-0.1896700263,
0.3086772263,
0.062159989,
0.288838774,
0.1936440319,
-0.0695783347,
0.0934276432,
-0.0114872158,
-0.2698579729,
-0.2536731064,
0.4061375856,
0.5300567746,
0.3972061574,
0.137866959,
-0.059791103,
0.3070997596,
-0.0631556362,
-0.1288224459,
-0.0893299952,
-0.4926508665,
-0.3143650889,
0.0508671775,
-0.2222653329,
-0.231596902,
0.1557896435,
-0.0203057248,
-0.2223538458,
0.1607839763,
0.0623978116,
0.4150554836,
-0.266061157,
0.2651793361,
0.0990358293,
0.0334004946,
0.1469834596,
0.095455043,
0.0855840892,
0.4602436423,
0.5097738504,
0.0404504612,
0.1301336437,
-0.6622837782,
-0.2451782227,
-0.1269898564,
0.1088270023,
0.1186442301,
0.1457491964,
0.2450833768,
0.1364672184,
-0.0506443158,
0.0577280745,
0.1131710112,
-0.0898912922,
-0.2700660825,
0.1025379226,
-0.1393713206,
-0.2526452839,
-0.1351351589,
0.1450165808,
-0.2999433875,
0.2264013141,
-0.0178264901,
0.3661504984,
-0.0311530679,
0.1361352652,
-0.1359082907,
0.008239897,
0.1248393282,
0.2287819684,
-0.2003583014,
0.0546173453,
-0.1801826209,
-0.2262332886,
-0.0555645414,
0.4207502902,
-0.2494483441,
0.3517979681,
-0.1085345969,
0.0947870314,
-0.2542037666,
0.2300179303,
0.0411372706,
0.2630347311,
0.4463311732,
0.2367641628,
-0.3244274259,
0.1226368323,
-0.4915889204,
-0.0083205327,
0.1664108634,
-0.0309535954,
0.0955245793,
0.1827283949,
-0.1708482206,
0.5495144129,
0.3181109428,
0.0608304776,
-0.3079122901,
-0.2431656122,
-0.0456493013,
0.0932934433,
-0.2519395649,
0.1259765476,
-0.0149488943,
0.1605841219,
0.1479864269,
0.1391665936,
-0.0399239846,
0.1106055528,
-0.3841341734,
-0.3176458776,
-0.2183740735,
0.2559512854,
-0.2841991186,
0.4446775615,
0.0117025776,
-0.1586307436,
-0.6243849397,
0.0294561852,
0.0492722206,
0.2845587432,
0.1485162824,
-0.2018571645,
-0.1169033796,
-0.1887796074,
-0.1352417916,
0.1517867148,
0.1835114509,
0.2048376203,
0.0418276712,
-0.2044501901,
0.18146272,
-0.1536146402,
-0.1122979447,
-0.2788068652,
-0.2039455175,
-0.1431141347,
-0.0476411656,
0.2464609295,
0.0012806332,
-0.1670650244,
0.3658782542,
0.323959738,
0.117753461,
-0.1524139345,
-0.2373726517,
0.604125917,
-0.1390982419,
-0.0789600536,
0.0034244745,
0.2094599009,
0.1134803891,
-0.1535094082,
0.0308564771,
0.012969791,
-0.1305315346,
0.094576031,
0.1106294543,
-0.1541674435,
0.1741613299,
0.0592384599,
0.1615213454,
-0.1204529852,
0.2137758583,
-0.0616092719,
-0.0034247041,
0.1305793077,
0.3732297122,
0.2331174165,
-0.028543815,
-0.2016835809,
-0.0376086682,
-0.512770474,
0.3843207955,
0.3453978598,
0.3265057206,
0.359950006,
0.1689171493,
0.2933267355,
-0.3082223535,
-0.2333551049,
-0.0657098517,
0.060302984,
-0.2593885064,
-0.7033094764,
0.2475510836,
-0.0839977115,
-0.2354950905,
-0.058885321,
0.19766289,
-0.0354865119,
-0.0789994895,
0.3530955017,
1.0329942703,
0.0987691209,
0.0267893411,
-0.4304262102,
-0.335608393,
0.3801322877,
-0.0936245397,
0.1957502961,
-0.4224960208,
-0.0866174549,
-0.0388265178,
0.0261208639,
0.1110915244,
-0.1249184757,
-0.1924740672,
-0.0173634682,
-0.1233442053,
0.0609236211,
0.1795128286,
0.3281283081,
0.0540819466,
-0.1532030106,
-0.2481844872,
0.1210634261,
0.1947479993,
-0.2238991261,
0.0050146049,
-0.2810083628,
-0.2808755338,
0.0553112663,
-0.5971984267,
-0.1863580644,
-0.0399814397,
-0.4611432552,
0.1596121937,
-0.3422939181,
0.3626864254,
-0.0703801662,
0.4668306112,
0.4842967391,
-0.0737412572,
-0.0694941282,
0.0366924964,
0.1245332509,
-0.1843047738,
-0.0027862645,
0.2379957139,
-0.2638519406,
-0.2504930198,
0.0592456236,
0.0248435065,
-0.5559664965,
-0.2395280451,
-0.2028932273,
0.0399368554,
-0.0618567839,
0.2410809696,
0.1050821543,
0.0090985755,
-0.3256765306,
0.1616493613,
0.0149831967,
0.150008291,
-0.2416745573,
0.5121465325,
-0.0415195376,
-0.0066343821,
-0.1852025837,
-0.0348520502,
-0.0585493371,
0.3361992538,
-0.2657077312,
-0.2842566371,
-0.3673946857,
-0.2095448226,
-0.1517293453,
-0.2556794584,
-0.2279985398,
-0.3344706297,
0.1072129011,
0.2088671625,
0.1864263266,
0.0250644386,
0.1557434052,
-0.4138956368,
-0.0959345326,
-0.2832696736,
-0.0826255009,
-0.1934811026,
-0.0135778701,
-0.3481926918,
0.1018176898,
-0.0567805544,
0.1701261997,
-0.4181610942,
-0.1137900949,
-0.0697601438,
0.1760500222,
0.129756704,
0.2301337719,
-0.4079912007,
-0.1695254743,
0.098038964,
-0.199352026,
0.0000264493,
-0.2183071524,
-0.1300953627,
0.064528361,
-0.2194271088,
-0.0114332912,
-0.1746134162,
0.2105699331,
-0.0136181507,
-0.1552871913,
0.2880458534,
-0.4908564389,
0.0657026023,
-0.1049734727,
0.3543925881,
0.3590663373,
-0.1950808764,
0.2469119728,
0.0935989469,
0.2444074899,
0.0557812601,
0.0973414406,
-0.3004737496,
0.0507569872,
0.0232050996,
0.3693738878,
0.252910316,
0.1999761611,
-0.0391094014,
0.0905396193,
0.1586599648,
0.2457713932,
-0.0460846424,
0.0454239845,
-0.0782134533,
0.0101956371,
0.2128921896,
0.2926061749,
-0.0236491151,
0.1094896644,
0.022701459,
-0.4266519547,
0.063787818,
0.328163892,
0.2642821074,
-0.0359789953,
0.182325989,
0.0455016382,
0.000115461,
-0.2732340991,
-0.1318155825,
0.237198323,
0.3348801434,
-0.157148242,
0.0156638715,
0.1034840867,
-0.3158790171,
0.0141241392,
0.17022416,
0.0528465174,
0.6181904078,
-0.0859589055,
-0.1979691088,
0.2050765753,
0.526861012,
0.1701178551,
0.0559202842,
-0.0009941141,
0.4363952577,
-0.0463246182,
0.399831593,
-0.1263882965,
0.1100404561,
0.1448130608,
0.1256260276,
-0.1330391467,
-0.1659826189,
-0.2505107224,
-0.0952544138,
-0.0703959614,
-0.0521673933,
0.0308796875,
0.2825104892,
-0.0764953345,
0.0954555199,
-0.2828326225,
0.2052452415,
0.1016525701,
0.4226231873,
-0.2950292528,
-0.350366205,
-0.3940166235,
0.1210169047,
0.2045232207,
0.4660822153,
0.342967838,
0.3145907819,
0.0399906076,
0.0893357918,
-0.3145334721,
-0.0536466762,
0.1763777733,
-0.2129718512,
-0.0489463359,
0.0159542207,
-0.1443197876,
0.1885784119,
-0.0426910594,
0.136011824,
-0.3474744558,
-0.2046602964,
-0.3693490624,
0.0712847188,
0.3377410769,
-0.2967549562,
0.0880789682,
0.0636641085,
0.2292110026,
-0.1092675775,
0.2663523257,
-0.1475563645,
-0.0056576268,
0.0758295134,
0.1527761072,
0.0426080823,
0.3626253307,
0.407848388,
0.0534561276,
0.2614657879,
-0.253679961,
-0.3476072848,
-0.1435645968,
-0.0036711541,
-0.2498133481,
0.4415526688,
-0.0989467651,
-0.006374605,
0.2304726243,
0.3054554462,
-0.4487065971,
0.0310565662,
0.2885080278,
-0.2973444462,
0.0304994993,
0.0739950687,
-0.0709082931,
-0.0824230909,
-0.1109728813,
0.1490412503,
0.1887842566,
0.1701788604,
-0.1737646163,
0.3798018098,
0.4420378208,
0.0347327441,
0.052898936,
-0.0062570535,
-0.0769623965,
0.0052981498,
-0.3952997923,
-0.1899289787,
0.3359509408,
-0.2358902246,
0.2942880392,
0.2298410684,
0.0443130322,
0.1369886547,
-0.1349154562,
-0.1582659036,
0.0546335727,
-0.0149275661,
0.0848097056,
0.0352041908,
-0.1491521895,
0.3638442755,
-0.0452309251,
-0.0501682498,
-0.324726373,
0.1386160105,
-0.0084707346,
-0.4337863922,
-0.0220286958,
0.0941558704,
0.0832504258,
-0.100853622,
-0.1104094982,
0.427177012,
-0.1836427003,
0.2398796231,
-0.7837470174,
-0.2171042413,
0.3100741208,
-0.1514721215,
-0.3679717481,
0.2498750538,
-0.1580917537,
0.1606008857,
-0.0646487027,
0.4301405549,
-0.2075142413,
0.0656212047,
-0.452848047,
-0.1619823575
] |
https://github.com/huggingface/datasets/issues/3452 | why the stratify option is omitted from test_train_split function? | Hi ! It's simply not added yet :)
If someone wants to contribute to add the `stratify` parameter I'd be happy to give some pointers.
In the meantime, I guess you can use `sklearn` or other tools to do a stratified train/test split over the **indices** of your dataset and then do
```
train_dataset = dataset.select(train_indices)
test_dataset = dataset.select(test_indices)
``` | why the stratify option is omitted from test_train_split function?
is there any other way implement the stratify option while splitting the dataset? as it is important point to be considered while splitting the dataset. | 60 | why the stratify option is omitted from test_train_split function?
why the stratify option is omitted from test_train_split function?
is there any other way implement the stratify option while splitting the dataset? as it is important point to be considered while splitting the dataset.
Hi ! It's simply not added yet :)
If someone wants to contribute to add the `stratify` parameter I'd be happy to give some pointers.
In the meantime, I guess you can use `sklearn` or other tools to do a stratified train/test split over the **indices** of your dataset and then do
```
train_dataset = dataset.select(train_indices)
test_dataset = dataset.select(test_indices)
``` | [
-0.5293185115,
-0.0548487902,
-0.1174931154,
-0.1046918258,
0.2126727104,
0.0128880581,
0.336581856,
0.254406631,
-0.0457450524,
0.362811774,
0.1107298806,
0.3568530977,
-0.0795329884,
0.3337858617,
-0.0435331874,
-0.3662008941,
-0.1260603964,
0.0729326308,
-0.146767363,
0.1772599816,
-0.1039986759,
-0.0129163237,
-0.3873733878,
-0.305770874,
-0.2252365053,
0.0702289119,
0.0586885177,
-0.0608848073,
-0.1367441565,
-0.0820587873,
0.1999539882,
0.1456409097,
0.1332622021,
0.308183521,
-0.0001005132,
-0.1260003448,
0.0541953184,
-0.320992887,
-0.0293755196,
-0.3746547699,
-0.2733126879,
0.1714514196,
-0.1804194599,
-0.0938218459,
-0.3420349061,
-0.047060322,
-0.2644605339,
-0.3474150896,
0.221185118,
0.1745133102,
0.2192722857,
0.2382259667,
-0.2318423241,
-0.2352666557,
-0.0395846106,
-0.0449042395,
-0.2666403353,
0.0135267023,
-0.2800477445,
0.049771782,
-0.0255399495,
0.0833293423,
0.4014353752,
-0.1324953288,
0.030021701,
-0.046333272,
-0.3737834692,
-0.167895928,
-0.3583141863,
0.0288179312,
0.2718638182,
0.0783439726,
-0.2228536904,
0.2425988764,
0.0505780801,
-0.2832591832,
0.0475938953,
0.2006925792,
0.0481878556,
0.1128956079,
-0.2429915518,
0.1371024549,
-0.2634058297,
0.1216251552,
0.1645549983,
0.4433889985,
-0.146530211,
0.0502298027,
0.4911282659,
0.2465079129,
-0.4197573066,
-0.0086899642,
0.1950315833,
0.1160287783,
-0.4278467298,
-0.2447155565,
-0.2443816811,
-0.4169802964,
0.186913684,
0.281376034,
0.0196662322,
0.1705505252,
0.3918428719,
-0.0355122313,
0.239287883,
0.1457157284,
0.062405698,
0.175417304,
-0.1203637719,
-0.0919329897,
-0.1698857993,
-0.200596869,
0.1691758484,
-0.2368946075,
0.0099357199,
0.0002212458,
-0.280325979,
-0.0403933264,
-0.2624587119,
-0.5259946585,
-0.3531084955,
-0.1513392627,
0.2167071998,
0.2259500623,
0.068144612,
-0.1666806042,
-0.4671082795,
0.1817967892,
-0.3539061248,
0.0087075327,
-0.259606719,
0.2588579059,
-0.1435712278,
0.1466373801,
0.0429546423,
-0.2523299456,
-0.0371692032,
0.1986062974,
0.4258392155,
-0.0077981413,
0.0650170445,
0.0208547935,
0.3993743062,
0.2053540051,
0.1677503735,
-0.2307280153,
-0.0420138054,
0.2585530281,
-0.1453728974,
0.1100435704,
-0.0746974573,
-0.7046908736,
-0.1315713823,
0.246736601,
0.1874747127,
-0.0157085359,
-0.330948472,
0.3428334892,
0.0199634712,
-0.0772052407,
0.0505353175,
-0.1828574836,
-0.2611156702,
-0.20193699,
0.5801535249,
-0.057215251,
-0.1188030019,
-0.0547436513,
-0.1034318656,
-0.0496894084,
0.5888472795,
-0.0119192293,
-0.2260581255,
-0.2613179088,
-0.0850056708,
0.4826071858,
0.4657335579,
0.2611480951,
-0.1008505598,
0.0100430558,
-0.0862529874,
-0.2454691082,
0.1231402233,
-0.1468535066,
0.1340680569,
0.0542582348,
-0.2181074619,
0.3325819969,
-0.2235338837,
-0.1235537678,
0.0050210427,
-0.0130630089,
0.5355626345,
0.2754992247,
0.0882401317,
-0.0696562529,
0.1616600156,
0.239050895,
0.3639234304,
-0.1028911695,
0.0738060698,
-0.1507027,
0.1759146452,
-0.1642565876,
-0.0793269053,
-0.4868154228,
0.0930184871,
-0.0572976582,
0.3632220328,
0.009460235,
0.2746326029,
-0.1991209537,
-0.2743806243,
-0.4468292892,
-0.0030784479,
0.0651066378,
0.2027722001,
-0.016907692,
0.0577212498,
-0.2317454815,
-0.1870107502,
0.2066377252,
-0.2627966404,
-0.0116388043,
0.1986272484,
0.2463790476,
-0.1194042861,
-0.1947696656,
0.2462301105,
0.2559919655,
0.0608318672,
-0.2980194688,
-0.0715279207,
0.4443039596,
0.3153753579,
-0.4252050221,
-0.0025899857,
-0.0906660482,
0.1184681877,
-0.221658498,
-0.2597107291,
-0.0728718638,
-0.0314476117,
0.0598786511,
-0.232048586,
0.4483126998,
-0.5069954395,
-0.0435905419,
0.0904275477,
0.0358661003,
0.0821726993,
-0.154225558,
0.0194877163,
-0.2882736027,
-0.4150860012,
-0.3285643756,
-0.0552884676,
0.0027180288,
-0.4433062971,
0.1119066626,
0.1959342957,
0.0526796877,
0.0102231903,
-0.2524597347,
0.3787611723,
-0.0490855463,
0.1296455264,
0.1601630151,
0.3419039845,
0.2244420201,
0.2554573417,
-0.2841292918,
-0.1453515738,
-0.0598684251,
0.1061393619,
0.1282239705,
0.0661010519,
0.0386329293,
-0.2191491127,
0.021569496,
-0.2911769152,
-0.0077092797,
-0.0074595069,
-0.2004341781,
-0.0601885691,
0.0219809264,
-0.4383560121,
-0.0876040235,
-0.0536809117,
-0.0878062472,
-0.2174813598,
-0.226345703,
0.1395001411,
-0.2363579422,
-0.2733141184,
0.2724518478,
-0.2287923992,
0.4479762614,
0.1180224493,
-0.0103183901,
0.1868899316,
0.1513221711,
0.0810618177,
0.2461501211,
-0.1442611963,
0.4279320836,
0.4200904071,
0.1108107567,
-0.0860172436,
0.0973853841,
-0.1871666461,
0.1492991,
-0.2975417674,
0.1476679146,
-0.03224748,
-0.1874533892,
-0.3575737774,
-0.2959253192,
-0.1772409379,
-0.2416425496,
-0.0711899474,
-0.1908291876,
0.2216786742,
0.0119765522,
-0.4236189127,
-0.7918320298,
-0.125024274,
-0.2832904756,
-0.2390762269,
-0.1878421158,
-0.0486992709,
-0.090609014,
0.0539684556,
-0.0158187971,
-0.0031706286,
-0.034104351,
-0.2375293821,
-0.1701408178,
0.3310907185,
-0.4649676681,
-0.2550136745,
0.0570111312,
0.214855209,
-0.126057148,
-0.0304273069,
0.0143971462,
0.0782648325,
0.0607779138,
0.1845163256,
-0.3242484927,
0.0352262184,
0.230334729,
-0.1621302515,
-0.071156837,
-0.2606827617,
-0.1054632813,
0.2171175033,
0.466180712,
0.3706047237,
-0.1051321775,
0.1368006766,
0.146794185,
0.7618208528,
0.1414896995,
-0.0374398641,
0.1675718725,
-0.2166180015,
-0.0557150543,
-0.0650106519,
-0.2196323723,
0.3488070071,
0.0578964613,
0.2559829354,
0.2494225204,
0.0087830843,
-0.0710950941,
-0.013018257,
-0.0326781459,
0.173613742,
-0.2623085082,
0.0621386655,
-0.106457375,
0.2445471138,
-0.1541185677,
-0.1030506119,
0.0982700586,
0.148290351,
0.0332709961,
0.3051649332,
0.2418823987,
-0.0048581231,
-0.3400764763,
0.2316672206,
0.0500859544,
-0.0254364759,
0.4591471255,
0.1523965895,
-0.0817897841,
-0.3274260759,
-0.0229717027,
0.2177787423,
0.3757546246,
0.022353163,
-0.1600226164,
0.2420523167,
-0.2797829509,
0.0957334638,
-0.0627897754,
-0.1419170052,
0.2651337981,
0.1365962476,
-0.2265186906,
-0.2088277638,
-0.4525534511,
0.6382114291,
0.2376547456,
0.1253290027,
-0.1646066308,
-0.1204737648,
-0.1061432287,
0.3573410809,
0.3048980832,
0.1519404352,
0.4276483357,
-0.3566948175,
-0.0998592451,
0.1492119879,
-0.3736146986,
-0.0143566448,
-0.0612450913,
0.3366985321,
0.1082260609,
0.1192401126,
0.0453301966,
-0.0357772224,
0.347111702,
0.276840657,
0.0754221752,
0.0341873392,
0.2072058469,
-0.2491635233,
0.6603633165,
0.0180792324,
-0.1201893687,
0.1139635667,
-0.1075235829,
0.2276897579,
-0.2075395286,
0.2011722624,
0.1504577994,
-0.1241231635,
-0.0489717685,
-0.2586784959,
0.1943368912,
-0.1102436334,
0.0885293037,
0.2040878385,
0.1262369603,
-0.1882253438,
0.2667073309,
0.1713541001,
0.6822240353,
0.255564332,
-0.1555181593,
-0.21319592,
0.2625065744,
0.0681591332,
-0.0122492677,
0.38923195,
-0.1951939464,
-0.4087659717,
-0.0564957224,
-0.1337778121,
0.2152267396,
0.2251753509,
-0.2677851915,
0.1174745262,
0.0604244247,
0.2310129851,
-0.216132924,
0.0237825364,
-0.2089012116,
-0.1508903652,
0.001767282,
0.1331101656,
0.2012601346,
-0.1054565832,
0.2148824483,
-0.1578713804,
0.080255188,
-0.0467991903,
0.0021794043,
-0.1113366112,
-0.1250502616,
0.2613846064,
-0.0188215449,
-0.2644607723,
0.5452488661,
0.0321585312,
0.0517910644,
0.0696825385,
0.0568883196,
0.0676963553,
-0.090675056,
0.2380611748,
-0.1855898649,
0.0822538286,
0.5425282717,
-0.0215040073,
-0.2229049802,
-0.1634112597,
0.1478691101,
-0.4970170259,
-0.2148628086,
0.1375739425,
-0.0488438308,
-0.3887244165,
0.0796110108,
0.1683112234,
0.1969220191,
-0.3357969224,
0.2506589293,
-0.0879490897,
-0.2204864323,
0.452670455,
0.27572909,
-0.0559811778,
-0.1782752872,
0.0859968513,
-0.062427111,
0.2936299443,
-0.0864759684,
-0.1064166799,
-0.218486473,
-0.3070993125,
0.1186006814,
0.0384999886,
0.1215798855,
0.2482917607,
-0.2845219076,
0.109977901,
0.1864691526,
0.3085389435,
0.0296597537,
0.1518340558,
-0.2636839151,
-0.2571392059,
0.1572282314,
-0.0346493423,
-0.0832224786,
0.4009620845,
-0.1801169962,
0.238624841,
-0.0177044403,
0.0759878904,
-0.4225296676,
-0.1226854473,
-0.1012698337,
0.1858926415,
-0.2196107507,
0.0122040296,
0.2173189521,
0.0441851765,
0.1895851046,
0.0221979301,
-0.0542839207,
-0.2754721642,
-0.231634438,
0.0173905455,
-0.046029713,
0.0812428147,
-0.2249396592,
0.0200270973,
-0.4240547419,
-0.0494290255,
0.3600240052,
-0.1370466799,
-0.0420106612,
0.4651861787,
0.4188354611,
-0.2643191814,
-0.0097514791,
-0.0158670209,
0.0638481379,
0.2388870716,
0.0590017997,
0.1540207863,
0.127500996,
-0.042371124,
0.0340880863,
-0.1172408834,
-0.0281320456,
-0.1457090229,
0.0465827808,
0.2320061326,
0.0445338227,
-0.1358427256,
0.4890651405,
0.4204424322,
0.1400029659,
0.1139381006,
-0.0073824422,
0.331720978,
-0.1489473432,
-0.0350157693,
0.0287828986,
0.1240615472,
0.1742103547,
0.3615043461,
0.0863119811,
0.3182870448,
-0.0555869862,
-0.0207835808,
0.0040094336,
0.0080083301,
0.3773131371,
0.2138914168,
-0.1946135461,
0.0186255649,
0.3114884496,
-0.1920402497,
0.1443356574,
0.0423106886,
0.1224101111,
0.6489207149,
0.2265137285,
0.0816278458,
-0.0974712521,
0.0611020327,
-0.1310683191,
0.2850148082,
-0.2290724367,
-0.0315435119,
0.1469400525,
0.4777131379,
-0.5227757096,
-0.264772743,
0.0650781766,
0.0128229326,
-0.0474361964,
0.0072251735,
-0.1674042344,
-0.1747517139,
-0.2168537378,
0.0383875445,
0.3586482108,
0.0194365159,
0.4860092998,
0.0338868946,
0.1913314164,
0.1446145624,
-0.0595632978,
0.1498439461,
0.2534327209,
-0.1020296961,
-0.3012531996,
0.1169562861,
0.1203009337,
0.1675801724,
0.1666800827,
0.1402904987,
-0.1371965557,
-0.177603066,
-0.3863644898,
0.3821321726,
-0.1438274086,
0.1699549705,
0.1545838863,
-0.058238104,
-0.0852848291,
0.3448764384,
0.2291963547,
-0.1895205081,
0.11211624,
0.2364937067,
0.1905555874,
-0.4742107093,
0.379793942,
0.29505077,
-0.097185716,
0.0724363029,
-0.0552045219,
0.1814488918,
-0.2212629914,
-0.0505931228,
-0.3344269395,
-0.0171903037,
-0.1684636027,
0.1486688852,
0.1084737554,
0.6447477341,
-0.3289763629,
-0.2689524293,
-0.11910294,
-0.2778251767,
-0.0742100626,
-0.1967042387,
0.2914133668,
-0.079056792,
-0.0475171655,
0.2261488885,
0.0448392145,
0.0536211282,
0.1104607731,
-0.2831478417,
0.3139964044,
0.2387503535,
-0.3837475479,
0.0892713144,
-0.1436838359,
-0.0569255017,
-0.0605707169,
-0.1970451772,
0.1779619604,
-0.1288994849,
0.0614913329,
-0.043425452,
0.0068089752,
0.522947669,
0.0391938165,
0.0222737305,
-0.0738676265,
0.4719516635,
-0.0625697225,
0.3241916299,
0.1853877753,
-0.1183009967,
-0.2009815127,
0.0763684437,
-0.0966729596,
0.3955195546,
0.1839701682,
-0.104152903,
-0.18155168,
0.1832259595,
0.110200651,
0.0872193947,
0.0694668964,
0.1536949873,
0.0124505386,
-0.2506685853,
0.2798533142,
0.3707998395,
-0.1970091313,
-0.1617906988,
-0.0112429988,
-0.3040784001,
-0.029917635,
-0.0906468928,
-0.237727046,
-0.3506932557,
0.059606079,
0.2465263754,
-0.1107148156,
-0.4389809668,
-0.2195644379,
0.100007236,
-0.1826618612,
0.0668182224,
0.5939300656,
0.1303530335,
0.1333308965,
0.0537290946,
0.2797352672,
-0.1238490492,
-0.0022866018,
-0.0009008984,
-0.1168259606
] |
https://github.com/huggingface/datasets/issues/3452 | why the stratify option is omitted from test_train_split function? | Hi @lhoestq I would like to add `stratify` parameter, can you give me some pointers for adding the same ? | why the stratify option is omitted from test_train_split function?
is there any other way implement the stratify option while splitting the dataset? as it is important point to be considered while splitting the dataset. | 20 | why the stratify option is omitted from test_train_split function?
why the stratify option is omitted from test_train_split function?
is there any other way implement the stratify option while splitting the dataset? as it is important point to be considered while splitting the dataset.
Hi @lhoestq I would like to add `stratify` parameter, can you give me some pointers for adding the same ? | [
-0.5134284496,
-0.1317567527,
-0.115856044,
-0.1088105962,
0.2143979073,
-0.0632685944,
0.3055258095,
0.1485875547,
-0.0885695368,
0.3909530342,
0.078435339,
0.3760671616,
-0.0534927361,
0.2609143257,
-0.0250584893,
-0.4552244842,
-0.0951922089,
-0.0083258748,
-0.1576342285,
0.145107016,
-0.1588095278,
-0.0798936412,
-0.4538412094,
-0.3113557696,
-0.119354777,
0.1650991738,
0.0350115374,
-0.0273550544,
-0.2073325217,
0.0387431644,
0.0390492082,
0.0908190012,
0.094297938,
0.2767519951,
-0.0001068031,
-0.1057456881,
-0.0092889797,
-0.3452890217,
-0.0581333973,
-0.4762871563,
-0.2152582705,
0.2039278895,
-0.2135872841,
-0.0708325207,
-0.2053131014,
0.0423050299,
-0.2274042666,
-0.290372014,
0.3696855307,
0.1426468343,
0.198246479,
0.2200733125,
-0.3088658154,
-0.1376615018,
-0.0793468356,
0.0073059932,
-0.2524676919,
-0.0183646586,
-0.2207409292,
0.151699692,
0.042271778,
0.049379319,
0.3879317641,
-0.295679599,
-0.0129075367,
-0.1628820896,
-0.4886379242,
-0.2513941526,
-0.2534247935,
-0.0694584846,
0.3071352243,
0.097023502,
-0.1299767941,
0.3809051514,
0.0252344273,
-0.261477232,
0.1638513803,
0.1683273464,
0.1086531878,
0.2151513547,
-0.2294895202,
-0.0054256576,
-0.3174060285,
0.172996968,
0.2485696822,
0.3424180746,
-0.2135677189,
0.0449487753,
0.350251317,
0.3388407528,
-0.4608415067,
-0.1154168472,
0.2320666015,
0.172256127,
-0.377086103,
-0.240088746,
-0.310726583,
-0.2726857066,
0.1237026602,
0.3467790484,
-0.0149161182,
0.1787366569,
0.486307621,
-0.0790697336,
0.1986675411,
0.0091436058,
0.0816038027,
0.1147729829,
-0.1542800218,
-0.1741110384,
-0.1355922818,
-0.2414078563,
0.1715714782,
-0.184994325,
0.0913954154,
-0.0195250325,
-0.1800529063,
-0.0642059743,
-0.1744956076,
-0.5218609571,
-0.3590185344,
-0.286049962,
0.191031754,
0.2415479571,
0.1241454333,
-0.2109053731,
-0.4882138968,
0.1919753104,
-0.2838025689,
-0.0908608139,
-0.2541135848,
0.3007392585,
-0.0730846301,
0.1840557456,
-0.0833405778,
-0.2734487653,
-0.0477505401,
0.2561798096,
0.3570987284,
-0.0022636082,
0.041880995,
-0.030368384,
0.3082016408,
0.2063251883,
0.1271265447,
-0.2040489912,
-0.1682329029,
0.4711243808,
-0.0763494223,
0.1107606813,
-0.1595261842,
-0.7662485838,
-0.1915908456,
0.2090332061,
0.3217534423,
0.0344852805,
-0.3623131514,
0.2846831679,
0.0391373336,
-0.0571984872,
0.1054620072,
-0.1254145056,
-0.2829788327,
-0.238751322,
0.4378868043,
-0.071015276,
-0.1584219784,
-0.1225547567,
-0.1462253779,
-0.0370967239,
0.7209694386,
-0.0065425183,
-0.2344972938,
-0.2130298167,
-0.0631039739,
0.459893167,
0.7456841469,
0.2250279933,
-0.1782921255,
0.0425325632,
-0.0891409516,
-0.248100549,
0.1470003128,
-0.1778560579,
0.197345078,
0.0641916916,
-0.221652329,
0.2336584479,
-0.1810191125,
-0.2141320258,
0.0563220493,
0.0370457545,
0.5085085034,
0.2862650752,
0.0491932482,
0.0641161054,
0.2143456489,
0.2570227683,
0.2756148577,
-0.0716772079,
0.1132795885,
-0.171422556,
0.2921884954,
-0.1704004407,
-0.1162393689,
-0.5170232654,
0.0899343267,
-0.1785237342,
0.4102614522,
-0.1061804742,
0.331784308,
-0.1889739335,
-0.2236508876,
-0.4522276521,
0.0633812174,
0.1459336579,
0.1159654632,
-0.0327546746,
0.1084069163,
-0.2970435321,
-0.2300737798,
0.2821528614,
-0.4069468975,
0.0460404083,
0.2095855772,
0.1871627122,
-0.1983460337,
-0.1751495004,
0.2169170976,
0.1921061128,
0.1056951508,
-0.3519948423,
-0.1029093862,
0.3887726367,
0.2985583246,
-0.4550960064,
-0.0232811645,
-0.1178788766,
0.1032186374,
-0.2273409218,
-0.2374484837,
-0.1419317424,
-0.0332605876,
0.0531362742,
-0.0749903694,
0.3545763195,
-0.4837943614,
-0.0943828896,
0.1296887547,
-0.0372149237,
0.0604193136,
-0.1262171566,
0.0767804757,
-0.208586067,
-0.3548511267,
-0.2762880027,
0.1555562168,
0.0429619625,
-0.5344241858,
0.0614208803,
0.3116385937,
0.101620473,
-0.0300676432,
-0.1532969475,
0.4862812161,
-0.1829990745,
0.1373953819,
0.0859166086,
0.4660526216,
0.1672530472,
0.1385687292,
-0.2070239931,
-0.0053467825,
-0.0672813356,
0.1447924525,
0.1418918371,
0.0866247341,
0.0153883174,
-0.222556144,
0.1581810862,
-0.272154361,
-0.0389375165,
-0.0616111085,
-0.289049238,
0.023718087,
0.0432845838,
-0.4055069685,
-0.0408171006,
0.0653017014,
-0.0374500751,
-0.2073708922,
-0.1493994594,
0.1328900456,
-0.2755148709,
-0.2333253324,
0.2551240921,
-0.13097395,
0.4551087022,
0.0821205005,
-0.0066199503,
0.0738975704,
0.3598189056,
0.1410654187,
0.2165853232,
-0.2403257191,
0.3418519497,
0.4181846678,
-0.0041549066,
-0.1124120355,
0.0522056818,
-0.1923434287,
0.2037205547,
-0.2311590761,
0.1420592219,
-0.005010698,
-0.2141829133,
-0.3991208375,
-0.2356480658,
-0.2640393376,
-0.2373082936,
-0.0988382548,
-0.2265975624,
0.1536122262,
0.0193828028,
-0.4136286676,
-0.7435683608,
-0.2005932331,
-0.2913881242,
-0.2140146941,
-0.2235487849,
-0.0325620025,
-0.1827192307,
-0.0759934857,
-0.0417259559,
-0.0735268965,
0.0872371271,
-0.3203111589,
-0.2148990631,
0.3054413497,
-0.4099448919,
-0.2580040991,
0.1165740937,
0.3119964898,
-0.0111699626,
-0.0522731468,
-0.0245227888,
0.0210865773,
0.0806645751,
0.1884682477,
-0.3922058642,
0.1446888,
0.1916414797,
-0.2511528134,
-0.0288772061,
-0.3065425456,
-0.1638936549,
0.1523201615,
0.5473328829,
0.442465961,
-0.0574358776,
0.2654493153,
0.0010571849,
0.7963004708,
0.1315540224,
-0.0216490459,
0.1750082523,
-0.1553601772,
-0.0586251095,
-0.1407389045,
-0.257383287,
0.3999217153,
0.1234682351,
0.2343219072,
0.270275265,
-0.0440227464,
0.0259332098,
-0.0118398704,
-0.1819452792,
0.1368492842,
-0.1829445064,
0.0039775036,
0.0460517891,
0.2954087853,
-0.1024378687,
-0.1891910583,
0.1025931984,
0.1524392217,
0.0209694859,
0.5084146261,
0.4257503748,
-0.0063878773,
-0.3901019692,
0.1454479396,
0.0460771322,
0.0076417369,
0.4470238388,
0.1983350068,
-0.1676535755,
-0.2317334861,
0.0639811084,
0.2775690258,
0.3390665054,
0.0882425457,
-0.2306853086,
0.1886551827,
-0.3701639175,
0.2233656496,
0.0284623224,
-0.1428480595,
0.3261749446,
0.2390690446,
-0.3350613415,
-0.1575856209,
-0.4917578995,
0.6516014934,
0.2684769034,
0.1529845595,
-0.2521646917,
-0.0642362237,
-0.1580352485,
0.3398031592,
0.1652923375,
0.1021000594,
0.3578810394,
-0.3621298671,
-0.0469193421,
0.2565657794,
-0.327688545,
-0.0179486535,
-0.10762804,
0.2439460605,
-0.0124768093,
0.0280143656,
-0.1007848009,
0.0494038612,
0.3659784794,
0.282024473,
0.0618512556,
-0.1391957551,
0.3303167522,
-0.2434267104,
0.788508296,
-0.0098290043,
-0.2235960215,
0.2944984138,
-0.1337187439,
0.1841512471,
-0.0750947148,
0.0554147102,
0.1714987904,
-0.1267205924,
-0.0390293002,
-0.1645110697,
0.0444583446,
-0.0995204598,
0.0894788876,
0.198467344,
0.0480702035,
-0.1081192419,
0.1913547963,
0.0746022612,
0.8064485788,
0.3217679858,
-0.2177685052,
-0.2933292985,
0.2316793948,
-0.0070937849,
0.0349446237,
0.229486987,
-0.1568131298,
-0.2963978052,
-0.0817384124,
-0.1154500097,
0.312833488,
0.2842738628,
-0.3520962298,
0.1259477884,
0.0834343061,
0.262552619,
-0.1839413047,
0.0690501109,
-0.1708470881,
-0.0937845409,
-0.1473468542,
0.0708672032,
0.2128619403,
-0.0556483679,
0.1244139522,
-0.1544425935,
0.204542011,
-0.0483065471,
0.118291311,
-0.1403590441,
-0.222133711,
0.1901706457,
0.0266366843,
-0.2223239094,
0.7618203163,
0.0985217243,
0.0714220181,
0.0544490628,
0.1317803264,
-0.0018818182,
-0.1108118668,
0.2154280394,
-0.2417660654,
0.1928018332,
0.3958102167,
-0.0986254513,
-0.2744448185,
-0.0483442843,
0.0977307558,
-0.5186982155,
-0.2688908875,
0.1442533433,
0.0826503038,
-0.3659190238,
0.0431351624,
0.0929030702,
0.1659958661,
-0.2755949795,
0.2051874399,
-0.038355574,
-0.1115073785,
0.4389328957,
0.2472792864,
-0.0922665074,
-0.2649290562,
0.0404871888,
-0.0711582601,
0.3151043355,
-0.086102128,
-0.1560002565,
-0.2437681705,
-0.3090105951,
0.107404083,
-0.1158617884,
0.0501241796,
0.1097648889,
-0.1313752681,
0.2137918919,
0.1108590886,
0.2853390872,
0.0046728188,
0.1023962051,
-0.2850540578,
-0.2014116943,
0.1730060428,
-0.050407052,
-0.1589320451,
0.2189792693,
-0.0450124554,
0.1966208965,
0.0503373966,
0.120148316,
-0.3669217229,
-0.138253808,
-0.0249501877,
0.1778822541,
-0.190070346,
0.0840789378,
0.1774235815,
0.1226433367,
0.1394544691,
0.0081156641,
-0.1369622946,
-0.1975717694,
-0.1676737964,
0.0624281839,
-0.1288309395,
0.112719886,
-0.295103997,
0.0678222105,
-0.4177818894,
0.115670681,
0.3677186668,
-0.1910847425,
0.0661557987,
0.4863019288,
0.3420719802,
-0.3194917738,
-0.1876674592,
0.0295952037,
0.0375534706,
0.3270674348,
-0.0288563129,
0.1646682471,
0.160490036,
-0.1196526587,
-0.1307217032,
-0.1480340809,
0.0188675839,
-0.1320830882,
-0.0138690965,
0.3323829472,
0.1672839075,
-0.2178182453,
0.3370009065,
0.3432564735,
0.0740538463,
0.1002037898,
0.0266925134,
0.2599085569,
-0.0907099247,
0.0078021684,
0.0077917785,
0.0839138255,
0.1181212887,
0.3368067443,
0.1071765497,
0.400728792,
0.0860049501,
-0.065115273,
0.0248241369,
-0.0225660894,
0.2844671607,
0.2817878127,
-0.1751206517,
0.2431318313,
0.369255811,
-0.016891459,
0.0088463118,
-0.0287241191,
0.1809897423,
0.6609165668,
0.1789808273,
0.1094385758,
-0.0137891965,
-0.0366295762,
-0.1109588221,
0.3799537718,
-0.3461683989,
-0.0601096265,
0.1728700101,
0.3271583021,
-0.4154466689,
-0.2879450321,
0.2204473913,
0.0261023212,
-0.0586575232,
0.0634087771,
-0.1664607972,
-0.0797737986,
-0.2166397721,
-0.0109256152,
0.3329166472,
0.1591881961,
0.4858214855,
0.0548347719,
0.2856094539,
0.3303278089,
-0.0524491481,
0.0813060328,
0.2014041394,
-0.0124025838,
-0.2628765702,
-0.0570429415,
0.2642680407,
0.1662195623,
0.1589808911,
0.0053400011,
-0.1141831204,
-0.0135162938,
-0.3773333132,
0.4859395623,
-0.1610081494,
0.163336575,
0.2463407367,
-0.0966773853,
-0.0773482844,
0.2300221473,
0.1880578399,
-0.1667561531,
0.1013458669,
0.337749809,
0.2044051737,
-0.483135283,
0.4419530928,
0.2639530897,
-0.1448201835,
0.01208214,
-0.0082115652,
0.172980383,
-0.2137058377,
-0.0387080014,
-0.3716946244,
-0.042237781,
-0.2307139486,
0.1136180758,
0.11007981,
0.5424067974,
-0.1737125963,
-0.2911669016,
-0.0519673117,
-0.3655089736,
0.0866929591,
-0.1568864882,
0.3641720712,
-0.0563754439,
-0.1178323627,
0.2390737087,
0.0319142789,
0.1078080833,
0.1823386848,
-0.3951519132,
0.2388301045,
0.1833503097,
-0.3660154343,
0.1030717492,
-0.0735762492,
0.0989350379,
-0.1065997928,
-0.1360886097,
0.250947088,
-0.1764400601,
-0.0079136118,
-0.2163149863,
0.0456255749,
0.5232406259,
0.1085073054,
0.0113192992,
-0.0848825425,
0.403898865,
-0.1427398324,
0.2927704453,
0.3832502961,
-0.0714600086,
-0.084179908,
0.0576995276,
-0.1803168058,
0.2752528191,
0.2715690732,
-0.1413798183,
-0.1049575135,
0.2083810717,
0.0745249018,
0.0931534767,
0.039234858,
0.2067563534,
0.0447912365,
-0.2694517672,
0.2849061787,
0.323495388,
-0.1868070662,
-0.1990131289,
-0.0970786363,
-0.1729597151,
-0.0598753542,
0.0274352375,
-0.2432055324,
-0.4005160034,
0.1105144024,
0.1289306432,
-0.1829076707,
-0.531532824,
-0.2364755422,
0.1339370906,
-0.214677155,
0.152799055,
0.7351974249,
0.1119328514,
0.2064080834,
0.1152461469,
0.3434330225,
-0.2100213915,
-0.0108094541,
0.0613890328,
-0.0785995424
] |
https://github.com/huggingface/datasets/issues/3452 | why the stratify option is omitted from test_train_split function? | Hi ! Sure :)
The `train_test_split` method is defined here:
https://github.com/huggingface/datasets/blob/dc62232fa1b3bcfe2fbddcb721f2d141f8908943/src/datasets/arrow_dataset.py#L3253-L3253
and inside `train_test_split ` we need to create the right `train_indices` and `test_indices` that are passed here to `.select()`:
https://github.com/huggingface/datasets/blob/dc62232fa1b3bcfe2fbddcb721f2d141f8908943/src/datasets/arrow_dataset.py#L3450-L3464
For example if your dataset is like
| | label |
|---:|--------:|
| 0 | 1 |
| 1 | 1 |
| 2 | 0 |
| 3 | 0 |
and the user passes `stratify=dataset["label"]`, then you should get indices that look like this
```
train_indices = [0, 2]
test_indices = [1, 3]
```
these indices will be passed to `.select` to return the stratified train and test splits :)
Feel free to îng me if you have any question ! | why the stratify option is omitted from test_train_split function?
is there any other way implement the stratify option while splitting the dataset? as it is important point to be considered while splitting the dataset. | 114 | why the stratify option is omitted from test_train_split function?
why the stratify option is omitted from test_train_split function?
is there any other way implement the stratify option while splitting the dataset? as it is important point to be considered while splitting the dataset.
Hi ! Sure :)
The `train_test_split` method is defined here:
https://github.com/huggingface/datasets/blob/dc62232fa1b3bcfe2fbddcb721f2d141f8908943/src/datasets/arrow_dataset.py#L3253-L3253
and inside `train_test_split ` we need to create the right `train_indices` and `test_indices` that are passed here to `.select()`:
https://github.com/huggingface/datasets/blob/dc62232fa1b3bcfe2fbddcb721f2d141f8908943/src/datasets/arrow_dataset.py#L3450-L3464
For example if your dataset is like
| | label |
|---:|--------:|
| 0 | 1 |
| 1 | 1 |
| 2 | 0 |
| 3 | 0 |
and the user passes `stratify=dataset["label"]`, then you should get indices that look like this
```
train_indices = [0, 2]
test_indices = [1, 3]
```
these indices will be passed to `.select` to return the stratified train and test splits :)
Feel free to îng me if you have any question ! | [
-0.3376852274,
-0.1832867414,
-0.1047078744,
0.1171168387,
0.2018857002,
-0.0858201459,
0.3129179776,
0.1023204327,
-0.0346965976,
0.3047149181,
-0.0190207548,
0.5014281869,
-0.0940354541,
0.2779452801,
-0.0283282306,
-0.5074386597,
-0.0960934237,
0.0319260135,
-0.2141888887,
0.1700921506,
-0.0419331975,
-0.006981119,
-0.4544807673,
-0.2334385812,
-0.2628436089,
0.1033921242,
-0.016614927,
-0.095812656,
-0.368666172,
-0.1709285975,
0.2846076488,
0.025125565,
0.0215586107,
0.401768744,
-0.000111072,
-0.0535658188,
0.0017707605,
-0.3129101694,
-0.0715311319,
-0.5595552325,
-0.1961295903,
0.1695765704,
0.0227305163,
0.0015748241,
-0.2184434533,
-0.2978336811,
-0.3208585978,
-0.3136143386,
0.393886447,
-0.0218404531,
0.1633078605,
0.3562992811,
-0.1911716163,
-0.1234652102,
-0.0849837661,
0.0691781491,
-0.2794132233,
0.2094421089,
-0.2640932798,
0.1702763438,
0.1465464532,
0.2100408822,
0.4105549157,
-0.3316379189,
0.1022013426,
0.0046005785,
-0.4900355935,
-0.2407565713,
-0.2997126281,
0.0443572626,
0.364664644,
0.0468089506,
-0.3524330854,
0.1519047916,
0.0452062674,
-0.4107649624,
0.079121165,
0.1604895741,
0.1172816083,
0.1931265891,
-0.2271114141,
0.0947679803,
-0.3211034238,
0.1725358367,
0.3020272851,
0.4047162235,
-0.2530813515,
0.1176612303,
0.5106753111,
0.2752676904,
-0.4427288771,
-0.0602249764,
0.1906806529,
0.222830534,
-0.4606953859,
-0.230890438,
-0.32060498,
-0.3133934736,
0.2546060681,
0.4761583805,
0.1399735957,
0.2108923346,
0.2869281471,
-0.0319774821,
0.286614269,
0.2326503396,
0.1900132298,
0.1746810377,
-0.1814234406,
0.0031541372,
-0.0286051612,
-0.2602051795,
0.0474508107,
-0.2273466587,
0.023311438,
-0.0354797691,
-0.2490942627,
-0.046177052,
-0.1923693419,
-0.5446055532,
-0.4068240225,
-0.226367861,
0.2901254296,
0.2805149555,
0.0730043501,
-0.2072091699,
-0.4749847054,
0.3638924658,
-0.2340214401,
0.1167202145,
-0.2596014738,
0.1714468598,
-0.1668905467,
0.1890642494,
-0.023995243,
-0.3066495061,
0.1121598035,
0.2981179357,
0.3822115064,
-0.1240169778,
0.0224036742,
0.0535290875,
0.4254344404,
0.2580646574,
-0.0102949943,
-0.1575225592,
0.0436548255,
0.2756248415,
-0.1323718727,
-0.0147664752,
-0.138763532,
-0.6902291775,
-0.1079757512,
0.1297175288,
0.2120031863,
0.0444465317,
-0.4457944632,
0.2684272528,
0.0987247378,
0.0531446114,
0.2080256939,
-0.1743197143,
-0.1467565149,
-0.2404096723,
0.5547696948,
0.0999593139,
-0.1279682368,
-0.100019902,
0.0263421237,
-0.0632215068,
0.5412700772,
0.0310070384,
-0.2344833165,
-0.346057862,
-0.0410556942,
0.5389015079,
0.5255013704,
0.1865770966,
-0.1944560111,
-0.0517440178,
-0.0606705956,
-0.1184106842,
0.0922644213,
-0.1354189962,
0.0336030088,
0.1028034836,
-0.1889647394,
0.2234656662,
-0.0785758868,
-0.1983673722,
0.0503275208,
-0.1831481159,
0.4571466446,
0.187898919,
-0.1121807545,
-0.1367294788,
0.0658165142,
-0.0214197617,
0.4522061646,
-0.0596412309,
0.1022354588,
-0.1044338718,
0.1585525274,
-0.0575774051,
-0.0152378641,
-0.5065770149,
0.0395957045,
-0.0214827508,
0.2953599989,
0.0215497445,
0.0595614538,
-0.251211971,
-0.2812520564,
-0.2775264978,
-0.1246147901,
-0.0860270709,
0.0820063725,
-0.1463773847,
0.2534968853,
-0.2467258573,
-0.3324322104,
0.023782732,
-0.3055219054,
0.2105007172,
0.0313861705,
0.2302842736,
-0.0494400747,
-0.1966229081,
0.0400538594,
0.2525256574,
0.0525370426,
-0.36645329,
-0.0455319807,
0.4818964303,
0.2913968861,
-0.3806391656,
-0.0657409355,
-0.118927829,
0.1406264007,
-0.4193663597,
-0.1896234751,
-0.0870793909,
0.0543194115,
0.0957290158,
-0.1207812652,
0.5623719692,
-0.5408415794,
0.1191762537,
0.0891599059,
0.0237212479,
-0.0300303549,
-0.0384385735,
-0.0782331005,
-0.2653543353,
-0.4447279871,
-0.4379208386,
0.1832114756,
-0.0084677897,
-0.5160092711,
0.116590865,
0.1918135881,
0.2309796214,
-0.05236388,
-0.1867100298,
0.2177756429,
-0.0495069772,
0.0849170014,
-0.0131943291,
0.3981100917,
0.175836578,
0.2065851837,
-0.1946192682,
0.0326084457,
-0.0517008454,
0.1947586834,
0.1314025372,
0.1830830723,
0.0222734399,
-0.1989627331,
0.037622679,
-0.2813162804,
0.0120593505,
-0.1965525597,
-0.3313919604,
-0.0374962501,
0.141190663,
-0.3906755745,
-0.1051171422,
-0.0167461969,
-0.2987337708,
-0.2068015039,
-0.0856497809,
0.066815868,
-0.2479157895,
-0.1815853566,
0.2925269306,
-0.3204953074,
0.202672869,
0.1146462932,
-0.1366840303,
0.0049012695,
0.2031190693,
0.1340671182,
0.1088141203,
-0.1763068587,
0.3501371145,
0.4281661808,
0.1266886592,
-0.2656632364,
0.0615117401,
-0.149542883,
0.2477269024,
-0.4289467633,
0.1428819001,
0.0789652765,
-0.1849499494,
-0.4167137146,
-0.1558458805,
-0.0390647464,
-0.2716833949,
-0.1349868476,
-0.2131227702,
0.2839476466,
0.0382781737,
-0.3589575887,
-0.7297251821,
-0.2589991093,
-0.2668716908,
0.039708361,
-0.1429484189,
-0.0004161133,
0.0288717449,
0.0423943214,
0.0548473522,
-0.1054276675,
0.0495781526,
-0.19628492,
-0.1385394633,
0.2552309036,
-0.4576142728,
-0.2534153461,
0.0351878926,
0.1400253326,
-0.0123032574,
-0.058915507,
-0.0060102334,
0.0520504564,
-0.0268368647,
0.1349837631,
-0.3093068004,
0.2455775589,
0.412770927,
-0.1594915539,
0.0031549043,
-0.2972419858,
-0.1063815355,
0.2428905815,
0.4031877518,
0.3507999182,
0.0192700829,
0.1233494431,
0.0977881476,
0.9815270901,
0.3402635753,
0.0648767352,
0.2859348357,
-0.2640924454,
0.0254330486,
-0.21386002,
-0.2754728794,
0.2405130267,
-0.0643476471,
0.3462203741,
0.1327104568,
0.0910247788,
0.1017407402,
-0.0506138317,
-0.0426472165,
0.0316937491,
-0.2526383102,
0.0503069386,
-0.1099296808,
0.1613601297,
-0.1154845357,
-0.0518512651,
0.1744040996,
0.1463383734,
0.0773759931,
0.3320485651,
0.3973811269,
0.0774419904,
-0.4541842043,
0.2076718062,
-0.0912533104,
0.0326644108,
0.4433419704,
0.0706887394,
-0.004060999,
-0.3675042689,
0.1208555475,
0.2657715976,
0.4384290278,
0.062885195,
-0.1920427382,
0.1120634675,
-0.3230317235,
-0.0565447472,
0.0937642977,
-0.1486298889,
0.2876964509,
0.0808830336,
-0.1023307443,
-0.3446829319,
-0.5141717196,
0.5189234018,
0.3729541302,
0.1555637866,
-0.1936398447,
-0.2337409705,
-0.0679905638,
0.2800478637,
0.2322919667,
0.1715822667,
0.3910597861,
-0.3561607301,
-0.017461488,
0.1247383133,
-0.2659433186,
-0.066502057,
-0.0618427508,
0.4021639824,
-0.1399917901,
0.0696314648,
0.2180577666,
-0.0014333844,
0.3473854065,
0.5958777666,
0.1172868758,
-0.2427348793,
0.198733747,
-0.1622150838,
0.7832286358,
0.1480835378,
-0.1171829253,
0.2819027603,
-0.0674612075,
0.2293192893,
-0.0966378227,
-0.0102961557,
0.2135791928,
-0.1038758904,
-0.1536585689,
-0.3040917814,
0.3000946045,
-0.1496147066,
0.0225358773,
0.3293628991,
0.4725294411,
-0.0952246711,
0.2425986379,
0.1336201131,
0.8496340513,
0.3945810497,
-0.0636500567,
-0.0679394603,
0.1376294196,
0.1591284126,
0.2458132058,
0.350704819,
-0.3474468291,
-0.3378596008,
-0.065015547,
-0.2250777036,
0.2061143517,
0.1924747676,
-0.2237991989,
0.1589723527,
-0.1404223144,
0.1198179945,
-0.2733489275,
0.041954685,
-0.3559838235,
-0.1662243307,
-0.1240587682,
0.0658026263,
0.2910080254,
0.0853300095,
0.190981701,
-0.1666235626,
-0.1172434986,
-0.1366050392,
0.0081351139,
-0.0483578332,
-0.2685137689,
0.2359433919,
0.1524932384,
-0.4085146189,
0.6816512942,
0.1277495325,
0.1167335808,
-0.0620440952,
0.0680744275,
-0.0672490373,
-0.1533935815,
0.1753260195,
-0.1315789968,
0.0301797017,
0.5340799689,
0.0119787091,
-0.268351227,
-0.1510254592,
0.0503779761,
-0.4662740529,
-0.1321677566,
0.1960354298,
0.0805519149,
-0.3775747418,
-0.0127011212,
0.0870612934,
0.1694115102,
-0.3131161332,
0.1448641568,
-0.0103663597,
-0.1576648802,
0.242771104,
0.2806635201,
-0.0557426438,
-0.215662986,
0.096728228,
-0.1028826609,
0.2499789298,
0.0945962816,
-0.0395649262,
-0.2618275583,
-0.2676625252,
0.1371956021,
0.2119758576,
-0.1891421974,
0.1022911742,
-0.1713861674,
0.1825742722,
0.0547230504,
0.3320285678,
0.0406162292,
0.0787044838,
-0.3322235346,
-0.2654839456,
0.1081516817,
0.1480044425,
-0.0196057875,
0.2713269889,
-0.239203006,
0.2496377826,
-0.0272082482,
0.0538808927,
-0.3233223259,
-0.0258494578,
0.0286169201,
0.1726494133,
-0.1735492647,
0.0523817986,
0.3876191974,
0.0026534644,
0.1335773617,
0.0827980787,
-0.1485372633,
-0.1872196645,
-0.370711714,
0.0806550384,
-0.0758326799,
-0.0164555609,
-0.2739557028,
0.0557673946,
-0.4298330247,
-0.0809035599,
0.3702187538,
-0.1054530814,
0.038876757,
0.3348190188,
0.3482070863,
-0.1481373757,
-0.1901350766,
0.0768098831,
0.0184758697,
0.2760676146,
-0.0189218502,
0.0884477943,
0.0445077792,
-0.1738203019,
-0.0470889471,
-0.0643949956,
0.0807119235,
-0.0747716352,
0.0511112437,
0.1799102724,
0.1468667835,
-0.3485207856,
0.6383367777,
0.449583739,
0.2676564157,
0.2196608633,
0.0195850544,
0.2382942736,
-0.1650779545,
0.0151738655,
-0.0845749304,
0.1087276936,
0.0964853838,
0.4276222289,
0.0551124625,
0.5088328123,
-0.1486191154,
-0.0683611929,
0.0224708095,
-0.027634142,
0.2841011286,
0.1980163157,
-0.2823905945,
0.1166293472,
0.5485170484,
-0.0148740858,
0.2041592747,
-0.09765248,
0.0017324922,
0.6311459541,
0.1518403292,
0.1043184996,
-0.1006157696,
0.0895093903,
-0.3172970414,
0.1958256215,
-0.1821006685,
-0.0215806495,
0.0563743897,
0.6442851424,
-0.5344571471,
-0.3246156573,
0.1584615856,
0.0805195943,
0.0034791359,
-0.0193077624,
-0.1268858761,
-0.1945537031,
-0.1465248913,
-0.0732770115,
0.2811497748,
-0.0858643353,
0.4898653626,
0.0083237989,
0.3110453486,
-0.0652586892,
-0.1762637794,
0.2738797963,
0.3799913824,
-0.048225604,
-0.204871282,
0.1829710007,
0.2848364711,
0.0437595025,
0.1684942394,
0.1703464389,
-0.1699946374,
-0.1200254112,
-0.3601554334,
0.3751306534,
-0.1692601293,
0.1910409927,
0.2152489424,
-0.0188372508,
-0.2372937799,
0.2457983345,
0.1464180797,
-0.1371726096,
0.0045931111,
0.251381278,
0.3645967543,
-0.4977194071,
0.400437206,
0.0322522968,
-0.1525981277,
0.0681526661,
-0.0433757715,
0.0858236551,
-0.006343449,
-0.0753840134,
-0.3075603843,
-0.0350786597,
-0.1921038479,
0.0918696746,
0.1720626801,
0.5661844015,
-0.1094500944,
-0.15960069,
-0.1248585656,
-0.2015501708,
-0.0415136926,
-0.2520365715,
0.3706254959,
-0.151835233,
-0.1243904456,
0.177843973,
0.0960123166,
0.1830416769,
0.1679604053,
-0.1750783622,
0.4419769645,
0.3146316707,
-0.3145582378,
0.1529200524,
-0.1379148066,
0.0629704371,
-0.022898104,
-0.1852698922,
0.0947023705,
-0.1709638536,
-0.0775366426,
-0.0822569728,
0.1655723006,
0.427305758,
-0.0045744502,
0.1564919353,
0.0626012981,
0.4896810353,
-0.0106362216,
0.1060754433,
0.2899922132,
-0.1903998852,
-0.1960583776,
0.2000125796,
-0.1407720596,
0.4505740702,
0.1364288032,
-0.245219022,
-0.2161222994,
0.1940610409,
0.1415829957,
0.0333328173,
-0.078674376,
0.1907402873,
-0.0763764307,
-0.2001331896,
0.2380246669,
0.4071678817,
-0.2052201033,
-0.1247541681,
-0.026634654,
-0.2536636591,
0.1801702529,
-0.1253007054,
-0.265922159,
-0.2046091706,
-0.0032994461,
0.4281959832,
-0.3846023083,
-0.5286460519,
-0.121870853,
0.0752175972,
-0.1882373542,
0.0736917406,
0.4595592022,
0.037674997,
0.0876754969,
0.0912960395,
0.5005210042,
-0.1473472714,
-0.0032093457,
0.1018909365,
-0.155531466
] |
https://github.com/huggingface/datasets/issues/3450 | Unexpected behavior doing Split + Filter | Hi ! This is an issue with `datasets` 1.12. Sorry for the inconvenience. Can you update to `>=1.13` ?
see https://github.com/huggingface/datasets/issues/3190
Maybe we should also backport the bug fix to `1.12` (in a new version `1.12.2`) | ## Describe the bug
I observed unexpected behavior when applying 'train_test_split' followed by 'filter' on dataset. Elements of the training dataset eventually end up in the test dataset (after applying the 'filter')
## Steps to reproduce the bug
```
from datasets import Dataset
import pandas as pd
dic = {'x': [1,2,3,4,5,6,7,8,9], 'y':['q','w','e','r','t','y','u','i','o']}
df = pd.DataFrame.from_dict(dic)
dataset = Dataset.from_pandas(df)
split_dataset = dataset.train_test_split(test_size=0.5, shuffle=False, seed=42)
train_dataset = split_dataset["train"]
eval_dataset = split_dataset["test"]
eval_dataset_2 = eval_dataset.filter(lambda example: example['x'] % 2 == 0)
print( eval_dataset['x'])
print(eval_dataset_2['x'])
```
One observes that elements in eval_dataset2 are actually coming from the training dataset...
## Expected results
The expected results would be that the filtered eval dataset would only contain elements from the original eval dataset.
## Actual results
Specify the actual results or traceback.
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.12.1
- Platform: Windows 10
- Python version: 3.7
- PyArrow version: 5.0.0
| 36 | Unexpected behavior doing Split + Filter
## Describe the bug
I observed unexpected behavior when applying 'train_test_split' followed by 'filter' on dataset. Elements of the training dataset eventually end up in the test dataset (after applying the 'filter')
## Steps to reproduce the bug
```
from datasets import Dataset
import pandas as pd
dic = {'x': [1,2,3,4,5,6,7,8,9], 'y':['q','w','e','r','t','y','u','i','o']}
df = pd.DataFrame.from_dict(dic)
dataset = Dataset.from_pandas(df)
split_dataset = dataset.train_test_split(test_size=0.5, shuffle=False, seed=42)
train_dataset = split_dataset["train"]
eval_dataset = split_dataset["test"]
eval_dataset_2 = eval_dataset.filter(lambda example: example['x'] % 2 == 0)
print( eval_dataset['x'])
print(eval_dataset_2['x'])
```
One observes that elements in eval_dataset2 are actually coming from the training dataset...
## Expected results
The expected results would be that the filtered eval dataset would only contain elements from the original eval dataset.
## Actual results
Specify the actual results or traceback.
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.12.1
- Platform: Windows 10
- Python version: 3.7
- PyArrow version: 5.0.0
Hi ! This is an issue with `datasets` 1.12. Sorry for the inconvenience. Can you update to `>=1.13` ?
see https://github.com/huggingface/datasets/issues/3190
Maybe we should also backport the bug fix to `1.12` (in a new version `1.12.2`) | [
-0.1384005994,
-0.1338323355,
-0.1100934669,
0.0964838117,
0.1088930294,
0.0105679287,
0.1856798977,
0.2552303672,
-0.1076799408,
-0.0520347208,
-0.1723319888,
0.4741823375,
0.0075506228,
0.403278321,
-0.0472604558,
-0.1393702477,
0.027355304,
-0.0092402995,
0.0107643297,
-0.1231958121,
-0.1186911538,
0.1305604428,
-0.3450927734,
-0.0211684089,
0.0160580073,
-0.10237436,
-0.024028413,
0.1175240055,
0.210003525,
0.048999887,
0.3208971322,
-0.1596711874,
-0.1252475977,
0.5050558448,
-0.0001075718,
-0.0927170515,
0.0806829259,
0.0984011739,
-0.0383940078,
-0.304922998,
-0.1704864353,
0.0601614639,
0.1348725408,
-0.0514960773,
-0.1158730984,
-0.1224389747,
-0.4196151197,
-0.2483652085,
0.4687274396,
0.3174338937,
0.2649632692,
0.1299320906,
-0.1650581211,
0.1352074891,
0.1592169106,
0.1873076111,
-0.0192100611,
-0.1090771854,
0.2359384149,
-0.2113778591,
0.155759424,
0.3869310617,
-0.1809795946,
0.0119460346,
-0.0923113897,
0.2481513172,
-0.168157801,
-0.4544046223,
0.059665367,
0.0295422338,
0.04304225,
-0.1502938718,
-0.2797868252,
-0.3362354338,
-0.3209257722,
-0.1481669396,
0.1696148366,
0.2549108565,
-0.1336041242,
0.2767779529,
-0.3288031518,
0.0778299719,
0.1044429243,
0.1273610294,
-0.4663668573,
0.1356822103,
-0.0365786217,
0.1197793707,
-0.0690988973,
0.2465389222,
0.1135676131,
-0.424918741,
0.0696542636,
0.2419556975,
-0.1216741204,
-0.1311838478,
0.0682711899,
-0.0786883533,
-0.0386359915,
0.2547768354,
-0.2057003379,
-0.0214398708,
-0.019975407,
0.1225353181,
0.2637891769,
0.2001240551,
0.0986890569,
0.4429875314,
-0.0844324678,
-0.0767102093,
-0.2536472976,
-0.0309073161,
0.4921279848,
-0.0013516712,
0.0798551217,
-0.2426480502,
0.1696015894,
-0.1942241192,
-0.5532503724,
0.0515480191,
-0.5781368017,
0.040712066,
0.325286001,
0.1709711403,
-0.0841478854,
0.0329659842,
-0.0981778949,
0.1854678392,
-0.2953635752,
0.0002503177,
-0.2247843146,
-0.0153387971,
-0.2727736533,
-0.1284759492,
-0.1375160217,
-0.4086946249,
0.1086937338,
0.3947978616,
-0.0017874894,
-0.1926836818,
0.2269219607,
-0.1517410576,
0.261377722,
0.2852195203,
0.0432116352,
0.2685985565,
0.1045589522,
-0.0864050835,
-0.0256852359,
0.3098203242,
-0.2362316102,
-0.1381267309,
0.3043731153,
0.309915334,
-0.2205149978,
0.2333231568,
-0.0567469336,
0.2969112694,
0.3151140511,
0.0319143869,
-0.0042014821,
-0.332193017,
-0.4573894441,
-0.1195785627,
0.3700874746,
0.1626734138,
-0.4257056415,
-0.0984008312,
-0.1460278332,
-0.0601889603,
0.2116643637,
0.1654638946,
-0.126526311,
0.2050435841,
-0.1795262843,
0.1669019014,
0.3088755906,
-0.0847349539,
-0.4206396639,
0.2875164747,
-0.2150919139,
0.5698438287,
-0.354504317,
-0.1641796678,
0.2067888975,
-0.004237772,
0.0928822309,
0.5877625942,
-0.3927009106,
-0.0434154607,
-0.3075739145,
0.0627628788,
0.3789293766,
-0.0720625967,
0.2284968495,
0.1420857012,
0.2151849717,
-0.0858758837,
0.3948539793,
0.099453412,
0.0170624014,
-0.0925397947,
0.3155038655,
0.280619204,
0.148449257,
-0.3772065639,
0.0583437458,
0.0136495782,
0.1497053802,
-0.3050143719,
-0.0617715269,
-0.1205030456,
-0.3843897283,
0.0283853933,
-0.371240288,
-0.3694948256,
0.0561053306,
0.013080419,
0.0259653777,
-0.1087860465,
-0.0178269576,
0.5779597163,
-0.1555450559,
0.2821296155,
-0.1433886141,
0.4870600104,
0.1040683463,
-0.1162369698,
-0.3136704564,
0.1660744697,
0.1494642943,
-0.1154002175,
-0.0627289489,
0.4116948545,
0.2902378738,
-0.0891073272,
-0.1935036182,
-0.3059329093,
0.2332511395,
-0.1775752306,
-0.2204998434,
0.2306407988,
0.1639942527,
0.0155660864,
-0.0878168494,
0.5444144607,
-0.1215674281,
0.1579539478,
-0.0176633969,
0.1376492828,
0.2201116383,
-0.1096430197,
0.0691929534,
-0.2117482573,
0.0934022814,
-0.1326970309,
0.1794779003,
0.1538205743,
-0.2419986725,
0.203007862,
0.0552736595,
-0.1786915809,
-0.1528133005,
0.0055648405,
-0.0044174255,
0.0313545428,
-0.0550176017,
0.359590441,
0.5270842314,
0.1536070406,
0.2043431103,
0.168078199,
-0.1669701487,
-0.1589184105,
0.1792212874,
0.3218389153,
-0.0959983319,
0.2224205434,
0.3366271257,
-0.0253336616,
-0.0985161439,
0.3425022066,
0.0764831975,
0.0098037375,
-0.3634092212,
0.4151413441,
-0.299274683,
-0.0939564183,
-0.4596647024,
-0.1753466576,
0.0002662679,
-0.2886033654,
0.1413304508,
0.2473589778,
-0.1031970829,
0.0035899954,
0.0711678341,
0.2468176186,
-0.0999922305,
0.0397539996,
0.1709492952,
0.1394024491,
-0.4091958702,
0.194879964,
0.1409972757,
0.2390760183,
0.3816771805,
0.1443632245,
-0.3392957747,
-0.0139479153,
-0.6195431948,
0.0732087418,
-0.0653969646,
0.717871964,
-0.2272518873,
-0.3906618059,
-0.0918109342,
-0.3839025795,
-0.0535623431,
-0.1072114259,
-0.2624142766,
0.0031697729,
0.290930301,
0.3045806587,
-0.289727807,
-0.6921526194,
-0.2217159271,
-0.0192994028,
-0.0189993531,
-0.185416624,
-0.041610498,
0.0970652252,
-0.1159363389,
-0.1389610022,
-0.1850245744,
-0.1831262559,
-0.2674398422,
0.1000055745,
0.1397005469,
-0.0625688955,
-0.1067099124,
-0.0872951224,
-0.2687196434,
-0.2576800287,
0.5187570453,
-0.2705382705,
-0.1802951992,
-0.2210891694,
0.05120131,
0.0279265847,
-0.1044700593,
-0.0457026176,
-0.1686641127,
0.0926036611,
-0.1920962334,
0.0524795651,
0.1140598878,
-0.0407961197,
0.130147323,
-0.2018646598,
0.468459934,
0.29498595,
0.649748385,
0.2458695769,
0.1966979206,
-0.0822287723,
0.0473907366,
0.1746476591,
-0.3168677092,
-0.5449874401,
-0.0238275956,
-0.0640596971,
-0.1274025887,
0.2021594346,
0.200698331,
-0.0742500499,
-0.0266869403,
-0.0187760741,
-0.0821258575,
-0.3381737173,
0.029367784,
0.0082301833,
0.3630914688,
0.2704673111,
0.1141907275,
0.1679151207,
-0.1973793805,
-0.2174301296,
0.1545910835,
-0.1114049479,
0.0750370473,
-0.3404785097,
-0.0347122662,
0.0773838162,
0.1322539747,
0.3632851243,
0.1768461466,
-0.0333352238,
-0.2407827675,
0.2072985917,
0.2558761239,
0.8898820877,
-0.1167786345,
0.0002208644,
-0.1231960952,
-0.4077211022,
-0.1574126929,
-0.1203824878,
-0.3704096973,
0.1119104102,
0.3983238041,
0.177566722,
0.0730794147,
0.0624850355,
0.2536645234,
0.106136933,
-0.0940454379,
0.006311364,
-0.0627407879,
-0.1572251469,
0.0236293804,
0.1725474447,
0.2027645111,
0.1258593351,
-0.2606546581,
-0.2145002931,
-0.0752891824,
-0.2263514251,
0.1706210077,
-0.0419949964,
0.2185727954,
-0.0271566603,
0.3429125249,
0.0956925526,
0.0082436381,
-0.0430659764,
0.3652381599,
-0.2093001753,
-0.2671454847,
-0.2659678161,
-0.3531703651,
0.2783985734,
0.3999413848,
-0.1325261891,
0.0873532966,
-0.3518052101,
-0.0089753279,
0.0043186261,
0.2912138999,
0.192680344,
0.1972654611,
0.0034367428,
-0.5801058412,
0.0778690055,
0.1013098657,
-0.3258392811,
0.4656160176,
-0.1362305433,
-0.4698040187,
0.3305202425,
-0.145554468,
0.6788830757,
0.3205861151,
-0.0783482343,
0.4585233331,
-0.2710074186,
0.1379144937,
-0.1251248121,
0.2163402289,
-0.1971991211,
-0.3250998557,
-0.0320497341,
-0.1357449889,
0.1162323803,
-0.0102678509,
-0.0488503873,
0.2440145761,
-0.4482601285,
0.3402754068,
0.1893619299,
-0.0396743752,
0.1212256104,
0.055729799,
-0.2445610315,
0.1250974387,
0.0995022133,
0.1220748723,
0.0188175235,
-0.049687393,
-0.1138104424,
-0.0982230678,
0.0281826276,
0.1832030118,
-0.0955191553,
0.1541767418,
0.1602681875,
-0.4494723976,
0.1329331994,
0.1148507297,
0.1775899529,
0.1654094011,
0.1725304276,
0.1722920537,
0.1799484342,
0.4919588566,
0.2863282561,
-0.2463895828,
0.3764446974,
0.1824581027,
-0.1636626422,
-0.0963948965,
-0.0413798615,
0.001357249,
-0.2913986742,
0.2559871972,
0.1941453815,
-0.5556690097,
0.087429285,
-0.0164848715,
0.3294984102,
-0.3385231793,
0.181612581,
-0.271021992,
-0.1975546777,
0.315919131,
-0.2167320549,
-0.3040759265,
-0.1763251573,
0.0823388696,
0.2306226343,
0.1335443556,
0.2218470871,
0.0387545712,
-0.1856316924,
-0.153018415,
0.1057332829,
0.2960752249,
-0.1180841401,
0.2412986159,
-0.4406548738,
-0.0533877462,
0.0695315376,
-0.07320676,
-0.1157500148,
-0.0602321774,
-0.2475581914,
-0.458258152,
0.2933084071,
0.0473977849,
0.1416836381,
-0.0201328993,
0.0712004527,
0.5275369287,
-0.0519639663,
0.2474910319,
-0.319211334,
0.0537427478,
0.2677709758,
0.3376624584,
-0.1052914858,
0.0080355192,
0.120559305,
-0.104406938,
0.0996455476,
0.0620508268,
-0.0346090049,
-0.2899676561,
-0.1012967452,
0.0620704331,
-0.0626074374,
-0.3614683449,
-0.006385054,
-0.0145879649,
0.0495987386,
-0.0990976542,
0.250780195,
0.1484613717,
0.1583989859,
-0.1946389377,
0.0119038019,
0.0122339847,
0.0658319443,
0.0384792499,
-0.3662517965,
-0.2229629457,
0.1611460298,
0.1351644993,
0.0631969646,
0.0891524181,
-0.1877360642,
-0.2762017548,
-0.2139297724,
0.0860516056,
0.2181613147,
-0.2014153302,
0.0189443324,
0.0990619063,
0.3757978082,
0.326533407,
-0.2475616783,
-0.0139349233,
-0.0011969197,
0.2162851691,
-0.1100640148,
-0.1036873758,
0.389397651,
0.0830361545,
0.0533214733,
0.3443720937,
0.0648372546,
0.1187142059,
-0.0132187735,
0.154502973,
0.2453822941,
0.0314934887,
0.4269294739,
0.7224652767,
-0.0819628984,
0.2144916952,
0.067094937,
-0.2420421839,
-0.1304361373,
0.582569778,
0.0717689171,
0.4792497754,
-0.0588639453,
0.0599080324,
0.1579599231,
-0.3432518244,
-0.2454228252,
0.0359251946,
-0.3622514009,
0.1823870391,
0.1421442032,
0.1695185453,
-0.1999492645,
-0.4124534428,
0.0263128895,
0.0715300739,
-0.1813386679,
0.0405382738,
0.1023155302,
-0.207979098,
-0.0646758378,
0.1185835749,
0.2187936455,
-0.2930907905,
0.3661251664,
-0.1042569429,
-0.2037522942,
-0.2063069046,
-0.1254125684,
-0.0032817165,
0.0824238285,
-0.0887027308,
0.1758403778,
-0.1839080453,
-0.0661492869,
0.2432811111,
-0.1570462435,
0.1438044608,
0.2195668966,
-0.0207440909,
-0.1687161624,
0.1859501749,
-0.1032594666,
-0.0245687999,
0.2409379333,
-0.1947381049,
0.2081596553,
0.1675651968,
0.2051995546,
-0.2016340494,
-0.0612655431,
0.4455607831,
0.2907149196,
-0.742918849,
0.4080229998,
0.0341439955,
0.1255088151,
-0.1328301728,
-0.1486071795,
-0.0895435661,
0.1401088685,
0.3319240808,
-0.1057558283,
0.1773092896,
0.1276812851,
0.0996652246,
0.0881103501,
-0.0107394159,
-0.0139409555,
-0.1484921724,
-0.2792572379,
-0.1069531292,
-0.5106596351,
0.0040862998,
-0.0039006216,
0.0690059885,
0.0379075482,
0.1838707179,
-0.1666197926,
0.1259857118,
-0.1681754142,
-0.1393606216,
0.0664266795,
-0.1356471181,
-0.2854786217,
-0.3284343481,
-0.1911325157,
0.0284430925,
-0.0134180924,
-0.1766479462,
0.1797419041,
-0.1094327345,
0.0960315689,
0.2473549545,
-0.2608381808,
0.0920034796,
-0.0265058987,
-0.2360240221,
0.2704970241,
0.3358160853,
0.033779081,
0.4164491296,
-0.0764170066,
-0.3645360768,
-0.3840859234,
0.3391598463,
-0.2415718138,
0.303917259,
-0.1684405655,
-0.2400926501,
-0.1544158161,
0.1671055257,
0.3222571015,
0.0365158059,
-0.2809253931,
0.0212815143,
-0.1879725307,
0.327111125,
0.1667456031,
0.5572367907,
-0.1839991808,
0.1422242224,
0.0611175373,
-0.4626354575,
0.2963455915,
-0.6073687673,
-0.2499369681,
-0.1409377903,
0.1310240924,
0.4991544187,
-0.3818491101,
-0.3113527894,
-0.3930334449,
0.3461677432,
-0.4192751348,
0.0329637453,
0.1248148605,
0.1201775149,
0.0750872791,
-0.1183611229,
-0.1656182557,
0.301402837,
-0.2145801038,
0.6384904385,
-0.1671471745
] |
https://github.com/huggingface/datasets/issues/3449 | Add `__add__()`, `__iadd__()` and similar to `Dataset` class | I was going through the codebase, and I believe the implementation of __add__() and __iadd__() will be similar to concatenate_datasets() after the elimination of code for arguments other than the list of datasets (info, split, axis).
(Assuming elimination of axis means concatenating over axis 1.) | **Is your feature request related to a problem? Please describe.**
No.
**Describe the solution you'd like**
I would like to be able to concatenate datasets as follows:
```python
>>> dataset["train"] += dataset["validation"]
```
... instead of using `concatenate_datasets()`:
```python
>>> raw_datasets["train"] = concatenate_datasets([raw_datasets["train"], raw_datasets["validation"]])
>>> del raw_datasets["validation"]
```
**Describe alternatives you've considered**
Well, I have considered `concatenate_datasets()` 😀
**Additional context**
N.a.
| 45 | Add `__add__()`, `__iadd__()` and similar to `Dataset` class
**Is your feature request related to a problem? Please describe.**
No.
**Describe the solution you'd like**
I would like to be able to concatenate datasets as follows:
```python
>>> dataset["train"] += dataset["validation"]
```
... instead of using `concatenate_datasets()`:
```python
>>> raw_datasets["train"] = concatenate_datasets([raw_datasets["train"], raw_datasets["validation"]])
>>> del raw_datasets["validation"]
```
**Describe alternatives you've considered**
Well, I have considered `concatenate_datasets()` 😀
**Additional context**
N.a.
I was going through the codebase, and I believe the implementation of __add__() and __iadd__() will be similar to concatenate_datasets() after the elimination of code for arguments other than the list of datasets (info, split, axis).
(Assuming elimination of axis means concatenating over axis 1.) | [
-0.2595470846,
0.0174407102,
-0.1195520759,
-0.0258937329,
0.297565043,
0.4441085458,
0.4135001302,
0.1891679317,
-0.2233495861,
0.1560035944,
-0.1052789316,
0.3455277681,
-0.1738570482,
0.2189385146,
-0.0191160589,
-0.2958265543,
0.0940745622,
0.1944159269,
-0.2048512399,
-0.065221779,
-0.2910801172,
-0.1032394543,
-0.204880476,
-0.1049069837,
-0.3372940719,
0.0320242085,
-0.3964619339,
-0.0228165016,
-0.0235597901,
-0.4783444405,
0.0162487961,
0.281863898,
0.0211479366,
0.1145863757,
-0.0001064326,
-0.1459657699,
0.0214317795,
0.0459091552,
-0.3905855715,
0.0986692682,
-0.4882591665,
-0.3452112079,
0.1621004939,
-0.3436641395,
0.0043024742,
-0.462598443,
-0.0599403493,
-0.1710886806,
0.1158837527,
0.1376538426,
0.2389482409,
-0.1006014869,
0.1687404513,
-0.3601845503,
-0.2358098328,
0.1798997372,
-0.0714271367,
0.0399315953,
0.1272184849,
0.0999915078,
0.2845572531,
0.137563169,
-0.0227373391,
-0.3559103012,
0.2602879107,
0.2197919786,
0.0023155089,
-0.1984967142,
-0.0623919591,
0.1377970874,
0.5021819472,
-0.4305049181,
-0.4552251399,
-0.2267748713,
0.3570366502,
-0.3564399779,
-0.1249914691,
-0.0528211705,
0.0390640348,
0.3308336735,
0.0132599901,
-0.1510406435,
-0.1801246554,
0.3075233996,
0.1479302347,
0.3278825581,
0.316709727,
0.0305330567,
0.1927703619,
-0.1864553541,
0.1302895993,
-0.3030749559,
0.0716374293,
0.2941232026,
-0.2609853446,
-0.2485318929,
-0.0200099573,
-0.302064091,
0.1187976822,
0.1461310089,
-0.0259014033,
0.0931193903,
-0.0991991758,
0.0924041867,
0.0870943069,
0.1135500371,
0.1171285212,
0.1999644935,
-0.1956737787,
-0.0901536644,
0.1077654213,
-0.1143562049,
-0.1203609183,
0.0804943591,
0.3179934919,
0.0622175485,
0.0461500697,
0.2882077992,
-0.0154210636,
-0.0783487558,
-0.1242223755,
-0.195769608,
0.0821543485,
0.2476603687,
0.0126506202,
0.2873687744,
0.0806154832,
0.0664197356,
0.2175949812,
-0.0238046888,
-0.1431885362,
0.2489820868,
-0.0514824092,
0.0256058928,
0.0884789377,
-0.1370185316,
-0.0401638895,
0.2343640924,
0.2128248364,
0.1655545682,
0.0863459706,
-0.1049877852,
0.3274389505,
-0.0708496571,
-0.182250917,
-0.2478383631,
-0.0434376039,
-0.2334575355,
-0.1174748987,
0.1437436193,
-0.0900425687,
-0.2977752388,
-0.3816037476,
0.3086343408,
0.0085587734,
-0.0770434812,
0.0800647661,
0.320828408,
-0.0361230299,
-0.1532810926,
-0.0161734279,
-0.0387382917,
0.2272023708,
-0.177687481,
0.2414103895,
0.3017529845,
-0.2696483433,
-0.1631048024,
-0.1870982349,
-0.1138330176,
0.001371335,
0.0511680804,
-0.3414820731,
0.2404452115,
-0.259855479,
0.1235633343,
0.6342797875,
-0.4105705321,
-0.0774586499,
-0.1083782613,
0.0498291291,
0.2510839403,
0.2692238986,
0.2428606451,
0.1280425936,
0.0564050376,
0.5487986803,
0.0091145746,
-0.06608814,
-0.3532036841,
-0.0344154425,
-0.1252347529,
0.2653495073,
0.0905914903,
-0.0344844088,
0.227406472,
0.0365350842,
-0.2643186748,
0.4115909636,
-0.460328877,
-0.0633025542,
-0.0448083654,
0.2832429409,
-0.1797128171,
-0.1395962387,
-0.3004189432,
-0.38369748,
0.0211356431,
0.1063432992,
0.1154493466,
0.1375420392,
-0.4216379821,
-0.0343877077,
0.1350983679,
-0.1927196681,
-0.034220662,
0.2293696105,
-0.0604496822,
0.0532009229,
-0.3321824074,
-0.3627726734,
0.4948564172,
-0.2531909049,
0.0776117444,
-0.018215511,
0.0577072836,
0.1038969606,
0.1035042778,
-0.2378664911,
0.3036178052,
0.0029527077,
-0.0260488875,
0.0090544848,
0.2687129676,
-0.1234982312,
-0.2876235843,
0.1439639032,
0.3037221432,
0.1403285861,
0.1625834703,
-0.0676723197,
-0.28671363,
0.1585084647,
-0.120035395,
-0.0660987794,
0.2533479035,
0.2065896541,
0.227205202,
0.1385450214,
0.1820484251,
0.2871908844,
-0.1389206499,
-0.2498132885,
-0.4372167289,
-0.04874954,
0.1636432707,
0.1203076541,
0.2665177584,
-0.3791875243,
0.0753270462,
0.5721164346,
-0.0962549895,
0.1265953481,
0.034369953,
-0.1833012104,
0.2206387073,
-0.0368988216,
0.1234716326,
0.6229577065,
0.2844319642,
-0.0629393533,
0.2930696905,
0.0768877938,
-0.0499126203,
0.2500047684,
0.1103069186,
0.1023184434,
0.0187279209,
0.2379679084,
0.0872466713,
0.0056169685,
-0.3952101469,
0.0734239593,
-0.0100746648,
-0.122352466,
-0.0422326028,
-0.1173972711,
-0.0262960121,
-0.1066768542,
-0.157255128,
-0.0746128336,
-0.2773827016,
0.0066975164,
-0.1124107093,
-0.2860073745,
0.1339143217,
-0.2089542747,
0.359420687,
-0.169114396,
-0.3589507937,
0.0971406102,
0.0931264237,
0.0098800687,
0.1744167954,
0.0070224283,
-0.1525987536,
0.4334676266,
-0.0355834551,
0.121601969,
-0.044645194,
-0.3801866472,
0.013673448,
0.0945758075,
0.0386207066,
0.223331213,
-0.1238018572,
0.0659617633,
-0.6741278768,
0.0712692812,
0.3070907891,
0.0575162321,
-0.1900818646,
0.17435579,
-0.2124805152,
-0.1812719405,
-0.5040621161,
-0.4765720367,
-0.4218770266,
0.2393353283,
-0.1172712892,
0.1262841076,
0.0730646029,
0.0578220338,
0.1897959113,
0.0791502222,
0.1497886628,
-0.1872174442,
-0.0774411038,
0.3482378721,
-0.2758318484,
-0.0440898165,
-0.1635347903,
-0.521045506,
0.3038811982,
0.1452833116,
-0.0172893871,
-0.4382302165,
-0.1404102892,
0.332352519,
-0.3144204021,
0.0667771921,
0.1856165975,
0.4337627292,
-0.1692805439,
-0.0284737796,
-0.0664867312,
0.1687267125,
0.0465638079,
0.0033107121,
-0.0176553223,
0.1107647493,
-0.077448152,
0.4660401046,
0.1832099706,
-0.2601552606,
0.0944430605,
-0.016575722,
0.3457302451,
-0.1759647578,
-0.5632662773,
-0.1874114573,
-0.0321852565,
0.0910631344,
-0.0866417736,
-0.2337075472,
-0.1390871853,
-0.0307547096,
0.3443626165,
-0.0696636811,
-0.1456758529,
0.2993459404,
-0.195308581,
0.4029931128,
-0.0261543207,
0.0508536585,
-0.3432684839,
0.2256255597,
-0.0579304472,
0.2312103361,
-0.0247318707,
-0.4017776251,
-0.4452370107,
-0.1799709797,
-0.3292656243,
0.2740229964,
0.3465708196,
0.1181285083,
-0.0325667448,
-0.1171728149,
-0.1616586,
0.1258088797,
0.5187420845,
-0.1638930142,
-0.6845868826,
0.406466037,
-0.0182852615,
-0.0411235392,
-0.0169872604,
-0.0913711265,
0.1247835681,
0.3461965621,
0.3236803114,
-0.3219267428,
-0.2611536384,
0.559989512,
0.1863019466,
-0.0706895068,
-0.2341450453,
0.2747513056,
0.0842288136,
-0.3102548718,
-0.1559834629,
0.1629478633,
0.3695203066,
-0.0629049242,
-0.171205163,
-0.2117679417,
-0.098341465,
0.3105266094,
-0.0158962104,
0.249583602,
0.3645302653,
0.2038111538,
-0.1972594857,
-0.1095546111,
0.233129248,
0.456304878,
-0.28634426,
-0.6952151656,
-0.2259897292,
-0.1698008031,
0.7050462961,
0.1048630476,
-0.030703688,
0.3222739398,
-0.0854284316,
0.03966932,
-0.4413328767,
0.3890387416,
0.2593726516,
-0.0166762732,
-0.5025876164,
-0.642195642,
0.1537920386,
0.2399486452,
-0.1691120714,
0.3634848595,
-0.2169067264,
-0.4939745069,
0.0391052216,
0.0921965912,
0.9021914005,
0.2281241864,
0.287166208,
-0.0040690056,
-0.016406225,
0.215821296,
-0.0097077657,
0.1939513236,
-0.1499227732,
-0.2681198418,
0.0023970825,
-0.1277056634,
0.2044018209,
0.1068203375,
-0.1981129497,
0.1371082664,
-0.3347036242,
0.2412646711,
0.1582817286,
0.4771815836,
-0.0822211429,
-0.3789587021,
-0.1724762022,
0.1544243097,
0.1863531023,
-0.5341023803,
-0.2676879466,
-0.3343814313,
-0.0320593715,
0.0193860549,
-0.1935744435,
0.0253596678,
-0.1481703371,
0.2943678796,
-0.0371489301,
-0.1217511669,
0.259218663,
0.0253916178,
0.1381429583,
0.2999907136,
0.1676438302,
-0.024966266,
-0.1848131865,
0.2654363513,
-0.1944848448,
-0.2135374397,
0.4752114117,
0.1218570471,
-0.041653432,
0.356490314,
-0.0252206177,
-0.45394665,
-0.2588846982,
0.1098904163,
0.2130346149,
-0.5147147179,
-0.0280036032,
0.2781355679,
-0.1147655025,
-0.1861646324,
0.1748690903,
0.1948998123,
-0.2818333805,
0.2012242973,
0.032330092,
-0.0804227218,
-0.0249589607,
-0.0529504679,
0.3244483769,
-0.193059817,
0.4715483785,
-0.240252018,
0.0215510707,
-0.2268905491,
-0.1238828003,
0.2637284398,
0.0172519479,
0.1452673376,
0.1580480784,
-0.1542966217,
-0.120239988,
-0.0854612663,
0.0477429219,
0.3253932297,
-0.2750528157,
-0.0710989162,
-0.541780591,
0.0480765253,
0.1419150829,
0.4130959511,
-0.0825018063,
0.3049737811,
-0.1801318526,
0.0322133377,
-0.4143408537,
-0.2589414418,
-0.1257980764,
0.1248161122,
0.2135836035,
-0.0851502419,
0.0962432995,
0.1512522995,
0.2577461898,
-0.0037482334,
-0.0818664506,
-0.3134922981,
-0.1682060361,
0.1018282548,
0.063025862,
-0.001619741,
-0.0700746402,
0.0483133011,
-0.0637510195,
-0.3424263299,
0.0709681809,
-0.0984801278,
-0.0763774961,
0.29093045,
0.0628265738,
0.0650991574,
0.0613675155,
0.0075293202,
0.168587327,
0.0984382033,
0.1180113032,
0.1846036613,
-0.2401783615,
-0.0677811727,
0.1327408254,
0.1342411637,
0.1687290967,
-0.008284024,
0.1348429024,
0.064599961,
-0.1182973757,
0.2594931722,
0.0663972199,
0.2460865229,
-0.180098474,
0.1518107653,
0.0491861366,
0.2829866707,
-0.3101415932,
-0.2895262837,
0.2093143314,
0.0362057388,
0.2010695487,
0.128957808,
0.0420074426,
0.0796489716,
-0.0872272402,
-0.1022489294,
-0.0564227141,
-0.0766571611,
0.5472677946,
0.3530134857,
0.127914086,
-0.0407283343,
0.0217517857,
0.14608109,
0.1917551011,
0.1677992791,
-0.24785164,
0.3706202209,
0.1453266889,
-0.1064782143,
0.3666237295,
-0.0075538838,
0.1573437601,
0.0916406065,
0.0474478118,
0.3087611198,
0.1965233386,
-0.077143237,
0.0623717755,
-0.29101336,
-0.0031083052,
0.1247734055,
-0.1837055385,
0.0964779109,
0.3379849195,
-0.0413172431,
-0.0824350715,
-0.0756014138,
0.1678179801,
-0.2911868989,
0.4747575819,
-0.1563875079,
0.1406046748,
-0.0136858672,
0.4961175621,
0.3433204591,
0.3930061758,
-0.2804223001,
-0.3549798429,
0.4022843838,
-0.0146749383,
-0.0661556125,
0.3200830221,
0.3652683496,
0.2476987988,
0.2820957005,
0.1263364404,
-0.2436189204,
-0.0282405391,
-0.0604134761,
-0.038322825,
0.2624738812,
-0.0098620374,
0.1926542819,
0.2215897888,
-0.1571585238,
0.0617784373,
-0.0228736289,
0.0222029984,
-0.7255237699,
0.3736325204,
0.4239483774,
-0.2555250227,
-0.0379921198,
0.0800239891,
-0.2676095068,
-0.4901951253,
0.6436259151,
-0.07752648,
-0.0038077845,
-0.0607047901,
0.1170139164,
0.160444051,
0.2595974505,
0.1295846403,
0.1526567787,
-0.3718707561,
0.0096284887,
-0.2849203348,
-0.1750084609,
0.2193703651,
0.1562253833,
0.0244460683,
0.0210308265,
0.0440880954,
-0.0489462279,
0.1638645679,
-0.2421010435,
0.0345734507,
-0.1421406269,
-0.5322028995,
-0.0409623161,
0.2346290648,
-0.0509700328,
0.2804233134,
-0.023890052,
0.0764628947,
-0.1387193948,
0.1006491184,
0.0770841688,
-0.0174880158,
0.2796103656,
-0.0192159154,
0.3892125785,
0.2587926984,
0.3141514063,
-0.1644347012,
0.0662189797,
0.1471453011,
-0.227018252,
-0.1368875653,
0.5479970574,
0.019381132,
0.0831221044,
-0.3065361381,
-0.1302948594,
0.1062865853,
-0.0540994667,
0.2015714198,
-0.2257321179,
-0.2572327852,
0.2274731994,
0.0289911795,
-0.0552886873,
0.044711981,
0.3239305615,
-0.0843964592,
0.1224179715,
0.1104948521,
-0.2612310648,
0.1871456057,
0.0937756523,
-0.304789871,
-0.1464074403,
0.0895984843,
0.1042395905,
0.1969120055,
-0.560312748,
-0.3981598914,
0.4883899987,
-0.1599409878,
-0.0847889036,
0.4397689402,
0.1182136089,
-0.0581444465,
-0.157445088,
-0.0266887285,
-0.1839084625,
-0.2181929648,
-0.0005273542,
-0.3772294521
] |
https://github.com/huggingface/datasets/issues/3448 | JSONDecodeError with HuggingFace dataset viewer | Hi ! I think the issue comes from the dataset_infos.json file: it has the "flat" field twice.
Can you try deleting this file and regenerating it please ? | ## Dataset viewer issue for 'pubmed_neg'
**Link:** https://huggingface.co/datasets/IGESML/pubmed_neg
I am getting the error:
Status code: 400
Exception: JSONDecodeError
Message: Expecting property name enclosed in double quotes: line 61 column 2 (char 1202)
I have checked all files - I am not using single quotes anywhere. Not sure what is causing this issue.
Am I the one who added this dataset ? Yes
| 28 | JSONDecodeError with HuggingFace dataset viewer
## Dataset viewer issue for 'pubmed_neg'
**Link:** https://huggingface.co/datasets/IGESML/pubmed_neg
I am getting the error:
Status code: 400
Exception: JSONDecodeError
Message: Expecting property name enclosed in double quotes: line 61 column 2 (char 1202)
I have checked all files - I am not using single quotes anywhere. Not sure what is causing this issue.
Am I the one who added this dataset ? Yes
Hi ! I think the issue comes from the dataset_infos.json file: it has the "flat" field twice.
Can you try deleting this file and regenerating it please ? | [
0.2295418084,
-0.1201282293,
0.0490055047,
0.2303445041,
0.1695690006,
0.0577233173,
0.0852913558,
0.1623660028,
-0.0017490645,
0.0962924287,
0.1668467969,
0.2956420183,
-0.1245155856,
0.0679474473,
-0.1284822077,
-0.257044971,
0.1415823102,
0.2197294384,
0.1280412525,
-0.077343747,
-0.1991614252,
0.5407518148,
-0.1372192651,
0.1925834864,
-0.0773462206,
-0.1646023989,
0.1248666942,
0.0503622405,
-0.2352316678,
-0.6108032465,
0.1825273484,
0.0068036118,
0.0243878439,
0.5318033099,
-0.000124313,
0.0471874289,
0.3346125484,
-0.0701061636,
-0.2907135487,
-0.3544469178,
-0.2027761787,
-0.0309148189,
0.3325050175,
-0.1822505891,
-0.0991285294,
-0.3767586648,
-0.1806702912,
-0.4984890223,
0.5452631712,
0.0639695674,
0.0923633575,
-0.0461195558,
0.1396580637,
-0.0715849847,
-0.0621321127,
0.39025262,
-0.0133275772,
0.2967044413,
0.2882288992,
0.5704967976,
0.108062081,
0.4412469566,
-0.0178404953,
0.1737413257,
0.1619184613,
0.1689563543,
-0.1997098476,
-0.1587148309,
0.3424787223,
0.2488838136,
0.5452134013,
-0.2241824716,
-0.2792276144,
-0.2669476569,
0.0643336251,
0.0024405927,
0.3452029824,
0.0083258497,
-0.0145489518,
0.1722724438,
-0.3152351677,
-0.3719948232,
-0.1623045951,
-0.1056016833,
-0.0734338909,
-0.072703056,
-0.2976114452,
0.2091562301,
0.0891277641,
-0.2091567069,
-0.1303324848,
-0.1438709497,
-0.3724159896,
0.1404169053,
0.105225876,
-0.1883954704,
-0.2302413285,
-0.1910566539,
0.3178774416,
0.1374253333,
-0.0221342985,
-0.0583723895,
-0.0210297573,
0.0997098759,
0.2559548914,
0.0002930644,
0.252241075,
0.0216257274,
0.215324536,
0.2025235295,
0.1685303003,
-0.1484932601,
0.0064701848,
0.0565134771,
-0.2069925815,
-0.4021454453,
0.5043196678,
-0.2971713543,
-0.322663933,
0.2807434499,
-0.1377951056,
-0.2078128755,
-0.1317893714,
0.1296415925,
0.2502056062,
-0.0802325234,
0.1082563326,
0.1659632623,
0.0875333995,
-0.4068311751,
-0.0254013427,
-0.0262039248,
0.1853226721,
0.1277041733,
-0.0351236835,
-0.244019419,
0.2320867777,
0.0083874669,
-0.0301686414,
-0.195508346,
-0.1086890176,
0.0756639242,
-0.1501651108,
0.1510699242,
0.0881980658,
0.2398091555,
0.0988890082,
-0.6970397234,
0.035330072,
-0.085977599,
-0.2810894251,
0.0409674272,
-0.7361626029,
-0.0163425915,
-0.4227284193,
-0.1399767548,
-0.3953574598,
0.1251384467,
0.0999380052,
-0.1930176467,
-0.0031422006,
0.3656953871,
0.030734228,
-0.0423297249,
0.2172963023,
0.4921431243,
-0.3275251687,
-0.205138281,
0.0404642597,
-0.1297541708,
-0.0918975696,
0.3010300994,
-0.1225110814,
0.2531976402,
-0.1277522892,
0.2245862633,
0.2611702979,
-0.3775947094,
-0.3580394685,
0.5831648707,
-0.3189088702,
0.1684471667,
0.1616860926,
-0.2265278995,
0.0802992657,
0.1343963146,
0.1131758094,
-0.1584894955,
0.0598535985,
-0.0979637429,
-0.1174647436,
-0.2006271183,
0.327208519,
0.0305778384,
-0.2070438415,
0.028800115,
0.1961560398,
0.0922542512,
0.3440178335,
-0.1299547702,
0.1904045939,
0.4240055084,
0.2430157214,
0.0928818956,
0.0623511337,
-0.156949386,
-0.3644614816,
-0.0922744572,
-0.0718804002,
0.0066992068,
-0.5873866081,
0.0104598207,
-0.1725000441,
-0.0020522231,
-0.446891129,
-0.2488487661,
-0.0015927608,
0.2237250209,
-0.0027162563,
0.3182990551,
-0.2253235281,
0.2082751989,
0.1188771799,
0.226512149,
-0.6014869213,
0.1080587208,
0.020124767,
-0.1411704421,
-0.072162956,
0.0549028777,
0.1241339147,
-0.1473491639,
-0.1096349061,
0.2997169495,
-0.0551039502,
0.1626177728,
0.3453702629,
-0.2165055722,
0.1825623959,
-0.1181681231,
-0.0140546151,
0.0508091077,
0.2017799914,
-0.0062842355,
-0.2202068418,
0.2319241911,
-0.0150048593,
0.1570712775,
-0.2471930087,
0.1603633612,
0.2884010673,
0.0039754836,
-0.1542056948,
-0.3582911789,
0.1974275708,
-0.0393347852,
0.0235706009,
-0.0899545997,
-0.2563652694,
-0.1705639064,
0.4985341132,
-0.0941684246,
0.0101864496,
0.1693348289,
-0.2732705474,
0.2383763492,
0.034693677,
0.4629466534,
0.4355127513,
0.1239126921,
-0.3527147174,
0.1744801998,
0.2548744678,
0.0004830583,
0.1870090663,
0.1449760646,
0.1398271173,
0.0091770943,
0.0285164341,
0.1515179574,
-0.2448883057,
-0.1957328469,
0.1217238978,
0.2097320855,
-0.4421114624,
-0.0256041214,
-0.4401097894,
-0.2000641376,
-0.1665917784,
0.197072491,
-0.2758947611,
-0.1708985269,
-0.1555637568,
0.0371117368,
-0.0398119874,
0.0619012006,
-0.1538420022,
0.1874179542,
-0.059962064,
0.0014248827,
-0.1998270303,
-0.0503047407,
-0.2853176594,
-0.0683409348,
0.0891920701,
-0.1387416273,
0.229425922,
-0.1810250282,
0.1941751987,
-0.3740409017,
-0.3094111383,
0.2482060492,
-0.3803492188,
0.3117530942,
0.1076399162,
0.327893734,
-0.0475667045,
-0.1454926282,
0.2850397825,
0.2129234672,
-0.2250967771,
0.0322138295,
0.1010826677,
-0.2061996162,
-0.1429094672,
-0.026466446,
-0.0592398904,
-0.0138070667,
0.4695780277,
-0.1580190361,
-0.0514835343,
0.0173543245,
-0.1464054585,
0.2308705896,
-0.3388152421,
0.1905447841,
-0.1678788215,
-0.4876130521,
0.4006467462,
-0.2197315991,
-0.2718029618,
0.1303026229,
0.2467714101,
0.0519672744,
-0.5086180568,
-0.4440146387,
-0.1026448682,
-0.1463534385,
-0.0265284348,
-0.0213406961,
-0.0924289301,
0.154589653,
0.2491445094,
0.0165533982,
-0.1715129316,
-0.268009305,
0.2756875455,
-0.1611708403,
0.3910311162,
0.2023319602,
0.4182278514,
0.0617463514,
-0.0747499391,
0.7103187442,
-0.0398210846,
0.3504879177,
-0.2346099466,
0.2757659554,
0.1269504577,
-0.3707773089,
-0.1381985694,
0.026597973,
0.2619149387,
0.2607761323,
-0.0878790691,
0.2688651383,
-0.1372312903,
-0.3746501505,
-0.2769081891,
-0.2129932195,
-0.2565303147,
-0.206208542,
-0.1348799616,
-0.0177649818,
0.0947396234,
0.0826018825,
-0.0320895091,
-0.1185569614,
0.224207297,
0.0798896998,
0.0560155064,
-0.1814266145,
-0.0653395727,
-0.1821721941,
0.4914548695,
-0.105581224,
0.1159373894,
-0.2330348045,
0.3867319226,
0.223767519,
-0.0231041368,
0.6122581363,
-0.0269394126,
-0.1922249496,
-0.1981427222,
-0.1209099218,
-0.2389710397,
0.0419305265,
-0.053517241,
0.4765599966,
0.0359844789,
0.4000053406,
-0.3207003772,
-0.1662390977,
0.4404127002,
-0.1312661618,
-0.1998459697,
-0.3786299825,
-0.1111235172,
-0.5625745058,
-0.3428520262,
-0.2392134368,
0.1032639444,
0.3623338342,
0.2833314836,
-0.1237803698,
0.2586138546,
-0.0346663408,
0.1843714714,
0.0464883037,
0.2094643265,
0.0638555214,
0.1495448947,
0.4568074048,
0.5483312607,
0.3827325404,
0.5919120908,
0.2190171778,
-0.3396248817,
-0.015495657,
-0.2665840685,
0.3541140258,
0.3382225037,
-0.0567970611,
0.3824742734,
0.4476425648,
0.2395471781,
-0.0481039211,
-0.2705909312,
0.6338372827,
-0.1261602342,
-0.2678438127,
-0.129886359,
0.662545681,
0.0063407533,
0.0487768017,
0.0627763569,
0.7981144786,
-0.3823058903,
-0.0140577825,
-0.0054088095,
0.9053082466,
0.206673637,
-0.043662414,
0.1939495057,
-0.4085060954,
0.7087865472,
-0.0675440878,
-0.1255097091,
-0.0580878593,
-0.1071302295,
-0.1879161596,
-0.0135248359,
0.6936959624,
-0.0815913454,
-0.4362000227,
0.0960247517,
-0.0963587612,
-0.0188883245,
0.03476955,
0.3258745968,
-0.1810542941,
-0.0579250455,
-0.1519226581,
-0.0190971941,
-0.2652633488,
0.0870664343,
0.1637327522,
-0.5067907572,
-0.2360290736,
-0.4161909819,
-0.5135124922,
-0.111781776,
0.0459534563,
0.1015625894,
0.38620013,
-0.1598164439,
0.4605421126,
0.2396497726,
0.3381340802,
0.0516835935,
-0.414313674,
0.3856038749,
-0.0521284416,
-0.0339930132,
-0.1622264534,
0.1996897608,
0.1137519628,
-0.0954502374,
-0.3290660381,
-0.0069514858,
-0.108280234,
-0.1599625051,
-0.2061291039,
0.0103761097,
-0.4906304777,
-0.4229438305,
-0.0455280729,
-0.0449477956,
0.225161314,
-0.2141593248,
-0.0053672465,
0.213068217,
-0.2017499804,
-0.059118703,
0.2627776563,
-0.2921135426,
-0.0604064874,
0.2684642076,
0.0421445481,
-0.1926213205,
0.6752769947,
0.0651646778,
-0.0906303003,
-0.0114942761,
0.3043268323,
0.5340693593,
-0.3650411963,
0.1264675111,
0.1118922681,
0.163077116,
-0.1475607902,
0.3394631445,
0.1092485413,
-0.0505668931,
0.0801887512,
-0.1800007224,
-0.2339003682,
0.1882319152,
-0.2047943771,
0.1468100697,
0.1400103569,
0.1095770225,
0.0449830852,
-0.1455420256,
-0.1618840247,
-0.0044114846,
-0.2096531242,
-0.0753383487,
0.3618504405,
0.0817534328,
0.2641284168,
-0.0496666618,
0.0475901924,
0.2951945662,
0.0566551052,
0.0147482371,
-0.0640629306,
0.1931368411,
0.0236905683,
-0.105554454,
-0.2446368188,
-0.0281391647,
-0.1153863668,
-0.0010663449,
-0.0463426486,
0.0538203791,
0.1517961621,
0.1676615775,
-0.2061073035,
-0.2655585408,
0.0276104361,
-0.0707820803,
-0.1014360934,
0.5551561117,
0.015604754,
0.1241131425,
-0.0820323825,
0.0014890125,
-0.1608718932,
0.1894377321,
0.0673243478,
0.0396484956,
0.2714738548,
-0.6175538301,
0.0601069704,
0.1932881325,
0.2710090876,
0.2348518819,
-0.6114370823,
-0.079557538,
0.0978367329,
-0.0325661711,
-0.128106907,
-0.1080927774,
0.3963139355,
0.0653608516,
-0.2319709808,
0.2500227094,
-0.0533722937,
0.0614506416,
-0.120466806,
0.0120124677,
0.7670584321,
0.0420517176,
0.094213888,
0.092506282,
-0.1925982535,
-0.0670575872,
0.0247060563,
0.6103841066,
0.1069934517,
0.4419882298,
-0.3004558384,
-0.0573594682,
-0.2164461017,
0.2513775826,
0.0447480083,
-0.1965063363,
0.2959111929,
0.1750768572,
-0.0864345878,
0.0859519839,
0.2449840009,
0.2466249764,
-0.0712462589,
-0.1079355404,
-0.3276787996,
0.3814947307,
-0.0776159242,
-0.0510692559,
-0.0209040008,
-0.0555303432,
-0.2262202352,
0.0268429667,
-0.0056482446,
-0.1236807182,
0.0230407361,
-0.0240735766,
-0.206259951,
-0.4978781939,
0.0209883861,
0.0226250626,
0.1778875589,
-0.3796525002,
0.3566878438,
0.5526350737,
-0.2140754759,
0.3183519542,
0.3410280943,
0.4458884299,
0.2452947795,
0.1100698858,
0.0474294983,
-0.2947312295,
-0.2163445204,
0.3956011534,
0.1900389045,
0.1373299509,
0.1173026413,
0.3539389074,
-0.0067037707,
0.0516026169,
0.1160619035,
0.2121736407,
0.5646777749,
-0.1849998534,
0.0584815517,
-0.4745895565,
0.0756192878,
-0.2387663722,
-0.3974596262,
-0.653255105,
-0.1548597068,
-0.0049014445,
-0.036180798,
-0.0249191374,
-0.177940309,
-0.013769595,
0.1194856837,
0.3948096037,
0.295278728,
0.1650282592,
0.0085866489,
-0.2721437812,
-0.2798648477,
-0.0443382002,
-0.0192281697,
-0.0722409785,
0.0595457591,
-0.0246355291,
0.0408495739,
0.0244060308,
0.2511589825,
0.1795523912,
-0.3474934399,
0.0074421195,
-0.2263581455,
-0.1820809245,
0.3554254174,
0.0228757504,
0.0749512911,
0.3802931607,
0.3871899843,
-0.1086277887,
-0.0761385858,
-0.2208633721,
0.3098997474,
-0.4239133298,
-0.4233884811,
0.160015434,
0.3338053823,
0.3798539042,
0.0255208742,
-0.1441792995,
-0.0141668003,
-0.0737596974,
-0.2673201263,
0.5033922195,
0.3719110489,
0.4132606089,
-0.1407330781,
-0.1387498379,
-0.2461726665,
0.0885421187,
-0.3240983784,
0.1006184369,
-0.3695479631,
0.089988865,
0.0061624027,
-0.0295174103,
0.0888923481,
-0.1360697895,
-0.002717966,
0.3850752711,
-0.1769923568,
-0.2127286941,
0.6720061302,
-0.4060389996,
-0.1581735611,
0.4096771479,
0.1077449322,
0.1813844889,
-0.4040646255,
-0.709317863,
0.0302952752,
0.3436852694,
-0.0178779401,
-0.2780787051,
0.1312031895,
0.0166616533,
-0.2452157885,
0.1079051793,
0.4096065462,
0.0937564597,
-0.0988190249,
0.2637469172,
0.0388045609
] |
https://github.com/huggingface/datasets/issues/3448 | JSONDecodeError with HuggingFace dataset viewer | Thanks! That fixed that, but now I am getting:
Server Error
Status code: 400
Exception: KeyError
Message: 'feature'
I checked the dataset_infos.json and pubmed_neg.py script, I don't use 'feature' anywhere as a key. Is the dataset viewer expecting that I do? | ## Dataset viewer issue for 'pubmed_neg'
**Link:** https://huggingface.co/datasets/IGESML/pubmed_neg
I am getting the error:
Status code: 400
Exception: JSONDecodeError
Message: Expecting property name enclosed in double quotes: line 61 column 2 (char 1202)
I have checked all files - I am not using single quotes anywhere. Not sure what is causing this issue.
Am I the one who added this dataset ? Yes
| 41 | JSONDecodeError with HuggingFace dataset viewer
## Dataset viewer issue for 'pubmed_neg'
**Link:** https://huggingface.co/datasets/IGESML/pubmed_neg
I am getting the error:
Status code: 400
Exception: JSONDecodeError
Message: Expecting property name enclosed in double quotes: line 61 column 2 (char 1202)
I have checked all files - I am not using single quotes anywhere. Not sure what is causing this issue.
Am I the one who added this dataset ? Yes
Thanks! That fixed that, but now I am getting:
Server Error
Status code: 400
Exception: KeyError
Message: 'feature'
I checked the dataset_infos.json and pubmed_neg.py script, I don't use 'feature' anywhere as a key. Is the dataset viewer expecting that I do? | [
0.3349670172,
-0.1692841202,
0.0579741821,
0.1783903539,
0.1159864739,
0.0022668086,
0.165877685,
0.0293862037,
-0.0354914218,
0.0884651765,
0.2415665239,
0.2807991207,
-0.1743422896,
0.1949502826,
-0.0547123365,
-0.1336168945,
0.1672874391,
0.280290097,
0.1399284005,
-0.0962148383,
-0.3200155497,
0.4835500121,
-0.1113527864,
0.2538946867,
-0.1230856776,
-0.0757379979,
0.070395276,
0.0585576296,
-0.1995701343,
-0.7043629885,
0.1773025692,
-0.0072668362,
-0.0351408906,
0.4634977877,
-0.0001290876,
0.0687240288,
0.3097592592,
-0.1144310161,
-0.2780866921,
-0.3072424531,
-0.166217491,
-0.1538920999,
0.3584642112,
-0.2714163065,
-0.0792954192,
-0.4530892372,
-0.1439638585,
-0.2645532787,
0.4040035009,
0.1243401021,
0.0578722209,
0.0514811128,
0.1682053804,
0.0169093385,
-0.0030945004,
0.4283492565,
-0.0812473744,
0.1662642509,
0.2754844725,
0.4196506441,
0.0199615955,
0.3997253478,
0.0405172221,
0.1109439805,
0.4023475349,
0.1284208894,
-0.2308473587,
-0.3225634098,
0.2879580259,
0.2035840154,
0.6325817704,
-0.1054759547,
-0.3470057249,
-0.2554841936,
-0.0125984112,
-0.0197242815,
0.3616762757,
-0.0729535818,
-0.0287488941,
0.1142562479,
-0.3089893758,
-0.3980188072,
-0.1286629885,
-0.1236188933,
-0.1246645302,
0.0069031175,
-0.2426866442,
0.2447191924,
-0.0167257059,
-0.2082816809,
-0.2184599042,
-0.1835669726,
-0.3062981367,
0.0961385071,
0.126348421,
-0.1399058998,
-0.0396154374,
-0.0413486287,
0.2724003494,
0.2609727085,
-0.1559864581,
-0.0331040174,
-0.1381055117,
0.0119645866,
0.2366567701,
0.078293182,
0.2441240251,
0.0388287902,
0.278298378,
0.1848610193,
0.1210517064,
-0.1172657609,
0.0966966674,
0.1035451442,
-0.0511794388,
-0.3851378262,
0.6089187264,
-0.2565052509,
-0.1650776416,
0.2584141493,
-0.0248462856,
-0.2358986735,
-0.2105110437,
0.2018019706,
0.2602516115,
-0.0967717022,
-0.0104962364,
0.234632358,
0.0030645202,
-0.3710449338,
-0.0109619191,
-0.0362292416,
0.2046204358,
0.0623646453,
-0.0496474504,
-0.2730513215,
0.2131709456,
-0.1220350191,
0.0371998399,
-0.2478586137,
-0.1643042415,
0.0415504165,
-0.1394084245,
0.1597965658,
0.0278206486,
0.2956233323,
0.1879888624,
-0.6802116632,
0.0230048131,
-0.0734946802,
-0.2283001691,
-0.1025699675,
-0.5639523864,
-0.06081938,
-0.5605066419,
-0.1886563748,
-0.392043829,
0.0593174659,
0.081233412,
-0.1287500262,
0.0182899069,
0.2890234888,
-0.0394311287,
-0.1684204787,
0.2044117451,
0.6462894082,
-0.3311196864,
-0.2533488572,
0.0695174411,
-0.0825594962,
-0.1533649564,
0.2355883121,
-0.1371327937,
0.2637926042,
-0.1116505712,
0.1958499253,
0.3081727028,
-0.3805351853,
-0.4767791331,
0.5036284328,
-0.3513452113,
0.2147819847,
0.2225227058,
-0.1615454704,
0.1954507679,
0.1268360615,
0.0390137099,
-0.2238816321,
0.0654439703,
-0.0873475,
-0.1069706827,
-0.2826243639,
0.4202959836,
0.0063174954,
-0.0479511134,
0.1142773032,
0.1569794714,
-0.0610954911,
0.3008698821,
-0.1378505975,
0.1971646994,
0.3449249566,
0.2918771803,
0.1919661164,
0.1857846081,
-0.0488331653,
-0.2832796276,
0.0313592628,
0.083061032,
0.0926781669,
-0.7186772227,
-0.0113366107,
-0.1608981341,
0.0133999549,
-0.5100704432,
-0.2663249373,
-0.0512594059,
0.2040728629,
-0.0340172835,
0.3180087805,
-0.2896166742,
0.1976922452,
0.2598672807,
0.2952732146,
-0.5851888657,
0.0498290323,
-0.0761260614,
-0.118891269,
-0.1132950112,
0.0855458677,
0.1669544727,
-0.1262005717,
-0.1453747898,
0.2251474857,
-0.0028870779,
0.1757926047,
0.3177250922,
-0.2263647169,
0.226129353,
-0.2070199102,
0.0943894237,
0.1115804687,
0.2308667004,
-0.0225613434,
-0.111733675,
0.2900493741,
0.054262355,
0.263119489,
-0.2631472945,
0.2149174511,
0.1809909791,
0.0867471695,
-0.1674719602,
-0.2828969955,
0.1766401678,
-0.1838666648,
-0.0252182353,
-0.1010046601,
-0.2193673104,
-0.1348598748,
0.5794929266,
-0.0922638103,
0.068900913,
0.1674261689,
-0.3074681163,
0.1980747879,
0.1228731051,
0.3350047171,
0.4535337985,
0.0840269104,
-0.3719691932,
0.1350114346,
0.2665398717,
0.0463369004,
0.1618737578,
0.2451468259,
-0.0212059878,
-0.0629022792,
0.0009344826,
0.1120325848,
-0.1706874669,
-0.163430959,
0.0624067672,
0.1588701159,
-0.4913250804,
0.0203471538,
-0.4321138561,
-0.2673591375,
-0.0064396486,
0.2229285985,
-0.2938955724,
-0.2348916084,
-0.1914517879,
-0.0411682054,
0.0865859911,
0.0116411597,
-0.3322995603,
0.0579643846,
-0.1234924197,
-0.0523054935,
-0.156818077,
0.0066062631,
-0.2464477271,
-0.1342487633,
-0.0149824573,
-0.1416887045,
0.2038478553,
-0.1734601557,
0.274865061,
-0.3760205507,
-0.3403144181,
0.1934224218,
-0.4669493139,
0.2915157676,
0.1712654978,
0.3249736726,
0.01150956,
-0.0826751292,
0.2971024513,
0.1473516226,
-0.2755602896,
0.0868832693,
0.1278885007,
-0.1847961545,
-0.1473127902,
-0.1283162534,
-0.0837556645,
-0.0611207373,
0.5471813679,
0.0458364151,
-0.0073459544,
0.0352045484,
-0.1841142029,
0.1741683334,
-0.2019836456,
0.1474639475,
-0.1000352651,
-0.2023385465,
0.4952686429,
-0.1158047244,
-0.2570669055,
0.2463960648,
0.1946710497,
-0.0627766475,
-0.5214527845,
-0.4580499828,
-0.1125501171,
-0.2222223133,
0.1731904,
0.0361224711,
-0.0211323537,
0.2044451088,
0.2828431726,
0.0924886465,
-0.1331232488,
-0.3217515051,
0.2168673873,
-0.1149045527,
0.3705756366,
0.229542166,
0.5801632404,
0.0267307814,
0.1267066002,
0.4855313599,
0.0813877657,
0.4397227764,
-0.2448516935,
0.2744466662,
0.0405868255,
-0.3967849612,
-0.144380793,
-0.0067425766,
0.2739504874,
0.2107274234,
-0.0721477941,
0.2501766682,
-0.161156103,
-0.4184881151,
-0.2881410718,
-0.2161305547,
-0.2507658005,
-0.2529597878,
-0.1558507383,
-0.0427527204,
0.1910305321,
-0.0089064585,
-0.0368012562,
-0.165631637,
0.3251269758,
0.187195912,
0.0616853312,
-0.3045361042,
-0.0767420083,
-0.3085831106,
0.5139846206,
-0.1512745619,
0.1072856262,
-0.2109487355,
0.261408776,
0.2018530965,
-0.0830560625,
0.5891121626,
-0.0522664264,
-0.1955270171,
-0.2235857695,
-0.1792806089,
-0.1916977316,
-0.0003655858,
0.0515177399,
0.524971664,
-0.1540424377,
0.4854559898,
-0.2532545924,
-0.1027110219,
0.3763462007,
-0.0827973187,
-0.2750820518,
-0.274766773,
-0.221667245,
-0.6309242845,
-0.3929288089,
-0.2411657423,
0.0419175029,
0.1712827384,
0.2202278525,
-0.0511404313,
0.2413155138,
-0.0368994772,
0.2094680369,
0.0573112257,
0.164881587,
0.015696913,
0.1193452999,
0.447676301,
0.4823464751,
0.3408181071,
0.5438460112,
0.2892931998,
-0.3729484379,
-0.1212894171,
-0.2567265928,
0.3685420156,
0.3659646511,
-0.1454487443,
0.4599063694,
0.4394858181,
0.1895735711,
-0.0235841945,
-0.35052073,
0.6708257794,
-0.136162281,
-0.3003071845,
-0.2251113355,
0.6455274224,
-0.0722115785,
-0.0083005521,
-0.0961425528,
0.8565520644,
-0.4045521617,
0.1406683177,
-0.1144146845,
0.9707813859,
0.2439148575,
0.0657509789,
0.212507382,
-0.3460534215,
0.7805585265,
-0.1146148443,
-0.1569778174,
-0.1061242074,
-0.2784779966,
-0.253462851,
-0.0314239375,
0.6162327528,
-0.129265964,
-0.3895373344,
0.2596889138,
-0.1813994497,
-0.0262026936,
0.0630647615,
0.3302702308,
-0.1566197574,
0.0120084137,
-0.1239413992,
-0.0406471565,
-0.2230633944,
0.2573016584,
0.1836851984,
-0.4963357747,
-0.3150823712,
-0.5024331212,
-0.4564316571,
-0.1392840296,
0.0554738306,
0.1075320765,
0.3621320724,
-0.1425970644,
0.42131266,
0.2806856036,
0.2414780259,
0.0733569488,
-0.3126103878,
0.3042821884,
0.0693075731,
0.0905005708,
-0.1009964719,
0.2046938092,
0.1310374886,
-0.0908240676,
-0.3782346547,
0.0255646296,
-0.170405969,
-0.2730223835,
-0.3052792549,
-0.0108464863,
-0.5314845443,
-0.3592272103,
-0.0459644906,
-0.0933968052,
0.1204604954,
-0.2096866071,
-0.0508309118,
0.2051824182,
-0.1585181206,
0.11315988,
0.1752721071,
-0.2599327564,
-0.1211365834,
0.1945240051,
0.0517081097,
-0.0758094415,
0.738201201,
-0.0151161337,
-0.0463288575,
0.0344071947,
0.305067122,
0.5040737391,
-0.3405202031,
-0.0078189261,
0.1015039682,
0.203764677,
-0.1576676369,
0.3481948972,
0.1456015855,
0.017616801,
-0.0434355028,
-0.1594154239,
-0.2938861251,
0.2577037811,
-0.1001600176,
0.0724462569,
0.0341090895,
0.0561429709,
0.0715898871,
-0.1312874258,
-0.1116523072,
-0.054886613,
-0.2279753238,
-0.0961762965,
0.5317974091,
0.0938218907,
0.2391976267,
-0.0412316546,
-0.0095941387,
0.2431293428,
0.0938178971,
0.0676105171,
-0.0370422862,
0.2322483808,
0.0467586853,
-0.1022975966,
-0.3561674356,
-0.0097471206,
-0.041012127,
0.0793019831,
-0.0139505789,
0.1000053212,
0.122114785,
0.239648819,
-0.1847434342,
-0.1497962028,
-0.0093253627,
0.0410424657,
-0.0874931291,
0.5481004119,
0.0717477575,
0.1259182543,
-0.0479989201,
0.0514641665,
-0.2951927483,
0.205824092,
-0.1041139737,
0.0983924717,
0.2587778866,
-0.5512776971,
0.1468630284,
0.1320091486,
0.2144632041,
0.3191116154,
-0.5068872571,
-0.0747356787,
0.1159851924,
-0.0918560103,
-0.162713781,
-0.2045922428,
0.4023219347,
0.0717082545,
-0.1683941782,
0.3643619418,
-0.0852905586,
0.1275620759,
-0.1635774374,
0.0195566695,
0.6517640948,
0.0120809888,
0.1246201843,
0.1561939567,
-0.1916542053,
0.010339587,
0.1720245928,
0.5985143185,
0.0668238252,
0.5794849992,
-0.3076900244,
-0.0728971139,
-0.087423116,
0.1050709933,
0.1808955669,
-0.1946446896,
0.3338294327,
0.1026643962,
-0.0328661911,
0.0556588322,
0.2579696774,
0.2040362954,
-0.1194916368,
-0.1161335707,
-0.3817315996,
0.3743077219,
-0.0626280159,
-0.0479780845,
0.10640423,
-0.1119835824,
-0.2741886973,
-0.0057804091,
-0.0417926572,
-0.2112561017,
-0.0392164364,
-0.0361016504,
-0.2471692264,
-0.3594624102,
0.1148994416,
-0.07085336,
0.3237806857,
-0.3258561492,
0.2716215551,
0.4770396054,
-0.0874145404,
0.3965903819,
0.1802964211,
0.4558027089,
0.2538439035,
0.0559700541,
0.1341740638,
-0.2208001763,
-0.2341291904,
0.3859181702,
0.1854974777,
0.0741456524,
0.2813531756,
0.3191987872,
-0.0598136,
0.0704869628,
0.157232374,
0.1676174253,
0.5063421726,
-0.233423546,
0.2219503373,
-0.4632662535,
-0.093121767,
-0.1873606443,
-0.2527435124,
-0.6309565902,
-0.1494468004,
0.0954419672,
0.1450188905,
-0.0473054834,
-0.2213515341,
-0.0389558822,
0.0667643696,
0.3249362409,
0.3471042514,
0.1524049193,
0.0727005675,
-0.0405905843,
-0.4020784497,
-0.0642596111,
-0.0017720949,
-0.2230420113,
0.0846144706,
-0.0462719761,
0.0855319723,
-0.0165546555,
0.2441145033,
0.1304906458,
-0.2920006812,
0.1221100241,
-0.1371928304,
-0.2522900105,
0.3164979815,
0.1390787065,
-0.0291791987,
0.2870527506,
0.4058148563,
-0.119514145,
-0.1022103429,
-0.2267849743,
0.1514929235,
-0.3036987185,
-0.3732871413,
0.1816313416,
0.2759608924,
0.520064652,
0.0530720353,
-0.1515792459,
-0.0674705878,
-0.0698416829,
-0.2896794081,
0.4932010174,
0.2914783061,
0.4569692016,
-0.0481124818,
-0.0334689505,
-0.2781469226,
0.1481506377,
-0.2447091788,
-0.0002809319,
-0.2397976518,
0.0752074793,
-0.0365626998,
-0.2248827517,
0.2073450983,
-0.093376562,
-0.0137532195,
0.2888597548,
-0.2180061489,
-0.1873251647,
0.634741962,
-0.3872469366,
-0.1221085712,
0.3153212965,
0.1434237808,
0.2447898388,
-0.4161329865,
-0.6202842593,
-0.0238009691,
0.3712835014,
-0.029262621,
-0.249429971,
0.1089367718,
0.0357241109,
-0.2324365228,
0.0692822635,
0.3532497287,
-0.106445156,
-0.0376626067,
0.239304468,
0.0481238663
] |
https://github.com/huggingface/datasets/issues/3448 | JSONDecodeError with HuggingFace dataset viewer | It seems that the `feature` key is missing from some feature type definition in your dataset_infos.json:
```json
"tokens": {
"dtype": "list",
"id": null,
"_type": "Sequence"
},
"tags": {
"dtype": "list",
"id": null,
"_type": "Sequence"
}
```
They should be
```json
"tokens": {
"dtype": "list",
"id": null,
"_type": "Sequence"
"feature": {"dtype": "string", "id": null, "_type": "Value"}
},
"tags": {
"dtype": "list",
"id": null,
"_type": "Sequence",
"feature": {"num_classes": 5, "names": ["-", "S", "H", "N", "C"], "names_file": null, "id": null, "_type": "ClassLabel"}
}
```
Note that you can generate the dataset_infos.json automatically to avoid mistakes:
```bash
datasets-cli test ./path/to/dataset --save_infos
``` | ## Dataset viewer issue for 'pubmed_neg'
**Link:** https://huggingface.co/datasets/IGESML/pubmed_neg
I am getting the error:
Status code: 400
Exception: JSONDecodeError
Message: Expecting property name enclosed in double quotes: line 61 column 2 (char 1202)
I have checked all files - I am not using single quotes anywhere. Not sure what is causing this issue.
Am I the one who added this dataset ? Yes
| 98 | JSONDecodeError with HuggingFace dataset viewer
## Dataset viewer issue for 'pubmed_neg'
**Link:** https://huggingface.co/datasets/IGESML/pubmed_neg
I am getting the error:
Status code: 400
Exception: JSONDecodeError
Message: Expecting property name enclosed in double quotes: line 61 column 2 (char 1202)
I have checked all files - I am not using single quotes anywhere. Not sure what is causing this issue.
Am I the one who added this dataset ? Yes
It seems that the `feature` key is missing from some feature type definition in your dataset_infos.json:
```json
"tokens": {
"dtype": "list",
"id": null,
"_type": "Sequence"
},
"tags": {
"dtype": "list",
"id": null,
"_type": "Sequence"
}
```
They should be
```json
"tokens": {
"dtype": "list",
"id": null,
"_type": "Sequence"
"feature": {"dtype": "string", "id": null, "_type": "Value"}
},
"tags": {
"dtype": "list",
"id": null,
"_type": "Sequence",
"feature": {"num_classes": 5, "names": ["-", "S", "H", "N", "C"], "names_file": null, "id": null, "_type": "ClassLabel"}
}
```
Note that you can generate the dataset_infos.json automatically to avoid mistakes:
```bash
datasets-cli test ./path/to/dataset --save_infos
``` | [
0.1093126163,
-0.0348637216,
0.0341626778,
0.1241071299,
0.1576343179,
0.0917591006,
0.0911152512,
0.1819448918,
-0.0062630931,
0.1343883127,
0.160380289,
0.3906168342,
-0.2260689139,
0.177926749,
-0.0963281766,
-0.2384369373,
0.153585434,
0.2733956277,
0.1301555037,
-0.0759228915,
-0.2729405165,
0.6004837751,
-0.1502159685,
0.1359085143,
-0.0068328152,
-0.0958884507,
0.1005220562,
0.0405356474,
-0.2024142295,
-0.7026222348,
0.1683975756,
-0.0063659218,
0.0300413705,
0.4620123208,
-0.0001211502,
0.0333367288,
0.3822969198,
-0.1279213428,
-0.2868421674,
-0.5271567702,
-0.1087766811,
-0.1505895704,
0.3054636717,
-0.2841658592,
-0.1448465586,
-0.4547342956,
-0.1411081403,
-0.5221770406,
0.3412873745,
0.1330373436,
0.1192946136,
-0.0580136701,
0.1341989785,
-0.1666596681,
0.0392424911,
0.5257143974,
-0.1785455197,
0.1319948882,
0.3311593235,
0.6049295664,
0.1621312499,
0.4071724713,
0.0375233516,
0.0914946795,
0.384819746,
0.1884717643,
-0.2242311686,
-0.1516784877,
0.2209334224,
0.1750061363,
0.5552140474,
-0.2547836006,
-0.3051436245,
-0.1874630898,
0.0066121169,
-0.1356926113,
0.2798221409,
-0.048955299,
-0.0145273544,
0.1108414829,
-0.2952203751,
-0.340434283,
-0.1523091346,
-0.1021288633,
0.0194410644,
-0.0662150532,
-0.2849165201,
0.2092010081,
0.0850683823,
-0.314930439,
-0.3175570667,
-0.1850062907,
-0.3517677486,
0.1706748307,
0.1709848642,
-0.1567334831,
-0.0435674489,
-0.2973996103,
0.3636880815,
0.3019361794,
-0.1608977318,
-0.0685374811,
-0.0384026058,
0.0727111921,
0.2752907872,
-0.0061227884,
0.2997719944,
-0.066532366,
0.2071035653,
0.2547293901,
0.1758122444,
-0.2130620629,
0.0795502514,
0.1326757222,
-0.1013404503,
-0.2653521597,
0.5658556223,
-0.2766278684,
-0.2066798806,
0.3014305532,
-0.0416291393,
-0.143940106,
-0.2037468851,
0.2117972523,
0.309215337,
-0.1413502991,
0.1388327628,
0.1595690548,
0.0005353728,
-0.2984175086,
-0.0462876931,
0.0183114484,
0.182655558,
-0.0296961181,
-0.0485123768,
-0.2004299909,
0.2719328403,
-0.1463880092,
0.0536723807,
-0.1852937043,
-0.1973432153,
0.0847406983,
-0.0669977069,
0.1572296619,
0.0809412673,
0.2671148777,
0.1706960052,
-0.7364267707,
-0.0763394088,
-0.0900565982,
-0.1889548898,
0.0143750943,
-0.650847435,
0.0112122325,
-0.4802261293,
-0.0963126048,
-0.4396265447,
0.078265503,
-0.0237852782,
-0.1282686442,
-0.1275112182,
0.2842402458,
-0.0606187545,
-0.0887374654,
0.2764636874,
0.4429082274,
-0.2907970548,
-0.2434026301,
0.0037523522,
-0.0473260246,
-0.0456876308,
0.2244792134,
-0.112580575,
0.2330551296,
-0.1621323526,
0.3425220251,
0.2254611999,
-0.333553642,
-0.2924152911,
0.5230190158,
-0.3223005235,
0.1681215018,
0.1430888027,
-0.1122111753,
0.1940625757,
0.0901901275,
0.039408315,
-0.1306494325,
0.05056943,
-0.0248871725,
-0.073172085,
-0.2406374961,
0.3468250334,
-0.0318508297,
-0.1912434995,
-0.0145509308,
0.2580162585,
0.091686897,
0.2945630252,
-0.1904602498,
0.2009153962,
0.4366216362,
0.3877874911,
0.1005304307,
0.1008360162,
-0.1720669568,
-0.4046907127,
-0.0164616052,
0.0369940437,
0.1107464507,
-0.680388689,
-0.0313699432,
-0.1524731517,
0.0572900251,
-0.3744133711,
-0.2691677809,
0.0226571951,
0.2479572892,
-0.0026865071,
0.3482220471,
-0.2437302768,
0.0625211522,
0.2246945202,
0.2162647247,
-0.5772853494,
0.0481822975,
-0.126546964,
-0.167999655,
-0.0439060703,
0.0870392099,
0.1563396752,
-0.1797902882,
-0.124446623,
0.3061776459,
0.0051155738,
0.1507057548,
0.2925601006,
-0.1950381398,
0.2211878449,
-0.2424279153,
-0.0040765102,
0.1290698498,
0.2625068724,
0.0031892061,
-0.2692584991,
0.2989778221,
0.0648640692,
0.2477885783,
-0.1695527583,
0.175123468,
0.275264442,
0.0367804319,
-0.1249589249,
-0.2753441036,
0.1542328,
-0.0392176397,
-0.1631759554,
-0.1266905069,
-0.2342569828,
-0.116299212,
0.5628201365,
0.0472202189,
0.053832408,
0.109679006,
-0.3088531196,
0.2412759513,
0.0871490017,
0.3299829066,
0.4539822042,
0.1667145491,
-0.3659740686,
0.1616222709,
0.2496368587,
0.0431213677,
0.1970291287,
0.12199606,
0.0971451104,
-0.0060133021,
0.0324108154,
0.1219168752,
-0.1761828661,
-0.2821277976,
0.0186544545,
0.1560920775,
-0.3983766437,
-0.0111266281,
-0.4180439413,
-0.1300456971,
0.0653400421,
0.1875072569,
-0.2200118452,
-0.2188099176,
-0.1642106324,
0.031900607,
-0.0648126304,
0.0901924521,
-0.2692291737,
0.0862573907,
-0.0667275116,
-0.1745952666,
-0.1348445117,
-0.0743367523,
-0.2887210548,
-0.0621478334,
0.0359551571,
-0.0985462815,
0.2402274907,
-0.0918833688,
0.25952968,
-0.4695128798,
-0.417247653,
0.2439705133,
-0.5047016144,
0.3316901326,
0.1762338579,
0.2495271116,
-0.0514500178,
-0.202271983,
0.3402781487,
0.180376932,
-0.2988286614,
0.1188239232,
0.1158015206,
-0.2846006155,
-0.2487903982,
-0.2366877645,
-0.0032470878,
-0.1473991275,
0.5743983984,
0.0062006158,
-0.0000804422,
0.1568951458,
-0.1111060455,
0.1752444655,
-0.233451426,
0.1923502088,
-0.0976102576,
-0.2441763729,
0.4443976283,
-0.2938812673,
-0.354903698,
0.2314736694,
0.2514656484,
-0.0253372211,
-0.4378635585,
-0.3998901844,
0.0089921504,
-0.1614856124,
0.1909886301,
0.0160933491,
-0.1111534908,
0.2367256582,
0.2811397314,
-0.0117877657,
-0.2141016722,
-0.3667083085,
0.3498558998,
-0.1862113029,
0.4151295125,
0.26231426,
0.4251692593,
0.0593582392,
-0.0071865497,
0.5740023255,
-0.1012948304,
0.4094876945,
-0.2559710145,
0.283179909,
-0.0050352099,
-0.3901174068,
-0.0471068136,
0.0173331071,
0.2140525579,
0.2595523298,
-0.11402677,
0.1619521379,
-0.1638651937,
-0.2303597927,
-0.2233545333,
-0.252836138,
-0.216642797,
-0.0759787485,
-0.0824301839,
-0.1016885117,
0.074050352,
0.0295758955,
-0.0331138484,
-0.0696128011,
0.304702282,
0.1541809738,
0.0890980586,
-0.3766130507,
-0.0929808244,
-0.2212347835,
0.4685804546,
-0.0735951886,
0.0473068282,
-0.308482796,
0.2637278438,
0.109241657,
-0.0742934868,
0.583748579,
-0.0614352338,
-0.1372241974,
-0.0931015238,
-0.102958113,
-0.1451697797,
0.0206199829,
-0.0428611375,
0.537740469,
-0.0234261714,
0.4713232219,
-0.310738951,
-0.1813132167,
0.3540818989,
-0.1576786637,
-0.1632363349,
-0.2993328571,
-0.0872506574,
-0.5861104131,
-0.3985607624,
-0.25151667,
0.1500119716,
0.3752922118,
0.2598404884,
-0.1170977205,
0.2177708298,
0.0028534494,
0.1497060061,
0.0198718868,
0.3284032643,
0.0956293792,
0.215333581,
0.267935425,
0.4024061263,
0.4464538693,
0.4643518031,
0.3052897453,
-0.4028830826,
-0.0318866707,
-0.3318476975,
0.3278054595,
0.2265519798,
-0.0717291385,
0.2912713289,
0.3653918505,
0.2005808353,
-0.1547363847,
-0.249952659,
0.6298196912,
-0.1528212577,
-0.2122303396,
-0.0620952137,
0.5767747164,
-0.0173192415,
0.0948341787,
-0.1098332629,
0.8245103359,
-0.4138952494,
0.0757507682,
0.0095366063,
0.8159400225,
0.2482527345,
-0.0418104976,
0.1336552352,
-0.3178969026,
0.8087646961,
-0.0672866106,
-0.1389811188,
-0.0797900185,
-0.1718435436,
-0.2023022026,
-0.0048381444,
0.6646832228,
-0.1040020734,
-0.5103780031,
0.1425367594,
-0.0969019905,
-0.1143034771,
0.0281824451,
0.3027711213,
-0.0876509994,
-0.1118512154,
-0.0151140662,
0.0472326912,
-0.2929546535,
0.1460062563,
0.195724681,
-0.4998072982,
-0.3500108123,
-0.3860821128,
-0.528121531,
-0.1152421311,
0.0344328806,
0.1044199839,
0.3826616406,
-0.1672718078,
0.5036777258,
0.2165815681,
0.2840229869,
0.1613737494,
-0.372454375,
0.3369403183,
-0.0967946276,
-0.0162985343,
-0.1316636503,
0.1878580004,
0.1195114031,
-0.0992284864,
-0.269633323,
-0.0269095134,
-0.1601721495,
-0.1805278659,
-0.1013852805,
-0.0780938938,
-0.4832065105,
-0.3588617444,
-0.0895778239,
-0.0236547496,
0.0609618649,
-0.2382472456,
0.013220151,
0.1446792483,
-0.2514340878,
-0.0074992115,
0.2358792722,
-0.2042064369,
0.0203474071,
0.1444782019,
0.025283007,
-0.1825623959,
0.6517089605,
0.2101213038,
-0.1209121197,
-0.038477391,
0.218893379,
0.502358079,
-0.3262062073,
0.1398685127,
0.0606925674,
0.1366871744,
-0.1445341557,
0.4420735538,
0.0420188457,
-0.0951920822,
0.0401651934,
-0.1215226799,
-0.2092278004,
0.2262674868,
-0.273896277,
0.1481814831,
0.1300196052,
0.026237404,
0.0944331586,
-0.2285446078,
-0.1999961734,
-0.0641300529,
-0.2735784352,
-0.0400538072,
0.4160198271,
0.0789680406,
0.2699539661,
-0.1040394008,
0.0361363403,
0.2553703487,
0.0068357307,
-0.0216143858,
-0.0766461417,
0.1694800109,
0.0072788689,
-0.0261342339,
-0.253492713,
0.0601912551,
-0.1290718019,
-0.0398419499,
-0.0801920295,
-0.0058645224,
0.1003517583,
0.242477268,
-0.1396210194,
-0.2705876529,
0.0839368477,
-0.0259921309,
-0.0420414247,
0.5958685875,
-0.005329004,
0.1061865613,
-0.1223088503,
-0.0167055447,
-0.2896275222,
0.1853919178,
-0.0403366834,
0.1580655426,
0.371297121,
-0.494096458,
0.031226784,
0.2974081635,
0.2877344191,
0.1649893969,
-0.5133990049,
-0.0502550006,
0.0319311693,
0.0091747018,
-0.1150541157,
-0.1989216059,
0.3478713036,
0.1012283415,
-0.1216591075,
0.2804596722,
-0.1061627269,
0.1796758026,
-0.1402622461,
0.0572886914,
0.7856020927,
0.0253872033,
0.1270875484,
0.0492177121,
-0.1063346341,
0.0044295648,
-0.0240269843,
0.5841275454,
0.1701432317,
0.4755906463,
-0.3196818233,
-0.083918184,
0.1153504774,
0.2271289825,
0.1283914894,
-0.1819808483,
0.2997121215,
0.123351045,
0.0458740853,
0.1415826827,
0.2419813722,
0.2511918843,
-0.0167257097,
-0.162758112,
-0.2316252738,
0.3857504129,
-0.0504155681,
-0.0326705202,
-0.0243738666,
0.0023023493,
-0.3450808525,
-0.0215230528,
0.0130763547,
-0.144253999,
-0.0076452722,
-0.0076882569,
-0.1282713115,
-0.4682411849,
0.084335342,
-0.0686384514,
0.2420974076,
-0.4047833681,
0.2903747261,
0.5441663265,
-0.2114984393,
0.2838193774,
0.3509964049,
0.5047976971,
0.2554543316,
0.0952392891,
0.1188402772,
-0.2060829848,
-0.2767353058,
0.3469498158,
0.0542436279,
0.0294794273,
0.1730302572,
0.2807544768,
0.0365720242,
0.0504235439,
0.1486908048,
0.2146361023,
0.4748764038,
-0.073975876,
0.0936745852,
-0.4272106588,
0.0571307838,
-0.2262034118,
-0.3689087331,
-0.5895825624,
-0.2581380904,
0.0717912465,
0.0433199219,
0.0158066545,
-0.1482310295,
0.0144565441,
0.0515360683,
0.2786646485,
0.2331703007,
0.0996590182,
0.0116099818,
-0.1606122702,
-0.2709611356,
-0.0901350379,
0.0512550436,
-0.2348310202,
0.123740308,
0.0965248868,
0.0706200078,
0.0399892107,
0.1675466448,
0.1865786314,
-0.2878423333,
0.0976615027,
-0.3147788048,
-0.2447460145,
0.3604768515,
-0.0277192071,
0.061749611,
0.3491971195,
0.3305656314,
-0.0357143767,
-0.0759705454,
-0.2699781954,
0.1456195116,
-0.3592274189,
-0.3176042438,
0.1841950268,
0.2685942948,
0.3677827418,
-0.0509493388,
-0.2259937972,
-0.0328943729,
-0.0519719422,
-0.2312511057,
0.4864512086,
0.2860600948,
0.5178737044,
-0.1130928397,
-0.0267078616,
-0.2762331069,
0.0777504742,
-0.2090174407,
-0.1007467285,
-0.4507443607,
0.1543888152,
-0.0512071587,
-0.0161000211,
0.0889090747,
-0.1566115767,
0.004301046,
0.3592106104,
-0.2015642673,
-0.2969314158,
0.6654171944,
-0.1869539022,
-0.1652337909,
0.4272998869,
0.075072825,
0.2001617998,
-0.3132848442,
-0.6769551635,
-0.0335415863,
0.3167101443,
0.0142119555,
-0.2567385137,
0.0546926856,
-0.0502427369,
-0.2829319537,
0.0788383782,
0.3112531006,
0.0490916856,
-0.0380362123,
0.2607263625,
0.0067712064
] |
https://github.com/huggingface/datasets/issues/3447 | HF_DATASETS_OFFLINE=1 didn't stop datasets.builder from downloading | Hi ! Indeed it says "downloading and preparing" but in your case it didn't need to download anything since you used local files (it would have thrown an error otherwise). I think we can improve the logging to make it clearer in this case | ## Describe the bug
According to https://huggingface.co/docs/datasets/loading_datasets.html#loading-a-dataset-builder, setting HF_DATASETS_OFFLINE to 1 should make datasets to "run in full offline mode". It didn't work for me. At the very beginning, datasets still tried to download "custom data configuration" for JSON, despite I have run the program once and cached all data into the same --cache_dir.
"Downloading" is not an issue when running with local disk, but crashes often with cloud storage because (1) multiply GPU processes try to access the same file, AND (2) FileLocker fails to synchronize all processes, due to storage throttling. 99% of times, when the main process releases FileLocker, the file is not actually ready for access in cloud storage and thus triggers "FileNotFound" errors for all other processes. Well, another way to resolve the problem is to investigate super reliable cloud storage, but that's out of scope here.
## Steps to reproduce the bug
```
export HF_DATASETS_OFFLINE=1
python run_clm.py --model_name_or_path=models/gpt-j-6B --train_file=trainpy.v2.train.json --validation_file=trainpy.v2.eval.json --cache_dir=datacache/trainpy.v2
```
## Expected results
datasets should stop all "downloading" behavior but reuse the cached JSON configuration. I think the problem here is part of the cache directory path, "default-471372bed4b51b53", is randomly generated, and it could change if some parameters changed. And I didn't find a way to use a fixed path to ensure datasets to reuse cached data every time.
## Actual results
The logging shows datasets are still downloading into "datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/c2d554c3377ea79c7664b93dc65d0803b45e3279000f993c7bfd18937fd7f426".
```
12/16/2021 10:25:59 - WARNING - datasets.builder - Using custom data configuration default-471372bed4b51b53
12/16/2021 10:25:59 - INFO - datasets.builder - Generating dataset json (datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/c2d554c3377ea79c7664b93dc65d0803b45e3279000f993c7bfd18937fd7f426)
Downloading and preparing dataset json/default to datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/c2d554c3377ea79c7664b93dc65d0803b45e3279000f993c7bfd18937fd7f426...
100%|██████████████████████████████████████████████████████████████████████████████████| 2/2 [00:00<00:00, 17623.13it/s]
12/16/2021 10:25:59 - INFO - datasets.utils.download_manager - Downloading took 0.0 min
12/16/2021 10:26:00 - INFO - datasets.utils.download_manager - Checksum Computation took 0.0 min
100%|███████████████████████████████████████████████████████████████████████████████████| 2/2 [00:00<00:00, 1206.99it/s]
12/16/2021 10:26:00 - INFO - datasets.utils.info_utils - Unable to verify checksums.
12/16/2021 10:26:00 - INFO - datasets.builder - Generating split train
12/16/2021 10:26:01 - INFO - datasets.builder - Generating split validation
12/16/2021 10:26:02 - INFO - datasets.utils.info_utils - Unable to verify splits sizes.
Dataset json downloaded and prepared to datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/c2d554c3377ea79c7664b93dc65d0803b45e3279000f993c7bfd18937fd7f426. Subsequent calls will reuse this data.
100%|█████████████████████████████████████████████████████████████████████████████████████| 2/2 [00:00<00:00, 53.54it/s]
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.16.1
- Platform: Linux
- Python version: 3.8.10
- PyArrow version: 6.0.1
| 44 | HF_DATASETS_OFFLINE=1 didn't stop datasets.builder from downloading
## Describe the bug
According to https://huggingface.co/docs/datasets/loading_datasets.html#loading-a-dataset-builder, setting HF_DATASETS_OFFLINE to 1 should make datasets to "run in full offline mode". It didn't work for me. At the very beginning, datasets still tried to download "custom data configuration" for JSON, despite I have run the program once and cached all data into the same --cache_dir.
"Downloading" is not an issue when running with local disk, but crashes often with cloud storage because (1) multiply GPU processes try to access the same file, AND (2) FileLocker fails to synchronize all processes, due to storage throttling. 99% of times, when the main process releases FileLocker, the file is not actually ready for access in cloud storage and thus triggers "FileNotFound" errors for all other processes. Well, another way to resolve the problem is to investigate super reliable cloud storage, but that's out of scope here.
## Steps to reproduce the bug
```
export HF_DATASETS_OFFLINE=1
python run_clm.py --model_name_or_path=models/gpt-j-6B --train_file=trainpy.v2.train.json --validation_file=trainpy.v2.eval.json --cache_dir=datacache/trainpy.v2
```
## Expected results
datasets should stop all "downloading" behavior but reuse the cached JSON configuration. I think the problem here is part of the cache directory path, "default-471372bed4b51b53", is randomly generated, and it could change if some parameters changed. And I didn't find a way to use a fixed path to ensure datasets to reuse cached data every time.
## Actual results
The logging shows datasets are still downloading into "datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/c2d554c3377ea79c7664b93dc65d0803b45e3279000f993c7bfd18937fd7f426".
```
12/16/2021 10:25:59 - WARNING - datasets.builder - Using custom data configuration default-471372bed4b51b53
12/16/2021 10:25:59 - INFO - datasets.builder - Generating dataset json (datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/c2d554c3377ea79c7664b93dc65d0803b45e3279000f993c7bfd18937fd7f426)
Downloading and preparing dataset json/default to datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/c2d554c3377ea79c7664b93dc65d0803b45e3279000f993c7bfd18937fd7f426...
100%|██████████████████████████████████████████████████████████████████████████████████| 2/2 [00:00<00:00, 17623.13it/s]
12/16/2021 10:25:59 - INFO - datasets.utils.download_manager - Downloading took 0.0 min
12/16/2021 10:26:00 - INFO - datasets.utils.download_manager - Checksum Computation took 0.0 min
100%|███████████████████████████████████████████████████████████████████████████████████| 2/2 [00:00<00:00, 1206.99it/s]
12/16/2021 10:26:00 - INFO - datasets.utils.info_utils - Unable to verify checksums.
12/16/2021 10:26:00 - INFO - datasets.builder - Generating split train
12/16/2021 10:26:01 - INFO - datasets.builder - Generating split validation
12/16/2021 10:26:02 - INFO - datasets.utils.info_utils - Unable to verify splits sizes.
Dataset json downloaded and prepared to datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/c2d554c3377ea79c7664b93dc65d0803b45e3279000f993c7bfd18937fd7f426. Subsequent calls will reuse this data.
100%|█████████████████████████████████████████████████████████████████████████████████████| 2/2 [00:00<00:00, 53.54it/s]
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.16.1
- Platform: Linux
- Python version: 3.8.10
- PyArrow version: 6.0.1
Hi ! Indeed it says "downloading and preparing" but in your case it didn't need to download anything since you used local files (it would have thrown an error otherwise). I think we can improve the logging to make it clearer in this case | [
-0.3771060407,
0.3645550311,
0.0545568578,
0.297896266,
0.2478350103,
-0.0242792517,
0.2448200583,
0.1876754463,
0.2710855901,
0.0606375188,
-0.0563665815,
0.0012010799,
-0.0477959551,
0.2244563699,
-0.042479936,
0.1671870351,
0.0634073466,
0.0005657274,
-0.0805838034,
-0.0723701119,
-0.149542138,
0.3304843605,
-0.0279873926,
-0.0619430877,
-0.2950894535,
-0.1792235523,
0.0909412727,
0.0981357694,
-0.3247748017,
-0.3094448745,
0.4932441115,
0.2930701077,
0.1043176949,
0.4861291945,
-0.0001161499,
0.1958223879,
0.0064502847,
-0.0416023359,
-0.5929573774,
-0.3239890635,
-0.1176579297,
-0.128677547,
0.1511259526,
-0.0768128932,
-0.0185805112,
-0.1940189451,
-0.0987968445,
-0.248343572,
0.3681134284,
0.2415208966,
0.1489446759,
0.303727299,
0.0386154875,
0.0001060527,
0.0733179003,
0.2232067585,
-0.3229056597,
0.2753351033,
-0.166133225,
-0.0935220569,
-0.2426612824,
0.1819606572,
-0.1729584485,
0.3153598905,
0.3019115329,
0.0796648562,
-0.1847037077,
-0.4123035371,
0.1690774709,
0.3626730442,
0.4065836668,
-0.3111477494,
-0.1943264306,
-0.5541575551,
-0.0637430847,
-0.1435642689,
0.3801208138,
0.2441411763,
-0.3796819746,
0.2399765402,
-0.3043854833,
-0.318764776,
-0.0009627707,
0.1685283184,
-0.0111769969,
-0.05546128,
-0.2092853338,
-0.0167395696,
0.2262019664,
0.1810107976,
0.0339598283,
-0.4548461139,
-0.1745292246,
0.0656248555,
-0.3045861423,
-0.1220215261,
0.0826459154,
0.0941204429,
0.2019512206,
0.1261328459,
0.0708344579,
0.0370873325,
-0.0037308161,
-0.0368727446,
0.263140738,
0.2189540714,
-0.1565986574,
0.0544237047,
0.3984751403,
0.4138939977,
-0.0910500735,
0.1133313328,
0.1390938759,
-0.14810507,
0.1437509358,
-0.3489008844,
0.2990494072,
-0.2262061536,
-0.0919843093,
0.273774147,
0.117805168,
-0.0363217518,
0.1147343516,
0.3758810759,
-0.1040931046,
-0.1193516999,
0.0399821438,
-0.0158388168,
-0.3484830856,
-0.0775389671,
-0.1470935643,
-0.0114033259,
-0.0828941464,
0.1293116361,
0.3246577978,
-0.1211194322,
0.289691776,
0.2500597835,
0.0473054834,
-0.029250782,
0.2739145756,
-0.205669269,
0.0953871608,
0.4357787967,
-0.2006676048,
0.2245298326,
0.2022901326,
0.014219055,
-0.0627848506,
-0.0460961945,
-0.2970683873,
-0.3883802295,
-0.1470983922,
0.1297327578,
-0.2992550731,
-0.1291611195,
-0.5435219407,
0.0572483018,
0.091848202,
0.0691203102,
0.2140514851,
-0.123557508,
-0.020322118,
-0.0991172642,
0.230266273,
0.6482762098,
-0.2848667204,
-0.172595799,
0.1467906237,
-0.2133756429,
-0.0293807611,
0.1418738961,
-0.3825209439,
0.524117589,
-0.3629796803,
-0.2708621323,
0.2983474731,
-0.0997627899,
-0.3915802538,
0.5430011153,
-0.1321301013,
0.3104219139,
-0.0222130157,
0.0559613891,
0.1007166132,
0.1705107689,
-0.1328493655,
0.29503721,
0.0685301572,
0.1895580441,
-0.2722433209,
-0.4819198251,
-0.1582438946,
0.2285336703,
0.1787438691,
0.2692222893,
0.0790865496,
-0.0650703683,
0.2074873596,
0.0204036292,
0.193661496,
0.2614831328,
0.2287382782,
0.1060356125,
-0.0761723816,
-0.0113378661,
-0.822820127,
0.3931924105,
-0.1229442954,
-0.0384808928,
-0.3631315529,
-0.220397383,
0.0138057508,
-0.1179293767,
-0.4330796003,
-0.2106692642,
0.0303965993,
0.0356014334,
0.2881070673,
0.0516906083,
-0.2993871868,
0.433139056,
-0.0202200953,
0.3480180204,
-0.1344724596,
0.2775657177,
0.2102471441,
0.0078161033,
-0.1034399122,
-0.1379253566,
0.0289926715,
-0.2600713968,
-0.1750442684,
0.5280989408,
0.0697496384,
0.1832966954,
0.0691078678,
0.2608167231,
0.1532735229,
0.493922323,
0.1274275333,
0.0821774006,
-0.0323045179,
0.023623161,
-0.1821875572,
0.4888336658,
0.0547967479,
0.2446391433,
0.0493419096,
-0.1625959277,
0.2766591609,
0.0204466376,
-0.1260583252,
-0.1902974099,
0.1064878479,
0.0430429168,
0.3800433576,
0.1267901957,
-0.2862274647,
0.1810454726,
0.5636476874,
0.1511561275,
-0.1007637158,
0.1134172902,
-0.0285380334,
-0.1053910255,
0.2328044325,
0.5286235213,
0.4508607388,
-0.0096197715,
0.0356268249,
0.1840508133,
-0.2254067659,
-0.2421070635,
0.1064271629,
-0.0181595962,
0.154023394,
0.2736231685,
0.2255670279,
-0.1165462658,
-0.7022887468,
-0.2253247201,
0.0172578655,
0.2141301781,
-0.3369897902,
0.1370543242,
-0.5385793447,
-0.091994971,
-0.1469152719,
0.0953565091,
-0.4603863955,
-0.3161154389,
0.0773422718,
0.5820371509,
-0.0759491771,
0.1314277351,
-0.2651427686,
0.3445365727,
-0.1593553275,
-0.4816987813,
-0.1539901495,
0.0479732826,
-0.298928231,
-0.0724020526,
0.2802785635,
-0.2258649766,
0.2112368792,
-0.0219622254,
-0.4363895953,
-0.4036354721,
-0.0402257852,
0.254616797,
-0.0959331989,
0.3412903249,
0.2886514068,
0.3193321526,
-0.0477510281,
0.1725631803,
0.0733626634,
-0.0397762768,
0.085419029,
0.0028321564,
-0.0329315774,
0.1220454648,
-0.2263490409,
-0.2187576294,
-0.1459906846,
-0.3106692433,
0.2668367922,
0.1135435551,
0.1194323301,
0.1856222302,
0.2772600651,
0.1343691498,
-0.1656146199,
0.0657612085,
-0.2607957125,
-0.8752496243,
0.3158276081,
-0.148803845,
-0.2059362233,
0.214206785,
0.0660963356,
0.0644007027,
0.0058926311,
-0.792188406,
-0.1587280035,
-0.2364689261,
0.4459840059,
0.0821544528,
0.0003213315,
0.3384246826,
-0.0375401676,
0.0361628719,
-0.0595457293,
0.1440402716,
0.283591181,
-0.005447269,
0.2494149506,
-0.0213511959,
0.376688689,
0.0354927927,
0.5628858805,
0.1050657108,
-0.0684552267,
0.4087568521,
0.024169255,
0.5009689927,
-0.4342516065,
-0.0742150173,
0.0390255526,
-0.1013527289,
-0.3405588567,
0.1302663833,
0.0492885821,
0.1414796561,
-0.1760073751,
0.1335892975,
0.142142579,
-0.3794331253,
0.0377689116,
0.0210833997,
0.0351445116,
0.2634787261,
0.2589312792,
-0.2149841785,
-0.0623341426,
0.0163369421,
0.36560449,
0.1742675155,
0.218951568,
-0.1962735355,
0.0833092183,
-0.5444387794,
0.0505613498,
-0.2929972112,
0.0742468536,
-0.0139863994,
0.120495826,
0.1991144121,
-0.2061509639,
0.6142319441,
-0.0312697515,
0.0200914759,
-0.015968889,
-0.1307868063,
-0.1464710981,
-0.3794789016,
0.0233798046,
0.0970827267,
0.2007865012,
0.398183614,
-0.3378542662,
-0.2974178195,
0.0917026624,
0.0058453809,
-0.0348967612,
-0.1385248005,
-0.2563632429,
-0.2709489763,
-0.2914271653,
0.165048629,
-0.0171924997,
-0.0210954063,
-0.1010691598,
-0.2208378762,
0.1013952121,
0.1051413715,
-0.0760397017,
0.0743686631,
-0.0219443832,
-0.0946928263,
0.1499682814,
0.0838806629,
0.193859458,
0.5458834171,
0.4984756112,
0.0581394807,
-0.10041558,
0.1967577338,
0.0612493008,
-0.1490690857,
0.4627983272,
-0.3140332103,
0.0812862664,
0.1655009836,
0.5606791973,
-0.1973018497,
-0.0234376602,
0.3315827847,
-0.0843841657,
-0.0903544575,
-0.4605581164,
0.4727436304,
-0.0078561651,
-0.0326257199,
0.1552491635,
0.200316757,
-0.2698961496,
0.1840105206,
0.0546925254,
0.6952425241,
0.2288852185,
0.1471467316,
0.4156360328,
-0.2330494672,
0.4782853425,
-0.6611750126,
0.1640219837,
-0.0640158057,
-0.0373971052,
-0.1439361423,
-0.005820862,
0.3378594518,
0.085169293,
0.1002155393,
0.415322721,
-0.0551944822,
0.4513868988,
-0.2118888497,
0.2328147292,
-0.3205887675,
-0.3824599087,
-0.1826850623,
0.1513186395,
-0.0511706807,
0.3802853227,
-0.112793237,
-0.0991780013,
0.2776609361,
-0.0976709872,
-0.197254613,
0.0481412821,
-0.3651536405,
0.0674760714,
0.1715120077,
0.1350494027,
-0.100931026,
-0.0239003785,
0.3525387049,
-0.0388792157,
-0.2251665145,
0.0874657854,
-0.0032332968,
0.2261126339,
-0.147273168,
-0.1226002872,
0.2855151296,
-0.024962144,
-0.0315470248,
-0.1839541644,
-0.2326206714,
-0.2302627116,
0.1309139431,
-0.362960875,
-0.207309559,
-0.2737062275,
0.0540466644,
0.0681035146,
0.1682220697,
-0.2352153063,
0.1065831855,
0.0363243297,
0.065057084,
0.1664476395,
-0.2638940811,
-0.3289960623,
-0.4618972838,
0.5148115754,
-0.0940905213,
-0.1016823947,
0.309181273,
0.1354936957,
-0.1731780469,
-0.2784658074,
0.0751283318,
0.2539462745,
-0.2026139796,
0.2794599533,
0.1086567491,
0.022630943,
-0.0870907158,
0.2194132358,
0.0565912649,
-0.0810241029,
-0.0215806644,
-0.2239600867,
-0.3077503443,
0.1007694975,
-0.0786512196,
0.1344320178,
0.0416446999,
0.1206231639,
0.2031095624,
-0.0253378302,
-0.2632277906,
0.0540597402,
-0.102071397,
-0.2120981067,
0.1060157493,
0.1216607392,
0.3692950606,
-0.1301432252,
-0.0378172994,
-0.0734508559,
-0.4778506756,
-0.1295854151,
-0.2194599956,
0.2081042826,
0.0215351377,
-0.0552968681,
0.1004260555,
-0.2857994139,
-0.3148607612,
-0.1325368881,
0.4680606723,
0.1915600896,
-0.0236137602,
-0.0804449618,
0.0056251101,
0.1977899224,
-0.1495991945,
-0.2191643417,
-0.0429589823,
0.1507379562,
0.0659264401,
0.0779705644,
-0.2201288939,
0.0218657106,
-0.3067268431,
0.2477346957,
-0.0421781875,
0.2516803443,
0.4915270805,
-0.3494473994,
-0.1462102383,
0.1692706794,
0.3857570887,
0.1643128246,
-0.0563286394,
-0.2520607412,
0.2170604765,
0.1449858993,
-0.1726251245,
-0.2595944703,
0.2495053262,
0.0008041754,
0.0763361305,
0.2835106254,
0.4667946994,
-0.0899040252,
0.0102602579,
0.0665270686,
0.5836099982,
-0.1776026338,
0.2839236259,
0.3880079091,
-0.1992437094,
0.1166926697,
0.3512999713,
0.1814543456,
0.0582546853,
0.4114238918,
-0.147438556,
0.0122126071,
0.1096138284,
0.1499212086,
-0.2597983479,
-0.6033144593,
0.1470732838,
0.308706075,
-0.1856643111,
0.1502131969,
-0.1690982282,
0.2909322381,
-0.2931394279,
-0.2718724608,
-0.4396873713,
0.2993877828,
-0.2092563063,
-0.1649801731,
-0.222373873,
-0.2140948772,
-0.1603384465,
0.3382243514,
-0.0086991647,
-0.2688585818,
0.2031989098,
-0.0222249608,
-0.1623664945,
-0.4138527513,
0.198727116,
-0.1281400025,
0.2837714553,
-0.1644661427,
0.3080491722,
-0.1909546405,
-0.1662188917,
-0.1839440167,
0.1685184985,
0.2185055912,
0.2010781616,
0.1600152701,
-0.0993808582,
0.1152726486,
0.0304288641,
-0.1458594203,
0.0363904759,
-0.255110234,
0.0249511097,
0.2943158448,
0.0887470767,
-0.1122211814,
0.0940365344,
-0.1895027161,
0.3534546196,
-0.3985623717,
0.4402439892,
0.135070771,
0.0354030915,
0.1347652227,
-0.0719425902,
-0.1253916323,
-0.1948190928,
0.3149832189,
-0.104888171,
0.1986123174,
-0.3150271773,
0.0759106278,
-0.1353922188,
0.5072630048,
0.1423622072,
-0.2581669092,
-0.2378881425,
-0.0266651288,
-0.5688871145,
-0.2023188621,
-0.2873973548,
-0.0904568285,
-0.0334426053,
0.2520282865,
-0.029120747,
0.0734525621,
0.0230562817,
0.028279487,
0.1370808333,
0.105484888,
-0.2727462649,
0.0704303756,
-0.2570290267,
0.2354102135,
0.0678607672,
-0.3524972498,
0.3484043777,
-0.1028643325,
-0.0920000821,
0.2024568319,
0.1080807149,
0.0438599735,
-0.4841185212,
0.5242003798,
0.0250831656,
-0.2306379378,
0.1475538611,
-0.1114445254,
-0.4103056788,
0.0371783711,
-0.3270640671,
-0.0723988116,
-0.1682721674,
0.5673780441,
-0.1439940929,
0.0363063179,
-0.4745262861,
0.1719297469,
0.2834002078,
0.0889753029,
-0.0870383605,
0.1110447496,
-0.0903470069,
0.3253178895,
0.2429434657,
0.2964677811,
0.0683340132,
0.2211221755,
-0.3460671902,
-0.2087771595,
0.3723540604,
-0.1996343434,
-0.2583676577,
-0.1745095402,
0.410281539,
0.2341164649,
-0.2522521317,
-0.4919864535,
0.1825635284,
0.1768801808,
-0.1668042243,
-0.2113681585,
0.3685191274,
-0.1875643432,
0.0898689553,
-0.0213435814,
0.3217051327,
-0.0108949887,
-0.2810415626,
0.0259362273,
-0.1608594805
] |
https://github.com/huggingface/datasets/issues/3447 | HF_DATASETS_OFFLINE=1 didn't stop datasets.builder from downloading | @lhoestq Thank you for explaining. I am sorry but I was not clear about my intention. I didn't want to kill internet traffic; I wanted to kill all write activity. In other words, you can imagine that my storage has only read access but crashes on write.
When run_clm.py is invoked with the same parameters, the hash in the cache directory "datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/..." doesn't change, and my job can load cached data properly. This is great.
Unfortunately, when params change (which happens sometimes), the hash changes and the old cache is invalid. datasets builder would create a new cache directory with the new hash and create JSON builder there, even though every JSON builder is the same. I didn't find a way to avoid such behavior.
This problem can be resolved when using datasets.map() for tokenizing and grouping text. This function allows me to specify output filenames with --cache_file_names, so that the cached files are always valid.
This is the code that I used to freeze cache filenames for tokenization. I wish I could do the same to datasets.load_dataset()
```
tokenized_datasets = raw_datasets.map(
tokenize_function,
batched=True,
num_proc=data_args.preprocessing_num_workers,
remove_columns=column_names,
load_from_cache_file=not data_args.overwrite_cache,
desc="Running tokenizer on dataset",
cache_file_names={k: os.path.join(model_args.cache_dir, f'{k}-tokenized') for k in raw_datasets},
)
``` | ## Describe the bug
According to https://huggingface.co/docs/datasets/loading_datasets.html#loading-a-dataset-builder, setting HF_DATASETS_OFFLINE to 1 should make datasets to "run in full offline mode". It didn't work for me. At the very beginning, datasets still tried to download "custom data configuration" for JSON, despite I have run the program once and cached all data into the same --cache_dir.
"Downloading" is not an issue when running with local disk, but crashes often with cloud storage because (1) multiply GPU processes try to access the same file, AND (2) FileLocker fails to synchronize all processes, due to storage throttling. 99% of times, when the main process releases FileLocker, the file is not actually ready for access in cloud storage and thus triggers "FileNotFound" errors for all other processes. Well, another way to resolve the problem is to investigate super reliable cloud storage, but that's out of scope here.
## Steps to reproduce the bug
```
export HF_DATASETS_OFFLINE=1
python run_clm.py --model_name_or_path=models/gpt-j-6B --train_file=trainpy.v2.train.json --validation_file=trainpy.v2.eval.json --cache_dir=datacache/trainpy.v2
```
## Expected results
datasets should stop all "downloading" behavior but reuse the cached JSON configuration. I think the problem here is part of the cache directory path, "default-471372bed4b51b53", is randomly generated, and it could change if some parameters changed. And I didn't find a way to use a fixed path to ensure datasets to reuse cached data every time.
## Actual results
The logging shows datasets are still downloading into "datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/c2d554c3377ea79c7664b93dc65d0803b45e3279000f993c7bfd18937fd7f426".
```
12/16/2021 10:25:59 - WARNING - datasets.builder - Using custom data configuration default-471372bed4b51b53
12/16/2021 10:25:59 - INFO - datasets.builder - Generating dataset json (datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/c2d554c3377ea79c7664b93dc65d0803b45e3279000f993c7bfd18937fd7f426)
Downloading and preparing dataset json/default to datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/c2d554c3377ea79c7664b93dc65d0803b45e3279000f993c7bfd18937fd7f426...
100%|██████████████████████████████████████████████████████████████████████████████████| 2/2 [00:00<00:00, 17623.13it/s]
12/16/2021 10:25:59 - INFO - datasets.utils.download_manager - Downloading took 0.0 min
12/16/2021 10:26:00 - INFO - datasets.utils.download_manager - Checksum Computation took 0.0 min
100%|███████████████████████████████████████████████████████████████████████████████████| 2/2 [00:00<00:00, 1206.99it/s]
12/16/2021 10:26:00 - INFO - datasets.utils.info_utils - Unable to verify checksums.
12/16/2021 10:26:00 - INFO - datasets.builder - Generating split train
12/16/2021 10:26:01 - INFO - datasets.builder - Generating split validation
12/16/2021 10:26:02 - INFO - datasets.utils.info_utils - Unable to verify splits sizes.
Dataset json downloaded and prepared to datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/c2d554c3377ea79c7664b93dc65d0803b45e3279000f993c7bfd18937fd7f426. Subsequent calls will reuse this data.
100%|█████████████████████████████████████████████████████████████████████████████████████| 2/2 [00:00<00:00, 53.54it/s]
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.16.1
- Platform: Linux
- Python version: 3.8.10
- PyArrow version: 6.0.1
| 201 | HF_DATASETS_OFFLINE=1 didn't stop datasets.builder from downloading
## Describe the bug
According to https://huggingface.co/docs/datasets/loading_datasets.html#loading-a-dataset-builder, setting HF_DATASETS_OFFLINE to 1 should make datasets to "run in full offline mode". It didn't work for me. At the very beginning, datasets still tried to download "custom data configuration" for JSON, despite I have run the program once and cached all data into the same --cache_dir.
"Downloading" is not an issue when running with local disk, but crashes often with cloud storage because (1) multiply GPU processes try to access the same file, AND (2) FileLocker fails to synchronize all processes, due to storage throttling. 99% of times, when the main process releases FileLocker, the file is not actually ready for access in cloud storage and thus triggers "FileNotFound" errors for all other processes. Well, another way to resolve the problem is to investigate super reliable cloud storage, but that's out of scope here.
## Steps to reproduce the bug
```
export HF_DATASETS_OFFLINE=1
python run_clm.py --model_name_or_path=models/gpt-j-6B --train_file=trainpy.v2.train.json --validation_file=trainpy.v2.eval.json --cache_dir=datacache/trainpy.v2
```
## Expected results
datasets should stop all "downloading" behavior but reuse the cached JSON configuration. I think the problem here is part of the cache directory path, "default-471372bed4b51b53", is randomly generated, and it could change if some parameters changed. And I didn't find a way to use a fixed path to ensure datasets to reuse cached data every time.
## Actual results
The logging shows datasets are still downloading into "datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/c2d554c3377ea79c7664b93dc65d0803b45e3279000f993c7bfd18937fd7f426".
```
12/16/2021 10:25:59 - WARNING - datasets.builder - Using custom data configuration default-471372bed4b51b53
12/16/2021 10:25:59 - INFO - datasets.builder - Generating dataset json (datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/c2d554c3377ea79c7664b93dc65d0803b45e3279000f993c7bfd18937fd7f426)
Downloading and preparing dataset json/default to datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/c2d554c3377ea79c7664b93dc65d0803b45e3279000f993c7bfd18937fd7f426...
100%|██████████████████████████████████████████████████████████████████████████████████| 2/2 [00:00<00:00, 17623.13it/s]
12/16/2021 10:25:59 - INFO - datasets.utils.download_manager - Downloading took 0.0 min
12/16/2021 10:26:00 - INFO - datasets.utils.download_manager - Checksum Computation took 0.0 min
100%|███████████████████████████████████████████████████████████████████████████████████| 2/2 [00:00<00:00, 1206.99it/s]
12/16/2021 10:26:00 - INFO - datasets.utils.info_utils - Unable to verify checksums.
12/16/2021 10:26:00 - INFO - datasets.builder - Generating split train
12/16/2021 10:26:01 - INFO - datasets.builder - Generating split validation
12/16/2021 10:26:02 - INFO - datasets.utils.info_utils - Unable to verify splits sizes.
Dataset json downloaded and prepared to datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/c2d554c3377ea79c7664b93dc65d0803b45e3279000f993c7bfd18937fd7f426. Subsequent calls will reuse this data.
100%|█████████████████████████████████████████████████████████████████████████████████████| 2/2 [00:00<00:00, 53.54it/s]
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.16.1
- Platform: Linux
- Python version: 3.8.10
- PyArrow version: 6.0.1
@lhoestq Thank you for explaining. I am sorry but I was not clear about my intention. I didn't want to kill internet traffic; I wanted to kill all write activity. In other words, you can imagine that my storage has only read access but crashes on write.
When run_clm.py is invoked with the same parameters, the hash in the cache directory "datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/..." doesn't change, and my job can load cached data properly. This is great.
Unfortunately, when params change (which happens sometimes), the hash changes and the old cache is invalid. datasets builder would create a new cache directory with the new hash and create JSON builder there, even though every JSON builder is the same. I didn't find a way to avoid such behavior.
This problem can be resolved when using datasets.map() for tokenizing and grouping text. This function allows me to specify output filenames with --cache_file_names, so that the cached files are always valid.
This is the code that I used to freeze cache filenames for tokenization. I wish I could do the same to datasets.load_dataset()
```
tokenized_datasets = raw_datasets.map(
tokenize_function,
batched=True,
num_proc=data_args.preprocessing_num_workers,
remove_columns=column_names,
load_from_cache_file=not data_args.overwrite_cache,
desc="Running tokenizer on dataset",
cache_file_names={k: os.path.join(model_args.cache_dir, f'{k}-tokenized') for k in raw_datasets},
)
``` | [
-0.3771060407,
0.3645550311,
0.0545568578,
0.297896266,
0.2478350103,
-0.0242792517,
0.2448200583,
0.1876754463,
0.2710855901,
0.0606375188,
-0.0563665815,
0.0012010799,
-0.0477959551,
0.2244563699,
-0.042479936,
0.1671870351,
0.0634073466,
0.0005657274,
-0.0805838034,
-0.0723701119,
-0.149542138,
0.3304843605,
-0.0279873926,
-0.0619430877,
-0.2950894535,
-0.1792235523,
0.0909412727,
0.0981357694,
-0.3247748017,
-0.3094448745,
0.4932441115,
0.2930701077,
0.1043176949,
0.4861291945,
-0.0001161499,
0.1958223879,
0.0064502847,
-0.0416023359,
-0.5929573774,
-0.3239890635,
-0.1176579297,
-0.128677547,
0.1511259526,
-0.0768128932,
-0.0185805112,
-0.1940189451,
-0.0987968445,
-0.248343572,
0.3681134284,
0.2415208966,
0.1489446759,
0.303727299,
0.0386154875,
0.0001060527,
0.0733179003,
0.2232067585,
-0.3229056597,
0.2753351033,
-0.166133225,
-0.0935220569,
-0.2426612824,
0.1819606572,
-0.1729584485,
0.3153598905,
0.3019115329,
0.0796648562,
-0.1847037077,
-0.4123035371,
0.1690774709,
0.3626730442,
0.4065836668,
-0.3111477494,
-0.1943264306,
-0.5541575551,
-0.0637430847,
-0.1435642689,
0.3801208138,
0.2441411763,
-0.3796819746,
0.2399765402,
-0.3043854833,
-0.318764776,
-0.0009627707,
0.1685283184,
-0.0111769969,
-0.05546128,
-0.2092853338,
-0.0167395696,
0.2262019664,
0.1810107976,
0.0339598283,
-0.4548461139,
-0.1745292246,
0.0656248555,
-0.3045861423,
-0.1220215261,
0.0826459154,
0.0941204429,
0.2019512206,
0.1261328459,
0.0708344579,
0.0370873325,
-0.0037308161,
-0.0368727446,
0.263140738,
0.2189540714,
-0.1565986574,
0.0544237047,
0.3984751403,
0.4138939977,
-0.0910500735,
0.1133313328,
0.1390938759,
-0.14810507,
0.1437509358,
-0.3489008844,
0.2990494072,
-0.2262061536,
-0.0919843093,
0.273774147,
0.117805168,
-0.0363217518,
0.1147343516,
0.3758810759,
-0.1040931046,
-0.1193516999,
0.0399821438,
-0.0158388168,
-0.3484830856,
-0.0775389671,
-0.1470935643,
-0.0114033259,
-0.0828941464,
0.1293116361,
0.3246577978,
-0.1211194322,
0.289691776,
0.2500597835,
0.0473054834,
-0.029250782,
0.2739145756,
-0.205669269,
0.0953871608,
0.4357787967,
-0.2006676048,
0.2245298326,
0.2022901326,
0.014219055,
-0.0627848506,
-0.0460961945,
-0.2970683873,
-0.3883802295,
-0.1470983922,
0.1297327578,
-0.2992550731,
-0.1291611195,
-0.5435219407,
0.0572483018,
0.091848202,
0.0691203102,
0.2140514851,
-0.123557508,
-0.020322118,
-0.0991172642,
0.230266273,
0.6482762098,
-0.2848667204,
-0.172595799,
0.1467906237,
-0.2133756429,
-0.0293807611,
0.1418738961,
-0.3825209439,
0.524117589,
-0.3629796803,
-0.2708621323,
0.2983474731,
-0.0997627899,
-0.3915802538,
0.5430011153,
-0.1321301013,
0.3104219139,
-0.0222130157,
0.0559613891,
0.1007166132,
0.1705107689,
-0.1328493655,
0.29503721,
0.0685301572,
0.1895580441,
-0.2722433209,
-0.4819198251,
-0.1582438946,
0.2285336703,
0.1787438691,
0.2692222893,
0.0790865496,
-0.0650703683,
0.2074873596,
0.0204036292,
0.193661496,
0.2614831328,
0.2287382782,
0.1060356125,
-0.0761723816,
-0.0113378661,
-0.822820127,
0.3931924105,
-0.1229442954,
-0.0384808928,
-0.3631315529,
-0.220397383,
0.0138057508,
-0.1179293767,
-0.4330796003,
-0.2106692642,
0.0303965993,
0.0356014334,
0.2881070673,
0.0516906083,
-0.2993871868,
0.433139056,
-0.0202200953,
0.3480180204,
-0.1344724596,
0.2775657177,
0.2102471441,
0.0078161033,
-0.1034399122,
-0.1379253566,
0.0289926715,
-0.2600713968,
-0.1750442684,
0.5280989408,
0.0697496384,
0.1832966954,
0.0691078678,
0.2608167231,
0.1532735229,
0.493922323,
0.1274275333,
0.0821774006,
-0.0323045179,
0.023623161,
-0.1821875572,
0.4888336658,
0.0547967479,
0.2446391433,
0.0493419096,
-0.1625959277,
0.2766591609,
0.0204466376,
-0.1260583252,
-0.1902974099,
0.1064878479,
0.0430429168,
0.3800433576,
0.1267901957,
-0.2862274647,
0.1810454726,
0.5636476874,
0.1511561275,
-0.1007637158,
0.1134172902,
-0.0285380334,
-0.1053910255,
0.2328044325,
0.5286235213,
0.4508607388,
-0.0096197715,
0.0356268249,
0.1840508133,
-0.2254067659,
-0.2421070635,
0.1064271629,
-0.0181595962,
0.154023394,
0.2736231685,
0.2255670279,
-0.1165462658,
-0.7022887468,
-0.2253247201,
0.0172578655,
0.2141301781,
-0.3369897902,
0.1370543242,
-0.5385793447,
-0.091994971,
-0.1469152719,
0.0953565091,
-0.4603863955,
-0.3161154389,
0.0773422718,
0.5820371509,
-0.0759491771,
0.1314277351,
-0.2651427686,
0.3445365727,
-0.1593553275,
-0.4816987813,
-0.1539901495,
0.0479732826,
-0.298928231,
-0.0724020526,
0.2802785635,
-0.2258649766,
0.2112368792,
-0.0219622254,
-0.4363895953,
-0.4036354721,
-0.0402257852,
0.254616797,
-0.0959331989,
0.3412903249,
0.2886514068,
0.3193321526,
-0.0477510281,
0.1725631803,
0.0733626634,
-0.0397762768,
0.085419029,
0.0028321564,
-0.0329315774,
0.1220454648,
-0.2263490409,
-0.2187576294,
-0.1459906846,
-0.3106692433,
0.2668367922,
0.1135435551,
0.1194323301,
0.1856222302,
0.2772600651,
0.1343691498,
-0.1656146199,
0.0657612085,
-0.2607957125,
-0.8752496243,
0.3158276081,
-0.148803845,
-0.2059362233,
0.214206785,
0.0660963356,
0.0644007027,
0.0058926311,
-0.792188406,
-0.1587280035,
-0.2364689261,
0.4459840059,
0.0821544528,
0.0003213315,
0.3384246826,
-0.0375401676,
0.0361628719,
-0.0595457293,
0.1440402716,
0.283591181,
-0.005447269,
0.2494149506,
-0.0213511959,
0.376688689,
0.0354927927,
0.5628858805,
0.1050657108,
-0.0684552267,
0.4087568521,
0.024169255,
0.5009689927,
-0.4342516065,
-0.0742150173,
0.0390255526,
-0.1013527289,
-0.3405588567,
0.1302663833,
0.0492885821,
0.1414796561,
-0.1760073751,
0.1335892975,
0.142142579,
-0.3794331253,
0.0377689116,
0.0210833997,
0.0351445116,
0.2634787261,
0.2589312792,
-0.2149841785,
-0.0623341426,
0.0163369421,
0.36560449,
0.1742675155,
0.218951568,
-0.1962735355,
0.0833092183,
-0.5444387794,
0.0505613498,
-0.2929972112,
0.0742468536,
-0.0139863994,
0.120495826,
0.1991144121,
-0.2061509639,
0.6142319441,
-0.0312697515,
0.0200914759,
-0.015968889,
-0.1307868063,
-0.1464710981,
-0.3794789016,
0.0233798046,
0.0970827267,
0.2007865012,
0.398183614,
-0.3378542662,
-0.2974178195,
0.0917026624,
0.0058453809,
-0.0348967612,
-0.1385248005,
-0.2563632429,
-0.2709489763,
-0.2914271653,
0.165048629,
-0.0171924997,
-0.0210954063,
-0.1010691598,
-0.2208378762,
0.1013952121,
0.1051413715,
-0.0760397017,
0.0743686631,
-0.0219443832,
-0.0946928263,
0.1499682814,
0.0838806629,
0.193859458,
0.5458834171,
0.4984756112,
0.0581394807,
-0.10041558,
0.1967577338,
0.0612493008,
-0.1490690857,
0.4627983272,
-0.3140332103,
0.0812862664,
0.1655009836,
0.5606791973,
-0.1973018497,
-0.0234376602,
0.3315827847,
-0.0843841657,
-0.0903544575,
-0.4605581164,
0.4727436304,
-0.0078561651,
-0.0326257199,
0.1552491635,
0.200316757,
-0.2698961496,
0.1840105206,
0.0546925254,
0.6952425241,
0.2288852185,
0.1471467316,
0.4156360328,
-0.2330494672,
0.4782853425,
-0.6611750126,
0.1640219837,
-0.0640158057,
-0.0373971052,
-0.1439361423,
-0.005820862,
0.3378594518,
0.085169293,
0.1002155393,
0.415322721,
-0.0551944822,
0.4513868988,
-0.2118888497,
0.2328147292,
-0.3205887675,
-0.3824599087,
-0.1826850623,
0.1513186395,
-0.0511706807,
0.3802853227,
-0.112793237,
-0.0991780013,
0.2776609361,
-0.0976709872,
-0.197254613,
0.0481412821,
-0.3651536405,
0.0674760714,
0.1715120077,
0.1350494027,
-0.100931026,
-0.0239003785,
0.3525387049,
-0.0388792157,
-0.2251665145,
0.0874657854,
-0.0032332968,
0.2261126339,
-0.147273168,
-0.1226002872,
0.2855151296,
-0.024962144,
-0.0315470248,
-0.1839541644,
-0.2326206714,
-0.2302627116,
0.1309139431,
-0.362960875,
-0.207309559,
-0.2737062275,
0.0540466644,
0.0681035146,
0.1682220697,
-0.2352153063,
0.1065831855,
0.0363243297,
0.065057084,
0.1664476395,
-0.2638940811,
-0.3289960623,
-0.4618972838,
0.5148115754,
-0.0940905213,
-0.1016823947,
0.309181273,
0.1354936957,
-0.1731780469,
-0.2784658074,
0.0751283318,
0.2539462745,
-0.2026139796,
0.2794599533,
0.1086567491,
0.022630943,
-0.0870907158,
0.2194132358,
0.0565912649,
-0.0810241029,
-0.0215806644,
-0.2239600867,
-0.3077503443,
0.1007694975,
-0.0786512196,
0.1344320178,
0.0416446999,
0.1206231639,
0.2031095624,
-0.0253378302,
-0.2632277906,
0.0540597402,
-0.102071397,
-0.2120981067,
0.1060157493,
0.1216607392,
0.3692950606,
-0.1301432252,
-0.0378172994,
-0.0734508559,
-0.4778506756,
-0.1295854151,
-0.2194599956,
0.2081042826,
0.0215351377,
-0.0552968681,
0.1004260555,
-0.2857994139,
-0.3148607612,
-0.1325368881,
0.4680606723,
0.1915600896,
-0.0236137602,
-0.0804449618,
0.0056251101,
0.1977899224,
-0.1495991945,
-0.2191643417,
-0.0429589823,
0.1507379562,
0.0659264401,
0.0779705644,
-0.2201288939,
0.0218657106,
-0.3067268431,
0.2477346957,
-0.0421781875,
0.2516803443,
0.4915270805,
-0.3494473994,
-0.1462102383,
0.1692706794,
0.3857570887,
0.1643128246,
-0.0563286394,
-0.2520607412,
0.2170604765,
0.1449858993,
-0.1726251245,
-0.2595944703,
0.2495053262,
0.0008041754,
0.0763361305,
0.2835106254,
0.4667946994,
-0.0899040252,
0.0102602579,
0.0665270686,
0.5836099982,
-0.1776026338,
0.2839236259,
0.3880079091,
-0.1992437094,
0.1166926697,
0.3512999713,
0.1814543456,
0.0582546853,
0.4114238918,
-0.147438556,
0.0122126071,
0.1096138284,
0.1499212086,
-0.2597983479,
-0.6033144593,
0.1470732838,
0.308706075,
-0.1856643111,
0.1502131969,
-0.1690982282,
0.2909322381,
-0.2931394279,
-0.2718724608,
-0.4396873713,
0.2993877828,
-0.2092563063,
-0.1649801731,
-0.222373873,
-0.2140948772,
-0.1603384465,
0.3382243514,
-0.0086991647,
-0.2688585818,
0.2031989098,
-0.0222249608,
-0.1623664945,
-0.4138527513,
0.198727116,
-0.1281400025,
0.2837714553,
-0.1644661427,
0.3080491722,
-0.1909546405,
-0.1662188917,
-0.1839440167,
0.1685184985,
0.2185055912,
0.2010781616,
0.1600152701,
-0.0993808582,
0.1152726486,
0.0304288641,
-0.1458594203,
0.0363904759,
-0.255110234,
0.0249511097,
0.2943158448,
0.0887470767,
-0.1122211814,
0.0940365344,
-0.1895027161,
0.3534546196,
-0.3985623717,
0.4402439892,
0.135070771,
0.0354030915,
0.1347652227,
-0.0719425902,
-0.1253916323,
-0.1948190928,
0.3149832189,
-0.104888171,
0.1986123174,
-0.3150271773,
0.0759106278,
-0.1353922188,
0.5072630048,
0.1423622072,
-0.2581669092,
-0.2378881425,
-0.0266651288,
-0.5688871145,
-0.2023188621,
-0.2873973548,
-0.0904568285,
-0.0334426053,
0.2520282865,
-0.029120747,
0.0734525621,
0.0230562817,
0.028279487,
0.1370808333,
0.105484888,
-0.2727462649,
0.0704303756,
-0.2570290267,
0.2354102135,
0.0678607672,
-0.3524972498,
0.3484043777,
-0.1028643325,
-0.0920000821,
0.2024568319,
0.1080807149,
0.0438599735,
-0.4841185212,
0.5242003798,
0.0250831656,
-0.2306379378,
0.1475538611,
-0.1114445254,
-0.4103056788,
0.0371783711,
-0.3270640671,
-0.0723988116,
-0.1682721674,
0.5673780441,
-0.1439940929,
0.0363063179,
-0.4745262861,
0.1719297469,
0.2834002078,
0.0889753029,
-0.0870383605,
0.1110447496,
-0.0903470069,
0.3253178895,
0.2429434657,
0.2964677811,
0.0683340132,
0.2211221755,
-0.3460671902,
-0.2087771595,
0.3723540604,
-0.1996343434,
-0.2583676577,
-0.1745095402,
0.410281539,
0.2341164649,
-0.2522521317,
-0.4919864535,
0.1825635284,
0.1768801808,
-0.1668042243,
-0.2113681585,
0.3685191274,
-0.1875643432,
0.0898689553,
-0.0213435814,
0.3217051327,
-0.0108949887,
-0.2810415626,
0.0259362273,
-0.1608594805
] |
https://github.com/huggingface/datasets/issues/3447 | HF_DATASETS_OFFLINE=1 didn't stop datasets.builder from downloading | Hi ! `load_dataset` may re-generate your dataset if some parameters changed indeed. If you want to freeze a dataset loaded with `load_dataset`, I think the best solution is just to save it somewhere on your disk with `.save_to_disk(my_dataset_dir)` and reload it with `load_from_disk(my_dataset_dir)`. This way you will be able to reload the dataset without having to run `load_dataset` | ## Describe the bug
According to https://huggingface.co/docs/datasets/loading_datasets.html#loading-a-dataset-builder, setting HF_DATASETS_OFFLINE to 1 should make datasets to "run in full offline mode". It didn't work for me. At the very beginning, datasets still tried to download "custom data configuration" for JSON, despite I have run the program once and cached all data into the same --cache_dir.
"Downloading" is not an issue when running with local disk, but crashes often with cloud storage because (1) multiply GPU processes try to access the same file, AND (2) FileLocker fails to synchronize all processes, due to storage throttling. 99% of times, when the main process releases FileLocker, the file is not actually ready for access in cloud storage and thus triggers "FileNotFound" errors for all other processes. Well, another way to resolve the problem is to investigate super reliable cloud storage, but that's out of scope here.
## Steps to reproduce the bug
```
export HF_DATASETS_OFFLINE=1
python run_clm.py --model_name_or_path=models/gpt-j-6B --train_file=trainpy.v2.train.json --validation_file=trainpy.v2.eval.json --cache_dir=datacache/trainpy.v2
```
## Expected results
datasets should stop all "downloading" behavior but reuse the cached JSON configuration. I think the problem here is part of the cache directory path, "default-471372bed4b51b53", is randomly generated, and it could change if some parameters changed. And I didn't find a way to use a fixed path to ensure datasets to reuse cached data every time.
## Actual results
The logging shows datasets are still downloading into "datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/c2d554c3377ea79c7664b93dc65d0803b45e3279000f993c7bfd18937fd7f426".
```
12/16/2021 10:25:59 - WARNING - datasets.builder - Using custom data configuration default-471372bed4b51b53
12/16/2021 10:25:59 - INFO - datasets.builder - Generating dataset json (datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/c2d554c3377ea79c7664b93dc65d0803b45e3279000f993c7bfd18937fd7f426)
Downloading and preparing dataset json/default to datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/c2d554c3377ea79c7664b93dc65d0803b45e3279000f993c7bfd18937fd7f426...
100%|██████████████████████████████████████████████████████████████████████████████████| 2/2 [00:00<00:00, 17623.13it/s]
12/16/2021 10:25:59 - INFO - datasets.utils.download_manager - Downloading took 0.0 min
12/16/2021 10:26:00 - INFO - datasets.utils.download_manager - Checksum Computation took 0.0 min
100%|███████████████████████████████████████████████████████████████████████████████████| 2/2 [00:00<00:00, 1206.99it/s]
12/16/2021 10:26:00 - INFO - datasets.utils.info_utils - Unable to verify checksums.
12/16/2021 10:26:00 - INFO - datasets.builder - Generating split train
12/16/2021 10:26:01 - INFO - datasets.builder - Generating split validation
12/16/2021 10:26:02 - INFO - datasets.utils.info_utils - Unable to verify splits sizes.
Dataset json downloaded and prepared to datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/c2d554c3377ea79c7664b93dc65d0803b45e3279000f993c7bfd18937fd7f426. Subsequent calls will reuse this data.
100%|█████████████████████████████████████████████████████████████████████████████████████| 2/2 [00:00<00:00, 53.54it/s]
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.16.1
- Platform: Linux
- Python version: 3.8.10
- PyArrow version: 6.0.1
| 58 | HF_DATASETS_OFFLINE=1 didn't stop datasets.builder from downloading
## Describe the bug
According to https://huggingface.co/docs/datasets/loading_datasets.html#loading-a-dataset-builder, setting HF_DATASETS_OFFLINE to 1 should make datasets to "run in full offline mode". It didn't work for me. At the very beginning, datasets still tried to download "custom data configuration" for JSON, despite I have run the program once and cached all data into the same --cache_dir.
"Downloading" is not an issue when running with local disk, but crashes often with cloud storage because (1) multiply GPU processes try to access the same file, AND (2) FileLocker fails to synchronize all processes, due to storage throttling. 99% of times, when the main process releases FileLocker, the file is not actually ready for access in cloud storage and thus triggers "FileNotFound" errors for all other processes. Well, another way to resolve the problem is to investigate super reliable cloud storage, but that's out of scope here.
## Steps to reproduce the bug
```
export HF_DATASETS_OFFLINE=1
python run_clm.py --model_name_or_path=models/gpt-j-6B --train_file=trainpy.v2.train.json --validation_file=trainpy.v2.eval.json --cache_dir=datacache/trainpy.v2
```
## Expected results
datasets should stop all "downloading" behavior but reuse the cached JSON configuration. I think the problem here is part of the cache directory path, "default-471372bed4b51b53", is randomly generated, and it could change if some parameters changed. And I didn't find a way to use a fixed path to ensure datasets to reuse cached data every time.
## Actual results
The logging shows datasets are still downloading into "datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/c2d554c3377ea79c7664b93dc65d0803b45e3279000f993c7bfd18937fd7f426".
```
12/16/2021 10:25:59 - WARNING - datasets.builder - Using custom data configuration default-471372bed4b51b53
12/16/2021 10:25:59 - INFO - datasets.builder - Generating dataset json (datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/c2d554c3377ea79c7664b93dc65d0803b45e3279000f993c7bfd18937fd7f426)
Downloading and preparing dataset json/default to datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/c2d554c3377ea79c7664b93dc65d0803b45e3279000f993c7bfd18937fd7f426...
100%|██████████████████████████████████████████████████████████████████████████████████| 2/2 [00:00<00:00, 17623.13it/s]
12/16/2021 10:25:59 - INFO - datasets.utils.download_manager - Downloading took 0.0 min
12/16/2021 10:26:00 - INFO - datasets.utils.download_manager - Checksum Computation took 0.0 min
100%|███████████████████████████████████████████████████████████████████████████████████| 2/2 [00:00<00:00, 1206.99it/s]
12/16/2021 10:26:00 - INFO - datasets.utils.info_utils - Unable to verify checksums.
12/16/2021 10:26:00 - INFO - datasets.builder - Generating split train
12/16/2021 10:26:01 - INFO - datasets.builder - Generating split validation
12/16/2021 10:26:02 - INFO - datasets.utils.info_utils - Unable to verify splits sizes.
Dataset json downloaded and prepared to datacache/trainpy.v2/json/default-471372bed4b51b53/0.0.0/c2d554c3377ea79c7664b93dc65d0803b45e3279000f993c7bfd18937fd7f426. Subsequent calls will reuse this data.
100%|█████████████████████████████████████████████████████████████████████████████████████| 2/2 [00:00<00:00, 53.54it/s]
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.16.1
- Platform: Linux
- Python version: 3.8.10
- PyArrow version: 6.0.1
Hi ! `load_dataset` may re-generate your dataset if some parameters changed indeed. If you want to freeze a dataset loaded with `load_dataset`, I think the best solution is just to save it somewhere on your disk with `.save_to_disk(my_dataset_dir)` and reload it with `load_from_disk(my_dataset_dir)`. This way you will be able to reload the dataset without having to run `load_dataset` | [
-0.3771060407,
0.3645550311,
0.0545568578,
0.297896266,
0.2478350103,
-0.0242792517,
0.2448200583,
0.1876754463,
0.2710855901,
0.0606375188,
-0.0563665815,
0.0012010799,
-0.0477959551,
0.2244563699,
-0.042479936,
0.1671870351,
0.0634073466,
0.0005657274,
-0.0805838034,
-0.0723701119,
-0.149542138,
0.3304843605,
-0.0279873926,
-0.0619430877,
-0.2950894535,
-0.1792235523,
0.0909412727,
0.0981357694,
-0.3247748017,
-0.3094448745,
0.4932441115,
0.2930701077,
0.1043176949,
0.4861291945,
-0.0001161499,
0.1958223879,
0.0064502847,
-0.0416023359,
-0.5929573774,
-0.3239890635,
-0.1176579297,
-0.128677547,
0.1511259526,
-0.0768128932,
-0.0185805112,
-0.1940189451,
-0.0987968445,
-0.248343572,
0.3681134284,
0.2415208966,
0.1489446759,
0.303727299,
0.0386154875,
0.0001060527,
0.0733179003,
0.2232067585,
-0.3229056597,
0.2753351033,
-0.166133225,
-0.0935220569,
-0.2426612824,
0.1819606572,
-0.1729584485,
0.3153598905,
0.3019115329,
0.0796648562,
-0.1847037077,
-0.4123035371,
0.1690774709,
0.3626730442,
0.4065836668,
-0.3111477494,
-0.1943264306,
-0.5541575551,
-0.0637430847,
-0.1435642689,
0.3801208138,
0.2441411763,
-0.3796819746,
0.2399765402,
-0.3043854833,
-0.318764776,
-0.0009627707,
0.1685283184,
-0.0111769969,
-0.05546128,
-0.2092853338,
-0.0167395696,
0.2262019664,
0.1810107976,
0.0339598283,
-0.4548461139,
-0.1745292246,
0.0656248555,
-0.3045861423,
-0.1220215261,
0.0826459154,
0.0941204429,
0.2019512206,
0.1261328459,
0.0708344579,
0.0370873325,
-0.0037308161,
-0.0368727446,
0.263140738,
0.2189540714,
-0.1565986574,
0.0544237047,
0.3984751403,
0.4138939977,
-0.0910500735,
0.1133313328,
0.1390938759,
-0.14810507,
0.1437509358,
-0.3489008844,
0.2990494072,
-0.2262061536,
-0.0919843093,
0.273774147,
0.117805168,
-0.0363217518,
0.1147343516,
0.3758810759,
-0.1040931046,
-0.1193516999,
0.0399821438,
-0.0158388168,
-0.3484830856,
-0.0775389671,
-0.1470935643,
-0.0114033259,
-0.0828941464,
0.1293116361,
0.3246577978,
-0.1211194322,
0.289691776,
0.2500597835,
0.0473054834,
-0.029250782,
0.2739145756,
-0.205669269,
0.0953871608,
0.4357787967,
-0.2006676048,
0.2245298326,
0.2022901326,
0.014219055,
-0.0627848506,
-0.0460961945,
-0.2970683873,
-0.3883802295,
-0.1470983922,
0.1297327578,
-0.2992550731,
-0.1291611195,
-0.5435219407,
0.0572483018,
0.091848202,
0.0691203102,
0.2140514851,
-0.123557508,
-0.020322118,
-0.0991172642,
0.230266273,
0.6482762098,
-0.2848667204,
-0.172595799,
0.1467906237,
-0.2133756429,
-0.0293807611,
0.1418738961,
-0.3825209439,
0.524117589,
-0.3629796803,
-0.2708621323,
0.2983474731,
-0.0997627899,
-0.3915802538,
0.5430011153,
-0.1321301013,
0.3104219139,
-0.0222130157,
0.0559613891,
0.1007166132,
0.1705107689,
-0.1328493655,
0.29503721,
0.0685301572,
0.1895580441,
-0.2722433209,
-0.4819198251,
-0.1582438946,
0.2285336703,
0.1787438691,
0.2692222893,
0.0790865496,
-0.0650703683,
0.2074873596,
0.0204036292,
0.193661496,
0.2614831328,
0.2287382782,
0.1060356125,
-0.0761723816,
-0.0113378661,
-0.822820127,
0.3931924105,
-0.1229442954,
-0.0384808928,
-0.3631315529,
-0.220397383,
0.0138057508,
-0.1179293767,
-0.4330796003,
-0.2106692642,
0.0303965993,
0.0356014334,
0.2881070673,
0.0516906083,
-0.2993871868,
0.433139056,
-0.0202200953,
0.3480180204,
-0.1344724596,
0.2775657177,
0.2102471441,
0.0078161033,
-0.1034399122,
-0.1379253566,
0.0289926715,
-0.2600713968,
-0.1750442684,
0.5280989408,
0.0697496384,
0.1832966954,
0.0691078678,
0.2608167231,
0.1532735229,
0.493922323,
0.1274275333,
0.0821774006,
-0.0323045179,
0.023623161,
-0.1821875572,
0.4888336658,
0.0547967479,
0.2446391433,
0.0493419096,
-0.1625959277,
0.2766591609,
0.0204466376,
-0.1260583252,
-0.1902974099,
0.1064878479,
0.0430429168,
0.3800433576,
0.1267901957,
-0.2862274647,
0.1810454726,
0.5636476874,
0.1511561275,
-0.1007637158,
0.1134172902,
-0.0285380334,
-0.1053910255,
0.2328044325,
0.5286235213,
0.4508607388,
-0.0096197715,
0.0356268249,
0.1840508133,
-0.2254067659,
-0.2421070635,
0.1064271629,
-0.0181595962,
0.154023394,
0.2736231685,
0.2255670279,
-0.1165462658,
-0.7022887468,
-0.2253247201,
0.0172578655,
0.2141301781,
-0.3369897902,
0.1370543242,
-0.5385793447,
-0.091994971,
-0.1469152719,
0.0953565091,
-0.4603863955,
-0.3161154389,
0.0773422718,
0.5820371509,
-0.0759491771,
0.1314277351,
-0.2651427686,
0.3445365727,
-0.1593553275,
-0.4816987813,
-0.1539901495,
0.0479732826,
-0.298928231,
-0.0724020526,
0.2802785635,
-0.2258649766,
0.2112368792,
-0.0219622254,
-0.4363895953,
-0.4036354721,
-0.0402257852,
0.254616797,
-0.0959331989,
0.3412903249,
0.2886514068,
0.3193321526,
-0.0477510281,
0.1725631803,
0.0733626634,
-0.0397762768,
0.085419029,
0.0028321564,
-0.0329315774,
0.1220454648,
-0.2263490409,
-0.2187576294,
-0.1459906846,
-0.3106692433,
0.2668367922,
0.1135435551,
0.1194323301,
0.1856222302,
0.2772600651,
0.1343691498,
-0.1656146199,
0.0657612085,
-0.2607957125,
-0.8752496243,
0.3158276081,
-0.148803845,
-0.2059362233,
0.214206785,
0.0660963356,
0.0644007027,
0.0058926311,
-0.792188406,
-0.1587280035,
-0.2364689261,
0.4459840059,
0.0821544528,
0.0003213315,
0.3384246826,
-0.0375401676,
0.0361628719,
-0.0595457293,
0.1440402716,
0.283591181,
-0.005447269,
0.2494149506,
-0.0213511959,
0.376688689,
0.0354927927,
0.5628858805,
0.1050657108,
-0.0684552267,
0.4087568521,
0.024169255,
0.5009689927,
-0.4342516065,
-0.0742150173,
0.0390255526,
-0.1013527289,
-0.3405588567,
0.1302663833,
0.0492885821,
0.1414796561,
-0.1760073751,
0.1335892975,
0.142142579,
-0.3794331253,
0.0377689116,
0.0210833997,
0.0351445116,
0.2634787261,
0.2589312792,
-0.2149841785,
-0.0623341426,
0.0163369421,
0.36560449,
0.1742675155,
0.218951568,
-0.1962735355,
0.0833092183,
-0.5444387794,
0.0505613498,
-0.2929972112,
0.0742468536,
-0.0139863994,
0.120495826,
0.1991144121,
-0.2061509639,
0.6142319441,
-0.0312697515,
0.0200914759,
-0.015968889,
-0.1307868063,
-0.1464710981,
-0.3794789016,
0.0233798046,
0.0970827267,
0.2007865012,
0.398183614,
-0.3378542662,
-0.2974178195,
0.0917026624,
0.0058453809,
-0.0348967612,
-0.1385248005,
-0.2563632429,
-0.2709489763,
-0.2914271653,
0.165048629,
-0.0171924997,
-0.0210954063,
-0.1010691598,
-0.2208378762,
0.1013952121,
0.1051413715,
-0.0760397017,
0.0743686631,
-0.0219443832,
-0.0946928263,
0.1499682814,
0.0838806629,
0.193859458,
0.5458834171,
0.4984756112,
0.0581394807,
-0.10041558,
0.1967577338,
0.0612493008,
-0.1490690857,
0.4627983272,
-0.3140332103,
0.0812862664,
0.1655009836,
0.5606791973,
-0.1973018497,
-0.0234376602,
0.3315827847,
-0.0843841657,
-0.0903544575,
-0.4605581164,
0.4727436304,
-0.0078561651,
-0.0326257199,
0.1552491635,
0.200316757,
-0.2698961496,
0.1840105206,
0.0546925254,
0.6952425241,
0.2288852185,
0.1471467316,
0.4156360328,
-0.2330494672,
0.4782853425,
-0.6611750126,
0.1640219837,
-0.0640158057,
-0.0373971052,
-0.1439361423,
-0.005820862,
0.3378594518,
0.085169293,
0.1002155393,
0.415322721,
-0.0551944822,
0.4513868988,
-0.2118888497,
0.2328147292,
-0.3205887675,
-0.3824599087,
-0.1826850623,
0.1513186395,
-0.0511706807,
0.3802853227,
-0.112793237,
-0.0991780013,
0.2776609361,
-0.0976709872,
-0.197254613,
0.0481412821,
-0.3651536405,
0.0674760714,
0.1715120077,
0.1350494027,
-0.100931026,
-0.0239003785,
0.3525387049,
-0.0388792157,
-0.2251665145,
0.0874657854,
-0.0032332968,
0.2261126339,
-0.147273168,
-0.1226002872,
0.2855151296,
-0.024962144,
-0.0315470248,
-0.1839541644,
-0.2326206714,
-0.2302627116,
0.1309139431,
-0.362960875,
-0.207309559,
-0.2737062275,
0.0540466644,
0.0681035146,
0.1682220697,
-0.2352153063,
0.1065831855,
0.0363243297,
0.065057084,
0.1664476395,
-0.2638940811,
-0.3289960623,
-0.4618972838,
0.5148115754,
-0.0940905213,
-0.1016823947,
0.309181273,
0.1354936957,
-0.1731780469,
-0.2784658074,
0.0751283318,
0.2539462745,
-0.2026139796,
0.2794599533,
0.1086567491,
0.022630943,
-0.0870907158,
0.2194132358,
0.0565912649,
-0.0810241029,
-0.0215806644,
-0.2239600867,
-0.3077503443,
0.1007694975,
-0.0786512196,
0.1344320178,
0.0416446999,
0.1206231639,
0.2031095624,
-0.0253378302,
-0.2632277906,
0.0540597402,
-0.102071397,
-0.2120981067,
0.1060157493,
0.1216607392,
0.3692950606,
-0.1301432252,
-0.0378172994,
-0.0734508559,
-0.4778506756,
-0.1295854151,
-0.2194599956,
0.2081042826,
0.0215351377,
-0.0552968681,
0.1004260555,
-0.2857994139,
-0.3148607612,
-0.1325368881,
0.4680606723,
0.1915600896,
-0.0236137602,
-0.0804449618,
0.0056251101,
0.1977899224,
-0.1495991945,
-0.2191643417,
-0.0429589823,
0.1507379562,
0.0659264401,
0.0779705644,
-0.2201288939,
0.0218657106,
-0.3067268431,
0.2477346957,
-0.0421781875,
0.2516803443,
0.4915270805,
-0.3494473994,
-0.1462102383,
0.1692706794,
0.3857570887,
0.1643128246,
-0.0563286394,
-0.2520607412,
0.2170604765,
0.1449858993,
-0.1726251245,
-0.2595944703,
0.2495053262,
0.0008041754,
0.0763361305,
0.2835106254,
0.4667946994,
-0.0899040252,
0.0102602579,
0.0665270686,
0.5836099982,
-0.1776026338,
0.2839236259,
0.3880079091,
-0.1992437094,
0.1166926697,
0.3512999713,
0.1814543456,
0.0582546853,
0.4114238918,
-0.147438556,
0.0122126071,
0.1096138284,
0.1499212086,
-0.2597983479,
-0.6033144593,
0.1470732838,
0.308706075,
-0.1856643111,
0.1502131969,
-0.1690982282,
0.2909322381,
-0.2931394279,
-0.2718724608,
-0.4396873713,
0.2993877828,
-0.2092563063,
-0.1649801731,
-0.222373873,
-0.2140948772,
-0.1603384465,
0.3382243514,
-0.0086991647,
-0.2688585818,
0.2031989098,
-0.0222249608,
-0.1623664945,
-0.4138527513,
0.198727116,
-0.1281400025,
0.2837714553,
-0.1644661427,
0.3080491722,
-0.1909546405,
-0.1662188917,
-0.1839440167,
0.1685184985,
0.2185055912,
0.2010781616,
0.1600152701,
-0.0993808582,
0.1152726486,
0.0304288641,
-0.1458594203,
0.0363904759,
-0.255110234,
0.0249511097,
0.2943158448,
0.0887470767,
-0.1122211814,
0.0940365344,
-0.1895027161,
0.3534546196,
-0.3985623717,
0.4402439892,
0.135070771,
0.0354030915,
0.1347652227,
-0.0719425902,
-0.1253916323,
-0.1948190928,
0.3149832189,
-0.104888171,
0.1986123174,
-0.3150271773,
0.0759106278,
-0.1353922188,
0.5072630048,
0.1423622072,
-0.2581669092,
-0.2378881425,
-0.0266651288,
-0.5688871145,
-0.2023188621,
-0.2873973548,
-0.0904568285,
-0.0334426053,
0.2520282865,
-0.029120747,
0.0734525621,
0.0230562817,
0.028279487,
0.1370808333,
0.105484888,
-0.2727462649,
0.0704303756,
-0.2570290267,
0.2354102135,
0.0678607672,
-0.3524972498,
0.3484043777,
-0.1028643325,
-0.0920000821,
0.2024568319,
0.1080807149,
0.0438599735,
-0.4841185212,
0.5242003798,
0.0250831656,
-0.2306379378,
0.1475538611,
-0.1114445254,
-0.4103056788,
0.0371783711,
-0.3270640671,
-0.0723988116,
-0.1682721674,
0.5673780441,
-0.1439940929,
0.0363063179,
-0.4745262861,
0.1719297469,
0.2834002078,
0.0889753029,
-0.0870383605,
0.1110447496,
-0.0903470069,
0.3253178895,
0.2429434657,
0.2964677811,
0.0683340132,
0.2211221755,
-0.3460671902,
-0.2087771595,
0.3723540604,
-0.1996343434,
-0.2583676577,
-0.1745095402,
0.410281539,
0.2341164649,
-0.2522521317,
-0.4919864535,
0.1825635284,
0.1768801808,
-0.1668042243,
-0.2113681585,
0.3685191274,
-0.1875643432,
0.0898689553,
-0.0213435814,
0.3217051327,
-0.0108949887,
-0.2810415626,
0.0259362273,
-0.1608594805
] |
https://github.com/huggingface/datasets/issues/3444 | Align the Dataset and IterableDataset processing API | Yes I agree, these should be as aligned as possible. Maybe we can also check the feedback in the survey at http://hf.co/oss-survey and see if people mentioned related things on the API (in particular if we go the breaking change way, it would be good to be sure we are taking the right direction for the community). | ## Intro
Currently the two classes have two distinct API for processing:
### The `.map()` method
Both have those parameters in common: function, batched, batch_size
- IterableDataset is missing those parameters:
with_indices, with_rank, input_columns, drop_last_batch, remove_columns, features, disable_nullable, fn_kwargs, num_proc
- Dataset also has additional parameters that are exclusive, due to caching:
keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, suffix_template, new_fingerprint
- There is also an important difference in terms of behavior:
**Dataset.map adds new columns** (with dict.update)
BUT
**IterableDataset discards previous columns** (it overwrites the dict)
IMO the two methods should have the same behavior. This would be an important breaking change though.
- Dataset.map is eager while IterableDataset.map is lazy
### The `.shuffle()` method
- Both have an optional seed parameter, but IterableDataset requires a mandatory parameter buffer_size to control the size of the local buffer used for approximate shuffling.
- IterableDataset is missing the parameter generator
- Also Dataset has exclusive parameters due to caching: keep_in_memory, load_from_cache_file, indices_cache_file_name, writer_batch_size, new_fingerprint
### The `.with_format()` method
- IterableDataset only supports "torch" (it misses tf, jax, pandas, arrow) and is missing the parameters: columns, output_all_columns and format_kwargs
- other methods like `set_format`, `reset_format` or `formatted_as` are also missing
### Other methods
- Both have the same `remove_columns` method
- IterableDataset is missing: cast, cast_column, filter, rename_column, rename_columns, class_encode_column, flatten, prepare_for_task, train_test_split, shard
- Some other methods are missing but we can discuss them: set_transform, formatted_as, with_transform
- And others don't really make sense for an iterable dataset: select, sort, add_column, add_item
- Dataset is missing skip and take, that IterableDataset implements.
## Questions
I think it would be nice to be able to switch between streaming and regular dataset easily, without changing the processing code significantly.
1. What should be aligned and what shouldn't between those two APIs ?
IMO the minimum is to align the main processing methods.
It would mean aligning breaking the current `Iterable.map` to have the same behavior as `Dataset.map` (add columns with dict.update), and add multiprocessing as well as the missing parameters.
It would also mean implementing the missing methods: cast, cast_column, filter, rename_column, rename_columns, class_encode_column, flatten, prepare_for_task, train_test_split, shard
2. What are the breaking changes for IterableDataset ?
The main breaking change would be the change of behavior of `IterableDataset.map`, because currently it discards all the previous columns instead of keeping them.
3. Shall we also do some changes for regular datasets ?
I agree the simplest would be to have the exact same methods for both Dataset and IterableDataset. However this is probably not a good idea because it would prevent users from using the best benefits of them. That's why we can keep some aspects of regular datasets as they are:
- keep the eager Dataset.map with caching
- keep the with_transform method for lazy processing
- keep Dataset.select (it could also be added to IterableDataset even though it's not recommended)
We could have a completely aligned `map` method if both methods were lazy by default, but this is a very big breaking change so I'm not sure we can consider doing that.
For information, TFDS does lazy map by default, and has an additional `.cache()` method.
## Opinions ?
I'd love to gather some opinions about this here. If the two APIs are more aligned it would be awesome for the examples in `transformers`, and it would create a satisfactory experience for users that want to switch from one mode to the other.
cc @mariosasko @albertvillanova @thomwolf @patrickvonplaten @sgugger | 57 | Align the Dataset and IterableDataset processing API
## Intro
Currently the two classes have two distinct API for processing:
### The `.map()` method
Both have those parameters in common: function, batched, batch_size
- IterableDataset is missing those parameters:
with_indices, with_rank, input_columns, drop_last_batch, remove_columns, features, disable_nullable, fn_kwargs, num_proc
- Dataset also has additional parameters that are exclusive, due to caching:
keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, suffix_template, new_fingerprint
- There is also an important difference in terms of behavior:
**Dataset.map adds new columns** (with dict.update)
BUT
**IterableDataset discards previous columns** (it overwrites the dict)
IMO the two methods should have the same behavior. This would be an important breaking change though.
- Dataset.map is eager while IterableDataset.map is lazy
### The `.shuffle()` method
- Both have an optional seed parameter, but IterableDataset requires a mandatory parameter buffer_size to control the size of the local buffer used for approximate shuffling.
- IterableDataset is missing the parameter generator
- Also Dataset has exclusive parameters due to caching: keep_in_memory, load_from_cache_file, indices_cache_file_name, writer_batch_size, new_fingerprint
### The `.with_format()` method
- IterableDataset only supports "torch" (it misses tf, jax, pandas, arrow) and is missing the parameters: columns, output_all_columns and format_kwargs
- other methods like `set_format`, `reset_format` or `formatted_as` are also missing
### Other methods
- Both have the same `remove_columns` method
- IterableDataset is missing: cast, cast_column, filter, rename_column, rename_columns, class_encode_column, flatten, prepare_for_task, train_test_split, shard
- Some other methods are missing but we can discuss them: set_transform, formatted_as, with_transform
- And others don't really make sense for an iterable dataset: select, sort, add_column, add_item
- Dataset is missing skip and take, that IterableDataset implements.
## Questions
I think it would be nice to be able to switch between streaming and regular dataset easily, without changing the processing code significantly.
1. What should be aligned and what shouldn't between those two APIs ?
IMO the minimum is to align the main processing methods.
It would mean aligning breaking the current `Iterable.map` to have the same behavior as `Dataset.map` (add columns with dict.update), and add multiprocessing as well as the missing parameters.
It would also mean implementing the missing methods: cast, cast_column, filter, rename_column, rename_columns, class_encode_column, flatten, prepare_for_task, train_test_split, shard
2. What are the breaking changes for IterableDataset ?
The main breaking change would be the change of behavior of `IterableDataset.map`, because currently it discards all the previous columns instead of keeping them.
3. Shall we also do some changes for regular datasets ?
I agree the simplest would be to have the exact same methods for both Dataset and IterableDataset. However this is probably not a good idea because it would prevent users from using the best benefits of them. That's why we can keep some aspects of regular datasets as they are:
- keep the eager Dataset.map with caching
- keep the with_transform method for lazy processing
- keep Dataset.select (it could also be added to IterableDataset even though it's not recommended)
We could have a completely aligned `map` method if both methods were lazy by default, but this is a very big breaking change so I'm not sure we can consider doing that.
For information, TFDS does lazy map by default, and has an additional `.cache()` method.
## Opinions ?
I'd love to gather some opinions about this here. If the two APIs are more aligned it would be awesome for the examples in `transformers`, and it would create a satisfactory experience for users that want to switch from one mode to the other.
cc @mariosasko @albertvillanova @thomwolf @patrickvonplaten @sgugger
Yes I agree, these should be as aligned as possible. Maybe we can also check the feedback in the survey at http://hf.co/oss-survey and see if people mentioned related things on the API (in particular if we go the breaking change way, it would be good to be sure we are taking the right direction for the community). | [
-0.3938247263,
0.0599105097,
-0.1768295169,
0.1296566725,
0.1461639255,
0.1594101638,
0.1987354755,
0.4363477528,
-0.1442689151,
0.1145086735,
-0.1134143472,
0.4282385409,
-0.004529018,
0.0938546732,
-0.1481654942,
-0.2814331353,
0.2069459409,
0.2346381545,
-0.2922790945,
-0.0827013031,
-0.3709232807,
0.0790471435,
-0.3790383041,
-0.1493100673,
0.170381248,
-0.3876644671,
-0.25459975,
-0.0112901703,
-0.1872618049,
-0.1664619297,
0.25650841,
0.3596169353,
-0.0392020307,
0.4749002159,
-0.0001048881,
-0.189496398,
0.1596276313,
-0.028314041,
-0.1329943091,
0.1643233597,
-0.245006606,
-0.1325974017,
-0.2192605287,
-0.4512743056,
-0.088414453,
-0.4349061847,
-0.008044051,
-0.3300686479,
0.3047149479,
0.172640413,
0.2316041291,
-0.1052304059,
-0.0344250351,
-0.1494503468,
-0.0447011404,
0.158591792,
-0.1470772773,
-0.1915032864,
0.3304655552,
0.2332138717,
-0.1053332686,
0.1240311041,
-0.1286486387,
-0.02746238,
0.2674429715,
-0.0581031404,
-0.2388736904,
-0.2534137964,
0.1762710065,
0.1188536361,
0.4069985747,
-0.3529678285,
-0.4058941007,
-0.4256542027,
-0.0954871699,
-0.4326694608,
0.0464729592,
-0.1677734554,
0.1453318149,
0.0508873872,
-0.2507835925,
0.122688055,
-0.0637237057,
-0.0185686722,
0.1952025145,
0.3103402555,
0.0209804513,
0.1045050398,
-0.2547565401,
-0.024220679,
0.3727327585,
-0.1913315356,
0.0812461004,
0.3966723084,
-0.3184553087,
-0.2795436382,
0.2104090899,
-0.1641948819,
0.0158984009,
0.3784617782,
0.1635190994,
0.1981881261,
0.0959029943,
0.0607292876,
0.2486555576,
0.2446094751,
-0.0309416596,
0.3233133852,
0.0683354661,
0.104280822,
0.0407602899,
0.0161781814,
0.2399730235,
-0.0915141404,
0.2290834635,
0.121813938,
-0.0953623876,
-0.0288374294,
-0.1814334542,
-0.0313318111,
-0.0681091622,
-0.279132843,
-0.1173051447,
0.166688025,
-0.1932288706,
0.3575166762,
-0.21005027,
-0.0021490497,
0.1231017783,
-0.012348365,
-0.2095153332,
0.0819291174,
0.0453538112,
0.0545670055,
0.157973811,
0.0491879694,
0.2179070562,
0.2747003436,
-0.0591200702,
0.3111183643,
0.2509402335,
-0.2835653424,
0.5274523497,
0.0273553655,
0.1089247167,
0.0711828619,
-0.0379658043,
0.1941185445,
-0.1548009515,
0.0839548633,
-0.0352621153,
-0.1624655724,
0.3057820201,
0.3095150888,
-0.0871459544,
-0.1429676116,
-0.1455596834,
0.2704123259,
0.0487675071,
-0.3790198863,
0.0651991963,
-0.179873094,
-0.0584248565,
-0.4877621531,
0.1868191063,
-0.0246840771,
-0.3142235279,
0.0858544186,
-0.037913017,
0.0887040347,
0.376447171,
0.1597224027,
-0.1438839436,
0.2501089275,
-0.2317945361,
0.1334908158,
0.370124191,
-0.1617664099,
-0.2880757451,
0.2121586949,
0.2511653602,
0.429608345,
0.0652671903,
0.0094102472,
0.3817861378,
-0.1547675431,
0.160683915,
0.2267097235,
-0.3918659985,
-0.0274675228,
-0.1209318191,
-0.1214727312,
0.0905162096,
-0.0232880823,
0.21764189,
-0.0295408871,
-0.0291234367,
-0.3070268035,
0.3469239473,
-0.2588120699,
0.0630616769,
0.0952612832,
0.2312033772,
-0.1346115619,
0.0933532193,
-0.3839901984,
-0.4101966619,
0.0963224694,
0.0951941013,
-0.0538193025,
0.2278878391,
-0.2389973551,
-0.1754375398,
-0.2133572102,
-0.1884432584,
-0.2397693545,
0.2273387313,
0.0050578807,
0.1808647811,
-0.3127583563,
-0.2746402919,
0.1080456227,
-0.2515923381,
-0.1921006143,
-0.1730244309,
-0.1847862303,
-0.0187559072,
-0.1123970374,
0.2256552726,
0.3912216127,
-0.0573877729,
-0.192913413,
-0.0026424567,
0.2370887995,
0.1233157292,
-0.0493472591,
-0.0960090384,
0.4840137661,
0.1542468965,
0.3634497225,
-0.2041444033,
-0.1077213213,
0.1557956785,
-0.1402861327,
-0.1875533164,
0.5086090565,
-0.2821324468,
0.2179533541,
0.4013932943,
-0.3300424814,
0.3879389763,
0.1092597321,
-0.0808732808,
-0.0853594542,
-0.1707437485,
-0.0880099535,
0.262590766,
0.0752714649,
-0.2563150525,
0.334820509,
0.5981007814,
0.0390738547,
-0.0901900828,
-0.1499186307,
-0.0563810393,
-0.210679844,
0.1447109729,
0.481634289,
0.4766665995,
0.2772517204,
0.0725311711,
0.0107796667,
-0.0227075107,
0.0103549194,
0.2694106698,
0.2089919746,
0.3263947666,
0.2509996891,
-0.0385280401,
0.2861737609,
-0.1132946238,
-0.4261757135,
-0.0567027554,
0.2981863618,
0.0077270055,
-0.1878189296,
-0.0889780223,
-0.1070023254,
0.0628677458,
-0.1617553085,
0.2058797628,
-0.4961052537,
0.0102989944,
0.0883019716,
-0.2727248967,
0.0921406224,
-0.1139539108,
0.1690764576,
-0.1451888531,
-0.0929238796,
-0.2493962049,
-0.1789161116,
-0.1266287416,
0.2168071419,
0.181276992,
-0.2027794123,
0.5645669103,
-0.026076857,
0.126778841,
-0.1418687701,
-0.3402943909,
0.1850636154,
-0.2053448856,
-0.1176374406,
0.2922479808,
0.0495874323,
0.0383851938,
-0.3684128523,
0.1105410382,
-0.2912330925,
-0.1725311726,
-0.1738808006,
-0.0540844761,
-0.4535257816,
-0.184661746,
-0.5225244761,
0.1136677489,
-0.3995248079,
0.0294724945,
-0.0287335571,
0.2656822503,
0.0647183657,
-0.0686746538,
0.0953060687,
0.2002909034,
0.2508393228,
-0.2875946462,
-0.1995408833,
0.2655699253,
-0.2103496045,
-0.2576856017,
-0.0578578152,
-0.1705086827,
0.5599966645,
0.2715258598,
0.0540114939,
-0.1253504604,
-0.3154040873,
0.2782407105,
0.0463124178,
-0.0059912321,
0.486540854,
0.2683175504,
-0.153807953,
-0.1352544129,
-0.2218643576,
0.0776321366,
0.1649953425,
-0.0860192403,
0.1473940313,
0.4835622907,
0.0046256138,
0.7643153071,
0.0952189937,
-0.0911128074,
0.1420985758,
-0.0413184166,
0.1967849433,
-0.3426159322,
-0.2553687096,
0.1801258624,
-0.0329628326,
-0.1247089803,
0.2014690787,
-0.2172219306,
-0.2758239508,
-0.07115639,
0.1753584892,
-0.3700980246,
-0.262391001,
0.2075195462,
-0.0012074478,
0.2088101059,
0.0408636183,
0.2202389836,
-0.3115622401,
0.1037243828,
0.3095892072,
-0.1034913063,
0.2170984894,
-0.1889564544,
-0.3297433257,
-0.3293831646,
-0.4656160176,
0.3795633912,
0.2243554294,
0.3545791209,
-0.0173508208,
-0.4456827939,
0.0076472098,
-0.0817617998,
0.3973110318,
-0.4162670672,
-0.4276762605,
0.1079173088,
-0.1121569201,
-0.0727535635,
-0.0041441191,
-0.2792299986,
0.2218794972,
0.1647448242,
0.5939705968,
-0.2795187533,
-0.2414465249,
0.1236437634,
0.0514523201,
-0.0127774486,
-0.1447264701,
-0.0570765622,
-0.1820764244,
-0.1943103373,
-0.115191184,
0.1131431907,
0.0748773813,
0.0091232732,
-0.1652210504,
-0.3048882186,
-0.1022565886,
0.2610974908,
0.440731287,
0.2206822783,
-0.0448319577,
0.1253077388,
0.0348342806,
0.2825872004,
0.182136938,
0.1827869266,
-0.299418509,
-0.0917966217,
0.1187268794,
-0.3675478995,
0.1956217736,
0.1522434503,
-0.0662753507,
0.038820494,
-0.1946687698,
0.0004666856,
-0.4489881694,
-0.0836453885,
0.2694931328,
0.0446352363,
-0.4176667035,
-0.7557767034,
0.1402267814,
0.2727515996,
-0.2956458628,
0.4798955619,
0.0339795761,
-0.1434513628,
0.4613711536,
0.1325906068,
0.7459076047,
0.1473956108,
0.0116124079,
0.414219141,
-0.1439040005,
0.0534751341,
0.0181214456,
0.3403147161,
-0.2328066826,
-0.4288156331,
0.021096427,
0.0871841908,
0.1489483714,
0.2966483533,
-0.0704635009,
0.4370461404,
0.1454187483,
0.0537687503,
-0.1373431087,
0.3099332154,
-0.0752967745,
-0.167357564,
-0.2215203792,
0.1695389152,
0.073613584,
-0.1743609905,
-0.0444150716,
0.0159487855,
-0.1583304405,
0.1352563053,
-0.1113559827,
-0.0216035433,
-0.1305423677,
0.1792606413,
-0.1055143997,
-0.1182365939,
0.1261243969,
0.1437497139,
0.1610058546,
-0.1183527708,
-0.0425557382,
0.2407610565,
0.0440976061,
0.3883620501,
0.0886703357,
-0.1736502349,
0.5399495959,
-0.1309777051,
0.1185004413,
0.094690688,
-0.221031785,
-0.291715771,
-0.4185091257,
0.0324573889,
0.3706111014,
-0.4416734576,
-0.271625638,
0.1152307987,
-0.1167008951,
-0.1554003805,
0.1703113616,
-0.1800570786,
0.1504668593,
0.6006763577,
-0.2035085559,
-0.1193844453,
-0.1548911035,
0.1269121617,
0.1272383481,
-0.1046423614,
0.5184613466,
-0.2217818201,
-0.2456699461,
-0.282035768,
-0.3517222703,
0.3917877674,
-0.0399654172,
0.0799717158,
-0.1522025168,
-0.0278037153,
0.1547952741,
0.117503576,
0.3042074144,
-0.0869453102,
-0.236362204,
-0.0933941677,
-0.3473157585,
0.2271448523,
0.2884257734,
0.3429836631,
0.1500588208,
-0.1144856215,
-0.0780164227,
0.1938443631,
-0.42980358,
-0.3451654017,
0.0963940471,
0.1103833616,
0.0775988623,
-0.0034850494,
0.0441721193,
-0.0814908668,
0.1551719755,
-0.1353917718,
-0.1204196364,
-0.2847900987,
-0.0684377253,
0.0730666891,
-0.0330304578,
0.0574141406,
0.0401284918,
-0.0030414388,
-0.3749843538,
-0.403042376,
0.2404549867,
-0.1155770048,
-0.0092633925,
0.2228492051,
0.1906485111,
0.0444738381,
-0.1909020096,
-0.0616414063,
-0.1469374299,
-0.1118150055,
0.0551527925,
0.1870843321,
0.0551497675,
-0.2592665553,
0.3343960643,
0.1731711775,
0.2246255875,
0.0205305759,
0.3800829351,
-0.0412686095,
0.0146619938,
0.4392943382,
0.2582322061,
0.4059662819,
0.0939721465,
-0.228277877,
-0.0008990892,
0.3355579972,
-0.25574404,
0.0994435027,
0.0010900231,
0.0780839473,
0.17342709,
0.0607343018,
-0.0194148272,
-0.058834251,
-0.0736196712,
0.1280210167,
0.5335603952,
-0.5485839248,
0.2280774415,
0.3149157465,
0.1929387599,
0.0203473046,
0.322912991,
-0.0678182766,
0.1141840592,
0.3676504195,
0.0786435381,
0.4667395949,
0.3182158768,
0.1420912594,
0.2005693465,
-0.3031516671,
0.1445685327,
0.2726216912,
-0.0037318878,
0.3984976709,
0.5406652689,
0.2438676208,
0.0165410899,
-0.2205164284,
-0.0303952005,
-0.0565178096,
-0.1739672273,
0.1011653468,
-0.2280927002,
-0.4134572148,
-0.0667382553,
-0.1848126203,
-0.0506394617,
-0.0039083068,
0.4524054527,
-0.1314304471,
-0.0336906835,
-0.2809821069,
0.1701765954,
-0.0557131842,
0.4646828771,
-0.1668409556,
0.0306806732,
0.1583096385,
-0.2752102315,
-0.0351046473,
0.321313113,
0.2923759818,
0.3571781814,
-0.1909562945,
0.0241232868,
0.0205731802,
-0.1383623481,
-0.0740654618,
0.1340501755,
-0.1510371268,
-0.2100837678,
0.2287798375,
0.2750110626,
-0.1631526798,
-0.0885111168,
0.0194071699,
0.1699271351,
-0.0251775533,
0.3678476214,
0.1011236459,
-0.2240391672,
0.2183157653,
0.0719842464,
-0.1648489684,
-0.3703827262,
0.0713655651,
-0.3820591867,
0.1009900123,
-0.2069848776,
0.1372294128,
0.1428149939,
0.2448458672,
0.335786581,
-0.4205283225,
-0.0888740122,
-0.1441642493,
-0.488967061,
-0.093561694,
0.3024022579,
0.0438535735,
0.0451669693,
0.3202670813,
0.0613437071,
-0.2147625387,
0.2450206131,
-0.1699800193,
0.0172031205,
0.3157087266,
-0.4452907145,
0.0882449299,
-0.1555569023,
-0.2211295068,
0.0565795414,
-0.3819115162,
0.063455984,
-0.0150508089,
0.1577458233,
-0.1588950008,
0.059793666,
0.3827983141,
-0.2145563066,
0.2025450319,
0.2901981473,
-0.0085876482,
-0.2942786217,
0.0616883747,
-0.00181214,
0.2401493788,
-0.3151827753,
0.5031018257,
-0.0215960406,
0.1763950884,
0.1234778315,
-0.1240508929,
-0.0559715852,
0.1100693643,
-0.0035631736,
-0.0541434921,
-0.3359680474,
0.3081209362,
-0.0349041745,
0.1504846066,
0.010142046,
0.3293340206,
0.0806157738,
0.0899241492,
-0.3726038039,
-0.4050135612,
0.2532756925,
-0.4581846297,
-0.2800023556,
-0.0918834582,
0.0123291416,
0.0038931004,
0.1220795885,
-0.3755329847,
-0.2388033867,
0.2589737773,
-0.2083823979,
-0.0017374012,
0.3746935427,
-0.040475294,
0.0620433576,
-0.0093390634,
0.3484624922,
0.0814217031,
-0.4091294706,
-0.139594838,
-0.1869113296
] |
https://github.com/huggingface/datasets/issues/3444 | Align the Dataset and IterableDataset processing API | I like this proposal.
> There is also an important difference in terms of behavior:
Dataset.map adds new columns (with dict.update)
BUT
IterableDataset discards previous columns (it overwrites the dict)
IMO the two methods should have the same behavior. This would be an important breaking change though.
> The main breaking change would be the change of behavior of IterableDataset.map, because currently it discards all the previous columns instead of keeping them.
Yes, this behavior of `IterableDataset.map` was surprising to me the first time I used it because I was expecting the same behavior as `Dataset.map`, so I'm OK with the breaking change here.
> IterableDataset only supports "torch" (it misses tf, jax, pandas, arrow) and is missing the parameters: columns, output_all_columns and format_kwargs
\+ it's also missing the actual formatting code (we return unformatted tensors)
> We could have a completely aligned map method if both methods were lazy by default, but this is a very big breaking change so I'm not sure we can consider doing that.
> For information, TFDS does lazy map by default, and has an additional .cache() method.
If I understand this part correctly, the idea would be for `Dataset.map` to behave similarly to `Dataset.with_transform` (lazy processing) and to have an option to cache processed data (with `.cache()`). This idea is really nice because it can also be applied to `IterableDataset` to fix https://github.com/huggingface/datasets/issues/3142 (again we get the aligned APIs). However, this change would break a lot of things, so I'm still not sure if this is a step in the right direction (maybe it's OK for Datasets 2.0?)
> If the two APIs are more aligned it would be awesome for the examples in transformers, and it would create a satisfactory experience for users that want to switch from one mode to the other.
Yes, it would be amazing to have an option to easily switch between these two modes.
I agree with the rest.
| ## Intro
Currently the two classes have two distinct API for processing:
### The `.map()` method
Both have those parameters in common: function, batched, batch_size
- IterableDataset is missing those parameters:
with_indices, with_rank, input_columns, drop_last_batch, remove_columns, features, disable_nullable, fn_kwargs, num_proc
- Dataset also has additional parameters that are exclusive, due to caching:
keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, suffix_template, new_fingerprint
- There is also an important difference in terms of behavior:
**Dataset.map adds new columns** (with dict.update)
BUT
**IterableDataset discards previous columns** (it overwrites the dict)
IMO the two methods should have the same behavior. This would be an important breaking change though.
- Dataset.map is eager while IterableDataset.map is lazy
### The `.shuffle()` method
- Both have an optional seed parameter, but IterableDataset requires a mandatory parameter buffer_size to control the size of the local buffer used for approximate shuffling.
- IterableDataset is missing the parameter generator
- Also Dataset has exclusive parameters due to caching: keep_in_memory, load_from_cache_file, indices_cache_file_name, writer_batch_size, new_fingerprint
### The `.with_format()` method
- IterableDataset only supports "torch" (it misses tf, jax, pandas, arrow) and is missing the parameters: columns, output_all_columns and format_kwargs
- other methods like `set_format`, `reset_format` or `formatted_as` are also missing
### Other methods
- Both have the same `remove_columns` method
- IterableDataset is missing: cast, cast_column, filter, rename_column, rename_columns, class_encode_column, flatten, prepare_for_task, train_test_split, shard
- Some other methods are missing but we can discuss them: set_transform, formatted_as, with_transform
- And others don't really make sense for an iterable dataset: select, sort, add_column, add_item
- Dataset is missing skip and take, that IterableDataset implements.
## Questions
I think it would be nice to be able to switch between streaming and regular dataset easily, without changing the processing code significantly.
1. What should be aligned and what shouldn't between those two APIs ?
IMO the minimum is to align the main processing methods.
It would mean aligning breaking the current `Iterable.map` to have the same behavior as `Dataset.map` (add columns with dict.update), and add multiprocessing as well as the missing parameters.
It would also mean implementing the missing methods: cast, cast_column, filter, rename_column, rename_columns, class_encode_column, flatten, prepare_for_task, train_test_split, shard
2. What are the breaking changes for IterableDataset ?
The main breaking change would be the change of behavior of `IterableDataset.map`, because currently it discards all the previous columns instead of keeping them.
3. Shall we also do some changes for regular datasets ?
I agree the simplest would be to have the exact same methods for both Dataset and IterableDataset. However this is probably not a good idea because it would prevent users from using the best benefits of them. That's why we can keep some aspects of regular datasets as they are:
- keep the eager Dataset.map with caching
- keep the with_transform method for lazy processing
- keep Dataset.select (it could also be added to IterableDataset even though it's not recommended)
We could have a completely aligned `map` method if both methods were lazy by default, but this is a very big breaking change so I'm not sure we can consider doing that.
For information, TFDS does lazy map by default, and has an additional `.cache()` method.
## Opinions ?
I'd love to gather some opinions about this here. If the two APIs are more aligned it would be awesome for the examples in `transformers`, and it would create a satisfactory experience for users that want to switch from one mode to the other.
cc @mariosasko @albertvillanova @thomwolf @patrickvonplaten @sgugger | 322 | Align the Dataset and IterableDataset processing API
## Intro
Currently the two classes have two distinct API for processing:
### The `.map()` method
Both have those parameters in common: function, batched, batch_size
- IterableDataset is missing those parameters:
with_indices, with_rank, input_columns, drop_last_batch, remove_columns, features, disable_nullable, fn_kwargs, num_proc
- Dataset also has additional parameters that are exclusive, due to caching:
keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, suffix_template, new_fingerprint
- There is also an important difference in terms of behavior:
**Dataset.map adds new columns** (with dict.update)
BUT
**IterableDataset discards previous columns** (it overwrites the dict)
IMO the two methods should have the same behavior. This would be an important breaking change though.
- Dataset.map is eager while IterableDataset.map is lazy
### The `.shuffle()` method
- Both have an optional seed parameter, but IterableDataset requires a mandatory parameter buffer_size to control the size of the local buffer used for approximate shuffling.
- IterableDataset is missing the parameter generator
- Also Dataset has exclusive parameters due to caching: keep_in_memory, load_from_cache_file, indices_cache_file_name, writer_batch_size, new_fingerprint
### The `.with_format()` method
- IterableDataset only supports "torch" (it misses tf, jax, pandas, arrow) and is missing the parameters: columns, output_all_columns and format_kwargs
- other methods like `set_format`, `reset_format` or `formatted_as` are also missing
### Other methods
- Both have the same `remove_columns` method
- IterableDataset is missing: cast, cast_column, filter, rename_column, rename_columns, class_encode_column, flatten, prepare_for_task, train_test_split, shard
- Some other methods are missing but we can discuss them: set_transform, formatted_as, with_transform
- And others don't really make sense for an iterable dataset: select, sort, add_column, add_item
- Dataset is missing skip and take, that IterableDataset implements.
## Questions
I think it would be nice to be able to switch between streaming and regular dataset easily, without changing the processing code significantly.
1. What should be aligned and what shouldn't between those two APIs ?
IMO the minimum is to align the main processing methods.
It would mean aligning breaking the current `Iterable.map` to have the same behavior as `Dataset.map` (add columns with dict.update), and add multiprocessing as well as the missing parameters.
It would also mean implementing the missing methods: cast, cast_column, filter, rename_column, rename_columns, class_encode_column, flatten, prepare_for_task, train_test_split, shard
2. What are the breaking changes for IterableDataset ?
The main breaking change would be the change of behavior of `IterableDataset.map`, because currently it discards all the previous columns instead of keeping them.
3. Shall we also do some changes for regular datasets ?
I agree the simplest would be to have the exact same methods for both Dataset and IterableDataset. However this is probably not a good idea because it would prevent users from using the best benefits of them. That's why we can keep some aspects of regular datasets as they are:
- keep the eager Dataset.map with caching
- keep the with_transform method for lazy processing
- keep Dataset.select (it could also be added to IterableDataset even though it's not recommended)
We could have a completely aligned `map` method if both methods were lazy by default, but this is a very big breaking change so I'm not sure we can consider doing that.
For information, TFDS does lazy map by default, and has an additional `.cache()` method.
## Opinions ?
I'd love to gather some opinions about this here. If the two APIs are more aligned it would be awesome for the examples in `transformers`, and it would create a satisfactory experience for users that want to switch from one mode to the other.
cc @mariosasko @albertvillanova @thomwolf @patrickvonplaten @sgugger
I like this proposal.
> There is also an important difference in terms of behavior:
Dataset.map adds new columns (with dict.update)
BUT
IterableDataset discards previous columns (it overwrites the dict)
IMO the two methods should have the same behavior. This would be an important breaking change though.
> The main breaking change would be the change of behavior of IterableDataset.map, because currently it discards all the previous columns instead of keeping them.
Yes, this behavior of `IterableDataset.map` was surprising to me the first time I used it because I was expecting the same behavior as `Dataset.map`, so I'm OK with the breaking change here.
> IterableDataset only supports "torch" (it misses tf, jax, pandas, arrow) and is missing the parameters: columns, output_all_columns and format_kwargs
\+ it's also missing the actual formatting code (we return unformatted tensors)
> We could have a completely aligned map method if both methods were lazy by default, but this is a very big breaking change so I'm not sure we can consider doing that.
> For information, TFDS does lazy map by default, and has an additional .cache() method.
If I understand this part correctly, the idea would be for `Dataset.map` to behave similarly to `Dataset.with_transform` (lazy processing) and to have an option to cache processed data (with `.cache()`). This idea is really nice because it can also be applied to `IterableDataset` to fix https://github.com/huggingface/datasets/issues/3142 (again we get the aligned APIs). However, this change would break a lot of things, so I'm still not sure if this is a step in the right direction (maybe it's OK for Datasets 2.0?)
> If the two APIs are more aligned it would be awesome for the examples in transformers, and it would create a satisfactory experience for users that want to switch from one mode to the other.
Yes, it would be amazing to have an option to easily switch between these two modes.
I agree with the rest.
| [
-0.3938247263,
0.0599105097,
-0.1768295169,
0.1296566725,
0.1461639255,
0.1594101638,
0.1987354755,
0.4363477528,
-0.1442689151,
0.1145086735,
-0.1134143472,
0.4282385409,
-0.004529018,
0.0938546732,
-0.1481654942,
-0.2814331353,
0.2069459409,
0.2346381545,
-0.2922790945,
-0.0827013031,
-0.3709232807,
0.0790471435,
-0.3790383041,
-0.1493100673,
0.170381248,
-0.3876644671,
-0.25459975,
-0.0112901703,
-0.1872618049,
-0.1664619297,
0.25650841,
0.3596169353,
-0.0392020307,
0.4749002159,
-0.0001048881,
-0.189496398,
0.1596276313,
-0.028314041,
-0.1329943091,
0.1643233597,
-0.245006606,
-0.1325974017,
-0.2192605287,
-0.4512743056,
-0.088414453,
-0.4349061847,
-0.008044051,
-0.3300686479,
0.3047149479,
0.172640413,
0.2316041291,
-0.1052304059,
-0.0344250351,
-0.1494503468,
-0.0447011404,
0.158591792,
-0.1470772773,
-0.1915032864,
0.3304655552,
0.2332138717,
-0.1053332686,
0.1240311041,
-0.1286486387,
-0.02746238,
0.2674429715,
-0.0581031404,
-0.2388736904,
-0.2534137964,
0.1762710065,
0.1188536361,
0.4069985747,
-0.3529678285,
-0.4058941007,
-0.4256542027,
-0.0954871699,
-0.4326694608,
0.0464729592,
-0.1677734554,
0.1453318149,
0.0508873872,
-0.2507835925,
0.122688055,
-0.0637237057,
-0.0185686722,
0.1952025145,
0.3103402555,
0.0209804513,
0.1045050398,
-0.2547565401,
-0.024220679,
0.3727327585,
-0.1913315356,
0.0812461004,
0.3966723084,
-0.3184553087,
-0.2795436382,
0.2104090899,
-0.1641948819,
0.0158984009,
0.3784617782,
0.1635190994,
0.1981881261,
0.0959029943,
0.0607292876,
0.2486555576,
0.2446094751,
-0.0309416596,
0.3233133852,
0.0683354661,
0.104280822,
0.0407602899,
0.0161781814,
0.2399730235,
-0.0915141404,
0.2290834635,
0.121813938,
-0.0953623876,
-0.0288374294,
-0.1814334542,
-0.0313318111,
-0.0681091622,
-0.279132843,
-0.1173051447,
0.166688025,
-0.1932288706,
0.3575166762,
-0.21005027,
-0.0021490497,
0.1231017783,
-0.012348365,
-0.2095153332,
0.0819291174,
0.0453538112,
0.0545670055,
0.157973811,
0.0491879694,
0.2179070562,
0.2747003436,
-0.0591200702,
0.3111183643,
0.2509402335,
-0.2835653424,
0.5274523497,
0.0273553655,
0.1089247167,
0.0711828619,
-0.0379658043,
0.1941185445,
-0.1548009515,
0.0839548633,
-0.0352621153,
-0.1624655724,
0.3057820201,
0.3095150888,
-0.0871459544,
-0.1429676116,
-0.1455596834,
0.2704123259,
0.0487675071,
-0.3790198863,
0.0651991963,
-0.179873094,
-0.0584248565,
-0.4877621531,
0.1868191063,
-0.0246840771,
-0.3142235279,
0.0858544186,
-0.037913017,
0.0887040347,
0.376447171,
0.1597224027,
-0.1438839436,
0.2501089275,
-0.2317945361,
0.1334908158,
0.370124191,
-0.1617664099,
-0.2880757451,
0.2121586949,
0.2511653602,
0.429608345,
0.0652671903,
0.0094102472,
0.3817861378,
-0.1547675431,
0.160683915,
0.2267097235,
-0.3918659985,
-0.0274675228,
-0.1209318191,
-0.1214727312,
0.0905162096,
-0.0232880823,
0.21764189,
-0.0295408871,
-0.0291234367,
-0.3070268035,
0.3469239473,
-0.2588120699,
0.0630616769,
0.0952612832,
0.2312033772,
-0.1346115619,
0.0933532193,
-0.3839901984,
-0.4101966619,
0.0963224694,
0.0951941013,
-0.0538193025,
0.2278878391,
-0.2389973551,
-0.1754375398,
-0.2133572102,
-0.1884432584,
-0.2397693545,
0.2273387313,
0.0050578807,
0.1808647811,
-0.3127583563,
-0.2746402919,
0.1080456227,
-0.2515923381,
-0.1921006143,
-0.1730244309,
-0.1847862303,
-0.0187559072,
-0.1123970374,
0.2256552726,
0.3912216127,
-0.0573877729,
-0.192913413,
-0.0026424567,
0.2370887995,
0.1233157292,
-0.0493472591,
-0.0960090384,
0.4840137661,
0.1542468965,
0.3634497225,
-0.2041444033,
-0.1077213213,
0.1557956785,
-0.1402861327,
-0.1875533164,
0.5086090565,
-0.2821324468,
0.2179533541,
0.4013932943,
-0.3300424814,
0.3879389763,
0.1092597321,
-0.0808732808,
-0.0853594542,
-0.1707437485,
-0.0880099535,
0.262590766,
0.0752714649,
-0.2563150525,
0.334820509,
0.5981007814,
0.0390738547,
-0.0901900828,
-0.1499186307,
-0.0563810393,
-0.210679844,
0.1447109729,
0.481634289,
0.4766665995,
0.2772517204,
0.0725311711,
0.0107796667,
-0.0227075107,
0.0103549194,
0.2694106698,
0.2089919746,
0.3263947666,
0.2509996891,
-0.0385280401,
0.2861737609,
-0.1132946238,
-0.4261757135,
-0.0567027554,
0.2981863618,
0.0077270055,
-0.1878189296,
-0.0889780223,
-0.1070023254,
0.0628677458,
-0.1617553085,
0.2058797628,
-0.4961052537,
0.0102989944,
0.0883019716,
-0.2727248967,
0.0921406224,
-0.1139539108,
0.1690764576,
-0.1451888531,
-0.0929238796,
-0.2493962049,
-0.1789161116,
-0.1266287416,
0.2168071419,
0.181276992,
-0.2027794123,
0.5645669103,
-0.026076857,
0.126778841,
-0.1418687701,
-0.3402943909,
0.1850636154,
-0.2053448856,
-0.1176374406,
0.2922479808,
0.0495874323,
0.0383851938,
-0.3684128523,
0.1105410382,
-0.2912330925,
-0.1725311726,
-0.1738808006,
-0.0540844761,
-0.4535257816,
-0.184661746,
-0.5225244761,
0.1136677489,
-0.3995248079,
0.0294724945,
-0.0287335571,
0.2656822503,
0.0647183657,
-0.0686746538,
0.0953060687,
0.2002909034,
0.2508393228,
-0.2875946462,
-0.1995408833,
0.2655699253,
-0.2103496045,
-0.2576856017,
-0.0578578152,
-0.1705086827,
0.5599966645,
0.2715258598,
0.0540114939,
-0.1253504604,
-0.3154040873,
0.2782407105,
0.0463124178,
-0.0059912321,
0.486540854,
0.2683175504,
-0.153807953,
-0.1352544129,
-0.2218643576,
0.0776321366,
0.1649953425,
-0.0860192403,
0.1473940313,
0.4835622907,
0.0046256138,
0.7643153071,
0.0952189937,
-0.0911128074,
0.1420985758,
-0.0413184166,
0.1967849433,
-0.3426159322,
-0.2553687096,
0.1801258624,
-0.0329628326,
-0.1247089803,
0.2014690787,
-0.2172219306,
-0.2758239508,
-0.07115639,
0.1753584892,
-0.3700980246,
-0.262391001,
0.2075195462,
-0.0012074478,
0.2088101059,
0.0408636183,
0.2202389836,
-0.3115622401,
0.1037243828,
0.3095892072,
-0.1034913063,
0.2170984894,
-0.1889564544,
-0.3297433257,
-0.3293831646,
-0.4656160176,
0.3795633912,
0.2243554294,
0.3545791209,
-0.0173508208,
-0.4456827939,
0.0076472098,
-0.0817617998,
0.3973110318,
-0.4162670672,
-0.4276762605,
0.1079173088,
-0.1121569201,
-0.0727535635,
-0.0041441191,
-0.2792299986,
0.2218794972,
0.1647448242,
0.5939705968,
-0.2795187533,
-0.2414465249,
0.1236437634,
0.0514523201,
-0.0127774486,
-0.1447264701,
-0.0570765622,
-0.1820764244,
-0.1943103373,
-0.115191184,
0.1131431907,
0.0748773813,
0.0091232732,
-0.1652210504,
-0.3048882186,
-0.1022565886,
0.2610974908,
0.440731287,
0.2206822783,
-0.0448319577,
0.1253077388,
0.0348342806,
0.2825872004,
0.182136938,
0.1827869266,
-0.299418509,
-0.0917966217,
0.1187268794,
-0.3675478995,
0.1956217736,
0.1522434503,
-0.0662753507,
0.038820494,
-0.1946687698,
0.0004666856,
-0.4489881694,
-0.0836453885,
0.2694931328,
0.0446352363,
-0.4176667035,
-0.7557767034,
0.1402267814,
0.2727515996,
-0.2956458628,
0.4798955619,
0.0339795761,
-0.1434513628,
0.4613711536,
0.1325906068,
0.7459076047,
0.1473956108,
0.0116124079,
0.414219141,
-0.1439040005,
0.0534751341,
0.0181214456,
0.3403147161,
-0.2328066826,
-0.4288156331,
0.021096427,
0.0871841908,
0.1489483714,
0.2966483533,
-0.0704635009,
0.4370461404,
0.1454187483,
0.0537687503,
-0.1373431087,
0.3099332154,
-0.0752967745,
-0.167357564,
-0.2215203792,
0.1695389152,
0.073613584,
-0.1743609905,
-0.0444150716,
0.0159487855,
-0.1583304405,
0.1352563053,
-0.1113559827,
-0.0216035433,
-0.1305423677,
0.1792606413,
-0.1055143997,
-0.1182365939,
0.1261243969,
0.1437497139,
0.1610058546,
-0.1183527708,
-0.0425557382,
0.2407610565,
0.0440976061,
0.3883620501,
0.0886703357,
-0.1736502349,
0.5399495959,
-0.1309777051,
0.1185004413,
0.094690688,
-0.221031785,
-0.291715771,
-0.4185091257,
0.0324573889,
0.3706111014,
-0.4416734576,
-0.271625638,
0.1152307987,
-0.1167008951,
-0.1554003805,
0.1703113616,
-0.1800570786,
0.1504668593,
0.6006763577,
-0.2035085559,
-0.1193844453,
-0.1548911035,
0.1269121617,
0.1272383481,
-0.1046423614,
0.5184613466,
-0.2217818201,
-0.2456699461,
-0.282035768,
-0.3517222703,
0.3917877674,
-0.0399654172,
0.0799717158,
-0.1522025168,
-0.0278037153,
0.1547952741,
0.117503576,
0.3042074144,
-0.0869453102,
-0.236362204,
-0.0933941677,
-0.3473157585,
0.2271448523,
0.2884257734,
0.3429836631,
0.1500588208,
-0.1144856215,
-0.0780164227,
0.1938443631,
-0.42980358,
-0.3451654017,
0.0963940471,
0.1103833616,
0.0775988623,
-0.0034850494,
0.0441721193,
-0.0814908668,
0.1551719755,
-0.1353917718,
-0.1204196364,
-0.2847900987,
-0.0684377253,
0.0730666891,
-0.0330304578,
0.0574141406,
0.0401284918,
-0.0030414388,
-0.3749843538,
-0.403042376,
0.2404549867,
-0.1155770048,
-0.0092633925,
0.2228492051,
0.1906485111,
0.0444738381,
-0.1909020096,
-0.0616414063,
-0.1469374299,
-0.1118150055,
0.0551527925,
0.1870843321,
0.0551497675,
-0.2592665553,
0.3343960643,
0.1731711775,
0.2246255875,
0.0205305759,
0.3800829351,
-0.0412686095,
0.0146619938,
0.4392943382,
0.2582322061,
0.4059662819,
0.0939721465,
-0.228277877,
-0.0008990892,
0.3355579972,
-0.25574404,
0.0994435027,
0.0010900231,
0.0780839473,
0.17342709,
0.0607343018,
-0.0194148272,
-0.058834251,
-0.0736196712,
0.1280210167,
0.5335603952,
-0.5485839248,
0.2280774415,
0.3149157465,
0.1929387599,
0.0203473046,
0.322912991,
-0.0678182766,
0.1141840592,
0.3676504195,
0.0786435381,
0.4667395949,
0.3182158768,
0.1420912594,
0.2005693465,
-0.3031516671,
0.1445685327,
0.2726216912,
-0.0037318878,
0.3984976709,
0.5406652689,
0.2438676208,
0.0165410899,
-0.2205164284,
-0.0303952005,
-0.0565178096,
-0.1739672273,
0.1011653468,
-0.2280927002,
-0.4134572148,
-0.0667382553,
-0.1848126203,
-0.0506394617,
-0.0039083068,
0.4524054527,
-0.1314304471,
-0.0336906835,
-0.2809821069,
0.1701765954,
-0.0557131842,
0.4646828771,
-0.1668409556,
0.0306806732,
0.1583096385,
-0.2752102315,
-0.0351046473,
0.321313113,
0.2923759818,
0.3571781814,
-0.1909562945,
0.0241232868,
0.0205731802,
-0.1383623481,
-0.0740654618,
0.1340501755,
-0.1510371268,
-0.2100837678,
0.2287798375,
0.2750110626,
-0.1631526798,
-0.0885111168,
0.0194071699,
0.1699271351,
-0.0251775533,
0.3678476214,
0.1011236459,
-0.2240391672,
0.2183157653,
0.0719842464,
-0.1648489684,
-0.3703827262,
0.0713655651,
-0.3820591867,
0.1009900123,
-0.2069848776,
0.1372294128,
0.1428149939,
0.2448458672,
0.335786581,
-0.4205283225,
-0.0888740122,
-0.1441642493,
-0.488967061,
-0.093561694,
0.3024022579,
0.0438535735,
0.0451669693,
0.3202670813,
0.0613437071,
-0.2147625387,
0.2450206131,
-0.1699800193,
0.0172031205,
0.3157087266,
-0.4452907145,
0.0882449299,
-0.1555569023,
-0.2211295068,
0.0565795414,
-0.3819115162,
0.063455984,
-0.0150508089,
0.1577458233,
-0.1588950008,
0.059793666,
0.3827983141,
-0.2145563066,
0.2025450319,
0.2901981473,
-0.0085876482,
-0.2942786217,
0.0616883747,
-0.00181214,
0.2401493788,
-0.3151827753,
0.5031018257,
-0.0215960406,
0.1763950884,
0.1234778315,
-0.1240508929,
-0.0559715852,
0.1100693643,
-0.0035631736,
-0.0541434921,
-0.3359680474,
0.3081209362,
-0.0349041745,
0.1504846066,
0.010142046,
0.3293340206,
0.0806157738,
0.0899241492,
-0.3726038039,
-0.4050135612,
0.2532756925,
-0.4581846297,
-0.2800023556,
-0.0918834582,
0.0123291416,
0.0038931004,
0.1220795885,
-0.3755329847,
-0.2388033867,
0.2589737773,
-0.2083823979,
-0.0017374012,
0.3746935427,
-0.040475294,
0.0620433576,
-0.0093390634,
0.3484624922,
0.0814217031,
-0.4091294706,
-0.139594838,
-0.1869113296
] |
https://github.com/huggingface/datasets/issues/3444 | Align the Dataset and IterableDataset processing API | > If I understand this part correctly, the idea would be for Dataset.map to behave similarly to Dataset.with_transform (lazy processing) and to have an option to cache processed data (with .cache()). This idea is really nice because it can also be applied to IterableDataset to fix #3142 (again we get the aligned APIs). However, this change would break a lot of things, so I'm still not sure if this is a step in the right direction (maybe it's OK for Datasets 2.0?)
Yea this is too big of a change in my opinion. Anyway it's fine as it is right now with streaming=lazy and regular=eager. | ## Intro
Currently the two classes have two distinct API for processing:
### The `.map()` method
Both have those parameters in common: function, batched, batch_size
- IterableDataset is missing those parameters:
with_indices, with_rank, input_columns, drop_last_batch, remove_columns, features, disable_nullable, fn_kwargs, num_proc
- Dataset also has additional parameters that are exclusive, due to caching:
keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, suffix_template, new_fingerprint
- There is also an important difference in terms of behavior:
**Dataset.map adds new columns** (with dict.update)
BUT
**IterableDataset discards previous columns** (it overwrites the dict)
IMO the two methods should have the same behavior. This would be an important breaking change though.
- Dataset.map is eager while IterableDataset.map is lazy
### The `.shuffle()` method
- Both have an optional seed parameter, but IterableDataset requires a mandatory parameter buffer_size to control the size of the local buffer used for approximate shuffling.
- IterableDataset is missing the parameter generator
- Also Dataset has exclusive parameters due to caching: keep_in_memory, load_from_cache_file, indices_cache_file_name, writer_batch_size, new_fingerprint
### The `.with_format()` method
- IterableDataset only supports "torch" (it misses tf, jax, pandas, arrow) and is missing the parameters: columns, output_all_columns and format_kwargs
- other methods like `set_format`, `reset_format` or `formatted_as` are also missing
### Other methods
- Both have the same `remove_columns` method
- IterableDataset is missing: cast, cast_column, filter, rename_column, rename_columns, class_encode_column, flatten, prepare_for_task, train_test_split, shard
- Some other methods are missing but we can discuss them: set_transform, formatted_as, with_transform
- And others don't really make sense for an iterable dataset: select, sort, add_column, add_item
- Dataset is missing skip and take, that IterableDataset implements.
## Questions
I think it would be nice to be able to switch between streaming and regular dataset easily, without changing the processing code significantly.
1. What should be aligned and what shouldn't between those two APIs ?
IMO the minimum is to align the main processing methods.
It would mean aligning breaking the current `Iterable.map` to have the same behavior as `Dataset.map` (add columns with dict.update), and add multiprocessing as well as the missing parameters.
It would also mean implementing the missing methods: cast, cast_column, filter, rename_column, rename_columns, class_encode_column, flatten, prepare_for_task, train_test_split, shard
2. What are the breaking changes for IterableDataset ?
The main breaking change would be the change of behavior of `IterableDataset.map`, because currently it discards all the previous columns instead of keeping them.
3. Shall we also do some changes for regular datasets ?
I agree the simplest would be to have the exact same methods for both Dataset and IterableDataset. However this is probably not a good idea because it would prevent users from using the best benefits of them. That's why we can keep some aspects of regular datasets as they are:
- keep the eager Dataset.map with caching
- keep the with_transform method for lazy processing
- keep Dataset.select (it could also be added to IterableDataset even though it's not recommended)
We could have a completely aligned `map` method if both methods were lazy by default, but this is a very big breaking change so I'm not sure we can consider doing that.
For information, TFDS does lazy map by default, and has an additional `.cache()` method.
## Opinions ?
I'd love to gather some opinions about this here. If the two APIs are more aligned it would be awesome for the examples in `transformers`, and it would create a satisfactory experience for users that want to switch from one mode to the other.
cc @mariosasko @albertvillanova @thomwolf @patrickvonplaten @sgugger | 105 | Align the Dataset and IterableDataset processing API
## Intro
Currently the two classes have two distinct API for processing:
### The `.map()` method
Both have those parameters in common: function, batched, batch_size
- IterableDataset is missing those parameters:
with_indices, with_rank, input_columns, drop_last_batch, remove_columns, features, disable_nullable, fn_kwargs, num_proc
- Dataset also has additional parameters that are exclusive, due to caching:
keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, suffix_template, new_fingerprint
- There is also an important difference in terms of behavior:
**Dataset.map adds new columns** (with dict.update)
BUT
**IterableDataset discards previous columns** (it overwrites the dict)
IMO the two methods should have the same behavior. This would be an important breaking change though.
- Dataset.map is eager while IterableDataset.map is lazy
### The `.shuffle()` method
- Both have an optional seed parameter, but IterableDataset requires a mandatory parameter buffer_size to control the size of the local buffer used for approximate shuffling.
- IterableDataset is missing the parameter generator
- Also Dataset has exclusive parameters due to caching: keep_in_memory, load_from_cache_file, indices_cache_file_name, writer_batch_size, new_fingerprint
### The `.with_format()` method
- IterableDataset only supports "torch" (it misses tf, jax, pandas, arrow) and is missing the parameters: columns, output_all_columns and format_kwargs
- other methods like `set_format`, `reset_format` or `formatted_as` are also missing
### Other methods
- Both have the same `remove_columns` method
- IterableDataset is missing: cast, cast_column, filter, rename_column, rename_columns, class_encode_column, flatten, prepare_for_task, train_test_split, shard
- Some other methods are missing but we can discuss them: set_transform, formatted_as, with_transform
- And others don't really make sense for an iterable dataset: select, sort, add_column, add_item
- Dataset is missing skip and take, that IterableDataset implements.
## Questions
I think it would be nice to be able to switch between streaming and regular dataset easily, without changing the processing code significantly.
1. What should be aligned and what shouldn't between those two APIs ?
IMO the minimum is to align the main processing methods.
It would mean aligning breaking the current `Iterable.map` to have the same behavior as `Dataset.map` (add columns with dict.update), and add multiprocessing as well as the missing parameters.
It would also mean implementing the missing methods: cast, cast_column, filter, rename_column, rename_columns, class_encode_column, flatten, prepare_for_task, train_test_split, shard
2. What are the breaking changes for IterableDataset ?
The main breaking change would be the change of behavior of `IterableDataset.map`, because currently it discards all the previous columns instead of keeping them.
3. Shall we also do some changes for regular datasets ?
I agree the simplest would be to have the exact same methods for both Dataset and IterableDataset. However this is probably not a good idea because it would prevent users from using the best benefits of them. That's why we can keep some aspects of regular datasets as they are:
- keep the eager Dataset.map with caching
- keep the with_transform method for lazy processing
- keep Dataset.select (it could also be added to IterableDataset even though it's not recommended)
We could have a completely aligned `map` method if both methods were lazy by default, but this is a very big breaking change so I'm not sure we can consider doing that.
For information, TFDS does lazy map by default, and has an additional `.cache()` method.
## Opinions ?
I'd love to gather some opinions about this here. If the two APIs are more aligned it would be awesome for the examples in `transformers`, and it would create a satisfactory experience for users that want to switch from one mode to the other.
cc @mariosasko @albertvillanova @thomwolf @patrickvonplaten @sgugger
> If I understand this part correctly, the idea would be for Dataset.map to behave similarly to Dataset.with_transform (lazy processing) and to have an option to cache processed data (with .cache()). This idea is really nice because it can also be applied to IterableDataset to fix #3142 (again we get the aligned APIs). However, this change would break a lot of things, so I'm still not sure if this is a step in the right direction (maybe it's OK for Datasets 2.0?)
Yea this is too big of a change in my opinion. Anyway it's fine as it is right now with streaming=lazy and regular=eager. | [
-0.3938247263,
0.0599105097,
-0.1768295169,
0.1296566725,
0.1461639255,
0.1594101638,
0.1987354755,
0.4363477528,
-0.1442689151,
0.1145086735,
-0.1134143472,
0.4282385409,
-0.004529018,
0.0938546732,
-0.1481654942,
-0.2814331353,
0.2069459409,
0.2346381545,
-0.2922790945,
-0.0827013031,
-0.3709232807,
0.0790471435,
-0.3790383041,
-0.1493100673,
0.170381248,
-0.3876644671,
-0.25459975,
-0.0112901703,
-0.1872618049,
-0.1664619297,
0.25650841,
0.3596169353,
-0.0392020307,
0.4749002159,
-0.0001048881,
-0.189496398,
0.1596276313,
-0.028314041,
-0.1329943091,
0.1643233597,
-0.245006606,
-0.1325974017,
-0.2192605287,
-0.4512743056,
-0.088414453,
-0.4349061847,
-0.008044051,
-0.3300686479,
0.3047149479,
0.172640413,
0.2316041291,
-0.1052304059,
-0.0344250351,
-0.1494503468,
-0.0447011404,
0.158591792,
-0.1470772773,
-0.1915032864,
0.3304655552,
0.2332138717,
-0.1053332686,
0.1240311041,
-0.1286486387,
-0.02746238,
0.2674429715,
-0.0581031404,
-0.2388736904,
-0.2534137964,
0.1762710065,
0.1188536361,
0.4069985747,
-0.3529678285,
-0.4058941007,
-0.4256542027,
-0.0954871699,
-0.4326694608,
0.0464729592,
-0.1677734554,
0.1453318149,
0.0508873872,
-0.2507835925,
0.122688055,
-0.0637237057,
-0.0185686722,
0.1952025145,
0.3103402555,
0.0209804513,
0.1045050398,
-0.2547565401,
-0.024220679,
0.3727327585,
-0.1913315356,
0.0812461004,
0.3966723084,
-0.3184553087,
-0.2795436382,
0.2104090899,
-0.1641948819,
0.0158984009,
0.3784617782,
0.1635190994,
0.1981881261,
0.0959029943,
0.0607292876,
0.2486555576,
0.2446094751,
-0.0309416596,
0.3233133852,
0.0683354661,
0.104280822,
0.0407602899,
0.0161781814,
0.2399730235,
-0.0915141404,
0.2290834635,
0.121813938,
-0.0953623876,
-0.0288374294,
-0.1814334542,
-0.0313318111,
-0.0681091622,
-0.279132843,
-0.1173051447,
0.166688025,
-0.1932288706,
0.3575166762,
-0.21005027,
-0.0021490497,
0.1231017783,
-0.012348365,
-0.2095153332,
0.0819291174,
0.0453538112,
0.0545670055,
0.157973811,
0.0491879694,
0.2179070562,
0.2747003436,
-0.0591200702,
0.3111183643,
0.2509402335,
-0.2835653424,
0.5274523497,
0.0273553655,
0.1089247167,
0.0711828619,
-0.0379658043,
0.1941185445,
-0.1548009515,
0.0839548633,
-0.0352621153,
-0.1624655724,
0.3057820201,
0.3095150888,
-0.0871459544,
-0.1429676116,
-0.1455596834,
0.2704123259,
0.0487675071,
-0.3790198863,
0.0651991963,
-0.179873094,
-0.0584248565,
-0.4877621531,
0.1868191063,
-0.0246840771,
-0.3142235279,
0.0858544186,
-0.037913017,
0.0887040347,
0.376447171,
0.1597224027,
-0.1438839436,
0.2501089275,
-0.2317945361,
0.1334908158,
0.370124191,
-0.1617664099,
-0.2880757451,
0.2121586949,
0.2511653602,
0.429608345,
0.0652671903,
0.0094102472,
0.3817861378,
-0.1547675431,
0.160683915,
0.2267097235,
-0.3918659985,
-0.0274675228,
-0.1209318191,
-0.1214727312,
0.0905162096,
-0.0232880823,
0.21764189,
-0.0295408871,
-0.0291234367,
-0.3070268035,
0.3469239473,
-0.2588120699,
0.0630616769,
0.0952612832,
0.2312033772,
-0.1346115619,
0.0933532193,
-0.3839901984,
-0.4101966619,
0.0963224694,
0.0951941013,
-0.0538193025,
0.2278878391,
-0.2389973551,
-0.1754375398,
-0.2133572102,
-0.1884432584,
-0.2397693545,
0.2273387313,
0.0050578807,
0.1808647811,
-0.3127583563,
-0.2746402919,
0.1080456227,
-0.2515923381,
-0.1921006143,
-0.1730244309,
-0.1847862303,
-0.0187559072,
-0.1123970374,
0.2256552726,
0.3912216127,
-0.0573877729,
-0.192913413,
-0.0026424567,
0.2370887995,
0.1233157292,
-0.0493472591,
-0.0960090384,
0.4840137661,
0.1542468965,
0.3634497225,
-0.2041444033,
-0.1077213213,
0.1557956785,
-0.1402861327,
-0.1875533164,
0.5086090565,
-0.2821324468,
0.2179533541,
0.4013932943,
-0.3300424814,
0.3879389763,
0.1092597321,
-0.0808732808,
-0.0853594542,
-0.1707437485,
-0.0880099535,
0.262590766,
0.0752714649,
-0.2563150525,
0.334820509,
0.5981007814,
0.0390738547,
-0.0901900828,
-0.1499186307,
-0.0563810393,
-0.210679844,
0.1447109729,
0.481634289,
0.4766665995,
0.2772517204,
0.0725311711,
0.0107796667,
-0.0227075107,
0.0103549194,
0.2694106698,
0.2089919746,
0.3263947666,
0.2509996891,
-0.0385280401,
0.2861737609,
-0.1132946238,
-0.4261757135,
-0.0567027554,
0.2981863618,
0.0077270055,
-0.1878189296,
-0.0889780223,
-0.1070023254,
0.0628677458,
-0.1617553085,
0.2058797628,
-0.4961052537,
0.0102989944,
0.0883019716,
-0.2727248967,
0.0921406224,
-0.1139539108,
0.1690764576,
-0.1451888531,
-0.0929238796,
-0.2493962049,
-0.1789161116,
-0.1266287416,
0.2168071419,
0.181276992,
-0.2027794123,
0.5645669103,
-0.026076857,
0.126778841,
-0.1418687701,
-0.3402943909,
0.1850636154,
-0.2053448856,
-0.1176374406,
0.2922479808,
0.0495874323,
0.0383851938,
-0.3684128523,
0.1105410382,
-0.2912330925,
-0.1725311726,
-0.1738808006,
-0.0540844761,
-0.4535257816,
-0.184661746,
-0.5225244761,
0.1136677489,
-0.3995248079,
0.0294724945,
-0.0287335571,
0.2656822503,
0.0647183657,
-0.0686746538,
0.0953060687,
0.2002909034,
0.2508393228,
-0.2875946462,
-0.1995408833,
0.2655699253,
-0.2103496045,
-0.2576856017,
-0.0578578152,
-0.1705086827,
0.5599966645,
0.2715258598,
0.0540114939,
-0.1253504604,
-0.3154040873,
0.2782407105,
0.0463124178,
-0.0059912321,
0.486540854,
0.2683175504,
-0.153807953,
-0.1352544129,
-0.2218643576,
0.0776321366,
0.1649953425,
-0.0860192403,
0.1473940313,
0.4835622907,
0.0046256138,
0.7643153071,
0.0952189937,
-0.0911128074,
0.1420985758,
-0.0413184166,
0.1967849433,
-0.3426159322,
-0.2553687096,
0.1801258624,
-0.0329628326,
-0.1247089803,
0.2014690787,
-0.2172219306,
-0.2758239508,
-0.07115639,
0.1753584892,
-0.3700980246,
-0.262391001,
0.2075195462,
-0.0012074478,
0.2088101059,
0.0408636183,
0.2202389836,
-0.3115622401,
0.1037243828,
0.3095892072,
-0.1034913063,
0.2170984894,
-0.1889564544,
-0.3297433257,
-0.3293831646,
-0.4656160176,
0.3795633912,
0.2243554294,
0.3545791209,
-0.0173508208,
-0.4456827939,
0.0076472098,
-0.0817617998,
0.3973110318,
-0.4162670672,
-0.4276762605,
0.1079173088,
-0.1121569201,
-0.0727535635,
-0.0041441191,
-0.2792299986,
0.2218794972,
0.1647448242,
0.5939705968,
-0.2795187533,
-0.2414465249,
0.1236437634,
0.0514523201,
-0.0127774486,
-0.1447264701,
-0.0570765622,
-0.1820764244,
-0.1943103373,
-0.115191184,
0.1131431907,
0.0748773813,
0.0091232732,
-0.1652210504,
-0.3048882186,
-0.1022565886,
0.2610974908,
0.440731287,
0.2206822783,
-0.0448319577,
0.1253077388,
0.0348342806,
0.2825872004,
0.182136938,
0.1827869266,
-0.299418509,
-0.0917966217,
0.1187268794,
-0.3675478995,
0.1956217736,
0.1522434503,
-0.0662753507,
0.038820494,
-0.1946687698,
0.0004666856,
-0.4489881694,
-0.0836453885,
0.2694931328,
0.0446352363,
-0.4176667035,
-0.7557767034,
0.1402267814,
0.2727515996,
-0.2956458628,
0.4798955619,
0.0339795761,
-0.1434513628,
0.4613711536,
0.1325906068,
0.7459076047,
0.1473956108,
0.0116124079,
0.414219141,
-0.1439040005,
0.0534751341,
0.0181214456,
0.3403147161,
-0.2328066826,
-0.4288156331,
0.021096427,
0.0871841908,
0.1489483714,
0.2966483533,
-0.0704635009,
0.4370461404,
0.1454187483,
0.0537687503,
-0.1373431087,
0.3099332154,
-0.0752967745,
-0.167357564,
-0.2215203792,
0.1695389152,
0.073613584,
-0.1743609905,
-0.0444150716,
0.0159487855,
-0.1583304405,
0.1352563053,
-0.1113559827,
-0.0216035433,
-0.1305423677,
0.1792606413,
-0.1055143997,
-0.1182365939,
0.1261243969,
0.1437497139,
0.1610058546,
-0.1183527708,
-0.0425557382,
0.2407610565,
0.0440976061,
0.3883620501,
0.0886703357,
-0.1736502349,
0.5399495959,
-0.1309777051,
0.1185004413,
0.094690688,
-0.221031785,
-0.291715771,
-0.4185091257,
0.0324573889,
0.3706111014,
-0.4416734576,
-0.271625638,
0.1152307987,
-0.1167008951,
-0.1554003805,
0.1703113616,
-0.1800570786,
0.1504668593,
0.6006763577,
-0.2035085559,
-0.1193844453,
-0.1548911035,
0.1269121617,
0.1272383481,
-0.1046423614,
0.5184613466,
-0.2217818201,
-0.2456699461,
-0.282035768,
-0.3517222703,
0.3917877674,
-0.0399654172,
0.0799717158,
-0.1522025168,
-0.0278037153,
0.1547952741,
0.117503576,
0.3042074144,
-0.0869453102,
-0.236362204,
-0.0933941677,
-0.3473157585,
0.2271448523,
0.2884257734,
0.3429836631,
0.1500588208,
-0.1144856215,
-0.0780164227,
0.1938443631,
-0.42980358,
-0.3451654017,
0.0963940471,
0.1103833616,
0.0775988623,
-0.0034850494,
0.0441721193,
-0.0814908668,
0.1551719755,
-0.1353917718,
-0.1204196364,
-0.2847900987,
-0.0684377253,
0.0730666891,
-0.0330304578,
0.0574141406,
0.0401284918,
-0.0030414388,
-0.3749843538,
-0.403042376,
0.2404549867,
-0.1155770048,
-0.0092633925,
0.2228492051,
0.1906485111,
0.0444738381,
-0.1909020096,
-0.0616414063,
-0.1469374299,
-0.1118150055,
0.0551527925,
0.1870843321,
0.0551497675,
-0.2592665553,
0.3343960643,
0.1731711775,
0.2246255875,
0.0205305759,
0.3800829351,
-0.0412686095,
0.0146619938,
0.4392943382,
0.2582322061,
0.4059662819,
0.0939721465,
-0.228277877,
-0.0008990892,
0.3355579972,
-0.25574404,
0.0994435027,
0.0010900231,
0.0780839473,
0.17342709,
0.0607343018,
-0.0194148272,
-0.058834251,
-0.0736196712,
0.1280210167,
0.5335603952,
-0.5485839248,
0.2280774415,
0.3149157465,
0.1929387599,
0.0203473046,
0.322912991,
-0.0678182766,
0.1141840592,
0.3676504195,
0.0786435381,
0.4667395949,
0.3182158768,
0.1420912594,
0.2005693465,
-0.3031516671,
0.1445685327,
0.2726216912,
-0.0037318878,
0.3984976709,
0.5406652689,
0.2438676208,
0.0165410899,
-0.2205164284,
-0.0303952005,
-0.0565178096,
-0.1739672273,
0.1011653468,
-0.2280927002,
-0.4134572148,
-0.0667382553,
-0.1848126203,
-0.0506394617,
-0.0039083068,
0.4524054527,
-0.1314304471,
-0.0336906835,
-0.2809821069,
0.1701765954,
-0.0557131842,
0.4646828771,
-0.1668409556,
0.0306806732,
0.1583096385,
-0.2752102315,
-0.0351046473,
0.321313113,
0.2923759818,
0.3571781814,
-0.1909562945,
0.0241232868,
0.0205731802,
-0.1383623481,
-0.0740654618,
0.1340501755,
-0.1510371268,
-0.2100837678,
0.2287798375,
0.2750110626,
-0.1631526798,
-0.0885111168,
0.0194071699,
0.1699271351,
-0.0251775533,
0.3678476214,
0.1011236459,
-0.2240391672,
0.2183157653,
0.0719842464,
-0.1648489684,
-0.3703827262,
0.0713655651,
-0.3820591867,
0.1009900123,
-0.2069848776,
0.1372294128,
0.1428149939,
0.2448458672,
0.335786581,
-0.4205283225,
-0.0888740122,
-0.1441642493,
-0.488967061,
-0.093561694,
0.3024022579,
0.0438535735,
0.0451669693,
0.3202670813,
0.0613437071,
-0.2147625387,
0.2450206131,
-0.1699800193,
0.0172031205,
0.3157087266,
-0.4452907145,
0.0882449299,
-0.1555569023,
-0.2211295068,
0.0565795414,
-0.3819115162,
0.063455984,
-0.0150508089,
0.1577458233,
-0.1588950008,
0.059793666,
0.3827983141,
-0.2145563066,
0.2025450319,
0.2901981473,
-0.0085876482,
-0.2942786217,
0.0616883747,
-0.00181214,
0.2401493788,
-0.3151827753,
0.5031018257,
-0.0215960406,
0.1763950884,
0.1234778315,
-0.1240508929,
-0.0559715852,
0.1100693643,
-0.0035631736,
-0.0541434921,
-0.3359680474,
0.3081209362,
-0.0349041745,
0.1504846066,
0.010142046,
0.3293340206,
0.0806157738,
0.0899241492,
-0.3726038039,
-0.4050135612,
0.2532756925,
-0.4581846297,
-0.2800023556,
-0.0918834582,
0.0123291416,
0.0038931004,
0.1220795885,
-0.3755329847,
-0.2388033867,
0.2589737773,
-0.2083823979,
-0.0017374012,
0.3746935427,
-0.040475294,
0.0620433576,
-0.0093390634,
0.3484624922,
0.0814217031,
-0.4091294706,
-0.139594838,
-0.1869113296
] |
https://github.com/huggingface/datasets/issues/3444 | Align the Dataset and IterableDataset processing API | Yes indeed, thanks. I added it to the list of methods to align in the first post | ## Intro
Currently the two classes have two distinct API for processing:
### The `.map()` method
Both have those parameters in common: function, batched, batch_size
- IterableDataset is missing those parameters:
with_indices, with_rank, input_columns, drop_last_batch, remove_columns, features, disable_nullable, fn_kwargs, num_proc
- Dataset also has additional parameters that are exclusive, due to caching:
keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, suffix_template, new_fingerprint
- There is also an important difference in terms of behavior:
**Dataset.map adds new columns** (with dict.update)
BUT
**IterableDataset discards previous columns** (it overwrites the dict)
IMO the two methods should have the same behavior. This would be an important breaking change though.
- Dataset.map is eager while IterableDataset.map is lazy
### The `.shuffle()` method
- Both have an optional seed parameter, but IterableDataset requires a mandatory parameter buffer_size to control the size of the local buffer used for approximate shuffling.
- IterableDataset is missing the parameter generator
- Also Dataset has exclusive parameters due to caching: keep_in_memory, load_from_cache_file, indices_cache_file_name, writer_batch_size, new_fingerprint
### The `.with_format()` method
- IterableDataset only supports "torch" (it misses tf, jax, pandas, arrow) and is missing the parameters: columns, output_all_columns and format_kwargs
- other methods like `set_format`, `reset_format` or `formatted_as` are also missing
### Other methods
- Both have the same `remove_columns` method
- IterableDataset is missing: cast, cast_column, filter, rename_column, rename_columns, class_encode_column, flatten, prepare_for_task, train_test_split, shard
- Some other methods are missing but we can discuss them: set_transform, formatted_as, with_transform
- And others don't really make sense for an iterable dataset: select, sort, add_column, add_item
- Dataset is missing skip and take, that IterableDataset implements.
## Questions
I think it would be nice to be able to switch between streaming and regular dataset easily, without changing the processing code significantly.
1. What should be aligned and what shouldn't between those two APIs ?
IMO the minimum is to align the main processing methods.
It would mean aligning breaking the current `Iterable.map` to have the same behavior as `Dataset.map` (add columns with dict.update), and add multiprocessing as well as the missing parameters.
It would also mean implementing the missing methods: cast, cast_column, filter, rename_column, rename_columns, class_encode_column, flatten, prepare_for_task, train_test_split, shard
2. What are the breaking changes for IterableDataset ?
The main breaking change would be the change of behavior of `IterableDataset.map`, because currently it discards all the previous columns instead of keeping them.
3. Shall we also do some changes for regular datasets ?
I agree the simplest would be to have the exact same methods for both Dataset and IterableDataset. However this is probably not a good idea because it would prevent users from using the best benefits of them. That's why we can keep some aspects of regular datasets as they are:
- keep the eager Dataset.map with caching
- keep the with_transform method for lazy processing
- keep Dataset.select (it could also be added to IterableDataset even though it's not recommended)
We could have a completely aligned `map` method if both methods were lazy by default, but this is a very big breaking change so I'm not sure we can consider doing that.
For information, TFDS does lazy map by default, and has an additional `.cache()` method.
## Opinions ?
I'd love to gather some opinions about this here. If the two APIs are more aligned it would be awesome for the examples in `transformers`, and it would create a satisfactory experience for users that want to switch from one mode to the other.
cc @mariosasko @albertvillanova @thomwolf @patrickvonplaten @sgugger | 17 | Align the Dataset and IterableDataset processing API
## Intro
Currently the two classes have two distinct API for processing:
### The `.map()` method
Both have those parameters in common: function, batched, batch_size
- IterableDataset is missing those parameters:
with_indices, with_rank, input_columns, drop_last_batch, remove_columns, features, disable_nullable, fn_kwargs, num_proc
- Dataset also has additional parameters that are exclusive, due to caching:
keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, suffix_template, new_fingerprint
- There is also an important difference in terms of behavior:
**Dataset.map adds new columns** (with dict.update)
BUT
**IterableDataset discards previous columns** (it overwrites the dict)
IMO the two methods should have the same behavior. This would be an important breaking change though.
- Dataset.map is eager while IterableDataset.map is lazy
### The `.shuffle()` method
- Both have an optional seed parameter, but IterableDataset requires a mandatory parameter buffer_size to control the size of the local buffer used for approximate shuffling.
- IterableDataset is missing the parameter generator
- Also Dataset has exclusive parameters due to caching: keep_in_memory, load_from_cache_file, indices_cache_file_name, writer_batch_size, new_fingerprint
### The `.with_format()` method
- IterableDataset only supports "torch" (it misses tf, jax, pandas, arrow) and is missing the parameters: columns, output_all_columns and format_kwargs
- other methods like `set_format`, `reset_format` or `formatted_as` are also missing
### Other methods
- Both have the same `remove_columns` method
- IterableDataset is missing: cast, cast_column, filter, rename_column, rename_columns, class_encode_column, flatten, prepare_for_task, train_test_split, shard
- Some other methods are missing but we can discuss them: set_transform, formatted_as, with_transform
- And others don't really make sense for an iterable dataset: select, sort, add_column, add_item
- Dataset is missing skip and take, that IterableDataset implements.
## Questions
I think it would be nice to be able to switch between streaming and regular dataset easily, without changing the processing code significantly.
1. What should be aligned and what shouldn't between those two APIs ?
IMO the minimum is to align the main processing methods.
It would mean aligning breaking the current `Iterable.map` to have the same behavior as `Dataset.map` (add columns with dict.update), and add multiprocessing as well as the missing parameters.
It would also mean implementing the missing methods: cast, cast_column, filter, rename_column, rename_columns, class_encode_column, flatten, prepare_for_task, train_test_split, shard
2. What are the breaking changes for IterableDataset ?
The main breaking change would be the change of behavior of `IterableDataset.map`, because currently it discards all the previous columns instead of keeping them.
3. Shall we also do some changes for regular datasets ?
I agree the simplest would be to have the exact same methods for both Dataset and IterableDataset. However this is probably not a good idea because it would prevent users from using the best benefits of them. That's why we can keep some aspects of regular datasets as they are:
- keep the eager Dataset.map with caching
- keep the with_transform method for lazy processing
- keep Dataset.select (it could also be added to IterableDataset even though it's not recommended)
We could have a completely aligned `map` method if both methods were lazy by default, but this is a very big breaking change so I'm not sure we can consider doing that.
For information, TFDS does lazy map by default, and has an additional `.cache()` method.
## Opinions ?
I'd love to gather some opinions about this here. If the two APIs are more aligned it would be awesome for the examples in `transformers`, and it would create a satisfactory experience for users that want to switch from one mode to the other.
cc @mariosasko @albertvillanova @thomwolf @patrickvonplaten @sgugger
Yes indeed, thanks. I added it to the list of methods to align in the first post | [
-0.3938247263,
0.0599105097,
-0.1768295169,
0.1296566725,
0.1461639255,
0.1594101638,
0.1987354755,
0.4363477528,
-0.1442689151,
0.1145086735,
-0.1134143472,
0.4282385409,
-0.004529018,
0.0938546732,
-0.1481654942,
-0.2814331353,
0.2069459409,
0.2346381545,
-0.2922790945,
-0.0827013031,
-0.3709232807,
0.0790471435,
-0.3790383041,
-0.1493100673,
0.170381248,
-0.3876644671,
-0.25459975,
-0.0112901703,
-0.1872618049,
-0.1664619297,
0.25650841,
0.3596169353,
-0.0392020307,
0.4749002159,
-0.0001048881,
-0.189496398,
0.1596276313,
-0.028314041,
-0.1329943091,
0.1643233597,
-0.245006606,
-0.1325974017,
-0.2192605287,
-0.4512743056,
-0.088414453,
-0.4349061847,
-0.008044051,
-0.3300686479,
0.3047149479,
0.172640413,
0.2316041291,
-0.1052304059,
-0.0344250351,
-0.1494503468,
-0.0447011404,
0.158591792,
-0.1470772773,
-0.1915032864,
0.3304655552,
0.2332138717,
-0.1053332686,
0.1240311041,
-0.1286486387,
-0.02746238,
0.2674429715,
-0.0581031404,
-0.2388736904,
-0.2534137964,
0.1762710065,
0.1188536361,
0.4069985747,
-0.3529678285,
-0.4058941007,
-0.4256542027,
-0.0954871699,
-0.4326694608,
0.0464729592,
-0.1677734554,
0.1453318149,
0.0508873872,
-0.2507835925,
0.122688055,
-0.0637237057,
-0.0185686722,
0.1952025145,
0.3103402555,
0.0209804513,
0.1045050398,
-0.2547565401,
-0.024220679,
0.3727327585,
-0.1913315356,
0.0812461004,
0.3966723084,
-0.3184553087,
-0.2795436382,
0.2104090899,
-0.1641948819,
0.0158984009,
0.3784617782,
0.1635190994,
0.1981881261,
0.0959029943,
0.0607292876,
0.2486555576,
0.2446094751,
-0.0309416596,
0.3233133852,
0.0683354661,
0.104280822,
0.0407602899,
0.0161781814,
0.2399730235,
-0.0915141404,
0.2290834635,
0.121813938,
-0.0953623876,
-0.0288374294,
-0.1814334542,
-0.0313318111,
-0.0681091622,
-0.279132843,
-0.1173051447,
0.166688025,
-0.1932288706,
0.3575166762,
-0.21005027,
-0.0021490497,
0.1231017783,
-0.012348365,
-0.2095153332,
0.0819291174,
0.0453538112,
0.0545670055,
0.157973811,
0.0491879694,
0.2179070562,
0.2747003436,
-0.0591200702,
0.3111183643,
0.2509402335,
-0.2835653424,
0.5274523497,
0.0273553655,
0.1089247167,
0.0711828619,
-0.0379658043,
0.1941185445,
-0.1548009515,
0.0839548633,
-0.0352621153,
-0.1624655724,
0.3057820201,
0.3095150888,
-0.0871459544,
-0.1429676116,
-0.1455596834,
0.2704123259,
0.0487675071,
-0.3790198863,
0.0651991963,
-0.179873094,
-0.0584248565,
-0.4877621531,
0.1868191063,
-0.0246840771,
-0.3142235279,
0.0858544186,
-0.037913017,
0.0887040347,
0.376447171,
0.1597224027,
-0.1438839436,
0.2501089275,
-0.2317945361,
0.1334908158,
0.370124191,
-0.1617664099,
-0.2880757451,
0.2121586949,
0.2511653602,
0.429608345,
0.0652671903,
0.0094102472,
0.3817861378,
-0.1547675431,
0.160683915,
0.2267097235,
-0.3918659985,
-0.0274675228,
-0.1209318191,
-0.1214727312,
0.0905162096,
-0.0232880823,
0.21764189,
-0.0295408871,
-0.0291234367,
-0.3070268035,
0.3469239473,
-0.2588120699,
0.0630616769,
0.0952612832,
0.2312033772,
-0.1346115619,
0.0933532193,
-0.3839901984,
-0.4101966619,
0.0963224694,
0.0951941013,
-0.0538193025,
0.2278878391,
-0.2389973551,
-0.1754375398,
-0.2133572102,
-0.1884432584,
-0.2397693545,
0.2273387313,
0.0050578807,
0.1808647811,
-0.3127583563,
-0.2746402919,
0.1080456227,
-0.2515923381,
-0.1921006143,
-0.1730244309,
-0.1847862303,
-0.0187559072,
-0.1123970374,
0.2256552726,
0.3912216127,
-0.0573877729,
-0.192913413,
-0.0026424567,
0.2370887995,
0.1233157292,
-0.0493472591,
-0.0960090384,
0.4840137661,
0.1542468965,
0.3634497225,
-0.2041444033,
-0.1077213213,
0.1557956785,
-0.1402861327,
-0.1875533164,
0.5086090565,
-0.2821324468,
0.2179533541,
0.4013932943,
-0.3300424814,
0.3879389763,
0.1092597321,
-0.0808732808,
-0.0853594542,
-0.1707437485,
-0.0880099535,
0.262590766,
0.0752714649,
-0.2563150525,
0.334820509,
0.5981007814,
0.0390738547,
-0.0901900828,
-0.1499186307,
-0.0563810393,
-0.210679844,
0.1447109729,
0.481634289,
0.4766665995,
0.2772517204,
0.0725311711,
0.0107796667,
-0.0227075107,
0.0103549194,
0.2694106698,
0.2089919746,
0.3263947666,
0.2509996891,
-0.0385280401,
0.2861737609,
-0.1132946238,
-0.4261757135,
-0.0567027554,
0.2981863618,
0.0077270055,
-0.1878189296,
-0.0889780223,
-0.1070023254,
0.0628677458,
-0.1617553085,
0.2058797628,
-0.4961052537,
0.0102989944,
0.0883019716,
-0.2727248967,
0.0921406224,
-0.1139539108,
0.1690764576,
-0.1451888531,
-0.0929238796,
-0.2493962049,
-0.1789161116,
-0.1266287416,
0.2168071419,
0.181276992,
-0.2027794123,
0.5645669103,
-0.026076857,
0.126778841,
-0.1418687701,
-0.3402943909,
0.1850636154,
-0.2053448856,
-0.1176374406,
0.2922479808,
0.0495874323,
0.0383851938,
-0.3684128523,
0.1105410382,
-0.2912330925,
-0.1725311726,
-0.1738808006,
-0.0540844761,
-0.4535257816,
-0.184661746,
-0.5225244761,
0.1136677489,
-0.3995248079,
0.0294724945,
-0.0287335571,
0.2656822503,
0.0647183657,
-0.0686746538,
0.0953060687,
0.2002909034,
0.2508393228,
-0.2875946462,
-0.1995408833,
0.2655699253,
-0.2103496045,
-0.2576856017,
-0.0578578152,
-0.1705086827,
0.5599966645,
0.2715258598,
0.0540114939,
-0.1253504604,
-0.3154040873,
0.2782407105,
0.0463124178,
-0.0059912321,
0.486540854,
0.2683175504,
-0.153807953,
-0.1352544129,
-0.2218643576,
0.0776321366,
0.1649953425,
-0.0860192403,
0.1473940313,
0.4835622907,
0.0046256138,
0.7643153071,
0.0952189937,
-0.0911128074,
0.1420985758,
-0.0413184166,
0.1967849433,
-0.3426159322,
-0.2553687096,
0.1801258624,
-0.0329628326,
-0.1247089803,
0.2014690787,
-0.2172219306,
-0.2758239508,
-0.07115639,
0.1753584892,
-0.3700980246,
-0.262391001,
0.2075195462,
-0.0012074478,
0.2088101059,
0.0408636183,
0.2202389836,
-0.3115622401,
0.1037243828,
0.3095892072,
-0.1034913063,
0.2170984894,
-0.1889564544,
-0.3297433257,
-0.3293831646,
-0.4656160176,
0.3795633912,
0.2243554294,
0.3545791209,
-0.0173508208,
-0.4456827939,
0.0076472098,
-0.0817617998,
0.3973110318,
-0.4162670672,
-0.4276762605,
0.1079173088,
-0.1121569201,
-0.0727535635,
-0.0041441191,
-0.2792299986,
0.2218794972,
0.1647448242,
0.5939705968,
-0.2795187533,
-0.2414465249,
0.1236437634,
0.0514523201,
-0.0127774486,
-0.1447264701,
-0.0570765622,
-0.1820764244,
-0.1943103373,
-0.115191184,
0.1131431907,
0.0748773813,
0.0091232732,
-0.1652210504,
-0.3048882186,
-0.1022565886,
0.2610974908,
0.440731287,
0.2206822783,
-0.0448319577,
0.1253077388,
0.0348342806,
0.2825872004,
0.182136938,
0.1827869266,
-0.299418509,
-0.0917966217,
0.1187268794,
-0.3675478995,
0.1956217736,
0.1522434503,
-0.0662753507,
0.038820494,
-0.1946687698,
0.0004666856,
-0.4489881694,
-0.0836453885,
0.2694931328,
0.0446352363,
-0.4176667035,
-0.7557767034,
0.1402267814,
0.2727515996,
-0.2956458628,
0.4798955619,
0.0339795761,
-0.1434513628,
0.4613711536,
0.1325906068,
0.7459076047,
0.1473956108,
0.0116124079,
0.414219141,
-0.1439040005,
0.0534751341,
0.0181214456,
0.3403147161,
-0.2328066826,
-0.4288156331,
0.021096427,
0.0871841908,
0.1489483714,
0.2966483533,
-0.0704635009,
0.4370461404,
0.1454187483,
0.0537687503,
-0.1373431087,
0.3099332154,
-0.0752967745,
-0.167357564,
-0.2215203792,
0.1695389152,
0.073613584,
-0.1743609905,
-0.0444150716,
0.0159487855,
-0.1583304405,
0.1352563053,
-0.1113559827,
-0.0216035433,
-0.1305423677,
0.1792606413,
-0.1055143997,
-0.1182365939,
0.1261243969,
0.1437497139,
0.1610058546,
-0.1183527708,
-0.0425557382,
0.2407610565,
0.0440976061,
0.3883620501,
0.0886703357,
-0.1736502349,
0.5399495959,
-0.1309777051,
0.1185004413,
0.094690688,
-0.221031785,
-0.291715771,
-0.4185091257,
0.0324573889,
0.3706111014,
-0.4416734576,
-0.271625638,
0.1152307987,
-0.1167008951,
-0.1554003805,
0.1703113616,
-0.1800570786,
0.1504668593,
0.6006763577,
-0.2035085559,
-0.1193844453,
-0.1548911035,
0.1269121617,
0.1272383481,
-0.1046423614,
0.5184613466,
-0.2217818201,
-0.2456699461,
-0.282035768,
-0.3517222703,
0.3917877674,
-0.0399654172,
0.0799717158,
-0.1522025168,
-0.0278037153,
0.1547952741,
0.117503576,
0.3042074144,
-0.0869453102,
-0.236362204,
-0.0933941677,
-0.3473157585,
0.2271448523,
0.2884257734,
0.3429836631,
0.1500588208,
-0.1144856215,
-0.0780164227,
0.1938443631,
-0.42980358,
-0.3451654017,
0.0963940471,
0.1103833616,
0.0775988623,
-0.0034850494,
0.0441721193,
-0.0814908668,
0.1551719755,
-0.1353917718,
-0.1204196364,
-0.2847900987,
-0.0684377253,
0.0730666891,
-0.0330304578,
0.0574141406,
0.0401284918,
-0.0030414388,
-0.3749843538,
-0.403042376,
0.2404549867,
-0.1155770048,
-0.0092633925,
0.2228492051,
0.1906485111,
0.0444738381,
-0.1909020096,
-0.0616414063,
-0.1469374299,
-0.1118150055,
0.0551527925,
0.1870843321,
0.0551497675,
-0.2592665553,
0.3343960643,
0.1731711775,
0.2246255875,
0.0205305759,
0.3800829351,
-0.0412686095,
0.0146619938,
0.4392943382,
0.2582322061,
0.4059662819,
0.0939721465,
-0.228277877,
-0.0008990892,
0.3355579972,
-0.25574404,
0.0994435027,
0.0010900231,
0.0780839473,
0.17342709,
0.0607343018,
-0.0194148272,
-0.058834251,
-0.0736196712,
0.1280210167,
0.5335603952,
-0.5485839248,
0.2280774415,
0.3149157465,
0.1929387599,
0.0203473046,
0.322912991,
-0.0678182766,
0.1141840592,
0.3676504195,
0.0786435381,
0.4667395949,
0.3182158768,
0.1420912594,
0.2005693465,
-0.3031516671,
0.1445685327,
0.2726216912,
-0.0037318878,
0.3984976709,
0.5406652689,
0.2438676208,
0.0165410899,
-0.2205164284,
-0.0303952005,
-0.0565178096,
-0.1739672273,
0.1011653468,
-0.2280927002,
-0.4134572148,
-0.0667382553,
-0.1848126203,
-0.0506394617,
-0.0039083068,
0.4524054527,
-0.1314304471,
-0.0336906835,
-0.2809821069,
0.1701765954,
-0.0557131842,
0.4646828771,
-0.1668409556,
0.0306806732,
0.1583096385,
-0.2752102315,
-0.0351046473,
0.321313113,
0.2923759818,
0.3571781814,
-0.1909562945,
0.0241232868,
0.0205731802,
-0.1383623481,
-0.0740654618,
0.1340501755,
-0.1510371268,
-0.2100837678,
0.2287798375,
0.2750110626,
-0.1631526798,
-0.0885111168,
0.0194071699,
0.1699271351,
-0.0251775533,
0.3678476214,
0.1011236459,
-0.2240391672,
0.2183157653,
0.0719842464,
-0.1648489684,
-0.3703827262,
0.0713655651,
-0.3820591867,
0.1009900123,
-0.2069848776,
0.1372294128,
0.1428149939,
0.2448458672,
0.335786581,
-0.4205283225,
-0.0888740122,
-0.1441642493,
-0.488967061,
-0.093561694,
0.3024022579,
0.0438535735,
0.0451669693,
0.3202670813,
0.0613437071,
-0.2147625387,
0.2450206131,
-0.1699800193,
0.0172031205,
0.3157087266,
-0.4452907145,
0.0882449299,
-0.1555569023,
-0.2211295068,
0.0565795414,
-0.3819115162,
0.063455984,
-0.0150508089,
0.1577458233,
-0.1588950008,
0.059793666,
0.3827983141,
-0.2145563066,
0.2025450319,
0.2901981473,
-0.0085876482,
-0.2942786217,
0.0616883747,
-0.00181214,
0.2401493788,
-0.3151827753,
0.5031018257,
-0.0215960406,
0.1763950884,
0.1234778315,
-0.1240508929,
-0.0559715852,
0.1100693643,
-0.0035631736,
-0.0541434921,
-0.3359680474,
0.3081209362,
-0.0349041745,
0.1504846066,
0.010142046,
0.3293340206,
0.0806157738,
0.0899241492,
-0.3726038039,
-0.4050135612,
0.2532756925,
-0.4581846297,
-0.2800023556,
-0.0918834582,
0.0123291416,
0.0038931004,
0.1220795885,
-0.3755329847,
-0.2388033867,
0.2589737773,
-0.2083823979,
-0.0017374012,
0.3746935427,
-0.040475294,
0.0620433576,
-0.0093390634,
0.3484624922,
0.0814217031,
-0.4091294706,
-0.139594838,
-0.1869113296
] |
https://github.com/huggingface/datasets/issues/3440 | datasets keeps reading from cached files, although I disabled it | Hi ! What version of `datasets` are you using ? Can you also provide the logs you get before it raises the error ? | ## Describe the bug
Hi,
I am trying to avoid dataset library using cached files, I get the following bug when this tried to read the cached files. I tried to do the followings:
```
from datasets import set_caching_enabled
set_caching_enabled(False)
```
also force redownlaod:
```
download_mode='force_redownload'
```
but none worked so far, this is on a cluster and on some of the machines this reads from the cached files, I really appreciate any idea on how to fully remove caching @lhoestq
many thanks
```
File "run_clm.py", line 496, in <module>
main()
File "run_clm.py", line 419, in main
train_result = trainer.train(resume_from_checkpoint=checkpoint)
File "/users/dara/codes/fewshot/debug/fewshot/third_party/trainers/trainer.py", line 943, in train
self._maybe_log_save_evaluate(tr_loss, model, trial, epoch, ignore_keys_for_eval)
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/transformers/trainer.py", line 1445, in _maybe_log_save_evaluate
metrics = self.evaluate(ignore_keys=ignore_keys_for_eval)
File "/users/dara/codes/fewshot/debug/fewshot/third_party/trainers/trainer.py", line 172, in evaluate
output = self.eval_loop(
File "/users/dara/codes/fewshot/debug/fewshot/third_party/trainers/trainer.py", line 241, in eval_loop
metrics = self.compute_pet_metrics(eval_datasets, model, self.extra_info[metric_key_prefix], task=task)
File "/users/dara/codes/fewshot/debug/fewshot/third_party/trainers/trainer.py", line 268, in compute_pet_metrics
centroids = self._compute_per_token_train_centroids(model, task=task)
File "/users/dara/codes/fewshot/debug/fewshot/third_party/trainers/trainer.py", line 353, in _compute_per_token_train_centroids
data = get_label_samples(self.get_per_task_train_dataset(task), label)
File "/users/dara/codes/fewshot/debug/fewshot/third_party/trainers/trainer.py", line 350, in get_label_samples
return dataset.filter(lambda example: int(example['labels']) == label)
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/datasets/arrow_dataset.py", line 470, in wrapper
out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs)
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/datasets/fingerprint.py", line 406, in wrapper
out = func(self, *args, **kwargs)
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/datasets/arrow_dataset.py", line 2519, in filter
indices = self.map(
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/datasets/arrow_dataset.py", line 2036, in map
return self._map_single(
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/datasets/arrow_dataset.py", line 503, in wrapper
out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs)
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/datasets/arrow_dataset.py", line 470, in wrapper
out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs)
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/datasets/fingerprint.py", line 406, in wrapper
out = func(self, *args, **kwargs)
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/datasets/arrow_dataset.py", line 2248, in _map_single
return Dataset.from_file(cache_file_name, info=info, split=self.split)
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/datasets/arrow_dataset.py", line 654, in from_file
return cls(
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/datasets/arrow_dataset.py", line 593, in __init__
self.info.features = self.info.features.reorder_fields_as(inferred_features)
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/datasets/features/features.py", line 1092, in reorder_fields_as
return Features(recursive_reorder(self, other))
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/datasets/features/features.py", line 1081, in recursive_reorder
raise ValueError(f"Keys mismatch: between {source} and {target}" + stack_position)
ValueError: Keys mismatch: between {'indices': Value(dtype='uint64', id=None)} and {'candidates_ids': Sequence(feature=Value(dtype='null', id=None), length=-1, id=None), 'labels': Value(dtype='int64', id=None), 'attention_mask': Sequence(feature=Value(dtype='int8', id=None), length=-1, id=None), 'input_ids': Sequence(feature=Value(dtype='int32', id=None), length=-1, id=None), 'extra_fields': {}, 'task': Value(dtype='string', id=None)}
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version:
- Platform: linux
- Python version: 3.8.12
- PyArrow version: 6.0.1
| 24 | datasets keeps reading from cached files, although I disabled it
## Describe the bug
Hi,
I am trying to avoid dataset library using cached files, I get the following bug when this tried to read the cached files. I tried to do the followings:
```
from datasets import set_caching_enabled
set_caching_enabled(False)
```
also force redownlaod:
```
download_mode='force_redownload'
```
but none worked so far, this is on a cluster and on some of the machines this reads from the cached files, I really appreciate any idea on how to fully remove caching @lhoestq
many thanks
```
File "run_clm.py", line 496, in <module>
main()
File "run_clm.py", line 419, in main
train_result = trainer.train(resume_from_checkpoint=checkpoint)
File "/users/dara/codes/fewshot/debug/fewshot/third_party/trainers/trainer.py", line 943, in train
self._maybe_log_save_evaluate(tr_loss, model, trial, epoch, ignore_keys_for_eval)
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/transformers/trainer.py", line 1445, in _maybe_log_save_evaluate
metrics = self.evaluate(ignore_keys=ignore_keys_for_eval)
File "/users/dara/codes/fewshot/debug/fewshot/third_party/trainers/trainer.py", line 172, in evaluate
output = self.eval_loop(
File "/users/dara/codes/fewshot/debug/fewshot/third_party/trainers/trainer.py", line 241, in eval_loop
metrics = self.compute_pet_metrics(eval_datasets, model, self.extra_info[metric_key_prefix], task=task)
File "/users/dara/codes/fewshot/debug/fewshot/third_party/trainers/trainer.py", line 268, in compute_pet_metrics
centroids = self._compute_per_token_train_centroids(model, task=task)
File "/users/dara/codes/fewshot/debug/fewshot/third_party/trainers/trainer.py", line 353, in _compute_per_token_train_centroids
data = get_label_samples(self.get_per_task_train_dataset(task), label)
File "/users/dara/codes/fewshot/debug/fewshot/third_party/trainers/trainer.py", line 350, in get_label_samples
return dataset.filter(lambda example: int(example['labels']) == label)
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/datasets/arrow_dataset.py", line 470, in wrapper
out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs)
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/datasets/fingerprint.py", line 406, in wrapper
out = func(self, *args, **kwargs)
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/datasets/arrow_dataset.py", line 2519, in filter
indices = self.map(
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/datasets/arrow_dataset.py", line 2036, in map
return self._map_single(
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/datasets/arrow_dataset.py", line 503, in wrapper
out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs)
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/datasets/arrow_dataset.py", line 470, in wrapper
out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs)
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/datasets/fingerprint.py", line 406, in wrapper
out = func(self, *args, **kwargs)
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/datasets/arrow_dataset.py", line 2248, in _map_single
return Dataset.from_file(cache_file_name, info=info, split=self.split)
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/datasets/arrow_dataset.py", line 654, in from_file
return cls(
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/datasets/arrow_dataset.py", line 593, in __init__
self.info.features = self.info.features.reorder_fields_as(inferred_features)
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/datasets/features/features.py", line 1092, in reorder_fields_as
return Features(recursive_reorder(self, other))
File "/users/dara/conda/envs/multisuccess/lib/python3.8/site-packages/datasets/features/features.py", line 1081, in recursive_reorder
raise ValueError(f"Keys mismatch: between {source} and {target}" + stack_position)
ValueError: Keys mismatch: between {'indices': Value(dtype='uint64', id=None)} and {'candidates_ids': Sequence(feature=Value(dtype='null', id=None), length=-1, id=None), 'labels': Value(dtype='int64', id=None), 'attention_mask': Sequence(feature=Value(dtype='int8', id=None), length=-1, id=None), 'input_ids': Sequence(feature=Value(dtype='int32', id=None), length=-1, id=None), 'extra_fields': {}, 'task': Value(dtype='string', id=None)}
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version:
- Platform: linux
- Python version: 3.8.12
- PyArrow version: 6.0.1
Hi ! What version of `datasets` are you using ? Can you also provide the logs you get before it raises the error ? | [
-0.134791404,
0.0252022874,
0.0009025426,
0.5154468417,
0.4938995242,
0.2646331489,
0.057791438,
0.325937748,
0.0154794231,
-0.0155137088,
-0.2143104076,
0.2182268202,
-0.085602425,
-0.3043366373,
-0.1368986666,
0.2771289349,
0.1166641265,
0.0681685731,
0.0084792469,
-0.0709792972,
-0.3026717305,
-0.0255560074,
-0.2052818984,
-0.1392595917,
-0.348295331,
-0.32141307,
0.1381623894,
0.0075002215,
-0.2036435902,
-0.2740697563,
0.4375573695,
0.0028206951,
0.0893771127,
0.5267435312,
-0.0001160746,
0.0314320885,
0.1130924746,
0.0364635438,
-0.0466689467,
-0.047641512,
-0.0376653895,
-0.0472617187,
0.3255212903,
-0.2387638688,
-0.1338167191,
-0.1992305815,
-0.1100827977,
-0.7465627789,
0.4422792196,
0.4422798157,
0.2044254988,
-0.0111772576,
-0.2539697289,
0.3288720548,
0.2135253847,
-0.2099317312,
-0.2228216529,
0.1832698584,
0.2086633742,
-0.033980839,
-0.4124691188,
0.4314963818,
-0.4581138492,
0.2001527995,
0.3858487606,
-0.0813777149,
-0.1843183786,
-0.3547951877,
0.1968846023,
-0.0773099214,
0.6554117799,
-0.5104454756,
-0.2234265059,
-0.3071141541,
-0.1280069053,
-0.2817064226,
0.322357446,
0.2355410606,
-0.0164910015,
0.2743012011,
-0.4476619959,
-0.2035814673,
-0.2682554722,
0.0064549507,
0.1146932468,
-0.1818071604,
-0.0806555748,
-0.0062083188,
0.2816998363,
0.1406171918,
0.7125241756,
-0.1121701151,
-0.1603090316,
0.1727027297,
-0.4422088861,
0.0334234089,
-0.0894004852,
0.482113421,
0.0502712131,
0.2645428479,
-0.0537974238,
0.0786593258,
-0.151637584,
0.0134789879,
0.1726575047,
0.3093885779,
-0.1447682232,
0.4031310081,
0.1806670278,
0.1639500707,
-0.2777961195,
-0.0618467107,
0.2777053416,
-0.1662117988,
0.6028595567,
-0.0185194984,
0.1513294429,
-0.4025506377,
-0.0992431119,
0.0622788072,
-0.1391213089,
0.001798103,
0.1857324839,
0.2613671124,
-0.1333520263,
0.2755845785,
-0.0062638973,
0.0802932531,
-0.3829362094,
-0.1316264123,
-0.1894789934,
0.1735137105,
-0.1626889259,
0.1001404598,
0.3576357961,
-0.3488932848,
0.1726446301,
0.3647530675,
0.0780154243,
-0.2128511667,
0.3054154813,
-0.3893027902,
0.3533241153,
0.1857803464,
-0.2119144648,
0.3226234615,
0.3489102423,
-0.2285856903,
-0.0369242877,
0.2101987898,
-0.5204888582,
-0.128018409,
0.138724491,
0.1730235517,
-0.3193347156,
0.0718141645,
-0.2431096435,
-0.024638664,
0.399312228,
-0.0198423881,
0.188506037,
-0.1070010662,
-0.2108373791,
-0.2313872129,
0.0495155044,
0.4662142098,
-0.2028482705,
0.1330049187,
-0.0383603834,
-0.079802759,
-0.0053066737,
0.1470536888,
-0.1381856501,
0.1418816,
-0.3478868604,
-0.2191425562,
0.248132959,
-0.5889915824,
-0.8006488085,
0.2653118074,
0.2215210199,
0.2435998321,
0.0362367481,
0.3255743086,
-0.0917175487,
0.0562624484,
-0.1296573281,
0.0400859341,
0.1390340626,
-0.0191246774,
-0.1640002429,
-0.3946738243,
0.1176612526,
0.1274541169,
0.1215947121,
0.2789894938,
0.2014136761,
0.0965598226,
0.2482377291,
-0.0630897954,
0.0736224279,
0.3326494694,
0.1358740479,
0.0082370769,
0.2744852901,
-0.2027184367,
-0.4298445284,
0.213818118,
-0.0000378609,
-0.4653173089,
-0.3672341108,
-0.3241564035,
-0.0096511878,
-0.1919164807,
-0.4852227271,
-0.0810116604,
0.0685175061,
-0.1516574323,
0.0228847582,
0.0424296111,
-0.2088163942,
0.5369132757,
-0.1694108695,
0.1113306209,
-0.3570794761,
-0.1020251289,
0.0235208552,
0.0227096882,
-0.2411289513,
0.0505348593,
0.280775696,
0.0284303855,
-0.2509103417,
0.3418459892,
0.2283070087,
0.198672846,
-0.1491059959,
0.3588514328,
0.2382886708,
-0.1213663369,
-0.0666476041,
0.0512813739,
0.1486517638,
-0.0570433736,
-0.0710929111,
0.1589007229,
-0.1821679473,
0.1149348617,
-0.1578964889,
-0.0836705267,
0.1419345289,
-0.1440802366,
0.1643739641,
-0.0298305545,
0.1915691048,
-0.0289210677,
0.4275229573,
0.2735752463,
-0.1063180864,
-0.061034102,
0.4289520085,
0.2639598846,
-0.0853557736,
-0.0585679412,
-0.0546098053,
-0.1435466111,
0.0495653264,
0.5101735592,
0.2027992457,
0.0540245101,
0.2070150822,
0.3291209638,
0.1233242452,
-0.0752893165,
0.0654141381,
0.1733806282,
0.031477116,
0.1283111721,
0.0793275088,
-0.0276675411,
-0.2090269625,
0.127644673,
-0.0255700201,
0.3077681959,
-0.3078734577,
0.3045542836,
-0.6040995717,
-0.3373568654,
-0.1494442075,
0.200871557,
-0.1669394672,
-0.1591370702,
-0.1292672455,
0.406545341,
0.3137303293,
0.0997062251,
-0.3969267011,
0.1712883264,
0.0253105536,
-0.378103137,
-0.1359472871,
-0.0190087426,
-0.2054716349,
-0.0227104966,
0.3963700533,
-0.2685647905,
0.1744906306,
-0.0971134529,
-0.0605773702,
-0.3700220287,
0.051159922,
-0.0430152528,
0.131077379,
0.3719232678,
-0.0071011055,
-0.096382089,
-0.3381530941,
0.0884459689,
-0.1145653948,
-0.1268668324,
0.091413781,
-0.0404213443,
-0.0237785112,
0.3179362416,
-0.1407574862,
-0.4279046059,
-0.1378014237,
-0.1757679582,
-0.0294477716,
0.0090285148,
0.0518950485,
0.4343233407,
-0.0716579854,
0.1872651428,
0.1484446526,
0.1082531735,
-0.083315894,
-0.5835840106,
0.3847768009,
0.0708785728,
-0.2034754306,
0.1745608598,
0.0651162937,
0.2045127153,
0.3564768732,
-0.6828066707,
-0.3330178261,
-0.1190028712,
0.0513893291,
-0.2413743585,
-0.0784251541,
0.1261018217,
0.0544722788,
0.129462406,
-0.215983063,
0.196952045,
0.1558251977,
-0.3336177766,
0.1633084863,
0.0664345175,
0.0745892748,
0.2744604349,
0.6522011757,
0.2870260179,
0.1414099634,
0.3819146156,
0.0016724457,
0.5076668859,
-0.0276621319,
-0.3993758857,
-0.1943572164,
-0.109675698,
-0.2254601866,
0.1166374162,
0.0560063459,
-0.0246816743,
-0.1047056317,
-0.0227341522,
-0.0623612888,
-0.1511332393,
-0.1468775123,
-0.390878886,
0.1160012707,
0.1268462241,
0.2441411465,
-0.0013382344,
-0.4342244267,
-0.0588000156,
0.0898897871,
0.0825620443,
0.1988687962,
-0.2553462684,
-0.176561594,
-0.1378846616,
0.2281266451,
0.0518587008,
0.2835312784,
-0.0996269435,
0.1695991755,
0.2192079723,
0.1101902649,
0.5520722866,
-0.1663531661,
0.0709269941,
0.024951566,
-0.0113203526,
-0.0520148873,
0.0291597974,
-0.0085807471,
0.4014029503,
-0.1068227366,
0.3156183064,
0.1102736816,
-0.148681879,
-0.2751522958,
0.2791404128,
-0.0248108692,
-0.2352975607,
-0.2115869224,
-0.2593565285,
-0.0725789368,
0.0832059309,
0.117980279,
0.0860334411,
-0.1773768663,
-0.114359349,
-0.1533456594,
0.2051085681,
0.1178754792,
-0.1021509394,
0.2973546088,
-0.0652014017,
0.1285987496,
0.2409387082,
0.1910720915,
0.2554965019,
0.4197859764,
-0.1137322411,
-0.2731846571,
-0.1763150841,
-0.0805273429,
-0.0248648915,
-0.0669802204,
-0.3691058159,
0.2432824969,
0.1605737954,
-0.2770901024,
0.0347594991,
-0.0497940369,
0.0972130969,
0.049663797,
-0.424544245,
-0.6316391826,
0.4190454185,
0.3045807183,
0.0081860563,
0.3562624753,
-0.3668882251,
-0.3287132382,
0.0961378291,
0.002473542,
0.6574751139,
0.0300528593,
0.0049576284,
0.1125439107,
0.0544150174,
0.3930119276,
-0.5218994021,
0.3046451509,
-0.3042566478,
-0.4631273448,
-0.2019228935,
-0.0858644843,
0.2060091645,
0.1615210623,
-0.0452830531,
0.4331934452,
-0.2647492588,
0.0281740855,
-0.0705811009,
0.079282701,
-0.2485657185,
-0.0534678437,
-0.0044919737,
0.1198784709,
-0.2538807392,
0.0068452409,
0.0795007497,
-0.0438417234,
0.062097162,
-0.0154330647,
0.0784981549,
0.0685067251,
-0.2393893152,
0.1746146381,
-0.1204020381,
-0.1453877389,
0.257492274,
0.4543972015,
0.3002947271,
0.0526842847,
-0.3081891537,
0.1907516867,
0.21941185,
0.2534482777,
0.1369719952,
0.0236623958,
0.230869934,
0.1184643954,
-0.212581709,
-0.0636716187,
-0.1239025816,
-0.24892582,
0.2821977437,
0.0618180409,
0.3056772053,
-0.255769074,
-0.1287043095,
-0.1908764243,
0.1213424578,
-0.0687278435,
0.1271541268,
0.0366886258,
0.0609228089,
0.4310394824,
-0.294018805,
-0.4138998091,
0.0357549414,
0.506496489,
0.3554610908,
-0.3040548563,
0.3512309492,
-0.0590363033,
-0.3172995746,
-0.1793729514,
0.0324653573,
-0.1416352242,
-0.2214342505,
0.0847590938,
-0.0138141094,
0.383431524,
0.0336732753,
-0.2299469411,
-0.1586364061,
0.0198897813,
-0.0860384256,
-0.2967455387,
-0.3863810003,
-0.0951275378,
-0.2142587453,
0.0358196385,
0.2288571,
-0.2530404627,
0.1190260872,
-0.0467524529,
-0.2260139436,
0.2313621342,
-0.1944500953,
-0.0276743192,
0.0610524267,
0.1294263154,
-0.0392901003,
-0.0826965421,
-0.0619786046,
0.1599396616,
-0.1796274781,
-0.1650332212,
-0.1122873947,
0.1522652358,
0.0173329413,
-0.1186089292,
-0.0528036915,
-0.4081191719,
-0.1308064163,
-0.1916933805,
-0.0160703212,
0.2838402092,
0.2402589619,
0.2796680629,
-0.0205425788,
-0.0178655591,
-0.1487213969,
-0.0110317068,
-0.2021083534,
-0.1929634213,
0.0638850555,
0.1568104327,
0.0670988262,
-0.0268641915,
-0.3181250989,
-0.0463667437,
0.0356437489,
-0.0454798974,
0.187283814,
-0.278670758,
0.0494371317,
0.525552392,
0.2498692572,
0.1973018795,
-0.2667002082,
-0.1578570753,
0.2348188162,
0.1544656754,
-0.2505806088,
-0.2499798238,
0.4176491201,
-0.0213177223,
-0.1260715723,
0.233415395,
0.3245375156,
-0.1972013563,
0.3462364376,
0.0262117982,
0.7386052608,
-0.4272473454,
0.4117094278,
0.1251026243,
0.1057168245,
-0.2002333701,
0.3396926224,
0.2865657806,
-0.0427418537,
0.5904507041,
-0.1204680577,
0.1303248256,
0.2190086842,
0.0901360884,
-0.3276152909,
-0.6483091712,
-0.0558608584,
0.1784959882,
-0.3428573906,
0.1243221462,
-0.1264890283,
0.3529452682,
0.0406285003,
-0.1802373827,
-0.0573355146,
0.0981605276,
-0.2038969547,
0.147056222,
0.4855539203,
-0.0836677402,
-0.0160011481,
0.0863033235,
-0.0304956175,
0.0290233251,
0.1801701784,
0.050696414,
-0.2791249156,
-0.2303781062,
0.2451778948,
0.1552445292,
0.278863281,
-0.2352053672,
0.1010223106,
-0.1652720571,
0.0975868106,
-0.0501938462,
0.2315779179,
0.1395295858,
0.2028762549,
0.2465294003,
-0.0075035882,
-0.0187212471,
0.0900168121,
-0.0771628991,
0.321965903,
-0.1267392933,
0.0306815393,
0.074513793,
0.0130568016,
-0.0121778268,
0.1135984287,
-0.1161460206,
0.4055129886,
-0.5134980679,
0.048257228,
0.2246146351,
-0.0588571168,
-0.1539872289,
0.0565458089,
-0.2629218698,
0.1327325255,
0.6940327287,
0.0143940384,
0.1934345961,
-0.2888110876,
0.0417878963,
0.023026986,
0.2698503733,
0.361217469,
0.0533477925,
-0.1564626247,
0.0269881338,
-0.8161220551,
0.1464647502,
-0.0073125823,
0.2464925349,
0.1565988511,
-0.0000836531,
-0.2792975605,
-0.0581893139,
0.0121887121,
-0.1338331103,
0.3161815703,
0.1288111061,
-0.1394453496,
-0.0828576386,
-0.0218586139,
0.0441423357,
-0.1246831268,
-0.5205823779,
0.2609215677,
0.0098402128,
0.028924901,
0.0543816686,
-0.151699096,
0.0941016749,
0.1607334614,
0.3281303048,
0.2039524913,
0.1477577239,
0.1539508104,
0.1748634428,
-0.4056674838,
-0.1845772564,
-0.1943687648,
-0.0822167546,
0.0278480221,
0.2128581107,
-0.4784362316,
0.0037557355,
-0.3199614286,
0.3863435388,
0.0858006999,
-0.0279975571,
-0.1598742753,
-0.0399551205,
-0.1412644833,
0.3255360723,
0.0265496131,
0.2884543538,
-0.0144712441,
0.3763434291,
-0.417773962,
-0.2574901879,
0.3212435842,
-0.5280935764,
-0.2193676829,
0.2080870271,
0.3773922026,
0.259752363,
-0.3157711327,
-0.3864001632,
-0.0429439843,
0.527166307,
-0.1613986492,
-0.0660747811,
0.2943634093,
-0.2307702452,
0.3154682517,
-0.011348852,
0.0057109455,
0.1775219589,
-0.1377203315,
0.4448752999,
-0.2505968511
] |
https://github.com/huggingface/datasets/issues/3431 | Unable to resolve any data file after loading once | Hi ! `load_dataset` accepts as input either a local dataset directory or a dataset name from the Hugging Face Hub.
So here you are getting this error the second time because it tries to load the local `wiki_dpr` directory, instead of `wiki_dpr` from the Hub. It doesn't work since it's a **cache** directory, not a **dataset** directory in itself.
To fix that you can use another cache directory like `cache_dir="/data2/whr/lzy/open_domain_data/retrieval/cache"` | when I rerun my program, it occurs this error
" Unable to resolve any data file that matches '['**train*']' at /data2/whr/lzy/open_domain_data/retrieval/wiki_dpr with any supported extension ['csv', 'tsv', 'json', 'jsonl', 'parquet', 'txt', 'zip']", so how could i deal with this problem?
thx.
And below is my code .
![image](https://user-images.githubusercontent.com/84694183/146023446-d75fdec8-65c1-484f-80d8-6c20ff5e994b.png)
| 70 | Unable to resolve any data file after loading once
when I rerun my program, it occurs this error
" Unable to resolve any data file that matches '['**train*']' at /data2/whr/lzy/open_domain_data/retrieval/wiki_dpr with any supported extension ['csv', 'tsv', 'json', 'jsonl', 'parquet', 'txt', 'zip']", so how could i deal with this problem?
thx.
And below is my code .
![image](https://user-images.githubusercontent.com/84694183/146023446-d75fdec8-65c1-484f-80d8-6c20ff5e994b.png)
Hi ! `load_dataset` accepts as input either a local dataset directory or a dataset name from the Hugging Face Hub.
So here you are getting this error the second time because it tries to load the local `wiki_dpr` directory, instead of `wiki_dpr` from the Hub. It doesn't work since it's a **cache** directory, not a **dataset** directory in itself.
To fix that you can use another cache directory like `cache_dir="/data2/whr/lzy/open_domain_data/retrieval/cache"` | [
0.0235010572,
-0.0923303813,
-0.0853217915,
0.5271120667,
0.3798449636,
0.14113383,
0.0799056143,
0.5025756359,
0.2032744288,
0.075701423,
0.1105002686,
-0.0108606387,
0.1759342104,
0.0473020822,
-0.0830672532,
-0.1982478648,
-0.1227090135,
0.2124536932,
0.1570390165,
0.056508258,
-0.0941126943,
0.2072376013,
0.0278491341,
-0.0109031862,
-0.5511704683,
0.0114743365,
-0.1955417991,
0.0679085553,
0.0216842573,
-0.4020966589,
0.5563514233,
0.041772943,
0.4304461479,
0.3836534619,
-0.0001147879,
0.1027838737,
0.1191908494,
-0.014525583,
-0.1031957194,
-0.2323745787,
0.2735649347,
-0.1032646671,
0.2602539659,
-0.4209734499,
-0.2330064774,
0.0823137462,
0.1298931688,
-0.0588665977,
0.8446517587,
0.0390019417,
0.1634757519,
-0.3755128384,
0.0628808662,
-0.1028687209,
0.054622449,
0.1275773495,
0.1820348054,
0.2474460304,
0.2063879967,
-0.1432085335,
-0.0783759356,
0.3664889932,
-0.0231795348,
0.2122309655,
0.2097848356,
0.1975141019,
0.0217422508,
-0.2805301845,
0.3199221492,
0.0206746086,
0.6778357625,
0.0125387898,
-0.0483255312,
-0.0385634974,
-0.0159508493,
-0.1628515422,
0.3767315745,
0.0805789679,
0.0846255943,
0.2639566958,
-0.0626922771,
-0.2750409544,
-0.107895337,
-0.0027287931,
-0.1556402743,
0.2074209005,
0.0134997647,
0.2024933845,
0.3164549768,
-0.1212428361,
0.0737419575,
0.248839736,
-0.2387193441,
0.2314709872,
-0.5613319874,
0.0437604822,
-0.0487954095,
0.0177740175,
0.1197194979,
0.0875319764,
0.1650348753,
-0.006352881,
-0.0101500414,
-0.0565263033,
0.5378554463,
0.428306818,
0.077369906,
0.0403715335,
0.3489692211,
0.0741118714,
-0.3704512119,
-0.0154921385,
-0.3845214844,
-0.1791653335,
-0.1043894961,
-0.10822016,
0.2127160281,
-0.094909206,
0.0244932473,
0.3061710298,
-0.024115013,
-0.052507259,
0.0334931873,
0.5147624016,
-0.2212889344,
0.2455554754,
0.1658206135,
0.0363781005,
0.0289337803,
-0.0536869988,
-0.0705096871,
-0.0107555566,
-0.2826847136,
0.1171799675,
0.3204647303,
0.0291499756,
0.2336799204,
0.0045100045,
0.1812268198,
-0.4299933314,
0.0546167493,
-0.1799017042,
0.0267856549,
0.2145902067,
-0.0805901289,
0.1579179615,
-0.0025223086,
-0.2529569864,
0.1067551225,
0.1903114468,
-0.6178181171,
-0.2562895119,
-0.0138410116,
0.1138289943,
-0.2807007432,
0.3627817333,
-0.0424152315,
-0.0234452523,
0.0297728311,
-0.2394820154,
0.0080750184,
-0.0210882518,
0.1281894147,
-0.2538211942,
0.4858943522,
0.3196287751,
-0.0638930127,
0.279466182,
-0.0143162375,
0.0300566368,
-0.2417254448,
0.3479000926,
-0.2619829178,
0.2430753261,
-0.4131557941,
0.1957117319,
0.2988140583,
-0.6477735639,
-0.6307657361,
0.1833775043,
-0.2321541607,
0.122511141,
-0.0445169434,
0.1439863741,
-0.0180676077,
0.0647651777,
0.1815213263,
0.0626943558,
-0.0347340703,
-0.19948107,
-0.2252822667,
-0.1114913896,
0.0847896487,
0.2439161837,
0.1684810817,
0.1059506163,
0.1110454425,
0.1972103864,
0.1728195697,
-0.101170674,
0.1137945503,
0.1980821639,
0.1860946864,
0.289042443,
0.1525543332,
0.1522702277,
-0.5122994184,
0.3835255206,
-0.1815199256,
-0.1087400913,
-0.220075056,
-0.129743129,
-0.0147930132,
-0.2311615199,
-0.4051474929,
-0.2030912042,
0.0720171332,
0.02746181,
0.1080279723,
-0.026876267,
-0.171965003,
0.4957535863,
-0.1741048098,
-0.0086797923,
-0.358246237,
0.3695957959,
-0.110053584,
-0.1175258681,
-0.0407609716,
-0.0480815768,
0.1920131296,
-0.2018754333,
-0.0150942383,
0.2767944038,
-0.0455343202,
0.275990814,
0.3504789174,
-0.03035165,
0.0141138807,
-0.4298625886,
-0.1681643724,
-0.0785902664,
0.116395399,
-0.0835221335,
0.0435048975,
0.1105848104,
-0.1786929965,
0.0420910642,
0.0390596017,
-0.0749718323,
0.3698669076,
-0.2445076108,
-0.0955382138,
-0.1610662937,
0.1946421713,
0.2705613673,
0.0809741244,
-0.0900462195,
-0.1153573543,
-0.1419992,
0.3758881986,
-0.128918305,
0.0867353007,
0.1408331692,
-0.0298602674,
-0.097159937,
-0.0181994811,
0.1824230552,
0.1616166979,
0.0739422962,
-0.1047717556,
0.3152352273,
-0.0865573213,
-0.0678830817,
-0.0864321217,
-0.1811196655,
0.1925162673,
0.6114952564,
0.0473485626,
0.073247917,
-0.2106777728,
0.0402626246,
0.0511456169,
0.2326358855,
-0.0743700042,
-0.0754746348,
-0.3911803961,
0.0019010631,
0.0698460564,
0.0626794547,
-0.4266352057,
-0.0436503403,
-0.0567509495,
0.0579972342,
0.1082173958,
-0.0630067736,
0.1116990224,
0.3665393293,
-0.0765982866,
-0.1037628204,
-0.3823920488,
-0.6609821916,
-0.325828433,
-0.0303017218,
0.0409821495,
-0.0039782492,
0.3425943255,
-0.3290385008,
0.1344326288,
-0.4004617035,
-0.4518876672,
0.0455466807,
0.0460642949,
0.365544349,
-0.0100118686,
0.657648921,
-0.4055890739,
-0.416430831,
0.395406872,
-0.2024629563,
-0.0403898247,
-0.1551210284,
0.168468684,
0.0293727331,
-0.1937476695,
-0.3351163268,
-0.2538433075,
-0.404392451,
0.3545823693,
-0.143530786,
0.134377405,
0.1249045208,
-0.1490847766,
0.214511767,
-0.1962374002,
-0.0387225859,
-0.4604591727,
-0.392316848,
0.3985952735,
-0.1796931475,
-0.2159686834,
0.252877295,
-0.161436677,
0.3047698438,
0.105208762,
-0.6089665294,
-0.335694015,
0.0180502981,
0.1981135756,
-0.1224930957,
0.066366002,
0.1610475928,
-0.13292858,
-0.0359091088,
-0.040298339,
-0.0049994532,
0.3628980517,
0.3612172306,
0.3401914537,
0.1938133538,
0.1360825449,
-0.1760373414,
0.4638028443,
0.0734678954,
0.066347979,
0.5312770605,
0.0402315967,
0.1391570568,
-0.2402773947,
-0.1681959182,
-0.1341074109,
-0.2759906054,
-0.1379107237,
0.1804646701,
0.1328415126,
0.1368221492,
-0.5194760561,
-0.0204801615,
-0.5748538971,
-0.3482212126,
0.0918675512,
-0.0222114213,
0.1710323393,
-0.1911341846,
-0.1136246771,
0.0361195505,
-0.0777738541,
0.305247426,
0.4058062732,
0.1377718151,
0.0535106547,
-0.2498987615,
-0.2751894891,
-0.2899353802,
0.3347910345,
0.033711493,
0.1175579354,
-0.3558876812,
0.1254309416,
0.1242197677,
-0.2753825188,
0.9871459007,
-0.0517058671,
0.2348385751,
-0.0932537615,
-0.1968736351,
0.1401321888,
-0.0549151935,
0.0686761513,
-0.1711547971,
-0.1325059831,
0.5586894751,
-0.2828468084,
0.0237727053,
-0.0817223936,
0.1551638246,
-0.3074443042,
-0.2523894608,
-0.1342826784,
-0.3368940353,
-0.3963450789,
-0.1374531835,
-0.0415094048,
0.2529231012,
0.1652090997,
-0.2430496365,
-0.2043415755,
-0.09179952,
0.0596833713,
0.1221151501,
0.5810610652,
0.0724201873,
0.039595928,
0.4640653729,
0.2450190485,
0.2099152207,
0.6358337998,
-0.0416175947,
-0.1444655806,
0.0764885023,
-0.0706949234,
0.0284832586,
0.5030778646,
-0.2096843123,
0.1085491627,
-0.1033664718,
0.0831042603,
-0.3968752325,
0.1444931179,
0.2115427554,
-0.0026163382,
-0.364132762,
-0.2588685751,
0.2742964923,
0.0399618112,
-0.0765799731,
0.2630152106,
0.1703770757,
-0.1732192785,
0.2072160244,
0.0030846922,
1.1643010378,
-0.2471190989,
-0.0095236776,
0.0447089002,
-0.0273481105,
0.5925610065,
-0.4694826603,
0.3610602617,
-0.3072707355,
-0.1826181412,
-0.1092323363,
0.0029967204,
0.2331509441,
0.1388564855,
-0.2538410127,
0.0403845012,
0.0369235128,
0.2295955569,
-0.2997162044,
0.3467670679,
0.1366940886,
0.1964263618,
-0.4675031602,
0.0511871539,
-0.3231397569,
0.3663570583,
-0.2707387507,
-0.1783928275,
-0.1275576502,
-0.3308494687,
-0.0328496583,
0.1328206062,
-0.1715250462,
0.2542670667,
-0.1570864469,
-0.343868196,
-0.209727034,
0.3421546221,
0.3023692369,
0.010793522,
-0.2052474022,
0.4544918835,
0.0645841137,
-0.1630550027,
-0.1921536028,
-0.0114314212,
0.0699752644,
-0.0667312369,
-0.3024127483,
0.0205495115,
-0.1697191745,
-0.2907220423,
-0.0813968778,
0.058016248,
-0.1691270024,
-0.0561853535,
-0.2416491061,
0.1307576746,
-0.1520737708,
0.0904884115,
0.0933582857,
0.0476816706,
-0.1462476701,
-0.0831312612,
0.2754121423,
-0.2694044411,
0.0145781571,
0.4174262881,
0.0283610616,
-0.2997196317,
0.4389178455,
0.0126718702,
0.0229374934,
-0.2160261571,
-0.1854074448,
0.1828525215,
-0.4274329543,
0.1018161252,
0.0283472016,
-0.0213110466,
0.1152736247,
0.0908912346,
0.3719822764,
-0.1063137725,
0.0457857847,
-0.4596368968,
-0.3692487478,
0.377913326,
0.0127119226,
0.3690316379,
0.3626083732,
0.0526570119,
0.1072267815,
0.4325957894,
-0.2638521791,
-0.0840198845,
-0.4194466174,
0.2384081781,
-0.1859374195,
-0.1412293464,
0.0490407497,
0.0652469993,
0.1155228615,
0.277466923,
-0.4328433573,
-0.1699872911,
-0.0639586598,
0.2298261523,
-0.1345633566,
0.1733065397,
-0.1071318537,
-0.3485932946,
0.249114424,
-0.0743149817,
0.1834969819,
-0.013324541,
0.1600280106,
-0.0769065842,
0.2798811495,
0.1255079806,
-0.2426351458,
-0.1302020997,
0.0063641332,
0.2822346985,
0.1997066587,
-0.2204200774,
-0.1286370456,
0.0560812727,
-0.2947569489,
-0.1285947263,
0.0285537653,
-0.3265837133,
0.1576647013,
-0.2072505951,
-0.1272050291,
-0.0981748998,
0.1988841891,
0.5071946383,
-0.4187746048,
-0.0268028677,
0.2449527979,
0.1444960386,
-0.2963344455,
0.1719597876,
0.4460627735,
-0.0801046714,
-0.2569898367,
0.1119244993,
0.368481487,
-0.0080888262,
-0.2484238148,
0.0568089336,
0.6748259068,
-0.2624029517,
0.3730263412,
0.472785145,
-0.1808776706,
-0.0644105375,
0.0643806532,
-0.0437595695,
-0.016091641,
0.3620415926,
-0.5149978995,
0.018666245,
-0.2368254364,
0.7380324602,
0.073400557,
-0.4126085043,
-0.0479742251,
0.1411715448,
-0.2095796913,
0.0237351842,
-0.1095528528,
0.1669540554,
-0.1893042028,
-0.241832763,
-0.3203452528,
0.4262770414,
-0.2919471264,
-0.0671029612,
0.1248383746,
-0.4218351245,
-0.173414126,
0.1655536741,
0.1190372258,
0.0218133517,
0.1356700063,
0.187215656,
-0.2374189347,
-0.1907073855,
-0.0095731337,
0.0350952558,
0.1788125187,
-0.1659300029,
0.5323813558,
0.2017335296,
-0.1223460957,
0.2729357183,
0.2660974562,
0.2450393587,
0.5397843719,
-0.1690377742,
0.2073227763,
-0.0634867251,
0.0617580675,
-0.070709981,
0.3176749945,
0.4513801634,
-0.1022183672,
0.1312882453,
0.0610252284,
-0.1149070933,
0.2059634328,
-0.3009594977,
0.3273159862,
-0.2878502011,
0.2055437267,
0.0970584527,
0.074985683,
-0.1547768265,
0.1343663335,
-0.6538735628,
-0.1131612733,
0.1755314618,
0.0460325256,
0.0454938486,
0.0504871532,
0.047173921,
-0.1538770348,
0.5811419487,
0.2677921057,
0.1523762196,
-0.3457331061,
-0.2743903697,
-0.8765487671,
0.2267727256,
0.0071280124,
0.2360420972,
0.1355490535,
-0.0011473504,
-0.1242220625,
0.163754791,
0.2338048369,
-0.1144284084,
0.1836369634,
-0.0802287683,
-0.3178771734,
0.1423061043,
-0.0425418206,
0.1692430675,
0.0187725313,
-0.1359504759,
0.1670513302,
0.1846816987,
-0.1040530279,
0.2547250986,
-0.0079857698,
0.0528186187,
-0.1032886505,
0.7231138349,
0.0900957808,
0.4345130324,
0.0859349146,
-0.0069614099,
-0.199769184,
-0.2261648923,
0.0814923495,
-0.0859933272,
0.2894130945,
0.2845361531,
-0.2686153352,
0.0231520534,
-0.4392754138,
-0.2278915346,
-0.1012701988,
0.2262863815,
-0.1609072536,
-0.379894346,
0.1386253685,
0.0905842632,
0.1235484108,
0.4513026178,
0.0457214937,
-0.0187505744,
-0.145385772,
-0.1346793324,
0.7209711671,
-0.4639814198,
-0.3037883639,
0.171214819,
0.0416057743,
-0.1270064861,
-0.1100669503,
-0.5785179734,
-0.0063911541,
0.2587918639,
0.1460392773,
-0.3268373609,
0.0691806898,
-0.2231688052,
-0.1035181358,
0.039155364,
-0.1007963121,
0.3590092659,
-0.1465277672,
-0.2960295379,
-0.1860985905
] |
https://github.com/huggingface/datasets/issues/3425 | Getting configs names takes too long | It looks like it's currently calling `HfFileSystem.ls()` ~8 times at the root and for each subdirectory:
- ""
- "en.noblocklist"
- "en.noclean"
- "en"
- "multilingual"
- "realnewslike"
Currently `ls` is slow because it iterates on all the files inside the repository.
An easy optimization would be to cache the result of each call to `ls`.
We can also optimize `ls` by using a tree structure per directory instead of a list of all the files.
|
## Steps to reproduce the bug
```python
from datasets import get_dataset_config_names
get_dataset_config_names("allenai/c4")
```
## Expected results
I would expect to get the answer quickly, at least in less than 10s
## Actual results
It takes about 45s on my environment
## Environment info
- `datasets` version: 1.16.1
- Platform: Linux-5.11.0-1022-aws-x86_64-with-glibc2.31
- Python version: 3.9.6
- PyArrow version: 4.0.1 | 76 | Getting configs names takes too long
## Steps to reproduce the bug
```python
from datasets import get_dataset_config_names
get_dataset_config_names("allenai/c4")
```
## Expected results
I would expect to get the answer quickly, at least in less than 10s
## Actual results
It takes about 45s on my environment
## Environment info
- `datasets` version: 1.16.1
- Platform: Linux-5.11.0-1022-aws-x86_64-with-glibc2.31
- Python version: 3.9.6
- PyArrow version: 4.0.1
It looks like it's currently calling `HfFileSystem.ls()` ~8 times at the root and for each subdirectory:
- ""
- "en.noblocklist"
- "en.noclean"
- "en"
- "multilingual"
- "realnewslike"
Currently `ls` is slow because it iterates on all the files inside the repository.
An easy optimization would be to cache the result of each call to `ls`.
We can also optimize `ls` by using a tree structure per directory instead of a list of all the files.
| [
-0.3283521235,
0.1722298414,
-0.1880414635,
0.377035141,
0.199928537,
-0.1003855318,
0.1385930628,
0.4915502965,
-0.0290571153,
0.3562119901,
-0.1960751116,
0.352930218,
0.132097736,
-0.2432373315,
-0.2165948004,
0.0623897761,
-0.0295607448,
0.1501358598,
0.0637908578,
-0.2429284304,
-0.2170455456,
0.1156889722,
-0.0441155098,
-0.0471616425,
-0.2419754714,
0.0851694942,
-0.1668529063,
-0.023232989,
-0.1466599256,
-0.3311944306,
0.1002259701,
0.0848369896,
-0.1900843829,
0.3920297027,
-0.0001138624,
-0.1775077581,
0.2576197088,
0.1408651918,
-0.3977585733,
0.237092793,
-0.3137454391,
-0.4717762768,
0.03644263,
-0.3989420533,
-0.1039436832,
-0.0872274041,
-0.0072795767,
-0.2399000525,
-0.1956025213,
0.1267161816,
0.1788363606,
0.1481162012,
-0.2144665271,
0.0868481174,
0.4284647107,
-0.1136829257,
-0.1058953479,
-0.1914028525,
0.1253660321,
-0.112543717,
0.1715471894,
0.4061121047,
-0.2142766118,
0.1782011539,
0.0585702769,
-0.0194623861,
-0.1078308076,
-0.2298285067,
0.3125298619,
0.3142500222,
0.5726146102,
-0.2321846336,
-0.341917336,
-0.323549062,
0.0541949049,
-0.1749774218,
0.2400868684,
0.1122341082,
-0.155009076,
0.0262179542,
-0.0721314028,
-0.1331975907,
0.0129826292,
0.108211562,
-0.0486320071,
0.4571966529,
0.0467725918,
-0.0054736277,
0.1402052939,
-0.2213102877,
0.0722059235,
-0.4857117534,
-0.0585107468,
0.230164662,
-0.5162576437,
0.0300863963,
0.2911922932,
0.3916606307,
-0.0195690058,
0.1962170154,
-0.152949661,
0.1309496462,
0.3077014983,
-0.0092587285,
-0.1205125228,
0.1298979968,
0.155302912,
0.4172437489,
0.2827747762,
-0.0810806528,
-0.0660671368,
0.080323182,
-0.0750359222,
-0.2258939892,
-0.090218313,
-0.1788241267,
0.0853828341,
-0.3055813015,
0.0705238953,
0.0903452933,
-0.224986583,
-0.2075744569,
0.1587717831,
0.2674567103,
-0.1989425123,
0.1211344376,
-0.0228629094,
-0.2458028942,
-0.2259303927,
0.195297271,
-0.2576244473,
-0.0953392684,
-0.1651108861,
0.0572577454,
0.0198777001,
-0.1839921325,
0.2660896778,
-0.0540306382,
0.1658898145,
0.0845019072,
0.0274058562,
-0.0110201305,
0.0234092548,
0.4828353822,
-0.0930836201,
0.1153512225,
-0.0869710967,
-0.4192582369,
-0.378244549,
-0.1182524562,
-0.1593546569,
-0.412391305,
0.0327871554,
0.1672683507,
0.0334813967,
0.2363187373,
-0.0814567208,
0.0307098888,
0.1712089181,
0.3955303431,
0.0439533181,
-0.075491637,
0.3969988823,
-0.0836614519,
0.2459640205,
0.3607471287,
-0.3711392879,
0.1132619902,
-0.1675347537,
0.2238897085,
0.1707318872,
0.3981341124,
-0.1165167093,
0.0575772263,
-0.0783672556,
0.1092141345,
0.4840183556,
-0.256739676,
-0.3556321263,
0.2435787022,
0.1357584298,
-0.1711355746,
0.2956233919,
0.0885229334,
-0.2591401041,
0.0573478974,
-0.1520090103,
0.0588656627,
0.0064534792,
0.110133186,
-0.0897744596,
-0.1814337969,
-0.449446559,
0.3117048442,
-0.2495407313,
-0.2444494963,
0.1137359813,
-0.2190403491,
0.3829838336,
-0.2123190016,
-0.2444946319,
0.2426517904,
0.2843573689,
0.3706579506,
0.0931756869,
0.1730275303,
-0.4357806742,
0.3328467607,
0.3461663723,
0.1651809216,
-0.3426586986,
-0.2341167182,
0.1669634581,
0.2084058523,
-0.0366156958,
0.0010168067,
0.0448976792,
0.5023496151,
0.1103986427,
-0.2829918563,
0.0368314907,
0.1823268831,
-0.2379618585,
0.0409011319,
-0.5903838277,
0.1523784846,
0.0660914481,
0.1453377157,
0.0285566039,
-0.2185180187,
0.1840421557,
-0.1441026181,
-0.0535627417,
0.1866045147,
0.0244364683,
0.3301219046,
0.2091055512,
0.587289691,
-0.1624203473,
0.0245121736,
0.5088233948,
-0.0022593425,
0.0817067102,
-0.0719908699,
-0.0889331549,
0.4640774131,
0.4207333624,
0.5638929605,
-0.0119151315,
-0.1841079146,
0.2009587586,
0.0528859943,
-0.0723401234,
-0.0945338681,
0.3010466695,
0.1938932389,
0.3651151955,
0.2533346415,
-0.2518151104,
0.1736262292,
0.6453282237,
-0.158489272,
-0.3119299114,
0.0034403845,
0.1898708344,
-0.0122192288,
0.2791702747,
0.1414456815,
0.0700721145,
0.3760903776,
0.0091777826,
-0.006705157,
-0.1947557926,
-0.127078861,
0.466442436,
0.2177503258,
0.1594700813,
-0.0252339449,
0.0531325303,
-0.2167073339,
-0.3013718724,
-0.674210608,
-0.216320172,
0.2862896025,
-0.207804516,
0.3290459514,
-0.4347783625,
-0.1111244783,
0.1296535879,
0.0133918207,
-0.0087593105,
-0.2641429007,
-0.0278267134,
-0.0872093216,
-0.1944994181,
0.3942287564,
-0.0393071473,
0.0621859841,
0.095816344,
-0.3419718444,
-0.5869113803,
0.043339625,
-0.2015621066,
-0.0439752378,
0.2102998048,
-0.1791886091,
0.3392645717,
-0.2636735439,
-0.1485763937,
-0.5283127427,
-0.2583646178,
0.1344671994,
-0.2407528162,
0.2412715554,
0.2105219513,
-0.0376080237,
0.018496288,
-0.1526321918,
0.1601604819,
0.3820940852,
0.0256504696,
0.022284152,
-0.1658668518,
-0.3764617443,
0.0940106809,
-0.4570722282,
-0.0807390809,
-0.1377253532,
0.1575507075,
0.1508633196,
0.3315747976,
0.1174993068,
0.0676118284,
0.0896922871,
-0.1037586257,
-0.0773838758,
0.016228579,
-0.3667277098,
0.4960043132,
0.0495688021,
0.1045257002,
-0.2792675495,
0.1123285294,
0.1453101635,
0.0782467723,
-0.5737979412,
0.2637540996,
-0.4898380935,
0.5774402022,
0.0308237728,
0.2673086226,
0.170229286,
0.2299753428,
-0.1606562287,
0.0416975543,
-0.1787074059,
-0.0329755507,
-0.0291739833,
0.1730591506,
0.0437913015,
0.3468036652,
-0.1811507195,
0.3531593382,
0.3370423019,
-0.0873999149,
-0.0238866452,
-0.0850775093,
0.1680865884,
-0.1783612967,
-0.2352033556,
0.2234624773,
0.2654000521,
-0.187407136,
0.4006913006,
0.1036618426,
-0.4152062833,
-0.1419954896,
0.0082131801,
-0.1106155589,
-0.2037892193,
0.0746627301,
-0.0901045501,
0.1576703489,
0.1732092053,
0.0695386752,
-0.1478506178,
-0.0480850302,
-0.0392360203,
0.1008325964,
-0.3436032534,
-0.163491413,
-0.3445984721,
-0.1925024688,
-0.4680581689,
0.4330330789,
-0.107503064,
-0.176367119,
0.0894601867,
0.1350557804,
0.1712564528,
-0.1216756105,
0.26116395,
-0.2267142385,
0.0624097213,
0.3184084892,
0.0793128982,
-0.06381201,
-0.1671238095,
-0.3627338111,
0.079576239,
0.2594817877,
0.3957138956,
-0.4433830082,
-0.4356044829,
-0.0047481474,
0.2041512728,
-0.0761437118,
0.0031723906,
0.0312890857,
-0.4575141668,
-0.0499609634,
0.1658424735,
-0.1137939692,
0.1167342663,
-0.0071339356,
-0.2545967996,
0.1727527678,
0.2099189013,
0.2521020174,
0.4212419391,
-0.0127570406,
-0.1490930766,
0.2915552258,
-0.1633068174,
-0.0095575238,
0.5218681693,
0.5178298354,
-0.0491385274,
0.0170253757,
-0.0533967353,
0.0632441416,
0.3771873713,
0.3914456069,
-0.2244369388,
-0.1968832314,
-0.1824418604,
0.5670384765,
-0.0274261795,
-0.2576004565,
0.4615047574,
0.3978300393,
-0.2237206995,
-0.4994649291,
0.5088412762,
0.0021032365,
-0.1534714699,
0.4175445139,
0.2937540412,
-0.2103093565,
0.3566151261,
0.0524896383,
0.9589038491,
-0.0254208967,
-0.008923457,
0.37195611,
-0.1908182502,
0.2964910865,
-0.3007679582,
-0.0104727382,
-0.2163135856,
0.2151634544,
0.1624349356,
-0.1213949993,
0.306196928,
0.5333624482,
0.1258908212,
0.3559737802,
-0.0693819746,
-0.158042863,
-0.1472427994,
0.3460870087,
-0.211620003,
-0.3247089088,
-0.6696755886,
0.1557154953,
0.0670974404,
0.0889267698,
0.0481578298,
0.1928563416,
-0.1466331035,
-0.2505445182,
-0.1298559159,
0.1549122334,
-0.1462385952,
0.1995201707,
0.0196016449,
-0.1771726161,
-0.237222597,
0.1135824993,
-0.1110503599,
0.5356447101,
-0.0003232554,
0.4336274564,
0.1650890708,
0.2508238852,
0.3243044019,
-0.1968119889,
0.0556134172,
-0.0557838231,
-0.1917729974,
-0.4033285677,
-0.1071269512,
-0.2421149313,
0.1662588567,
-0.1605659127,
0.0520658158,
0.0904571041,
0.0906181931,
0.1714848578,
-0.2582496703,
-0.2262405157,
0.1813987792,
0.0982630923,
-0.0982787311,
0.5479364991,
-0.0344167799,
-0.3311585486,
-0.1872452348,
0.0404546447,
0.0539564006,
0.101375334,
0.3768720031,
0.153155148,
-0.4963784516,
-0.3022589087,
0.1680032164,
-0.1165509596,
-0.2602885962,
-0.0513499193,
-0.0151574723,
-0.0454168282,
0.067764096,
-0.1003176123,
0.137442559,
-0.1569693387,
-0.0838961005,
-0.1724640876,
0.1360703558,
0.044424627,
0.0214576907,
0.314719975,
-0.1672269553,
-0.1526510417,
-0.2958726287,
-0.007965235,
-0.3220590651,
-0.0888519585,
-0.4775020778,
0.2444068044,
-0.0189221036,
0.11679966,
0.3233935833,
-0.0243466962,
0.3429093957,
-0.3434146941,
-0.2315563858,
-0.25861305,
-0.1871939451,
0.1016789302,
-0.1741749197,
0.032814689,
0.1892742068,
-0.2999507487,
-0.2597377896,
-0.4610325098,
0.2061571628,
0.1686488837,
0.1824169904,
0.0916220471,
0.3008909523,
-0.4786645174,
0.1403574049,
0.287814796,
0.0209328663,
-0.048315946,
-0.1747130752,
0.270472765,
-0.1016631052,
-0.2679360509,
0.1478577256,
0.1240790784,
-0.2929023206,
0.3159477711,
0.3793805242,
0.0867041871,
-0.0798508748,
0.2067062408,
0.2061439455,
0.3700617254,
0.1024755687,
-0.1556482613,
0.2296752185,
0.1829904318,
-0.3369842768,
-0.5035552382,
-0.0688518137,
-0.0533457138,
0.1037036702,
0.1302521527,
-0.0490966924,
-0.0756106004,
0.1739018708,
-0.2019190043,
0.3181102276,
-0.2661065161,
-0.1711442024,
0.4983610213,
0.0888211504,
0.0312823355,
0.4141243994,
0.1342072338,
0.0376914889,
0.4479528368,
-0.0849227533,
-0.0341990143,
0.2586561441,
0.2619678378,
-0.0918696225,
-0.2037392855,
-0.1991106421,
-0.1165118292,
-0.2598819733,
0.1688092053,
0.0001368124,
-0.085278742,
0.2096900791,
0.1568368673,
-0.1286866665,
0.3937622607,
-0.1316897869,
-0.2080242187,
0.0105873412,
-0.1273125261,
-0.0274163131,
0.0586353354,
-0.0767721087,
-0.1801473349,
0.3661505878,
0.2323436588,
0.1826774031,
-0.2457281351,
0.3752363324,
-0.2793877423,
0.3188737631,
-0.2826540172,
0.1064707041,
-0.0634929314,
-0.0001527002,
-0.25305444,
0.1586907655,
0.3956941664,
0.066589959,
0.2502323687,
0.1105355769,
-0.0071290131,
-0.1485554278,
-0.1733510494,
0.1473801434,
-0.3420999348,
-0.2500783801,
0.1325756311,
0.0814116299,
-0.1624478549,
-0.1787912548,
-0.278221935,
0.0489295945,
-0.175752297,
0.2892164588,
0.1460885108,
-0.2257738858,
-0.1975779086,
0.2544613183,
-0.440417856,
-0.1275465935,
0.6323225498,
0.0339948423,
0.076885812,
-0.030700814,
0.0855430365,
-0.2803451419,
0.4933254123,
0.1439127922,
0.2732363343,
-0.1230382323,
-0.2509457469,
-0.3565226197,
-0.2606149316,
-0.1981364936,
-0.196738869,
0.0691675469,
0.3206529617,
0.2061561942,
-0.0005908851,
0.3275528848,
-0.4094035327,
0.0683763921,
0.3701228201,
-0.3835268617,
-0.0468865409,
-0.1536133438,
0.0551113635,
0.0907106996,
-0.3243435919,
0.2902974486,
0.0935659334,
0.0293883588,
-0.2874608338,
0.1861386597,
0.4659396708,
0.1841208637,
0.4177636206,
0.0021560949,
0.1041413322,
-0.1131060347,
-0.1670004278,
-0.3372450769,
-0.0661617965,
-0.0084510893,
0.1539358646,
-0.1649986506,
0.0720866695,
-0.1303374171,
-0.0669935942,
-0.2250271142,
0.0270320792,
-0.0811792836,
-0.1598470658,
0.1808299422,
-0.0584071316,
-0.046148926,
0.3622552454,
-0.2207482904,
0.0377791859,
0.1482821852,
0.0308149513,
-0.2795009315,
-0.4185489714,
0.8398545384,
0.1498460919,
-0.3093314469,
0.0408440381,
0.2565687597,
0.1511314362,
0.0553208515,
-0.1855393946,
0.0887654126,
0.4335238934,
-0.193427518,
-0.3126256466,
0.2419326305,
0.106845066,
0.1862695217,
-0.2072793841,
0.172190547,
-0.1802938581,
-0.3029078543,
-0.3101299703,
-0.3126801848
] |
https://github.com/huggingface/datasets/issues/3423 | data duplicate when setting num_works > 1 with streaming data | Hi ! Thanks for reporting :)
When using a PyTorch's data loader with `num_workers>1` and an iterable dataset, each worker streams the exact same data by default, resulting in duplicate data when iterating using the data loader.
We can probably fix this in `datasets` by checking `torch.utils.data.get_worker_info()` which gives the worker id if it happens. | ## Describe the bug
The data is repeated num_works times when we load_dataset with streaming and set num_works > 1 when construct dataloader
## Steps to reproduce the bug
```python
# Sample code to reproduce the bug
import pandas as pd
import numpy as np
import os
from datasets import load_dataset
from torch.utils.data import DataLoader
from tqdm import tqdm
import shutil
NUM_OF_USER = 1000000
NUM_OF_ACTION = 50000
NUM_OF_SEQUENCE = 10000
NUM_OF_FILES = 32
NUM_OF_WORKERS = 16
if __name__ == "__main__":
shutil.rmtree("./dataset")
for i in range(NUM_OF_FILES):
sequence_data = pd.DataFrame(
{
"imei": np.random.randint(1, NUM_OF_USER, size=NUM_OF_SEQUENCE),
"sequence": np.random.randint(1, NUM_OF_ACTION, size=NUM_OF_SEQUENCE)
}
)
if not os.path.exists("./dataset"):
os.makedirs("./dataset")
sequence_data.to_csv(f"./dataset/sequence_data_{i}.csv",
index=False)
dataset = load_dataset("csv",
data_files=[os.path.join("./dataset",file) for file in os.listdir("./dataset") if file.endswith(".csv")],
split="train",
streaming=True).with_format("torch")
data_loader = DataLoader(dataset,
batch_size=1024,
num_workers=NUM_OF_WORKERS)
result = pd.DataFrame()
for i, batch in tqdm(enumerate(data_loader)):
result = pd.concat([result,
pd.DataFrame(batch)],
axis=0)
result.to_csv(f"num_work_{NUM_OF_WORKERS}.csv", index=False)
```
## Expected results
data do not duplicate
## Actual results
data duplicate NUM_OF_WORKERS = 16
![image](https://user-images.githubusercontent.com/16486492/145748707-9d2df25b-2f4f-4d7b-a83e-242be4fc8934.png)
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version:datasets==1.14.0
- Platform:transformers==4.11.3
- Python version:3.8
- PyArrow version:
| 55 | data duplicate when setting num_works > 1 with streaming data
## Describe the bug
The data is repeated num_works times when we load_dataset with streaming and set num_works > 1 when construct dataloader
## Steps to reproduce the bug
```python
# Sample code to reproduce the bug
import pandas as pd
import numpy as np
import os
from datasets import load_dataset
from torch.utils.data import DataLoader
from tqdm import tqdm
import shutil
NUM_OF_USER = 1000000
NUM_OF_ACTION = 50000
NUM_OF_SEQUENCE = 10000
NUM_OF_FILES = 32
NUM_OF_WORKERS = 16
if __name__ == "__main__":
shutil.rmtree("./dataset")
for i in range(NUM_OF_FILES):
sequence_data = pd.DataFrame(
{
"imei": np.random.randint(1, NUM_OF_USER, size=NUM_OF_SEQUENCE),
"sequence": np.random.randint(1, NUM_OF_ACTION, size=NUM_OF_SEQUENCE)
}
)
if not os.path.exists("./dataset"):
os.makedirs("./dataset")
sequence_data.to_csv(f"./dataset/sequence_data_{i}.csv",
index=False)
dataset = load_dataset("csv",
data_files=[os.path.join("./dataset",file) for file in os.listdir("./dataset") if file.endswith(".csv")],
split="train",
streaming=True).with_format("torch")
data_loader = DataLoader(dataset,
batch_size=1024,
num_workers=NUM_OF_WORKERS)
result = pd.DataFrame()
for i, batch in tqdm(enumerate(data_loader)):
result = pd.concat([result,
pd.DataFrame(batch)],
axis=0)
result.to_csv(f"num_work_{NUM_OF_WORKERS}.csv", index=False)
```
## Expected results
data do not duplicate
## Actual results
data duplicate NUM_OF_WORKERS = 16
![image](https://user-images.githubusercontent.com/16486492/145748707-9d2df25b-2f4f-4d7b-a83e-242be4fc8934.png)
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version:datasets==1.14.0
- Platform:transformers==4.11.3
- Python version:3.8
- PyArrow version:
Hi ! Thanks for reporting :)
When using a PyTorch's data loader with `num_workers>1` and an iterable dataset, each worker streams the exact same data by default, resulting in duplicate data when iterating using the data loader.
We can probably fix this in `datasets` by checking `torch.utils.data.get_worker_info()` which gives the worker id if it happens. | [
-0.232575953,
-0.3752961457,
-0.0161686987,
0.3272433281,
0.254571557,
-0.1762158871,
0.5691007376,
0.3358851373,
-0.2572708726,
0.421199739,
0.0956361741,
0.2009149492,
-0.0080959164,
0.1235197484,
0.144700557,
0.0096041495,
0.0426976569,
0.1493969113,
-0.2690355778,
0.1793185472,
-0.0729403421,
0.0054132892,
0.0089017423,
-0.1221663803,
-0.2812235951,
0.0286028441,
-0.0868533701,
0.2736003399,
0.1483578384,
-0.2246373594,
-0.1355646998,
0.0167593528,
0.2225170881,
0.7733385563,
-0.0001093749,
0.0273636896,
0.1163530201,
-0.056424357,
-0.2641803324,
-0.1926754713,
0.1805037111,
-0.1169929877,
0.1388168037,
-0.1363621056,
-0.0714548528,
-0.1025254056,
-0.1689471453,
-0.2384032756,
0.5982194543,
0.3020549715,
0.2001245022,
0.2040703297,
-0.2368645221,
0.0807682872,
-0.0227851067,
-0.1564833969,
-0.0560325533,
0.323571533,
0.4014079571,
0.2742699087,
-0.2470953017,
0.4327002168,
0.0168398749,
0.2134006023,
0.0467013717,
-0.0043556588,
0.1431002021,
-0.3292378187,
0.1463049948,
0.2457196862,
0.2474497706,
-0.2629604936,
-0.0524540432,
-0.1481212229,
0.0667593405,
-0.4061613381,
0.1443610489,
-0.0307432227,
-0.2216880769,
0.0767681003,
-0.0286441017,
0.3717752695,
-0.0570947118,
-0.1216569021,
0.0836961418,
-0.0682971105,
-0.0232118759,
0.1365586817,
0.1115456149,
-0.0734323412,
0.4617798328,
-0.1524796784,
0.0924358517,
-0.1511486322,
-0.5506556034,
-0.0842756256,
-0.1262447238,
-0.18125543,
-0.0152595062,
0.1713977307,
0.4865384996,
0.0704089031,
0.2151358128,
0.0869303197,
0.1190569177,
0.1585398614,
-0.2548934817,
-0.2556325197,
0.1860319674,
0.2502902448,
-0.3122908771,
-0.072654821,
0.1632324904,
-0.2154927254,
0.4953039587,
0.1664383411,
0.3587911129,
0.0031171637,
-0.2563692331,
0.0642858669,
-0.0471295379,
0.0858362317,
-0.0064097261,
0.1443856657,
-0.0242646653,
0.4580362737,
-0.1754567623,
0.1291881204,
-0.1905430257,
-0.4064302146,
-0.2643486559,
-0.1287216395,
-0.0944207013,
0.0119195068,
0.180719167,
-0.3319132924,
0.3005277216,
0.4278579056,
0.1608969569,
-0.3793379962,
0.4736733139,
-0.310723871,
0.0393359363,
0.0551883914,
0.0177808348,
0.2736403942,
0.3146783113,
0.1342144758,
0.1491898298,
0.2838484049,
-0.1892237812,
-0.2029173076,
-0.0568242669,
0.3010509014,
0.1310585439,
0.1251802146,
-0.0480440296,
0.0954206809,
0.0963972583,
-0.1041648388,
0.1092259288,
-0.1158669144,
-0.2004847974,
-0.2430848777,
-0.0550286956,
0.3452441394,
0.0651237667,
0.0787205696,
0.0774828419,
0.0190095287,
0.4452487528,
0.2374712229,
-0.1243970022,
0.111159794,
-0.285185039,
0.0325275883,
0.5462091565,
-0.2593693733,
-0.4046398103,
0.4371255636,
-0.3668297231,
0.1128629819,
0.4238320291,
0.3645485044,
0.3320660591,
-0.0692273229,
0.237993896,
0.1600595862,
-0.0987204909,
0.1280480325,
-0.3108530939,
-0.0816036239,
0.2053228915,
-0.0725030676,
-0.1776509583,
-0.0163214467,
0.1787858903,
-0.3957609832,
0.1258983761,
-0.0926750898,
0.0156174293,
-0.0106572742,
0.0279159751,
0.0100688934,
0.0942916572,
-0.1388716549,
-0.3768976033,
0.1278701723,
-0.0430594087,
-0.2299952358,
0.0710649118,
-0.2208883315,
-0.2414957434,
-0.2183570564,
-0.3691313863,
-0.2393306941,
0.2320527732,
0.2318074703,
-0.1677780896,
-0.4088276029,
-0.0711868256,
0.3986448348,
-0.270922929,
-0.1191243678,
-0.1939222515,
0.1301831454,
-0.1840546131,
-0.2086043209,
0.0535813943,
0.1124010533,
0.3394463956,
0.0721242651,
-0.1523097456,
0.3804547489,
0.1329360306,
0.3735527098,
-0.038091626,
-0.0956407934,
0.1595097333,
-0.0778009072,
-0.1383574307,
0.4598845541,
0.2602322698,
-0.0261142123,
-0.1658342928,
0.2862226367,
-0.3266169429,
-0.1722667515,
-0.0017229073,
-0.065285109,
0.2907440066,
-0.0369179882,
0.0375464037,
-0.1470053345,
0.2070091367,
0.1391850412,
0.0649997145,
0.0727383122,
-0.405975908,
0.209656328,
-0.1640549451,
-0.0075465953,
-0.00475865,
-0.2022501081,
-0.1684258133,
-0.1741589159,
0.1045864969,
0.1734927297,
0.5916929841,
0.2543932796,
0.0968850553,
-0.0018729728,
0.0082860813,
-0.1786676347,
0.1541017741,
-0.1791674048,
-0.183665812,
0.4155962765,
0.2356173694,
0.0200196095,
-0.4517162144,
-0.1200749353,
0.119653292,
0.2558179796,
-0.3397213221,
0.0509373583,
-0.2482746243,
0.0186311454,
-0.606431067,
-0.0510987341,
-0.000010234,
-0.1501995772,
-0.1013373956,
0.5159271955,
0.0118255392,
0.143835023,
-0.0190673526,
0.0992671326,
0.2845371962,
0.2305807024,
-0.0683516562,
0.1002191678,
-0.1617559344,
0.1221623048,
0.0412561782,
-0.0153149283,
0.454814285,
0.0532763042,
0.1019114777,
-0.5667012334,
-0.2578648925,
-0.0815544128,
0.1752305478,
0.5197483897,
0.0439645462,
0.163611114,
-0.0249476563,
-0.1216460988,
-0.1182224751,
-0.1421073377,
-0.2364524603,
0.0028132028,
-0.0856936872,
0.2417736501,
-0.2683660686,
-0.3805565238,
-0.0926021412,
-0.2641489208,
-0.0859280229,
-0.03914994,
0.2593416274,
0.0706427544,
0.0145754134,
0.1512506306,
0.4747600555,
0.1178864986,
-0.4887931049,
-0.4494748414,
0.161095202,
-0.1190936565,
-0.2410860509,
-0.1528856307,
-0.2208817005,
0.0288344547,
0.1341529191,
-0.4471953511,
-0.2873135209,
0.0889250189,
0.1785939634,
-0.239826709,
0.0668607131,
0.2155983895,
0.0780532807,
-0.2084505409,
-0.124240689,
0.1337824166,
-0.1466187984,
0.0573121719,
0.1487947702,
-0.0183943622,
0.4291378558,
0.0459715948,
0.484354347,
0.4392162263,
-0.1078845039,
0.2628548443,
-0.221682474,
0.1691560447,
-0.0023894452,
-0.2227885872,
0.0420335941,
-0.1378420889,
0.1540296525,
0.3252018988,
-0.1319096386,
0.0955434293,
-0.0142488955,
-0.0308306273,
-0.421865195,
-0.1347929686,
-0.0119806947,
-0.3076411188,
0.098223336,
0.0375870056,
-0.0054138214,
-0.0894386768,
-0.1637147069,
-0.2463334203,
0.2291080505,
-0.0954918563,
-0.0217901319,
0.0473622046,
0.1014093906,
-0.4657289386,
0.1351403892,
0.2343238741,
0.5233976245,
0.2992340922,
0.0203538407,
0.136978358,
-0.0041869474,
0.6461728811,
-0.3047169149,
0.0476736836,
-0.1932584345,
-0.1261408478,
-0.1682854742,
-0.0581339821,
-0.0846077576,
-0.0806838498,
0.1723971516,
0.4653706253,
0.0265069883,
-0.0148554202,
0.2174687684,
0.1550377607,
-0.1928663552,
-0.3623105586,
-0.3043017089,
-0.1657861769,
-0.2099126279,
0.0879315436,
-0.0795945525,
0.1049776077,
-0.2061510682,
-0.177376017,
-0.215195775,
-0.1180919632,
0.3505523801,
0.0371508859,
0.2076809108,
0.117569156,
0.1883310527,
0.198341161,
-0.0034398793,
0.0276818108,
0.2447553128,
-0.0347714089,
-0.1358008832,
0.1123774424,
-0.1470552087,
-0.0612301789,
0.2799743414,
-0.0463500097,
0.1913714856,
0.0878689736,
0.1661930084,
0.0228155982,
0.0068182377,
0.2787887156,
0.1595890671,
-0.1118461788,
-0.395503372,
0.2151824087,
0.1865969449,
-0.0263719372,
0.4284128845,
-0.6620622873,
-0.0693075955,
-0.1004177779,
-0.1200399473,
0.8012030721,
0.0864051655,
0.2501120269,
0.3097534776,
-0.441106081,
0.2539435923,
-0.1422570199,
0.0669219345,
-0.3592149317,
-0.5228200555,
-0.0282712132,
-0.2225419134,
0.1761112362,
-0.1735491604,
-0.4452694952,
0.3149872422,
-0.1891490966,
0.5836107731,
0.0185050443,
0.1185785756,
-0.1462282985,
-0.0395731404,
-0.1299455613,
0.1105904505,
-0.1269225031,
-0.0677937418,
-0.0709882602,
-0.0920867845,
0.168343693,
-0.204983443,
0.0975842699,
-0.0535733141,
-0.5762127638,
0.3885456324,
-0.1233952492,
-0.3521104753,
-0.2716169655,
0.1786541939,
0.1162146404,
-0.1140589565,
-0.0478193201,
-0.0510274284,
0.526525557,
0.3620860577,
-0.1496388018,
-0.1554919183,
0.428835988,
-0.0585505255,
-0.1998509169,
0.1820119917,
0.3065870702,
-0.0111220023,
-0.1905931085,
0.2617819309,
0.0260656197,
-0.3174489439,
-0.0009438712,
-0.1390988231,
-0.2691533864,
-0.377700299,
0.1506715119,
-0.1279238313,
-0.3933440149,
0.0299371388,
-0.0321401991,
-0.3152776957,
-0.262006551,
0.3653553724,
0.4884817004,
0.0139432382,
0.2156249136,
-0.1268915832,
-0.2012768537,
-0.2409163713,
0.2364681214,
-0.0645363182,
-0.4119770229,
0.3218462467,
-0.1883367151,
0.0247345325,
0.0609537512,
0.0677364245,
-0.0725697875,
0.3467039168,
-0.1514204293,
-0.2300658375,
-0.5069087148,
-0.2645509541,
0.0354065597,
0.3188835382,
0.0444840528,
0.3194245696,
-0.0256970953,
0.0955407172,
-0.3671633899,
0.1582467854,
0.0879701898,
0.3427937925,
0.0873424783,
-0.1522430629,
0.0005403492,
0.2912174165,
0.155146867,
0.3171488345,
-0.2249580026,
-0.3285801709,
-0.2647249997,
0.1057538912,
-0.1502897292,
-0.1710045338,
-0.3112558126,
0.0084038805,
-0.0470641069,
-0.1014044434,
0.1801440269,
0.0556426384,
0.1147338748,
-0.0376476869,
0.4749485552,
0.0470995158,
-0.0665547848,
-0.0082190698,
-0.2510852218,
0.1600515246,
-0.001483725,
-0.0181242861,
-0.1668705195,
-0.0752054751,
-0.3852079213,
-0.1256996542,
0.2910532951,
0.0289067496,
0.0514651537,
-0.2525205314,
-0.0977330729,
0.0498849973,
0.2729039788,
0.2360826433,
-0.3120245934,
-0.2801553905,
0.0210351031,
0.2392579466,
-0.3121617436,
-0.0398395844,
-0.0378115922,
-0.0988773033,
0.1698572189,
0.3003664613,
0.1743740439,
-0.3612979054,
-0.01045678,
-0.1054110005,
-0.0099790795,
-0.4217979908,
0.127356261,
0.2815951407,
-0.0306152776,
-0.1822191775,
0.2722438872,
0.0665353909,
-0.0620772205,
0.139346838,
-0.0178823974,
0.1360493749,
0.1372889429,
-0.0290609896,
-0.1934634745,
-0.1284843385,
0.0366067216,
0.2566311657,
-0.521482408,
0.1776340157,
0.2164945602,
0.1239331141,
-0.116606392,
0.0941545665,
-0.058331836,
0.0959786549,
-0.3209308386,
-0.132339716,
0.180310607,
-0.0214880873,
-0.2110702991,
-0.071096614,
0.0528353751,
0.3617663682,
-0.015877191,
0.3496361077,
-0.1326559037,
-0.2699390352,
-0.1952128112,
0.4980935156,
-0.019497985,
-0.3491037488,
0.110523358,
0.4241358936,
0.2394896895,
0.1648161709,
0.1961564273,
0.5627021194,
0.3440356553,
-0.1720213741,
0.0585061014,
0.1696974933,
-0.030498514,
-0.0836497992,
-0.0755369961,
0.0568408072,
0.0500526875,
0.2399840504,
0.1664672792,
-0.2357577682,
0.003071971,
0.2274904847,
-0.1396827847,
-0.5591310859,
0.3070270717,
0.0002791799,
0.0034610496,
-0.1033052132,
0.1001996994,
-0.4988170564,
0.0374831669,
0.2939960361,
-0.0956988484,
0.206319347,
-0.1676300764,
0.1177940443,
-0.1041228324,
0.3071419597,
-0.0495376065,
0.0543714911,
-0.3376259804,
-0.0499860533,
-0.7678493261,
0.173656404,
0.0997275636,
0.1303597838,
0.1125439331,
0.1695895791,
-0.3727913201,
0.0537747182,
0.1624019593,
-0.0016957116,
0.0444720313,
0.2206200659,
-0.3652908802,
-0.2507268786,
-0.3343899846,
0.0296970606,
0.1035117134,
-0.4949091971,
0.3291401863,
-0.1104037911,
0.2040228546,
0.0616560504,
-0.1067567095,
0.0815832838,
0.2937067747,
0.3502361178,
0.0903141126,
0.294501394,
-0.1944580376,
0.1323443502,
-0.0687395856,
-0.035848368,
-0.2151158601,
0.092779994,
0.3993166685,
0.210215643,
0.0204806253,
-0.3557466567,
-0.2885124683,
0.4376610518,
0.2642537951,
-0.120663099,
-0.1990336627,
0.1214664802,
-0.1278471202,
0.4034743309,
-0.0583958216,
0.3974510133,
-0.0233102739,
0.4110554159,
-0.1494300067,
-0.5788661838,
0.5883355141,
-0.3078076541,
-0.2945581675,
-0.6304722428,
0.3672095835,
0.0877360627,
0.3985938728,
-0.4144457579,
0.2957020104,
0.45825845,
-0.0350577869,
-0.1528308392,
0.3996999264,
-0.166746214,
0.1765512973,
0.0108728129,
-0.0371446311,
0.3672332168,
0.0079083052,
0.2092932314,
-0.2773926556
] |
https://github.com/huggingface/datasets/issues/3423 | data duplicate when setting num_works > 1 with streaming data | > Hi ! Thanks for reporting :)
>
> When using a PyTorch's data loader with `num_workers>1` and an iterable dataset, each worker streams the exact same data by default, resulting in duplicate data when iterating using the data loader.
>
> We can probably fix this in `datasets` by checking `torch.utils.data.get_worker_info()` which gives the worker id if it happens.
Hi ! Thanks for reply
Do u have some plans to fix the problem?
| ## Describe the bug
The data is repeated num_works times when we load_dataset with streaming and set num_works > 1 when construct dataloader
## Steps to reproduce the bug
```python
# Sample code to reproduce the bug
import pandas as pd
import numpy as np
import os
from datasets import load_dataset
from torch.utils.data import DataLoader
from tqdm import tqdm
import shutil
NUM_OF_USER = 1000000
NUM_OF_ACTION = 50000
NUM_OF_SEQUENCE = 10000
NUM_OF_FILES = 32
NUM_OF_WORKERS = 16
if __name__ == "__main__":
shutil.rmtree("./dataset")
for i in range(NUM_OF_FILES):
sequence_data = pd.DataFrame(
{
"imei": np.random.randint(1, NUM_OF_USER, size=NUM_OF_SEQUENCE),
"sequence": np.random.randint(1, NUM_OF_ACTION, size=NUM_OF_SEQUENCE)
}
)
if not os.path.exists("./dataset"):
os.makedirs("./dataset")
sequence_data.to_csv(f"./dataset/sequence_data_{i}.csv",
index=False)
dataset = load_dataset("csv",
data_files=[os.path.join("./dataset",file) for file in os.listdir("./dataset") if file.endswith(".csv")],
split="train",
streaming=True).with_format("torch")
data_loader = DataLoader(dataset,
batch_size=1024,
num_workers=NUM_OF_WORKERS)
result = pd.DataFrame()
for i, batch in tqdm(enumerate(data_loader)):
result = pd.concat([result,
pd.DataFrame(batch)],
axis=0)
result.to_csv(f"num_work_{NUM_OF_WORKERS}.csv", index=False)
```
## Expected results
data do not duplicate
## Actual results
data duplicate NUM_OF_WORKERS = 16
![image](https://user-images.githubusercontent.com/16486492/145748707-9d2df25b-2f4f-4d7b-a83e-242be4fc8934.png)
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version:datasets==1.14.0
- Platform:transformers==4.11.3
- Python version:3.8
- PyArrow version:
| 74 | data duplicate when setting num_works > 1 with streaming data
## Describe the bug
The data is repeated num_works times when we load_dataset with streaming and set num_works > 1 when construct dataloader
## Steps to reproduce the bug
```python
# Sample code to reproduce the bug
import pandas as pd
import numpy as np
import os
from datasets import load_dataset
from torch.utils.data import DataLoader
from tqdm import tqdm
import shutil
NUM_OF_USER = 1000000
NUM_OF_ACTION = 50000
NUM_OF_SEQUENCE = 10000
NUM_OF_FILES = 32
NUM_OF_WORKERS = 16
if __name__ == "__main__":
shutil.rmtree("./dataset")
for i in range(NUM_OF_FILES):
sequence_data = pd.DataFrame(
{
"imei": np.random.randint(1, NUM_OF_USER, size=NUM_OF_SEQUENCE),
"sequence": np.random.randint(1, NUM_OF_ACTION, size=NUM_OF_SEQUENCE)
}
)
if not os.path.exists("./dataset"):
os.makedirs("./dataset")
sequence_data.to_csv(f"./dataset/sequence_data_{i}.csv",
index=False)
dataset = load_dataset("csv",
data_files=[os.path.join("./dataset",file) for file in os.listdir("./dataset") if file.endswith(".csv")],
split="train",
streaming=True).with_format("torch")
data_loader = DataLoader(dataset,
batch_size=1024,
num_workers=NUM_OF_WORKERS)
result = pd.DataFrame()
for i, batch in tqdm(enumerate(data_loader)):
result = pd.concat([result,
pd.DataFrame(batch)],
axis=0)
result.to_csv(f"num_work_{NUM_OF_WORKERS}.csv", index=False)
```
## Expected results
data do not duplicate
## Actual results
data duplicate NUM_OF_WORKERS = 16
![image](https://user-images.githubusercontent.com/16486492/145748707-9d2df25b-2f4f-4d7b-a83e-242be4fc8934.png)
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version:datasets==1.14.0
- Platform:transformers==4.11.3
- Python version:3.8
- PyArrow version:
> Hi ! Thanks for reporting :)
>
> When using a PyTorch's data loader with `num_workers>1` and an iterable dataset, each worker streams the exact same data by default, resulting in duplicate data when iterating using the data loader.
>
> We can probably fix this in `datasets` by checking `torch.utils.data.get_worker_info()` which gives the worker id if it happens.
Hi ! Thanks for reply
Do u have some plans to fix the problem?
| [
-0.232575953,
-0.3752961457,
-0.0161686987,
0.3272433281,
0.254571557,
-0.1762158871,
0.5691007376,
0.3358851373,
-0.2572708726,
0.421199739,
0.0956361741,
0.2009149492,
-0.0080959164,
0.1235197484,
0.144700557,
0.0096041495,
0.0426976569,
0.1493969113,
-0.2690355778,
0.1793185472,
-0.0729403421,
0.0054132892,
0.0089017423,
-0.1221663803,
-0.2812235951,
0.0286028441,
-0.0868533701,
0.2736003399,
0.1483578384,
-0.2246373594,
-0.1355646998,
0.0167593528,
0.2225170881,
0.7733385563,
-0.0001093749,
0.0273636896,
0.1163530201,
-0.056424357,
-0.2641803324,
-0.1926754713,
0.1805037111,
-0.1169929877,
0.1388168037,
-0.1363621056,
-0.0714548528,
-0.1025254056,
-0.1689471453,
-0.2384032756,
0.5982194543,
0.3020549715,
0.2001245022,
0.2040703297,
-0.2368645221,
0.0807682872,
-0.0227851067,
-0.1564833969,
-0.0560325533,
0.323571533,
0.4014079571,
0.2742699087,
-0.2470953017,
0.4327002168,
0.0168398749,
0.2134006023,
0.0467013717,
-0.0043556588,
0.1431002021,
-0.3292378187,
0.1463049948,
0.2457196862,
0.2474497706,
-0.2629604936,
-0.0524540432,
-0.1481212229,
0.0667593405,
-0.4061613381,
0.1443610489,
-0.0307432227,
-0.2216880769,
0.0767681003,
-0.0286441017,
0.3717752695,
-0.0570947118,
-0.1216569021,
0.0836961418,
-0.0682971105,
-0.0232118759,
0.1365586817,
0.1115456149,
-0.0734323412,
0.4617798328,
-0.1524796784,
0.0924358517,
-0.1511486322,
-0.5506556034,
-0.0842756256,
-0.1262447238,
-0.18125543,
-0.0152595062,
0.1713977307,
0.4865384996,
0.0704089031,
0.2151358128,
0.0869303197,
0.1190569177,
0.1585398614,
-0.2548934817,
-0.2556325197,
0.1860319674,
0.2502902448,
-0.3122908771,
-0.072654821,
0.1632324904,
-0.2154927254,
0.4953039587,
0.1664383411,
0.3587911129,
0.0031171637,
-0.2563692331,
0.0642858669,
-0.0471295379,
0.0858362317,
-0.0064097261,
0.1443856657,
-0.0242646653,
0.4580362737,
-0.1754567623,
0.1291881204,
-0.1905430257,
-0.4064302146,
-0.2643486559,
-0.1287216395,
-0.0944207013,
0.0119195068,
0.180719167,
-0.3319132924,
0.3005277216,
0.4278579056,
0.1608969569,
-0.3793379962,
0.4736733139,
-0.310723871,
0.0393359363,
0.0551883914,
0.0177808348,
0.2736403942,
0.3146783113,
0.1342144758,
0.1491898298,
0.2838484049,
-0.1892237812,
-0.2029173076,
-0.0568242669,
0.3010509014,
0.1310585439,
0.1251802146,
-0.0480440296,
0.0954206809,
0.0963972583,
-0.1041648388,
0.1092259288,
-0.1158669144,
-0.2004847974,
-0.2430848777,
-0.0550286956,
0.3452441394,
0.0651237667,
0.0787205696,
0.0774828419,
0.0190095287,
0.4452487528,
0.2374712229,
-0.1243970022,
0.111159794,
-0.285185039,
0.0325275883,
0.5462091565,
-0.2593693733,
-0.4046398103,
0.4371255636,
-0.3668297231,
0.1128629819,
0.4238320291,
0.3645485044,
0.3320660591,
-0.0692273229,
0.237993896,
0.1600595862,
-0.0987204909,
0.1280480325,
-0.3108530939,
-0.0816036239,
0.2053228915,
-0.0725030676,
-0.1776509583,
-0.0163214467,
0.1787858903,
-0.3957609832,
0.1258983761,
-0.0926750898,
0.0156174293,
-0.0106572742,
0.0279159751,
0.0100688934,
0.0942916572,
-0.1388716549,
-0.3768976033,
0.1278701723,
-0.0430594087,
-0.2299952358,
0.0710649118,
-0.2208883315,
-0.2414957434,
-0.2183570564,
-0.3691313863,
-0.2393306941,
0.2320527732,
0.2318074703,
-0.1677780896,
-0.4088276029,
-0.0711868256,
0.3986448348,
-0.270922929,
-0.1191243678,
-0.1939222515,
0.1301831454,
-0.1840546131,
-0.2086043209,
0.0535813943,
0.1124010533,
0.3394463956,
0.0721242651,
-0.1523097456,
0.3804547489,
0.1329360306,
0.3735527098,
-0.038091626,
-0.0956407934,
0.1595097333,
-0.0778009072,
-0.1383574307,
0.4598845541,
0.2602322698,
-0.0261142123,
-0.1658342928,
0.2862226367,
-0.3266169429,
-0.1722667515,
-0.0017229073,
-0.065285109,
0.2907440066,
-0.0369179882,
0.0375464037,
-0.1470053345,
0.2070091367,
0.1391850412,
0.0649997145,
0.0727383122,
-0.405975908,
0.209656328,
-0.1640549451,
-0.0075465953,
-0.00475865,
-0.2022501081,
-0.1684258133,
-0.1741589159,
0.1045864969,
0.1734927297,
0.5916929841,
0.2543932796,
0.0968850553,
-0.0018729728,
0.0082860813,
-0.1786676347,
0.1541017741,
-0.1791674048,
-0.183665812,
0.4155962765,
0.2356173694,
0.0200196095,
-0.4517162144,
-0.1200749353,
0.119653292,
0.2558179796,
-0.3397213221,
0.0509373583,
-0.2482746243,
0.0186311454,
-0.606431067,
-0.0510987341,
-0.000010234,
-0.1501995772,
-0.1013373956,
0.5159271955,
0.0118255392,
0.143835023,
-0.0190673526,
0.0992671326,
0.2845371962,
0.2305807024,
-0.0683516562,
0.1002191678,
-0.1617559344,
0.1221623048,
0.0412561782,
-0.0153149283,
0.454814285,
0.0532763042,
0.1019114777,
-0.5667012334,
-0.2578648925,
-0.0815544128,
0.1752305478,
0.5197483897,
0.0439645462,
0.163611114,
-0.0249476563,
-0.1216460988,
-0.1182224751,
-0.1421073377,
-0.2364524603,
0.0028132028,
-0.0856936872,
0.2417736501,
-0.2683660686,
-0.3805565238,
-0.0926021412,
-0.2641489208,
-0.0859280229,
-0.03914994,
0.2593416274,
0.0706427544,
0.0145754134,
0.1512506306,
0.4747600555,
0.1178864986,
-0.4887931049,
-0.4494748414,
0.161095202,
-0.1190936565,
-0.2410860509,
-0.1528856307,
-0.2208817005,
0.0288344547,
0.1341529191,
-0.4471953511,
-0.2873135209,
0.0889250189,
0.1785939634,
-0.239826709,
0.0668607131,
0.2155983895,
0.0780532807,
-0.2084505409,
-0.124240689,
0.1337824166,
-0.1466187984,
0.0573121719,
0.1487947702,
-0.0183943622,
0.4291378558,
0.0459715948,
0.484354347,
0.4392162263,
-0.1078845039,
0.2628548443,
-0.221682474,
0.1691560447,
-0.0023894452,
-0.2227885872,
0.0420335941,
-0.1378420889,
0.1540296525,
0.3252018988,
-0.1319096386,
0.0955434293,
-0.0142488955,
-0.0308306273,
-0.421865195,
-0.1347929686,
-0.0119806947,
-0.3076411188,
0.098223336,
0.0375870056,
-0.0054138214,
-0.0894386768,
-0.1637147069,
-0.2463334203,
0.2291080505,
-0.0954918563,
-0.0217901319,
0.0473622046,
0.1014093906,
-0.4657289386,
0.1351403892,
0.2343238741,
0.5233976245,
0.2992340922,
0.0203538407,
0.136978358,
-0.0041869474,
0.6461728811,
-0.3047169149,
0.0476736836,
-0.1932584345,
-0.1261408478,
-0.1682854742,
-0.0581339821,
-0.0846077576,
-0.0806838498,
0.1723971516,
0.4653706253,
0.0265069883,
-0.0148554202,
0.2174687684,
0.1550377607,
-0.1928663552,
-0.3623105586,
-0.3043017089,
-0.1657861769,
-0.2099126279,
0.0879315436,
-0.0795945525,
0.1049776077,
-0.2061510682,
-0.177376017,
-0.215195775,
-0.1180919632,
0.3505523801,
0.0371508859,
0.2076809108,
0.117569156,
0.1883310527,
0.198341161,
-0.0034398793,
0.0276818108,
0.2447553128,
-0.0347714089,
-0.1358008832,
0.1123774424,
-0.1470552087,
-0.0612301789,
0.2799743414,
-0.0463500097,
0.1913714856,
0.0878689736,
0.1661930084,
0.0228155982,
0.0068182377,
0.2787887156,
0.1595890671,
-0.1118461788,
-0.395503372,
0.2151824087,
0.1865969449,
-0.0263719372,
0.4284128845,
-0.6620622873,
-0.0693075955,
-0.1004177779,
-0.1200399473,
0.8012030721,
0.0864051655,
0.2501120269,
0.3097534776,
-0.441106081,
0.2539435923,
-0.1422570199,
0.0669219345,
-0.3592149317,
-0.5228200555,
-0.0282712132,
-0.2225419134,
0.1761112362,
-0.1735491604,
-0.4452694952,
0.3149872422,
-0.1891490966,
0.5836107731,
0.0185050443,
0.1185785756,
-0.1462282985,
-0.0395731404,
-0.1299455613,
0.1105904505,
-0.1269225031,
-0.0677937418,
-0.0709882602,
-0.0920867845,
0.168343693,
-0.204983443,
0.0975842699,
-0.0535733141,
-0.5762127638,
0.3885456324,
-0.1233952492,
-0.3521104753,
-0.2716169655,
0.1786541939,
0.1162146404,
-0.1140589565,
-0.0478193201,
-0.0510274284,
0.526525557,
0.3620860577,
-0.1496388018,
-0.1554919183,
0.428835988,
-0.0585505255,
-0.1998509169,
0.1820119917,
0.3065870702,
-0.0111220023,
-0.1905931085,
0.2617819309,
0.0260656197,
-0.3174489439,
-0.0009438712,
-0.1390988231,
-0.2691533864,
-0.377700299,
0.1506715119,
-0.1279238313,
-0.3933440149,
0.0299371388,
-0.0321401991,
-0.3152776957,
-0.262006551,
0.3653553724,
0.4884817004,
0.0139432382,
0.2156249136,
-0.1268915832,
-0.2012768537,
-0.2409163713,
0.2364681214,
-0.0645363182,
-0.4119770229,
0.3218462467,
-0.1883367151,
0.0247345325,
0.0609537512,
0.0677364245,
-0.0725697875,
0.3467039168,
-0.1514204293,
-0.2300658375,
-0.5069087148,
-0.2645509541,
0.0354065597,
0.3188835382,
0.0444840528,
0.3194245696,
-0.0256970953,
0.0955407172,
-0.3671633899,
0.1582467854,
0.0879701898,
0.3427937925,
0.0873424783,
-0.1522430629,
0.0005403492,
0.2912174165,
0.155146867,
0.3171488345,
-0.2249580026,
-0.3285801709,
-0.2647249997,
0.1057538912,
-0.1502897292,
-0.1710045338,
-0.3112558126,
0.0084038805,
-0.0470641069,
-0.1014044434,
0.1801440269,
0.0556426384,
0.1147338748,
-0.0376476869,
0.4749485552,
0.0470995158,
-0.0665547848,
-0.0082190698,
-0.2510852218,
0.1600515246,
-0.001483725,
-0.0181242861,
-0.1668705195,
-0.0752054751,
-0.3852079213,
-0.1256996542,
0.2910532951,
0.0289067496,
0.0514651537,
-0.2525205314,
-0.0977330729,
0.0498849973,
0.2729039788,
0.2360826433,
-0.3120245934,
-0.2801553905,
0.0210351031,
0.2392579466,
-0.3121617436,
-0.0398395844,
-0.0378115922,
-0.0988773033,
0.1698572189,
0.3003664613,
0.1743740439,
-0.3612979054,
-0.01045678,
-0.1054110005,
-0.0099790795,
-0.4217979908,
0.127356261,
0.2815951407,
-0.0306152776,
-0.1822191775,
0.2722438872,
0.0665353909,
-0.0620772205,
0.139346838,
-0.0178823974,
0.1360493749,
0.1372889429,
-0.0290609896,
-0.1934634745,
-0.1284843385,
0.0366067216,
0.2566311657,
-0.521482408,
0.1776340157,
0.2164945602,
0.1239331141,
-0.116606392,
0.0941545665,
-0.058331836,
0.0959786549,
-0.3209308386,
-0.132339716,
0.180310607,
-0.0214880873,
-0.2110702991,
-0.071096614,
0.0528353751,
0.3617663682,
-0.015877191,
0.3496361077,
-0.1326559037,
-0.2699390352,
-0.1952128112,
0.4980935156,
-0.019497985,
-0.3491037488,
0.110523358,
0.4241358936,
0.2394896895,
0.1648161709,
0.1961564273,
0.5627021194,
0.3440356553,
-0.1720213741,
0.0585061014,
0.1696974933,
-0.030498514,
-0.0836497992,
-0.0755369961,
0.0568408072,
0.0500526875,
0.2399840504,
0.1664672792,
-0.2357577682,
0.003071971,
0.2274904847,
-0.1396827847,
-0.5591310859,
0.3070270717,
0.0002791799,
0.0034610496,
-0.1033052132,
0.1001996994,
-0.4988170564,
0.0374831669,
0.2939960361,
-0.0956988484,
0.206319347,
-0.1676300764,
0.1177940443,
-0.1041228324,
0.3071419597,
-0.0495376065,
0.0543714911,
-0.3376259804,
-0.0499860533,
-0.7678493261,
0.173656404,
0.0997275636,
0.1303597838,
0.1125439331,
0.1695895791,
-0.3727913201,
0.0537747182,
0.1624019593,
-0.0016957116,
0.0444720313,
0.2206200659,
-0.3652908802,
-0.2507268786,
-0.3343899846,
0.0296970606,
0.1035117134,
-0.4949091971,
0.3291401863,
-0.1104037911,
0.2040228546,
0.0616560504,
-0.1067567095,
0.0815832838,
0.2937067747,
0.3502361178,
0.0903141126,
0.294501394,
-0.1944580376,
0.1323443502,
-0.0687395856,
-0.035848368,
-0.2151158601,
0.092779994,
0.3993166685,
0.210215643,
0.0204806253,
-0.3557466567,
-0.2885124683,
0.4376610518,
0.2642537951,
-0.120663099,
-0.1990336627,
0.1214664802,
-0.1278471202,
0.4034743309,
-0.0583958216,
0.3974510133,
-0.0233102739,
0.4110554159,
-0.1494300067,
-0.5788661838,
0.5883355141,
-0.3078076541,
-0.2945581675,
-0.6304722428,
0.3672095835,
0.0877360627,
0.3985938728,
-0.4144457579,
0.2957020104,
0.45825845,
-0.0350577869,
-0.1528308392,
0.3996999264,
-0.166746214,
0.1765512973,
0.0108728129,
-0.0371446311,
0.3672332168,
0.0079083052,
0.2092932314,
-0.2773926556
] |
https://github.com/huggingface/datasets/issues/3423 | data duplicate when setting num_works > 1 with streaming data | Isn’t that somehow a bug on PyTorch side? (Just asking because this behavior seems quite general and maybe not what would be intended) | ## Describe the bug
The data is repeated num_works times when we load_dataset with streaming and set num_works > 1 when construct dataloader
## Steps to reproduce the bug
```python
# Sample code to reproduce the bug
import pandas as pd
import numpy as np
import os
from datasets import load_dataset
from torch.utils.data import DataLoader
from tqdm import tqdm
import shutil
NUM_OF_USER = 1000000
NUM_OF_ACTION = 50000
NUM_OF_SEQUENCE = 10000
NUM_OF_FILES = 32
NUM_OF_WORKERS = 16
if __name__ == "__main__":
shutil.rmtree("./dataset")
for i in range(NUM_OF_FILES):
sequence_data = pd.DataFrame(
{
"imei": np.random.randint(1, NUM_OF_USER, size=NUM_OF_SEQUENCE),
"sequence": np.random.randint(1, NUM_OF_ACTION, size=NUM_OF_SEQUENCE)
}
)
if not os.path.exists("./dataset"):
os.makedirs("./dataset")
sequence_data.to_csv(f"./dataset/sequence_data_{i}.csv",
index=False)
dataset = load_dataset("csv",
data_files=[os.path.join("./dataset",file) for file in os.listdir("./dataset") if file.endswith(".csv")],
split="train",
streaming=True).with_format("torch")
data_loader = DataLoader(dataset,
batch_size=1024,
num_workers=NUM_OF_WORKERS)
result = pd.DataFrame()
for i, batch in tqdm(enumerate(data_loader)):
result = pd.concat([result,
pd.DataFrame(batch)],
axis=0)
result.to_csv(f"num_work_{NUM_OF_WORKERS}.csv", index=False)
```
## Expected results
data do not duplicate
## Actual results
data duplicate NUM_OF_WORKERS = 16
![image](https://user-images.githubusercontent.com/16486492/145748707-9d2df25b-2f4f-4d7b-a83e-242be4fc8934.png)
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version:datasets==1.14.0
- Platform:transformers==4.11.3
- Python version:3.8
- PyArrow version:
| 23 | data duplicate when setting num_works > 1 with streaming data
## Describe the bug
The data is repeated num_works times when we load_dataset with streaming and set num_works > 1 when construct dataloader
## Steps to reproduce the bug
```python
# Sample code to reproduce the bug
import pandas as pd
import numpy as np
import os
from datasets import load_dataset
from torch.utils.data import DataLoader
from tqdm import tqdm
import shutil
NUM_OF_USER = 1000000
NUM_OF_ACTION = 50000
NUM_OF_SEQUENCE = 10000
NUM_OF_FILES = 32
NUM_OF_WORKERS = 16
if __name__ == "__main__":
shutil.rmtree("./dataset")
for i in range(NUM_OF_FILES):
sequence_data = pd.DataFrame(
{
"imei": np.random.randint(1, NUM_OF_USER, size=NUM_OF_SEQUENCE),
"sequence": np.random.randint(1, NUM_OF_ACTION, size=NUM_OF_SEQUENCE)
}
)
if not os.path.exists("./dataset"):
os.makedirs("./dataset")
sequence_data.to_csv(f"./dataset/sequence_data_{i}.csv",
index=False)
dataset = load_dataset("csv",
data_files=[os.path.join("./dataset",file) for file in os.listdir("./dataset") if file.endswith(".csv")],
split="train",
streaming=True).with_format("torch")
data_loader = DataLoader(dataset,
batch_size=1024,
num_workers=NUM_OF_WORKERS)
result = pd.DataFrame()
for i, batch in tqdm(enumerate(data_loader)):
result = pd.concat([result,
pd.DataFrame(batch)],
axis=0)
result.to_csv(f"num_work_{NUM_OF_WORKERS}.csv", index=False)
```
## Expected results
data do not duplicate
## Actual results
data duplicate NUM_OF_WORKERS = 16
![image](https://user-images.githubusercontent.com/16486492/145748707-9d2df25b-2f4f-4d7b-a83e-242be4fc8934.png)
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version:datasets==1.14.0
- Platform:transformers==4.11.3
- Python version:3.8
- PyArrow version:
Isn’t that somehow a bug on PyTorch side? (Just asking because this behavior seems quite general and maybe not what would be intended) | [
-0.232575953,
-0.3752961457,
-0.0161686987,
0.3272433281,
0.254571557,
-0.1762158871,
0.5691007376,
0.3358851373,
-0.2572708726,
0.421199739,
0.0956361741,
0.2009149492,
-0.0080959164,
0.1235197484,
0.144700557,
0.0096041495,
0.0426976569,
0.1493969113,
-0.2690355778,
0.1793185472,
-0.0729403421,
0.0054132892,
0.0089017423,
-0.1221663803,
-0.2812235951,
0.0286028441,
-0.0868533701,
0.2736003399,
0.1483578384,
-0.2246373594,
-0.1355646998,
0.0167593528,
0.2225170881,
0.7733385563,
-0.0001093749,
0.0273636896,
0.1163530201,
-0.056424357,
-0.2641803324,
-0.1926754713,
0.1805037111,
-0.1169929877,
0.1388168037,
-0.1363621056,
-0.0714548528,
-0.1025254056,
-0.1689471453,
-0.2384032756,
0.5982194543,
0.3020549715,
0.2001245022,
0.2040703297,
-0.2368645221,
0.0807682872,
-0.0227851067,
-0.1564833969,
-0.0560325533,
0.323571533,
0.4014079571,
0.2742699087,
-0.2470953017,
0.4327002168,
0.0168398749,
0.2134006023,
0.0467013717,
-0.0043556588,
0.1431002021,
-0.3292378187,
0.1463049948,
0.2457196862,
0.2474497706,
-0.2629604936,
-0.0524540432,
-0.1481212229,
0.0667593405,
-0.4061613381,
0.1443610489,
-0.0307432227,
-0.2216880769,
0.0767681003,
-0.0286441017,
0.3717752695,
-0.0570947118,
-0.1216569021,
0.0836961418,
-0.0682971105,
-0.0232118759,
0.1365586817,
0.1115456149,
-0.0734323412,
0.4617798328,
-0.1524796784,
0.0924358517,
-0.1511486322,
-0.5506556034,
-0.0842756256,
-0.1262447238,
-0.18125543,
-0.0152595062,
0.1713977307,
0.4865384996,
0.0704089031,
0.2151358128,
0.0869303197,
0.1190569177,
0.1585398614,
-0.2548934817,
-0.2556325197,
0.1860319674,
0.2502902448,
-0.3122908771,
-0.072654821,
0.1632324904,
-0.2154927254,
0.4953039587,
0.1664383411,
0.3587911129,
0.0031171637,
-0.2563692331,
0.0642858669,
-0.0471295379,
0.0858362317,
-0.0064097261,
0.1443856657,
-0.0242646653,
0.4580362737,
-0.1754567623,
0.1291881204,
-0.1905430257,
-0.4064302146,
-0.2643486559,
-0.1287216395,
-0.0944207013,
0.0119195068,
0.180719167,
-0.3319132924,
0.3005277216,
0.4278579056,
0.1608969569,
-0.3793379962,
0.4736733139,
-0.310723871,
0.0393359363,
0.0551883914,
0.0177808348,
0.2736403942,
0.3146783113,
0.1342144758,
0.1491898298,
0.2838484049,
-0.1892237812,
-0.2029173076,
-0.0568242669,
0.3010509014,
0.1310585439,
0.1251802146,
-0.0480440296,
0.0954206809,
0.0963972583,
-0.1041648388,
0.1092259288,
-0.1158669144,
-0.2004847974,
-0.2430848777,
-0.0550286956,
0.3452441394,
0.0651237667,
0.0787205696,
0.0774828419,
0.0190095287,
0.4452487528,
0.2374712229,
-0.1243970022,
0.111159794,
-0.285185039,
0.0325275883,
0.5462091565,
-0.2593693733,
-0.4046398103,
0.4371255636,
-0.3668297231,
0.1128629819,
0.4238320291,
0.3645485044,
0.3320660591,
-0.0692273229,
0.237993896,
0.1600595862,
-0.0987204909,
0.1280480325,
-0.3108530939,
-0.0816036239,
0.2053228915,
-0.0725030676,
-0.1776509583,
-0.0163214467,
0.1787858903,
-0.3957609832,
0.1258983761,
-0.0926750898,
0.0156174293,
-0.0106572742,
0.0279159751,
0.0100688934,
0.0942916572,
-0.1388716549,
-0.3768976033,
0.1278701723,
-0.0430594087,
-0.2299952358,
0.0710649118,
-0.2208883315,
-0.2414957434,
-0.2183570564,
-0.3691313863,
-0.2393306941,
0.2320527732,
0.2318074703,
-0.1677780896,
-0.4088276029,
-0.0711868256,
0.3986448348,
-0.270922929,
-0.1191243678,
-0.1939222515,
0.1301831454,
-0.1840546131,
-0.2086043209,
0.0535813943,
0.1124010533,
0.3394463956,
0.0721242651,
-0.1523097456,
0.3804547489,
0.1329360306,
0.3735527098,
-0.038091626,
-0.0956407934,
0.1595097333,
-0.0778009072,
-0.1383574307,
0.4598845541,
0.2602322698,
-0.0261142123,
-0.1658342928,
0.2862226367,
-0.3266169429,
-0.1722667515,
-0.0017229073,
-0.065285109,
0.2907440066,
-0.0369179882,
0.0375464037,
-0.1470053345,
0.2070091367,
0.1391850412,
0.0649997145,
0.0727383122,
-0.405975908,
0.209656328,
-0.1640549451,
-0.0075465953,
-0.00475865,
-0.2022501081,
-0.1684258133,
-0.1741589159,
0.1045864969,
0.1734927297,
0.5916929841,
0.2543932796,
0.0968850553,
-0.0018729728,
0.0082860813,
-0.1786676347,
0.1541017741,
-0.1791674048,
-0.183665812,
0.4155962765,
0.2356173694,
0.0200196095,
-0.4517162144,
-0.1200749353,
0.119653292,
0.2558179796,
-0.3397213221,
0.0509373583,
-0.2482746243,
0.0186311454,
-0.606431067,
-0.0510987341,
-0.000010234,
-0.1501995772,
-0.1013373956,
0.5159271955,
0.0118255392,
0.143835023,
-0.0190673526,
0.0992671326,
0.2845371962,
0.2305807024,
-0.0683516562,
0.1002191678,
-0.1617559344,
0.1221623048,
0.0412561782,
-0.0153149283,
0.454814285,
0.0532763042,
0.1019114777,
-0.5667012334,
-0.2578648925,
-0.0815544128,
0.1752305478,
0.5197483897,
0.0439645462,
0.163611114,
-0.0249476563,
-0.1216460988,
-0.1182224751,
-0.1421073377,
-0.2364524603,
0.0028132028,
-0.0856936872,
0.2417736501,
-0.2683660686,
-0.3805565238,
-0.0926021412,
-0.2641489208,
-0.0859280229,
-0.03914994,
0.2593416274,
0.0706427544,
0.0145754134,
0.1512506306,
0.4747600555,
0.1178864986,
-0.4887931049,
-0.4494748414,
0.161095202,
-0.1190936565,
-0.2410860509,
-0.1528856307,
-0.2208817005,
0.0288344547,
0.1341529191,
-0.4471953511,
-0.2873135209,
0.0889250189,
0.1785939634,
-0.239826709,
0.0668607131,
0.2155983895,
0.0780532807,
-0.2084505409,
-0.124240689,
0.1337824166,
-0.1466187984,
0.0573121719,
0.1487947702,
-0.0183943622,
0.4291378558,
0.0459715948,
0.484354347,
0.4392162263,
-0.1078845039,
0.2628548443,
-0.221682474,
0.1691560447,
-0.0023894452,
-0.2227885872,
0.0420335941,
-0.1378420889,
0.1540296525,
0.3252018988,
-0.1319096386,
0.0955434293,
-0.0142488955,
-0.0308306273,
-0.421865195,
-0.1347929686,
-0.0119806947,
-0.3076411188,
0.098223336,
0.0375870056,
-0.0054138214,
-0.0894386768,
-0.1637147069,
-0.2463334203,
0.2291080505,
-0.0954918563,
-0.0217901319,
0.0473622046,
0.1014093906,
-0.4657289386,
0.1351403892,
0.2343238741,
0.5233976245,
0.2992340922,
0.0203538407,
0.136978358,
-0.0041869474,
0.6461728811,
-0.3047169149,
0.0476736836,
-0.1932584345,
-0.1261408478,
-0.1682854742,
-0.0581339821,
-0.0846077576,
-0.0806838498,
0.1723971516,
0.4653706253,
0.0265069883,
-0.0148554202,
0.2174687684,
0.1550377607,
-0.1928663552,
-0.3623105586,
-0.3043017089,
-0.1657861769,
-0.2099126279,
0.0879315436,
-0.0795945525,
0.1049776077,
-0.2061510682,
-0.177376017,
-0.215195775,
-0.1180919632,
0.3505523801,
0.0371508859,
0.2076809108,
0.117569156,
0.1883310527,
0.198341161,
-0.0034398793,
0.0276818108,
0.2447553128,
-0.0347714089,
-0.1358008832,
0.1123774424,
-0.1470552087,
-0.0612301789,
0.2799743414,
-0.0463500097,
0.1913714856,
0.0878689736,
0.1661930084,
0.0228155982,
0.0068182377,
0.2787887156,
0.1595890671,
-0.1118461788,
-0.395503372,
0.2151824087,
0.1865969449,
-0.0263719372,
0.4284128845,
-0.6620622873,
-0.0693075955,
-0.1004177779,
-0.1200399473,
0.8012030721,
0.0864051655,
0.2501120269,
0.3097534776,
-0.441106081,
0.2539435923,
-0.1422570199,
0.0669219345,
-0.3592149317,
-0.5228200555,
-0.0282712132,
-0.2225419134,
0.1761112362,
-0.1735491604,
-0.4452694952,
0.3149872422,
-0.1891490966,
0.5836107731,
0.0185050443,
0.1185785756,
-0.1462282985,
-0.0395731404,
-0.1299455613,
0.1105904505,
-0.1269225031,
-0.0677937418,
-0.0709882602,
-0.0920867845,
0.168343693,
-0.204983443,
0.0975842699,
-0.0535733141,
-0.5762127638,
0.3885456324,
-0.1233952492,
-0.3521104753,
-0.2716169655,
0.1786541939,
0.1162146404,
-0.1140589565,
-0.0478193201,
-0.0510274284,
0.526525557,
0.3620860577,
-0.1496388018,
-0.1554919183,
0.428835988,
-0.0585505255,
-0.1998509169,
0.1820119917,
0.3065870702,
-0.0111220023,
-0.1905931085,
0.2617819309,
0.0260656197,
-0.3174489439,
-0.0009438712,
-0.1390988231,
-0.2691533864,
-0.377700299,
0.1506715119,
-0.1279238313,
-0.3933440149,
0.0299371388,
-0.0321401991,
-0.3152776957,
-0.262006551,
0.3653553724,
0.4884817004,
0.0139432382,
0.2156249136,
-0.1268915832,
-0.2012768537,
-0.2409163713,
0.2364681214,
-0.0645363182,
-0.4119770229,
0.3218462467,
-0.1883367151,
0.0247345325,
0.0609537512,
0.0677364245,
-0.0725697875,
0.3467039168,
-0.1514204293,
-0.2300658375,
-0.5069087148,
-0.2645509541,
0.0354065597,
0.3188835382,
0.0444840528,
0.3194245696,
-0.0256970953,
0.0955407172,
-0.3671633899,
0.1582467854,
0.0879701898,
0.3427937925,
0.0873424783,
-0.1522430629,
0.0005403492,
0.2912174165,
0.155146867,
0.3171488345,
-0.2249580026,
-0.3285801709,
-0.2647249997,
0.1057538912,
-0.1502897292,
-0.1710045338,
-0.3112558126,
0.0084038805,
-0.0470641069,
-0.1014044434,
0.1801440269,
0.0556426384,
0.1147338748,
-0.0376476869,
0.4749485552,
0.0470995158,
-0.0665547848,
-0.0082190698,
-0.2510852218,
0.1600515246,
-0.001483725,
-0.0181242861,
-0.1668705195,
-0.0752054751,
-0.3852079213,
-0.1256996542,
0.2910532951,
0.0289067496,
0.0514651537,
-0.2525205314,
-0.0977330729,
0.0498849973,
0.2729039788,
0.2360826433,
-0.3120245934,
-0.2801553905,
0.0210351031,
0.2392579466,
-0.3121617436,
-0.0398395844,
-0.0378115922,
-0.0988773033,
0.1698572189,
0.3003664613,
0.1743740439,
-0.3612979054,
-0.01045678,
-0.1054110005,
-0.0099790795,
-0.4217979908,
0.127356261,
0.2815951407,
-0.0306152776,
-0.1822191775,
0.2722438872,
0.0665353909,
-0.0620772205,
0.139346838,
-0.0178823974,
0.1360493749,
0.1372889429,
-0.0290609896,
-0.1934634745,
-0.1284843385,
0.0366067216,
0.2566311657,
-0.521482408,
0.1776340157,
0.2164945602,
0.1239331141,
-0.116606392,
0.0941545665,
-0.058331836,
0.0959786549,
-0.3209308386,
-0.132339716,
0.180310607,
-0.0214880873,
-0.2110702991,
-0.071096614,
0.0528353751,
0.3617663682,
-0.015877191,
0.3496361077,
-0.1326559037,
-0.2699390352,
-0.1952128112,
0.4980935156,
-0.019497985,
-0.3491037488,
0.110523358,
0.4241358936,
0.2394896895,
0.1648161709,
0.1961564273,
0.5627021194,
0.3440356553,
-0.1720213741,
0.0585061014,
0.1696974933,
-0.030498514,
-0.0836497992,
-0.0755369961,
0.0568408072,
0.0500526875,
0.2399840504,
0.1664672792,
-0.2357577682,
0.003071971,
0.2274904847,
-0.1396827847,
-0.5591310859,
0.3070270717,
0.0002791799,
0.0034610496,
-0.1033052132,
0.1001996994,
-0.4988170564,
0.0374831669,
0.2939960361,
-0.0956988484,
0.206319347,
-0.1676300764,
0.1177940443,
-0.1041228324,
0.3071419597,
-0.0495376065,
0.0543714911,
-0.3376259804,
-0.0499860533,
-0.7678493261,
0.173656404,
0.0997275636,
0.1303597838,
0.1125439331,
0.1695895791,
-0.3727913201,
0.0537747182,
0.1624019593,
-0.0016957116,
0.0444720313,
0.2206200659,
-0.3652908802,
-0.2507268786,
-0.3343899846,
0.0296970606,
0.1035117134,
-0.4949091971,
0.3291401863,
-0.1104037911,
0.2040228546,
0.0616560504,
-0.1067567095,
0.0815832838,
0.2937067747,
0.3502361178,
0.0903141126,
0.294501394,
-0.1944580376,
0.1323443502,
-0.0687395856,
-0.035848368,
-0.2151158601,
0.092779994,
0.3993166685,
0.210215643,
0.0204806253,
-0.3557466567,
-0.2885124683,
0.4376610518,
0.2642537951,
-0.120663099,
-0.1990336627,
0.1214664802,
-0.1278471202,
0.4034743309,
-0.0583958216,
0.3974510133,
-0.0233102739,
0.4110554159,
-0.1494300067,
-0.5788661838,
0.5883355141,
-0.3078076541,
-0.2945581675,
-0.6304722428,
0.3672095835,
0.0877360627,
0.3985938728,
-0.4144457579,
0.2957020104,
0.45825845,
-0.0350577869,
-0.1528308392,
0.3996999264,
-0.166746214,
0.1765512973,
0.0108728129,
-0.0371446311,
0.3672332168,
0.0079083052,
0.2092932314,
-0.2773926556
] |
https://github.com/huggingface/datasets/issues/3423 | data duplicate when setting num_works > 1 with streaming data | From PyTorch's documentation [here](https://pytorch.org/docs/stable/data.html#dataset-types):
> When using an IterableDataset with multi-process data loading. The same dataset object is replicated on each worker process, and thus the replicas must be configured differently to avoid duplicated data. See [IterableDataset](https://pytorch.org/docs/stable/data.html#torch.utils.data.IterableDataset) documentations for how to achieve this.
It looks like an intended behavior from PyTorch
As suggested in the [docstring of the IterableDataset class](https://pytorch.org/docs/stable/data.html#torch.utils.data.IterableDataset), we could pass a `worker_init_fn` to the DataLoader to fix this. It could be called `streaming_worker_init_fn` for example.
However, while this solution works, I'm worried that many users simply don't know about this parameter and just start their training with duplicate data without knowing it. That's why I'm more in favor of integrating the check on the worker id directly in `datasets` in our implementation of `IterableDataset.__iter__`. | ## Describe the bug
The data is repeated num_works times when we load_dataset with streaming and set num_works > 1 when construct dataloader
## Steps to reproduce the bug
```python
# Sample code to reproduce the bug
import pandas as pd
import numpy as np
import os
from datasets import load_dataset
from torch.utils.data import DataLoader
from tqdm import tqdm
import shutil
NUM_OF_USER = 1000000
NUM_OF_ACTION = 50000
NUM_OF_SEQUENCE = 10000
NUM_OF_FILES = 32
NUM_OF_WORKERS = 16
if __name__ == "__main__":
shutil.rmtree("./dataset")
for i in range(NUM_OF_FILES):
sequence_data = pd.DataFrame(
{
"imei": np.random.randint(1, NUM_OF_USER, size=NUM_OF_SEQUENCE),
"sequence": np.random.randint(1, NUM_OF_ACTION, size=NUM_OF_SEQUENCE)
}
)
if not os.path.exists("./dataset"):
os.makedirs("./dataset")
sequence_data.to_csv(f"./dataset/sequence_data_{i}.csv",
index=False)
dataset = load_dataset("csv",
data_files=[os.path.join("./dataset",file) for file in os.listdir("./dataset") if file.endswith(".csv")],
split="train",
streaming=True).with_format("torch")
data_loader = DataLoader(dataset,
batch_size=1024,
num_workers=NUM_OF_WORKERS)
result = pd.DataFrame()
for i, batch in tqdm(enumerate(data_loader)):
result = pd.concat([result,
pd.DataFrame(batch)],
axis=0)
result.to_csv(f"num_work_{NUM_OF_WORKERS}.csv", index=False)
```
## Expected results
data do not duplicate
## Actual results
data duplicate NUM_OF_WORKERS = 16
![image](https://user-images.githubusercontent.com/16486492/145748707-9d2df25b-2f4f-4d7b-a83e-242be4fc8934.png)
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version:datasets==1.14.0
- Platform:transformers==4.11.3
- Python version:3.8
- PyArrow version:
| 127 | data duplicate when setting num_works > 1 with streaming data
## Describe the bug
The data is repeated num_works times when we load_dataset with streaming and set num_works > 1 when construct dataloader
## Steps to reproduce the bug
```python
# Sample code to reproduce the bug
import pandas as pd
import numpy as np
import os
from datasets import load_dataset
from torch.utils.data import DataLoader
from tqdm import tqdm
import shutil
NUM_OF_USER = 1000000
NUM_OF_ACTION = 50000
NUM_OF_SEQUENCE = 10000
NUM_OF_FILES = 32
NUM_OF_WORKERS = 16
if __name__ == "__main__":
shutil.rmtree("./dataset")
for i in range(NUM_OF_FILES):
sequence_data = pd.DataFrame(
{
"imei": np.random.randint(1, NUM_OF_USER, size=NUM_OF_SEQUENCE),
"sequence": np.random.randint(1, NUM_OF_ACTION, size=NUM_OF_SEQUENCE)
}
)
if not os.path.exists("./dataset"):
os.makedirs("./dataset")
sequence_data.to_csv(f"./dataset/sequence_data_{i}.csv",
index=False)
dataset = load_dataset("csv",
data_files=[os.path.join("./dataset",file) for file in os.listdir("./dataset") if file.endswith(".csv")],
split="train",
streaming=True).with_format("torch")
data_loader = DataLoader(dataset,
batch_size=1024,
num_workers=NUM_OF_WORKERS)
result = pd.DataFrame()
for i, batch in tqdm(enumerate(data_loader)):
result = pd.concat([result,
pd.DataFrame(batch)],
axis=0)
result.to_csv(f"num_work_{NUM_OF_WORKERS}.csv", index=False)
```
## Expected results
data do not duplicate
## Actual results
data duplicate NUM_OF_WORKERS = 16
![image](https://user-images.githubusercontent.com/16486492/145748707-9d2df25b-2f4f-4d7b-a83e-242be4fc8934.png)
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version:datasets==1.14.0
- Platform:transformers==4.11.3
- Python version:3.8
- PyArrow version:
From PyTorch's documentation [here](https://pytorch.org/docs/stable/data.html#dataset-types):
> When using an IterableDataset with multi-process data loading. The same dataset object is replicated on each worker process, and thus the replicas must be configured differently to avoid duplicated data. See [IterableDataset](https://pytorch.org/docs/stable/data.html#torch.utils.data.IterableDataset) documentations for how to achieve this.
It looks like an intended behavior from PyTorch
As suggested in the [docstring of the IterableDataset class](https://pytorch.org/docs/stable/data.html#torch.utils.data.IterableDataset), we could pass a `worker_init_fn` to the DataLoader to fix this. It could be called `streaming_worker_init_fn` for example.
However, while this solution works, I'm worried that many users simply don't know about this parameter and just start their training with duplicate data without knowing it. That's why I'm more in favor of integrating the check on the worker id directly in `datasets` in our implementation of `IterableDataset.__iter__`. | [
-0.232575953,
-0.3752961457,
-0.0161686987,
0.3272433281,
0.254571557,
-0.1762158871,
0.5691007376,
0.3358851373,
-0.2572708726,
0.421199739,
0.0956361741,
0.2009149492,
-0.0080959164,
0.1235197484,
0.144700557,
0.0096041495,
0.0426976569,
0.1493969113,
-0.2690355778,
0.1793185472,
-0.0729403421,
0.0054132892,
0.0089017423,
-0.1221663803,
-0.2812235951,
0.0286028441,
-0.0868533701,
0.2736003399,
0.1483578384,
-0.2246373594,
-0.1355646998,
0.0167593528,
0.2225170881,
0.7733385563,
-0.0001093749,
0.0273636896,
0.1163530201,
-0.056424357,
-0.2641803324,
-0.1926754713,
0.1805037111,
-0.1169929877,
0.1388168037,
-0.1363621056,
-0.0714548528,
-0.1025254056,
-0.1689471453,
-0.2384032756,
0.5982194543,
0.3020549715,
0.2001245022,
0.2040703297,
-0.2368645221,
0.0807682872,
-0.0227851067,
-0.1564833969,
-0.0560325533,
0.323571533,
0.4014079571,
0.2742699087,
-0.2470953017,
0.4327002168,
0.0168398749,
0.2134006023,
0.0467013717,
-0.0043556588,
0.1431002021,
-0.3292378187,
0.1463049948,
0.2457196862,
0.2474497706,
-0.2629604936,
-0.0524540432,
-0.1481212229,
0.0667593405,
-0.4061613381,
0.1443610489,
-0.0307432227,
-0.2216880769,
0.0767681003,
-0.0286441017,
0.3717752695,
-0.0570947118,
-0.1216569021,
0.0836961418,
-0.0682971105,
-0.0232118759,
0.1365586817,
0.1115456149,
-0.0734323412,
0.4617798328,
-0.1524796784,
0.0924358517,
-0.1511486322,
-0.5506556034,
-0.0842756256,
-0.1262447238,
-0.18125543,
-0.0152595062,
0.1713977307,
0.4865384996,
0.0704089031,
0.2151358128,
0.0869303197,
0.1190569177,
0.1585398614,
-0.2548934817,
-0.2556325197,
0.1860319674,
0.2502902448,
-0.3122908771,
-0.072654821,
0.1632324904,
-0.2154927254,
0.4953039587,
0.1664383411,
0.3587911129,
0.0031171637,
-0.2563692331,
0.0642858669,
-0.0471295379,
0.0858362317,
-0.0064097261,
0.1443856657,
-0.0242646653,
0.4580362737,
-0.1754567623,
0.1291881204,
-0.1905430257,
-0.4064302146,
-0.2643486559,
-0.1287216395,
-0.0944207013,
0.0119195068,
0.180719167,
-0.3319132924,
0.3005277216,
0.4278579056,
0.1608969569,
-0.3793379962,
0.4736733139,
-0.310723871,
0.0393359363,
0.0551883914,
0.0177808348,
0.2736403942,
0.3146783113,
0.1342144758,
0.1491898298,
0.2838484049,
-0.1892237812,
-0.2029173076,
-0.0568242669,
0.3010509014,
0.1310585439,
0.1251802146,
-0.0480440296,
0.0954206809,
0.0963972583,
-0.1041648388,
0.1092259288,
-0.1158669144,
-0.2004847974,
-0.2430848777,
-0.0550286956,
0.3452441394,
0.0651237667,
0.0787205696,
0.0774828419,
0.0190095287,
0.4452487528,
0.2374712229,
-0.1243970022,
0.111159794,
-0.285185039,
0.0325275883,
0.5462091565,
-0.2593693733,
-0.4046398103,
0.4371255636,
-0.3668297231,
0.1128629819,
0.4238320291,
0.3645485044,
0.3320660591,
-0.0692273229,
0.237993896,
0.1600595862,
-0.0987204909,
0.1280480325,
-0.3108530939,
-0.0816036239,
0.2053228915,
-0.0725030676,
-0.1776509583,
-0.0163214467,
0.1787858903,
-0.3957609832,
0.1258983761,
-0.0926750898,
0.0156174293,
-0.0106572742,
0.0279159751,
0.0100688934,
0.0942916572,
-0.1388716549,
-0.3768976033,
0.1278701723,
-0.0430594087,
-0.2299952358,
0.0710649118,
-0.2208883315,
-0.2414957434,
-0.2183570564,
-0.3691313863,
-0.2393306941,
0.2320527732,
0.2318074703,
-0.1677780896,
-0.4088276029,
-0.0711868256,
0.3986448348,
-0.270922929,
-0.1191243678,
-0.1939222515,
0.1301831454,
-0.1840546131,
-0.2086043209,
0.0535813943,
0.1124010533,
0.3394463956,
0.0721242651,
-0.1523097456,
0.3804547489,
0.1329360306,
0.3735527098,
-0.038091626,
-0.0956407934,
0.1595097333,
-0.0778009072,
-0.1383574307,
0.4598845541,
0.2602322698,
-0.0261142123,
-0.1658342928,
0.2862226367,
-0.3266169429,
-0.1722667515,
-0.0017229073,
-0.065285109,
0.2907440066,
-0.0369179882,
0.0375464037,
-0.1470053345,
0.2070091367,
0.1391850412,
0.0649997145,
0.0727383122,
-0.405975908,
0.209656328,
-0.1640549451,
-0.0075465953,
-0.00475865,
-0.2022501081,
-0.1684258133,
-0.1741589159,
0.1045864969,
0.1734927297,
0.5916929841,
0.2543932796,
0.0968850553,
-0.0018729728,
0.0082860813,
-0.1786676347,
0.1541017741,
-0.1791674048,
-0.183665812,
0.4155962765,
0.2356173694,
0.0200196095,
-0.4517162144,
-0.1200749353,
0.119653292,
0.2558179796,
-0.3397213221,
0.0509373583,
-0.2482746243,
0.0186311454,
-0.606431067,
-0.0510987341,
-0.000010234,
-0.1501995772,
-0.1013373956,
0.5159271955,
0.0118255392,
0.143835023,
-0.0190673526,
0.0992671326,
0.2845371962,
0.2305807024,
-0.0683516562,
0.1002191678,
-0.1617559344,
0.1221623048,
0.0412561782,
-0.0153149283,
0.454814285,
0.0532763042,
0.1019114777,
-0.5667012334,
-0.2578648925,
-0.0815544128,
0.1752305478,
0.5197483897,
0.0439645462,
0.163611114,
-0.0249476563,
-0.1216460988,
-0.1182224751,
-0.1421073377,
-0.2364524603,
0.0028132028,
-0.0856936872,
0.2417736501,
-0.2683660686,
-0.3805565238,
-0.0926021412,
-0.2641489208,
-0.0859280229,
-0.03914994,
0.2593416274,
0.0706427544,
0.0145754134,
0.1512506306,
0.4747600555,
0.1178864986,
-0.4887931049,
-0.4494748414,
0.161095202,
-0.1190936565,
-0.2410860509,
-0.1528856307,
-0.2208817005,
0.0288344547,
0.1341529191,
-0.4471953511,
-0.2873135209,
0.0889250189,
0.1785939634,
-0.239826709,
0.0668607131,
0.2155983895,
0.0780532807,
-0.2084505409,
-0.124240689,
0.1337824166,
-0.1466187984,
0.0573121719,
0.1487947702,
-0.0183943622,
0.4291378558,
0.0459715948,
0.484354347,
0.4392162263,
-0.1078845039,
0.2628548443,
-0.221682474,
0.1691560447,
-0.0023894452,
-0.2227885872,
0.0420335941,
-0.1378420889,
0.1540296525,
0.3252018988,
-0.1319096386,
0.0955434293,
-0.0142488955,
-0.0308306273,
-0.421865195,
-0.1347929686,
-0.0119806947,
-0.3076411188,
0.098223336,
0.0375870056,
-0.0054138214,
-0.0894386768,
-0.1637147069,
-0.2463334203,
0.2291080505,
-0.0954918563,
-0.0217901319,
0.0473622046,
0.1014093906,
-0.4657289386,
0.1351403892,
0.2343238741,
0.5233976245,
0.2992340922,
0.0203538407,
0.136978358,
-0.0041869474,
0.6461728811,
-0.3047169149,
0.0476736836,
-0.1932584345,
-0.1261408478,
-0.1682854742,
-0.0581339821,
-0.0846077576,
-0.0806838498,
0.1723971516,
0.4653706253,
0.0265069883,
-0.0148554202,
0.2174687684,
0.1550377607,
-0.1928663552,
-0.3623105586,
-0.3043017089,
-0.1657861769,
-0.2099126279,
0.0879315436,
-0.0795945525,
0.1049776077,
-0.2061510682,
-0.177376017,
-0.215195775,
-0.1180919632,
0.3505523801,
0.0371508859,
0.2076809108,
0.117569156,
0.1883310527,
0.198341161,
-0.0034398793,
0.0276818108,
0.2447553128,
-0.0347714089,
-0.1358008832,
0.1123774424,
-0.1470552087,
-0.0612301789,
0.2799743414,
-0.0463500097,
0.1913714856,
0.0878689736,
0.1661930084,
0.0228155982,
0.0068182377,
0.2787887156,
0.1595890671,
-0.1118461788,
-0.395503372,
0.2151824087,
0.1865969449,
-0.0263719372,
0.4284128845,
-0.6620622873,
-0.0693075955,
-0.1004177779,
-0.1200399473,
0.8012030721,
0.0864051655,
0.2501120269,
0.3097534776,
-0.441106081,
0.2539435923,
-0.1422570199,
0.0669219345,
-0.3592149317,
-0.5228200555,
-0.0282712132,
-0.2225419134,
0.1761112362,
-0.1735491604,
-0.4452694952,
0.3149872422,
-0.1891490966,
0.5836107731,
0.0185050443,
0.1185785756,
-0.1462282985,
-0.0395731404,
-0.1299455613,
0.1105904505,
-0.1269225031,
-0.0677937418,
-0.0709882602,
-0.0920867845,
0.168343693,
-0.204983443,
0.0975842699,
-0.0535733141,
-0.5762127638,
0.3885456324,
-0.1233952492,
-0.3521104753,
-0.2716169655,
0.1786541939,
0.1162146404,
-0.1140589565,
-0.0478193201,
-0.0510274284,
0.526525557,
0.3620860577,
-0.1496388018,
-0.1554919183,
0.428835988,
-0.0585505255,
-0.1998509169,
0.1820119917,
0.3065870702,
-0.0111220023,
-0.1905931085,
0.2617819309,
0.0260656197,
-0.3174489439,
-0.0009438712,
-0.1390988231,
-0.2691533864,
-0.377700299,
0.1506715119,
-0.1279238313,
-0.3933440149,
0.0299371388,
-0.0321401991,
-0.3152776957,
-0.262006551,
0.3653553724,
0.4884817004,
0.0139432382,
0.2156249136,
-0.1268915832,
-0.2012768537,
-0.2409163713,
0.2364681214,
-0.0645363182,
-0.4119770229,
0.3218462467,
-0.1883367151,
0.0247345325,
0.0609537512,
0.0677364245,
-0.0725697875,
0.3467039168,
-0.1514204293,
-0.2300658375,
-0.5069087148,
-0.2645509541,
0.0354065597,
0.3188835382,
0.0444840528,
0.3194245696,
-0.0256970953,
0.0955407172,
-0.3671633899,
0.1582467854,
0.0879701898,
0.3427937925,
0.0873424783,
-0.1522430629,
0.0005403492,
0.2912174165,
0.155146867,
0.3171488345,
-0.2249580026,
-0.3285801709,
-0.2647249997,
0.1057538912,
-0.1502897292,
-0.1710045338,
-0.3112558126,
0.0084038805,
-0.0470641069,
-0.1014044434,
0.1801440269,
0.0556426384,
0.1147338748,
-0.0376476869,
0.4749485552,
0.0470995158,
-0.0665547848,
-0.0082190698,
-0.2510852218,
0.1600515246,
-0.001483725,
-0.0181242861,
-0.1668705195,
-0.0752054751,
-0.3852079213,
-0.1256996542,
0.2910532951,
0.0289067496,
0.0514651537,
-0.2525205314,
-0.0977330729,
0.0498849973,
0.2729039788,
0.2360826433,
-0.3120245934,
-0.2801553905,
0.0210351031,
0.2392579466,
-0.3121617436,
-0.0398395844,
-0.0378115922,
-0.0988773033,
0.1698572189,
0.3003664613,
0.1743740439,
-0.3612979054,
-0.01045678,
-0.1054110005,
-0.0099790795,
-0.4217979908,
0.127356261,
0.2815951407,
-0.0306152776,
-0.1822191775,
0.2722438872,
0.0665353909,
-0.0620772205,
0.139346838,
-0.0178823974,
0.1360493749,
0.1372889429,
-0.0290609896,
-0.1934634745,
-0.1284843385,
0.0366067216,
0.2566311657,
-0.521482408,
0.1776340157,
0.2164945602,
0.1239331141,
-0.116606392,
0.0941545665,
-0.058331836,
0.0959786549,
-0.3209308386,
-0.132339716,
0.180310607,
-0.0214880873,
-0.2110702991,
-0.071096614,
0.0528353751,
0.3617663682,
-0.015877191,
0.3496361077,
-0.1326559037,
-0.2699390352,
-0.1952128112,
0.4980935156,
-0.019497985,
-0.3491037488,
0.110523358,
0.4241358936,
0.2394896895,
0.1648161709,
0.1961564273,
0.5627021194,
0.3440356553,
-0.1720213741,
0.0585061014,
0.1696974933,
-0.030498514,
-0.0836497992,
-0.0755369961,
0.0568408072,
0.0500526875,
0.2399840504,
0.1664672792,
-0.2357577682,
0.003071971,
0.2274904847,
-0.1396827847,
-0.5591310859,
0.3070270717,
0.0002791799,
0.0034610496,
-0.1033052132,
0.1001996994,
-0.4988170564,
0.0374831669,
0.2939960361,
-0.0956988484,
0.206319347,
-0.1676300764,
0.1177940443,
-0.1041228324,
0.3071419597,
-0.0495376065,
0.0543714911,
-0.3376259804,
-0.0499860533,
-0.7678493261,
0.173656404,
0.0997275636,
0.1303597838,
0.1125439331,
0.1695895791,
-0.3727913201,
0.0537747182,
0.1624019593,
-0.0016957116,
0.0444720313,
0.2206200659,
-0.3652908802,
-0.2507268786,
-0.3343899846,
0.0296970606,
0.1035117134,
-0.4949091971,
0.3291401863,
-0.1104037911,
0.2040228546,
0.0616560504,
-0.1067567095,
0.0815832838,
0.2937067747,
0.3502361178,
0.0903141126,
0.294501394,
-0.1944580376,
0.1323443502,
-0.0687395856,
-0.035848368,
-0.2151158601,
0.092779994,
0.3993166685,
0.210215643,
0.0204806253,
-0.3557466567,
-0.2885124683,
0.4376610518,
0.2642537951,
-0.120663099,
-0.1990336627,
0.1214664802,
-0.1278471202,
0.4034743309,
-0.0583958216,
0.3974510133,
-0.0233102739,
0.4110554159,
-0.1494300067,
-0.5788661838,
0.5883355141,
-0.3078076541,
-0.2945581675,
-0.6304722428,
0.3672095835,
0.0877360627,
0.3985938728,
-0.4144457579,
0.2957020104,
0.45825845,
-0.0350577869,
-0.1528308392,
0.3996999264,
-0.166746214,
0.1765512973,
0.0108728129,
-0.0371446311,
0.3672332168,
0.0079083052,
0.2092932314,
-0.2773926556
] |
https://github.com/huggingface/datasets/issues/3422 | Error about load_metric | Hi ! I wasn't able to reproduce your error.
Can you try to clear your cache at `~/.cache/huggingface/modules` and try again ? | ## Describe the bug
File "/opt/conda/lib/python3.8/site-packages/datasets/load.py", line 1371, in load_metric
metric = metric_cls(
TypeError: 'NoneType' object is not callable
## Steps to reproduce the bug
```python
metric = load_metric("glue", "sst2")
```
## Environment info
- `datasets` version: 1.16.1
- Platform: Linux-4.15.0-161-generic-x86_64-with-glibc2.10
- Python version: 3.8.3
- PyArrow version: 6.0.1
| 22 | Error about load_metric
## Describe the bug
File "/opt/conda/lib/python3.8/site-packages/datasets/load.py", line 1371, in load_metric
metric = metric_cls(
TypeError: 'NoneType' object is not callable
## Steps to reproduce the bug
```python
metric = load_metric("glue", "sst2")
```
## Environment info
- `datasets` version: 1.16.1
- Platform: Linux-4.15.0-161-generic-x86_64-with-glibc2.10
- Python version: 3.8.3
- PyArrow version: 6.0.1
Hi ! I wasn't able to reproduce your error.
Can you try to clear your cache at `~/.cache/huggingface/modules` and try again ? | [
-0.1543193907,
-0.3634535074,
0.0099821575,
0.3949095309,
0.4780282378,
-0.0076498594,
0.1825974137,
0.1899198741,
0.1398091912,
0.1264668852,
-0.2365793586,
0.0703849867,
0.0390485004,
0.2697517574,
0.2777209878,
-0.1408575922,
-0.2320583612,
0.1285481155,
-0.3948494792,
0.1379793137,
-0.3345136046,
0.3227806687,
-0.2020763457,
0.0151673388,
-0.3880251646,
-0.0697293952,
0.0320154317,
0.3490536213,
-0.0542033948,
-0.3160964549,
0.4209107459,
-0.1223302484,
0.2104740739,
0.6237583756,
-0.0001083054,
0.0019291814,
0.4295630753,
-0.0698552653,
-0.1801166683,
-0.2114719599,
-0.0895232558,
-0.307934165,
0.2405192703,
-0.3028722405,
-0.162154302,
-0.0146062607,
-0.2227857858,
-0.1776643842,
0.3323097527,
0.3742238283,
0.2997359335,
0.635743022,
0.1827403754,
-0.2761428654,
-0.07004904,
-0.0462739356,
-0.0110346386,
0.5874061584,
-0.0932067633,
-0.0215857159,
0.2237031311,
0.1913193017,
-0.1458406746,
-0.0720232502,
0.4881642759,
0.0657688156,
0.1218045205,
-0.1812842488,
0.0592667907,
0.1686424315,
0.3828805685,
-0.41650635,
-0.1942471266,
-0.0256044548,
-0.040978238,
-0.3089537323,
0.24294056,
-0.0884574801,
-0.015892284,
0.1669610143,
-0.168607384,
-0.1738454401,
-0.100438714,
0.1321236342,
-0.1666911393,
-0.0566612035,
-0.1698295325,
0.0470446534,
0.3265687525,
-0.0522194505,
-0.2726070881,
0.2022336274,
-0.0763460547,
0.2358359098,
-0.4515021741,
-0.0882409513,
0.1740599126,
-0.0404450372,
0.1762191653,
0.170914501,
-0.0000452812,
-0.0666067749,
0.0723956153,
0.2488781661,
0.0324112475,
0.5187011957,
0.2003647685,
0.1472773552,
0.4208549261,
0.1673788428,
0.0964679793,
-0.0402158275,
0.0241074096,
-0.3343977332,
0.2084080875,
0.0671970174,
0.3447592556,
-0.0841712877,
-0.3775251806,
0.0181288682,
0.1573890597,
0.0060322373,
0.1943288743,
0.3640739918,
-0.0849585906,
0.0213765204,
0.3098779023,
0.2635483444,
-0.1441983432,
-0.045313362,
-0.3079618514,
0.0855331272,
-0.285023272,
0.0918695182,
0.1223317757,
-0.2411902696,
0.2972176373,
-0.0596992075,
0.2320474833,
0.0052753384,
-0.1801824868,
0.0002735663,
-0.4559583962,
0.3155317903,
-0.0426329076,
-0.0340471007,
0.3438808918,
-0.2498010844,
-0.1758817285,
-0.0667432547,
-0.396586597,
-0.3489949405,
-0.2281555235,
0.1906862557,
-0.2567124069,
-0.0366572365,
-0.0905084014,
-0.0524982661,
0.0816589966,
-0.0341058932,
-0.0221796427,
0.0213686042,
-0.2081440538,
-0.1809950024,
0.2654059529,
0.4197615981,
-0.1241386384,
-0.4193944633,
0.2475040406,
-0.2722266912,
0.1515624821,
0.0735412389,
0.046671439,
0.0418200642,
-0.2164573669,
-0.0529856496,
0.5696075559,
-0.4870830178,
-0.305324465,
-0.0129453726,
-0.0912948996,
-0.0660425127,
-0.0997284651,
-0.1221838593,
0.071233876,
0.1602919251,
0.3691285253,
0.181472823,
0.2460635155,
-0.0673031658,
-0.2959711254,
-0.2739143968,
0.0151239038,
0.1323705614,
0.1343490183,
0.207310617,
0.125881806,
-0.2733309567,
-0.0197356455,
0.0092079137,
-0.1091536954,
0.3077544868,
0.3138895631,
0.0530329421,
0.0884154439,
-0.3740164042,
-0.4855462611,
0.2208615988,
-0.1038556546,
0.2484364957,
0.0585204102,
-0.0572747588,
-0.5404747128,
0.0557721928,
0.1149240509,
-0.0396872014,
0.1177557036,
-0.0932685286,
0.0560616143,
0.2103016526,
-0.2174212635,
0.5194116831,
0.0435418896,
0.2268601954,
-0.0502142087,
0.2833231688,
-0.0082022399,
-0.2894022465,
0.1883431673,
0.3154475093,
0.3678774834,
-0.1913115382,
-0.1713063866,
0.3795666099,
-0.0026113496,
0.0007106374,
-0.0385931395,
0.0413058773,
0.1458423883,
-0.1447089314,
-0.0253061615,
-0.1285432577,
0.1023374051,
-0.0015313915,
0.3126978278,
0.2648939192,
-0.0290573072,
0.1211368218,
-0.0536955036,
0.2351401001,
0.1111266017,
-0.1546278447,
0.0089369183,
-0.256731689,
0.254592061,
-0.1343355924,
0.4579009414,
0.0160899851,
-0.0869357288,
-0.1570410579,
0.3953167498,
-0.067304574,
0.1365799606,
0.2145171911,
-0.2131551653,
0.0786093175,
0.0189038776,
-0.0976479501,
0.4290672839,
0.2625548244,
-0.1425195336,
0.1476903707,
0.0134682078,
-0.0187323224,
0.1198477522,
-0.1157618612,
0.2183317095,
0.0774156302,
0.1451822966,
0.043975912,
-0.2362022549,
0.0713773221,
-0.3299256563,
0.1857253611,
-0.3560781777,
0.0890052915,
-0.1118912175,
0.1443867683,
0.0165851787,
-0.1988376081,
-0.362349838,
-0.123298496,
-0.0745540112,
0.0772432014,
0.158858791,
0.2377409041,
0.1133857369,
0.2581503689,
0.174018532,
-0.1417493522,
-0.2986338139,
-0.1178747416,
-0.1444078088,
-0.01149383,
0.11324808,
0.0490721129,
0.2982063293,
-0.3821718097,
0.2066471279,
-0.0268710051,
-0.3316157162,
0.1415922046,
-0.0859710723,
0.5356300473,
0.3830053508,
0.2223938704,
0.0601645634,
0.0308396239,
0.4310187101,
-0.2781942189,
-0.1283776909,
0.3072198331,
-0.1938469857,
-0.0050386819,
-0.3107318878,
-0.0656446889,
-0.3405123353,
-0.4235740006,
0.1724358052,
0.1426467597,
0.1275131851,
0.2296762466,
0.1658716947,
0.2529861331,
-0.0127113406,
0.1873029619,
-0.2911024392,
-0.4766461253,
0.1857632101,
-0.1643531471,
-0.4779867232,
-0.0241930149,
0.0987191796,
0.355382055,
-0.1274408847,
-0.3843421936,
-0.4785295725,
-0.1180270836,
0.2772623003,
-0.2394438535,
0.078707397,
0.2070349157,
0.0424267165,
-0.1203310713,
-0.229477033,
-0.2517616153,
0.1537402421,
0.0673766434,
-0.0223556757,
-0.0006509194,
0.2750593126,
-0.1600403637,
0.3475377858,
0.2227562815,
-0.2459637225,
0.4428965151,
-0.1437604427,
0.523229897,
-0.1130054742,
-0.4164565504,
-0.0518746376,
0.1353650689,
0.2595985234,
0.1685200185,
0.0268953685,
0.0334365144,
-0.4545098245,
-0.1643532515,
-0.3277142644,
-0.177134797,
-0.202561304,
0.0784328058,
0.0985227004,
0.0509632714,
0.010581064,
-0.3053332269,
0.0922214091,
0.2822165489,
0.3305604458,
-0.0982861593,
0.0626645237,
-0.3062068224,
-0.0096916147,
-0.3819750547,
0.4482315481,
-0.2604286969,
0.1014641747,
-0.1435127109,
-0.038763117,
0.0554143451,
-0.0193761792,
0.8064731956,
0.096748963,
0.0023009598,
0.2276444137,
0.0722815245,
-0.5943183899,
0.0581105165,
0.0489210784,
0.0405836441,
0.4099037349,
0.6370711327,
-0.4610352218,
-0.2438020855,
0.1514240056,
0.1373371929,
-0.2201623023,
-0.3145673275,
-0.5559292436,
-0.3393345773,
-0.0693589896,
0.0664470643,
-0.0862250552,
0.4433618486,
0.1105679274,
-0.0669718906,
-0.1637883335,
-0.2969713509,
0.09541931,
0.2262407541,
0.3177546859,
-0.203986764,
0.0783028826,
0.3460392356,
0.0980790332,
-0.0270263553,
0.4275055826,
-0.1654261053,
-0.4301082492,
0.0426505283,
0.1415635347,
0.1941858381,
0.0211875178,
-0.1685594916,
-0.1225913912,
-0.0945896283,
0.3977294266,
-0.1312945038,
0.051165849,
0.2873539329,
0.2394390553,
-0.2045878917,
-0.1156883612,
0.3761635423,
0.1186435223,
-0.0263163187,
0.3491532207,
0.2600224018,
-0.205457449,
0.1034495756,
-0.2147405446,
0.9929335117,
-0.0760625377,
-0.149483785,
0.5446609855,
-0.1246734187,
0.3229943812,
-0.1661415249,
-0.1405926049,
-0.2135110646,
-0.2282049209,
0.0601632558,
-0.1905095428,
0.3257086873,
-0.2230764478,
-0.2780152857,
0.2320787609,
-0.3076221347,
-0.0603106245,
-0.105915308,
0.0705731735,
-0.0630601496,
0.0189420562,
-0.3930128515,
0.198435083,
-0.1281493306,
0.3653770089,
-0.0826806277,
-0.060449373,
-0.0884996355,
-0.3147259355,
-0.0624240935,
-0.073026225,
-0.3164161742,
-0.0459073111,
0.2826969624,
-0.1998780817,
-0.1997895092,
0.2814451158,
0.2877234519,
0.0609271191,
-0.3812238574,
0.0325647593,
-0.2441949099,
0.0376165062,
-0.1368627101,
0.1678997725,
0.1386077106,
-0.194309473,
-0.4308962226,
0.1675421,
-0.1084443778,
-0.0405192971,
0.3432368636,
-0.0080362642,
-0.1823507398,
-0.2824167311,
-0.1041511968,
-0.090878278,
0.4552912712,
-0.2211321741,
0.1785011142,
0.1620458663,
0.0342742689,
0.0679330081,
0.1136343926,
-0.2273802012,
-0.0519183539,
0.4864450991,
-0.083471939,
0.0249762405,
0.0534894802,
0.0321254469,
-0.2597407699,
-0.2428382039,
-0.0278028212,
-0.1640645564,
-0.4286106825,
0.207899496,
0.3593246341,
-0.0719111487,
-0.1309101582,
0.3136121333,
0.1878249943,
-0.1561847031,
0.0713431984,
-0.3429661095,
-0.3106890321,
0.3254926205,
-0.1386093348,
0.1446380615,
0.0694937408,
0.3498209119,
-0.0660736337,
0.1930470914,
-0.3858532608,
0.1191094518,
-0.3282261193,
-0.1081383452,
0.3824705184,
-0.2635087073,
0.2641922534,
0.0034407675,
0.1555200666,
-0.004397016,
-0.2775937617,
-0.2339661121,
-0.2332567573,
0.091856882,
-0.0972303376,
0.0010030346,
0.2003660947,
0.0180019345,
-0.1834857017,
-0.1536585093,
0.2279996574,
0.1330664158,
-0.0590102151,
0.1420371681,
0.1158946678,
0.1351254433,
0.0686732084,
0.1762053221,
0.0635123178,
0.0455036871,
-0.061164774,
-0.039875295,
-0.1663201749,
0.0178697519,
0.0060325926,
0.1249910295,
0.2673962414,
-0.0815037042,
0.0964764878,
-0.1315173805,
-0.112056151,
0.1473016441,
0.1405644119,
0.0386696607,
-0.317079097,
0.1420190334,
0.0035255663,
0.2761544585,
-0.4417006075,
-0.1216062009,
0.0497980192,
0.054993581,
0.0288840514,
0.0999868289,
-0.0845891312,
-0.0259249471,
0.1822575331,
0.046398107,
0.518940568,
0.1151527762,
0.1919164807,
0.0385289863,
-0.0194670167,
-0.0646583959,
0.5326470137,
0.0494826883,
0.186156407,
0.0317393318,
-0.4546195269,
0.146195963,
-0.3027110696,
0.2690322399,
-0.1006248817,
-0.4154537618,
0.1697059423,
0.1204892099,
-0.1359344721,
-0.2402418107,
-0.3671806455,
0.7900741696,
-0.3924963772,
-0.1632283479,
-0.3097439706,
0.2318674177,
-0.1400311291,
0.0216729138,
0.1469654888,
-0.1798674464,
0.0503690988,
-0.1505240351,
0.1205838174,
-0.2199514061,
0.3579034209,
-0.0854764804,
-0.044132743,
-0.3523139954,
-0.1355109662,
0.2504975498,
-0.0301421713,
-0.0222114157,
0.2156065702,
0.1001665071,
0.0285946205,
-0.0476212427,
0.5593239069,
0.2886433899,
0.206952095,
0.086589098,
-0.1723092794,
-0.0111054443,
-0.0807117969,
-0.0977339968,
0.3091266155,
0.0436851569,
-0.0408858359,
0.0484578982,
0.2101633102,
-0.2708367407,
-0.039506156,
-0.0592377633,
0.153814435,
-0.3556716442,
0.4135097563,
-0.45201841,
-0.1211047769,
-0.1917084903,
-0.0466134399,
-0.4535076022,
0.1552382112,
0.2312254757,
0.0699194372,
0.0697508827,
-0.2699513137,
0.1191656217,
-0.1043778956,
0.3091421723,
-0.1105448529,
0.2877157927,
-0.1335119903,
-0.15209952,
-0.5454505086,
0.3835498095,
0.169609338,
0.0089735324,
0.0475346446,
-0.1618138254,
-0.1630984843,
0.0022936943,
0.2713342309,
0.3717005253,
0.2465280592,
-0.3907343447,
-0.5792746544,
0.0543738641,
-0.3462854326,
-0.1129534245,
0.1301057637,
-0.3336260021,
0.0094933044,
-0.3056614399,
0.0865563378,
-0.1298405528,
0.0334081165,
-0.0160421431,
0.3075226545,
0.7048740387,
0.0608952269,
0.3860212862,
0.035061907,
-0.1216458008,
0.0122204479,
-0.4695712626,
0.0585601032,
0.0560122989,
0.0431882739,
-0.0348823667,
-0.2494522929,
-0.2301363647,
-0.2577665746,
0.4640192688,
0.1948456466,
-0.0784748569,
-0.1153282747,
0.100366801,
-0.1724696308,
-0.2344852835,
0.0842645392,
0.1854486018,
0.046943713,
0.1876497567,
-0.0878523514,
-0.0761202127,
0.7019881606,
-0.2026072294,
-0.1261036843,
0.1053268388,
0.376595974,
0.1096275076,
-0.4970853031,
-0.5933618546,
0.1258298308,
0.3880941272,
0.2593901753,
-0.15036726,
0.5415432453,
-0.2793854773,
0.005610317,
0.0067392248,
0.2523930073,
0.1528466791,
-0.1102636829,
0.16338633,
-0.0870218575
] |
https://github.com/huggingface/datasets/issues/3419 | `.to_json` is extremely slow after `.select` | Hi ! It's slower indeed because a datasets on which `select`/`shard`/`train_test_split`/`shuffle` has been called has to do additional steps to retrieve the data of the dataset table in the right order.
Indeed, if you call `dataset.select([0, 5, 10])`, the underlying table of the dataset is not altered to keep the examples at index 0, 5, and 10. Instead, an indices mapping is added on top of the table, that says that the first example is at index 0, the second at index 5 and the last one at index 10.
Therefore accessing the examples of the dataset is slower because of the additional step that uses the indices mapping.
The step that takes the most time is to query the dataset table from a list of indices here:
https://github.com/huggingface/datasets/blob/047dc756ed20fbf06e6bcaf910464aba0e20610a/src/datasets/formatting/formatting.py#L61-L63
In your case it can be made significantly faster by checking if the indices are contiguous. If they're contiguous, we could pass a python `slice` or `range` instead of a list of integers to `_query_table`. This way `_query_table` will do only one lookup to get the queried batch instead of `batch_size` lookups.
Given that calling `select` with contiguous indices is a common use case I'm in favor of implementing such an optimization :)
Let me know what you think | ## Describe the bug
Saving a dataset to JSON with `to_json` is extremely slow after using `.select` on the original dataset.
## Steps to reproduce the bug
```python
from datasets import load_dataset
original = load_dataset("squad", split="train")
original.to_json("from_original.json") # Takes 0 seconds
selected_subset1 = original.select([i for i in range(len(original))])
selected_subset1.to_json("from_select1.json") # Takes 212 seconds
selected_subset2 = original.select([i for i in range(int(len(original) / 2))])
selected_subset2.to_json("from_select2.json") # Takes 90 seconds
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: master (https://github.com/huggingface/datasets/commit/6090f3cfb5c819f441dd4a4bb635e037c875b044)
- Platform: Linux-4.4.0-19041-Microsoft-x86_64-with-glibc2.27
- Python version: 3.9.7
- PyArrow version: 6.0.0
| 208 | `.to_json` is extremely slow after `.select`
## Describe the bug
Saving a dataset to JSON with `to_json` is extremely slow after using `.select` on the original dataset.
## Steps to reproduce the bug
```python
from datasets import load_dataset
original = load_dataset("squad", split="train")
original.to_json("from_original.json") # Takes 0 seconds
selected_subset1 = original.select([i for i in range(len(original))])
selected_subset1.to_json("from_select1.json") # Takes 212 seconds
selected_subset2 = original.select([i for i in range(int(len(original) / 2))])
selected_subset2.to_json("from_select2.json") # Takes 90 seconds
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: master (https://github.com/huggingface/datasets/commit/6090f3cfb5c819f441dd4a4bb635e037c875b044)
- Platform: Linux-4.4.0-19041-Microsoft-x86_64-with-glibc2.27
- Python version: 3.9.7
- PyArrow version: 6.0.0
Hi ! It's slower indeed because a datasets on which `select`/`shard`/`train_test_split`/`shuffle` has been called has to do additional steps to retrieve the data of the dataset table in the right order.
Indeed, if you call `dataset.select([0, 5, 10])`, the underlying table of the dataset is not altered to keep the examples at index 0, 5, and 10. Instead, an indices mapping is added on top of the table, that says that the first example is at index 0, the second at index 5 and the last one at index 10.
Therefore accessing the examples of the dataset is slower because of the additional step that uses the indices mapping.
The step that takes the most time is to query the dataset table from a list of indices here:
https://github.com/huggingface/datasets/blob/047dc756ed20fbf06e6bcaf910464aba0e20610a/src/datasets/formatting/formatting.py#L61-L63
In your case it can be made significantly faster by checking if the indices are contiguous. If they're contiguous, we could pass a python `slice` or `range` instead of a list of integers to `_query_table`. This way `_query_table` will do only one lookup to get the queried batch instead of `batch_size` lookups.
Given that calling `select` with contiguous indices is a common use case I'm in favor of implementing such an optimization :)
Let me know what you think | [
-0.3134348094,
0.1887502223,
-0.0610732362,
-0.0651996881,
0.2008450627,
0.0744217187,
0.084237203,
0.4034846723,
-0.2616819143,
0.2137250602,
0.0064629111,
0.7067224979,
-0.007227724,
-0.0352007858,
0.0019335635,
-0.0267549418,
0.1643504947,
-0.1066153273,
0.0210075192,
-0.1266008019,
-0.1056948379,
-0.0096036987,
-0.2797527015,
-0.0329514705,
-0.1409995556,
-0.2784814537,
0.1729201823,
0.2560810149,
-0.0184410792,
-0.3377084732,
-0.001387561,
-0.0966915116,
-0.1162269413,
0.2409717143,
-0.0001087118,
0.0734114572,
0.2043654472,
0.0226171128,
-0.3878857791,
-0.1577962637,
-0.4634682834,
-0.1034036651,
0.0274384711,
-0.2707282603,
-0.023256924,
0.0306704119,
-0.1517097056,
-0.2918874323,
0.3181188107,
0.1040881425,
0.2415894717,
0.3510610759,
-0.2576989233,
-0.1619840562,
0.2756758332,
0.1905020773,
-0.1756991148,
0.4026585519,
0.0441579744,
0.1136146784,
0.1366685629,
0.089481391,
-0.1013908982,
-0.1817276031,
-0.1199257076,
0.0945554003,
-0.1025136188,
0.0468739904,
0.0227331333,
0.1377215385,
0.2284839451,
-0.2496943474,
-0.3619492948,
-0.3039983809,
-0.0144991102,
-0.0674322993,
0.1812418699,
-0.0457138307,
0.051965639,
-0.0960380882,
-0.2840663195,
0.1411956996,
0.1532614082,
-0.0746636614,
0.2828761637,
0.0203248989,
-0.0437164493,
0.0648747608,
0.3973839581,
-0.226938501,
0.0284305718,
-0.3199332654,
0.0073035117,
0.0225740112,
-0.5987463593,
-0.385268271,
0.0011236293,
-0.5389379859,
-0.1619408429,
0.1702694297,
0.2211835086,
0.148189649,
0.2020166814,
0.0272196457,
0.3664292097,
0.1000208929,
0.0174547918,
0.262576282,
0.0871517137,
0.2086934149,
-0.013808364,
0.148165375,
0.1846826077,
-0.2047812641,
0.0859755352,
-0.0904582143,
0.0278282184,
-0.0262624864,
-0.4396533072,
0.1123468503,
-0.1807842404,
-0.221479997,
0.0383385867,
0.2987675071,
-0.0489862859,
-0.234265849,
-0.2089882791,
0.0701902732,
-0.3014134169,
0.1154294834,
-0.3093777597,
0.2089116573,
-0.0547134019,
0.1547596604,
-0.1174715236,
-0.0906279236,
0.0556412004,
0.1574629992,
0.0302595552,
0.2194629461,
0.266926825,
-0.1213569939,
0.0269677658,
0.2240349948,
0.1139714792,
0.1025406048,
-0.1760905385,
-0.4222277105,
-0.3850273192,
0.2565738857,
-0.2997812927,
-0.1978812963,
0.2909234464,
0.2881027162,
-0.1039831862,
-0.197357282,
-0.7724062204,
0.2375659794,
0.0038512554,
-0.0859800056,
-0.0889125392,
-0.1200823411,
-0.0707587898,
-0.3188275695,
0.1193362996,
0.1258351803,
-0.4098063111,
0.0476830527,
0.1725774854,
-0.0028528315,
0.5176390409,
0.385589242,
-0.2536503077,
0.0334362797,
0.0381850637,
0.4675063491,
0.3435555398,
0.1652613282,
-0.4090452194,
0.0550914966,
-0.2947690487,
0.1766481996,
0.0297033302,
0.1767354161,
0.2951003015,
-0.1199591532,
0.3080725074,
0.4912299514,
0.0926656127,
0.2578490078,
-0.4891904891,
-0.1710204631,
0.0482306108,
0.2656108737,
-0.4736608863,
0.0205281135,
0.091903761,
0.2612652183,
0.2743980885,
-0.1598336846,
-0.1288861483,
0.3128335178,
0.2605653703,
-0.3065893352,
-0.1825326979,
-0.1751387864,
-0.0845702142,
0.1775666773,
0.0653960854,
-0.2772377729,
0.0805990025,
-0.1494891047,
-0.1239717156,
-0.0368665531,
-0.3007581234,
0.049829334,
0.1021754444,
-0.0479761474,
0.313644439,
0.0571882501,
0.0115164071,
-0.0163431913,
-0.3065513074,
-0.0460001342,
-0.4206381142,
0.3021359444,
-0.0428693444,
-0.4979563951,
0.1682612449,
-0.079145059,
0.0463175774,
-0.3157120645,
-0.2837695479,
0.212690413,
0.1319470406,
0.2195283771,
0.1680987179,
-0.0133239366,
-0.0074640671,
0.1460097879,
0.1451134235,
0.2135333121,
0.0524982065,
-0.0406725518,
-0.5448128581,
0.5830821991,
-0.2446796596,
0.2318926007,
0.1716701239,
-0.343875736,
0.1707449555,
0.2592820823,
0.1353048533,
0.0284490734,
-0.0213534571,
0.4851015806,
-0.0954677984,
0.0561240949,
-0.4406300187,
0.3064272404,
0.7711955905,
-0.1944095939,
0.0032762541,
0.293840915,
-0.0097143073,
-0.34468472,
-0.1106971055,
0.2224397212,
0.4611258805,
0.096471034,
0.0803126544,
-0.1639896929,
-0.0487830713,
-0.1641253978,
0.0692557171,
-0.1358746886,
0.1462064683,
0.08136601,
0.4279742241,
-0.0467500724,
-0.1886072308,
0.0017232549,
-0.0665475726,
0.2904408276,
-0.1108382046,
0.2306218147,
-0.3287338316,
0.3466448784,
0.0706559792,
0.0279637128,
-0.0069141588,
-0.3691058159,
0.1192110777,
0.2100225687,
-0.2380548418,
0.0761865228,
0.0345143378,
0.0194844455,
0.1538161188,
-0.3518487811,
-0.2038659006,
-0.0765818581,
-0.2606609762,
0.1363905817,
0.0733446181,
0.2094246894,
0.22192882,
0.0080149565,
-0.2296078503,
-0.0430735797,
-0.206567198,
-0.1438589245,
-0.1672302783,
0.4950194359,
-0.0068703191,
0.0881972089,
-0.1601240188,
-0.3883983791,
0.2172711492,
0.0743157193,
-0.3592293262,
0.1920380741,
-0.1569352299,
-0.0472036637,
0.1851294637,
-0.5259928107,
-0.1160995737,
-0.143583864,
0.4302064478,
0.0158863384,
0.0419201367,
0.0627424642,
0.2521983385,
0.016787488,
-0.0299189445,
0.0941865891,
-0.3023793399,
-0.3653063476,
0.4596995115,
0.0109309629,
-0.1705316156,
-0.21216847,
-0.1080060303,
-0.1047391221,
-0.016737584,
-0.1640963107,
-0.0278944075,
-0.5087157488,
0.1799611896,
-0.0483632237,
0.0166076403,
0.439876318,
-0.0021376642,
-0.172322154,
0.1671262234,
-0.3047691584,
-0.0020590699,
0.4214404523,
0.0138514033,
-0.2207439542,
0.3652331233,
0.1683788747,
0.6924616098,
0.1479628235,
-0.1337081939,
0.0095420042,
0.0462551787,
-0.0364885665,
-0.5109035969,
-0.2004980743,
0.0751406252,
-0.1127567291,
-0.1113483086,
-0.0418568961,
-0.1704164296,
-0.3016446531,
0.2597434223,
-0.0288990233,
-0.1784323156,
-0.2193289846,
0.1380930394,
0.1275411844,
-0.1970200986,
0.2786274552,
0.2328194827,
-0.1236686483,
0.0515850894,
-0.0946588144,
0.1037851796,
0.1574229002,
-0.2500370145,
-0.9735392928,
-0.2995592654,
-0.2195480168,
0.1327938288,
0.0326299332,
0.3345804214,
0.1370512247,
-0.4049047828,
0.2955638766,
-0.1078061834,
0.4373118281,
-0.1701018214,
-0.1340565383,
0.4174624979,
-0.0894445851,
-0.2117298394,
-0.1268094927,
-0.1319714785,
0.3457578421,
0.3224841058,
0.3333307505,
-0.2475526035,
-0.1017538607,
0.319676429,
0.3245224953,
0.0011374635,
-0.042833928,
-0.3655973971,
-0.2425503433,
-0.2323715985,
0.2111351043,
-0.3123554587,
0.132585898,
-0.1385989189,
-0.2153898776,
-0.0136649944,
-0.0503650866,
-0.0658152625,
0.1374820322,
0.2304978222,
0.0802306235,
0.531003356,
-0.0965476185,
-0.0546304099,
0.346699506,
0.4150266945,
0.2019808739,
-0.1423676908,
0.0770205557,
0.230156064,
-0.0180931464,
0.4188619554,
-0.0780442134,
0.1548786312,
-0.2305882573,
0.1619114876,
-0.0281022023,
-0.1405980736,
0.317235291,
-0.0957282409,
-0.0991643965,
-0.3467923701,
0.3974887729,
0.0113440137,
-0.0149886897,
-0.0108599979,
-0.0018369736,
0.2364629507,
0.3675495684,
0.0978720188,
1.0225621462,
-0.0858779922,
0.1601958424,
0.3355116844,
-0.0903852656,
0.2725017369,
-0.1318101436,
0.251478374,
-0.3491584659,
-0.3520565927,
0.420656532,
-0.2799407244,
0.0224870071,
0.2110417932,
-0.0556030199,
0.2110344917,
-0.2355403304,
-0.0482742749,
-0.1758936197,
0.1997664124,
-0.1217556,
-0.1705741584,
-0.1455706507,
0.167370528,
0.1070848033,
-0.2355092466,
0.3100248575,
-0.096325919,
-0.4213786125,
0.0342253931,
-0.0909588709,
0.3683893681,
0.072966896,
0.2721165419,
0.0602390505,
-0.3708632588,
0.0958930999,
0.1243219078,
0.0500068218,
0.2991911173,
0.067613937,
0.2390504777,
-0.1033114493,
0.4016725123,
0.3431910276,
-0.3226043582,
0.2374068201,
0.1161079407,
-0.177358672,
-0.0326406881,
-0.1100427657,
-0.3430115581,
-0.2668156922,
0.2599797845,
0.028088212,
-0.2675904334,
-0.4429409802,
0.1719235331,
-0.1661892235,
-0.4045939744,
0.2109053582,
0.0418832526,
0.0837141573,
0.5532726645,
-0.1243844703,
-0.1852436364,
-0.0161052719,
0.6113075018,
0.1215986609,
0.1196664646,
0.2837791741,
-0.1037544459,
-0.3717030883,
-0.1520831734,
0.3036408722,
0.1841975302,
-0.0880402252,
0.225774765,
-0.3918479383,
0.160076797,
-0.0730670542,
0.1251301914,
-0.1542084962,
-0.0720396563,
-0.1236908957,
-0.0095058074,
-0.0973174125,
0.1063448712,
0.2863865495,
0.0827881768,
0.0878173336,
0.1055624187,
-0.4721798003,
0.2480380982,
-0.3447907567,
0.1588338763,
-0.2549590468,
0.2485587746,
-0.0239039101,
-0.1693547368,
0.1887513995,
-0.1487515271,
0.2597970963,
0.0340498239,
-0.0731988326,
-0.3388067484,
0.1075837016,
0.0301245488,
-0.1735634655,
-0.0956710577,
-0.0457594953,
0.0267629158,
-0.2206482142,
-0.2683108449,
0.0685631111,
0.0652389154,
-0.03753848,
-0.0809791982,
0.3271727562,
-0.1303128451,
0.1796247959,
-0.0714881048,
-0.3994862735,
0.2186864913,
-0.1318871528,
0.1859520525,
-0.0828293338,
-0.1586292237,
-0.4689003527,
-0.0370616168,
0.0077591478,
0.320584327,
0.3248839974,
-0.284863919,
-0.213100329,
-0.0130716423,
0.2665207982,
0.5952203274,
-0.0384821296,
-0.1596280485,
-0.0844534934,
0.2417887449,
0.0144142509,
-0.4443404675,
0.0793595463,
0.0110707302,
0.0606450699,
-0.0421494097,
-0.1201584116,
0.4057097137,
0.0393603146,
-0.0101243891,
0.1896053255,
-0.0650809854,
0.1273460537,
0.2639834285,
0.1824457347,
-0.1474761516,
0.2487172782,
0.0047795465,
0.2920370996,
0.2118527442,
0.0441633239,
0.4532161653,
0.2633962333,
0.1582746953,
-0.230430156,
-0.2206712067,
-0.0117367581,
0.3890509009,
-0.0674922988,
0.0568530299,
0.3443177938,
0.0874014273,
-0.1940935999,
-0.1504990608,
-0.0496542603,
0.105290167,
-0.1243864149,
-0.3008610904,
-0.0350372307,
-0.0677013248,
-0.2100423425,
0.1656503826,
-0.2408541441,
0.0798022225,
0.0799584836,
-0.1094009951,
0.2087192237,
-0.1993489712,
0.1836387813,
-0.1601710916,
0.2308175713,
-0.2073523551,
0.0531507432,
0.1006847396,
-0.005264964,
-0.1117861792,
0.042766355,
0.3700507283,
0.1360532939,
-0.0336916707,
0.2653379738,
0.0105549572,
-0.1665966362,
0.1632378846,
0.2153517753,
-0.0037191326,
-0.1435413063,
0.2921921611,
0.200944066,
-0.26400581,
-0.1356965899,
0.1977033913,
0.060985323,
-0.2393737137,
-0.0496819466,
0.0903102085,
-0.1359859109,
-0.0192077663,
0.0932066962,
-0.1816336513,
-0.0926344395,
-0.2194137275,
0.0090431478,
0.1017523184,
-0.0428942069,
0.1602016538,
-0.0185831655,
0.4214801788,
-0.0928658098,
-0.157192409,
-0.2726480067,
0.0234540608,
-0.0621421635,
-0.1732740998,
-0.1141584218,
0.2177327126,
0.0483497046,
0.6270105243,
0.0941437781,
0.2578930855,
0.0320283882,
0.1852628738,
-0.2332965285,
0.3661886156,
-0.2351578325,
0.0591826215,
-0.0946943387,
-0.2338527292,
-0.1043047756,
-0.3980081975,
0.2205481529,
0.0799528286,
0.0906144753,
-0.2805927694,
-0.0530777089,
0.1725942641,
0.3960809112,
0.288792491,
0.1532499045,
-0.0146360202,
-0.2184807956,
-0.1840414107,
0.092697762,
-0.148541674,
-0.0767444745,
0.1614030898,
-0.1013266072,
0.4208100438,
0.1812617481,
0.1128615737,
-0.1661351323,
0.090759404,
-0.2752563357,
-0.1174222976,
-0.3608889282,
0.0192922447,
0.1124955565,
0.4805020392,
-0.0380766205,
0.2281412482,
-0.0012778888,
0.2794140577,
-0.3067985177,
-0.1709187627,
0.4034324884,
-0.038487006,
-0.0621317029,
0.0320063047,
0.2164650708,
0.136026457,
0.2223442197,
0.27693066,
0.0471664816,
0.4127053618,
-0.1648696512,
-0.0670876801,
0.464975208,
-0.059899386,
0.0414405577,
-0.1447860301,
0.1731017977,
-0.0706049427,
-0.1147776619,
0.0047175693,
-0.3433473706
] |
https://github.com/huggingface/datasets/issues/3419 | `.to_json` is extremely slow after `.select` | Hi, thanks for the response!
I still don't understand why it is so much slower than iterating and saving:
```python
from datasets import load_dataset
original = load_dataset("squad", split="train")
original.to_json("from_original.json") # Takes 0 seconds
selected_subset1 = original.select([i for i in range(len(original))])
selected_subset1.to_json("from_select1.json") # Takes 99 seconds
selected_subset2 = original.select([i for i in range(int(len(original) / 2))])
selected_subset2.to_json("from_select2.json") # Takes 47 seconds
selected_subset3 = original.select([i for i in range(len(original)) if i % 2 == 0])
selected_subset3.to_json("from_select3.json") # Takes 49 seconds
import json
import time
def fast_to_json(dataset, path):
start = time.time()
with open(path, mode="w") as f:
for example in dataset:
f.write(json.dumps(example, separators=(',', ':')) + "\n")
end = time.time()
print(f"Saved {len(dataset)} examples to {path} in {end - start} seconds.")
fast_to_json(original, "from_original_fast.json")
fast_to_json(selected_subset1, "from_select1_fast.json")
fast_to_json(selected_subset2, "from_select2_fast.json")
fast_to_json(selected_subset3, "from_select3_fast.json")
```
```
Saved 87599 examples to from_original_fast.json in 8 seconds.
Saved 87599 examples to from_select1_fast.json in 10 seconds.
Saved 43799 examples to from_select2_fast.json in 6 seconds.
Saved 43800 examples to from_select3_fast.json in 5 seconds.
``` | ## Describe the bug
Saving a dataset to JSON with `to_json` is extremely slow after using `.select` on the original dataset.
## Steps to reproduce the bug
```python
from datasets import load_dataset
original = load_dataset("squad", split="train")
original.to_json("from_original.json") # Takes 0 seconds
selected_subset1 = original.select([i for i in range(len(original))])
selected_subset1.to_json("from_select1.json") # Takes 212 seconds
selected_subset2 = original.select([i for i in range(int(len(original) / 2))])
selected_subset2.to_json("from_select2.json") # Takes 90 seconds
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: master (https://github.com/huggingface/datasets/commit/6090f3cfb5c819f441dd4a4bb635e037c875b044)
- Platform: Linux-4.4.0-19041-Microsoft-x86_64-with-glibc2.27
- Python version: 3.9.7
- PyArrow version: 6.0.0
| 157 | `.to_json` is extremely slow after `.select`
## Describe the bug
Saving a dataset to JSON with `to_json` is extremely slow after using `.select` on the original dataset.
## Steps to reproduce the bug
```python
from datasets import load_dataset
original = load_dataset("squad", split="train")
original.to_json("from_original.json") # Takes 0 seconds
selected_subset1 = original.select([i for i in range(len(original))])
selected_subset1.to_json("from_select1.json") # Takes 212 seconds
selected_subset2 = original.select([i for i in range(int(len(original) / 2))])
selected_subset2.to_json("from_select2.json") # Takes 90 seconds
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: master (https://github.com/huggingface/datasets/commit/6090f3cfb5c819f441dd4a4bb635e037c875b044)
- Platform: Linux-4.4.0-19041-Microsoft-x86_64-with-glibc2.27
- Python version: 3.9.7
- PyArrow version: 6.0.0
Hi, thanks for the response!
I still don't understand why it is so much slower than iterating and saving:
```python
from datasets import load_dataset
original = load_dataset("squad", split="train")
original.to_json("from_original.json") # Takes 0 seconds
selected_subset1 = original.select([i for i in range(len(original))])
selected_subset1.to_json("from_select1.json") # Takes 99 seconds
selected_subset2 = original.select([i for i in range(int(len(original) / 2))])
selected_subset2.to_json("from_select2.json") # Takes 47 seconds
selected_subset3 = original.select([i for i in range(len(original)) if i % 2 == 0])
selected_subset3.to_json("from_select3.json") # Takes 49 seconds
import json
import time
def fast_to_json(dataset, path):
start = time.time()
with open(path, mode="w") as f:
for example in dataset:
f.write(json.dumps(example, separators=(',', ':')) + "\n")
end = time.time()
print(f"Saved {len(dataset)} examples to {path} in {end - start} seconds.")
fast_to_json(original, "from_original_fast.json")
fast_to_json(selected_subset1, "from_select1_fast.json")
fast_to_json(selected_subset2, "from_select2_fast.json")
fast_to_json(selected_subset3, "from_select3_fast.json")
```
```
Saved 87599 examples to from_original_fast.json in 8 seconds.
Saved 87599 examples to from_select1_fast.json in 10 seconds.
Saved 43799 examples to from_select2_fast.json in 6 seconds.
Saved 43800 examples to from_select3_fast.json in 5 seconds.
``` | [
-0.141525194,
0.0571966134,
-0.0722180232,
0.0681989118,
0.136124745,
0.2194975615,
0.046746891,
0.3875999153,
-0.2274019718,
0.0900387391,
0.0242867842,
0.5975733995,
0.1035956293,
-0.005102756,
-0.0279693883,
-0.086014539,
0.2221941054,
-0.0900991112,
0.1746011972,
-0.1625322402,
-0.0590377524,
0.0549281761,
-0.2299278229,
-0.0594089366,
-0.0879533738,
-0.219149977,
0.2162448466,
0.2001278251,
-0.0479841754,
-0.5275933743,
0.1242539659,
-0.2489386201,
-0.0099345464,
0.2772343159,
-0.0001129507,
-0.0150657743,
0.2114275843,
0.0991381928,
-0.3368496299,
-0.1462551504,
-0.415112704,
-0.225680083,
0.0833852589,
-0.298042208,
0.066322647,
-0.0846410096,
-0.1769528389,
-0.4959798455,
0.2122636437,
0.1154772937,
0.2199398577,
0.4510140419,
-0.3033972979,
-0.0790811852,
-0.0552353263,
0.181531325,
-0.2140921056,
0.4801721275,
0.2107043415,
0.0391824096,
0.252112329,
-0.0031733406,
-0.1437683105,
-0.1535900384,
0.107588999,
0.0181162357,
-0.0976983532,
-0.0757537931,
-0.0088001722,
-0.0124157416,
0.5476434231,
-0.3393144011,
-0.3384481966,
-0.2084252387,
-0.2480505109,
-0.0675924495,
0.0595410764,
0.0860677063,
0.0672686324,
-0.0964643955,
-0.2494890988,
0.0444305278,
-0.0011118134,
-0.1339291632,
0.2964818776,
-0.0866544321,
-0.1005108953,
0.1777942777,
0.2886148095,
0.0143430401,
0.0285984091,
-0.4829737544,
0.0172684062,
0.1187236831,
-0.5491201878,
-0.3798495233,
0.0983628333,
-0.3264733553,
-0.222133413,
0.2354884893,
0.0646226704,
-0.0775680542,
0.1080520526,
-0.0336574279,
0.4661750495,
0.2574314475,
0.0259038508,
0.2694677114,
0.1002531275,
0.1381376088,
-0.0613422953,
0.0192518085,
0.262773931,
-0.1673508584,
0.4899327457,
-0.0496560559,
0.2087733895,
-0.2451494932,
-0.5025871396,
0.1798560023,
-0.4054966271,
-0.2969255149,
-0.040705245,
0.0846815854,
-0.1106596887,
-0.0833006203,
-0.10268078,
0.2033507079,
-0.2756371498,
0.1512175649,
-0.1914523095,
0.1665677279,
0.0792310536,
0.1671355069,
-0.1999266595,
-0.2481625229,
0.0595088825,
0.2827677131,
-0.0709185004,
0.0619025379,
0.3161605299,
-0.1750262529,
-0.0531243049,
0.070041351,
0.1081811413,
0.343385607,
-0.0705207959,
-0.5403023958,
-0.3883312345,
0.2814795375,
-0.2215907872,
-0.1794191897,
0.1389423162,
0.1950954795,
-0.1272898018,
-0.263861537,
-0.7340602279,
0.2221507132,
0.0634203404,
-0.013568745,
0.1003855169,
-0.0268680081,
-0.1333956718,
-0.3842291832,
-0.037619736,
0.2866802812,
-0.5492136478,
0.1751157045,
0.3376581371,
-0.0216701347,
0.4824239016,
0.4459160566,
-0.2432141155,
0.2343830615,
-0.0623711906,
0.2931306362,
0.1755411923,
-0.0465446562,
-0.3762188554,
0.2605928183,
-0.2491621822,
0.3272435367,
-0.0022408529,
0.242737323,
-0.0398651212,
-0.3347547352,
0.1664064229,
0.3895264864,
0.1134124324,
0.2121185064,
-0.5212129354,
-0.1275529414,
0.1446263492,
0.0732326061,
-0.4954231083,
0.1144243479,
-0.0918682739,
0.2167651504,
0.4174663126,
-0.2440637201,
-0.1367348582,
0.4039120078,
0.3786316216,
-0.2235646993,
-0.2100960016,
-0.0380246304,
-0.2238334119,
0.2148572803,
0.0691618919,
-0.2901186347,
0.1228443384,
-0.1143848225,
-0.1213712618,
0.0359931253,
-0.3633660972,
0.0177804716,
0.0299919825,
0.0938613415,
0.3762405217,
0.1257511973,
0.0760853216,
0.2111969292,
-0.0117083043,
-0.0949795097,
-0.5944105983,
0.2689832747,
0.0062840274,
-0.2690676153,
0.0431747735,
-0.1246744841,
0.213453576,
-0.2701279521,
-0.3491313159,
0.1790652275,
0.0810956806,
0.2691420019,
0.0847279951,
0.0725811869,
0.0372068323,
-0.0228920691,
0.2787643969,
0.3253176212,
0.2495271266,
-0.0865150169,
-0.4419248104,
0.3939855993,
-0.0983514339,
0.2821745574,
0.1420217752,
-0.3718956113,
-0.0028668095,
0.1617000848,
0.1463005841,
0.0656283796,
0.1483608931,
0.4280651808,
0.1280821115,
0.0643309578,
-0.5504081845,
0.2929072082,
0.5612955093,
-0.1986441761,
-0.1426467896,
0.166850239,
0.0247513168,
-0.24767676,
-0.0830123574,
0.0780618563,
0.4658493698,
-0.0273768194,
0.0384075604,
-0.1275173873,
0.0145459408,
-0.1688535661,
0.1621082425,
-0.0564677715,
0.3576234579,
-0.0531662405,
0.4698261321,
0.0399377085,
-0.0673468858,
0.0076175798,
-0.2238800377,
0.1914982498,
-0.1102313101,
0.3662958741,
-0.3055780232,
0.168711856,
-0.0470916405,
-0.1412177682,
-0.0157676879,
-0.3286732733,
-0.1775769442,
0.1054156423,
-0.0817890763,
-0.2565817535,
-0.0798301697,
-0.0772588998,
0.0578602292,
-0.4655489922,
-0.196325466,
-0.113372162,
-0.3123549223,
0.0382496379,
0.0750332922,
0.0501148589,
0.239126116,
0.0579665005,
-0.2794499993,
-0.008564854,
-0.2900516689,
-0.2131358087,
-0.2033653259,
0.5882799029,
-0.0857699588,
0.0599746853,
-0.0326217227,
-0.1904881001,
0.1898447424,
0.1854423881,
-0.2672302425,
0.0668517351,
-0.1086260751,
-0.0711195394,
0.3810195327,
-0.3852275014,
-0.1057123095,
-0.1523787677,
0.4267993569,
0.0308883879,
-0.0053048278,
0.2086134404,
0.156507954,
-0.0308347642,
0.256891489,
0.191740483,
-0.2718597651,
-0.2790312171,
0.4453031123,
0.0398446098,
-0.1928121299,
-0.2465355396,
0.0268600043,
-0.0000372796,
-0.2446018308,
-0.4528475106,
-0.046409376,
-0.6421847939,
0.329952091,
-0.1069818065,
0.0565502308,
0.2111710459,
-0.0208451245,
-0.0986383855,
0.0668165162,
-0.4338129461,
-0.1214085743,
0.372835964,
0.016676262,
-0.0548193306,
0.3770759404,
0.1341183931,
0.4359669685,
0.4670132995,
-0.0132510886,
0.2590840161,
0.1184198409,
-0.0744528621,
-0.5639155507,
-0.4056041241,
-0.0279292967,
-0.1830391884,
-0.1844917238,
-0.0869743675,
-0.0917011052,
-0.2435576171,
0.1423274577,
-0.1320413202,
-0.1227202415,
-0.1121738479,
0.0151001988,
0.0514857247,
-0.1315749288,
0.3054151833,
0.1157820895,
-0.2025295496,
0.0959771052,
0.0027289619,
0.0691922978,
0.2738050222,
-0.1540249288,
-0.8439213037,
-0.2265272141,
-0.3949464262,
0.1684971154,
0.0291995686,
0.2496982366,
0.1247913018,
-0.2195774913,
0.2817535996,
-0.1565481424,
0.4056993425,
-0.0177882053,
-0.0976179242,
0.4112003148,
-0.2556419969,
-0.3272459507,
-0.0812738538,
0.0131202266,
0.4306881726,
0.4347165823,
0.3323307037,
-0.1221221834,
-0.2227889746,
0.3045164049,
0.5938842297,
-0.0156988967,
-0.1601017565,
-0.3275744021,
-0.3682328165,
-0.1294555366,
-0.0417083167,
-0.2896509767,
0.2395186722,
0.0759513527,
-0.1399256587,
0.0109493537,
-0.0672311932,
-0.076220952,
-0.1040084884,
0.2069806755,
-0.0231698565,
0.5487129688,
-0.183389768,
-0.033999972,
0.2690096796,
0.6415680051,
0.1367254853,
-0.3767363131,
-0.0781137794,
0.2992781401,
0.170650214,
0.2856515944,
-0.0458879918,
0.1048257872,
-0.1762847602,
0.044882752,
-0.1327095479,
-0.3356394172,
0.3066625893,
0.0103884721,
-0.2658015192,
-0.3517196476,
0.5191374421,
0.1450932026,
0.0474626683,
0.0182686616,
-0.1735232472,
0.1887025833,
0.2042840123,
-0.0053530084,
0.8797033429,
0.0877029225,
0.1223355159,
0.297157377,
-0.2537456751,
0.3298408687,
-0.0205181893,
0.1138952002,
-0.362914592,
-0.1698938906,
0.3435956538,
-0.2907740474,
-0.0418597385,
0.0088083763,
-0.050197009,
0.2434742749,
-0.313888967,
-0.1406024992,
-0.035090737,
0.2566433251,
-0.1253536195,
-0.060683623,
-0.1916240603,
0.1277063191,
0.2095180899,
-0.003051105,
0.1137861311,
-0.1337272823,
-0.4224033654,
0.0128708323,
-0.1351495087,
0.3263962567,
0.0129463263,
0.2684400082,
0.0997748822,
-0.545589447,
0.2636107206,
0.2222103626,
0.1554383785,
0.2475041896,
-0.0280163549,
0.0196230188,
-0.0607715659,
0.4661371112,
0.3151881993,
-0.4391138852,
0.2665515542,
0.0656361058,
-0.0976291373,
-0.0939914733,
-0.2313027978,
-0.2373758405,
-0.2395758182,
0.2861467004,
-0.0563033633,
-0.238819018,
-0.5121665001,
0.2051509619,
-0.0180988275,
-0.4063471556,
0.1444154382,
0.1360506415,
0.111517407,
0.4939998686,
-0.3276518285,
-0.2560672462,
0.0236005057,
0.4288364351,
0.308204025,
-0.0231713261,
0.3604950309,
0.0850955993,
-0.3229475617,
-0.0989124104,
0.3029220402,
0.2354353815,
-0.2416036427,
0.3443708122,
-0.3379699588,
0.3694308102,
-0.10366036,
0.2229278684,
-0.2737130225,
-0.0808297917,
-0.0979866758,
-0.1085788757,
-0.1326066107,
-0.0147075206,
0.2885671556,
0.0289801955,
0.1032439768,
-0.0313137732,
-0.3142435849,
0.2918789983,
-0.2617714405,
0.0471054167,
-0.1107734591,
0.1741244644,
0.1151574999,
-0.0361848511,
0.2002707869,
-0.0902198404,
0.2100494653,
0.059264902,
0.0264424551,
-0.2859489918,
-0.0069268006,
0.1095131561,
-0.1426971704,
-0.3248060942,
0.0457029715,
-0.0119877784,
-0.0033224358,
-0.1836348623,
-0.0339648202,
0.1396414936,
0.011594112,
-0.1078934446,
0.1284306496,
-0.1332579404,
0.1438876241,
0.0409529954,
-0.2916141152,
0.3298972547,
0.0550848693,
0.1968719512,
0.0258703493,
-0.1704217941,
-0.4832948148,
-0.1459342837,
0.0350338742,
0.3800562024,
0.2126362622,
-0.3405205607,
-0.1052728668,
0.0593566969,
0.2071988285,
0.5806125402,
-0.0191952735,
0.0569173358,
-0.321012944,
0.1576364636,
0.1519163251,
-0.4581233859,
0.0405414179,
-0.0439011939,
-0.0290375501,
0.0828228816,
-0.020639319,
0.4486771226,
0.0494951643,
-0.1056111306,
0.306601733,
0.1134172231,
0.1366063803,
0.2347331345,
0.2875874937,
-0.1390492916,
0.2339871824,
0.1308010221,
0.2505461872,
-0.0055734995,
0.0632742122,
0.2057074159,
0.3916637003,
0.1445071399,
-0.225939557,
-0.1518240571,
-0.013104192,
0.1826595217,
-0.0054827323,
-0.0046858424,
0.3760847151,
-0.0885906965,
-0.1936905831,
-0.1642114222,
0.1058681384,
0.2251963168,
-0.0526938103,
-0.2534298599,
-0.057050772,
0.0015407992,
0.0063897804,
0.2322254926,
-0.2693991363,
-0.1045708954,
0.0131275002,
-0.0697310641,
0.1096080095,
-0.3768788874,
0.2246237546,
-0.1352375746,
0.2229737639,
-0.1491528898,
0.1514487565,
0.1069243029,
-0.0400524214,
-0.3501263261,
0.2801945508,
0.5537212491,
0.2702331841,
0.0020290737,
0.3253143132,
-0.0668053553,
-0.2004598081,
0.2931376696,
0.1948146522,
-0.1984039247,
0.0552876666,
0.2812349498,
0.134521693,
-0.1118230149,
0.0543554351,
0.1895143539,
0.0671717376,
-0.3570252359,
-0.0077226833,
-0.0513725132,
-0.1993951797,
-0.1436374784,
0.0595355183,
-0.256459415,
-0.1079984307,
-0.0469075814,
-0.0003996503,
0.1043765247,
-0.0084688785,
0.1295123994,
-0.1259377152,
0.3441361189,
0.1197757795,
0.1811247766,
-0.4527844191,
0.0839604512,
0.0264232382,
-0.2063645869,
-0.1341281831,
0.0417849086,
0.0470195524,
0.5455507636,
-0.0250698887,
0.2553902864,
0.1544786096,
0.4040150046,
-0.1279731244,
0.2899949253,
-0.1911487281,
0.0110965306,
0.1337502301,
-0.2427382171,
-0.110029839,
-0.3639656901,
0.2578966618,
0.0064098747,
0.1000279635,
-0.4198907018,
-0.1052946374,
0.2660743892,
0.4798904657,
0.4397669435,
0.253475666,
0.0014752145,
-0.1907308549,
-0.2765493393,
0.150734067,
-0.0546058565,
-0.030258121,
0.2417236269,
-0.1457765102,
0.2923898101,
-0.0024407927,
0.153824538,
-0.1543660462,
0.0646096319,
-0.268489033,
-0.2022571117,
-0.1421526819,
-0.0453434326,
-0.0250521936,
0.3404429853,
0.0144899096,
0.1711996049,
0.0748422444,
0.3890320063,
-0.3670270741,
-0.180870682,
0.3550505638,
-0.0061779199,
-0.0967352316,
0.1548164636,
0.2001547515,
0.1597261578,
0.1394755989,
0.2411685735,
-0.0012411075,
0.5445434451,
-0.1616694927,
-0.1680221409,
0.46795699,
-0.0998877883,
0.05788083,
-0.0403746292,
0.349362731,
-0.0538800284,
-0.098662056,
0.1218720526,
-0.2420042008
] |
https://github.com/huggingface/datasets/issues/3419 | `.to_json` is extremely slow after `.select` | There are slight differences between what you're doing and what `to_json` is actually doing.
In particular `to_json` currently converts batches of rows (as an arrow table) to a pandas dataframe, and then to JSON Lines. From your benchmark it looks like it's faster if we don't use pandas.
Thanks for investigating, I think we can optimize `to_json` significantly thanks to your test. | ## Describe the bug
Saving a dataset to JSON with `to_json` is extremely slow after using `.select` on the original dataset.
## Steps to reproduce the bug
```python
from datasets import load_dataset
original = load_dataset("squad", split="train")
original.to_json("from_original.json") # Takes 0 seconds
selected_subset1 = original.select([i for i in range(len(original))])
selected_subset1.to_json("from_select1.json") # Takes 212 seconds
selected_subset2 = original.select([i for i in range(int(len(original) / 2))])
selected_subset2.to_json("from_select2.json") # Takes 90 seconds
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: master (https://github.com/huggingface/datasets/commit/6090f3cfb5c819f441dd4a4bb635e037c875b044)
- Platform: Linux-4.4.0-19041-Microsoft-x86_64-with-glibc2.27
- Python version: 3.9.7
- PyArrow version: 6.0.0
| 62 | `.to_json` is extremely slow after `.select`
## Describe the bug
Saving a dataset to JSON with `to_json` is extremely slow after using `.select` on the original dataset.
## Steps to reproduce the bug
```python
from datasets import load_dataset
original = load_dataset("squad", split="train")
original.to_json("from_original.json") # Takes 0 seconds
selected_subset1 = original.select([i for i in range(len(original))])
selected_subset1.to_json("from_select1.json") # Takes 212 seconds
selected_subset2 = original.select([i for i in range(int(len(original) / 2))])
selected_subset2.to_json("from_select2.json") # Takes 90 seconds
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: master (https://github.com/huggingface/datasets/commit/6090f3cfb5c819f441dd4a4bb635e037c875b044)
- Platform: Linux-4.4.0-19041-Microsoft-x86_64-with-glibc2.27
- Python version: 3.9.7
- PyArrow version: 6.0.0
There are slight differences between what you're doing and what `to_json` is actually doing.
In particular `to_json` currently converts batches of rows (as an arrow table) to a pandas dataframe, and then to JSON Lines. From your benchmark it looks like it's faster if we don't use pandas.
Thanks for investigating, I think we can optimize `to_json` significantly thanks to your test. | [
-0.2503959835,
0.2378024757,
-0.1249384433,
-0.1713117659,
0.1673329324,
0.0435040705,
0.0635808259,
0.6106277108,
-0.2218094766,
0.0939173326,
-0.0214232244,
0.6983178258,
0.0707772151,
-0.079195939,
-0.0524651781,
0.0165274143,
0.1349955648,
-0.0152917076,
0.0161851514,
-0.1370963156,
-0.2098418623,
0.0587012209,
-0.159924984,
0.0364310145,
-0.0972954929,
-0.2456741184,
0.1418774724,
0.1193137765,
0.0031333021,
-0.3770897686,
-0.0082237124,
-0.1620412618,
-0.0909422711,
0.2664236426,
-0.0001016013,
0.035038624,
0.0929892585,
0.0512076244,
-0.3995318711,
-0.0975441188,
-0.2109442502,
-0.2653706968,
0.1664620489,
-0.3124701977,
-0.0308484845,
-0.0645480379,
-0.1038405746,
-0.2907902002,
0.4291034043,
0.1806691885,
0.301787883,
0.3703414798,
-0.1839235872,
-0.0814733952,
-0.0025726287,
0.1360293627,
-0.1501731575,
0.3968878388,
0.0845182911,
0.067115359,
0.0540101677,
0.0687457845,
-0.1829894185,
-0.1664602906,
0.0057008206,
0.0333068408,
-0.1071064994,
-0.0879263878,
0.0016005062,
0.1248911023,
0.3625846207,
-0.3336620629,
-0.3885550201,
-0.2272556126,
0.0169749577,
0.0107997917,
0.0573973693,
0.0401425511,
0.0153410239,
-0.02454721,
-0.1420698911,
0.02303279,
-0.0134240333,
-0.1471848041,
0.1463749409,
-0.0191186592,
-0.0518242382,
0.0440156646,
0.3721788824,
-0.1001985669,
-0.0347946621,
-0.4278786182,
0.0418717079,
0.0599872544,
-0.5377767682,
-0.4182269573,
-0.0032803877,
-0.5745549798,
-0.2515137792,
0.2420827448,
0.2485873252,
0.0951322392,
0.2942125797,
-0.0187996607,
0.2998629808,
0.0668955743,
-0.0129844788,
0.1866444498,
0.1584454626,
0.0646878928,
-0.092346482,
0.1964016855,
0.0509713702,
-0.1453683078,
0.2192653418,
-0.1794417799,
0.100295715,
-0.0394343734,
-0.4513498545,
0.0497817434,
-0.3608946502,
-0.2151987553,
-0.0964342132,
0.1281974316,
-0.1647616029,
-0.062529631,
-0.0768108517,
0.0488201939,
-0.1995474249,
0.1734290272,
-0.2556201816,
0.2718815207,
0.0244571902,
0.0215945728,
-0.0569452569,
-0.0914174169,
-0.0441788472,
0.0997318253,
-0.0294545516,
0.193622306,
0.2282822728,
-0.0830626041,
-0.2056282312,
0.1060933843,
0.1342857033,
0.0724938139,
-0.1086307541,
-0.4018720388,
-0.4661527574,
0.2079288363,
-0.1239955202,
-0.2403931469,
0.1721952558,
0.3063456714,
-0.0494334586,
-0.2604129612,
-0.607000649,
0.3252220452,
-0.0811798647,
0.1348978579,
-0.0353861935,
0.0923535824,
0.1217908859,
-0.3821808994,
0.0466743782,
0.2121394724,
-0.4239340127,
0.0754389763,
0.4371512532,
0.0275443327,
0.4549981952,
0.4105762243,
-0.2795130312,
0.1250847429,
0.1757536978,
0.2624893486,
0.3259250522,
-0.0703937188,
-0.3116873503,
0.2136979997,
-0.2763046026,
0.0480347313,
0.0502004437,
0.1537263542,
0.1320896447,
-0.1800527424,
0.2622281611,
0.4670516551,
0.1403413862,
0.2515659928,
-0.4862968326,
-0.1910043359,
0.1443220675,
0.2512943745,
-0.4521803856,
0.035611134,
-0.0242469199,
0.2695321739,
0.2546752095,
-0.2365942001,
-0.0728919208,
0.30782184,
0.3168504834,
-0.3446029425,
-0.2763070166,
-0.0258472897,
-0.1641948968,
0.0958665311,
0.0299473703,
-0.1285357326,
0.0658767596,
-0.1606660336,
-0.009617636,
0.0248192418,
-0.1556761116,
0.0577024296,
0.1573223472,
-0.0082073882,
0.4396990836,
0.0597879067,
-0.0909113213,
0.126562655,
-0.1795949936,
0.0661460012,
-0.2796418667,
0.2902971804,
0.020349469,
-0.348220557,
0.2736334801,
-0.0899030864,
0.0373932421,
-0.2426604033,
-0.2186574936,
0.123085089,
-0.0649451241,
0.2436860949,
0.3069054186,
-0.0119015183,
-0.0351589955,
0.0836761072,
0.1919573098,
0.2085307688,
0.1408371031,
-0.0025742557,
-0.5111404657,
0.4881326258,
-0.0881512761,
0.2310770899,
0.183625713,
-0.3565555811,
0.0818882883,
0.1529377103,
0.0006006616,
0.1818210483,
-0.1522517204,
0.506485343,
0.0720420927,
0.2064108551,
-0.5585559011,
0.2828577161,
0.6308921576,
-0.2551838458,
0.0175113771,
0.2926717997,
0.0494721346,
-0.278727591,
-0.1366983205,
0.0548409149,
0.3175992668,
0.1794975698,
0.0788780153,
-0.1997199506,
-0.1232642382,
-0.083541505,
0.168760702,
-0.0648912638,
0.3700634539,
-0.0799201503,
0.3501680493,
-0.0177040063,
-0.1962515712,
0.0022505082,
-0.1674725413,
0.2572056353,
0.0623290055,
0.2555961907,
-0.2237694114,
0.2412625104,
0.1460203081,
-0.0900494233,
0.0742030516,
-0.2842895687,
0.0141886855,
0.0799041018,
-0.1959103495,
0.0227383245,
-0.0893855691,
0.1119924784,
0.0562207624,
-0.5037917495,
-0.1990323663,
-0.0855021924,
-0.2611595392,
0.2037776709,
0.0390838794,
0.1658776999,
0.1911858022,
0.071245417,
-0.0850709081,
0.0408607833,
-0.1997081637,
-0.1211267412,
-0.2610802054,
0.3525977135,
-0.077137664,
0.1473807245,
-0.1672985554,
-0.2616322637,
0.186907813,
0.0753709525,
-0.3148607612,
0.0545539185,
-0.1685237288,
-0.1175375879,
0.2826782763,
-0.432441771,
-0.1714737266,
-0.2707915306,
0.4579289854,
0.0450442508,
0.033720538,
0.0417612493,
0.2312010229,
0.10900186,
0.1417301893,
0.1279231757,
-0.196924299,
-0.2280316949,
0.5487467647,
0.1174133047,
-0.2402159423,
-0.1919679493,
-0.0614277609,
0.009616429,
-0.2422948778,
-0.253614068,
-0.0845463201,
-0.4037928283,
0.2707932591,
-0.0385646299,
-0.0039555947,
0.290263921,
0.060181763,
-0.2616476715,
0.2031914145,
-0.2721651196,
-0.0705963597,
0.3222846985,
-0.0459734201,
-0.2378687263,
0.2979861796,
0.081571579,
0.3511075377,
0.28297773,
-0.1055571809,
0.1088353321,
0.0262573138,
0.0281908251,
-0.3876003027,
-0.2867638171,
0.0781808943,
-0.1837572902,
0.0126927067,
-0.0117646335,
-0.2035284638,
-0.3803871572,
0.1086752042,
-0.0637224466,
-0.2526530921,
-0.2093396783,
0.1590675563,
0.1587125212,
-0.1664377302,
0.2633393705,
0.1511070877,
-0.1546627134,
0.1266334802,
0.0110832546,
-0.0135175865,
0.2351943105,
-0.181706503,
-0.8477036953,
-0.1726402342,
-0.4840191305,
0.1475000679,
-0.0274039414,
0.1100771353,
0.260132134,
-0.28071931,
0.1828175634,
-0.3039473891,
0.4027149081,
0.0524521172,
-0.2089019865,
0.3382767737,
-0.1604099274,
-0.3566504419,
0.0722191557,
-0.082303986,
0.2534727454,
0.3947459459,
0.2372004539,
-0.3125941455,
-0.1843011528,
0.318857789,
0.2786617279,
0.0476965532,
-0.0372945666,
-0.295814991,
-0.4146120846,
-0.2543053627,
0.2290710211,
-0.2354577631,
0.238128677,
0.0520715676,
-0.2695268691,
-0.0178118385,
-0.1106635928,
0.0772065967,
0.1083741784,
0.0965993032,
0.0285489913,
0.4691228569,
-0.1684797555,
0.0684935004,
0.4049863517,
0.4466944039,
0.085552685,
-0.2616366744,
0.0311769918,
0.3094960451,
0.166826278,
0.3660056889,
0.006526676,
0.1444890499,
-0.280916363,
0.1885597855,
0.0746702403,
-0.227652967,
0.2246451229,
0.0377154388,
-0.1363986582,
-0.3237576187,
0.3496024013,
-0.0279620271,
0.0250485707,
-0.0723082796,
-0.1132722944,
0.1846269816,
0.2218175679,
0.1339513808,
0.9346584082,
0.0680771843,
0.2186432332,
0.3597020507,
-0.2716217041,
0.4036179781,
-0.1439910233,
0.1784942001,
-0.3261262476,
-0.0178274456,
0.3403764069,
-0.1832963824,
0.0285632182,
0.2210139334,
-0.0309758652,
0.1320131272,
-0.1053818017,
-0.0691482872,
-0.085319519,
0.3266869485,
-0.0789715275,
-0.3128966689,
-0.4167634249,
0.238895461,
0.077462256,
-0.1768785417,
0.2803983092,
-0.1883401275,
-0.4847393036,
0.0581378341,
-0.0017507835,
0.3398935199,
-0.0137127964,
0.271425724,
0.1993317902,
-0.3149795234,
0.0328595191,
0.1494445652,
0.0510489568,
0.2344257683,
0.0367087126,
0.1106582135,
-0.117445454,
0.3738915324,
0.2562256753,
-0.309310019,
0.3480418622,
-0.045828253,
-0.1773752272,
0.1598115265,
-0.1903682202,
-0.3076970279,
-0.0944204181,
0.20332627,
-0.0893397704,
-0.2294295877,
-0.3973999918,
0.1960685551,
-0.254524529,
-0.41452384,
0.2457470447,
0.0782741755,
0.0328804106,
0.474876374,
-0.1083834097,
-0.2436627448,
-0.0824670121,
0.4801318347,
0.2201749533,
0.0600062609,
0.3035833836,
-0.0938289091,
-0.3210491538,
-0.2355714589,
0.3457919359,
0.2800157666,
-0.1193259954,
0.2572590709,
-0.2147907019,
0.0512117408,
0.0386282392,
0.1411404908,
-0.0519986637,
-0.0260459054,
-0.0235258788,
0.0007618556,
-0.2091116309,
0.0928477347,
0.3100551367,
0.0349782221,
0.0945450962,
0.129450351,
-0.3187455535,
0.1782371253,
-0.3968226016,
0.0489091948,
-0.2624993324,
0.0297491718,
-0.0563887097,
-0.2502333224,
0.2140832841,
-0.0386505127,
0.3355618417,
0.1008079723,
-0.0768443942,
-0.4160560369,
0.0287920982,
0.0358497389,
-0.1556239277,
-0.1812350601,
0.0530455969,
0.0639344752,
-0.2146666199,
-0.232725367,
0.0342658013,
-0.0161234103,
0.0094254389,
-0.235552296,
0.1498121619,
-0.1984954029,
0.1946710944,
-0.1140335053,
-0.2035950571,
0.3525973558,
-0.0533344969,
0.1578993797,
0.0129827252,
-0.1854412109,
-0.3371756971,
-0.0289058629,
0.0822370127,
0.3269315958,
0.1969717145,
-0.3517019153,
-0.2547951639,
-0.0643032938,
0.1979707032,
0.5476304889,
0.0009917554,
-0.0355204083,
-0.236618951,
0.2946246862,
-0.1215800196,
-0.3579909205,
0.0455942787,
-0.1435238868,
0.0890261233,
-0.0031197225,
-0.0857084021,
0.4756791592,
0.1220398918,
-0.0271911323,
0.22892721,
0.092349425,
-0.0489989296,
0.1998846978,
0.214448452,
-0.1074296385,
0.320812583,
0.208791703,
0.3198990524,
0.0936176106,
0.0721278489,
0.2694587708,
0.153292343,
0.2292632163,
-0.2255680114,
-0.0136525929,
0.0043409024,
0.1438372582,
-0.0869669393,
0.026242815,
0.3738459945,
-0.0262329746,
-0.1763040721,
-0.2470268309,
0.0499862209,
0.2757522166,
-0.1321147233,
-0.2725328803,
-0.193260327,
0.0034897013,
-0.0838087872,
0.1355602443,
-0.1907896101,
-0.1359642446,
-0.1673498601,
-0.080774188,
0.2337323725,
-0.1612924784,
0.199808076,
-0.2447858304,
0.2500669956,
-0.0776776522,
0.0794352889,
0.1001687199,
-0.0222975295,
-0.2820625603,
0.1197093055,
0.358494997,
0.1376028806,
-0.0888154209,
0.2672447562,
-0.0943101943,
-0.1718906909,
0.1190612763,
0.1627908349,
0.0264455229,
-0.1755460054,
0.3467520177,
0.237705633,
-0.2766533494,
-0.0382132679,
0.1033826247,
-0.0712045357,
-0.2066875696,
0.0277025737,
0.151121676,
-0.223599121,
-0.137328729,
0.117349945,
-0.2124457061,
-0.0343585722,
-0.196401909,
-0.0409326889,
-0.0348489806,
-0.0768888146,
0.1940555423,
-0.0018787705,
0.4558204114,
-0.1506500393,
0.1083432212,
-0.2013710439,
0.089597106,
-0.1085288227,
-0.1452707052,
-0.0996675119,
0.0596121177,
0.0442095175,
0.5059889555,
0.2196410149,
0.3198701739,
0.01207578,
0.4222246408,
-0.1654482931,
0.2330664098,
-0.304127723,
0.1640481502,
0.0617777444,
-0.0670287684,
-0.0544115603,
-0.3672463298,
0.2460104823,
-0.0076783546,
0.1818060428,
-0.3678822517,
-0.1276557446,
0.2836916745,
0.4523615837,
0.3857597113,
0.0840992704,
-0.0666269884,
-0.2292940915,
-0.289211452,
0.2196380943,
-0.0159845632,
-0.0471455455,
0.1907085627,
-0.0443288125,
0.3135713637,
0.1677237004,
-0.0135920607,
-0.0807755366,
0.0462175868,
-0.1739217192,
-0.2352408618,
-0.1776249111,
0.0301780906,
0.1084753498,
0.3219669759,
-0.0392904654,
0.2695941031,
0.0331107751,
0.2696537673,
-0.3324785829,
-0.1459177881,
0.3916319311,
-0.1208638027,
-0.1739280075,
0.0804717019,
0.1871799231,
0.2121389657,
0.1382175833,
0.1931222081,
0.0139489239,
0.3721092045,
-0.1872173697,
-0.1696110219,
0.4170661569,
-0.1651668996,
0.0650924444,
-0.1386027634,
0.1867391914,
-0.1366535574,
-0.0025840884,
-0.1491069347,
-0.378151536
] |
https://github.com/huggingface/datasets/issues/3419 | `.to_json` is extremely slow after `.select` | Thanks for your observations, @eladsegal! I spent some time with this and tried different approaches. Turns out that https://github.com/huggingface/datasets/blob/bb13373637b1acc55f8a468a8927a56cf4732230/src/datasets/io/json.py#L100 is giving the problem when we use `to_json` after `select`. This is when `indices` parameter in `query_table` is not `None` (if it is `None` then `to_json` should work as expected)
In order to circumvent this problem, I found out instead of doing Arrow Table -> Pandas-> JSON we can directly go to JSON by using `to_pydict()` which is a little slower than the current approach but at least `select` works properly now. Lmk what you guys think of it @lhoestq, @eladsegal? | ## Describe the bug
Saving a dataset to JSON with `to_json` is extremely slow after using `.select` on the original dataset.
## Steps to reproduce the bug
```python
from datasets import load_dataset
original = load_dataset("squad", split="train")
original.to_json("from_original.json") # Takes 0 seconds
selected_subset1 = original.select([i for i in range(len(original))])
selected_subset1.to_json("from_select1.json") # Takes 212 seconds
selected_subset2 = original.select([i for i in range(int(len(original) / 2))])
selected_subset2.to_json("from_select2.json") # Takes 90 seconds
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: master (https://github.com/huggingface/datasets/commit/6090f3cfb5c819f441dd4a4bb635e037c875b044)
- Platform: Linux-4.4.0-19041-Microsoft-x86_64-with-glibc2.27
- Python version: 3.9.7
- PyArrow version: 6.0.0
| 100 | `.to_json` is extremely slow after `.select`
## Describe the bug
Saving a dataset to JSON with `to_json` is extremely slow after using `.select` on the original dataset.
## Steps to reproduce the bug
```python
from datasets import load_dataset
original = load_dataset("squad", split="train")
original.to_json("from_original.json") # Takes 0 seconds
selected_subset1 = original.select([i for i in range(len(original))])
selected_subset1.to_json("from_select1.json") # Takes 212 seconds
selected_subset2 = original.select([i for i in range(int(len(original) / 2))])
selected_subset2.to_json("from_select2.json") # Takes 90 seconds
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: master (https://github.com/huggingface/datasets/commit/6090f3cfb5c819f441dd4a4bb635e037c875b044)
- Platform: Linux-4.4.0-19041-Microsoft-x86_64-with-glibc2.27
- Python version: 3.9.7
- PyArrow version: 6.0.0
Thanks for your observations, @eladsegal! I spent some time with this and tried different approaches. Turns out that https://github.com/huggingface/datasets/blob/bb13373637b1acc55f8a468a8927a56cf4732230/src/datasets/io/json.py#L100 is giving the problem when we use `to_json` after `select`. This is when `indices` parameter in `query_table` is not `None` (if it is `None` then `to_json` should work as expected)
In order to circumvent this problem, I found out instead of doing Arrow Table -> Pandas-> JSON we can directly go to JSON by using `to_pydict()` which is a little slower than the current approach but at least `select` works properly now. Lmk what you guys think of it @lhoestq, @eladsegal? | [
-0.2212164849,
0.1027248725,
-0.0186260473,
0.1187605038,
0.2550524175,
0.1281235218,
-0.0699113682,
0.4468907118,
-0.1404294074,
0.0742776841,
-0.0600850955,
0.7489500046,
0.1289311498,
0.0481083617,
0.0308408998,
0.1059495285,
0.0500632152,
0.0200785641,
-0.0194915552,
-0.068450205,
-0.2514808774,
0.0447714403,
-0.1163403764,
-0.1094155088,
-0.0245003086,
-0.2224408388,
0.30149737,
0.0965206325,
-0.0075459643,
-0.5093438625,
0.0734262392,
-0.1758192331,
-0.1354288459,
0.2081249803,
-0.0001137351,
0.0679664835,
0.2719678879,
0.0535828173,
-0.5365381837,
-0.2311483026,
-0.3573003113,
-0.1388940811,
0.2557535172,
-0.2531037033,
-0.133645609,
0.0310371742,
-0.2982209325,
-0.3060910404,
0.3510064483,
0.0293588005,
0.2309679985,
0.3628421426,
-0.1646858156,
-0.1156876832,
0.2009748518,
0.3561604023,
-0.1560839713,
0.3634010851,
0.2044868469,
0.0620482489,
0.1399972141,
0.1037326902,
-0.0372602642,
-0.1979278922,
0.0561100803,
-0.0299407113,
-0.2686745226,
-0.027357785,
-0.0916126668,
0.1446889937,
0.4100539386,
-0.2249978036,
-0.3544405997,
-0.2841422856,
-0.0421535634,
-0.2869593799,
0.1476748288,
-0.1135684177,
0.0757285878,
-0.0883656964,
-0.3265125453,
-0.064691864,
0.0433592461,
-0.1626910567,
0.19790712,
0.027279688,
-0.121052362,
0.0473252796,
0.3540074825,
-0.1101483554,
-0.2436462939,
-0.1927631497,
0.0111338077,
0.003638458,
-0.6001591086,
-0.3125501871,
0.2634398639,
-0.4776878953,
-0.1184315532,
0.1514356434,
0.15534769,
0.0649712533,
0.1557543427,
-0.129844889,
0.2791085541,
0.2930158973,
-0.0213461854,
0.135121733,
0.2560072839,
0.4250747859,
0.0322534852,
0.1277362704,
0.1885881573,
-0.1201056615,
0.1591015756,
-0.0116670644,
0.2295640707,
-0.1727411151,
-0.5613194108,
0.2919116914,
-0.2507843971,
-0.1939918846,
0.0901198015,
0.1056158319,
-0.0429242477,
-0.1535499841,
0.084748432,
0.0801765919,
-0.3961700201,
0.1751001924,
-0.2035050541,
0.0765612721,
-0.0428600945,
0.1174688861,
-0.0187811684,
-0.3109202981,
-0.0811692253,
0.2774203122,
-0.0323445387,
0.1001666263,
0.2295553386,
-0.0565466136,
-0.0378032066,
0.2724794745,
-0.0369925499,
0.2297141403,
-0.0668642074,
-0.4862954021,
-0.4216568768,
0.1722474992,
-0.2782514691,
-0.2276365608,
0.1720303595,
0.2213504314,
-0.1306199729,
-0.1439812779,
-0.6190977097,
0.2602885664,
0.0193811171,
0.1665795147,
0.0303729679,
0.0334031023,
-0.2842152417,
-0.2251517028,
0.2023118734,
0.4405194521,
-0.4770883918,
0.0386167951,
0.2817356288,
-0.0092714215,
0.3368905485,
0.3594050109,
-0.1530907005,
0.1290907413,
0.0273233522,
0.3048486412,
0.0335328951,
-0.1145823076,
-0.3603203595,
0.1636500061,
-0.3505184054,
0.2438639551,
-0.0057154563,
0.0610197,
0.1514021605,
-0.1962343752,
0.4059722722,
0.3996651471,
0.1287596971,
0.1235579923,
-0.4668513536,
-0.2561834455,
0.0911670998,
0.2694248557,
-0.5443952084,
-0.0205241349,
-0.0250914209,
0.0719308034,
0.190844059,
-0.2245125622,
-0.0070595667,
0.3932718039,
0.4758760929,
-0.2522066534,
-0.0497874953,
0.0791520327,
-0.2843794823,
0.1939014792,
0.0884150639,
-0.1630726159,
-0.0640571862,
-0.2232188731,
-0.1110471934,
0.0332391039,
-0.247841388,
0.0461335331,
0.0455020368,
-0.1986777782,
0.2824603915,
0.1716522127,
0.0209632758,
0.0358564444,
-0.106255047,
-0.0303474125,
-0.6539130807,
0.0898551494,
0.1172934398,
-0.2634696066,
0.2731590867,
0.047046721,
0.1274697632,
-0.2707417011,
-0.3214112222,
0.1371394098,
0.0450290218,
0.3204577565,
0.1354251504,
0.1093331277,
0.117086865,
0.04533365,
0.1104482785,
0.2354529798,
0.1805741936,
-0.0813203678,
-0.4657791555,
0.492369771,
-0.2915325165,
0.338735491,
0.1077596843,
-0.3615035117,
0.1258700937,
0.1946074218,
0.0654672459,
0.0324668847,
0.1312691569,
0.4772085547,
0.212449789,
0.1212139726,
-0.5144756436,
0.3360311091,
0.4645705819,
-0.1469961554,
0.028579656,
0.3510459363,
0.0519953445,
-0.2610155344,
-0.0155808832,
0.1390167177,
0.2602511346,
0.0281642489,
-0.029363405,
-0.1913942844,
-0.0704117641,
-0.218958497,
0.137675181,
-0.2415281534,
0.2456591278,
0.1483845413,
0.4473206103,
-0.0324296877,
-0.2387774587,
0.1767968684,
-0.1974189281,
0.2349344045,
-0.1809415221,
0.2663917243,
-0.3574257195,
0.2530985177,
0.1515167803,
-0.0133973137,
-0.0843177661,
-0.3487617373,
0.0585240647,
0.114543125,
-0.2319316566,
0.0241062231,
-0.0544897914,
0.1498366296,
0.1685013175,
-0.4382392168,
-0.2993869781,
-0.1966489702,
-0.1576527208,
0.0336171873,
0.0358424783,
-0.0238324571,
0.1410058737,
0.0698702186,
-0.1107531115,
-0.0514251068,
-0.3640060425,
-0.1149773151,
-0.2514733076,
0.605520606,
0.1485515684,
0.1012538821,
-0.1017710865,
-0.073297143,
0.2689737082,
0.1816303432,
-0.3637196124,
0.1602525264,
-0.2575188279,
0.1195999682,
0.1660209745,
-0.4174374938,
-0.0465090387,
-0.2057501674,
0.5190742612,
-0.130230099,
-0.0128376856,
0.2838127911,
0.2633405924,
0.0694030672,
0.1586939245,
0.1444575191,
-0.2756017745,
-0.1759730726,
0.5513930321,
0.0617153458,
-0.1343180835,
-0.2934932411,
0.0372429676,
-0.0353238545,
-0.1132428721,
-0.4752553701,
-0.0632550567,
-0.5432240367,
0.1347199678,
-0.2238165885,
0.0941978022,
0.2979946434,
0.0702136904,
-0.1411171854,
0.1116129309,
-0.4074321389,
0.0897669792,
0.3451037109,
-0.0651412904,
-0.2244543135,
0.5375286937,
0.0739891306,
0.5368629098,
0.2415731698,
-0.0202101376,
0.2776856124,
0.1894548833,
0.1000249758,
-0.4498465061,
-0.2339782864,
-0.1182974949,
-0.1132831648,
-0.126129061,
-0.0917292908,
-0.139338553,
-0.2752787173,
0.1804166585,
-0.2230151445,
-0.1689070165,
-0.2300926298,
0.1071814671,
0.1208096594,
-0.0851948336,
0.2056714296,
0.147031635,
-0.0996778533,
-0.0052365744,
-0.0506078564,
-0.0904300362,
0.424446255,
-0.2886025608,
-0.7247642875,
-0.4398970008,
-0.462878406,
0.1117617637,
-0.1098660007,
0.3767344058,
0.1369870156,
-0.3409459591,
0.2547917962,
-0.2076942921,
0.5109802485,
0.0785145089,
-0.0538696684,
0.3577879965,
-0.2409508079,
-0.3276950419,
-0.0019099358,
0.0168687813,
0.4709596634,
0.0974463895,
0.4403004646,
-0.36927858,
-0.1569030881,
0.2743062079,
0.4493204355,
-0.0308285691,
-0.1048479155,
-0.3250127733,
-0.4341772199,
-0.1418239027,
0.2405958176,
-0.3014959097,
0.2199059874,
-0.0754416734,
-0.1604442596,
0.0608916394,
-0.1047325432,
-0.1251955628,
-0.0022671262,
0.2328352928,
0.0439471155,
0.5978381038,
-0.0879929364,
-0.0381070375,
0.4481482804,
0.6538857818,
0.0402079336,
-0.2432387173,
-0.0122003108,
0.3660717905,
-0.0245312136,
0.3892747462,
-0.0337946005,
0.33837834,
-0.0990147591,
0.1327370405,
-0.208353892,
-0.4160834849,
0.2067725807,
-0.0834385976,
-0.1987015903,
-0.0998712853,
0.5511418581,
-0.0543843694,
0.0041496539,
0.0257834978,
0.0463438779,
0.0984489992,
0.2499225736,
0.1865967065,
0.9694735408,
0.0116538536,
0.0877142772,
0.1952992827,
-0.2625277042,
0.4039732814,
-0.0698013604,
0.1793280542,
-0.3722851574,
-0.2326888591,
0.4106882513,
-0.1825081259,
-0.1153579131,
0.0871654674,
-0.0265008733,
0.1459196061,
-0.3671039641,
0.0042383871,
-0.1656652093,
0.3238170743,
-0.2722270489,
-0.1781634986,
-0.2659345269,
0.1267761439,
0.055588264,
-0.1337860972,
0.186880365,
-0.2059175968,
-0.4002214372,
-0.0485224947,
-0.0304097869,
0.2776385248,
-0.1420783848,
0.3259583116,
0.2006518692,
-0.5472698212,
0.2419346422,
0.0872791111,
0.0451358743,
0.3483054638,
-0.1347285509,
0.1306552589,
-0.1387288123,
0.4830154479,
0.3010188341,
-0.3559181988,
0.3081849813,
0.1640394032,
-0.0883447677,
-0.1026883051,
-0.0698739663,
-0.2632696033,
0.0394587629,
0.1749055982,
-0.3060218692,
-0.1849121749,
-0.4295331538,
0.0876497403,
0.0599156991,
-0.3817213476,
0.1603058428,
0.154367879,
0.0903148949,
0.3944988251,
-0.2276238203,
-0.2083495408,
-0.0046909256,
0.5529921055,
0.0386601053,
0.0359900855,
0.3539142609,
0.206366092,
-0.2990297377,
-0.1107009575,
0.2992524207,
0.3453059196,
-0.3845846951,
0.3381314278,
-0.2220592946,
0.297220856,
-0.1795100123,
0.1635109484,
-0.2515804172,
-0.1454907805,
-0.0451195873,
0.0037484183,
-0.2041274756,
0.211927101,
0.3582876027,
0.028999906,
0.0022846274,
-0.1402251124,
-0.3295764923,
0.3141362369,
-0.2951627076,
0.1313792616,
-0.2917520404,
0.1631375551,
0.1352870762,
-0.0497013777,
0.2213559598,
-0.1925830394,
0.1715203673,
0.0411070064,
-0.0243280139,
-0.3134888411,
-0.0441733487,
0.0866634995,
-0.1689059883,
-0.2967541814,
0.0621784888,
-0.0093112346,
-0.1334543824,
-0.2093476653,
-0.027939532,
0.0360384025,
-0.0283590145,
-0.2051325142,
0.2094950825,
-0.0612988174,
0.2295354456,
0.0338114277,
-0.2104404718,
0.3240141869,
0.0088046053,
0.1332275569,
-0.0023435652,
-0.1535810977,
-0.4801926613,
-0.0558987893,
-0.0060593039,
0.2735691071,
0.2264426798,
-0.2720620334,
-0.2402171344,
0.1876879632,
0.3303725123,
0.534655571,
-0.0814056918,
-0.0323250592,
-0.2676246762,
0.2031725794,
0.0621823855,
-0.345923245,
0.0718812197,
-0.1199154183,
0.0011614965,
0.0147138862,
0.054013215,
0.516248107,
0.1040138006,
-0.0147714457,
0.2301125675,
0.1111654267,
0.1431910843,
0.2522639334,
0.2328411043,
-0.1442130953,
0.1926731318,
0.049475871,
0.3423020244,
0.0812876895,
0.1582285017,
0.1845052391,
0.3619942665,
0.2237618715,
-0.140362069,
-0.212986961,
0.0025674198,
0.2055181861,
-0.0880569667,
0.0066563361,
0.2798720002,
0.2119061947,
-0.2851940393,
-0.1954561472,
0.0426195264,
0.3779239953,
-0.1439442635,
-0.3291193843,
-0.1696672887,
-0.0180985406,
-0.0677614063,
0.1926562637,
-0.2493192703,
0.0184096433,
-0.1037096828,
-0.0322524607,
0.1335077137,
-0.321069479,
0.0903235152,
-0.111377202,
0.3420434296,
-0.0946093947,
0.1727155447,
0.2196368873,
-0.0700744465,
-0.2211403847,
0.4062993526,
0.4047289789,
0.2171661407,
-0.1357706785,
0.351552695,
0.0403612331,
-0.0484353341,
0.1880151927,
0.2771341801,
-0.1155271605,
-0.0832794234,
0.1602646858,
0.0993525013,
-0.1839939058,
-0.0391797721,
0.0654641539,
0.0426422171,
-0.1968472004,
-0.2011223435,
0.1076932847,
-0.1719428748,
-0.1783086807,
0.0313143544,
-0.1554472595,
0.1225361228,
0.0150547046,
0.0582727343,
0.0667435601,
-0.085273765,
0.1455869526,
-0.0598792247,
0.3799327016,
-0.033348076,
-0.0079547502,
-0.3831625283,
0.0831198469,
-0.1054656878,
-0.222871989,
-0.1098016649,
0.214151755,
0.1143968254,
0.4680354297,
0.0405052193,
0.1523861736,
0.0882648826,
0.288169086,
-0.0386317819,
0.2116204202,
-0.1658527553,
0.0446070954,
-0.1348471791,
-0.2443237156,
-0.2028569877,
-0.2594792843,
0.231102407,
0.1844405234,
0.0317903943,
-0.4674375951,
-0.0122095151,
0.0767920688,
0.6055024862,
0.3804007471,
0.2365678996,
-0.0354954898,
-0.2536361814,
-0.3499912024,
0.1917377561,
-0.1033406407,
-0.0251230206,
0.2128556073,
-0.1328296214,
0.2634763122,
0.1270476282,
-0.1084213778,
-0.2460087091,
0.1050248668,
-0.3867131174,
-0.1510489583,
-0.3149528205,
0.0058063804,
-0.0769919306,
0.2385446876,
0.1369326711,
0.2710863054,
0.1012893245,
0.3847630024,
-0.4037477672,
-0.3382657766,
0.2753573954,
-0.1265708357,
-0.021607399,
0.1888894141,
0.2227277905,
0.1976964772,
0.1042641923,
0.1049030051,
0.0285091531,
0.4026560485,
-0.1105770171,
-0.1592692435,
0.4890053868,
-0.0369634256,
0.0500577465,
-0.1662544757,
0.402836293,
0.0332042202,
0.0011175495,
-0.0762744844,
-0.3011726439
] |
https://github.com/huggingface/datasets/issues/3419 | `.to_json` is extremely slow after `.select` | Posting it in @eladsegal's format:
For `squad`:
Saving examples using current `to_json` in 3.63 secs
Saving examples to `from_select1_fast.json` in 5.00 secs
Saving examples to `from_select2_fast.json` in 2.45 secs
Saving examples to `from_select3_fast.json` in 2.50 secs
For `squad_v2`:
Saving examples using current `to_json` in 5.26 secs
Saving examples to `from_select1_fast.json` in 7.54 secs
Saving examples to `from_select2_fast.json` in 3.80 secs
Saving examples to `from_select3_fast.json` in 3.67 secs | ## Describe the bug
Saving a dataset to JSON with `to_json` is extremely slow after using `.select` on the original dataset.
## Steps to reproduce the bug
```python
from datasets import load_dataset
original = load_dataset("squad", split="train")
original.to_json("from_original.json") # Takes 0 seconds
selected_subset1 = original.select([i for i in range(len(original))])
selected_subset1.to_json("from_select1.json") # Takes 212 seconds
selected_subset2 = original.select([i for i in range(int(len(original) / 2))])
selected_subset2.to_json("from_select2.json") # Takes 90 seconds
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: master (https://github.com/huggingface/datasets/commit/6090f3cfb5c819f441dd4a4bb635e037c875b044)
- Platform: Linux-4.4.0-19041-Microsoft-x86_64-with-glibc2.27
- Python version: 3.9.7
- PyArrow version: 6.0.0
| 67 | `.to_json` is extremely slow after `.select`
## Describe the bug
Saving a dataset to JSON with `to_json` is extremely slow after using `.select` on the original dataset.
## Steps to reproduce the bug
```python
from datasets import load_dataset
original = load_dataset("squad", split="train")
original.to_json("from_original.json") # Takes 0 seconds
selected_subset1 = original.select([i for i in range(len(original))])
selected_subset1.to_json("from_select1.json") # Takes 212 seconds
selected_subset2 = original.select([i for i in range(int(len(original) / 2))])
selected_subset2.to_json("from_select2.json") # Takes 90 seconds
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: master (https://github.com/huggingface/datasets/commit/6090f3cfb5c819f441dd4a4bb635e037c875b044)
- Platform: Linux-4.4.0-19041-Microsoft-x86_64-with-glibc2.27
- Python version: 3.9.7
- PyArrow version: 6.0.0
Posting it in @eladsegal's format:
For `squad`:
Saving examples using current `to_json` in 3.63 secs
Saving examples to `from_select1_fast.json` in 5.00 secs
Saving examples to `from_select2_fast.json` in 2.45 secs
Saving examples to `from_select3_fast.json` in 2.50 secs
For `squad_v2`:
Saving examples using current `to_json` in 5.26 secs
Saving examples to `from_select1_fast.json` in 7.54 secs
Saving examples to `from_select2_fast.json` in 3.80 secs
Saving examples to `from_select3_fast.json` in 3.67 secs | [
-0.3101400733,
0.0925761536,
-0.1085358784,
-0.0349015072,
0.1821510494,
0.138945356,
-0.0513339117,
0.4654997885,
-0.1702192128,
0.0859459564,
0.0617815703,
0.6600276232,
0.0525261126,
0.0195463039,
-0.104922533,
-0.0219948236,
0.0947584137,
-0.0787242055,
0.1732742488,
-0.0824123174,
-0.1327467859,
0.1048038751,
-0.1950713098,
-0.0190456342,
-0.0556677394,
-0.3036055565,
0.2953054607,
0.1781025827,
0.0155087011,
-0.4784874618,
0.1058763564,
-0.1730512381,
-0.0840071067,
0.233890757,
-0.0001066579,
0.0368817225,
0.1929190755,
0.0825724825,
-0.3625862002,
-0.0895358026,
-0.390801847,
-0.2717337608,
0.1206823215,
-0.2843599916,
-0.1011262089,
-0.0439238325,
-0.1937712133,
-0.44816643,
0.3356671333,
0.1652199626,
0.2847043276,
0.4140944183,
-0.2547278106,
-0.2032727301,
0.0044363462,
0.1908103824,
-0.2182024121,
0.4373444021,
0.2347452193,
0.0890786797,
0.1562525183,
0.0430551805,
-0.0626532808,
-0.1150785834,
-0.0051135812,
-0.0379591025,
-0.0684247389,
-0.0497362241,
-0.0214928128,
0.0146028642,
0.4432531297,
-0.2930611074,
-0.3304578364,
-0.240986377,
-0.1328952909,
-0.0335188322,
0.1038657948,
-0.0092891324,
0.000833451,
-0.0807042643,
-0.2420136034,
0.0014888084,
0.0538701527,
-0.0926030427,
0.3070171773,
-0.0701002106,
-0.1199654341,
0.0939500257,
0.281616956,
-0.1315194517,
-0.0952742174,
-0.3491820991,
-0.07102108,
0.0004506561,
-0.54081738,
-0.413600862,
0.0465426855,
-0.4677426517,
-0.1650526971,
0.1790828109,
0.0914599001,
0.0172319524,
0.1170055568,
-0.0221648607,
0.3905233145,
0.1335607022,
0.0104077896,
0.2518073618,
0.2083258629,
0.1959747374,
-0.0584822819,
0.1454658657,
0.1999356747,
-0.2137701511,
0.3569829464,
-0.0210644454,
0.1926974803,
-0.175921306,
-0.5197473168,
0.1698699445,
-0.265492022,
-0.1962192357,
0.00269541,
0.1522909552,
-0.1220098361,
-0.0925733447,
0.002350416,
0.1002736315,
-0.2956945002,
0.089337334,
-0.2441126108,
0.1840564758,
0.0275757425,
0.1023007184,
-0.1210134998,
-0.1915975809,
0.0439513884,
0.208280459,
-0.0890971422,
0.0620741732,
0.2927593589,
-0.1573477685,
-0.0927647948,
0.0887931436,
0.0755940899,
0.2409784198,
-0.0868392736,
-0.4670544267,
-0.3881093264,
0.1809862852,
-0.2469847053,
-0.1912652254,
0.084760204,
0.302446723,
-0.1123494506,
-0.2580760121,
-0.640344739,
0.2589891255,
0.0800572932,
0.0033740757,
0.0467656404,
-0.0327607617,
-0.1095701605,
-0.3089952767,
0.0517950282,
0.3048236668,
-0.4987024963,
0.070978269,
0.2913197875,
-0.0113494014,
0.4098984301,
0.4345087409,
-0.2302617133,
0.1239539087,
0.0286071673,
0.2146447152,
0.2414573878,
-0.0525999442,
-0.3322418332,
0.1941468418,
-0.2921780348,
0.1924487352,
-0.0204160027,
0.1823187172,
0.0735546127,
-0.2719909251,
0.2826761305,
0.5098420382,
0.1336237192,
0.2226109654,
-0.5169451237,
-0.2150833756,
0.038037762,
0.2103844136,
-0.4273743629,
0.026283972,
-0.0402990468,
0.2743598819,
0.2963384092,
-0.1894920915,
-0.0960926563,
0.4337853789,
0.3958443999,
-0.2876400054,
-0.1960322559,
-0.1190552488,
-0.2049243301,
0.1731494665,
0.1013552025,
-0.3316764832,
0.1613969505,
-0.1059204713,
-0.1220135093,
-0.0325637981,
-0.313601613,
0.0467592888,
0.117876403,
0.0696443096,
0.3417294919,
0.1253051162,
0.0698953718,
0.1657478809,
-0.1250647902,
-0.0441773012,
-0.4724467397,
0.2642067969,
-0.0274441279,
-0.367478013,
0.2000818849,
-0.0712565482,
0.1593781114,
-0.2454683632,
-0.3436287344,
0.1945641637,
0.0625226796,
0.2814652324,
0.1846234649,
0.0023091971,
-0.0207045246,
-0.0149886394,
0.142763406,
0.350174129,
0.1804853231,
-0.0246124994,
-0.4810678363,
0.4610843658,
-0.0740684792,
0.1711317301,
0.1724999994,
-0.3167746067,
0.1461387128,
0.1134844273,
0.1797671914,
0.0381490774,
0.0388208963,
0.4783591926,
0.1270121932,
0.0464913845,
-0.5469595194,
0.3104862571,
0.612046361,
-0.1466086954,
0.0353749469,
0.2590621412,
0.0279312953,
-0.2505810261,
-0.1480274349,
0.1169473678,
0.4037784636,
0.0912786126,
0.0221948829,
-0.2011814117,
0.0194042195,
-0.1583773047,
0.1431124359,
-0.133595258,
0.3038613796,
0.0587470494,
0.4947929978,
-0.0163550321,
-0.1629912853,
-0.0288130213,
-0.1577612162,
0.2393367589,
-0.0893450677,
0.2411555052,
-0.2787174582,
0.2055019885,
0.0202223621,
-0.0606370531,
0.0610074289,
-0.3003528714,
-0.0214136578,
0.1191722229,
-0.149989441,
-0.0241659991,
-0.0948152542,
0.0668291003,
0.1080947518,
-0.4636531472,
-0.1929397434,
-0.092496559,
-0.273465544,
0.1294698417,
0.0319549963,
0.066017352,
0.2641525269,
0.1217963323,
-0.2140786797,
-0.0552290678,
-0.2589117289,
-0.164375782,
-0.1386522651,
0.5349966884,
0.007682241,
0.1347983479,
0.0146305524,
-0.2734350562,
0.2179104239,
0.1252841502,
-0.2962166965,
0.0642196685,
-0.2177678496,
-0.0689741224,
0.2944493294,
-0.4831013083,
-0.1660626978,
-0.277182132,
0.4062390924,
0.0270055998,
-0.0422259867,
0.2060841322,
0.1874754578,
0.0468615256,
0.1974520236,
0.1790333241,
-0.2560665309,
-0.240607053,
0.451071173,
0.0564360432,
-0.1551893055,
-0.1753030568,
-0.0248837024,
-0.0524925813,
-0.2502908111,
-0.3361752927,
-0.0892984718,
-0.6219492555,
0.322227478,
-0.114065446,
-0.0353582501,
0.2646642625,
-0.0032365865,
-0.199439019,
0.112230733,
-0.430095464,
-0.0224621575,
0.3420812488,
-0.0131813241,
-0.213052392,
0.3529872,
0.1097689867,
0.4554390311,
0.4090588093,
-0.1087105349,
0.1908507049,
0.1020550653,
-0.0393725187,
-0.4100885093,
-0.3472264409,
0.0379795097,
-0.1312116534,
-0.1069265306,
-0.0547642708,
-0.160293892,
-0.2798634171,
0.1877710521,
-0.1300258785,
-0.1748605371,
-0.1848025769,
-0.0122284489,
0.1084124073,
-0.1109013259,
0.1959534585,
0.1580705792,
-0.1602138281,
0.037174765,
0.0207160059,
0.0967904776,
0.1752509475,
-0.1677855253,
-0.84662956,
-0.1708532274,
-0.2758153379,
0.1545547843,
-0.0644297153,
0.2798472643,
0.0603755899,
-0.2538927495,
0.2077073604,
-0.2147495449,
0.3861208558,
-0.0829894915,
-0.0392570719,
0.3458830714,
-0.1694648862,
-0.3096043468,
-0.0755176693,
0.0041016643,
0.3325093985,
0.4565496147,
0.3145332634,
-0.2081246078,
-0.1740027219,
0.3638343811,
0.4290901721,
-0.0321564376,
-0.0844215974,
-0.2809903622,
-0.3629008234,
-0.1883353889,
0.1245428771,
-0.2560681701,
0.1841619164,
0.0511959232,
-0.2976429462,
0.0371279418,
-0.1178735197,
-0.0656088144,
0.0056782123,
0.2004588395,
-0.0026998061,
0.5787895918,
-0.2049260736,
-0.0314671099,
0.2888971567,
0.5709424019,
0.1542443037,
-0.3821648657,
0.0088416347,
0.2977688909,
0.088318333,
0.3387293518,
-0.0916425958,
0.205030486,
-0.2148359567,
0.1857550442,
-0.0560873486,
-0.2109899819,
0.2637918591,
-0.0272893123,
-0.2365077585,
-0.2855061293,
0.4411311448,
0.0788339749,
0.007382398,
0.0233724508,
-0.2127114683,
0.132724613,
0.2087699324,
0.0757374167,
0.9146389961,
0.0400942825,
0.0622936897,
0.2546975613,
-0.2514058352,
0.3281849027,
-0.0815819278,
0.1235569417,
-0.4180954695,
-0.1737370938,
0.4178937972,
-0.2391075492,
0.0146299005,
0.0160436016,
-0.1340642869,
0.1650845408,
-0.2698446512,
-0.0950573236,
-0.1198154837,
0.3325280547,
-0.1227420419,
-0.1792066693,
-0.2915992439,
0.2153516263,
0.0811182037,
-0.0639131665,
0.2130101472,
-0.1545916498,
-0.3768330812,
-0.0129677262,
-0.1367102414,
0.3906550109,
-0.0444050618,
0.3009700477,
0.1625570208,
-0.4234708846,
0.2521557212,
0.1959448606,
0.1284865439,
0.3391322792,
-0.0534842536,
0.1800593138,
-0.1162450537,
0.4226049185,
0.2669224441,
-0.3514529169,
0.2739735246,
0.0765902102,
-0.1275443286,
0.044001542,
-0.1718744338,
-0.2234281749,
-0.2126681209,
0.180822134,
-0.0717239752,
-0.2756923139,
-0.5213320851,
0.1844198555,
-0.1013246104,
-0.4380697608,
0.2217866331,
0.1204709634,
0.0809665024,
0.4348757565,
-0.2310792059,
-0.2594289482,
-0.0168496706,
0.495518744,
0.1797313839,
0.0167508181,
0.3418840468,
0.05833029,
-0.2940683663,
-0.2150216848,
0.3009852171,
0.2499693334,
-0.2016392946,
0.3238243759,
-0.2438767105,
0.2186043859,
0.002102589,
0.2202425152,
-0.2176704109,
-0.1002188101,
-0.0261914339,
-0.1161290035,
-0.1765572131,
0.0103911161,
0.2585361898,
0.0127139082,
0.089112334,
0.0139830085,
-0.3266410828,
0.3008518815,
-0.3602864146,
0.058359839,
-0.2295833826,
0.1108025163,
-0.025164891,
-0.1165755987,
0.1572754681,
-0.0973094478,
0.2797768116,
0.0318724141,
-0.0289952699,
-0.3645993173,
-0.0364109948,
0.0515028797,
-0.1633483469,
-0.2324095666,
0.0551970899,
-0.0037273658,
-0.1235766336,
-0.2001293004,
0.018362036,
0.0407623835,
-0.030739421,
-0.1260194927,
0.093862243,
-0.1774172187,
0.2055571377,
-0.0413460992,
-0.3030075431,
0.2760178149,
0.03410054,
0.2086857557,
0.010183108,
-0.1272863597,
-0.4688549638,
-0.0576723367,
0.090678744,
0.3995648026,
0.1844229102,
-0.2989636362,
-0.2301455885,
0.1151085049,
0.2033042163,
0.5399263501,
-0.0958286077,
0.0173253492,
-0.3084280193,
0.2632668912,
0.0191242471,
-0.433123529,
0.0610711761,
-0.0792204663,
0.0636836812,
0.0289486032,
-0.0719003603,
0.397823751,
0.114986077,
-0.0239368379,
0.254037708,
0.0507534705,
0.1540922374,
0.2538853288,
0.3189495504,
-0.1823317856,
0.2228188217,
0.1125688329,
0.3414679766,
0.1066435724,
0.1325062215,
0.2869620919,
0.3179703057,
0.1871789098,
-0.1845559776,
-0.1908391416,
0.0260841548,
0.1720948219,
-0.0777153522,
0.0043233521,
0.3552826345,
-0.0519713834,
-0.2506079078,
-0.2268073708,
-0.0318457298,
0.1983353496,
-0.1288746446,
-0.2440379262,
-0.0562285222,
0.0349248163,
-0.0637270212,
0.1971300095,
-0.2385331988,
-0.0513330139,
-0.0208407827,
-0.0589735359,
0.1355529428,
-0.2953751087,
0.1821793616,
-0.0715015382,
0.2438186109,
-0.175379917,
0.175725922,
0.1061898321,
-0.0657938719,
-0.3179671466,
0.2435903847,
0.4281976819,
0.2374992073,
-0.0150605012,
0.2700892687,
-0.0448340736,
-0.1804198325,
0.1796309799,
0.2613207996,
-0.1181903109,
-0.0243415423,
0.2987752557,
0.2251611948,
-0.2207575589,
0.0087343398,
0.1499174833,
-0.0212246012,
-0.2408863306,
0.028683627,
0.051508002,
-0.1649881452,
-0.1302065402,
0.0523709618,
-0.1951951981,
-0.0957127735,
-0.0620737821,
0.078924574,
0.1115149707,
-0.0291391648,
0.1786737591,
-0.1039063036,
0.331930548,
-0.0367782488,
0.0271561127,
-0.35715729,
0.0486234128,
0.0007784345,
-0.1563373953,
-0.106397301,
0.0069808546,
0.0595798828,
0.4983715415,
0.0664851964,
0.2338200659,
0.0766065568,
0.4296497703,
-0.0647355765,
0.2455704212,
-0.3015609682,
0.0628363416,
0.0803223103,
-0.2002560198,
-0.033295773,
-0.384826988,
0.2011087984,
0.0734762922,
0.1383923143,
-0.4315439165,
-0.177120015,
0.250358969,
0.451297909,
0.4131142199,
0.1614387333,
0.0036162008,
-0.2573444545,
-0.2693337202,
0.1759982407,
-0.146816954,
-0.0514100306,
0.2133856565,
-0.0617846623,
0.3748806715,
0.0893228725,
0.168310076,
-0.1699820161,
0.0404123738,
-0.2427811176,
-0.1518685371,
-0.1915846169,
0.0081585702,
0.0306309573,
0.3977572918,
-0.0026164793,
0.2129616588,
0.0588227212,
0.3806843758,
-0.3954162002,
-0.209284395,
0.3522676229,
0.027337864,
-0.1022784486,
0.1018378139,
0.29651618,
0.1349652112,
0.1559075266,
0.2583506405,
0.0207093507,
0.497261703,
-0.1409360766,
-0.1423997134,
0.4585300982,
-0.1121119782,
0.0935087651,
-0.0773820281,
0.320946902,
-0.0407271869,
-0.083638683,
0.0561815575,
-0.2555466294
] |
https://github.com/huggingface/datasets/issues/3416 | disaster_response_messages unavailable | Hi, thanks for reporting! This is a duplicate of https://github.com/huggingface/datasets/issues/3240. We are working on a fix.
| ## Dataset viewer issue for '* disaster_response_messages*'
**Link:** https://huggingface.co/datasets/disaster_response_messages
Dataset unavailable. Link dead: https://datasets.appen.com/appen_datasets/disaster_response_data/disaster_response_messages_training.csv
Am I the one who added this dataset ?No
| 16 | disaster_response_messages unavailable
## Dataset viewer issue for '* disaster_response_messages*'
**Link:** https://huggingface.co/datasets/disaster_response_messages
Dataset unavailable. Link dead: https://datasets.appen.com/appen_datasets/disaster_response_data/disaster_response_messages_training.csv
Am I the one who added this dataset ?No
Hi, thanks for reporting! This is a duplicate of https://github.com/huggingface/datasets/issues/3240. We are working on a fix.
| [
-0.0299732853,
-0.5003219843,
-0.0671462715,
0.319308728,
0.2122155577,
0.2117061615,
0.048752252,
-0.0459239557,
0.0785185397,
0.0380444042,
-0.1369879991,
0.0033189463,
-0.3648077548,
0.0728738829,
0.3103375733,
-0.1563293934,
-0.0478129722,
0.027724579,
-0.1398403943,
0.142219767,
-0.1771475822,
0.2890430689,
-0.0540030971,
-0.0990055501,
-0.2285631597,
0.1154408008,
-0.1777835339,
0.0107454769,
-0.2866510153,
-0.4454723001,
0.2775406539,
-0.0819223672,
-0.0389212668,
0.2899876535,
-0.0001123664,
0.2116797119,
0.289301306,
-0.0423072688,
-0.3996543288,
-0.3504160643,
-0.1997315288,
-0.3478318751,
0.071686849,
0.2090807706,
-0.2646029592,
-0.1738753617,
0.1395047456,
-0.0506786406,
0.3579210043,
0.4835306704,
0.2269795388,
0.3641419113,
0.3899805546,
-0.3576339781,
-0.1157788634,
0.3465769291,
-0.1911728531,
0.4458270967,
0.1102849543,
0.2318106443,
0.1256678402,
0.4026742578,
0.2942790985,
-0.0906161219,
0.2226270884,
-0.0136385988,
-0.0924930498,
-0.2220219672,
0.1054360569,
0.2535860538,
0.5293083787,
0.1891981512,
-0.1826917827,
-0.2561545968,
0.2347147763,
0.0206315219,
0.3474799991,
0.084116824,
-0.0358592123,
0.3678694963,
-0.38107723,
-0.3276612759,
-0.0757542625,
0.0987575278,
-0.0779494271,
-0.2321637869,
-0.3543758392,
-0.0309595354,
0.1163535267,
0.0470854864,
-0.1986654848,
0.2614679933,
-0.0426690206,
0.1606514007,
-0.2143048793,
-0.083221741,
-0.0349649191,
-0.0596210025,
0.040570356,
-0.1706077456,
-0.1644182503,
-0.1278278977,
-0.0758245289,
-0.0180736985,
0.2007798851,
-0.1459625214,
-0.0758736208,
-0.0241292678,
0.227598086,
0.3193719685,
0.1655257493,
-0.0225369781,
-0.0340404846,
-0.0566323586,
-0.3551484942,
-0.2178957611,
0.2647096217,
-0.0856195912,
-0.3815215528,
0.1003754884,
-0.1799609363,
-0.0490683764,
0.1058380306,
0.280829072,
-0.1419561505,
-0.0330449119,
0.2358367145,
0.1186064705,
-0.0580856428,
-0.1859558374,
-0.2163186818,
0.021799285,
-0.240933612,
0.0482627638,
0.1400179565,
-0.1249546632,
0.2232752442,
0.1192906648,
0.0134863053,
-0.0801841393,
-0.2735648453,
0.0867689103,
-0.2249709964,
0.3265425563,
-0.1742539108,
0.2312971205,
0.0811844468,
0.0593385175,
0.1854854077,
-0.1720259041,
-0.2649029493,
-0.4155012369,
-0.3194851577,
0.1969663799,
-0.2242167443,
-0.1385056674,
-0.1974961758,
0.3487136662,
-0.2947645783,
-0.005873323,
0.01252231,
0.2461331636,
-0.0732463971,
-0.1544658542,
0.2622745037,
0.6182905436,
-0.4583748281,
-0.2095783055,
-0.1083631366,
-0.4166223705,
-0.054875344,
0.1128680632,
-0.1665381789,
0.0583278872,
-0.5202239752,
-0.1781946421,
0.1034242585,
0.0787863061,
-0.3780353665,
0.2601464987,
-0.2509763539,
0.0353801697,
0.0130673088,
0.0732859373,
-0.0152493408,
0.0118925581,
0.3443207145,
-0.2326517701,
0.2106124163,
-0.2434651554,
-0.1978898346,
-0.147329554,
-0.0800585747,
0.0401175544,
0.1391500235,
0.1212519258,
0.1472721696,
-0.2042877525,
0.2786703706,
0.1320928633,
0.100772053,
0.3994411528,
0.0888512209,
0.4095032215,
-0.0345554575,
-0.3016708195,
-0.2823215723,
0.0521827266,
0.1295684129,
0.0755663514,
-0.1615124196,
-0.1168439761,
-0.3499845564,
0.0066691991,
-0.2822821736,
-0.2329997569,
0.0990225598,
0.0317101292,
-0.0975137129,
0.3505381346,
-0.2743443549,
0.2439556122,
-0.1475838125,
0.1908285022,
-0.0857724175,
0.245644629,
-0.0328312404,
0.0786671415,
0.1223069578,
0.1445460469,
0.2025672346,
-0.2024889588,
0.0609173514,
0.1910790056,
-0.2864558697,
0.2929495573,
0.1641232967,
-0.1031975597,
0.3953495622,
-0.2833122313,
-0.0221462194,
-0.0058773318,
-0.0091230702,
0.0359129272,
0.0497123413,
0.1098953411,
0.036120344,
-0.0505243316,
0.0481611975,
0.3905571103,
0.2027193308,
0.125509724,
0.0460464358,
-0.2952647507,
0.4156195521,
-0.2552625537,
0.2555010319,
-0.1237107888,
-0.5482591391,
0.1214708686,
0.1556797624,
-0.0122302696,
-0.0797783732,
0.1661076546,
-0.3135469556,
0.1526515782,
0.0863790363,
0.2055061013,
0.4743485153,
0.1211689413,
0.0944972187,
0.1419577897,
0.0833981559,
-0.2654426992,
0.171525836,
0.0955150872,
0.0847581923,
0.1264393479,
0.2306050211,
0.0627995282,
-0.6860172749,
0.1786150634,
-0.0245526172,
0.0704919025,
-0.2868275642,
0.0893320441,
-0.2168476284,
-0.4501327574,
-0.0417791754,
-0.2003386617,
-0.2872134447,
-0.3427045345,
0.1639037579,
-0.0844314769,
0.0105019603,
0.0023933961,
0.0422868207,
0.1444421262,
-0.3048487306,
0.3941400349,
-0.2151819468,
0.2305168658,
-0.1490977257,
0.1350276023,
-0.0951356441,
-0.4219678044,
0.3490424752,
-0.137672767,
0.1671478599,
-0.4405508041,
-0.3121165633,
0.2409566045,
-0.1903217137,
0.2534343004,
0.4084077775,
0.3524567783,
-0.2246049941,
-0.0788918883,
0.2826426625,
-0.3633132279,
-0.2287950069,
-0.2020221353,
-0.0808706358,
0.0999836102,
-0.1418736875,
-0.3560787737,
-0.4679150283,
-0.345631212,
0.3323724568,
-0.1477758735,
-0.1233580634,
0.0576737672,
-0.0590977967,
0.1531910449,
-0.1439458877,
-0.0050235218,
-0.4409777522,
-0.4946694076,
0.2675393224,
-0.3384299874,
-0.3320697248,
0.1973767877,
0.1245294064,
0.1705575734,
-0.0989006236,
-0.6122778058,
-0.2373954207,
-0.0790800974,
-0.160367474,
-0.0285303015,
-0.0322208665,
0.2173507363,
-0.1074165329,
-0.09684816,
-0.0529325977,
-0.0699402168,
-0.1652567387,
-0.0885058045,
0.4766078591,
-0.2985801995,
0.4627816677,
0.2019154876,
0.8320379257,
0.2451502234,
0.015824955,
0.3560371101,
-0.2802174985,
0.6286759377,
0.0547198243,
-0.3551821113,
0.1142253503,
-0.0621099919,
0.2298925817,
0.101549089,
0.2730046213,
-0.0679122061,
-0.2690446079,
-0.202241227,
-0.4514009058,
-0.238278389,
-0.1934167296,
0.1251098663,
0.0964528099,
0.0520363748,
0.0513218977,
-0.0900359601,
-0.2409789413,
0.0538663007,
0.6988704801,
0.2822422981,
-0.0015989289,
-0.3578849137,
-0.1557117552,
-0.5922602415,
0.3120775521,
-0.1604121029,
0.1703573763,
-0.1916025281,
0.1898212284,
0.3943376541,
0.0810412094,
0.9433751106,
-0.1583438814,
-0.2798672616,
-0.1423256397,
0.1439228058,
-0.2383283228,
-0.0281398091,
0.0641766265,
0.3067203462,
0.397190541,
0.3620189726,
-0.1530820727,
-0.1385701895,
0.4187787175,
-0.0834271759,
-0.221888572,
-0.2837504447,
-0.1282038242,
-0.2774505019,
-0.0040671569,
0.049705293,
0.0060247537,
-0.0088810362,
0.1339429915,
-0.1896111518,
0.1145350412,
0.0406299345,
0.1568407267,
-0.0346659347,
0.054237619,
0.3158577383,
0.2387994826,
0.6006684899,
0.4616639614,
0.2996302843,
0.6284939647,
-0.1751900613,
-0.5563633442,
0.0715174749,
-0.0924920142,
0.3685697019,
0.5163508058,
-0.095750235,
0.193685472,
0.3171398044,
0.1644733995,
-0.3873576224,
0.1081914753,
0.5160545111,
-0.125479117,
-0.3126978874,
-0.3931913674,
0.2680355608,
-0.1121615916,
-0.0138364639,
0.1657107323,
0.4393199086,
-0.0476002246,
-0.0687847286,
-0.1346779466,
1.0563040972,
-0.1223880872,
0.1196554303,
0.2423357517,
-0.0346636064,
0.6227456331,
-0.30141747,
0.2656942308,
-0.0244873744,
-0.1965233684,
-0.1681185961,
-0.0794131607,
0.0641225576,
0.0036603247,
0.1993400007,
0.1892087609,
0.0865623876,
0.3442715108,
-0.1491422504,
0.0730435923,
-0.1883208752,
0.0494105704,
-0.4102259576,
0.2136985064,
0.1636135429,
0.4550849795,
-0.1157427728,
-0.2303368598,
0.0697608441,
-0.2781959474,
-0.4174268842,
-0.0701846257,
-0.3258192837,
0.1287648082,
0.3203534782,
-0.1622892916,
0.1732141823,
0.3801642358,
0.2611264884,
0.1038396806,
-0.1981738508,
0.3352108002,
-0.1196519658,
-0.199156478,
-0.3198239505,
0.1312182546,
0.0358729735,
-0.0504692458,
-0.3291896582,
0.2237184495,
-0.0529180989,
-0.1956142336,
-0.3713313937,
0.0265538432,
-0.0971716046,
-0.0966846794,
0.2413942665,
-0.081783317,
0.1622344255,
-0.1776779294,
0.1070362553,
0.1467016786,
0.0277055912,
-0.256131798,
0.0992973,
-0.0834656954,
-0.1374888867,
0.5387447476,
-0.0653945506,
-0.2101655155,
0.3802108765,
0.1646638364,
-0.3185933232,
-0.1975042373,
-0.0294795949,
0.0877005383,
-0.3877339661,
-0.0105575351,
0.2732809782,
0.2496322095,
0.1001150534,
0.2163718939,
0.2317157388,
-0.3672736585,
-0.0887213126,
-0.4418060184,
-0.3105323315,
0.1155424565,
-0.172674939,
0.1507783383,
0.1179631874,
0.0314345323,
0.2331537008,
0.0820100978,
-0.3087185025,
0.1815149933,
-0.157492131,
-0.1365111321,
0.0296388566,
-0.0826936886,
0.5766582489,
-0.1017818674,
0.0956173837,
0.0534434952,
-0.3050125837,
-0.0898217186,
0.0141966157,
0.1343563795,
-0.0970446467,
-0.0470216982,
-0.1236434877,
-0.1100376919,
-0.085474737,
0.2247168869,
0.2189702839,
0.2395720184,
0.1139119938,
-0.2078219652,
-0.2153667212,
-0.1290050298,
0.0373725593,
0.1058733016,
0.2003471553,
0.3517384827,
0.1779122055,
-0.1327842027,
0.0629827827,
-0.0211940128,
-0.0120751653,
0.1173512042,
-0.0254132077,
0.0421596318,
0.2516936064,
-0.2462694645,
-0.0885286704,
0.0481938347,
0.2777385712,
0.2609354556,
-0.1784138083,
0.2773508132,
0.2183600068,
0.1636570245,
-0.334277302,
-0.0028602248,
0.2601799667,
0.2744447887,
0.0330701843,
-0.1342789233,
0.3371148705,
0.0588034205,
0.1684000194,
0.1751248837,
0.325583756,
-0.1117166802,
0.1915370226,
0.0999774858,
-0.0678823888,
0.0206761416,
0.3635621667,
0.1357899308,
0.0558016747,
0.2472460866,
-0.1086397171,
0.0741549283,
-0.2025781423,
0.0979472175,
0.2321940511,
-0.3713745475,
0.2925388813,
0.0591113195,
-0.4024261236,
-0.0129665844,
0.0945118666,
0.637018621,
-0.3128812909,
-0.0104982015,
-0.3558793664,
0.2206938267,
-0.1349609047,
0.0384254567,
0.0554950982,
-0.361332804,
-0.0241710022,
0.0607437342,
0.0855948478,
-0.2850507796,
0.10332039,
-0.0196519904,
0.00163928,
-0.3861846924,
-0.0599460155,
0.1750119776,
0.2274091542,
0.0197187401,
0.1037150398,
0.1402762681,
0.141331926,
0.412881434,
0.3512895107,
0.0877158344,
-0.0510200672,
0.1992815435,
0.0845471919,
-0.0760393217,
-0.1448828727,
-0.07146696,
0.4709362388,
0.2808422446,
-0.0597427711,
0.1771741509,
0.1709278226,
-0.1568690389,
0.3546532989,
-0.1180352941,
0.4067528248,
-0.2529532313,
0.1323337555,
-0.7231724858,
0.0315579548,
-0.2422158718,
-0.1160830483,
-0.4693205655,
0.0236459207,
0.2258924544,
-0.2427818924,
0.1674398333,
-0.183297351,
0.0978380367,
0.0186175536,
0.243170619,
0.5336280465,
0.1583227068,
0.0265596788,
-0.2542762458,
-0.6056882739,
0.1497207433,
0.1303087622,
0.4227597117,
-0.170478031,
-0.0450688116,
0.1260077059,
-0.0273093432,
0.3173584044,
0.1003791243,
-0.1082492769,
-0.0226526745,
-0.1909310371,
-0.0515959598,
0.298676908,
0.1498540193,
0.0058825244,
0.2765489519,
0.1790893823,
-0.1261849105,
-0.0603250712,
-0.1901411116,
0.3190043569,
-0.5038446188,
-0.1955024302,
0.4322884977,
0.1081908196,
0.3612193167,
-0.1224831119,
-0.3528127372,
-0.2646780908,
-0.4349115491,
-0.0074021877,
0.2307374924,
0.1846410334,
0.3867776096,
-0.1913477182,
-0.2921843231,
-0.1612818539,
-0.0695390329,
0.0727862194,
0.0899941772,
-0.3744801879,
0.1204368919,
-0.395631671,
0.0731771216,
0.2846658528,
0.3187443018,
-0.0299131665,
-0.1833424717,
0.0434610918,
-0.1928855777,
0.4616826177,
-0.4601908326,
0.0474827178,
-0.2195049971,
0.097269915,
0.2061898857,
-0.1400899589,
-0.6934698224,
-0.1243432015,
0.4022204578,
-0.0989874974,
0.0514142551,
0.3395835161,
-0.0846089721,
-0.1041096523,
0.0037565143,
0.6139107943,
0.1865467578,
-0.0947699398,
0.3493081629,
-0.1068615317
] |
https://github.com/huggingface/datasets/issues/3415 | Non-deterministic tests: CI tests randomly fail | I think it might come from two different issues:
1. Google Drive is an unreliable host, mainly because of quota limitations
2. the staging environment can sometimes raise some errors
For Google Drive tests we could set up some retries with backup URLs if necessary I guess.
For staging on the other hand, I guess we can investigate what causes this and discuss with the back-end team | ## Describe the bug
Some CI tests fail randomly.
1. In https://github.com/huggingface/datasets/pull/3375/commits/c10275fe36085601cb7bdb9daee9a8f1fc734f48, there were 3 failing tests, only on Linux:
```
=========================== short test summary info ============================
FAILED tests/test_streaming_download_manager.py::test_streaming_dl_manager_get_extraction_protocol[https://drive.google.com/uc?export=download&id=1k92sUfpHxKq8PXWRr7Y5aNHXwOCNUmqh-zip]
FAILED tests/test_streaming_download_manager.py::test_streaming_gg_drive - Fi...
FAILED tests/test_streaming_download_manager.py::test_streaming_gg_drive_zipped
= 3 failed, 3553 passed, 2950 skipped, 2 xfailed, 1 xpassed, 125 warnings in 192.79s (0:03:12) =
```
2. After re-running the CI (without any change in the code) in https://github.com/huggingface/datasets/pull/3375/commits/57bfe1f342cd3c59d2510b992d5f06a0761eb147, there was only 1 failing test (one on Linux and a different one on Windows):
- On Linux:
```
=========================== short test summary info ============================
FAILED tests/test_streaming_download_manager.py::test_streaming_gg_drive_zipped
= 1 failed, 3555 passed, 2950 skipped, 2 xfailed, 1 xpassed, 125 warnings in 199.76s (0:03:19) =
```
- On Windows:
```
=========================== short test summary info ===========================
FAILED tests/test_load.py::test_load_dataset_builder_for_community_dataset_without_script
= 1 failed, 3551 passed, 2954 skipped, 2 xfailed, 1 xpassed, 121 warnings in 478.58s (0:07:58) =
```
The test `tests/test_streaming_download_manager.py::test_streaming_gg_drive_zipped` passes locally.
3. After re-running again the CI (without any change in the code) in https://github.com/huggingface/datasets/pull/3375/commits/39f32f2119cf91b86867216bb5c356c586503c6a, ALL the tests passed.
| 67 | Non-deterministic tests: CI tests randomly fail
## Describe the bug
Some CI tests fail randomly.
1. In https://github.com/huggingface/datasets/pull/3375/commits/c10275fe36085601cb7bdb9daee9a8f1fc734f48, there were 3 failing tests, only on Linux:
```
=========================== short test summary info ============================
FAILED tests/test_streaming_download_manager.py::test_streaming_dl_manager_get_extraction_protocol[https://drive.google.com/uc?export=download&id=1k92sUfpHxKq8PXWRr7Y5aNHXwOCNUmqh-zip]
FAILED tests/test_streaming_download_manager.py::test_streaming_gg_drive - Fi...
FAILED tests/test_streaming_download_manager.py::test_streaming_gg_drive_zipped
= 3 failed, 3553 passed, 2950 skipped, 2 xfailed, 1 xpassed, 125 warnings in 192.79s (0:03:12) =
```
2. After re-running the CI (without any change in the code) in https://github.com/huggingface/datasets/pull/3375/commits/57bfe1f342cd3c59d2510b992d5f06a0761eb147, there was only 1 failing test (one on Linux and a different one on Windows):
- On Linux:
```
=========================== short test summary info ============================
FAILED tests/test_streaming_download_manager.py::test_streaming_gg_drive_zipped
= 1 failed, 3555 passed, 2950 skipped, 2 xfailed, 1 xpassed, 125 warnings in 199.76s (0:03:19) =
```
- On Windows:
```
=========================== short test summary info ===========================
FAILED tests/test_load.py::test_load_dataset_builder_for_community_dataset_without_script
= 1 failed, 3551 passed, 2954 skipped, 2 xfailed, 1 xpassed, 121 warnings in 478.58s (0:07:58) =
```
The test `tests/test_streaming_download_manager.py::test_streaming_gg_drive_zipped` passes locally.
3. After re-running again the CI (without any change in the code) in https://github.com/huggingface/datasets/pull/3375/commits/39f32f2119cf91b86867216bb5c356c586503c6a, ALL the tests passed.
I think it might come from two different issues:
1. Google Drive is an unreliable host, mainly because of quota limitations
2. the staging environment can sometimes raise some errors
For Google Drive tests we could set up some retries with backup URLs if necessary I guess.
For staging on the other hand, I guess we can investigate what causes this and discuss with the back-end team | [
-0.1584395617,
-0.123356171,
-0.0278884545,
-0.0405436046,
0.2528170943,
-0.0344202034,
0.4490726888,
-0.1110161319,
0.0352990367,
0.5563315749,
0.1367921531,
0.0470314212,
-0.1694109738,
0.3488437533,
-0.0115375202,
-0.1670829505,
-0.2844315469,
-0.0986223891,
0.0157413092,
-0.0264725704,
-0.0534114242,
0.1345864832,
-0.2403456271,
-0.3323856294,
0.0252238847,
-0.1578456014,
-0.2633087635,
-0.0685590878,
-0.0940915421,
-0.372107476,
0.4001351297,
0.342766583,
-0.2628677785,
0.7087798119,
-0.0001192123,
-0.1591798216,
0.4356229603,
-0.1527634561,
-0.1010475606,
-0.2974422872,
0.1914633811,
0.2016117126,
-0.1533659995,
-0.2068966627,
-0.1568004936,
0.2985481322,
-0.0835216641,
-0.2809940875,
0.1198896021,
0.1992579103,
0.1486249715,
0.4929971695,
-0.4142318964,
-0.1699517965,
0.050908979,
0.2534661293,
-0.1733138561,
0.3419323266,
0.149819836,
0.2554728389,
-0.0387972444,
0.0474191271,
0.0358263217,
0.1841864437,
-0.0305353589,
-0.0844372213,
-0.2416034043,
-0.455509901,
0.1352170259,
0.2294065058,
0.0976049379,
-0.1766558886,
-0.1673673987,
-0.0347654708,
0.1170378104,
-0.3082687259,
0.191668123,
-0.0391268022,
-0.1472714096,
-0.0654699653,
-0.3947058916,
0.4699509442,
-0.1504683346,
0.0082304608,
-0.01761939,
0.1886733025,
0.0524139442,
0.0964299813,
0.2915994227,
0.0799585953,
-0.0424216092,
-0.3023266494,
-0.234918192,
-0.0944765285,
0.0862569213,
-0.3623919487,
-0.0412172973,
0.5765958428,
0.1067308113,
0.4613695741,
0.1466837972,
-0.1120740399,
0.1629806906,
0.0590546653,
-0.1269947886,
0.1395356506,
-0.0432041399,
0.1028598994,
0.3042004108,
0.3659866154,
-0.0610387288,
0.1333920658,
0.4554927051,
-0.26392591,
0.0973638073,
0.2916738987,
0.2527300715,
-0.2166422606,
-0.3384090066,
-0.0365924537,
-0.3331637979,
0.0676799193,
-0.110439159,
0.2595481277,
0.0328802019,
0.0985103026,
-0.2619539797,
0.1802675724,
0.0443108603,
0.0336614288,
-0.1336968988,
-0.0249864347,
-0.0045263306,
-0.0020630106,
0.2927274108,
-0.1261929721,
0.2242947817,
0.0995890796,
0.0666290894,
-0.3294422925,
0.1216868386,
-0.1734164208,
0.0483717062,
0.3660185635,
-0.0914308056,
0.073476471,
0.1213148311,
-0.1162152514,
-0.0916137248,
-0.0694773942,
0.1934849322,
0.0635752156,
0.5615616441,
0.1632625759,
-0.2832756937,
-0.1029362082,
0.0131558646,
-0.0513606779,
-0.2458222061,
-0.0267693195,
0.2674296796,
-0.2354945242,
-0.029117832,
0.01857749,
-0.0795359537,
0.5924094319,
0.3265112638,
-0.070866771,
0.0664168149,
-0.1047076732,
0.3171299398,
0.3142122328,
0.1723342389,
-0.1468568146,
-0.1391213238,
-0.0309168361,
-0.0523871556,
-0.4117188156,
-0.0757346302,
0.3580826521,
-0.0364206992,
0.3837195039,
0.0967631564,
-0.0961735249,
0.2245467156,
-0.0156498253,
-0.21217677,
0.0387496948,
-0.2552569807,
0.0250379201,
-0.2622945309,
-0.3184918165,
-0.0813369825,
-0.0942532867,
0.3041538894,
0.0119067198,
0.2141174525,
-0.3827778995,
0.1368595809,
-0.102648586,
-0.2119324505,
-0.0623617396,
0.6282675266,
-0.2755243778,
-0.0885032564,
0.0665686578,
-0.446326375,
0.2725459635,
-0.0620136894,
0.0889968723,
0.1991229355,
-0.3636194468,
-0.1905400902,
-0.2731691301,
-0.032921534,
-0.2939179242,
0.1187992916,
0.5719898343,
0.1667962372,
0.249621287,
0.3260281086,
-0.0631636158,
-0.1131637022,
0.0815077275,
0.0151156364,
0.1622915715,
-0.1255824268,
-0.3001067042,
-0.0964080095,
-0.1444869787,
0.1636483669,
-0.3503305018,
-0.2464181334,
0.3278498352,
-0.0296472609,
0.5238104463,
0.1476320922,
0.0397874042,
0.1828836501,
-0.2157431245,
-0.0950532034,
0.7010551691,
0.0416303389,
-0.1061384082,
0.0404819325,
0.4670199156,
-0.243701607,
-0.0803876519,
-0.0133441361,
0.1207693517,
0.3349416256,
-0.1131240502,
-0.2643941045,
0.0620347932,
0.4858631194,
-0.0029543003,
0.2118250132,
0.2234294266,
-0.4642683268,
-0.0701072738,
-0.0738679469,
-0.1045490578,
-0.209819898,
-0.0889132842,
0.156624034,
0.1771921217,
0.0778748691,
0.6702336073,
0.5462759137,
0.0811168328,
0.0801187679,
0.1124854311,
-0.1464958936,
-0.4210724235,
0.236305654,
0.015612429,
-0.2836622298,
0.4790423512,
0.1849152446,
0.2209292501,
-0.4821680188,
-0.3108732402,
0.150961861,
-0.0020984653,
-0.2584795058,
0.2491679639,
0.0350429676,
0.084318772,
-0.2106898129,
-0.0422064587,
-0.0201979261,
-0.1885301024,
-0.0635784715,
0.4104856849,
-0.3588700593,
0.1744116992,
-0.1258360445,
0.5557636023,
-0.0271779951,
-0.0698320121,
-0.3776938319,
0.1110448763,
0.0283074342,
0.0484326258,
0.3107317686,
-0.0838537887,
0.5202901363,
-0.4952478707,
-0.1437168121,
-0.2215084881,
-0.3089440763,
0.0675256401,
-0.1325113326,
0.6462064981,
0.0630222932,
-0.0303214379,
-0.1087514013,
-0.1902676076,
0.1578844041,
-0.3307380974,
-0.1383396089,
0.0810769871,
-0.0097436812,
-0.0411587767,
-0.3517848849,
-0.3140845299,
-0.1707706898,
-0.1763540953,
0.264634788,
0.0937239304,
-0.1990231276,
0.6221570969,
-0.1224597543,
-0.1531775594,
-0.0743072405,
-0.0683123246,
-0.1461931318,
-0.3007049561,
0.1221069396,
-0.0980583355,
-0.1428864002,
-0.1400244236,
0.0225559082,
0.0336668789,
0.2467299849,
-0.526725173,
-0.1477131099,
-0.0983012244,
0.1310350746,
0.1217496246,
-0.3485831022,
0.16228652,
-0.11976818,
-0.0302963126,
0.0352032259,
0.0754892081,
0.1717660129,
0.2489017993,
0.2269748151,
0.0880178064,
0.2765525579,
0.0793119073,
0.3892844319,
0.417042315,
-0.2069653422,
0.2009348869,
0.0273075327,
0.5469061732,
-0.110696502,
-0.1309106499,
0.3490974903,
0.174882248,
-0.2837817371,
0.12204431,
-0.3047086,
0.0489210896,
-0.0090822354,
0.1781499833,
0.1083436683,
-0.1793466955,
0.105982922,
-0.4477177262,
-0.0260778833,
0.0663230196,
0.3212476671,
0.054637365,
-0.1499160528,
0.0749241486,
0.5134772658,
0.1142545119,
-0.0509742498,
-0.1564961821,
0.0516006462,
-0.4614519179,
0.112042211,
0.0080394419,
0.369531095,
-0.2504901886,
0.0650192648,
0.2151790708,
-0.0360662751,
-0.1668017805,
-0.3277859092,
0.0117124347,
0.236402154,
-0.3763119578,
0.1553139538,
-0.2941155434,
-0.5910898447,
-0.304800272,
0.3173708916,
0.2712174952,
-0.1566048265,
0.0451749861,
0.2464778274,
0.0891364366,
-0.0402866676,
-0.1271060258,
-0.1259085536,
-0.4609696269,
-0.1598163545,
0.3577891588,
0.0910853595,
-0.2339383215,
-0.7440857291,
-0.2353760451,
0.0429577231,
-0.0160607118,
0.1827069372,
0.0041063647,
0.0099349124,
-0.0325722545,
0.1850740016,
-0.0008441467,
0.1575780362,
0.2197599709,
0.0548319258,
-0.0559511781,
0.1404280066,
0.065009065,
-0.2356113642,
-0.1624946594,
0.5088316202,
0.0164980162,
0.1345415562,
-0.0307082869,
0.322556138,
-0.2972334921,
0.0674000233,
0.4512583315,
0.017347753,
0.1068666279,
0.080504559,
-0.0702484548,
-0.1582077146,
-0.2896761894,
0.4638626873,
-0.2551747262,
-0.2239242047,
0.2600135207,
-0.0930240527,
0.7344825864,
0.1592722833,
0.0471161827,
0.1720779985,
0.0051895734,
0.0231047813,
0.5861778259,
0.1256856173,
-0.318472147,
-0.1932413876,
-0.0476785637,
-0.146556437,
0.3317587376,
-0.2081923634,
-0.4739011526,
0.3550080955,
0.1722665131,
0.4828886092,
0.0007396521,
-0.2759346068,
-0.6961134672,
0.0934839249,
0.1535385549,
0.0846424773,
0.162310183,
0.6574285626,
-0.2006084919,
-0.0360589698,
-0.0874371678,
-0.336583972,
-0.3304461837,
-0.1012171134,
-0.6336809993,
-0.0540466271,
-0.0914088711,
-0.4534758031,
-0.2317239195,
0.1597068608,
0.3198165298,
0.326192677,
-0.1629432142,
0.1510468721,
-0.0111772213,
0.2849167883,
0.2341392636,
-0.3475024104,
0.2383362502,
-0.0289575402,
-0.4136448801,
-0.0747613385,
-0.34520033,
-0.2415116876,
0.0485577583,
-0.2117231637,
-0.2484905422,
0.0203092881,
-0.0807389766,
-0.2776924372,
-0.3677467406,
-0.330773294,
0.0756351277,
-0.1545258015,
0.0665193126,
0.4554115534,
-0.1203616709,
-0.3577272892,
-0.3036146462,
-0.0297588613,
-0.2041576803,
-0.0318459421,
0.1530661881,
-0.3300574422,
-0.1419562399,
-0.3284139037,
0.1592991352,
-0.2304731607,
-0.2533914447,
0.1956678331,
-0.3475702703,
0.0324554406,
0.0834554732,
0.3512029946,
0.3434613049,
0.3780668378,
-0.1927839965,
-0.2281246185,
-0.0992118567,
0.0671726614,
0.1792555153,
0.5497723222,
-0.1654482484,
0.4358356893,
0.1291728318,
-0.0085222814,
-0.2867996097,
0.2855423093,
-0.2446002811,
0.061655622,
-0.0031883286,
-0.0859358162,
0.184714064,
0.0525419079,
0.0794473439,
0.1163922474,
-0.1377946734,
-0.1435252577,
-0.074246563,
0.1081300899,
0.0343278609,
-0.0429498404,
0.0944051817,
0.0591017976,
-0.0077108718,
-0.1156552806,
0.1362018883,
0.0797098279,
0.0954575986,
-0.3906946778,
0.0035472088,
0.4353245795,
-0.1152378991,
0.2383623123,
-0.4316903353,
0.2120059133,
-0.1116380543,
0.0002229489,
-0.2085121572,
-0.0803126022,
-0.1351273358,
-0.0443737805,
0.1168244928,
0.2063105404,
0.1803691238,
-0.0215596706,
-0.1007933021,
0.1158720702,
0.3082658052,
0.4069616795,
-0.2660813034,
-0.0626730248,
0.1664973348,
0.2146752179,
-0.0183684807,
0.2153735161,
-0.0984015465,
0.2777822018,
0.2665574849,
0.2633541524,
0.3323574662,
-0.4998087883,
-0.0471488871,
0.064131543,
0.378523916,
0.1259082705,
0.222409904,
0.1285208464,
0.1450673044,
0.2772004306,
0.0058743106,
-0.2880299389,
0.2129769474,
-0.319370687,
-0.1620084494,
0.4119372368,
-0.3900876641,
0.0290400311,
0.011063966,
-0.2369998246,
-0.0302229915,
0.0854857191,
-0.2216182351,
0.2128421962,
0.3654860556,
0.3604508042,
-0.737244606,
-0.3024216294,
-0.5719340444,
0.006981947,
0.0145659782,
-0.1103942171,
-0.2491986305,
-0.0702068135,
-0.2819883823,
0.1374423057,
0.1775873899,
0.5175742507,
0.4038144052,
0.2112770379,
-0.2072716653,
-0.3482258022,
-0.2822452486,
-0.0990006849,
0.2342342585,
-0.3652038276,
0.3807770908,
0.3738604486,
-0.1224912256,
-0.1004239768,
0.4690851569,
0.4191031158,
-0.1206373498,
0.0121795684,
0.0398573168,
-0.1591128856,
0.1402921528,
0.1399682462,
0.1809266955,
0.045116961,
-0.3157316446,
0.2716060579,
0.1617774963,
-0.1687639952,
0.0010122351,
0.134451136,
-0.2562083602,
-0.2425312698,
0.4678912163,
0.0965208486,
0.3590506911,
-0.0828356296,
0.0667212009,
-0.4133861363,
0.2643118501,
-0.1560667455,
-0.2740569711,
0.1162754372,
0.1477308869,
0.0596175045,
-0.0503623299,
0.1439786702,
0.1258916557,
0.0588902272,
-0.1959113926,
-0.2777007818,
-0.4897426367,
0.2637615204,
0.2349911332,
0.4736803174,
-0.256954819,
0.0215834491,
-0.1591444463,
-0.1424008757,
0.218193993,
0.0100281443,
0.3209747374,
0.0644738972,
-0.5378826261,
0.0856668651,
-0.1875005364,
-0.2184111625,
0.0189245902,
-0.2848773599,
0.2419598252,
-0.0082779368,
0.0063502407,
0.2558175921,
0.0329415947,
0.0878377408,
-0.1363096386,
0.1409227401,
0.0990811884,
0.5144605041,
-0.1017423794,
-0.3452961147,
-0.2276848406,
-0.1240349934,
0.2515205145,
0.015090324,
0.0883995369,
0.3843225539,
0.1222196892,
0.0887769237,
0.011427246,
0.3727857471,
0.15262945,
0.032216426,
-0.2319982797,
-0.0096162679,
-0.2288735956,
0.0736630782,
0.1809987277,
0.3491393328,
-0.1129863039,
0.2964577377,
0.010125557,
-0.4852718413,
0.6380035877,
0.0969753265,
0.0685841739,
-0.5617871881,
0.2428139448,
0.0477777719,
0.1465411633,
-0.1957366019,
0.0961098969,
0.00685017,
-0.0590261333,
0.0119978534,
0.1486869156,
0.0915709659,
-0.1305783093,
0.0101407757,
0.3171599805,
-0.0744466707,
0.1519486904,
0.3189456761,
0.0006561336
] |
https://github.com/huggingface/datasets/issues/3400 | Improve Wikipedia loading script | Thanks! See https://public.paws.wmcloud.org/User:Isaac_(WMF)/HuggingFace%20Wikipedia%20Processing.ipynb for more implementation details / some data around the overhead induced by adding the extra preprocessing steps (stripping link prefixes and magic words) | As reported by @geohci, the "wikipedia" processing/loading script could be improved by some additional small suggested processing functions:
- _extract_content(filepath):
- Replace .startswith("#redirect") with more structured approach: if elem.find(f"./{namespace}redirect") is None: continue
- _parse_and_clean_wikicode(raw_content, parser):
- Remove rm_template from cleaning -- this is redundant with .strip_code() from mwparserformhell
- Build a language-specific list of namespace prefixes to filter out per below get_namespace_prefixes
- Optional: strip prefixes like categories -- e.g., Category:Towns in Tianjin becomes Towns in Tianjin
- Optional: strip magic words
| 26 | Improve Wikipedia loading script
As reported by @geohci, the "wikipedia" processing/loading script could be improved by some additional small suggested processing functions:
- _extract_content(filepath):
- Replace .startswith("#redirect") with more structured approach: if elem.find(f"./{namespace}redirect") is None: continue
- _parse_and_clean_wikicode(raw_content, parser):
- Remove rm_template from cleaning -- this is redundant with .strip_code() from mwparserformhell
- Build a language-specific list of namespace prefixes to filter out per below get_namespace_prefixes
- Optional: strip prefixes like categories -- e.g., Category:Towns in Tianjin becomes Towns in Tianjin
- Optional: strip magic words
Thanks! See https://public.paws.wmcloud.org/User:Isaac_(WMF)/HuggingFace%20Wikipedia%20Processing.ipynb for more implementation details / some data around the overhead induced by adding the extra preprocessing steps (stripping link prefixes and magic words) | [
0.1939674467,
0.0157280955,
-0.1693702787,
-0.0298059471,
-0.1310296953,
0.0113722272,
0.1996670663,
0.5238221288,
0.4024954438,
-0.0102350758,
0.0286973957,
0.0813336745,
0.172223419,
-0.0693214908,
0.0228339527,
-0.1620891839,
0.0589284673,
0.075187549,
-0.119600378,
-0.020743927,
-0.4444520175,
0.1861186773,
-0.4511626065,
-0.0859892592,
-0.0912471712,
0.2421659529,
0.1153255105,
0.2092315853,
0.1948693395,
-0.2872225046,
-0.0061053634,
0.3577407598,
-0.0401710309,
0.1109704375,
-0.000100273,
-0.2469588518,
0.5153377056,
0.0351661332,
-0.3312370181,
0.1636209786,
-0.0898449868,
-0.2193903923,
0.1844626814,
-0.4156945944,
-0.0574796125,
0.1117336899,
0.0641758889,
-0.0384055786,
0.2483656257,
-0.1463218778,
0.3120387495,
-0.1311061084,
-0.338806361,
0.0696731284,
0.2988719642,
0.2239452302,
0.0603200868,
0.0594345219,
0.0962080061,
-0.3713485301,
-0.1716212183,
0.5728349686,
-0.4025577903,
-0.2046320587,
0.2831330299,
0.0182250738,
-0.009749868,
-0.3233193755,
0.2650040686,
0.314986378,
0.3173890114,
0.0236400031,
0.0248520002,
-0.1276536882,
-0.0964277014,
-0.1156852245,
0.2442683876,
-0.0068533393,
-0.2562578619,
-0.0331521705,
0.089022994,
-0.0106242783,
-0.1338702738,
0.0926016122,
0.1641380489,
0.5520074964,
0.0779264569,
-0.0354282744,
0.1138817221,
-0.1071101576,
-0.228353098,
-0.119265832,
0.2019227892,
0.2766710222,
0.1578532457,
0.0767139345,
0.112317495,
0.4077829123,
0.1442707628,
-0.1260866225,
-0.2911911905,
0.2781639993,
0.1760200113,
-0.0045608287,
0.0566202886,
-0.1745508313,
0.0607302114,
-0.4144013524,
0.4771040976,
0.3822631836,
-0.1582808942,
0.1549776495,
0.0367838442,
-0.1165254042,
-0.0515708178,
-0.1489294767,
0.0711140186,
0.0160701089,
-0.0365728363,
0.2464365959,
0.1388547271,
-0.1188734844,
-0.2540474832,
0.3988133371,
-0.2095292211,
0.4289596081,
0.3343983889,
-0.0866679102,
-0.3663811088,
0.1412836909,
0.0008141947,
0.1519884318,
-0.2420832962,
0.3433481455,
0.2891668975,
0.3463391364,
0.2299791873,
0.1195135638,
0.0228336565,
-0.2649949491,
-0.1235795319,
0.1033720821,
0.1625002027,
0.1821770817,
0.2008586377,
0.1995914578,
-0.0202677548,
-0.3072806001,
-0.0665583163,
0.0621544123,
-0.1904030442,
0.0098703224,
-0.1434506029,
0.2966479957,
0.1566783041,
0.3270171285,
-0.1444629133,
0.1403223127,
-0.0626058728,
-0.0610844754,
-0.1680756211,
0.2016086429,
-0.1793376356,
-0.1757236272,
0.2882601023,
0.5597962737,
0.0883892924,
0.0583679751,
0.0320228375,
0.3633697629,
0.2103021741,
0.1494204402,
-0.1388690174,
0.3393674195,
-0.1479441226,
0.0950755253,
0.1117617041,
-0.3317250609,
0.1356142461,
0.1435267329,
-0.0265915897,
0.3619920015,
0.0789326727,
0.0482243523,
0.1417694092,
-0.0312791131,
0.1057105511,
0.4501652718,
0.2587346733,
0.3759875596,
-0.4333106279,
-0.0674496815,
0.1218120009,
0.0629832745,
0.0771721527,
-0.1574196965,
-0.247097671,
0.3719612658,
0.499614805,
-0.2192959636,
0.0603059307,
0.0161310155,
-0.2356401384,
0.2280774564,
0.246270135,
0.0390632562,
-0.3629970551,
0.001837393,
0.1100867167,
0.3641886711,
-0.0224607848,
-0.3322692513,
-0.2734651566,
-0.1027374789,
-0.2649636567,
-0.1050421894,
0.3653176725,
0.1083379239,
-0.1081009954,
0.0767302662,
0.0920748562,
-0.1539315581,
-0.0843399093,
-0.0225494672,
-0.2017495781,
-0.0264847949,
-0.2185709476,
0.0780078396,
0.0057835905,
0.195263505,
0.088719137,
0.0484555624,
0.0568521507,
0.0124554317,
0.1700158417,
0.1198599637,
0.221955657,
-0.0985066965,
0.1282910109,
-0.2813479602,
-0.0226590969,
0.3502532244,
0.1358815879,
-0.1962113976,
-0.2686543763,
0.3152806759,
-0.1093214974,
0.3799713254,
-0.0246537812,
-0.1635636836,
0.2754853964,
-0.1843494773,
0.114607431,
-0.2074882537,
0.1068574786,
0.4016970396,
-0.0700615123,
-0.0360370763,
0.1334720403,
0.1356585026,
0.0684076771,
-0.141267091,
0.0886935666,
0.2324619293,
-0.2240821123,
-0.2752402127,
-0.1043944359,
-0.3513843417,
-0.2523003221,
0.2047179341,
-0.020920014,
0.0270534717,
0.0858572721,
-0.2293265909,
0.4935017228,
0.1044581831,
0.1242621914,
0.0732782409,
0.1463689804,
0.0798647404,
-0.2584498227,
-0.1309598386,
-0.380395472,
0.0250890367,
-0.1574727744,
-0.0367810614,
-0.0132051138,
-0.2037908286,
0.0287744608,
-0.0379245691,
-0.2146698982,
-0.39236781,
0.0190132447,
0.3406579792,
-0.2125295252,
-0.0141025214,
0.160033077,
0.1455851346,
0.0288523324,
-0.1303869486,
-0.2512117624,
-0.4596258402,
-0.1194254979,
0.1566367894,
0.2660678327,
0.1523708403,
0.2854031026,
-0.1775172651,
-0.0688068494,
-0.0890135914,
-0.409250319,
0.0873958692,
-0.0440465473,
-0.0718676969,
-0.0676468685,
0.4663812816,
0.0483359359,
-0.3969707191,
0.0335204192,
0.0154992333,
0.1801413447,
0.0213556997,
-0.0510101318,
-0.1333615333,
-0.1260953844,
-0.2026036382,
0.0398698784,
-0.2294676453,
0.044972159,
0.0135231568,
0.2352088094,
0.0966307372,
-0.0794008076,
-0.1473275572,
0.0748508349,
0.139011547,
-0.1198073998,
0.057325799,
0.2472427636,
-0.1321107596,
-0.2194018662,
-0.0100071561,
-0.1814775169,
0.1122779474,
-0.1714846641,
-0.2322448343,
0.0118436348,
0.2596341968,
0.3425202668,
0.2679558992,
-0.0650583729,
0.2999714613,
0.3202683628,
-0.2191019356,
0.0658630282,
0.0279411804,
-0.0477509238,
-0.3199147582,
-0.089419201,
0.2240565419,
-0.0051503587,
-0.1894939393,
0.5411359668,
0.0464812294,
0.2365591824,
0.2495225817,
0.0899611264,
-0.0603344403,
-0.1252016276,
-0.22025235,
-0.1825009733,
-0.1974008381,
-0.0929220021,
0.5239416957,
0.016860377,
-0.4163244367,
-0.2977272868,
-0.0316923,
-0.4262785614,
-0.5380662084,
0.2206466496,
0.3095548153,
0.12675111,
0.025829643,
0.0360506512,
-0.0829229578,
-0.2805317044,
0.3062799275,
0.3108703792,
0.2169535309,
-0.2577949166,
-0.0492842048,
-0.1781126261,
-0.3197226822,
0.1290710121,
0.2821547985,
-0.2474631816,
0.070248358,
-0.2803221047,
-0.0445660278,
-0.0322989821,
0.0916073769,
-0.2783812881,
0.1371693611,
0.1325854212,
0.128878355,
-0.2555559874,
0.0021132543,
-0.1049848646,
0.050227832,
0.3830425441,
0.287781775,
-0.3083184361,
-0.1490744352,
0.2239234895,
0.1955389977,
-0.1283423901,
-0.1758176982,
-0.1578365564,
-0.1932034343,
-0.4658791423,
0.0607990362,
-0.0999962613,
0.0779506713,
-0.2352165431,
-0.0587079711,
0.2724516392,
0.1748198271,
0.1611816734,
0.4964034259,
-0.0207759496,
0.3004980981,
-0.0954910889,
-0.1070536822,
0.0611135997,
-0.257599622,
-0.0300668124,
0.0738920197,
-0.1925343722,
-0.2220406532,
-0.1894481629,
0.1316819936,
0.3167429268,
0.0700948909,
-0.0988179967,
-0.0414119177,
0.0360115394,
-0.3061882257,
0.0620926023,
0.0063655279,
-0.1736820042,
-0.2378956079,
-0.1841260642,
0.5933900476,
-0.1437703818,
-0.2349095941,
0.2360368222,
0.1796830297,
-0.3814424872,
0.3847114146,
0.2383585721,
0.8987543583,
-0.0516586378,
0.1230954081,
0.2782084644,
0.2279372662,
0.2435744107,
-0.1195133701,
0.06854669,
-0.4692506492,
0.4453404248,
0.1492780149,
0.2424791306,
-0.2239142358,
-0.1199849024,
-0.3922636211,
0.1827923357,
-0.0172142088,
0.2226107419,
-0.0363374874,
0.435739249,
0.374486804,
-0.5732722878,
-0.1898366809,
0.2023319304,
-0.0664043948,
0.1826955527,
-0.197014004,
-0.0254257191,
0.0862837061,
0.0411431752,
-0.1733301729,
0.2033070624,
-0.1359961629,
0.0001561592,
-0.4181180596,
-0.0456581712,
-0.0702348724,
0.1971448958,
-0.068431139,
0.4870094061,
-0.2195172161,
0.1123197451,
-0.368702054,
0.015502844,
-0.1551222503,
-0.0183769353,
0.0250758305,
-0.1589437872,
-0.3191048205,
-0.0321831442,
-0.0716284066,
-0.0662624389,
-0.1918482482,
-0.0401997566,
0.2881020904,
-0.0727773011,
-0.2011107504,
0.183367908,
-0.4125090241,
-0.1956158727,
0.2751159966,
-0.281153053,
-0.0390102081,
-0.0009283472,
0.3952525258,
-0.0631781742,
0.0688211545,
0.1825774461,
0.1981413364,
-0.0526883528,
0.233470723,
0.3046669066,
-0.3192503452,
-0.3540278673,
-0.3280749619,
-0.3352369368,
-0.0938061327,
-0.1568705142,
0.193377763,
-0.0341673382,
-0.1086791754,
0.1438262165,
-0.0620257929,
-0.1775814891,
0.1205842346,
-0.16191414,
0.1192665547,
0.1904455125,
-0.0694226548,
-0.1131943092,
0.3257733285,
-0.07985048,
0.0100614103,
0.0878405273,
-0.4427439868,
-0.0684396252,
0.0731197,
0.1845859438,
0.2304848135,
-0.1026549637,
-0.0799461231,
0.0514247939,
0.2578164339,
-0.0021101334,
0.1764903069,
-0.4003841579,
-0.0718802065,
0.0373671986,
-0.0852267519,
-0.1933108568,
0.1080495194,
0.0868063793,
0.2302242815,
-0.406496942,
0.0054344423,
-0.4116820693,
-0.0091069601,
0.1595497876,
0.1464662701,
0.0697177947,
-0.1548727304,
0.2583472133,
-0.2023761272,
0.4401519895,
-0.0778349712,
-0.0764544234,
0.0911537185,
-0.1838290542,
-0.0587136932,
0.2433626801,
0.1264654249,
0.2627511621,
0.2240854204,
0.0987945125,
-0.2382785976,
0.3275716007,
-0.0331818089,
0.2493690699,
-0.0081670545,
-0.1067096889,
-0.0165930241,
0.3434424996,
-0.2702760398,
-0.0168035384,
0.2873019874,
-0.250228107,
0.1097452864,
0.2251852155,
0.1205997691,
-0.3605631292,
0.2464885116,
0.0988024324,
0.1095128655,
-0.2983401716,
-0.0652022287,
-0.1485273689,
0.175424993,
0.0132956132,
-0.1937700361,
-0.0438929312,
0.0206393413,
0.0734528899,
0.0950230733,
0.1919099689,
0.1560133398,
0.3505361676,
-0.2085324526,
0.0076171197,
0.148466453,
0.0697250366,
-0.1528830677,
0.246900022,
0.1856014132,
-0.258862257,
0.184341684,
-0.0372440554,
-0.240500614,
0.3417084217,
-0.1729107946,
-0.2435515076,
-0.0599392951,
-0.1566941291,
0.0595549121,
0.0679076612,
0.1021750197,
-0.1578800976,
0.1125140414,
0.2631389201,
-0.0394779295,
-0.2136985064,
0.2189947963,
-0.1573118567,
0.6545491815,
-0.127270624,
-0.1257637739,
0.192591086,
0.2000543326,
-0.1585046798,
0.0714728087,
0.2550327182,
0.3165016472,
-0.6406174898,
-0.1046991497,
-0.3989849687,
-0.024238525,
-0.1255565882,
0.0276211388,
0.1390301138,
0.0879331976,
0.1100018471,
0.297388345,
-0.2961974144,
-0.2825585902,
0.3328674138,
-0.1512019187,
0.3081097901,
-0.4566503167,
0.2687250376,
-0.1973640621,
-0.3515438437,
0.0844703987,
-0.2862688601,
0.1300309747,
0.2029810399,
0.1234528348,
0.0001134703,
-0.1324562281,
0.1443105638,
0.3218020797,
0.6565509439,
0.0659814477,
0.0047365734,
-0.1961849779,
-0.3693143725,
-0.3484481573,
0.0590785816,
-0.038557101,
-0.1177239418,
0.1309943646,
0.2057029456,
-0.1646439284,
0.2301688045,
-0.223108232,
-0.4212465882,
0.2636464536,
0.1143946499,
-0.251996249,
0.195547998,
0.1043985114,
-0.078876093,
-0.2041994184,
-0.2923618257,
0.2355423421,
-0.0570042506,
0.2492764294,
-0.0491896905,
0.0144193405,
0.1459773183,
0.3641505539,
0.2948463857,
0.0060271546,
0.1349406093,
-0.3772399426,
-0.2502677143,
-0.1802618802,
0.032031998,
0.0852953345,
0.187165305,
0.1036501378,
-0.012466657,
0.278662473,
-0.1666772068,
-0.0980776101,
0.2944087386,
0.0004489372,
0.0508137122,
-0.2840740681,
-0.2956267297,
0.2727311552,
0.3152614534,
-0.3661940992,
0.2305638343,
-0.2311155796,
0.1636923701,
-0.3503836691,
-0.5617601275,
0.285654068,
-0.3255731165,
-0.4806561768,
-0.0253116023,
0.3280142546,
-0.3236450851,
0.2449919581,
-0.2649852037,
-0.0043820334,
0.0613172315,
0.1307905316,
-0.2017226815,
0.268309176,
-0.1109301224,
-0.2373417169,
-0.1446774751,
-0.259483099,
0.1409661472,
-0.2233999223,
-0.4256357849,
-0.3655223548
] |
https://github.com/huggingface/datasets/issues/3398 | Add URL field to Wikimedia dataset instances: wikipedia,... | @geohci, I think the field "url" does not appear in the Wikimedia dumps. Therefore I guess we should generate it, using the "title" field and making some transformation of it (replacing spaces with underscores) and prepending the domain (created using the language)? | As reported by @geohci, in order to host pre-processed data in the Hub, we should add the full URL to data instances (new field "url"), so that we conform to proper attribution from license requirement. See, e.g.: https://fair-trec.github.io/docs/Fair_Ranking_2021_Participant_Instructions.pdf#subsection.3.2
This should be done for all pre-processed datasets under "wikimedia" org in the Hub: https://huggingface.co/wikimedia
| 42 | Add URL field to Wikimedia dataset instances: wikipedia,...
As reported by @geohci, in order to host pre-processed data in the Hub, we should add the full URL to data instances (new field "url"), so that we conform to proper attribution from license requirement. See, e.g.: https://fair-trec.github.io/docs/Fair_Ranking_2021_Participant_Instructions.pdf#subsection.3.2
This should be done for all pre-processed datasets under "wikimedia" org in the Hub: https://huggingface.co/wikimedia
@geohci, I think the field "url" does not appear in the Wikimedia dumps. Therefore I guess we should generate it, using the "title" field and making some transformation of it (replacing spaces with underscores) and prepending the domain (created using the language)? | [
0.1571048498,
0.2313973308,
0.0553592704,
-0.0971824825,
-0.03358436,
0.1205123737,
0.0998200104,
-0.0271696579,
0.1562780887,
0.1611171365,
0.1287598759,
0.3992244303,
0.242775768,
-0.0161260925,
0.1180695519,
-0.0430261418,
0.054670684,
-0.1464303583,
0.07935974,
-0.0267328992,
-0.5429911613,
-0.1044838652,
-0.1917272508,
0.1146844029,
-0.3291086257,
0.0800312608,
-0.1599080265,
0.0441330411,
-0.0529723205,
-0.585472703,
-0.0042660511,
0.2980199456,
0.1002146527,
0.1306039989,
-0.0001132735,
-0.1324888468,
0.7243064046,
-0.0478106402,
-0.3696549833,
-0.0865214542,
-0.3484996259,
0.0716844648,
-0.0329329558,
-0.3411332071,
-0.0347373188,
0.0769963264,
0.2073156983,
0.2120359987,
-0.1239785179,
-0.0874496028,
0.1283513904,
-0.0816620216,
0.0216714535,
-0.1109741554,
-0.0641791001,
0.016417481,
-0.0062293843,
-0.0231006369,
-0.1283850819,
0.0336459354,
-0.0439918675,
0.2164626271,
0.17453219,
-0.1757095158,
-0.0529072657,
0.1840190291,
-0.4282553494,
-0.2101131827,
0.1052666306,
0.2758531272,
0.4850413501,
-0.2248806059,
-0.3822430372,
0.0523296669,
0.3067311645,
0.0171265472,
0.1801777631,
0.2024203837,
0.2740787864,
0.1138714403,
0.0558753088,
-0.2460245937,
-0.3675605357,
0.2832786143,
0.0125483721,
0.7729817033,
0.1766660511,
0.2104033828,
-0.4395720363,
0.0830567107,
0.0963476673,
-0.2671804726,
0.2103014886,
-0.0297334846,
0.2215019763,
-0.2775944471,
-0.0385474935,
0.3087939322,
0.0627629682,
-0.2031493783,
-0.1683695018,
-0.0974444896,
-0.0315197743,
0.1059766039,
0.0595842153,
-0.3651389778,
0.0287308842,
0.1623826027,
0.4684324861,
0.0194595698,
0.0763422251,
-0.1140981764,
-0.1072529778,
0.2345823646,
-0.4018835723,
0.0570341721,
0.0196056273,
0.0645907521,
-0.0794446841,
0.137612924,
0.2561465204,
0.0578245707,
0.0104997596,
0.2400202155,
-0.1860044897,
0.0375083014,
-0.1100722477,
0.1483375877,
-0.0181227494,
-0.0486923791,
-0.1246274337,
0.2159366012,
0.2020654082,
0.4192015231,
0.1302261949,
0.0430967808,
0.5221185088,
-0.0742372572,
0.1118368581,
-0.2072152197,
0.0853823349,
0.1027614772,
0.0571580119,
0.2295502424,
0.2783555984,
0.3453047276,
0.0631176084,
-0.1750156283,
-0.0634330213,
0.287302196,
-0.8060637116,
-0.3427832723,
-0.119217284,
0.0656808466,
-0.107265681,
-0.1637141258,
-0.0690815821,
0.1616760492,
0.0532797351,
-0.0507364199,
0.0564290956,
0.2502653003,
-0.3048219681,
-0.1007436737,
0.1588171721,
0.2112125605,
0.0714340881,
0.1531759501,
-0.3376042843,
0.3999429643,
-0.0365651809,
-0.3135677576,
-0.1817651391,
0.5109193325,
0.0769783258,
0.4451573193,
0.0096156215,
-0.5028417706,
0.100263074,
-0.1535635889,
-0.1584357768,
-0.0804939196,
-0.2627419233,
0.0280170236,
0.1922602355,
-0.0362293497,
0.1505688727,
0.3364802897,
-0.0768672004,
0.1025324687,
-0.1525751799,
-0.0875771865,
-0.151656732,
0.2858833969,
0.203577891,
-0.1158209145,
0.1859502941,
0.2688697577,
0.1455790699,
-0.1816477627,
0.0648294538,
0.0687530711,
0.1228665486,
-0.081627734,
0.1301999092,
-0.0538912565,
0.1087941378,
0.0118220085,
-0.0961100012,
0.3593488634,
0.0140494108,
-0.341936022,
-0.3029313684,
0.215712592,
-0.1393557042,
-0.1969229281,
0.1480537057,
-0.0733193457,
-0.2070031613,
0.2494325042,
-0.0883369148,
-0.3459623158,
-0.2277377695,
-0.0458799303,
0.0200500656,
0.1895114928,
-0.0531904623,
0.2605976462,
-0.0001139112,
0.3334258497,
0.3131520748,
0.1439890563,
0.0837199688,
0.380857259,
0.3683312833,
0.4696274102,
0.7099099159,
-0.0142403105,
0.369246304,
-0.1358067393,
-0.1793780029,
0.1773073822,
0.0171841867,
0.1411432177,
-0.064885281,
0.5167849064,
0.027117569,
0.1138551459,
-0.0152508393,
0.1059939042,
0.2887975276,
0.0636156201,
-0.0846143365,
-0.2062883824,
-0.3655454814,
0.424862355,
-0.4011357427,
-0.1193471625,
0.2904349267,
0.1843613684,
0.2467884421,
-0.2662814856,
0.2120949328,
0.2430993021,
-0.2634652257,
-0.2581275702,
0.0794076324,
-0.0077673309,
-0.0398138091,
0.1474407911,
-0.0038375778,
0.0892229006,
-0.1190080792,
-0.1929739416,
0.4178105593,
0.3945692778,
0.0778945088,
0.1824631393,
0.0439282767,
-0.074650906,
-0.1595224291,
-0.214578107,
0.1168200746,
0.1221206188,
-0.2806229293,
-0.2594265938,
-0.073968783,
0.3686001003,
0.1147526801,
-0.1522685736,
-0.2333460897,
-0.4991747737,
0.3300071359,
0.259822011,
-0.3870490789,
0.063819319,
-0.0760410577,
0.4897831082,
0.004336643,
0.0693054721,
-0.140670687,
-0.5611676574,
-0.0849701241,
0.1216319501,
0.0549026057,
-0.0145729631,
0.0793680847,
0.2277263403,
0.3706839085,
-0.2828299999,
-0.4933715165,
-0.0375123695,
-0.0887297764,
0.2672691345,
-0.1062393934,
0.2783952653,
-0.239411667,
-0.3541609347,
0.0598435365,
0.1034302413,
0.208578676,
-0.0580077842,
-0.2077991217,
-0.1127876937,
0.1855125576,
-0.0473043807,
-0.1030105948,
-0.0299225822,
-0.3002202213,
0.0457695238,
0.181119293,
-0.2830668092,
-0.1259367913,
0.0104339588,
0.0368904807,
-0.263610214,
-0.2911464274,
-0.5249610543,
0.6405801177,
-0.6274124384,
-0.4060343504,
-0.0865540579,
-0.2978345156,
0.196901381,
0.0065603312,
-0.1384176761,
-0.4011158049,
0.3541615903,
-0.0716688782,
0.4516209066,
0.131701082,
0.2808435559,
0.1297417432,
-0.1068559065,
-0.0504303537,
0.0331978947,
0.2216804177,
0.6089898944,
0.0844608471,
0.1800934821,
-0.1761054844,
0.0348352194,
0.818659842,
0.15718925,
0.6756407619,
0.2751737833,
-0.0693537593,
-0.0109162619,
0.0215186421,
0.2668713927,
0.0392022394,
0.0589269735,
-0.1293039173,
0.5640243292,
0.2631167471,
-0.0527821109,
-0.0961015821,
-0.1205021515,
-0.5404086113,
-0.3672957122,
-0.1069331318,
0.1105805188,
0.2882355154,
0.1482437998,
-0.1270079166,
-0.4184297919,
-0.3477035165,
0.1899355799,
0.1659334004,
0.0704685748,
-0.201461494,
-0.2715220451,
-0.3834339678,
-0.4058076143,
0.0259660557,
0.210406065,
0.2598375082,
0.0974175781,
-0.0623097606,
0.0586795993,
0.0874451846,
0.2166733593,
-0.7263492942,
-0.0165609829,
-0.4133777022,
-0.0036686857,
-0.1826871634,
0.1710467488,
0.0882241055,
-0.0818929821,
-0.2886697352,
0.2166240811,
-0.272113055,
0.1595932543,
0.1527715772,
-0.2986048162,
-0.3178973198,
-0.1449678838,
-0.1900336593,
-0.5131242275,
-0.2366385311,
-0.0325788371,
0.0767148808,
0.4125594199,
0.0420359857,
0.0324723311,
-0.0443517119,
0.1911201626,
0.0275268108,
0.2228654176,
0.0188121423,
0.2195627987,
-0.1685980558,
0.3688139915,
-0.2433160543,
-0.1833591163,
0.230170399,
0.1098825559,
0.2075345069,
0.0956306681,
-0.2981626391,
0.3045850694,
0.3920588791,
0.0354087278,
0.0949159861,
0.0648183897,
-0.1324636191,
-0.5532919168,
0.0970962197,
-0.182209,
-0.1404328048,
-0.4321406782,
-0.1909466982,
0.5053846836,
-0.1782646775,
-0.1578428745,
0.6414773464,
0.7114952207,
-0.4021991193,
0.5957477093,
0.4631755948,
0.9357773662,
-0.0862678513,
-0.081011489,
0.1589872986,
0.1664650738,
0.4616440237,
-0.3395067155,
0.1791205853,
-0.2647747397,
-0.1054204479,
-0.153101176,
0.0845948011,
0.2797209918,
0.0541453809,
0.177862674,
0.2129308134,
0.4973930717,
0.3539379239,
0.1639743,
0.5899885893,
0.1091918275,
-0.2859500051,
0.2594406903,
0.0813441947,
-0.0305874385,
0.1428026855,
-0.0665461496,
-0.0894145444,
-0.2379824817,
-0.0971050411,
-0.0799111873,
-0.1489806324,
-0.0094084013,
0.1340415478,
-0.2814947367,
-0.0922937691,
-0.1230619922,
0.0335952155,
0.2060987353,
0.1672082543,
-0.4662222862,
0.378323555,
-0.5307953358,
0.0146573018,
0.0181042273,
-0.1363245696,
0.0250240732,
-0.1805870384,
-0.1280192584,
0.0412207581,
0.2666298747,
-0.3963735998,
-0.039220769,
-0.3230724335,
0.178453669,
0.0167939067,
-0.4491926432,
0.05947873,
-0.3773515224,
-0.2045875788,
0.087702848,
-0.2564255893,
-0.0313718915,
0.0065921466,
0.2617521882,
-0.1020319909,
-0.0648622662,
0.1830332577,
-0.0350578129,
0.2562339306,
0.0666972101,
-0.1344561577,
-0.1882985979,
0.0154346321,
0.0858303383,
-0.0457163155,
-0.2619359195,
-0.3094160557,
0.1578380167,
0.0623397827,
-0.4369158447,
-0.0744879171,
-0.0259249154,
0.2407653034,
-0.0397381559,
-0.4657502174,
0.0703846812,
0.2621298134,
-0.0950417221,
-0.0044432264,
-0.0163676925,
0.3038903773,
-0.0337681919,
0.0553172007,
-0.2856351435,
-0.0576566122,
-0.074901402,
0.2351736575,
-0.4766602516,
-0.0040164054,
0.1277240515,
0.0484385155,
0.0683724582,
-0.1406125724,
0.0342015959,
-0.1231119409,
-0.3923849463,
0.131785363,
0.3837364018,
-0.2271332592,
-0.1473481804,
-0.1966173947,
0.0796872154,
-0.1672929674,
-0.1250336766,
-0.1169778258,
-0.2187855989,
0.1820947826,
0.4294373989,
-0.0044478513,
-0.3471519947,
0.0897452608,
0.0600284524,
0.5105929375,
0.0436949395,
0.1724329889,
-0.1332742125,
-0.0034548617,
-0.0410170145,
0.3082301617,
-0.1319540441,
-0.0205801316,
0.3731490374,
0.1658699512,
0.0725501031,
0.3220739961,
0.1548769027,
-0.0434018634,
-0.1450307965,
-0.0288379919,
0.1590011865,
0.1196206361,
-0.1506825238,
0.1269675344,
0.1268859506,
-0.3333476484,
-0.0238826182,
0.1694366038,
0.351346612,
0.0323415659,
-0.4304580688,
0.0163582247,
0.2511725426,
-0.3516045809,
0.1274493784,
-0.057422705,
-0.0071591381,
0.3926854134,
0.0416689105,
0.1278658509,
-0.2044739276,
0.0581802651,
0.356865108,
0.3434561193,
0.4069539011,
0.0867464319,
0.0721382797,
-0.118519254,
0.3855225146,
0.0933214054,
0.1197318211,
-0.0453166552,
0.1271056831,
-0.4937657118,
-0.1264560372,
0.0644262657,
-0.2897922099,
0.1578407884,
0.0716982782,
-0.3310773969,
-0.1320506483,
-0.2311820686,
0.1090311706,
0.0212675594,
0.0693257973,
-0.5290611982,
-0.2259570509,
0.113768287,
0.0678169727,
-0.3914518952,
0.1999250799,
0.1695226282,
0.4718342125,
-0.1747952104,
0.014828234,
-0.0021800478,
0.0839592591,
0.1158063784,
0.0342842303,
-0.0375845879,
-0.0145864477,
-0.3996352851,
0.1207210124,
-0.0621919744,
-0.0695946515,
0.3447085321,
0.2452352792,
0.2654291689,
-0.1006201729,
0.3037272394,
0.1813045889,
-0.0590755418,
-0.3868129849,
0.4548271596,
-0.0009868378,
0.1636369675,
0.3703192472,
0.3437148929,
-0.1540393531,
0.2937690616,
-0.0103304051,
-0.3671334386,
-0.0779353231,
0.1463133097,
-0.3051075637,
0.0430704542,
-0.4431198239,
0.0627120212,
0.1513405889,
0.3051630259,
0.1399098188,
-0.0199385583,
-0.5631325841,
-0.3675636053,
-0.2455187589,
0.0906064957,
0.1005951837,
0.0697741434,
0.3071320653,
0.0128331203,
-0.2641519308,
0.2065819949,
-0.4644635916,
-0.2624206245,
-0.1943844855,
0.2004068941,
0.0914136618,
-0.0060097012,
-0.2864301205,
0.3131757677,
-0.3789751828,
0.1074572727,
0.2105989605,
0.0431931838,
-0.0345808826,
-0.0713337138,
0.0193774905,
0.2045369446,
-0.1479988098,
0.0550028421,
-0.1412007958,
-0.008834444,
-0.3092077672,
0.1963565946,
-0.0633320436,
-0.1040325314,
-0.3209192455,
0.0879872441,
-0.1193337217,
0.0961693674,
0.4164618552,
-0.3851751983,
-0.050267987,
0.1424194127,
-0.3583071828,
0.1259714514,
-0.2530063987,
0.0037487294,
-0.0387982018,
0.0956819877,
0.0652845353,
0.1522701234,
-0.070152238,
0.3735897541,
0.2124963999,
-0.4211577177,
0.3301283717,
-0.4017114639,
-0.1307597756,
0.0740719661,
0.416251123,
-0.1324542761,
0.3414396048,
-0.2097177207,
0.1044938415,
0.3347963095,
0.0714626461,
-0.0783172101,
0.2790919244,
-0.1634249836,
0.0115844412,
-0.2375722826,
0.2085675299,
-0.0779510364,
-0.247964263,
-0.1996239126,
-0.2036695182
] |
https://github.com/huggingface/datasets/issues/3398 | Add URL field to Wikimedia dataset instances: wikipedia,... | Indeed:
> To re-distribute text on Wikipedia in any form, provide credit to the authors either by including a) a [hyperlink](https://en.wikipedia.org/wiki/Hyperlink) (where possible) or [URL](https://en.wikipedia.org/wiki/URL) to the page or pages you are re-using, b) a hyperlink (where possible) or URL to an alternative, stable online copy which is freely accessible, which conforms with the license, and which provides credit to the authors in a manner equivalent to the credit given on this website, or c) a list of all authors. (Any list of authors may be filtered to exclude very small or irrelevant contributions.) This applies to text developed by the Wikipedia community. Text from external sources may attach additional attribution requirements to the work, which should be indicated on an article's face or on its talk page. For example, a page may have a banner or other notation indicating that some or all of its content was originally published somewhere else. Where such notations are visible in the page itself, they should generally be preserved by re-users.
source: https://en.wikipedia.org/wiki/Wikipedia:Copyrights
I guess it's fine to add the URL field - it can be constructed easily from the title page IIRC. | As reported by @geohci, in order to host pre-processed data in the Hub, we should add the full URL to data instances (new field "url"), so that we conform to proper attribution from license requirement. See, e.g.: https://fair-trec.github.io/docs/Fair_Ranking_2021_Participant_Instructions.pdf#subsection.3.2
This should be done for all pre-processed datasets under "wikimedia" org in the Hub: https://huggingface.co/wikimedia
| 190 | Add URL field to Wikimedia dataset instances: wikipedia,...
As reported by @geohci, in order to host pre-processed data in the Hub, we should add the full URL to data instances (new field "url"), so that we conform to proper attribution from license requirement. See, e.g.: https://fair-trec.github.io/docs/Fair_Ranking_2021_Participant_Instructions.pdf#subsection.3.2
This should be done for all pre-processed datasets under "wikimedia" org in the Hub: https://huggingface.co/wikimedia
Indeed:
> To re-distribute text on Wikipedia in any form, provide credit to the authors either by including a) a [hyperlink](https://en.wikipedia.org/wiki/Hyperlink) (where possible) or [URL](https://en.wikipedia.org/wiki/URL) to the page or pages you are re-using, b) a hyperlink (where possible) or URL to an alternative, stable online copy which is freely accessible, which conforms with the license, and which provides credit to the authors in a manner equivalent to the credit given on this website, or c) a list of all authors. (Any list of authors may be filtered to exclude very small or irrelevant contributions.) This applies to text developed by the Wikipedia community. Text from external sources may attach additional attribution requirements to the work, which should be indicated on an article's face or on its talk page. For example, a page may have a banner or other notation indicating that some or all of its content was originally published somewhere else. Where such notations are visible in the page itself, they should generally be preserved by re-users.
source: https://en.wikipedia.org/wiki/Wikipedia:Copyrights
I guess it's fine to add the URL field - it can be constructed easily from the title page IIRC. | [
0.1469034106,
0.1563643664,
0.0456905849,
-0.0973032638,
-0.0687778667,
0.088216275,
0.2351887822,
0.1012056246,
0.2732242048,
0.0965474546,
-0.0006463797,
0.5451566577,
0.3293744922,
-0.0347850844,
0.1449322999,
0.0359689258,
-0.0703827739,
-0.0078177322,
0.090093933,
-0.1189334467,
-0.2662048042,
-0.1626248211,
-0.015534617,
0.1017161757,
-0.3356573582,
0.1159458458,
-0.0399598889,
0.0005200213,
0.157419458,
-0.5787082314,
-0.0819801018,
0.3225383759,
0.1236570179,
-0.0274399836,
-0.0001021357,
-0.0546461903,
0.5468021631,
-0.0475490503,
-0.5382335186,
-0.023330871,
-0.2566258609,
0.0489837043,
0.0568550676,
-0.3973728716,
-0.0301076472,
0.1406403482,
0.1811786294,
0.2460210025,
0.0732584149,
-0.167951867,
0.2535535395,
-0.0784633011,
0.1035992727,
-0.0924303308,
0.1822032034,
0.0754531473,
-0.0247873552,
0.0816058591,
-0.1732114702,
0.2063210905,
-0.0600361489,
0.3942893445,
-0.0004340732,
-0.07010822,
0.1379072219,
0.0638573542,
-0.2373416871,
-0.1481060833,
0.0993545353,
0.3771220744,
0.4801139235,
-0.2192433476,
-0.3594066799,
-0.1700094789,
0.2406636626,
0.1399698257,
0.1156472713,
0.1680255234,
0.2211128026,
0.1134128571,
0.1342476606,
-0.373339653,
-0.3180847764,
0.1852881759,
0.0048250915,
0.5783547759,
0.1496167034,
0.1824679077,
-0.3639402986,
0.1655488461,
0.0077459435,
-0.2296752334,
0.2507576346,
-0.1130985618,
0.3515097201,
-0.2751331329,
-0.0183909945,
0.1524539292,
0.1466955841,
-0.2047618926,
-0.2302436382,
-0.1294032782,
0.0050688353,
0.0897691771,
0.1719194949,
-0.3878020048,
-0.1513748467,
0.1986069977,
0.6666782498,
0.0932133719,
-0.028370142,
-0.1217506379,
0.084926337,
0.266918391,
-0.224701494,
-0.0882997289,
0.0703120828,
0.0077625774,
-0.1085541472,
0.0707328171,
0.2000035495,
0.1023821533,
-0.0299218167,
0.1968512088,
-0.1519150138,
0.0512217581,
-0.0737474263,
0.0330853947,
0.0059438823,
-0.0676985309,
-0.1098105609,
0.1221284792,
0.1795981973,
0.4806160331,
0.1750594079,
-0.0541612804,
0.3845686913,
-0.0772483274,
0.1967744231,
-0.2339739054,
0.0770031735,
0.1059842259,
0.0359315798,
0.2334006727,
0.2348480523,
0.3434662223,
-0.0305456761,
-0.2094241828,
-0.1508959681,
0.2128832042,
-0.6181074977,
-0.2740845084,
-0.067501612,
0.1999602169,
-0.0985727832,
-0.173755914,
0.0588581562,
0.0555682853,
0.0001100598,
-0.1407594681,
0.0249536801,
0.3181324601,
-0.2238852978,
-0.1643949449,
0.1900384575,
0.3026748002,
0.0978506207,
0.1391931325,
-0.2733474672,
0.4062919915,
-0.1357605904,
-0.1495830268,
-0.2442494333,
0.5067583919,
0.0497438572,
0.387142241,
0.1573561877,
-0.42770046,
-0.0964093879,
-0.1044157147,
-0.1221537068,
-0.0234588683,
-0.2543874383,
0.2141284347,
0.2637698948,
-0.1073984727,
-0.0499412157,
0.2635253668,
0.0718704313,
0.2180800885,
-0.2854140401,
-0.1267764568,
-0.0481803007,
0.2987382114,
0.185676679,
-0.0288643688,
0.2431952506,
0.3796702325,
0.1560984999,
-0.2787531614,
0.1477968544,
-0.0194063708,
0.1948800534,
0.0229838956,
0.1043911949,
-0.147399947,
0.1707331091,
0.0292082913,
-0.108810313,
0.3266711235,
0.0639065281,
-0.440258652,
-0.3041575253,
0.0790004581,
-0.1735711545,
-0.2978613377,
0.3113654852,
-0.0526492484,
-0.1099533066,
0.24457331,
0.0824496299,
-0.2290256917,
-0.2422150224,
-0.1462170184,
0.1103816703,
0.2601083517,
-0.1399695724,
0.2263805121,
-0.0266408864,
0.3510400951,
0.1955288947,
0.2239444852,
0.1063671857,
0.2827290893,
0.1464264542,
0.3602929711,
0.5668966174,
-0.0803725272,
0.3841743469,
-0.2069437653,
-0.0565252155,
0.1418418884,
0.0722994581,
0.1228998303,
-0.2107607126,
0.4323967099,
-0.0234720632,
-0.00540662,
0.0210637338,
0.1478026956,
0.2514048219,
0.0401969701,
-0.0824949443,
-0.1763095707,
-0.4588902593,
0.4294436574,
-0.4020910263,
-0.0738375112,
0.1629476845,
0.2735232413,
0.2167514861,
0.0060062311,
0.3993229866,
0.1910374612,
-0.3449130058,
-0.1843083352,
0.1536910385,
0.0344008245,
-0.241194278,
0.2756951451,
0.0639946684,
0.0136994198,
-0.1985093057,
-0.2328681946,
0.3469599187,
0.1388813406,
0.0548967905,
0.1657069921,
0.1288608909,
0.0168113168,
-0.1835385263,
-0.0398841985,
0.0279999264,
0.0197532717,
-0.2920460105,
-0.2925819457,
-0.0371976495,
0.1780951768,
0.0230469368,
-0.0646425262,
-0.3090925217,
-0.462801218,
0.3608565629,
0.4439628124,
-0.3925620019,
0.0900408775,
0.0259258635,
0.3952257931,
-0.1167473197,
-0.0227689277,
-0.1975234449,
-0.5979511142,
-0.0163482837,
0.2233111411,
0.1192644909,
0.0379121043,
0.176336512,
0.3054109812,
0.1970911175,
-0.5195221305,
-0.4121032357,
-0.0221710391,
-0.0835980624,
0.1182546094,
-0.120215714,
0.2942832708,
-0.2619208992,
-0.226693958,
0.0871878639,
0.0447884426,
0.1951006353,
-0.0271189567,
-0.0644075274,
-0.0412845798,
0.0593130887,
-0.125822708,
0.0462754332,
-0.1167904958,
-0.1541948169,
0.0671909377,
0.0896052867,
-0.204549104,
-0.0314997397,
-0.052833762,
0.1352985203,
-0.0001871453,
-0.4103954732,
-0.3000585437,
0.6064276099,
-0.5251867771,
-0.4445526302,
-0.0520808809,
-0.0892060697,
0.0576484613,
0.0781400204,
-0.2847551405,
-0.4102747738,
0.3254012167,
0.0466101579,
0.2960564196,
0.1602219194,
0.3260316849,
0.1192244887,
-0.1974094659,
-0.0528341904,
0.0748987496,
0.1374464482,
0.3943043351,
-0.0685468093,
0.0085864356,
-0.2041339874,
0.0334286019,
0.7748714089,
0.2701440156,
0.5633047819,
0.2508841753,
-0.025386123,
0.1676224917,
-0.0936689526,
0.2571889758,
0.0504775047,
-0.0735870674,
-0.067767106,
0.4430109859,
0.1851842701,
-0.1841612756,
-0.1540106088,
-0.1697728783,
-0.4566394091,
-0.4647354186,
-0.1435474604,
0.1372802556,
0.2878472209,
0.1637940407,
-0.0998255089,
-0.2834562957,
-0.3358913958,
0.1877062023,
0.0754028261,
0.1472451538,
-0.1789665818,
-0.1838769317,
-0.3749965727,
-0.2222655714,
-0.0838433653,
0.2253239751,
-0.0245582461,
0.1696321815,
-0.1679864973,
0.05325092,
-0.0545870103,
0.052840855,
-0.6643757224,
0.0224648938,
-0.3550673127,
-0.0135576492,
-0.3319507837,
0.1573789418,
0.033612147,
0.0104120998,
-0.2775826454,
0.057424169,
-0.3950644732,
0.1579325795,
0.2167486101,
-0.2635210454,
-0.2641412914,
-0.0867572725,
-0.2286248207,
-0.376152277,
-0.4935841262,
0.0402512886,
-0.024665501,
0.1973611712,
-0.0157455914,
-0.0007904263,
-0.0890191197,
0.2273095697,
-0.0910485163,
0.3566377461,
0.0648856685,
0.2152753472,
-0.2236543298,
0.3684988916,
-0.1506119817,
-0.1574410945,
0.2500712574,
0.1321139783,
0.2381062508,
-0.108080782,
-0.3447964787,
-0.0221418664,
0.3928615749,
0.1908831149,
-0.0110415136,
0.043561399,
-0.2490576357,
-0.4834917188,
-0.1808334291,
-0.3089252114,
-0.1900218874,
-0.1039456204,
-0.1396086365,
0.4286550879,
-0.1640169919,
-0.2974367738,
0.3609734774,
0.5621209145,
-0.3697960973,
0.3702577353,
0.4870395064,
0.913834393,
-0.0421318449,
0.1037221998,
0.0753808618,
0.0998966768,
0.5308609009,
-0.1974436939,
0.1270969957,
-0.3398028314,
0.0636258051,
-0.0867999122,
0.1754828095,
-0.0065671834,
-0.1259958446,
0.0354766771,
0.066331543,
0.4569782615,
0.3598829806,
0.0038772102,
0.5944643021,
0.0365530215,
-0.3082893193,
0.057927262,
0.175420478,
0.0605975613,
-0.0113740936,
-0.0664559752,
-0.1235308498,
-0.1515166014,
-0.0629151464,
-0.1339090466,
-0.0675885975,
-0.0225926433,
0.1669906229,
-0.300508976,
-0.194373101,
-0.0307350326,
0.0418105535,
0.1874852479,
0.2144018114,
-0.4786580205,
0.1366259307,
-0.5104268789,
0.058294896,
-0.0270593278,
-0.1116472781,
0.1076638252,
-0.1984077394,
-0.239239946,
0.1225858778,
0.2656624913,
-0.4224669039,
-0.0959275812,
-0.2017137259,
0.0485180654,
-0.0745264366,
-0.1106375307,
0.1816289276,
-0.4262420237,
-0.3111447692,
0.2079677433,
-0.2333607078,
0.0341821276,
-0.0828970373,
0.3414910436,
-0.0604785569,
-0.0339681543,
0.2368971556,
0.0426158942,
0.3694775403,
0.0866157189,
-0.2098551542,
-0.2739284039,
-0.1495612115,
-0.0445436314,
-0.3149614632,
-0.3034520149,
-0.2130510956,
0.0005684468,
0.0801442638,
-0.4991174638,
-0.0580237955,
-0.0022148958,
0.2241778076,
-0.0956782326,
-0.2590576708,
0.0716620684,
0.2731951773,
-0.0165622104,
0.1281728745,
0.038840197,
0.2390838116,
-0.0307101216,
0.0894199833,
-0.4317534268,
-0.0993944481,
-0.0414525121,
0.1683292389,
-0.3024943769,
-0.0556594469,
0.0105785355,
-0.0347977094,
0.1202668399,
-0.021993177,
0.0168568268,
-0.276176542,
-0.1949330419,
0.0813060924,
0.3258542717,
-0.2434283048,
-0.3701075912,
-0.2095762491,
0.1802506596,
-0.1625819802,
0.1085808277,
-0.1152557507,
-0.1989911497,
0.2232440561,
0.323212564,
0.0679092184,
-0.3005160391,
0.0350152105,
-0.0000783442,
0.435756743,
0.0190685894,
0.2086363435,
-0.0983602703,
0.0265955757,
-0.0554665327,
0.3459659219,
0.0250042435,
0.0892526954,
0.3422194719,
0.1529926509,
0.0117408354,
0.3871974349,
0.1768146306,
0.0449112244,
-0.1342850775,
-0.1428019404,
0.1522002816,
0.2885763943,
-0.2086292356,
0.0665217936,
0.2080793083,
-0.4001155794,
0.1041706651,
0.1889126897,
0.4741079509,
-0.0780073777,
-0.2968240082,
0.0182269085,
0.2012771368,
-0.3409437239,
0.0044878479,
-0.0896984488,
0.0649945885,
0.1840413362,
-0.0751765445,
0.1642713994,
-0.0916077718,
0.0962609276,
0.2435673028,
0.2577209771,
0.3227426112,
-0.0482622832,
0.0999121964,
0.1951341182,
0.4553769529,
0.0744582713,
0.1505146325,
-0.0417666212,
0.099588275,
-0.4914233685,
0.0684939995,
0.0893102959,
-0.2908363938,
0.1289656013,
-0.0382893272,
-0.2271655649,
-0.3588451445,
-0.253813833,
0.1039813533,
-0.0252693165,
-0.0130088395,
-0.3938896358,
-0.0460471101,
0.1006605625,
0.0267771203,
-0.3801474273,
0.4115794599,
0.1608397514,
0.5432011485,
-0.1365998983,
-0.2166039497,
0.0223631524,
0.1102318913,
0.0308686998,
0.2194124013,
-0.0291416887,
-0.0244933274,
-0.3862724006,
0.1320828199,
-0.0966456905,
-0.0305128749,
0.1450460702,
-0.0081455354,
0.1327010542,
-0.1219547316,
0.3833060563,
0.270929724,
-0.1351033598,
-0.2311767191,
0.3404576778,
-0.0732576922,
0.1216082871,
0.0836682469,
0.3711115718,
-0.2749038637,
0.3133668303,
-0.0265421271,
-0.1598141938,
0.0444140136,
0.220649004,
-0.2590772212,
0.0696312115,
-0.4252674282,
0.144479841,
0.2330986857,
0.3673558235,
0.1867161244,
-0.1043867916,
-0.2606536746,
-0.181257084,
-0.2987924516,
0.1478162557,
-0.1248023212,
-0.0504018515,
0.2954321802,
0.1873916239,
-0.1827761829,
0.284004122,
-0.3474811316,
-0.3086631,
-0.2423110008,
0.1311973184,
0.1326836944,
-0.1187644005,
-0.2029798478,
0.0838558748,
-0.2803266048,
0.0925619304,
0.2257020473,
0.0464456081,
0.1186694503,
0.0565750115,
0.0894734785,
0.1446692348,
-0.0575432591,
0.2377275378,
-0.1214552596,
0.0116230221,
-0.3498582244,
0.0888686851,
-0.0250245929,
-0.0998586118,
-0.2354387492,
0.0578139052,
-0.1008334607,
0.0803475901,
0.3175028265,
-0.355450362,
-0.0696253479,
0.2576164007,
-0.132376641,
0.1787078083,
-0.1705941558,
-0.06235772,
0.0374015756,
0.0527986623,
-0.0959786698,
0.2312590033,
-0.1803338975,
0.2687799633,
0.009675689,
-0.4851631224,
0.2078989893,
-0.3379469812,
-0.1008740366,
0.0612260103,
0.3906523287,
-0.0528497845,
0.3145557046,
-0.284483254,
0.1483337283,
0.3090510666,
0.0537665449,
-0.1126113087,
0.1006661057,
-0.0483709164,
-0.0162439253,
-0.2264358103,
0.042246975,
-0.1530459523,
-0.2528942227,
-0.2374760658,
-0.3548929393
] |
https://github.com/huggingface/datasets/issues/3398 | Add URL field to Wikimedia dataset instances: wikipedia,... | yep, sorry forgot that that wasn't already in the dumps. specifically `f"https://{language}.wikipedia.org/wiki/{title.replace(' ', '_')}` should do it | As reported by @geohci, in order to host pre-processed data in the Hub, we should add the full URL to data instances (new field "url"), so that we conform to proper attribution from license requirement. See, e.g.: https://fair-trec.github.io/docs/Fair_Ranking_2021_Participant_Instructions.pdf#subsection.3.2
This should be done for all pre-processed datasets under "wikimedia" org in the Hub: https://huggingface.co/wikimedia
| 17 | Add URL field to Wikimedia dataset instances: wikipedia,...
As reported by @geohci, in order to host pre-processed data in the Hub, we should add the full URL to data instances (new field "url"), so that we conform to proper attribution from license requirement. See, e.g.: https://fair-trec.github.io/docs/Fair_Ranking_2021_Participant_Instructions.pdf#subsection.3.2
This should be done for all pre-processed datasets under "wikimedia" org in the Hub: https://huggingface.co/wikimedia
yep, sorry forgot that that wasn't already in the dumps. specifically `f"https://{language}.wikipedia.org/wiki/{title.replace(' ', '_')}` should do it | [
0.1569753885,
0.1533058435,
-0.0069044665,
-0.1684149206,
0.0327236876,
0.1310461462,
0.0735662058,
0.1554722637,
0.2668457925,
0.151658386,
0.0103205713,
0.550291419,
0.3304097354,
-0.0482819565,
-0.0146247707,
0.0482313037,
0.0911027268,
-0.0532020852,
0.1225777715,
-0.0800342113,
-0.3383880258,
0.039976079,
-0.1739845127,
0.1279703826,
-0.2993780375,
0.0576868728,
-0.0620994419,
0.1107451841,
0.023353355,
-0.5956232548,
-0.059164416,
0.4493721426,
-0.0468071885,
0.1134304106,
-0.0001041698,
-0.0922248214,
0.5972478986,
0.0153599828,
-0.4168346822,
-0.0108973198,
-0.2418026477,
0.0857031345,
-0.0102305245,
-0.2739644051,
-0.1164694428,
-0.0620012134,
0.1152025089,
0.1036485806,
-0.0051352871,
-0.0659433529,
0.2283047736,
-0.0157090183,
-0.0432872064,
-0.2180990577,
0.0814113468,
0.0542512871,
-0.0174057838,
-0.0268792007,
-0.2068990171,
0.0074001891,
-0.0486093089,
0.3843643665,
-0.0591932386,
-0.1436747164,
-0.0722062886,
0.050603807,
-0.3064972758,
-0.2710345685,
0.2315895259,
0.3889622092,
0.391379863,
-0.2141826451,
-0.2705120146,
-0.032047037,
0.1841516495,
0.0692073628,
0.1077937558,
0.1772963554,
0.2137196213,
0.14012371,
0.1176077276,
-0.2778812051,
-0.2628441155,
0.2081464231,
0.0593266711,
0.7477731109,
0.0992078781,
0.1046565175,
-0.3063517213,
0.0013272514,
-0.0065039718,
-0.1551405638,
0.0683439001,
-0.1263582259,
0.1762769222,
-0.2211142033,
-0.0165473297,
0.1898047179,
0.1757508516,
-0.2128414214,
-0.3463746607,
0.1564345062,
0.0020416863,
0.1314544231,
-0.0222511608,
-0.336654067,
0.0733021572,
0.2002920657,
0.5897763371,
0.1161623895,
-0.0649855062,
-0.0680838153,
0.0775443614,
0.2019591033,
-0.4392172992,
0.0609339513,
0.0611130744,
0.0253419597,
-0.1611119509,
0.1997836083,
0.2719553113,
0.025598269,
-0.0776783228,
0.4350873232,
-0.1876140833,
0.0759519488,
-0.0958139896,
0.2157303393,
-0.1640850902,
-0.0480188653,
-0.1787874699,
0.1961252093,
0.157121703,
0.4440363348,
0.1950271279,
0.0986276418,
0.4554647505,
-0.1042502746,
0.2662780881,
-0.290614754,
0.0502858832,
0.0748114064,
0.0504036956,
0.2081162483,
0.3091643155,
0.3266220689,
0.0816687122,
-0.274988234,
-0.0483175963,
0.2294976711,
-0.6770358086,
-0.1071560383,
-0.1320022047,
0.1452891082,
-0.0299424231,
-0.1405933052,
0.0341734439,
0.2131941468,
0.0166887641,
-0.0886399373,
0.019691268,
0.3607057333,
-0.3236532211,
-0.0820653662,
0.1527976841,
0.2311654389,
0.1102724448,
0.066820398,
-0.1086334959,
0.5067186952,
-0.0940242112,
-0.1313899308,
-0.0900819153,
0.3954952359,
0.0751242116,
0.551341176,
0.0588119626,
-0.5358223319,
-0.0112282895,
-0.1759868711,
-0.0632716268,
-0.0336365812,
-0.2080436796,
0.0010070706,
0.2313654572,
-0.0549409725,
0.0194342099,
0.3071813285,
0.0838320181,
0.1989809275,
-0.238289237,
-0.1037983447,
-0.1863386631,
0.262811631,
0.1689277589,
-0.1649743766,
0.0886095539,
0.1892814338,
0.2113836706,
-0.3333987892,
0.0810456425,
0.0015994058,
0.1511648595,
0.0541746058,
0.2056539506,
-0.1873546839,
0.0915032029,
0.0036034228,
-0.0890995786,
0.358943373,
-0.0087105418,
-0.4522179365,
-0.3365607262,
0.1887782514,
-0.223325491,
-0.1485831141,
0.2698013484,
-0.0196333267,
-0.1806795746,
0.3411152959,
-0.0055567781,
-0.2414974123,
-0.1890341938,
-0.0047179768,
0.0684144273,
0.2270138711,
-0.0913909897,
0.1470174938,
-0.0206931997,
0.2524677813,
0.3554238677,
0.1482692063,
0.0750712901,
0.3871060014,
0.3087367713,
0.3763486445,
0.5801573396,
-0.1475730091,
0.3004486263,
-0.2147487104,
-0.1176936403,
0.3358062208,
-0.0011501724,
0.1813631356,
-0.2873901725,
0.5433689952,
0.0684752688,
0.1063631549,
0.0035953966,
0.0970967561,
0.3445986807,
-0.0447311029,
-0.0097644329,
-0.2633307576,
-0.2830391526,
0.4216473103,
-0.4752156138,
-0.2244091928,
0.1995725036,
0.1422832161,
0.3035835624,
-0.0455279313,
0.4068109393,
0.2076283991,
-0.3091472089,
-0.1592332572,
0.1513535529,
-0.1203541458,
-0.2068811953,
0.2328027487,
-0.0513810217,
0.03009554,
-0.0312643573,
-0.2866463661,
0.3756707311,
0.2890819609,
0.0336493589,
0.2156124413,
0.2581697702,
-0.1159078106,
-0.3107542396,
-0.0811902955,
-0.0054293717,
0.059082184,
-0.2748796344,
-0.0983570963,
-0.2297760099,
0.2191713452,
0.1991606653,
-0.1090408638,
-0.2089923769,
-0.4358666539,
0.4411312342,
0.3972391188,
-0.382063359,
0.194353044,
0.0632675663,
0.4297341406,
0.0222195275,
0.1103922129,
-0.1458755583,
-0.5155971646,
-0.0339899361,
0.1834845245,
0.1118652076,
-0.0335785002,
0.0889062732,
0.2371498048,
0.1371298134,
-0.3750263751,
-0.4796653688,
0.0487206951,
-0.101585947,
0.1976363063,
-0.1153529212,
0.2503599226,
-0.2794215679,
-0.2048847228,
0.1470650136,
0.0026647276,
0.1692273319,
-0.0070871366,
-0.1067989692,
-0.036056079,
0.064957656,
-0.12394014,
0.0766571164,
-0.1253017634,
-0.1711119711,
0.0910631865,
0.160718143,
-0.2412041724,
-0.0384524018,
-0.1718397439,
0.0508101471,
-0.1151921898,
-0.377958566,
-0.3547456861,
0.5493462682,
-0.6466534138,
-0.38173154,
-0.0461786203,
-0.1216835007,
0.044535324,
-0.0780425072,
-0.1581059992,
-0.3938277364,
0.2260213792,
-0.0709946901,
0.2668582499,
0.1100559905,
0.2851067781,
0.1146323606,
-0.2410285771,
-0.1836719066,
-0.0135470061,
0.1003211513,
0.3792586625,
-0.1244216859,
0.1099868044,
-0.0746064708,
0.108931303,
0.6937591434,
0.1274296194,
0.6646239758,
0.3323845267,
-0.1110615283,
0.0163902771,
-0.0359288752,
0.2144142836,
-0.0401339233,
-0.0764072612,
0.0072542238,
0.6668745279,
0.2576006353,
-0.1947478503,
-0.1019393727,
-0.1951247752,
-0.4215950966,
-0.3661269248,
-0.1254669875,
0.1198431998,
0.198708564,
0.2163200974,
0.0157332774,
-0.3270581067,
-0.4070630074,
0.2278809547,
0.1359555572,
0.1158372387,
-0.2789106667,
-0.2604994774,
-0.360144794,
-0.2922314107,
0.1577053815,
0.2051457018,
0.1156006753,
0.0540255308,
-0.1034367457,
0.1216159463,
-0.0669742674,
0.2558265328,
-0.6589894295,
0.0035625021,
-0.2761293352,
-0.0150446016,
-0.2765730917,
0.093888782,
-0.0189689118,
0.0452624783,
-0.2642412484,
0.1949836612,
-0.3487500548,
0.0532747172,
0.0961711258,
-0.3618317246,
-0.2328755558,
-0.0979550332,
-0.2759756744,
-0.3721548021,
-0.5010523796,
0.101205267,
0.1236161217,
0.2898882031,
-0.0669288933,
-0.0878737047,
-0.0449805036,
0.1091953814,
0.024457464,
0.3140127659,
0.1345627308,
0.3067271709,
-0.3258069158,
0.2049127072,
-0.1849671304,
-0.2328709364,
0.1830023974,
0.1614166498,
0.1339716762,
-0.035558261,
-0.2773281038,
0.1291068792,
0.4311544001,
0.0864329413,
0.2097147107,
0.0236247387,
-0.0850963742,
-0.4839562178,
0.0880818665,
-0.129796654,
-0.1859393269,
-0.3126010895,
-0.1261209249,
0.533275485,
-0.1906814128,
-0.2634068131,
0.4641995728,
0.6304169297,
-0.4214740992,
0.5294380188,
0.4229243994,
0.8831874132,
-0.000821595,
0.0015833456,
0.0663264766,
0.1575776488,
0.496035099,
-0.4088934064,
0.2586592138,
-0.3137015402,
-0.0828100964,
-0.0904611722,
0.2084909678,
0.0700990409,
-0.0988394693,
-0.0281683784,
0.1607837677,
0.351123929,
0.3594238758,
0.145358026,
0.5320237875,
0.1429584026,
-0.3321807683,
0.0709560886,
0.1814462095,
0.0697101802,
0.0029867613,
-0.0814663693,
-0.1107507348,
-0.1820006669,
-0.1547896564,
-0.1354679316,
-0.0479550697,
0.0018877549,
0.1324031502,
-0.221342966,
-0.1426239461,
-0.0821280554,
-0.0079318769,
0.2765417993,
0.3293480873,
-0.4983344078,
0.3392686546,
-0.414958775,
0.0268003326,
-0.1374626011,
-0.0580623783,
-0.023163477,
-0.242485255,
-0.1692637503,
0.0416342616,
0.3279565871,
-0.4084942341,
-0.1729961038,
-0.2391860932,
0.2309626192,
-0.0299579576,
-0.2621980906,
0.0242754743,
-0.3875465989,
-0.3645226955,
0.1917676777,
-0.3263294697,
-0.0990780294,
-0.0354626738,
0.4321424961,
-0.0986371487,
-0.004157939,
0.271404326,
0.0261014923,
0.2623263299,
0.199529916,
0.0325881913,
-0.3061074317,
-0.1845931858,
-0.1410909295,
-0.1102645621,
-0.188030988,
-0.2008437663,
0.086291559,
-0.0251715798,
-0.3560045063,
0.0172784943,
-0.1311288923,
0.1999822408,
-0.036591582,
-0.3558524847,
0.1483103037,
0.2183294296,
-0.0902496502,
0.0283862613,
0.0947205946,
0.2152367979,
-0.1048431695,
0.1700679958,
-0.4015737474,
-0.0755306482,
-0.0465904027,
0.176291883,
-0.3490023315,
0.0558685288,
0.0500348695,
0.0666162744,
0.1610148847,
0.0313214436,
0.0413919166,
-0.2728201747,
-0.2928770781,
0.0915985852,
0.2525979578,
-0.1068625972,
-0.1912681311,
-0.1091852337,
0.1669671834,
-0.260273993,
0.0575286075,
-0.1439452767,
-0.1923736185,
0.2270905823,
0.3293332756,
0.0388045609,
-0.2002171278,
-0.0712878108,
0.0321332105,
0.2859524488,
-0.0187264215,
0.058471594,
-0.0415600836,
-0.0221566893,
0.0574109703,
0.3228456974,
0.0346983299,
0.0339993797,
0.2998735309,
0.145128563,
0.0544486083,
0.3259415925,
0.2600173652,
-0.005513344,
-0.0739577636,
-0.0984858349,
0.1953163296,
0.2236309201,
-0.176294148,
-0.0779535919,
0.3206540942,
-0.369235307,
0.137870118,
0.2108517736,
0.4134633839,
-0.0454849191,
-0.2595989108,
0.1588253975,
0.177715525,
-0.405363977,
0.157164067,
-0.1518515646,
0.0667119473,
0.2309499085,
-0.0532399379,
-0.0296700411,
-0.1004976332,
0.2952412069,
0.2941018343,
0.3319667876,
0.394502461,
-0.0445353501,
0.0880407467,
0.0648060665,
0.4256893992,
0.0275276732,
0.204987064,
-0.0407717265,
0.1208235472,
-0.3495711684,
0.0937629715,
-0.0254542902,
-0.3205579817,
0.2532355785,
0.0013373498,
-0.2831361294,
-0.2578955591,
-0.2469969392,
0.1369933486,
-0.0338867493,
0.0543517061,
-0.3951614201,
-0.1224424988,
0.0851212889,
0.0504460558,
-0.3234740198,
0.2797148228,
0.0360160917,
0.5314513445,
-0.1633887589,
-0.0580396242,
-0.0083925081,
0.1581303477,
0.0146498308,
0.0280905701,
-0.0051041329,
0.0346681513,
-0.5172097683,
0.0555498041,
-0.2350064516,
-0.1050220951,
0.2654999495,
0.1305444092,
0.2230826467,
-0.1830936074,
0.2156742066,
0.2590250969,
-0.1871554255,
-0.2910637259,
0.4449465871,
-0.0922408327,
0.1529603451,
0.1006594822,
0.3666313589,
-0.1307032257,
0.201271981,
-0.2007121146,
-0.329084605,
-0.0249872226,
0.1934487373,
-0.2971679568,
0.0927908793,
-0.4289367497,
0.1282737851,
0.1804134995,
0.3458841443,
0.0191607978,
-0.1390080899,
-0.3771677613,
-0.3148932159,
-0.1956651807,
0.2124377191,
-0.0413743518,
0.0519855097,
0.2243889123,
0.0509012938,
-0.1904112548,
0.1770929843,
-0.4007709622,
-0.3986266851,
-0.1099264696,
0.2001458257,
-0.0846589506,
0.0941675603,
-0.3145584166,
0.1609871835,
-0.215652287,
0.1020714566,
0.1626161635,
-0.0613220371,
0.0621970482,
0.0614251383,
0.0202652682,
0.0850138813,
-0.1550945789,
0.1863422245,
-0.0928313658,
0.1563725919,
-0.379001528,
0.1958712339,
-0.0890187472,
-0.1869489402,
-0.28798002,
0.1433732957,
-0.0219543055,
0.20655559,
0.302064091,
-0.3749828637,
0.048005186,
0.2534781396,
-0.1018007323,
0.1848817766,
-0.2030689418,
-0.0272200424,
0.0605419911,
0.0776059479,
-0.0985751376,
0.1853791624,
-0.1232302636,
0.2841971219,
-0.013087105,
-0.6380106807,
0.3465019464,
-0.5008826852,
-0.3169571161,
-0.0677024573,
0.3731593192,
-0.0734941214,
0.1871600896,
-0.1778672785,
0.1480980366,
0.2512250841,
0.1465622783,
-0.1328523308,
0.3041383624,
-0.1228259951,
-0.0903603807,
-0.2097326517,
0.091850318,
0.1153582409,
-0.3129682839,
-0.2349761426,
-0.3553527296
] |
https://github.com/huggingface/datasets/issues/3398 | Add URL field to Wikimedia dataset instances: wikipedia,... | Thanks @geohci.
I had already been looking for information about the conversion from title to URL and I found that apart from replacing blanks with underscores, some other special character must also be percent-encoded (e.g. `"` to `%22`): https://meta.wikimedia.org/wiki/Help:URL
Therefore, I have finally used `urllib.parse.quote` function. This additionally percent-encodes non-ASCII characters, but Wikimedia docs say these are equivalent:
> For the other characters either the code or the character can be used in internal and external links, they are equivalent. The system does a conversion when needed.
> [[%C3%80_propos_de_M%C3%A9ta]]
> is rendered as [À_propos_de_Méta](https://meta.wikimedia.org/wiki/%C3%80_propos_de_M%C3%A9ta), almost like [À propos de Méta](https://meta.wikimedia.org/wiki/%C3%80_propos_de_M%C3%A9ta), which leads to this page on Meta with in the address bar the URL
> [http://meta.wikipedia.org/wiki/%C3%80_propos_de_M%C3%A9ta](https://meta.wikipedia.org/wiki/%C3%80_propos_de_M%C3%A9ta)
> while [http://meta.wikipedia.org/wiki/À_propos_de_Méta](https://meta.wikipedia.org/wiki/%C3%80_propos_de_M%C3%A9ta) leads to the same. | As reported by @geohci, in order to host pre-processed data in the Hub, we should add the full URL to data instances (new field "url"), so that we conform to proper attribution from license requirement. See, e.g.: https://fair-trec.github.io/docs/Fair_Ranking_2021_Participant_Instructions.pdf#subsection.3.2
This should be done for all pre-processed datasets under "wikimedia" org in the Hub: https://huggingface.co/wikimedia
| 123 | Add URL field to Wikimedia dataset instances: wikipedia,...
As reported by @geohci, in order to host pre-processed data in the Hub, we should add the full URL to data instances (new field "url"), so that we conform to proper attribution from license requirement. See, e.g.: https://fair-trec.github.io/docs/Fair_Ranking_2021_Participant_Instructions.pdf#subsection.3.2
This should be done for all pre-processed datasets under "wikimedia" org in the Hub: https://huggingface.co/wikimedia
Thanks @geohci.
I had already been looking for information about the conversion from title to URL and I found that apart from replacing blanks with underscores, some other special character must also be percent-encoded (e.g. `"` to `%22`): https://meta.wikimedia.org/wiki/Help:URL
Therefore, I have finally used `urllib.parse.quote` function. This additionally percent-encodes non-ASCII characters, but Wikimedia docs say these are equivalent:
> For the other characters either the code or the character can be used in internal and external links, they are equivalent. The system does a conversion when needed.
> [[%C3%80_propos_de_M%C3%A9ta]]
> is rendered as [À_propos_de_Méta](https://meta.wikimedia.org/wiki/%C3%80_propos_de_M%C3%A9ta), almost like [À propos de Méta](https://meta.wikimedia.org/wiki/%C3%80_propos_de_M%C3%A9ta), which leads to this page on Meta with in the address bar the URL
> [http://meta.wikipedia.org/wiki/%C3%80_propos_de_M%C3%A9ta](https://meta.wikipedia.org/wiki/%C3%80_propos_de_M%C3%A9ta)
> while [http://meta.wikipedia.org/wiki/À_propos_de_Méta](https://meta.wikipedia.org/wiki/%C3%80_propos_de_M%C3%A9ta) leads to the same. | [
0.2340035588,
0.201874122,
0.0728768408,
-0.1125444248,
0.1974134296,
0.1343038082,
0.1067444161,
0.0891974717,
0.0614389367,
0.1533166468,
-0.0374546908,
0.6567925215,
0.2475124598,
-0.0832400024,
0.0288755186,
-0.1070964336,
0.0564479306,
-0.1294415295,
0.1043172181,
-0.0220144205,
-0.3840960562,
0.0646104664,
-0.1503374577,
0.1632054299,
-0.20851174,
0.2000513673,
-0.0961908102,
0.1673076302,
-0.1027540192,
-0.5418641567,
-0.1118872464,
0.182539925,
-0.0351749398,
0.1686323583,
-0.000110347,
-0.2104269862,
0.7711977363,
0.037872009,
-0.4874409437,
-0.2096485794,
-0.2414145917,
-0.0804781541,
0.0525088906,
-0.2706008554,
0.0555635579,
0.2368588746,
0.1470931619,
0.1629825085,
0.0072252303,
-0.1402037442,
0.159065485,
-0.211260736,
0.0514102131,
0.0379259177,
0.2309185863,
0.1224349886,
-0.0548789427,
-0.0676192567,
-0.1303980052,
0.0747082233,
-0.0966241136,
0.3104489446,
-0.0449851267,
-0.2990261614,
-0.063860327,
0.203909874,
-0.4247608483,
-0.2489673942,
0.169263199,
0.4385918975,
0.3218892515,
-0.2481317073,
-0.3301934302,
0.0219569169,
0.1477012932,
0.169328168,
0.0552807152,
0.2699544132,
0.2109696567,
-0.0490651019,
-0.0430246256,
-0.1304095984,
-0.3784222901,
0.098753415,
-0.0884537101,
0.8044314384,
0.1146358624,
0.1565368176,
-0.3500371277,
-0.1094771326,
-0.1760356128,
-0.2725827694,
0.1755669713,
-0.0300465301,
0.2538632154,
-0.1837873608,
-0.0817220286,
0.2461571395,
0.2387663275,
-0.3154180348,
-0.225062117,
0.126677379,
-0.1198728606,
0.1244317144,
0.0623473451,
-0.2715062797,
0.038729731,
0.1446976811,
0.4861881435,
0.1408589631,
0.09234979,
0.0602405518,
-0.0246748533,
0.1754548401,
-0.5333169699,
0.109105669,
0.0510232486,
-0.0363188088,
-0.211869508,
0.1191248,
0.1287839562,
0.009579625,
-0.1475200802,
0.2140117437,
-0.1944137961,
0.1504851133,
0.0237057563,
0.0134039382,
-0.0950044319,
-0.0842663944,
-0.1106513441,
0.2752285004,
0.194834739,
0.4159493446,
0.0102843475,
0.1520838886,
0.2937237024,
-0.0306863766,
0.1340698153,
-0.2085849196,
-0.0431813896,
0.0188609976,
0.2080972344,
0.1276951581,
0.399713546,
0.3828982413,
0.1170499623,
-0.1976902038,
-0.0565699413,
0.2806454003,
-0.5224655271,
-0.0224921983,
-0.0750791952,
0.0602238365,
0.0250005592,
-0.2197432071,
-0.0937500894,
0.2439611554,
0.0574490838,
-0.0584733635,
0.0941346139,
0.2871074378,
-0.3448174596,
-0.050761696,
0.2724903226,
0.3173450828,
-0.0025174064,
0.07686764,
-0.0873510763,
0.3945976198,
-0.0685033575,
-0.2259030044,
-0.0001700559,
0.3250090778,
0.1383517832,
0.499155134,
-0.0713879913,
-0.5407469869,
0.1018468961,
-0.0081000561,
-0.0747567043,
-0.0246547181,
-0.2858700156,
-0.0802109241,
0.2590830326,
-0.0759015977,
0.1017378643,
0.2128679156,
-0.063431859,
0.1654120237,
-0.2317864299,
-0.341478318,
-0.1983444989,
0.1647164822,
0.1385442317,
-0.2959536314,
0.1404946595,
0.2267987877,
0.2297327816,
-0.2826320827,
0.1495553702,
0.0005920857,
0.0730618685,
0.013107568,
0.2244532257,
-0.1262320131,
0.0484231934,
-0.0778096318,
-0.0520186648,
0.5230643749,
-0.1816156209,
-0.3466077745,
-0.3142737448,
0.0951882526,
-0.168504253,
-0.0522021502,
0.2173968107,
-0.1034600884,
-0.2609272301,
0.3252857924,
0.0277280789,
-0.4546027482,
-0.1656930149,
-0.010475873,
-0.0014740997,
0.1766813397,
-0.0520455018,
0.1808813065,
0.0154820783,
0.3016947806,
0.3816418946,
0.1228936166,
0.0074334526,
0.2852932513,
0.2362646013,
0.5721071959,
0.444075048,
-0.1287905127,
0.3490130901,
-0.1625608206,
-0.1335477084,
0.3202803433,
0.1165462285,
-0.0344701447,
-0.2375739217,
0.5159084201,
0.0307139643,
0.2677794695,
0.0488338992,
0.1510372907,
0.316657722,
-0.0163966827,
-0.0912109166,
-0.2494895607,
-0.315705061,
0.528519392,
-0.5927537084,
-0.2672331631,
0.3303258717,
0.2281841338,
0.4219257534,
-0.1674401015,
0.2633180916,
0.2233888209,
-0.3619695902,
-0.2064397931,
0.1424251497,
-0.1150296032,
-0.2406451851,
0.1671000868,
0.0214003995,
0.2519041598,
-0.0064928522,
-0.2217037231,
0.5224341154,
0.4037258029,
-0.0630293339,
0.1736897677,
0.0903983638,
0.0020912769,
-0.1849470288,
-0.153870523,
-0.0030596827,
0.032230068,
-0.3912665546,
-0.1550095826,
-0.1921557486,
0.2774944603,
0.2369605303,
-0.142191276,
-0.1756173819,
-0.555663228,
0.1592061818,
0.3582217991,
-0.2837479711,
0.0755107105,
-0.0760403499,
0.3422059417,
0.045325119,
-0.0248160269,
-0.1732859164,
-0.5976047516,
-0.2092444599,
0.1306692064,
0.3136163056,
-0.0437092148,
-0.032201238,
0.1821955293,
0.2223134339,
-0.3164118528,
-0.518052876,
0.0943675265,
-0.2139602453,
0.1639690399,
-0.0306843501,
0.1449799389,
-0.2129277587,
-0.0906820744,
0.1794799268,
0.0669812784,
0.1191789359,
-0.0282021202,
-0.2083548754,
-0.1114256829,
0.0097276103,
-0.0841767937,
0.1657662243,
-0.0328588411,
-0.2335311174,
0.0120287007,
0.1868292242,
-0.3157080412,
-0.1646476835,
0.1275376379,
0.0525828488,
-0.1721944809,
-0.2757040858,
-0.2774915099,
0.5927476287,
-0.4781372547,
-0.464807421,
0.046496354,
-0.1043152735,
0.120171532,
-0.0784391239,
-0.160398677,
-0.1875352114,
0.3231531084,
-0.1627510041,
0.2773265839,
0.1474834085,
0.2180847377,
0.1974413246,
-0.1331452578,
-0.1167452112,
-0.0553394482,
0.088425383,
0.3864367604,
-0.0624296851,
0.0985185057,
0.1249590591,
0.2333437055,
0.7549593449,
0.1441899836,
0.60199368,
0.1729192883,
-0.1590559632,
-0.1298570335,
0.0510644726,
0.2088464051,
0.1691455841,
-0.1473966986,
-0.0307688899,
0.7027075887,
0.2522582412,
-0.0971516296,
-0.1457250565,
-0.0726611242,
-0.4553512335,
-0.4735642374,
-0.0865506902,
0.0631652176,
0.0844490081,
0.1795656085,
-0.0050553298,
-0.2751551867,
-0.4479544461,
0.3658241928,
0.1234658286,
0.0506653599,
-0.3097633421,
-0.2877559364,
-0.3368441761,
-0.3491045237,
0.1600816846,
0.3812500834,
0.1825693697,
0.11428532,
-0.0893323496,
0.0307637043,
-0.163044095,
0.2272454053,
-0.6461273432,
0.0379547402,
-0.1827554256,
0.0931021646,
-0.3963257074,
0.1762348861,
-0.062383078,
0.1239074916,
-0.1148409694,
0.296136111,
-0.3682231307,
0.1047435328,
0.1112856492,
-0.286746949,
-0.1748961657,
-0.020130083,
-0.1418483257,
-0.4753939807,
-0.3247625828,
0.0204026829,
-0.0001199354,
0.3177650273,
-0.0550466217,
-0.2124274224,
0.0368336588,
0.0759906024,
0.0229931604,
0.1930082589,
0.0120784249,
0.1741114855,
-0.288915664,
0.2092133909,
-0.2351112515,
-0.1117285937,
0.2493715286,
0.0804905444,
0.1864194274,
0.0530038923,
-0.3049479425,
0.1721696556,
0.4349933863,
0.1434480697,
-0.0003098756,
0.1407126635,
-0.120577693,
-0.4585478902,
-0.0884308442,
-0.2329438776,
-0.0773783028,
-0.3103519976,
-0.1884300709,
0.6813959479,
-0.0500285104,
-0.163358748,
0.5908376575,
0.7477265,
-0.5820308328,
0.3694838881,
0.5702075958,
1.0252450705,
-0.0475336164,
0.1062085703,
0.1858005077,
0.1770842969,
0.514547348,
-0.2013673037,
0.1640900224,
-0.445412904,
0.2100028992,
-0.1590205878,
0.1730710417,
0.0938882232,
-0.1014620364,
-0.147434786,
0.1784694344,
0.284901917,
0.4925282001,
0.3642409444,
0.5389754772,
-0.0760745555,
-0.3002266586,
0.1781812608,
0.1607798189,
0.0324390382,
-0.1485292614,
-0.0348209813,
-0.1236484572,
-0.3307845592,
-0.0411157981,
-0.0826503187,
0.1223577932,
-0.323380053,
0.1060963869,
-0.3737764359,
-0.1674780846,
0.085754998,
-0.0064300043,
0.1564263254,
0.1279204786,
-0.4353767335,
0.3389425278,
-0.3917454779,
0.127292186,
-0.0452095531,
-0.0951368362,
0.0439284518,
-0.1831287742,
-0.0353360288,
-0.0522513427,
0.2917376757,
-0.2583575249,
-0.0584515259,
-0.2048512548,
0.314018786,
-0.0930981785,
-0.4269716144,
-0.0066733747,
-0.3557496071,
-0.2330577523,
0.1132892668,
-0.3309016526,
-0.1654595584,
0.0876577199,
0.4309771061,
-0.1580047905,
0.1647420079,
0.1173227504,
-0.0856132954,
0.1566226035,
0.2507611513,
-0.0005303776,
-0.2563637197,
-0.0394963808,
0.0896677449,
-0.108118169,
-0.0764987245,
-0.1669928581,
-0.0598099306,
0.1676597148,
-0.3286247551,
0.1381487846,
-0.1223524809,
0.3917224705,
-0.0405066758,
-0.4160990417,
0.2105146199,
0.2216701955,
-0.2045553923,
-0.0457014069,
0.0050306749,
0.1213708892,
-0.0742384493,
-0.0316521786,
-0.3101514578,
0.0977854654,
-0.0384864435,
0.2117624134,
-0.210134998,
0.0649939999,
0.0840222985,
-0.013853753,
0.086259298,
0.1662912518,
0.0223601144,
-0.1752000451,
-0.3237563372,
0.1122334674,
0.3635861874,
-0.1831108928,
-0.2742355466,
-0.0128061445,
0.1561900079,
-0.2780179977,
-0.053412281,
-0.112967059,
-0.2270049453,
0.1761939377,
0.2766915858,
0.1072585881,
-0.309006542,
-0.0158767831,
-0.0837828889,
0.4555370212,
0.1577347815,
0.2832833529,
0.070971109,
0.0122660222,
0.1029230803,
0.396168679,
0.1075321734,
0.0096951714,
0.3580160141,
0.1099388823,
-0.1036403403,
0.2565743923,
0.1662272811,
0.0626294911,
-0.1941970736,
-0.2504258156,
0.2108020037,
0.121466957,
-0.0172323678,
0.1783181727,
0.2558065057,
-0.4203455448,
0.0784542337,
0.1106818616,
0.3490749002,
-0.0255702268,
-0.4833202958,
0.0194590446,
0.3604373336,
-0.2510558963,
0.0745846555,
-0.0663430542,
-0.0955584347,
0.3691040576,
0.0424651317,
-0.0390963033,
-0.1399178356,
0.1303820312,
0.3794664145,
0.4299153686,
0.4565240443,
0.0906212702,
0.1236612797,
-0.0116299586,
0.4170233905,
0.1258683652,
0.0769236609,
0.0097269276,
0.1218188405,
-0.3536901474,
0.0644825473,
-0.0014582467,
-0.0758414268,
0.2850830555,
0.0707662627,
-0.3840766847,
-0.3089923263,
-0.2639106214,
0.0445328578,
0.0231503453,
0.0005498687,
-0.4719860852,
-0.0708030537,
0.1431178302,
0.0429282747,
-0.3359627128,
0.1465435177,
0.082561411,
0.4816013575,
-0.2729705572,
-0.1189423949,
0.102128908,
0.128437683,
-0.0830464736,
-0.0714813545,
0.0948549509,
0.1658550352,
-0.6102938652,
0.0576332323,
-0.1795198172,
-0.055061873,
0.3621645272,
0.0888492465,
0.2864280045,
-0.2302242517,
0.2503917515,
0.1864263564,
-0.1280217022,
-0.3992049694,
0.4658176303,
-0.0481495485,
0.2318394631,
0.2801465392,
0.2406149358,
-0.150048703,
0.1358494908,
-0.1574461758,
-0.3265057206,
-0.1784487665,
0.2019695193,
-0.3597189486,
0.1260860711,
-0.3452952504,
0.1017167121,
0.2879663706,
0.2930392027,
0.1013208702,
-0.076897338,
-0.2961525619,
-0.3004747331,
-0.2571499348,
0.0151258372,
0.1896755397,
-0.0467938147,
0.170211032,
0.1611473262,
-0.1877543628,
0.2028413564,
-0.3220080733,
-0.2464537472,
0.0333460234,
0.1029536054,
-0.0017472787,
0.0734948963,
-0.1272462606,
0.17659612,
-0.3925532401,
0.1039534509,
0.1867035031,
-0.1181777641,
0.0085822465,
-0.1017468348,
-0.0349499136,
0.1222352758,
-0.1610489637,
0.1760941297,
0.040393874,
0.1928465515,
-0.3170553148,
0.0799448192,
0.0295105558,
0.0654814169,
-0.261288166,
0.160636127,
-0.0928268135,
0.2348099053,
0.3398995399,
-0.3983382881,
-0.0155639937,
0.2366304398,
-0.3033750057,
-0.0147666177,
-0.2774967849,
-0.0018011957,
0.0223461296,
-0.0573860779,
-0.1762319505,
0.1643320918,
-0.1079676822,
0.4197874665,
-0.0289067011,
-0.4653973579,
0.3595939875,
-0.5404392481,
-0.3929248452,
-0.0054107565,
0.2385054976,
-0.2016265541,
0.1968442649,
-0.1844385117,
-0.0608094335,
0.2502826452,
0.1357348114,
-0.1590699852,
0.2733867168,
-0.064926967,
-0.0107456893,
-0.3459670246,
-0.1597985327,
0.1191690415,
-0.2672072053,
-0.2490481287,
-0.3367243409
] |
https://github.com/huggingface/datasets/issues/3396 | Install Audio dependencies to support audio decoding | https://huggingface.co/datasets/projecte-aina/parlament_parla -> works (but we still have to show an audio player)
https://huggingface.co/datasets/openslr -> another issue: `Message: [Errno 2] No such file or directory: '/home/hf/datasets-preview-backend/zip:/asr_javanese/data/00/00004fe6aa.flac'` | ## Dataset viewer issue for '*openslr*', '*projecte-aina/parlament_parla*'
**Link:** *https://huggingface.co/datasets/openslr*
**Link:** *https://huggingface.co/datasets/projecte-aina/parlament_parla*
Error:
```
Status code: 400
Exception: ImportError
Message: To support decoding audio files, please install 'librosa'.
```
Am I the one who added this dataset ? Yes-No
- openslr: No
- projecte-aina/parlament_parla: Yes
| 25 | Install Audio dependencies to support audio decoding
## Dataset viewer issue for '*openslr*', '*projecte-aina/parlament_parla*'
**Link:** *https://huggingface.co/datasets/openslr*
**Link:** *https://huggingface.co/datasets/projecte-aina/parlament_parla*
Error:
```
Status code: 400
Exception: ImportError
Message: To support decoding audio files, please install 'librosa'.
```
Am I the one who added this dataset ? Yes-No
- openslr: No
- projecte-aina/parlament_parla: Yes
https://huggingface.co/datasets/projecte-aina/parlament_parla -> works (but we still have to show an audio player)
https://huggingface.co/datasets/openslr -> another issue: `Message: [Errno 2] No such file or directory: '/home/hf/datasets-preview-backend/zip:/asr_javanese/data/00/00004fe6aa.flac'` | [
-0.2341928035,
0.0829561949,
-0.1228213683,
0.2838071287,
0.1610811651,
0.0163821392,
-0.0711146891,
-0.0265360139,
-0.3266075253,
0.2293248028,
-0.3968032897,
0.3755854666,
-0.0406985134,
0.0464402959,
-0.1093372628,
-0.2251796871,
0.091982089,
0.3634328246,
-0.1583887637,
-0.0297109894,
-0.2033932805,
0.4243871868,
-0.2201775312,
0.0990479738,
-0.1439189166,
0.0447139777,
0.0281777773,
-0.1364054829,
-0.5286777616,
-0.3223710656,
0.1723496169,
-0.0390273444,
0.0900085196,
0.3624122441,
-0.0001150156,
-0.0916187689,
0.4367978573,
-0.1400973052,
-0.1307918429,
-0.1518681943,
-0.3172643185,
-0.1341240853,
0.1124356166,
0.137645945,
0.1100963652,
-0.4963767827,
-0.1170556471,
-0.4504229128,
0.4022116661,
0.1258859634,
0.2048759907,
-0.0335429497,
0.3752242625,
0.0694860667,
0.3817954957,
0.0119480118,
-0.1067782491,
-0.0237843655,
0.2801417112,
0.2495438308,
-0.060851898,
0.4002117217,
-0.0564942881,
0.0244188327,
0.3291603923,
-0.3017023504,
-0.2653124332,
-0.6008692384,
0.1745330393,
0.2519070506,
0.8086963296,
-0.1358438432,
-0.3358102143,
0.152860567,
0.2076650858,
-0.0824640691,
0.2827850878,
0.305182904,
-0.0887220874,
0.3121015429,
-0.0358696021,
-0.2544262409,
-0.0997514203,
0.0654234365,
-0.0356112234,
0.3396911323,
-0.2548049688,
-0.1460393369,
0.3748890758,
-0.1155005395,
0.1107478589,
-0.0381479487,
-0.2872829437,
0.2715198398,
-0.1036993042,
0.0490623564,
-0.015168705,
0.2508012652,
-0.109076038,
0.2209172845,
-0.3179303706,
0.270295471,
-0.5252568722,
0.1978553832,
-0.086212486,
-0.0276249312,
0.1423909217,
0.0638520122,
0.4108978212,
0.1133724079,
0.4606716335,
-0.1374339014,
-0.174517557,
-0.0782639608,
-0.4310608208,
0.0026510328,
0.2989809215,
-0.3825353682,
-0.3316467702,
0.1689642966,
-0.5156121254,
-0.2463438511,
0.1758946329,
0.2025268823,
-0.0357027501,
0.2799886465,
0.2141552418,
0.3292526901,
0.0440291315,
-0.0873808786,
0.0338460766,
0.1558703333,
-0.0241576675,
0.0958411247,
0.1455366462,
-0.1727420688,
0.3236541748,
0.0517025813,
0.1310145706,
-0.0149725778,
0.1575008333,
-0.1141503453,
-0.2443856597,
0.4234372377,
-0.033798404,
0.1163771078,
-0.1253300607,
0.0229570772,
-0.0721587241,
0.2676765621,
-0.0922806337,
-0.0743158385,
-0.122339949,
0.1854370236,
-0.2704921067,
0.1822049618,
-0.2250193059,
0.0984553024,
-0.3147140443,
-0.4179733098,
-0.1146483943,
0.1290784329,
-0.0591501147,
0.0274897832,
0.3090469837,
0.137122035,
-0.6475441456,
-0.1357952207,
-0.2419781387,
-0.442183435,
-0.0041042734,
0.0454610139,
-0.1231764704,
0.0287717953,
-0.3128089905,
0.1355864853,
0.5135677457,
-0.317183584,
-0.4460077882,
0.1856278181,
0.1578184664,
0.128250584,
0.2680318356,
0.095220767,
0.1088119,
-0.1549207717,
-0.3386915028,
0.2537969053,
0.1383820176,
-0.1057015061,
0.0372768454,
-0.3360304832,
-0.1785954982,
0.2702172399,
-0.0006193353,
-0.0232059062,
0.0847053602,
0.0132009126,
0.1697148085,
-0.162083894,
0.0488308482,
0.2489346713,
0.6218203902,
0.1477503777,
0.0460199974,
-0.3431356251,
0.1593218297,
-0.1608143002,
-0.0088888546,
0.2573929131,
-0.4822892249,
-0.1869456619,
-0.2675109506,
-0.1326587051,
-0.410954088,
0.1133409292,
0.1314916164,
0.3642641306,
-0.1769638956,
0.0006498913,
-0.1465882659,
0.2756711841,
0.2550824583,
0.0214831233,
-0.2809083462,
0.1843815297,
-0.1693041623,
0.165086031,
0.3021090627,
0.2028158605,
0.1107982323,
-0.1228094548,
-0.1675713509,
0.3904956877,
0.1124952734,
0.307890594,
-0.0631732792,
0.0798605755,
0.2023763657,
-0.6000858545,
0.2217570543,
-0.0316930078,
0.1252828985,
-0.1914995909,
0.0626560152,
-0.0514457896,
-0.0018211781,
0.1445668489,
0.1951117516,
0.0218548011,
0.3287650347,
0.1392609179,
-0.3494177461,
-0.2493992895,
0.0350850672,
-0.2263278067,
0.5072665215,
-0.0168624502,
-0.1720826775,
-0.1734222621,
0.2258390337,
-0.1756076515,
-0.0706795827,
0.0417036749,
-0.2512350976,
0.1616012901,
0.2226365656,
0.096934244,
0.372266829,
0.2973399162,
-0.0336444713,
0.0266636033,
0.1730285138,
-0.2844957411,
0.1765520573,
0.2277487963,
0.0591931455,
0.2298947573,
-0.0593205504,
-0.001654,
-0.4046278298,
-0.3306983709,
-0.0946836323,
0.2002408653,
-0.1683919579,
-0.2084958255,
-0.4447605014,
-0.2565885782,
-0.2708145976,
-0.5788354874,
-0.3302179277,
-0.3632636666,
0.0036816339,
0.0907746106,
0.1078166664,
0.3846114874,
0.0471165553,
0.1418303847,
-0.3056341112,
0.0922193676,
-0.2208844125,
0.0711962804,
-0.1634006351,
0.1457838565,
0.4816268086,
0.2885898352,
0.2275770903,
-0.2130002081,
0.3165295422,
-0.2260603011,
-0.2394819558,
0.2331435829,
-0.0374883264,
0.0799186602,
0.1769375354,
0.076278761,
0.2532631457,
-0.4635227323,
0.1710249037,
0.2487236857,
-0.0931718573,
-0.0759447664,
-0.0767553598,
0.0502521992,
-0.1054531112,
-0.3222092986,
-0.2128930986,
-0.5416291952,
0.194280684,
-0.029914597,
-0.0141882431,
-0.0693676174,
0.0704741627,
0.3135613501,
0.2139149457,
0.2743997574,
-0.1324432194,
-0.09248247,
0.3485714197,
-0.1475348026,
-0.1842930168,
0.2961160839,
0.2353964001,
0.4261060953,
-0.2425886542,
-0.5917024612,
-0.0786819309,
-0.019849686,
-0.2189590335,
-0.1244481355,
0.215488106,
0.3251306117,
0.2958338857,
0.1003228351,
-0.101022765,
-0.3052575886,
-0.2448656708,
-0.399527967,
0.3646704853,
-0.1087182015,
0.5343530774,
-0.2807208002,
0.5696761608,
0.2660740614,
0.1940642297,
0.3537202477,
0.3349718451,
0.4842017293,
-0.2660482526,
-0.2535032928,
-0.0973631889,
0.0787256211,
0.1495182812,
0.2239735126,
0.1960519552,
-0.1579786092,
-0.4004413486,
-0.1694139689,
-0.2007056326,
-0.0210639257,
-0.1655186564,
-0.149299413,
0.0955285206,
-0.0795544684,
0.0617560968,
0.0902454555,
0.0046712421,
0.2843852639,
0.2436138391,
0.2608224452,
-0.1024827287,
-0.3269299269,
-0.1822540164,
-0.1590237916,
0.3430606425,
-0.2366663069,
0.1844843477,
-0.0675276294,
0.0329441614,
0.0647225678,
-0.0746954009,
0.2988637686,
-0.1877494454,
-0.2252943814,
0.1432379484,
0.3421634138,
-0.0050111664,
0.0403934009,
-0.3646676838,
-0.1304018348,
0.2839134634,
0.4539198875,
-0.2698023617,
-0.1463724226,
0.48874861,
0.1947338879,
0.1406269819,
-0.3357974589,
-0.3228794932,
-0.3527285159,
-0.2227861136,
-0.1630348116,
-0.2152774483,
0.2046851218,
0.2194581479,
-0.0496295914,
0.135894537,
-0.3146346509,
0.3173528016,
0.0508781485,
0.0510263406,
0.2336672992,
0.1488512009,
0.0438957699,
0.1709587425,
0.5495877266,
0.5976413488,
-0.0604319125,
-0.3979091942,
0.1928097755,
-0.3081610799,
0.4225554168,
0.19390966,
0.0216941833,
-0.1070512384,
0.220176205,
0.0806784108,
-0.0913644508,
0.0476235636,
0.456364274,
0.1042783409,
-0.239724353,
-0.2015970647,
0.3949379325,
0.158772558,
-0.1598414481,
0.1561383903,
0.4164211452,
-0.0467820019,
0.1760413647,
-0.1012203097,
1.2754446268,
0.0969292596,
-0.2841520309,
0.2249890864,
-0.4030656517,
0.2300591469,
-0.5599193573,
0.0400440991,
0.1547664404,
-0.1501393169,
-0.1431530714,
0.0150102023,
0.5549247861,
-0.1084408313,
-0.3859880865,
0.1811689287,
0.1613194495,
-0.003345652,
-0.0165474154,
0.349604845,
-0.1533085853,
-0.2881055772,
-0.1930171698,
0.1932808608,
0.1889801621,
0.1507906616,
-0.0609609857,
-0.1906386614,
-0.0406573042,
-0.2534169853,
-0.259475112,
0.1116982698,
-0.2598781586,
0.0850339979,
-0.0044122618,
-0.2347659916,
0.5655710697,
0.2190278322,
0.0812437087,
0.3419841528,
-0.112557821,
0.223819524,
-0.1010094509,
-0.0009525883,
0.1555354893,
0.201902017,
0.0667179078,
-0.1501627713,
-0.3048605621,
0.3032045662,
-0.1565372795,
-0.0342738852,
0.0706472844,
-0.1097867563,
0.1886409074,
-0.0976157114,
-0.2566108704,
0.0132945646,
0.0883685425,
-0.0527814478,
0.1536737978,
-0.0846802816,
-0.3673298061,
0.0466945097,
-0.1643299758,
-0.0956427231,
-0.2165774554,
0.2776628733,
0.0367011353,
-0.1475178599,
0.4008110166,
0.0860831812,
-0.2391090542,
-0.1738444269,
0.1101025119,
0.0336622708,
-0.2886326611,
-0.4667059183,
0.3312844932,
-0.2714470327,
-0.1329622269,
0.0964499861,
0.027416341,
0.1619584709,
-0.2194239944,
-0.3752605915,
-0.2605730295,
0.363514632,
-0.0876780748,
0.0905239582,
-0.3346713483,
0.1188049614,
0.1124188602,
0.1987295896,
-0.2979819477,
0.0604428425,
-0.1029134542,
0.1469175518,
0.125951156,
0.1723714173,
0.0272565112,
0.0314107351,
0.1014399156,
0.2454453707,
-0.3614525497,
-0.049540028,
0.1159034893,
0.124891676,
0.0753294751,
-0.1527142525,
-0.0369652808,
-0.138387233,
-0.212905854,
-0.0435375646,
-0.1810432673,
0.1162644625,
-0.0562962107,
-0.2493631244,
0.0179283302,
-0.0778998137,
0.0208120532,
-0.0257608704,
0.1532673389,
0.0192453451,
0.0256502107,
0.0756517798,
0.0739516541,
-0.1332636923,
0.1141109616,
0.1455307156,
0.1076566055,
-0.0508579761,
0.3243495822,
-0.0416407511,
0.2458233833,
0.3850569129,
0.3495706022,
0.358053267,
0.0648823082,
0.1293796897,
0.2336978167,
0.165923968,
-0.411667347,
-0.2308966666,
0.3693578541,
-0.120904848,
-0.083977595,
0.0644850731,
0.0840888917,
0.1035991982,
0.5770037174,
0.0657460317,
0.3175131083,
0.1655727774,
0.399892658,
0.1947416067,
-0.3258732557,
0.1178229302,
0.2910645008,
0.1166324094,
0.0004901362,
0.2584187388,
-0.7476299405,
-0.1118265167,
-0.0559091605,
0.0595453233,
0.1805292219,
-0.411716491,
-0.1986655593,
0.1345627308,
0.1591460258,
-0.3232932985,
0.0694475546,
0.2281364799,
-0.1701614261,
-0.1042947248,
-0.1230363995,
0.1816599965,
-0.0730578601,
0.1542133391,
0.1615904272,
-0.2398379892,
-0.1329551339,
-0.1445221454,
0.247698307,
-0.1011238694,
-0.0021792203,
-0.0329568796,
-0.0546461567,
-0.1080953404,
-0.3961255848,
-0.0147172483,
0.1138414666,
-0.1487851888,
0.3303058445,
0.1159598753,
0.0741246343,
0.2348746359,
0.289190799,
0.3627995253,
0.2933173478,
0.1386498362,
0.126160115,
-0.1389538497,
-0.1403836459,
0.0981831551,
0.3019406497,
0.2761540711,
0.5049616098,
0.1537565142,
0.1369754225,
-0.1840964407,
0.0006597217,
-0.0851270631,
0.4171952009,
-0.4151517153,
0.1250831634,
-0.6122140288,
-0.124116987,
-0.273650825,
-0.3102956414,
-0.5477475524,
0.0255081095,
0.0931052566,
0.0008471256,
-0.1484446377,
-0.1244503334,
0.0466710515,
-0.1771465242,
0.1974828839,
0.4238160551,
0.0331763588,
-0.0476296805,
-0.5881982446,
-0.7772827148,
0.0797121972,
0.1707250327,
0.0482808873,
-0.2426718026,
-0.091409117,
0.3920036554,
0.3148981929,
0.0504585244,
0.1853760928,
0.1144898683,
-0.1702589244,
-0.2064360827,
-0.0023926797,
0.1332022399,
0.185365051,
-0.1885026544,
-0.1940261275,
0.0217019506,
0.112349011,
0.0486573428,
0.0357390679,
0.0190550014,
-0.3290576041,
-0.0121666677,
0.3871978521,
0.1435486972,
0.6892684698,
-0.0921091288,
-0.0227667447,
0.0147904474,
-0.3207664192,
0.1197179779,
0.2423404455,
0.1438394338,
0.5700986981,
-0.2429644614,
-0.0075696539,
-0.452875793,
0.2142329514,
-0.1592194438,
0.1872590631,
-0.5132799149,
0.0581320859,
-0.2556420863,
0.0566890761,
0.2048811018,
-0.1677300483,
-0.0106835961,
-0.0103995278,
-0.348041594,
-0.1752216518,
0.4888722599,
-0.1627761126,
-0.0350321233,
0.0665257946,
0.2049950808,
0.1880412698,
-0.3445082307,
-0.7730877995,
0.1860069633,
0.2383259237,
-0.0002010321,
-0.044247862,
0.2122534215,
-0.1079460979,
-0.010624757,
-0.0660114437,
-0.200876385,
0.152562052,
-0.029776318,
0.1741731167,
-0.169830665
] |
https://github.com/huggingface/datasets/issues/3396 | Install Audio dependencies to support audio decoding | But https://huggingface.co/datasets/openslr/viewer does not work
<img width="678" alt="Capture d’écran 2022-04-12 à 13 59 46" src="https://user-images.githubusercontent.com/1676121/162958013-e31ef2ae-f886-47b7-9f27-664ed3d4b5a1.png">
Same issue as #4126:
```
Status code: 400
Exception: TypeError
Message: __init__() got an unexpected keyword argument 'audio_column'
``` | ## Dataset viewer issue for '*openslr*', '*projecte-aina/parlament_parla*'
**Link:** *https://huggingface.co/datasets/openslr*
**Link:** *https://huggingface.co/datasets/projecte-aina/parlament_parla*
Error:
```
Status code: 400
Exception: ImportError
Message: To support decoding audio files, please install 'librosa'.
```
Am I the one who added this dataset ? Yes-No
- openslr: No
- projecte-aina/parlament_parla: Yes
| 34 | Install Audio dependencies to support audio decoding
## Dataset viewer issue for '*openslr*', '*projecte-aina/parlament_parla*'
**Link:** *https://huggingface.co/datasets/openslr*
**Link:** *https://huggingface.co/datasets/projecte-aina/parlament_parla*
Error:
```
Status code: 400
Exception: ImportError
Message: To support decoding audio files, please install 'librosa'.
```
Am I the one who added this dataset ? Yes-No
- openslr: No
- projecte-aina/parlament_parla: Yes
But https://huggingface.co/datasets/openslr/viewer does not work
<img width="678" alt="Capture d’écran 2022-04-12 à 13 59 46" src="https://user-images.githubusercontent.com/1676121/162958013-e31ef2ae-f886-47b7-9f27-664ed3d4b5a1.png">
Same issue as #4126:
```
Status code: 400
Exception: TypeError
Message: __init__() got an unexpected keyword argument 'audio_column'
``` | [
-0.2965098321,
0.1264424175,
-0.0777170882,
0.2870647907,
0.151958853,
0.0553317517,
0.1448055059,
0.0143223889,
-0.28875947,
0.2315077037,
-0.3266481757,
0.4537605643,
-0.1193321347,
0.0719230473,
-0.1263938099,
-0.1828403771,
0.0877652392,
0.493055284,
-0.3374743462,
-0.1284854561,
-0.3122032583,
0.4497969747,
-0.3373767734,
0.0193424467,
-0.1670345962,
0.054548949,
0.1194868237,
-0.0849401727,
-0.5611323118,
-0.3907191157,
0.1181294769,
-0.0020332902,
0.0799599886,
0.3410718739,
-0.0001180416,
-0.0123010688,
0.355376631,
-0.1337410212,
-0.0589190871,
-0.2846211493,
-0.3987480104,
-0.1342016011,
0.090211913,
-0.0446395017,
0.2001910657,
-0.4174399674,
-0.1103490144,
-0.4196917713,
0.3497518003,
0.1527435482,
0.2060143501,
-0.0486945435,
0.3847513497,
0.1021894813,
0.375920862,
-0.0041761333,
-0.1956027597,
0.0484320633,
0.1801505238,
0.1847973913,
0.0904473513,
0.4932568669,
-0.0710325614,
0.0601901449,
0.3783477843,
-0.1833717227,
-0.1948537529,
-0.4637041092,
0.169602111,
0.1897086203,
0.8263199925,
-0.1372539252,
-0.2498106062,
0.2055687308,
0.0906692222,
-0.2023472786,
0.3588617146,
0.2713280916,
-0.0714312792,
0.2449369133,
-0.1820330173,
-0.189985007,
-0.171756655,
-0.0062090349,
-0.0480499156,
0.228938669,
-0.2268804312,
-0.0270443838,
0.4831114709,
-0.1177986488,
0.0006019734,
0.002053902,
-0.2501156628,
0.2812976837,
-0.2162686288,
0.0342349112,
-0.0401637293,
0.3858961761,
-0.0997065827,
0.299574554,
-0.3533371389,
0.1197672859,
-0.3374932408,
0.2003019452,
-0.1608876735,
-0.0852809548,
0.1476539671,
-0.0118173081,
0.3496220112,
0.0266030766,
0.2685146332,
-0.0799979046,
-0.1103982031,
-0.1702814996,
-0.3287713826,
-0.1256298572,
0.350001663,
-0.2691648304,
-0.3478120863,
0.1574758142,
-0.5971589684,
-0.2346353233,
0.1742916852,
0.2155531794,
0.0972591341,
0.1695046723,
0.3025212288,
0.3709834814,
0.0309650209,
-0.0292507932,
0.037373472,
0.2795081139,
-0.0564366356,
0.1358879656,
0.0773605779,
-0.010500934,
0.2030738592,
0.0044068485,
0.2049477994,
-0.0737833008,
0.166152209,
-0.0673561171,
-0.3284479082,
0.3049276471,
-0.1027759388,
0.1178771257,
-0.087597847,
-0.0115667619,
-0.1366862208,
0.3244288266,
-0.1386501491,
-0.0718658343,
-0.1517999023,
0.1467505544,
-0.2456987649,
0.1137240678,
-0.2354398966,
0.1237964109,
-0.3150434196,
-0.4164302051,
-0.1353189051,
0.1270403117,
-0.226479739,
0.0410494953,
0.2551624775,
0.1672241837,
-0.6773875356,
-0.1833294779,
-0.1926510334,
-0.3444876075,
-0.0512271002,
0.0188299902,
-0.0916833803,
0.0257181898,
-0.12069235,
0.1994233131,
0.5124173164,
-0.4812293649,
-0.5407556891,
0.0950634331,
0.2183421701,
0.0941767469,
0.2647719085,
0.1055217683,
0.1944753528,
-0.1488015503,
-0.3259063363,
0.1040425897,
0.1352661103,
-0.0597561449,
0.0830863118,
-0.3924722075,
-0.1379450858,
0.2720303833,
0.0155185284,
-0.0428796187,
-0.0165549014,
0.0409258753,
0.1223152876,
-0.1287953109,
0.0831750408,
0.2919635475,
0.6977112889,
0.1794006526,
0.0251744054,
-0.3098345995,
0.0541135073,
-0.1212191954,
0.1263425499,
0.3303841949,
-0.4748377204,
-0.1423388273,
-0.294990778,
-0.1105219573,
-0.4315510392,
0.1907231957,
0.0988581926,
0.2590758204,
-0.1917111874,
0.0086763119,
-0.1934990138,
0.3691785336,
0.1807157695,
0.0436595827,
-0.1861335486,
0.1028706282,
-0.2499742955,
0.1083643511,
0.1613461077,
0.1953547001,
0.1693784893,
-0.1504466683,
-0.1468350142,
0.4519402981,
0.1216976941,
0.2242484838,
-0.2389345765,
0.1035843268,
0.2189358026,
-0.6197242737,
0.1376970708,
-0.2700823247,
0.1694058776,
-0.0859653056,
0.0466348976,
-0.2112066299,
0.0298960507,
0.195627138,
0.0827449039,
-0.0008561984,
0.2615789473,
0.0937102735,
-0.2796604633,
-0.2861862183,
-0.0154992426,
-0.0323936716,
0.4190945327,
-0.0879231244,
-0.1159667596,
-0.2784943283,
0.3089643419,
-0.064324744,
-0.1229489967,
0.1038745344,
-0.1350016892,
0.2219616622,
0.1905633062,
0.1467235088,
0.4659525156,
0.2412380427,
-0.0542589016,
0.1082355604,
0.0753349811,
-0.1906435788,
0.163143903,
0.280719012,
-0.032540381,
0.1418093294,
-0.014456558,
-0.0137729412,
-0.3752256632,
-0.2744864523,
0.049916029,
0.1961297989,
-0.2460485548,
-0.1724981666,
-0.5155569315,
-0.0841059685,
-0.1357123554,
-0.553694427,
-0.1825817227,
-0.2305295914,
-0.021013787,
0.0941508636,
0.1482503414,
0.4917584658,
-0.0207626428,
0.2376137227,
-0.2833131254,
-0.0061005033,
-0.2012086511,
0.036091581,
-0.0811852142,
0.0885900632,
0.3569816649,
0.1533783972,
0.1478218585,
-0.256049782,
0.2446342409,
-0.120034188,
-0.3405117691,
0.2499938309,
-0.1740019172,
0.0754036903,
0.1136902198,
0.0154330507,
0.2122185826,
-0.3625841737,
0.218126148,
0.3223560154,
-0.0535626784,
-0.0957944393,
-0.1630850434,
0.0546198152,
-0.1782488823,
-0.3044292331,
-0.1431665868,
-0.551638782,
0.2285925597,
0.0954488441,
-0.0512213968,
-0.028520653,
0.1283805668,
0.2606461346,
0.2137171179,
0.4529341459,
-0.1459487081,
0.0196525007,
0.3394663334,
-0.134848088,
-0.1164792255,
0.2785386443,
0.1971232146,
0.4798459113,
-0.1664954275,
-0.5810844898,
-0.1963216215,
-0.0575670339,
-0.2384347767,
-0.0873155743,
0.1511265635,
0.3038572371,
0.2680080533,
0.1351878196,
-0.1380487233,
-0.375251174,
-0.0290546101,
-0.2957123816,
0.3250169456,
0.0139041496,
0.7046719193,
-0.2607308626,
0.3487101793,
0.2930922806,
0.0811129063,
0.4422973394,
0.1773878038,
0.5404126048,
-0.2462598383,
-0.1986391544,
-0.1231810451,
0.0387373082,
0.2108152211,
0.1328071654,
0.1469672918,
-0.1657873541,
-0.4202394485,
0.0260962676,
-0.2449022532,
-0.0890349373,
-0.1778941751,
-0.0812861547,
0.0533797666,
-0.015742531,
0.1050980166,
0.0361417606,
0.0145083191,
0.2543890178,
0.1649407297,
0.235931769,
-0.2142318338,
-0.3840625882,
-0.1167093962,
-0.1080687568,
0.3944219649,
-0.2297474891,
0.1828673929,
-0.0830010995,
-0.0120488582,
0.1246156171,
-0.098052673,
0.2941843271,
-0.1613223106,
-0.276915133,
0.0884477794,
0.3669171929,
0.0031879898,
-0.021694025,
-0.3593554199,
-0.1838276535,
0.2887158394,
0.4787682593,
-0.3374435902,
-0.0463771634,
0.6703531146,
0.1045486555,
0.1233566776,
-0.3176456094,
-0.2728497684,
-0.4574381113,
-0.2517078221,
-0.2163354605,
-0.1200708523,
0.3001325428,
0.2321389914,
-0.029708799,
0.2584701478,
-0.4059592783,
0.391784519,
0.0709454417,
0.1124614924,
0.1881408393,
0.226968348,
0.0509005785,
0.0425026901,
0.4449978471,
0.6628160477,
-0.1874638945,
-0.3807366788,
0.1834744513,
-0.2923923433,
0.365231514,
0.19848153,
-0.0075404872,
-0.0436380506,
0.1301310807,
-0.0170652587,
-0.1823848486,
0.0873657018,
0.6785202622,
0.0350396,
-0.1709733307,
-0.305575192,
0.4842645228,
0.1689837575,
-0.1753691733,
0.2298137695,
0.6659416556,
-0.0663392842,
0.1814222634,
-0.0865430757,
1.1843255758,
0.1579561234,
-0.2411417067,
0.2488917559,
-0.4925258756,
0.2735698819,
-0.5087192655,
0.1254105121,
0.1567850113,
-0.1094600335,
-0.1310155094,
-0.049369853,
0.464746803,
0.0061593084,
-0.4050674736,
0.0767115951,
0.1116768792,
0.1042854413,
-0.0870957226,
0.1049350202,
-0.1186455861,
-0.25985533,
-0.0815412402,
0.180002436,
0.296089828,
0.0698451325,
-0.1003024504,
-0.1492796838,
0.0287560206,
-0.3958359063,
-0.3329246938,
0.0174655858,
-0.1045902222,
0.1770836562,
0.1167293042,
-0.2412333786,
0.6063069105,
0.2822085917,
0.0921462029,
0.2476949543,
-0.1600434482,
0.283773005,
-0.0839610696,
0.0170367565,
0.1482763588,
0.2577406168,
0.0004867613,
-0.134591952,
-0.3313782215,
0.3105980158,
-0.0921424925,
-0.1476213187,
-0.0121445442,
-0.0215783119,
0.1621053964,
-0.1218022853,
-0.342182368,
0.0208391398,
0.0976416245,
-0.0817274153,
0.1244110391,
-0.2021479905,
-0.3452327847,
0.2709513307,
-0.2180454433,
-0.1850117743,
-0.1077453718,
0.2446537018,
-0.0441691764,
-0.1194470301,
0.4083455503,
0.0736926794,
-0.2694898546,
-0.1073086634,
0.0916704014,
0.0147464853,
-0.3294084072,
-0.3614120185,
0.3487329483,
-0.2339541465,
-0.0953849554,
0.1207526326,
-0.033952985,
0.1296768636,
-0.1243586093,
-0.296546787,
-0.2135926485,
0.4215398431,
-0.1064422503,
0.1385844946,
-0.2759275138,
0.1576883644,
0.0564484932,
0.144096911,
-0.2793571651,
0.1239410415,
-0.207517013,
0.133819446,
0.2659335136,
0.1311667264,
0.076640293,
0.0841472968,
0.1030262336,
0.4203999043,
-0.3279913068,
-0.0011729632,
-0.1006717905,
0.150255546,
0.0962196589,
-0.135588482,
-0.0407242924,
-0.2101922184,
-0.335924089,
0.0049608462,
-0.1157873794,
0.1585180908,
-0.0822384804,
-0.1763210446,
-0.1368635595,
-0.1457711458,
0.064039968,
0.0025957855,
0.1081433743,
0.1665681899,
0.081977725,
0.106917657,
0.0923501179,
-0.1063920185,
-0.0396185145,
0.2292169929,
0.1113193706,
-0.1705650836,
0.3226641715,
-0.0866726786,
0.3074798584,
0.233939901,
0.3788838983,
0.3780181408,
-0.0437781736,
0.1036058068,
0.1083362699,
0.1665809005,
-0.4014762044,
-0.181633234,
0.2367243022,
-0.122134693,
0.0745127499,
0.1144732311,
0.057498727,
0.142856732,
0.421289891,
0.0481059626,
0.4744130075,
0.1458822787,
0.2302336991,
0.1945652515,
-0.3767898083,
0.1892876923,
0.3521836102,
0.2289568335,
0.1280717254,
0.3721113503,
-0.73973912,
-0.142476961,
-0.0436295085,
-0.0166024305,
0.1686632931,
-0.3535032272,
-0.1562277228,
0.1708705872,
0.1456899494,
-0.2648204565,
0.0221310109,
0.1247804686,
-0.1929842979,
-0.0192326698,
-0.203151837,
0.1656719148,
-0.0471865833,
0.0566148013,
0.0141576491,
-0.26721102,
-0.2116291225,
-0.1058128998,
0.1850028336,
-0.0764439628,
0.1183102429,
-0.0347872898,
0.0441235565,
-0.0470646136,
-0.5005906224,
-0.0691038892,
0.0242958572,
-0.179663524,
0.3753097951,
0.2743575275,
0.1299221218,
0.3690678775,
0.2600869238,
0.4315783679,
0.3410784006,
0.1818734854,
0.0859751627,
-0.1100010648,
-0.1088940576,
0.0992350206,
0.3886077404,
0.3433656096,
0.6661241651,
0.1549144238,
0.0992631242,
-0.1760690063,
0.0058393939,
0.0240380559,
0.4162033498,
-0.4754807651,
0.1461360455,
-0.6169233918,
-0.1558150202,
-0.3028001487,
-0.2419107556,
-0.4697758853,
0.000072474,
0.0865170881,
0.0108621791,
-0.1616771668,
-0.0315013714,
0.0312918201,
-0.085427925,
0.2290857136,
0.2812866569,
0.1172815114,
-0.0327657387,
-0.5624066591,
-0.748103261,
0.0867002681,
0.0292877257,
-0.0508846194,
-0.2616381049,
-0.0398787782,
0.4480829239,
0.1827678829,
0.1552000493,
0.1249817684,
0.0757289529,
-0.1463999897,
-0.1832747161,
-0.0130154463,
0.2486179173,
0.1261281818,
-0.2086451799,
-0.1973275095,
0.0029973995,
0.1468496919,
0.0102749402,
-0.0842619538,
0.0112551777,
-0.3588754833,
-0.0852998197,
0.3909797668,
0.0850653872,
0.8222956657,
-0.0773536712,
-0.0795060992,
0.0199177843,
-0.3578900993,
0.0309896264,
0.0197286196,
0.1113199517,
0.4893071949,
-0.2686013281,
0.0550633334,
-0.3471343219,
0.2491450012,
-0.1425845027,
0.0754248649,
-0.5595657825,
-0.0019230315,
-0.2438563555,
0.0020238352,
0.2101786286,
-0.1871773154,
0.084199667,
0.0897356346,
-0.3817720413,
-0.2407766283,
0.6285683513,
-0.1950632036,
-0.1685040444,
0.0716474578,
0.1811517775,
0.1434505284,
-0.3217774332,
-0.7973064184,
0.1336534917,
0.221180141,
-0.0097552147,
-0.0797661543,
0.2737016082,
0.0340676159,
-0.0770543292,
-0.0695481524,
-0.2566356063,
0.1098541915,
-0.0021212273,
0.0980218723,
-0.2005828321
] |
https://github.com/huggingface/datasets/issues/3394 | Preserve all feature types when saving a dataset on the Hub with `push_to_hub` | According to this [comment in the forum](https://discuss.huggingface.co/t/save-datasetdict-to-huggingface-hub/12075/8?u=lhoestq), using `push_to_hub` on a dataset with `ClassLabel` can also make the feature simply disappear when it's reloaded ! | Currently, if one of the dataset features is of type `ClassLabel`, saving the dataset with `push_to_hub` and reloading the dataset with `load_dataset` will return the feature of type `Value`. To fix this, we should do something similar to `save_to_disk` (which correctly preserves the types) and not only push the parquet files in `push_to_hub`, but also the dataset `info` (stored in a JSON file). | 25 | Preserve all feature types when saving a dataset on the Hub with `push_to_hub`
Currently, if one of the dataset features is of type `ClassLabel`, saving the dataset with `push_to_hub` and reloading the dataset with `load_dataset` will return the feature of type `Value`. To fix this, we should do something similar to `save_to_disk` (which correctly preserves the types) and not only push the parquet files in `push_to_hub`, but also the dataset `info` (stored in a JSON file).
According to this [comment in the forum](https://discuss.huggingface.co/t/save-datasetdict-to-huggingface-hub/12075/8?u=lhoestq), using `push_to_hub` on a dataset with `ClassLabel` can also make the feature simply disappear when it's reloaded ! | [
-0.2111832201,
-0.421753943,
0.0569307096,
0.3006316423,
0.2904073596,
-0.0126073407,
0.1880396903,
0.2776143551,
0.01033042,
0.0954096094,
-0.4370885491,
0.4137707353,
-0.1050539538,
0.633710146,
-0.0238210876,
0.1002005562,
0.2585051358,
0.0915538147,
0.1439446658,
-0.1857997328,
-0.3444070816,
0.1544872969,
0.2028089762,
0.0133955935,
-0.5050088763,
-0.0545495227,
0.0639885068,
0.1560145915,
-0.0946274102,
-0.2617854774,
0.3016667366,
0.1229146942,
0.0251281261,
-0.0729007274,
-0.000110251,
-0.0156738684,
0.1298505217,
-0.2305693775,
-0.1600668132,
-0.1020417735,
0.0002053211,
0.0783441067,
0.0938008353,
-0.1145104021,
-0.2116517425,
0.2717475295,
0.014452477,
0.130625546,
0.1541194916,
0.0062578055,
0.1556765139,
0.0790169314,
0.0498162284,
-0.0331312455,
0.3613735735,
0.5582364798,
-0.2765959799,
-0.0294035114,
-0.0095802713,
0.5110071301,
0.0887864977,
0.2334180623,
0.0526150167,
-0.341391772,
0.3785181046,
0.1217031255,
-0.0449222401,
-0.0999423191,
0.0799593031,
0.0927002653,
0.0750223398,
-0.3629440069,
-0.3133401871,
-0.3963755965,
-0.0397101343,
-0.2836900353,
0.2079853565,
0.1384296119,
0.1214548945,
0.1115465984,
-0.150879845,
-0.45729509,
-0.1571629941,
-0.1476302743,
0.0400412381,
0.091611065,
-0.2346906066,
0.0812394544,
0.0121526495,
-0.1263189167,
-0.0720235333,
-0.2739060819,
-0.1568802893,
-0.0913952067,
0.0116860447,
-0.2402732968,
-0.0318942517,
0.4249568284,
0.2972501814,
0.1004034355,
-0.0989397317,
0.3380026519,
-0.187091887,
0.2192953527,
0.4268015623,
-0.0188070852,
0.5271796584,
-0.180587545,
0.4202421606,
0.1471216977,
0.0524931401,
-0.0749885961,
0.2663828433,
0.5446486473,
0.2874007225,
-0.1537428647,
0.4817511141,
-0.345079273,
-0.0608622953,
0.0352333523,
0.2810750008,
0.1954680979,
0.0321937315,
0.3828086257,
0.1109836847,
0.2837486565,
-0.1220056415,
0.3229446709,
0.0013726677,
-0.14110744,
-0.3007627726,
-0.0774797946,
0.0995249599,
-0.0327570066,
0.2195297927,
-0.3368288875,
0.1276181489,
0.1251100302,
-0.0583163202,
-0.0004969354,
-0.3639056385,
0.0839948207,
0.0277556255,
0.0992313474,
-0.1218299568,
0.1845412105,
0.1087979227,
-0.1937718838,
-0.3874523342,
-0.0881442502,
-0.333060056,
-0.160057351,
0.1413002014,
0.1926596314,
-0.0470279977,
0.0849905536,
-0.6471931934,
0.2393122613,
-0.0936852172,
0.2038309276,
0.0257514566,
-0.0548233725,
-0.1454124302,
-0.2868354619,
0.0360205546,
0.0736054331,
-0.0433641411,
-0.3077147603,
0.43232584,
-0.2486535609,
0.0101415981,
0.1967360526,
-0.1263927966,
-0.1542361826,
-0.179828003,
0.3444139659,
0.2515200973,
-0.5262076855,
-0.2353117764,
-0.2628825605,
0.0922520459,
0.0186672602,
-0.0661898479,
0.0914241374,
0.3083096445,
-0.2066025138,
0.0431893319,
0.1135393009,
-0.1270745993,
0.0599348657,
-0.2486942112,
-0.1129734591,
0.0301579665,
-0.0714979917,
-0.1197439581,
0.0904578418,
0.1212177351,
0.3055334687,
0.1151338592,
-0.014730609,
0.2339300513,
0.0892549828,
0.4966501594,
0.2424625009,
-0.0086092595,
-0.1921976358,
-0.6642531157,
0.1567051858,
-0.1047262773,
-0.0424640141,
0.1747419536,
-0.4139215052,
-0.0920230374,
-0.0145479459,
-0.2188374996,
-0.1865823269,
0.1649741083,
-0.0974721238,
-0.283870697,
0.2638104856,
-0.2219922394,
0.3030726314,
-0.1150236726,
0.2042955905,
-0.4889190793,
0.2745062709,
0.0521301851,
-0.2878071368,
-0.0966313332,
0.1534575671,
0.252925694,
-0.1000869796,
-0.0471871532,
0.3378113806,
0.1415903568,
0.4005409777,
-0.0384715796,
0.1847768575,
0.2574730515,
-0.0550114289,
-0.1373236477,
-0.1578860432,
0.2083818018,
0.0544476882,
-0.4241551757,
0.3938272893,
0.2695186436,
0.0118457796,
-0.0363378562,
0.0101914182,
0.0239695255,
-0.0016023631,
-0.0232551657,
-0.0479671024,
-0.3201811314,
-0.0297734924,
-0.0300834253,
0.0825167969,
-0.4610884786,
0.3865582645,
0.7573986053,
0.0277050398,
0.2959183753,
0.0880671218,
-0.3444048762,
-0.0797881931,
0.2980594635,
-0.1290376782,
-0.0097085536,
0.1025948301,
0.054090973,
0.0746839866,
-0.0199657232,
0.0432242863,
0.1364462227,
0.1274914891,
0.1322200894,
0.0512944758,
0.2477333993,
-0.0496778525,
-0.5481798649,
0.3959188461,
-0.1041583568,
-0.1394160837,
-0.2124565393,
-0.1445794404,
-0.1493774503,
0.2394797802,
0.0433824621,
-0.0206777658,
-0.4694596827,
-0.3046286106,
0.1097647026,
0.6526200771,
-0.1624806523,
0.118817322,
0.0325635597,
0.4589157701,
-0.0658675805,
-0.0868431926,
-0.2195904106,
-0.1028114036,
-0.2089407295,
0.018884087,
-0.0197733436,
0.1329304874,
0.4304411411,
-0.0312738754,
0.0483644083,
-0.4149526954,
-0.1042110845,
0.176773414,
-0.3377331197,
0.1289494932,
0.1665405482,
-0.0038129336,
-0.1705452353,
-0.0766851008,
0.2470386177,
-0.418202281,
-0.4161801636,
0.0749554709,
0.091058366,
0.0890927464,
-0.0884125903,
-0.2913160622,
-0.0041478225,
-0.4009441137,
0.467582643,
0.0194860976,
-0.0432233959,
-0.0221575201,
-0.2940726578,
0.0625710338,
-0.1647361368,
-0.0370446108,
-0.4541969299,
-0.3463742435,
0.2257575691,
-0.0980381295,
-0.3280848861,
0.1089411154,
0.0499332324,
-0.0484684519,
-0.1841905266,
-0.1113547236,
-0.357747823,
-0.1003805399,
0.4271508157,
0.1114121303,
0.0933501646,
0.4188218713,
0.0709713846,
-0.0560375303,
-0.0517344549,
-0.3323303759,
0.319838196,
0.4999797046,
0.0792775676,
-0.1264845729,
-0.0916919932,
-0.1294682324,
0.0615200959,
0.0050827181,
0.083805196,
0.5025809407,
0.1114787757,
0.4903524816,
-0.3571724594,
-0.1906967163,
0.1450273544,
-0.2710848451,
0.0602223203,
0.2465227842,
0.08472462,
0.19245857,
0.0319926031,
-0.3571422398,
-0.0042263977,
-0.5018234253,
-0.081384331,
0.2057008445,
-0.194452554,
0.0160728768,
-0.0209376886,
-0.036334049,
-0.054920122,
0.3727350235,
0.2607026994,
0.0358474702,
0.1743568778,
-0.5492036939,
-0.0654701293,
-0.5835779309,
0.1223155037,
-0.0186614227,
0.0110722575,
-0.0955588147,
-0.2032249421,
-0.0309997145,
-0.0186784677,
0.6852753162,
-0.1161357984,
0.2077042162,
-0.0087783393,
-0.3186962903,
-0.1730294377,
-0.1069221497,
-0.2178532481,
-0.1997998953,
-0.0719905198,
0.9042119384,
-0.4588038325,
-0.2086031735,
-0.3814492226,
-0.0554411411,
-0.231496349,
0.1915609539,
-0.1203477085,
-0.054670874,
-0.3577777743,
0.0911723822,
0.2419979423,
0.1592374295,
-0.1496082097,
-0.1502491832,
-0.2176727355,
-0.1881301105,
0.0875059143,
-0.0370865576,
0.4882078767,
0.0208344795,
-0.022615362,
0.0267911404,
0.3167560697,
0.0373632535,
0.6090016365,
0.0709036663,
-0.472758621,
0.1314334571,
-0.0341539793,
0.1411218345,
0.2641887367,
-0.0257519241,
0.1184726357,
-0.241635114,
0.1327179819,
-0.557197392,
0.2628572881,
-0.0303732362,
-0.0535567887,
-0.4110828638,
0.1695497036,
0.6166678667,
-0.3026646376,
-0.040229477,
-0.2078995109,
0.7314181328,
-0.4164004624,
0.337618649,
0.2684196234,
0.8262770176,
0.0892645866,
0.3919635713,
-0.0093567725,
-0.1781445295,
0.8271796107,
-0.1324295998,
0.01132946,
-0.3213522136,
-0.0527831428,
0.0022474458,
0.1607661396,
-0.013946359,
-0.142830193,
-0.2486783564,
0.1287599355,
0.0229514297,
0.3532177508,
-0.2913581729,
0.2055194378,
-0.3465154171,
-0.4076622725,
-0.1529924124,
0.1609587967,
-0.1090924218,
0.1554716676,
0.0530058704,
-0.0212233905,
-0.0787126571,
-0.1118321046,
-0.0741119236,
0.0562540367,
-0.0590780377,
0.1289057881,
0.1377787441,
-0.1193539947,
-0.0464194492,
-0.1040634811,
0.6642901897,
0.114056319,
-0.3280995488,
-0.0049088607,
0.0169515535,
0.075999096,
-0.1770872176,
-0.0758616626,
0.3508978784,
-0.0033223468,
0.126668483,
-0.1832412928,
-0.043523591,
-0.1388795525,
-0.218512848,
-0.1238738745,
-0.1201658621,
-0.5096359849,
-0.1316019446,
-0.1002365574,
0.0189455766,
-0.3283109367,
0.081388317,
0.0815693364,
-0.1559603959,
0.036541272,
0.2195965201,
-0.0855117291,
-0.1254959702,
0.1936482787,
0.1147084758,
-0.0693079159,
0.1962487549,
-0.2067267895,
-0.227709502,
-0.1778573543,
0.2700968683,
0.6978928447,
-0.2424560189,
0.3153719008,
-0.0720259026,
-0.4921329319,
-0.1350342184,
0.5250372887,
-0.0512891412,
-0.120640561,
0.0427479856,
-0.073178798,
-0.3829028904,
0.3700289726,
0.0369415022,
0.347137183,
0.245476678,
0.1417266577,
0.0310467668,
0.0398549028,
-0.3247227669,
0.0105449557,
-0.232717678,
0.1673201919,
-0.1151851863,
0.0393894538,
0.1593063325,
-0.2664575279,
0.0813768655,
0.1536742151,
-0.1662419587,
-0.2109243274,
-0.3899339139,
0.1012919769,
0.1512707919,
0.433454752,
-0.1744383723,
0.1454973221,
0.0896018222,
-0.1864095628,
0.3391370475,
0.2430373579,
0.1224934831,
0.1002961248,
0.473672241,
0.2507996857,
0.1492200494,
0.0989581347,
0.1787904203,
-0.0458837301,
-0.1696422994,
-0.069896169,
-0.4250804484,
-0.0223764777,
0.1138150617,
0.2178634107,
0.234177351,
0.2482365668,
-0.076716207,
0.0245441403,
-0.2541311681,
0.0592383184,
0.1663545221,
0.1684214622,
0.0067791264,
-0.2141201496,
0.2997598946,
0.2133422196,
-0.1126715615,
-0.2178344727,
0.3041946888,
-0.2481670529,
0.0503059216,
0.1755008996,
0.2104277611,
0.3987074494,
-0.3618604541,
0.0293658599,
0.4439434707,
-0.0522731654,
0.2423501909,
0.0571683869,
-0.1232949644,
0.1342971772,
0.429241389,
0.2898056209,
0.197835654,
0.2891130447,
0.2025267035,
0.3865195811,
0.1140889302,
0.1640895009,
0.5348469615,
-0.1588223875,
-0.1239684373,
0.0326692723,
-0.1251232624,
0.4107013941,
0.0866546407,
0.2516050041,
-0.3918283582,
-0.622484982,
-0.0891311541,
0.2784034014,
-0.3120987117,
-0.1627754569,
0.2301488519,
-0.0755697936,
-0.0569120198,
0.0250612367,
-0.1263755113,
-0.244930774,
0.162425071,
-0.0248455666,
0.0888869166,
-0.0251149759,
-0.1655044705,
-0.0670542344,
0.2680753171,
0.0137290871,
0.0860919952,
-0.1200207695,
-0.1757436395,
-0.104456231,
0.1203835979,
-0.0623581745,
0.0010767452,
0.0882209763,
0.2489161193,
0.0811857134,
-0.0620771833,
-0.0003032041,
-0.1582996845,
0.1272802949,
0.0177290794,
0.2611200511,
0.2004550993,
-0.0113670714,
-0.0389605425,
-0.1871769279,
0.1011082157,
-0.0306243729,
0.3090937436,
0.0140716275,
-0.1603603214,
-0.1205978021,
-0.0119141731,
-0.0068041226,
-0.1408759803,
0.0339684114,
-0.0675605983,
0.2252761573,
-0.2032569945,
0.1043593213,
0.2045037001,
0.2435318381,
0.0014038767,
-0.4093551636,
-0.1408069432,
0.043494869,
-0.3474693894,
0.1314099729,
0.2150865346,
0.0137446737,
0.2616281509,
0.1900839806,
0.0034270047,
0.0186615381,
-0.1941366494,
0.1911165118,
0.1019796208,
-0.0940745026,
-0.1518428177,
-0.0195782054,
0.0536238514,
-0.1271376908,
0.1229537427,
-0.1165702939,
0.4907313287,
0.2812719345,
-0.0109947082,
0.1593352854,
0.2437497526,
-0.1133152395,
-0.309173733,
0.2493262738,
0.1482830346,
-0.1244507879,
-0.2138340473,
-0.1366233826,
0.1457048804,
-0.1699576974,
-0.3982335031,
-0.2991377711,
-0.3448503315,
0.5003044605,
-0.0288539194,
-0.01827069,
-0.1497079134,
0.3333308101,
0.1879318804,
-0.1453335583,
-0.2359485626,
0.3906552494,
-0.0888977051,
-0.1006141156,
0.1244504005,
0.2655649483,
-0.0824042037,
0.0503389426,
-0.3072282076,
-0.3965739012,
0.6916154623,
0.001346787,
-0.4505903721,
-0.1409483701,
0.2906763554,
0.5809943676,
-0.1734907776,
-0.7488450408,
-0.1952002645,
0.054677505,
-0.1113075614,
-0.2098518312,
0.1879695952,
-0.1773838401,
-0.2350436896,
-0.1803070009,
0.2511641979,
0.2688182592,
0.0089322655,
0.3391692638,
-0.2201094925
] |
https://github.com/huggingface/datasets/issues/3394 | Preserve all feature types when saving a dataset on the Hub with `push_to_hub` | Maybe we can also fix https://github.com/huggingface/datasets/issues/3035 while working on this because, as pointed out in my initial post, `save_to_disk` also saves the `dataset_info.json` file. | Currently, if one of the dataset features is of type `ClassLabel`, saving the dataset with `push_to_hub` and reloading the dataset with `load_dataset` will return the feature of type `Value`. To fix this, we should do something similar to `save_to_disk` (which correctly preserves the types) and not only push the parquet files in `push_to_hub`, but also the dataset `info` (stored in a JSON file). | 24 | Preserve all feature types when saving a dataset on the Hub with `push_to_hub`
Currently, if one of the dataset features is of type `ClassLabel`, saving the dataset with `push_to_hub` and reloading the dataset with `load_dataset` will return the feature of type `Value`. To fix this, we should do something similar to `save_to_disk` (which correctly preserves the types) and not only push the parquet files in `push_to_hub`, but also the dataset `info` (stored in a JSON file).
Maybe we can also fix https://github.com/huggingface/datasets/issues/3035 while working on this because, as pointed out in my initial post, `save_to_disk` also saves the `dataset_info.json` file. | [
-0.3021219969,
-0.2699122429,
0.0240607709,
0.3232356012,
0.3119442165,
-0.0222277734,
0.216617316,
0.3837988377,
0.0547654517,
0.0118870577,
-0.3860481381,
0.4930749834,
-0.0736066401,
0.6211599112,
0.0524834841,
0.0989935249,
0.2516206205,
0.0786844417,
0.1469024569,
-0.1552143693,
-0.2845315337,
0.1313346326,
0.1958052814,
-0.0118042342,
-0.4609073699,
-0.0900078639,
0.1330183446,
0.1588865668,
-0.1387096494,
-0.2946502864,
0.2994624972,
0.1221604943,
0.0259597562,
-0.0027749974,
-0.0001096402,
0.0235098079,
0.2058635056,
-0.2454160601,
-0.1425560564,
-0.1004252434,
-0.1000388339,
-0.0144548323,
0.0570119694,
-0.1327540874,
-0.2366559952,
0.1689709723,
0.0256151315,
0.0871445239,
0.1775969416,
0.0167761724,
0.1536736935,
0.0686940402,
0.0999162197,
-0.0696437582,
0.4291982055,
0.5489186645,
-0.2761165202,
-0.0771488175,
0.0797067508,
0.455209136,
0.0860609189,
0.2028852701,
0.0745363757,
-0.3039910495,
0.311057657,
0.0976023376,
-0.1224925071,
-0.1364274621,
0.080818437,
0.1017004326,
0.2503564656,
-0.4217144847,
-0.3443126082,
-0.3258581758,
-0.1142172813,
-0.358538866,
0.2208531499,
0.1655044407,
0.1118843406,
0.0846944153,
-0.0992591456,
-0.4827114344,
-0.1820760816,
-0.0531470887,
-0.0090019777,
0.085646905,
-0.2151886672,
0.0288307387,
-0.0388921835,
-0.1137348041,
0.0321430676,
-0.2388228476,
-0.1958564073,
-0.1685551107,
-0.0711581483,
-0.282956779,
-0.0570537485,
0.2741911709,
0.3013918996,
0.140533641,
-0.09693975,
0.3932707608,
-0.1745273173,
0.1807375997,
0.4851616025,
-0.0046935002,
0.5186081529,
-0.084241882,
0.4635521173,
0.1100458801,
0.0031558098,
-0.0843005404,
0.2046647221,
0.4838481545,
0.3238301873,
-0.0790376365,
0.4993436038,
-0.3543516695,
0.0449046195,
0.0598376319,
0.3045431674,
0.1307563186,
0.0445533544,
0.3802148402,
0.0740149915,
0.3165448308,
-0.1378919184,
0.3838388026,
0.0046229744,
-0.1476916224,
-0.2837575972,
-0.0596045181,
0.0474168546,
-0.0324731059,
0.2240761966,
-0.2493434548,
0.1294129044,
0.1707197875,
-0.0684115067,
-0.0399487242,
-0.2571166754,
0.0558503345,
0.0322643481,
0.1268102676,
-0.0857912078,
0.2086881548,
0.0428789929,
-0.2128861696,
-0.366512686,
-0.0683534369,
-0.4375589192,
-0.1985497773,
0.1491825432,
0.2027528286,
-0.035767328,
0.0752003416,
-0.7787153721,
0.2497624606,
-0.0412665792,
0.1181547791,
-0.0484817773,
-0.0860254243,
-0.0449130759,
-0.2948029041,
0.0380637795,
-0.0156916082,
-0.116114676,
-0.190041095,
0.3519596159,
-0.1779084653,
0.1000921354,
0.2274989188,
-0.1202971265,
-0.1229247525,
-0.1224252433,
0.3776645958,
0.3595580161,
-0.4797186553,
-0.230379805,
-0.2469897717,
0.1811738908,
-0.0597750805,
-0.0600830428,
0.0558528379,
0.4553662539,
-0.2050821334,
0.0409113616,
0.1694823056,
-0.1595248133,
0.1472106874,
-0.2395473719,
-0.0752897337,
0.0074433181,
0.0260308459,
-0.0298948828,
0.0602631606,
0.1722242534,
0.4010870755,
0.0831672773,
-0.094969362,
0.2542704344,
0.0968859717,
0.4945827425,
0.1361560971,
-0.0089745065,
-0.2442575097,
-0.6467323899,
0.1479001045,
-0.0866682827,
-0.0816989765,
0.1532781273,
-0.3543922305,
-0.1035800651,
-0.0401333347,
-0.1867321879,
-0.0497154519,
0.1730326265,
-0.0727641732,
-0.3480594158,
0.2015602142,
-0.2198511511,
0.2052849531,
-0.1116999164,
0.1646289527,
-0.4485346079,
0.3771288097,
0.081090197,
-0.3532525301,
-0.0300224666,
0.1372882426,
0.2001414001,
-0.1606148332,
-0.0675134882,
0.2811967134,
0.2378723472,
0.4205718338,
0.041635219,
0.2240204513,
0.2690854371,
-0.0991227329,
-0.1164414957,
-0.1270003468,
0.1939643025,
0.0318412744,
-0.4412834346,
0.3626751006,
0.2257051617,
0.0075773811,
-0.0760243684,
-0.0050438349,
0.0949274749,
0.0207550675,
0.0312763602,
0.0032507104,
-0.3247912228,
-0.0188618712,
-0.104916431,
0.0669278055,
-0.4537508488,
0.4237675071,
0.8299555182,
0.0368749574,
0.3571645617,
0.0640422627,
-0.3045714796,
-0.0960531905,
0.2837402225,
-0.0841807947,
-0.0296125058,
0.1303184032,
0.0953416154,
-0.0039497698,
0.0241599046,
0.0572875887,
0.129569754,
0.0909020379,
0.167822957,
0.1514113098,
0.262145102,
-0.0708297193,
-0.5340867043,
0.3884509206,
-0.0006556375,
-0.0307143107,
-0.2139369398,
-0.1953598261,
-0.2379517853,
0.2536943555,
0.0986069962,
0.0026649749,
-0.4698373675,
-0.2989419401,
0.0820365697,
0.6632595062,
-0.2051054239,
0.163427189,
0.0467885062,
0.4383096993,
-0.0240688678,
-0.1281100512,
-0.2210640758,
-0.1703964919,
-0.1506045014,
0.0293333046,
0.1426887065,
0.1662157476,
0.4332897067,
-0.0235263426,
0.0634490773,
-0.4498261511,
-0.1215906218,
0.146858722,
-0.2993963659,
0.171786204,
0.1365855485,
0.0759357065,
-0.1223195195,
-0.0829482824,
0.2224651873,
-0.419065088,
-0.3879160881,
0.124336727,
0.0651327744,
0.003859374,
-0.0458292402,
-0.3939793408,
-0.007222177,
-0.4904206991,
0.3821241856,
0.0202344172,
0.0088172229,
-0.0443278402,
-0.2718421221,
-0.0748297647,
-0.100751251,
-0.0739383921,
-0.4417406321,
-0.3477034867,
0.2454003096,
-0.1362164319,
-0.3047369123,
0.0974601358,
0.0962620899,
-0.0609889328,
-0.07838846,
-0.0728864968,
-0.3672953844,
-0.0566798262,
0.3749770522,
0.1282463819,
0.1047851667,
0.4164513648,
0.0444286317,
-0.0554318614,
-0.0518967919,
-0.3737258613,
0.2969402969,
0.5758755803,
0.1096876189,
-0.0704133585,
-0.0534928031,
-0.1432965398,
0.1589552313,
0.0528848171,
0.0844001025,
0.5121853352,
0.1273334324,
0.4730950296,
-0.3484996855,
-0.153177768,
0.1249426007,
-0.2159375399,
0.0611589663,
0.2427039742,
0.0685405433,
0.0225430373,
0.0826745257,
-0.353323698,
-0.076459825,
-0.515745461,
-0.0302115995,
0.147247836,
-0.1766505986,
-0.0013271184,
-0.0155042903,
-0.0898858979,
-0.051792156,
0.3724217415,
0.2672953606,
-0.0364362635,
0.1550729424,
-0.5637886524,
-0.0790365487,
-0.5350404978,
0.096996367,
-0.075514175,
0.0818287432,
-0.1486019194,
-0.16154176,
-0.0617461912,
-0.0288035311,
0.6521588564,
-0.3156377077,
0.188875556,
0.0080655478,
-0.234330073,
-0.1282976866,
-0.1042894945,
-0.2199191749,
-0.14208211,
-0.0957757086,
0.8305382133,
-0.5269436836,
-0.2245795876,
-0.3632258773,
-0.0392330103,
-0.1660636067,
0.210733071,
-0.0267455373,
-0.0244251955,
-0.3431817293,
0.120162122,
0.2265259027,
0.1253321767,
-0.1366758645,
-0.2064959854,
-0.2582205832,
-0.1350330412,
0.0693696216,
-0.0170922577,
0.5429313779,
0.065408349,
-0.0219880696,
-0.0996568948,
0.2952557802,
0.1064602211,
0.6022058725,
0.083651565,
-0.4687982798,
0.166995883,
-0.0941178575,
0.1153051406,
0.2347995639,
-0.0016881588,
0.0780714005,
-0.2675597072,
0.0899666622,
-0.4905091226,
0.2885403931,
-0.0347913466,
-0.0321706347,
-0.4352105558,
0.1291777939,
0.5814301968,
-0.2963877022,
-0.0293842293,
-0.0962254032,
0.5557965636,
-0.4526546299,
0.3847350776,
0.2519129515,
0.7695953846,
0.0624934211,
0.2936181128,
-0.0534780547,
-0.1928806007,
0.7244348526,
-0.2288086563,
-0.0154199051,
-0.3891510665,
-0.086630486,
-0.0203133076,
0.1352953166,
-0.0482056327,
-0.1430905908,
-0.2550613284,
0.1522553414,
0.025712857,
0.3853259385,
-0.3246714771,
0.2395915538,
-0.2671677172,
-0.4265402853,
-0.1974276751,
0.1709969342,
-0.1561998725,
0.0527879223,
0.0584761277,
-0.1095701829,
-0.1205179766,
-0.0222451426,
-0.1586898118,
0.0817068145,
0.0566298813,
0.119720161,
0.0923355371,
-0.1369622052,
-0.0172296911,
-0.1430480331,
0.7171983719,
0.1484776735,
-0.3228471875,
-0.0214376021,
-0.0289959796,
0.0882544369,
-0.1163722798,
-0.1300288588,
0.3904704452,
-0.0278454367,
0.1055162176,
-0.1887374371,
-0.0640522912,
-0.1675051153,
-0.2209910452,
-0.179700464,
-0.1002793387,
-0.4792946875,
-0.1069324762,
-0.0741435364,
-0.0410457887,
-0.3374803662,
0.0955584422,
0.1154550985,
-0.1456882209,
0.1494862884,
0.1858069301,
-0.0275319088,
-0.0873452127,
0.1219029278,
0.1570639163,
0.0158593636,
0.1789122373,
-0.1613012701,
-0.2004016042,
-0.2367044091,
0.2703451216,
0.6755443215,
-0.2217987031,
0.3478247523,
-0.1536479443,
-0.4952473044,
-0.0620180629,
0.4634242654,
-0.0463849939,
-0.0780940279,
0.0369537473,
-0.1231158078,
-0.3252981305,
0.3804164827,
-0.0104683926,
0.3959216774,
0.2032438219,
0.0289528891,
-0.0076072146,
0.0369981043,
-0.3285310268,
0.0179285984,
-0.2756712437,
0.2472362518,
-0.1525498182,
-0.0133041926,
0.0913254693,
-0.3427309096,
0.0755998194,
0.0365965143,
-0.2540315986,
-0.2160342038,
-0.3146542013,
0.1045237482,
0.1410491019,
0.4969579875,
-0.1348832399,
0.0890412331,
0.0203335844,
-0.2267125994,
0.2741123736,
0.1381804943,
0.0772755146,
0.0684713423,
0.5517528057,
0.1994632185,
0.1482594907,
0.1786965728,
0.2068146467,
-0.0826711655,
-0.2368639708,
-0.005968126,
-0.3423645198,
-0.0578326844,
0.0678011328,
0.2048949301,
0.2354164571,
0.2797119021,
0.0635442659,
-0.0260669719,
-0.2278250158,
0.2205008715,
0.192337364,
0.1987867355,
0.0279199686,
-0.1306727231,
0.2495600581,
0.233223632,
-0.0969059542,
-0.2776758671,
0.3788425326,
-0.1857986897,
0.0271157641,
0.1568405479,
0.2995012403,
0.3721229434,
-0.3213810623,
0.0618419796,
0.447111547,
-0.1595705003,
0.318333149,
0.019963704,
-0.1382768303,
0.1032026932,
0.3836320043,
0.2407319397,
0.1231910959,
0.3311445713,
0.2247699052,
0.3684836626,
0.2435544729,
0.0625007525,
0.4920863211,
-0.1649104506,
-0.0925268605,
0.0102510322,
-0.0573554449,
0.4132175446,
0.1463534236,
0.2425757796,
-0.3140493333,
-0.6604781747,
-0.1572565138,
0.2162668258,
-0.2956420183,
-0.1159167513,
0.1006659642,
-0.1099053472,
-0.0167198256,
0.0046724076,
-0.1616666615,
-0.2048391998,
0.1102007627,
0.0210715123,
0.0889402181,
-0.0657047108,
-0.0747412965,
-0.0337214097,
0.2008379549,
0.0176387224,
0.1780669689,
-0.2045028359,
-0.2218186557,
-0.1313159764,
0.1474146992,
0.0119576789,
0.069671087,
0.0480425656,
0.1906738877,
0.1651554853,
-0.086356692,
0.0372363143,
-0.1579999626,
0.0963206813,
-0.0065022828,
0.2486468703,
0.2090412974,
-0.0019381408,
-0.0680064037,
-0.2110189497,
-0.0415429398,
0.0551113747,
0.3058764338,
0.1408124864,
-0.1976788938,
-0.0900802016,
-0.0826270878,
-0.0451372713,
-0.1976488382,
0.0999262556,
-0.0514395125,
0.228256762,
-0.178381905,
0.1113648862,
0.1229790822,
0.2879581153,
-0.0544637218,
-0.4405426979,
-0.1590616107,
0.0862204805,
-0.3448076248,
0.1460205764,
0.1924574524,
0.0218757689,
0.2792187333,
0.2511467338,
0.0917789638,
0.0270705055,
-0.1837421656,
0.1223015636,
0.1524252743,
0.0046090791,
-0.288538903,
0.0355342776,
0.1733711958,
-0.0860937983,
0.0607696474,
-0.1730927527,
0.4783822,
0.2674821019,
-0.0190673489,
0.1995560825,
0.2429147065,
-0.0847196802,
-0.4204113781,
0.2551088035,
0.1241905168,
-0.0252584107,
-0.2428986728,
-0.0365356505,
0.0326094367,
-0.299661696,
-0.4028061926,
-0.2263867408,
-0.2977371514,
0.5404521823,
-0.0527994335,
0.0059060985,
-0.2090690434,
0.2456273288,
0.1007377431,
-0.0344541855,
-0.1938952655,
0.3659701049,
-0.067173548,
-0.0635841638,
0.1243954003,
0.1522598118,
-0.0899929702,
0.0410276242,
-0.3201220036,
-0.4667931497,
0.616420567,
0.0368728451,
-0.5004857183,
-0.1327006072,
0.3070594966,
0.5914341807,
-0.0648199171,
-0.6515520215,
-0.1566549093,
0.0771539733,
-0.1705174446,
-0.1871693879,
0.2061386704,
-0.1317409128,
-0.1498599797,
-0.2031775266,
0.1771515757,
0.1998264641,
-0.1229837239,
0.2600868046,
-0.2254264355
] |
https://github.com/huggingface/datasets/issues/3392 | Dataset viewer issue for `dansbecker/hackernews_hiring_posts` | This issue was fixed by me calling `all_datasets.push_to_hub("hackernews_hiring_posts")`.
The previous problems were from calling `all_datasets.save_to_disk` and then pushing with `my_repo.git_add` and `my_repo.push_to_hub`.
| ## Dataset viewer issue for `dansbecker/hackernews_hiring_posts`
**Link:** https://huggingface.co/datasets/dansbecker/hackernews_hiring_posts
*short description of the issue*
Dataset preview not showing for uploaded DatasetDict. See https://discuss.huggingface.co/t/dataset-preview-not-showing-for-uploaded-datasetdict/12603
Am I the one who added this dataset ?
No -> @dansbecker | 22 | Dataset viewer issue for `dansbecker/hackernews_hiring_posts`
## Dataset viewer issue for `dansbecker/hackernews_hiring_posts`
**Link:** https://huggingface.co/datasets/dansbecker/hackernews_hiring_posts
*short description of the issue*
Dataset preview not showing for uploaded DatasetDict. See https://discuss.huggingface.co/t/dataset-preview-not-showing-for-uploaded-datasetdict/12603
Am I the one who added this dataset ?
No -> @dansbecker
This issue was fixed by me calling `all_datasets.push_to_hub("hackernews_hiring_posts")`.
The previous problems were from calling `all_datasets.save_to_disk` and then pushing with `my_repo.git_add` and `my_repo.push_to_hub`.
| [
-0.5134432912,
0.1532768458,
0.0064593675,
0.237880677,
0.0082575986,
0.0074706464,
0.2240114957,
0.32554093,
0.0523446687,
0.0919944271,
-0.0460804813,
0.3024221957,
-0.0253489986,
0.0762419403,
0.1139024124,
0.2501677871,
0.1825874299,
0.0068217758,
-0.168663919,
0.0667678714,
-0.0422957204,
0.0518775247,
-0.1205208972,
-0.0830808952,
-0.2230530679,
0.0443047434,
-0.0318339877,
0.0183768366,
-0.1017856225,
-0.3942713439,
0.349347502,
0.3863319755,
0.2144286036,
0.5339847207,
-0.00011252,
0.2463618964,
0.3110194206,
0.0796536282,
-0.471663326,
-0.3088158071,
-0.0915644839,
-0.4195661843,
0.1730878949,
-0.0914183781,
-0.3157420158,
-0.1641460806,
0.196663335,
-0.1017118841,
0.2552103996,
0.1723328084,
0.2406387031,
0.3618880212,
0.1469937265,
-0.2920434773,
-0.0442587435,
0.4592666626,
-0.3457598388,
0.115242973,
0.2274986058,
0.4340046942,
-0.0704493225,
0.3127884567,
0.152811408,
0.1041293293,
0.1301849782,
-0.0767650753,
-0.046088174,
-0.2675954401,
0.2284382135,
0.0658423603,
0.5412909389,
-0.1817335784,
-0.3430239558,
-0.362688452,
0.1792243123,
0.0897168145,
0.2097247392,
0.0055899415,
-0.110988453,
0.1277406961,
-0.2710935473,
-0.2650224566,
-0.0846698359,
0.1659499109,
-0.0156149911,
0.0970994011,
-0.3134592175,
0.0674095973,
-0.006968298,
-0.1468907297,
0.3378965557,
-0.1861063987,
-0.2004931122,
0.0779235289,
-0.1873691976,
-0.1042847186,
0.1155036762,
-0.1014248133,
0.0415874347,
0.1351523548,
-0.0398218147,
0.2689172029,
-0.0568655618,
-0.0608489029,
0.3307766914,
0.0487919264,
0.3176581264,
0.598541379,
0.434368819,
0.2248886675,
0.2209426761,
0.0125492923,
-0.2219065279,
-0.1415922642,
-0.2046155035,
-0.3607593179,
0.6048567891,
-0.2585218549,
-0.3036932647,
-0.0370561592,
0.0910746902,
-0.1715989709,
-0.0463014022,
0.3527898192,
-0.1322841942,
-0.2218678296,
-0.101767011,
0.4049354494,
-0.2368853837,
-0.1758903563,
-0.2884771228,
-0.256865859,
0.0648079738,
0.0494939275,
0.330305934,
-0.3322459459,
0.1379348189,
0.0180544201,
0.0571629293,
-0.1875558197,
-0.1014572158,
0.095290117,
-0.3499333858,
0.1454809308,
0.0908080637,
0.3295706809,
0.1161532253,
-0.3071195781,
0.1224789023,
0.3039858937,
-0.1540760994,
-0.1981234699,
-0.3435339332,
0.1412562281,
-0.5179545879,
-0.0746821314,
-0.5573969483,
0.3335939348,
-0.1253086776,
0.0440363027,
-0.1504086554,
-0.033373598,
-0.0479944795,
-0.0378900021,
0.3036348224,
0.5026234984,
-0.2498508543,
-0.2646943331,
-0.2100679576,
-0.3339935243,
0.0981071517,
0.0218383949,
-0.1727956384,
0.1070407778,
-0.3671718836,
-0.0634903461,
0.2897714376,
-0.2998133898,
-0.5156722665,
0.1981507391,
-0.0819064677,
0.3340154588,
-0.0459681116,
-0.0287433397,
0.0637425482,
-0.2635778189,
-0.389438808,
-0.1178527474,
0.3101977408,
0.0378599614,
-0.217209205,
-0.007154318,
0.0265503898,
0.28318277,
0.1441987753,
0.1149718389,
0.0830326453,
-0.0693072602,
0.2359769791,
0.1113662869,
0.1688342392,
-0.0407605954,
0.1082908809,
0.1981975287,
0.0385611691,
-0.1539905965,
-0.457031548,
0.2164195925,
0.039820835,
-0.0180415437,
-0.1362156272,
-0.2080819905,
-0.3114708364,
0.0615369417,
-0.4371368885,
-0.3112855256,
0.1740847975,
0.1617030203,
-0.2483762205,
0.2363282442,
0.0036451425,
0.1294957995,
-0.2237323374,
0.1356389523,
-0.0726360232,
0.3759024143,
0.047735814,
-0.0940211266,
-0.0009145521,
0.1136805117,
0.2198604941,
-0.1135167629,
-0.0727112368,
0.2322722226,
-0.1917593181,
0.4014608264,
0.4446038008,
-0.2151561379,
0.2804209888,
-0.3628669679,
0.0874268413,
-0.072597079,
-0.0648497343,
-0.1092317179,
-0.2952916622,
-0.0419406518,
-0.0588083453,
0.0133457016,
-0.221728906,
0.0103170797,
0.1205928251,
0.1086802408,
0.064662993,
-0.0345036834,
0.2263396978,
0.1207541972,
0.3179354072,
-0.1235942617,
-0.2778166831,
0.2446999103,
-0.0376968607,
-0.0087135676,
0.0870497003,
0.1905183792,
-0.3116271198,
0.0887726471,
0.0503789596,
0.1704162359,
0.2224986702,
0.019683091,
0.1643184721,
0.030218916,
0.2023887932,
-0.2176037878,
0.049860619,
0.1202327162,
-0.1399099678,
0.1383806318,
0.1246846095,
-0.0526971295,
-0.3597392738,
0.2919618785,
0.128808856,
0.2803258002,
-0.3035094142,
-0.2007831484,
-0.1788473725,
-0.2863942683,
-0.1101964042,
-0.0878130719,
-0.2583272457,
-0.3144355416,
0.070171617,
0.2318620533,
-0.1136247218,
0.2179689109,
0.0179143362,
0.3506782353,
-0.1095706522,
0.2958512604,
-0.1597974151,
0.1199641824,
-0.1579503119,
0.1464786381,
0.4705760777,
0.0408747196,
0.2913865745,
-0.0129243368,
0.2725557685,
-0.6202504039,
-0.2591623366,
-0.0486980416,
-0.0308895558,
0.5329671502,
-0.2639760077,
0.2136449218,
-0.0627613366,
0.0118317464,
0.2037848979,
0.0141303362,
-0.1589650661,
-0.0815250501,
-0.0055819163,
-0.0794518217,
0.1093143225,
-0.0731701925,
-0.3034719229,
-0.4439843297,
0.364143163,
0.1084310934,
-0.0841874778,
0.0759948567,
-0.0388637595,
-0.036807593,
0.144542411,
-0.0914549157,
-0.2531934679,
-0.4080030918,
0.4086261094,
-0.3934935033,
-0.4622139931,
0.2021652311,
0.2661654353,
-0.1218632832,
-0.2436641306,
-0.7571806908,
0.2925320566,
-0.1261766106,
0.1556652337,
0.2431792021,
-0.2694512606,
0.2703243494,
-0.1115141958,
0.0113428151,
-0.091201596,
-0.2842428386,
-0.0201309677,
-0.2795224488,
0.0539323054,
-0.1151149049,
-0.0618399307,
0.0329491496,
0.7642991543,
0.4535119534,
0.1759280711,
0.0901762992,
-0.080136016,
0.5892639756,
-0.010893167,
-0.4424790144,
0.1184155867,
0.0075175269,
0.1977319568,
0.3139531612,
0.2276069671,
-0.0010173756,
-0.1893001348,
-0.1584363729,
-0.357961297,
-0.2400812358,
-0.0460163504,
-0.3475387394,
-0.0780128762,
0.051076293,
0.2204984874,
-0.1819261909,
-0.4146892428,
-0.1805631965,
0.4170045257,
0.2583486438,
-0.0251104999,
-0.3483348787,
0.1399399191,
-0.5773434043,
0.2232341766,
-0.3214511275,
0.1217111275,
-0.1708185375,
-0.0313766338,
0.2937101126,
0.0425760224,
0.6171023846,
-0.0527642071,
-0.0352860726,
0.0018000044,
-0.3198745549,
-0.2456108034,
-0.133119747,
-0.0191469733,
0.3056258261,
-0.0712086782,
0.3266940415,
-0.1171519905,
0.0144088147,
0.4349011481,
-0.4206997752,
-0.0725338459,
-0.372765094,
-0.0526578464,
-0.0624166466,
-0.1154179722,
-0.0830829963,
-0.0833183303,
0.0128380777,
-0.1637095213,
-0.0455163829,
-0.1444641352,
0.0069243931,
0.0663497075,
0.0402675979,
0.1518831551,
0.2429011464,
0.384455651,
0.7008093596,
0.1675852239,
0.5272551179,
0.5969077349,
0.1934719533,
-0.4006477594,
0.2737547457,
-0.3076292872,
-0.036412362,
0.4369071126,
-0.0417658016,
0.0472928695,
0.0539080538,
0.1606185734,
-0.4965453446,
0.0525148809,
0.3994096816,
-0.0333623551,
-0.3819076419,
-0.3128853738,
0.4427221715,
-0.0817960128,
-0.0552896261,
0.3032048941,
-0.0025652908,
-0.1407575905,
-0.1156625673,
-0.2622473538,
0.7797161937,
0.0959555283,
-0.0917594209,
0.1592037976,
-0.2129517496,
0.4623513222,
-0.1148922145,
-0.0632221103,
-0.1167061031,
-0.4055911601,
-0.0176242981,
-0.1050879881,
0.2750587463,
0.0059183273,
-0.1506405026,
-0.1518358886,
0.1464926153,
0.1955267787,
-0.0138269719,
0.1975876391,
-0.1954609454,
0.048367016,
-0.0565839298,
0.1978217065,
-0.2278061211,
0.4033167958,
0.0419708528,
-0.0646951869,
-0.2720795572,
0.0368167795,
-0.6502905488,
0.1016663536,
0.1976998299,
0.1102077812,
0.1908035278,
-0.4118490219,
0.3968574703,
0.3403019607,
0.2414786518,
0.014711502,
-0.3163852096,
0.4104367197,
-0.0355153345,
0.109986946,
-0.0780238658,
-0.0115502421,
0.1593490243,
-0.169046253,
-0.1614037305,
0.0709079206,
0.0744353458,
-0.2691850662,
-0.5768893957,
0.1271324009,
0.2228667736,
-0.274810493,
-0.046671126,
-0.0761530325,
0.06358587,
-0.2983004153,
0.1635194123,
0.1156211868,
0.0652266741,
-0.123589538,
0.0847893357,
-0.2158940136,
-0.14547728,
0.5096850395,
0.1280657947,
-0.5131474137,
0.5700636506,
0.1550991237,
-0.2712846696,
-0.1244672984,
0.2544929385,
0.1502299458,
-0.2350037992,
0.0084035145,
-0.1289012581,
0.3003196716,
0.0798710957,
0.1375077814,
0.0931592062,
-0.2896893024,
-0.1435948759,
-0.3914891481,
-0.0215683188,
0.0016172727,
-0.0586182252,
0.3940120041,
-0.105933331,
0.0101342835,
0.1382175535,
0.3049601316,
-0.2801579535,
0.0737662613,
-0.0777453855,
-0.0804769322,
0.0026703051,
0.130114615,
0.141686812,
-0.254188329,
0.0761584789,
0.1667779088,
-0.2317573726,
-0.2120046169,
0.0339141376,
0.1473062038,
-0.0076827016,
-0.1907657534,
-0.115714252,
0.0680672675,
0.1082105786,
0.0539052933,
0.1859547943,
0.1053383946,
-0.025186114,
-0.1259886622,
0.5206232071,
0.0843573287,
0.1960934103,
0.1897350997,
0.1494040042,
0.4189546704,
0.0598743521,
0.1890476197,
-0.1040723324,
0.0391044542,
-0.1146771684,
0.0475897901,
0.0970848277,
0.3868695498,
0.1960267276,
-0.5128986835,
0.1826483458,
0.1187832728,
0.358946085,
0.2542522252,
-0.315449357,
-0.1106908023,
0.2053561658,
0.156159699,
-0.186657235,
0.079996936,
0.5574002266,
-0.0026116443,
0.0100606056,
-0.12500076,
0.012584216,
0.1582139581,
0.1078936085,
0.2559461594,
0.386270225,
-0.1551227719,
0.4457404613,
0.1025889739,
-0.2402578443,
0.0044060978,
0.1383187622,
0.1613081992,
-0.2469700724,
0.5724058151,
-0.004804885,
0.2909676731,
0.0234112516,
0.1909276843,
0.2239608169,
-0.4956777096,
0.1941001266,
0.1986241043,
-0.3189112544,
0.0229319483,
0.0396019705,
0.2546150088,
-0.2710961401,
-0.053756088,
-0.3555570543,
0.0346298516,
-0.2021001279,
0.1470209807,
-0.2767391801,
-0.2716538608,
-0.1530427635,
-0.0693485811,
-0.1675555408,
-0.3469290435,
-0.151655823,
0.0506094918,
-0.4584881067,
-0.235305652,
0.1872981638,
-0.2332421988,
0.1466992497,
-0.0994786248,
0.2762686908,
0.0560090989,
0.1159030646,
0.2780543566,
0.5455619097,
0.3651350141,
0.220450893,
0.2653032541,
0.0719561875,
-0.0109376172,
-0.1360262781,
0.082981579,
0.3162219226,
0.0969629064,
0.148855716,
0.2168899029,
0.1849048734,
-0.1319029331,
0.1179804802,
0.1876214147,
0.3677597344,
-0.3608936369,
0.1742830127,
-0.5624168515,
-0.0958791003,
0.0395596214,
-0.378449887,
-0.163143754,
-0.1361797452,
0.2119180411,
-0.2283607125,
0.0027837928,
-0.4028416872,
0.0971779302,
0.103415288,
0.4426827133,
0.2801666558,
0.0384272709,
-0.0690183342,
-0.3417201638,
-0.5360904336,
0.332395643,
0.0184705798,
0.1317507923,
0.0839429498,
0.0603357404,
-0.0556179248,
0.1981552243,
0.2724769413,
-0.0151423281,
-0.0165263955,
0.1858405322,
-0.2500795126,
-0.0073956237,
0.1177546456,
-0.0085309586,
-0.0468910858,
-0.0309513118,
0.4102710783,
0.0520577021,
-0.040624097,
0.2243994772,
0.0901968777,
0.0428983122,
-0.1758091301,
0.2154528797,
-0.118359983,
0.5262190104,
0.0759504512,
-0.0422608182,
-0.2967622876,
-0.4381701052,
-0.1727834344,
0.4215360582,
-0.0333983637,
0.4386766851,
-0.1764597148,
-0.3194533885,
-0.0578464642,
0.0632636771,
-0.1258139908,
0.0023661186,
-0.1220350415,
-0.1832944602,
-0.1053517014,
-0.0101862112,
0.2992933691,
0.0695976242,
-0.0171312597,
0.002394699,
-0.2000436336,
-0.2487394959,
0.2822033763,
-0.4662741125,
-0.0067323339,
-0.200057596,
-0.0030405738,
-0.053211417,
-0.2003414482,
-0.4542434514,
0.0892756954,
0.505733788,
-0.1174283326,
0.3472856581,
0.3145829737,
-0.1876456738,
0.0321530961,
-0.0939312875,
0.6974712014,
-0.0152036389,
-0.1802859455,
0.2915851176,
-0.2546996772
] |
https://github.com/huggingface/datasets/issues/3385 | None batched `with_transform`, `set_transform` | Hi ! Thanks for the suggestion :)
It makes sense to me, and it can surely be implemented by wrapping the user's function to make it a batched function. However I'm not a big fan of the inconsistency it would create with `map`: `with_transform` is batched by default while `map` isn't.
Is there something you would like to contribute ? I can give you some pointers if you want | **Is your feature request related to a problem? Please describe.**
A `torch.utils.data.Dataset.__getitem__` operates on a single example.
But 🤗 `Datasets.with_transform` doesn't seem to allow non-batched transform.
**Describe the solution you'd like**
Have a `batched=True` argument in `Datasets.with_transform`
**Describe alternatives you've considered**
* Convert a non-batched transform function to batched one myself.
* Wrap a 🤗 Dataset with torch Dataset, and add a `__getitem__`. 🙄
* Have `lazy=False` in `Dataset.map`, and returns a `LazyDataset` if `lazy=True`. This way the same `map` interface can be used, and existing code can be updated with one argument change. | 69 | None batched `with_transform`, `set_transform`
**Is your feature request related to a problem? Please describe.**
A `torch.utils.data.Dataset.__getitem__` operates on a single example.
But 🤗 `Datasets.with_transform` doesn't seem to allow non-batched transform.
**Describe the solution you'd like**
Have a `batched=True` argument in `Datasets.with_transform`
**Describe alternatives you've considered**
* Convert a non-batched transform function to batched one myself.
* Wrap a 🤗 Dataset with torch Dataset, and add a `__getitem__`. 🙄
* Have `lazy=False` in `Dataset.map`, and returns a `LazyDataset` if `lazy=True`. This way the same `map` interface can be used, and existing code can be updated with one argument change.
Hi ! Thanks for the suggestion :)
It makes sense to me, and it can surely be implemented by wrapping the user's function to make it a batched function. However I'm not a big fan of the inconsistency it would create with `map`: `with_transform` is batched by default while `map` isn't.
Is there something you would like to contribute ? I can give you some pointers if you want | [
-0.4295309484,
-0.3341989815,
-0.0814519078,
-0.2455640137,
0.1934489012,
-0.1620332301,
0.4565648735,
0.3031438887,
-0.0238189008,
0.0276807845,
0.0125372317,
0.5297407508,
-0.3673674166,
-0.2638860345,
-0.0991920158,
-0.0699826404,
0.1374474168,
0.0499798283,
-0.4633925259,
-0.0764294863,
-0.3802564144,
-0.1904473603,
-0.2393957525,
-0.1123950779,
0.0126792807,
-0.1958007067,
-0.1389263421,
-0.1522669494,
0.1678047478,
-0.1960270405,
0.2733937502,
0.262383163,
-0.0144351851,
0.4168480039,
-0.0001066913,
-0.0544729978,
0.1236177236,
-0.2256817371,
-0.2336465567,
-0.1647460312,
-0.0177983884,
-0.3054965734,
-0.1070252359,
-0.3700152934,
-0.2421942949,
-0.2396649718,
0.2478492558,
-0.5049322248,
0.2980462611,
0.1606941819,
0.2246578932,
0.14390634,
-0.4014176726,
-0.2371461391,
0.0918340012,
0.3026862442,
-0.0424357466,
-0.1151708737,
0.5453515053,
0.1850635558,
-0.1723394245,
0.1999798268,
-0.2845879197,
-0.1904656738,
0.4325425923,
-0.1019883156,
-0.3055570424,
-0.2149671614,
-0.1268892586,
0.1612449437,
0.1534521878,
-0.2125787139,
-0.3796202838,
-0.3815789521,
-0.071725823,
0.1431244761,
0.0254429299,
0.0686387941,
-0.1592762023,
0.0632736683,
-0.4808791876,
-0.1308428794,
-0.0340295248,
0.1372063011,
0.1465457529,
0.1580420882,
0.1547507048,
0.1549515575,
-0.0648291185,
-0.2293777317,
0.3853507638,
-0.0920636132,
0.0414448492,
0.3409327865,
-0.1196423694,
-0.0838600919,
0.1498833001,
0.0633559898,
0.3009599447,
0.1560037881,
0.087764971,
0.1310124099,
-0.0693630278,
0.086117506,
0.1179854423,
0.1199110374,
0.0682935193,
0.1757200062,
0.2662370205,
-0.2950572371,
0.1473175436,
0.1002612412,
0.1129603982,
-0.2193233222,
0.0158805773,
0.4368096888,
0.0866695493,
0.1666382104,
0.1539117843,
-0.5068204403,
0.2270816565,
-0.1005715504,
-0.1006754488,
0.4478546381,
0.0012474073,
0.1376152486,
0.2117703855,
-0.0171848591,
0.100616686,
-0.2318035215,
-0.0548583828,
-0.0922171846,
-0.2538592815,
-0.1653735042,
0.1696297973,
-0.0837124363,
0.1017803028,
0.1972128153,
-0.0962357968,
0.5433043838,
0.0516948514,
-0.2406348139,
0.5913308263,
-0.1083202139,
-0.0285711884,
0.1231154129,
0.129015699,
0.3656333387,
-0.3838834167,
0.338070333,
-0.2961191535,
-0.3063691556,
0.0760193989,
0.2178753465,
-0.1889041811,
0.0110161146,
-0.0759303197,
0.4268781841,
0.0830701515,
-0.1984636635,
0.2281820774,
-0.1215330958,
-0.0482346602,
-0.370662123,
-0.0050230259,
0.1821224093,
-0.2469235361,
-0.2769733369,
0.1671147346,
0.024016615,
-0.0637625232,
0.1491277665,
-0.3413161635,
0.1516078264,
-0.3233616948,
-0.0762754455,
0.5477129817,
-0.2108472884,
-0.1900514662,
-0.0101645561,
-0.0331839398,
0.0463751368,
0.2119169235,
0.1362176389,
0.4624435902,
-0.1762457788,
0.1542164832,
0.454443723,
-0.1316973865,
0.1673408747,
-0.057887692,
-0.390211612,
0.3227296472,
-0.066222474,
0.1516488194,
0.1754954755,
-0.0188082922,
-0.2379899174,
0.106901221,
-0.250773102,
0.1457651854,
0.021708075,
0.0676358938,
0.000037434,
-0.0183494575,
-0.104692854,
-0.5269610882,
0.1604917496,
0.0290469043,
-0.0993728042,
0.0457371138,
-0.3848358095,
0.2950692475,
-0.1539652348,
0.0375680812,
-0.1164778471,
0.1132297367,
0.0926338807,
-0.1790140569,
-0.2803538442,
-0.2145878375,
0.0099569941,
0.2337258607,
-0.1231432706,
-0.2837449908,
-0.1269954592,
0.149339065,
-0.3268161416,
-0.0581509694,
-0.1179370955,
0.2090755403,
-0.1946780831,
-0.0604291111,
0.2512240112,
-0.3445850611,
0.1778666079,
-0.298896879,
0.2619149983,
0.0383604951,
0.0290078744,
0.0710240975,
0.212202251,
0.0565658323,
-0.1034138054,
-0.6068916321,
0.6915948391,
0.1310405582,
0.3854437172,
-0.0198487472,
0.1154165193,
0.1684184968,
-0.2171197683,
-0.231724143,
-0.1969275326,
0.0065055154,
-0.0076109688,
0.1353652477,
0.0243962556,
-0.2481582314,
0.0962917656,
0.3899378479,
0.2600323856,
0.3142810464,
0.0358921364,
-0.0728938282,
0.005185937,
0.1200710237,
-0.2791883051,
0.5108342171,
0.4331842065,
-0.0325588249,
-0.1744401902,
0.5095744133,
0.0658602715,
0.241051659,
-0.1430619955,
-0.0918446779,
-0.0379651338,
0.2860427499,
-0.0091997683,
-0.0498206243,
-0.3717618287,
0.0286338925,
-0.1775727868,
-0.236174494,
-0.105899699,
-0.0966946855,
-0.02753211,
-0.2932404876,
0.0006646066,
-0.0468889661,
-0.1724777967,
0.114242509,
0.1438524425,
-0.2768304944,
0.5391347408,
0.0271422658,
0.3953766227,
-0.0188014153,
-0.3674989045,
-0.2827231288,
-0.0259770509,
0.0096543618,
0.1117047071,
-0.1805239469,
-0.3304965496,
0.482363075,
0.2049895823,
0.1176287606,
-0.3233047426,
0.0385143496,
0.0905329585,
-0.0307605807,
0.1209547594,
0.449572891,
0.0440399721,
0.3104957342,
-0.2433035374,
0.2382214516,
-0.3568540215,
0.0491784662,
-0.2768251002,
-0.1034762561,
0.1847540289,
-0.2121962905,
-0.1886854917,
-0.1300261915,
-0.544246912,
0.1391835213,
-0.2292751968,
0.2141584903,
-0.1276090294,
0.1842341274,
-0.0654794201,
0.1506121159,
0.0537522659,
0.0649677888,
-0.2952639759,
0.4660152197,
-0.2486337423,
-0.1335112751,
-0.2413093448,
-0.1653721184,
-0.2063158154,
0.5592970848,
-0.0190302897,
-0.0011177292,
-0.1168074533,
0.5583901405,
-0.1197689027,
0.1748388857,
0.3325070739,
0.1829001755,
-0.2059948146,
-0.2500990629,
-0.0403211676,
0.0152639002,
0.0505034551,
0.0752846152,
0.3420202434,
0.2642489076,
0.2524828315,
0.9602746964,
0.054251954,
-0.387970835,
0.0052882354,
-0.070847556,
0.159617424,
0.0617281683,
-0.5357180834,
-0.0116963228,
0.0166133828,
0.1580426693,
0.1620187908,
-0.1345437765,
-0.267346859,
-0.0121490126,
-0.3229475319,
-0.1806497574,
-0.1948104501,
0.5020338297,
-0.3759875894,
0.2039045841,
-0.1977424622,
0.1863174438,
-0.4251639247,
0.0348313674,
0.1685700566,
-0.10828951,
0.3462987542,
-0.0815924332,
-0.0064514568,
0.0935241133,
-0.2790901065,
0.3911322355,
0.0274938792,
0.1993332654,
-0.0392235219,
-0.1675198525,
-0.0971021578,
0.0387348309,
0.8057715297,
-0.2251293957,
-0.0793792456,
0.0590522215,
-0.1777013093,
-0.3262525499,
-0.0120633198,
-0.0288532097,
0.1488981396,
0.2653260529,
0.3597469926,
-0.1127995327,
-0.2859252393,
-0.1050391942,
0.0149208391,
-0.1698619276,
-0.07645569,
0.1257112771,
-0.0375016592,
-0.2610755563,
0.2313845456,
0.177450344,
-0.2077099234,
-0.0974906608,
-0.103601411,
-0.4231092334,
0.1233231276,
0.1454254091,
-0.2051395029,
0.0484367125,
0.0691511706,
0.0330369733,
0.0200614613,
0.2030548155,
0.1185464934,
0.1208034009,
-0.1575894952,
-0.1155704334,
-0.1994714886,
-0.0202990416,
0.3250644207,
0.3206854463,
-0.0350312442,
0.2576964498,
-0.0489106812,
0.1194562912,
-0.2026142776,
-0.152892977,
0.0873725936,
-0.1526424587,
-0.4054562151,
-0.5796859264,
0.2548052371,
0.286072135,
-0.2733594775,
0.2686944306,
-0.4227360785,
-0.5627907515,
0.5058528781,
0.4064009786,
0.9796896577,
0.1664846539,
0.2344916314,
-0.0474514775,
0.0723221973,
0.2349289507,
-0.1080671325,
0.0098637259,
-0.1893489957,
-0.3388238251,
-0.1379264444,
-0.1380849779,
0.0714437664,
0.1966303736,
-0.5177470446,
0.3036628664,
-0.2240804881,
0.2181955278,
-0.0767301992,
0.0721059144,
0.0149633922,
-0.4111936986,
0.1211164147,
0.1668590605,
0.052030284,
0.0668292269,
0.0059834416,
-0.1808181256,
-0.0364298113,
-0.1764054149,
-0.1973520666,
-0.0553822964,
-0.4096273482,
0.2041880339,
-0.2747022808,
-0.2291876823,
0.2709038556,
0.24502711,
0.1221303493,
0.1281338036,
-0.0245645605,
0.1205538362,
0.4771942496,
0.441916734,
-0.1892431229,
-0.1107615829,
0.4512735009,
0.118550159,
0.04760639,
0.2068212479,
0.0189809352,
-0.124065429,
-0.3792590797,
0.0502348579,
0.0180956759,
-0.3983492255,
-0.1909384727,
0.1302220225,
0.1814610362,
-0.1411410868,
0.1331454515,
0.1660132259,
0.0399862528,
0.5278525352,
-0.0116107184,
-0.0717082247,
-0.0180291459,
0.5423625112,
0.2122573256,
-0.2234226018,
0.2645744681,
-0.0456947386,
-0.2526443899,
-0.2864989936,
0.1626981944,
0.3042617738,
-0.4171228707,
0.3503534496,
-0.1644052863,
0.0374992527,
0.0011793219,
0.2650029659,
-0.0694571733,
0.1463859826,
-0.3619965017,
0.0521444231,
-0.2687900364,
0.141682446,
0.2051517516,
0.3461746871,
0.0078525292,
0.0949194953,
0.2333236933,
0.1456318796,
-0.4534859955,
-0.1994704306,
0.1567431092,
0.2777866721,
0.030596301,
0.2215950787,
-0.1667425931,
0.0109423455,
0.0681968853,
-0.048560556,
-0.1718589664,
-0.2449807078,
-0.2608168721,
0.1495780945,
-0.1305648983,
0.2838543355,
-0.1769030988,
-0.1287126541,
-0.0051661758,
-0.3064501882,
0.2058153749,
0.3063782454,
-0.0378805809,
0.3182391822,
0.2137871385,
0.1488669068,
-0.0750185102,
0.1623832732,
-0.025853578,
-0.2456712574,
-0.0905537084,
0.2361762524,
-0.1829240769,
-0.2301764935,
0.1336210668,
0.13823843,
0.3976425529,
0.4385483861,
0.0227236245,
0.246105656,
0.0045876596,
0.170309037,
0.1452967674,
0.0827446952,
-0.2487812638,
0.0128775332,
0.3809614182,
0.2653128505,
-0.3175286353,
0.02649872,
0.0086146304,
-0.1199657544,
0.3338315785,
0.2245676816,
-0.1392788887,
-0.0787046552,
0.1119481847,
-0.1132948175,
0.3855657279,
-0.3107675016,
0.2883133888,
0.4110664725,
0.1507866532,
-0.198431015,
0.3002700508,
0.1840613484,
0.4749109149,
0.3014984131,
0.0197992101,
0.4932370782,
0.4293276966,
-0.1618334055,
0.2800312936,
-0.3294986784,
0.0539431013,
-0.1011626944,
0.1457257718,
0.2844058275,
0.1224569753,
0.182041049,
-0.0660167113,
-0.3848779798,
0.1258669198,
0.4354141653,
-0.0019042902,
-0.0322707072,
-0.2071639001,
0.0062796967,
-0.1098862514,
-0.1289826483,
-0.1048974469,
-0.018738078,
0.440877825,
0.1447045803,
0.344099462,
0.0596933514,
0.1960252076,
-0.0881614387,
0.3728542924,
-0.1954397708,
-0.2206189781,
0.0087484159,
-0.0019892605,
0.0999737903,
0.5693271756,
0.1697333157,
0.4058479667,
-0.1825148165,
0.283028841,
-0.2460071594,
-0.0921309292,
-0.3691034615,
0.062750183,
-0.2352346927,
-0.0962470025,
0.1933154464,
0.2326011956,
-0.1750640571,
0.3061747849,
-0.1703759283,
-0.1806525588,
-0.1519054472,
0.357365191,
0.3389049172,
-0.4020301402,
0.1263379753,
-0.2161050439,
-0.0044699619,
-0.1532258987,
0.3877573609,
-0.2608048022,
0.1572977304,
-0.01095438,
0.1233246848,
0.0763536096,
0.1864046007,
-0.0791762099,
0.1155588552,
-0.0715484396,
-0.040529836,
-0.1668333411,
-0.2032974958,
0.1678041816,
0.1783124506,
-0.0528842807,
-0.1674333513,
0.1508949399,
-0.0492098704,
-0.0875458717,
-0.2192394435,
-0.0532062575,
0.6068763137,
-0.2213243991,
-0.1320447475,
-0.277264595,
0.2369889915,
0.2467440665,
-0.267780304,
-0.1112405434,
0.1150827333,
0.1758445203,
-0.2934876084,
-0.2490745038,
0.4110200405,
0.0404777601,
0.6535287499,
0.0730499327,
0.1114506721,
-0.169359684,
0.2988483906,
-0.0874720812,
0.046660509,
-0.3179551065,
0.0188858937,
0.2508709729,
0.0143270567,
-0.2243088782,
-0.2291503102,
-0.1598742455,
0.034921784,
0.1417371184,
0.2680797279,
-0.2188685089,
0.2249872237,
-0.179891929,
-0.1504158825,
-0.2670794129,
0.2849117517,
-0.0946470052,
0.0689084753,
-0.413649261,
-0.2767499387,
0.5885536671,
-0.392432034,
-0.4034228027,
-0.2760230005,
0.1512250453,
-0.0851464793,
0.1741056442,
-0.2394291312,
-0.2244386077,
0.396098882,
-0.0219021756,
-0.0229622722,
0.1469137669,
0.0037390774,
-0.0840597227,
-0.2234541774,
0.3722706735,
0.0676158145,
-0.1575483531,
-0.242011115,
-0.3448422849
] |
https://github.com/huggingface/datasets/issues/3385 | None batched `with_transform`, `set_transform` | Hi @lhoestq ,
Sorry I missed your reply.
I would love to contribute. But I don't know which solution would be the best for this repo.
> However I'm not a big fan of the inconsistency it would create with map: with_transform is batched by default while map isn't.
I agree. What do you think about the alternative solutions?
> * Convert a non-batched transform function to batched one myself.
This won't be able to use torch loader multi-worker.
> * Wrap a 🤗 Dataset with torch Dataset, and add a __getitem__. 🙄
This is actually pretty simple.
```python
import torch
class LazyMapTorchDataset(torch.utils.data.Dataset):
def __init__(self, ds, fn):
self.ds = ds
self.fn = fn
def __getitem__(self, i):
return self.fn(self.ds[i])
d = [{1:2, 2:3}, {1:3, 2:4}]
ds = LazyMapTorchDataset(d, lambda x:{k:v*2 for k,v in x.items()})
for i in range(2):
print(f'before {d[i]}')
print(f'after {ds[i]}')
```
```
before {1: 2, 2: 3}
after {1: 4, 2: 6}
before {1: 3, 2: 4}
after {1: 6, 2: 8}
```
But this requires converting data to torch tensor myself. And this is really similar to `.map()`, why not just use it? So I have the next solution.
> * Have lazy=False in Dataset.map, and returns a LazyDataset if lazy=True. This way the same map interface can be used, and existing code can be updated with one argument change.
I think I like this solution best. Because `.with_transform` is entangled with `.with_format`, so seems more flexible to modify the `.map` than to modify `.with_transform`.
The usage looks nice, too.
```python
# lazy, one to one, can be parallelized via torch loader, no need to set `num_worker` beforehand.
dataset = dataset.map(fn, lazy=True, batched=False)
# collate_fn
dataloader = Dataloader(dataset.with_format('torch'), collate_fn=collate_fn, num_workers=...)
```
There are some minor decisions like whether a lazy map should be allowed before another map, but I think we can work it out later. The implementation can probably borrow from `IterableDataset`. | **Is your feature request related to a problem? Please describe.**
A `torch.utils.data.Dataset.__getitem__` operates on a single example.
But 🤗 `Datasets.with_transform` doesn't seem to allow non-batched transform.
**Describe the solution you'd like**
Have a `batched=True` argument in `Datasets.with_transform`
**Describe alternatives you've considered**
* Convert a non-batched transform function to batched one myself.
* Wrap a 🤗 Dataset with torch Dataset, and add a `__getitem__`. 🙄
* Have `lazy=False` in `Dataset.map`, and returns a `LazyDataset` if `lazy=True`. This way the same `map` interface can be used, and existing code can be updated with one argument change. | 315 | None batched `with_transform`, `set_transform`
**Is your feature request related to a problem? Please describe.**
A `torch.utils.data.Dataset.__getitem__` operates on a single example.
But 🤗 `Datasets.with_transform` doesn't seem to allow non-batched transform.
**Describe the solution you'd like**
Have a `batched=True` argument in `Datasets.with_transform`
**Describe alternatives you've considered**
* Convert a non-batched transform function to batched one myself.
* Wrap a 🤗 Dataset with torch Dataset, and add a `__getitem__`. 🙄
* Have `lazy=False` in `Dataset.map`, and returns a `LazyDataset` if `lazy=True`. This way the same `map` interface can be used, and existing code can be updated with one argument change.
Hi @lhoestq ,
Sorry I missed your reply.
I would love to contribute. But I don't know which solution would be the best for this repo.
> However I'm not a big fan of the inconsistency it would create with map: with_transform is batched by default while map isn't.
I agree. What do you think about the alternative solutions?
> * Convert a non-batched transform function to batched one myself.
This won't be able to use torch loader multi-worker.
> * Wrap a 🤗 Dataset with torch Dataset, and add a __getitem__. 🙄
This is actually pretty simple.
```python
import torch
class LazyMapTorchDataset(torch.utils.data.Dataset):
def __init__(self, ds, fn):
self.ds = ds
self.fn = fn
def __getitem__(self, i):
return self.fn(self.ds[i])
d = [{1:2, 2:3}, {1:3, 2:4}]
ds = LazyMapTorchDataset(d, lambda x:{k:v*2 for k,v in x.items()})
for i in range(2):
print(f'before {d[i]}')
print(f'after {ds[i]}')
```
```
before {1: 2, 2: 3}
after {1: 4, 2: 6}
before {1: 3, 2: 4}
after {1: 6, 2: 8}
```
But this requires converting data to torch tensor myself. And this is really similar to `.map()`, why not just use it? So I have the next solution.
> * Have lazy=False in Dataset.map, and returns a LazyDataset if lazy=True. This way the same map interface can be used, and existing code can be updated with one argument change.
I think I like this solution best. Because `.with_transform` is entangled with `.with_format`, so seems more flexible to modify the `.map` than to modify `.with_transform`.
The usage looks nice, too.
```python
# lazy, one to one, can be parallelized via torch loader, no need to set `num_worker` beforehand.
dataset = dataset.map(fn, lazy=True, batched=False)
# collate_fn
dataloader = Dataloader(dataset.with_format('torch'), collate_fn=collate_fn, num_workers=...)
```
There are some minor decisions like whether a lazy map should be allowed before another map, but I think we can work it out later. The implementation can probably borrow from `IterableDataset`. | [
-0.4711225033,
-0.3246157765,
-0.0549607687,
-0.1955652386,
0.1590392888,
-0.1022731364,
0.6502953172,
0.3004758656,
0.0288872514,
0.0306590348,
-0.0858125314,
0.6519104838,
-0.2961898148,
-0.3571740985,
-0.0741108432,
-0.0310693197,
0.092642203,
-0.0295144226,
-0.4197269976,
-0.1126467437,
-0.3453668356,
-0.1154340655,
-0.2241370976,
-0.1967883259,
-0.0167287774,
-0.1126806885,
-0.2313566357,
-0.0543564968,
0.2294274867,
-0.1245447248,
0.422126472,
0.3283923566,
0.0611791983,
0.5336278677,
-0.0001071764,
0.0695500076,
0.1252516657,
-0.2203772217,
-0.2237211764,
-0.2557759881,
-0.0277659632,
-0.3834763467,
-0.0389441922,
-0.3486754298,
-0.2723690271,
-0.1158436909,
0.2067820728,
-0.489305079,
0.3108709455,
0.1837982237,
0.194607541,
0.1889453083,
-0.3023172319,
-0.2416505218,
0.1338344812,
0.1012061387,
-0.0280417036,
0.0960858837,
0.6349208951,
0.1355554014,
-0.2005688399,
0.2432681918,
-0.3011344969,
-0.0316332616,
0.3070968091,
-0.0675860792,
-0.099431105,
-0.204939872,
-0.1095505729,
0.1948915422,
0.0913889632,
-0.1453017592,
-0.3808381557,
-0.4255499244,
-0.0825831816,
0.194102183,
-0.0025776718,
0.1834045202,
-0.1552692801,
0.012939306,
-0.5211726427,
-0.0610019304,
-0.0205794573,
0.1567846537,
0.1077068523,
0.2466582805,
0.0879687667,
0.1857106239,
-0.0705762729,
-0.1110477298,
0.4320276082,
-0.0806178376,
0.1512476504,
0.2929493189,
-0.2076355666,
-0.1133076027,
0.1404975355,
-0.0949816629,
0.2375046462,
0.1793374866,
0.1663081348,
0.1028079242,
-0.1340145916,
0.0747369826,
0.1485816836,
0.1336832494,
-0.0355429985,
0.1838076264,
0.2335190475,
-0.1515789181,
0.1680419147,
0.1315313429,
0.0710570961,
-0.2317569703,
0.0577343553,
0.4872901738,
0.1683005095,
0.179284215,
-0.0130637968,
-0.5947455168,
0.0806812495,
-0.1959218532,
-0.180493176,
0.3848351538,
-0.1408487111,
0.3235300779,
0.1904086024,
0.1057817042,
0.0535787158,
-0.1774033755,
-0.0782470405,
-0.1267130822,
-0.2070501447,
-0.1470552236,
0.2358449996,
-0.127311945,
0.1955176741,
0.1308039278,
-0.0032267878,
0.493683666,
0.1419983804,
-0.1829642355,
0.4374261796,
-0.0858876482,
0.0854039714,
0.1148672625,
0.1535560936,
0.3288296163,
-0.3398991227,
0.3572044373,
-0.4203705192,
-0.3689233661,
0.0900453776,
0.2018878013,
-0.1276912391,
-0.0184555668,
-0.2811018825,
0.2665116787,
0.2146404982,
-0.0552401729,
0.214235574,
-0.1300136,
-0.112409234,
-0.3192116022,
-0.0892715752,
0.161241889,
-0.0986391008,
-0.2350444049,
0.2002987117,
0.0635177493,
0.0013540545,
0.1029297858,
-0.3248066306,
0.1430271268,
-0.3347871602,
-0.1782244295,
0.4257616997,
-0.3232330978,
-0.2195264995,
0.1291212738,
-0.0594978668,
0.0719237998,
0.2487336397,
0.0666334927,
0.4341469705,
-0.2113699168,
0.2510509491,
0.439469099,
-0.1365167052,
0.2124048322,
-0.1045816019,
-0.3297900259,
0.344606638,
0.08455652,
0.1913185418,
0.0671766028,
-0.1627071351,
-0.1987389773,
0.2804645896,
-0.1401816458,
0.0993563011,
0.0172796994,
-0.0139807994,
-0.0235308763,
0.0236868765,
-0.0556922667,
-0.5870633721,
0.2094667107,
0.1290420443,
0.0090852613,
0.0792272687,
-0.2415578216,
0.2290275693,
-0.1645846963,
-0.0801014081,
-0.2327689826,
0.0667371228,
0.138518095,
-0.1413664222,
-0.4105315506,
-0.207675606,
0.1549977809,
0.1783133,
-0.1027129516,
-0.2891635597,
0.0844196677,
0.134380579,
-0.2848817408,
-0.0512453318,
-0.0766879842,
0.2527854145,
-0.2179920375,
-0.0074705188,
0.2002017349,
-0.322427541,
0.2079226971,
-0.2997956872,
0.195292443,
0.175467968,
-0.0433694683,
0.1186171398,
0.374840349,
0.0528216958,
-0.1226055697,
-0.6456489563,
0.5840041041,
-0.0006718987,
0.373426348,
-0.0991899297,
0.0955678225,
0.2725901008,
-0.2332567573,
-0.2214981765,
-0.069988057,
0.1182979122,
0.1085231677,
0.1488994807,
-0.0574050918,
-0.1962557286,
0.1534259766,
0.223511681,
0.1386109889,
0.1628851295,
0.0175494459,
-0.064928934,
-0.0087263267,
0.1320239007,
-0.1529221982,
0.5411449671,
0.3627532423,
-0.0677384064,
-0.2286802083,
0.466823101,
0.022846384,
0.2019663602,
-0.1488331109,
0.156941846,
-0.0219443273,
0.4142290056,
-0.0588329583,
0.0019458476,
-0.3531245291,
0.1217072755,
-0.1213552803,
-0.1779992729,
-0.0565283969,
-0.0108935814,
0.1133311614,
-0.3415462673,
-0.1045775041,
0.0323735736,
-0.2703223228,
0.1136438698,
0.2020980418,
-0.2316624075,
0.5293697715,
0.1060829088,
0.2113356739,
-0.014763847,
-0.3383223116,
-0.1670262069,
-0.0579913445,
0.038670972,
0.1113283262,
-0.1907875985,
-0.4264956713,
0.4168759286,
0.0696870685,
-0.0823903605,
-0.3162454665,
0.0641126186,
0.0953015387,
-0.0697633252,
-0.0043510059,
0.4321966767,
0.0255577043,
0.4224784672,
-0.2087733895,
0.2284685075,
-0.3656724095,
0.0534080714,
-0.2308406383,
-0.1086116359,
0.2661179602,
-0.1422080398,
-0.2678959072,
-0.1774245054,
-0.468939513,
0.1378504932,
-0.1122001857,
0.2389121652,
-0.1537224501,
0.2402478307,
-0.0955218747,
0.3089002669,
0.0080603091,
0.051089406,
-0.3898175061,
0.5134438872,
-0.2009350657,
-0.1794424802,
-0.2082122117,
-0.2673682272,
-0.1437035054,
0.4664005935,
-0.0952919126,
-0.0975428894,
-0.0731066391,
0.5471215248,
-0.0483237244,
0.2029801905,
0.4040623307,
0.1179645434,
-0.1933652163,
-0.1954413503,
-0.0249867868,
0.0448787436,
0.084301658,
0.0963041782,
0.369125396,
0.2834114432,
0.2005013227,
1.0360913277,
0.0483129248,
-0.2693999112,
-0.0296012722,
-0.0729885474,
0.0550972447,
0.1573235095,
-0.5130919218,
-0.1090538427,
-0.0670019984,
0.1864426434,
0.1126144752,
-0.1194963828,
-0.3732958436,
0.0088521056,
-0.3565210998,
-0.1503201723,
-0.2123468816,
0.5134528279,
-0.3849529624,
0.1192932874,
-0.1418630332,
0.2322729677,
-0.480088383,
-0.0734720528,
0.1674777567,
-0.1201085597,
0.235603258,
-0.1887461841,
0.0650647506,
0.2612869143,
-0.3272728026,
0.3422315121,
0.0399663784,
0.1533800215,
0.1740545034,
-0.1775504649,
-0.0759323463,
-0.0792930797,
0.8048284054,
-0.1002959311,
0.0097372774,
0.0880311951,
-0.3145726323,
-0.3229267597,
-0.1487616152,
-0.1293161362,
0.2391362488,
0.3746313453,
0.4657880962,
-0.2113844156,
-0.3605944514,
-0.022054797,
-0.0372592472,
-0.2090665102,
-0.1137850657,
0.0335890092,
-0.0644194931,
-0.3345568478,
0.1582055241,
0.1676303893,
-0.064011097,
-0.1880771071,
-0.0297444388,
-0.367426604,
0.0224276818,
0.147870183,
-0.2974761724,
0.0033548058,
0.1653495878,
0.1313183606,
0.0711769462,
0.2033958882,
0.1051968038,
0.2923558354,
-0.2742362916,
-0.114504911,
-0.1045098603,
-0.1268267483,
0.2331181318,
0.3448082209,
0.0427917391,
0.0931757987,
-0.0709679946,
0.1300463825,
-0.254965663,
-0.1557910144,
0.0619132295,
-0.1272978932,
-0.2559748292,
-0.6764864326,
0.2971203625,
0.2205975503,
-0.2338944674,
0.1542351097,
-0.5489990711,
-0.4521862566,
0.3782273233,
0.4433788359,
0.9292342663,
0.0831314176,
0.2677840889,
-0.0038783674,
0.0540599674,
0.1656661481,
-0.3560735285,
0.0738611817,
-0.1746646315,
-0.3155484498,
-0.0829747468,
-0.1566771865,
0.000446081,
0.2115554065,
-0.4472917318,
0.3652637601,
-0.1330053508,
0.2126545012,
-0.058196146,
0.0767788813,
-0.0301104337,
-0.4389671087,
0.0185554065,
0.1200741678,
0.1217860058,
0.0715219304,
-0.0057566813,
-0.2171735168,
-0.0061767977,
-0.1906891167,
-0.2344836444,
0.0214972068,
-0.3280722797,
0.2624054849,
-0.0287513584,
-0.2781001329,
0.223964259,
0.2405835986,
0.0523634255,
-0.0429284833,
-0.0004580959,
0.0253558513,
0.4027706683,
0.3478582203,
-0.1889559627,
-0.1519615948,
0.5235299468,
0.0382626392,
-0.0016562687,
0.246712774,
0.0270168465,
-0.2154707909,
-0.2754541934,
0.1686149091,
0.1060441062,
-0.4086515605,
-0.1265905201,
0.243767336,
0.2147351056,
-0.1664004177,
0.1124435067,
0.2418871373,
-0.14273265,
0.3948943615,
-0.0231442172,
-0.1125757918,
-0.0040613022,
0.5660001636,
0.3967523873,
-0.2261764258,
0.3953677714,
0.1050839946,
-0.2227552682,
-0.266477704,
0.101930283,
0.3543086648,
-0.5201172233,
0.3260573447,
-0.241063118,
0.0112671312,
0.0054429206,
0.2683945,
-0.0970999971,
0.2608306706,
-0.257688731,
-0.0998098478,
-0.3109748662,
-0.0025681495,
0.2098945528,
0.2969897389,
0.0109469825,
0.0565780886,
0.2847714424,
0.193248719,
-0.4367371202,
-0.0772755817,
-0.0075466805,
0.2172151804,
-0.033850532,
0.1598965079,
-0.0876440853,
0.0088090012,
0.0556522869,
-0.0524633639,
-0.1725172102,
-0.2462816387,
-0.2674753368,
0.1414141953,
-0.1124333516,
0.1762049496,
-0.0779447332,
-0.1660975814,
0.015276894,
-0.2123715281,
0.2383676022,
0.2461405545,
0.0054865512,
0.2262739688,
0.3491477072,
0.131465748,
-0.1568527669,
0.1037040055,
-0.0685527474,
-0.0454515889,
-0.1138652489,
0.2073950917,
-0.1067779362,
-0.1828013659,
0.1468409002,
0.0617189296,
0.4185723364,
0.4318028092,
0.1520188004,
0.0402684174,
0.0214108936,
0.0843520463,
0.1354780644,
-0.0023665661,
-0.2722883821,
0.020170372,
0.311155349,
0.2508631945,
-0.3508816957,
0.0796907991,
0.0039526224,
-0.0954105482,
0.335052371,
0.2865383923,
-0.1225870103,
-0.0969837904,
0.1204475239,
0.0944820419,
0.3318260312,
-0.2760261297,
0.2090438753,
0.2408857793,
0.0488459356,
-0.1392177939,
0.2614601552,
0.1207220629,
0.3958681524,
0.0928754434,
0.0397161618,
0.5787734985,
0.4344002306,
-0.2148476243,
0.2868195474,
-0.3409051299,
0.0561898164,
-0.0425834879,
0.0859917253,
0.2280172259,
0.0949724093,
0.2399918586,
-0.0630089417,
-0.2006139308,
0.0440904424,
0.4590681493,
0.0223205332,
-0.0689031035,
-0.107160382,
-0.0351355225,
-0.2204753906,
-0.0142759504,
-0.1809249371,
-0.1177758425,
0.6052351594,
0.0928125083,
0.2455981672,
0.0092417179,
0.1307233125,
-0.0914709866,
0.3125674725,
-0.2304597497,
-0.1746213287,
0.1104945689,
0.0169607643,
0.009376918,
0.6031892896,
0.2367814481,
0.3835633695,
-0.2222282737,
0.2514435351,
-0.0840625614,
-0.0837931409,
-0.2759321034,
0.0553585477,
-0.3176045418,
-0.1205178052,
0.1944895685,
0.2067997456,
-0.2260139734,
0.3357407749,
-0.0406044796,
-0.2518153787,
-0.061739713,
0.4888369143,
0.3165277839,
-0.3302331865,
0.0717740878,
-0.1594765931,
-0.084830448,
-0.1430492103,
0.374089241,
-0.2783740759,
0.1832100749,
0.0232766028,
0.1303528249,
0.0058702598,
0.2332187444,
-0.0649811253,
0.1756470501,
-0.2447214723,
-0.017198598,
-0.0941356346,
-0.1004036441,
0.0079312362,
0.1185982898,
-0.1433870047,
0.0098147299,
0.2557879686,
0.0636958852,
-0.1215757206,
-0.2909857333,
0.0980923623,
0.6609246135,
-0.2374637872,
-0.1631504297,
-0.1930316687,
0.3087807894,
0.3174530864,
-0.3069647253,
-0.1615954787,
0.0610095747,
0.1621089876,
-0.2844516933,
-0.1841722131,
0.4689262807,
-0.0237008333,
0.4092940688,
-0.0132073974,
0.0283637363,
-0.1392101496,
0.1804051399,
-0.0306832939,
0.0577845126,
-0.2891313732,
-0.093325831,
0.2231622338,
0.0151599338,
-0.2752870023,
-0.1724519432,
-0.2024922222,
0.1237975508,
0.0885248631,
0.2602422833,
-0.2752456367,
0.2975162268,
-0.2117256075,
-0.13739793,
-0.2470140755,
0.2834549546,
-0.0288622156,
0.0030332387,
-0.4447761178,
-0.2930388153,
0.5838688612,
-0.6023529172,
-0.4221651554,
-0.4319282472,
0.1275589764,
-0.1530819237,
0.2864525318,
-0.34552297,
-0.0727484077,
0.3976144791,
-0.0286589153,
-0.1004247367,
0.1080233455,
0.1923861057,
-0.0772977769,
-0.2563923597,
0.2747256756,
0.0229378305,
-0.171203956,
-0.3757610321,
-0.3374507129
] |
https://github.com/huggingface/datasets/issues/3385 | None batched `with_transform`, `set_transform` | I like the idea of lazy map. On the other hand we should only have either lazy map or `with_transform` (not both). That's why I'd rather stick with `with_transform` for now (but maybe we can consider it for later major releases like `datasets` v2).
I understand the issue with `with_transform` and `with_format` being exclusive, maybe we can separate them: first transform, them format.
Finally I think what's also going to be important in the end will be the addition of multiprocessing to transforms | **Is your feature request related to a problem? Please describe.**
A `torch.utils.data.Dataset.__getitem__` operates on a single example.
But 🤗 `Datasets.with_transform` doesn't seem to allow non-batched transform.
**Describe the solution you'd like**
Have a `batched=True` argument in `Datasets.with_transform`
**Describe alternatives you've considered**
* Convert a non-batched transform function to batched one myself.
* Wrap a 🤗 Dataset with torch Dataset, and add a `__getitem__`. 🙄
* Have `lazy=False` in `Dataset.map`, and returns a `LazyDataset` if `lazy=True`. This way the same `map` interface can be used, and existing code can be updated with one argument change. | 83 | None batched `with_transform`, `set_transform`
**Is your feature request related to a problem? Please describe.**
A `torch.utils.data.Dataset.__getitem__` operates on a single example.
But 🤗 `Datasets.with_transform` doesn't seem to allow non-batched transform.
**Describe the solution you'd like**
Have a `batched=True` argument in `Datasets.with_transform`
**Describe alternatives you've considered**
* Convert a non-batched transform function to batched one myself.
* Wrap a 🤗 Dataset with torch Dataset, and add a `__getitem__`. 🙄
* Have `lazy=False` in `Dataset.map`, and returns a `LazyDataset` if `lazy=True`. This way the same `map` interface can be used, and existing code can be updated with one argument change.
I like the idea of lazy map. On the other hand we should only have either lazy map or `with_transform` (not both). That's why I'd rather stick with `with_transform` for now (but maybe we can consider it for later major releases like `datasets` v2).
I understand the issue with `with_transform` and `with_format` being exclusive, maybe we can separate them: first transform, them format.
Finally I think what's also going to be important in the end will be the addition of multiprocessing to transforms | [
-0.4687542617,
-0.312884897,
-0.0656989068,
-0.2338286489,
0.2658573389,
-0.1204679683,
0.486851126,
0.4093423486,
-0.1548074335,
-0.0003178421,
-0.1138283834,
0.5173217654,
-0.3530977368,
-0.1026493981,
-0.0778419897,
-0.1407481879,
0.2095866948,
0.0911348164,
-0.4605179131,
0.0447243229,
-0.3199198246,
-0.1909858137,
-0.2245099992,
-0.0781536177,
-0.1639564335,
-0.1039127186,
-0.1483007669,
-0.1973615587,
0.1008402556,
-0.2246042043,
0.2129238397,
0.2881470025,
0.0640649498,
0.5212792158,
-0.0001051417,
-0.0094457315,
0.1325227916,
-0.1668575257,
-0.1888015717,
-0.1427520514,
-0.0153546268,
-0.337292105,
-0.0789718255,
-0.3621992767,
-0.2289913595,
-0.3799800575,
0.221635446,
-0.4447899163,
0.293745935,
0.1115705445,
0.2402185649,
0.1558633298,
-0.3252518475,
-0.2349421531,
0.0849213079,
0.2807734311,
-0.0489993989,
-0.1477221549,
0.5329069495,
0.2994230986,
-0.1836404949,
0.2589876056,
-0.2960538268,
-0.2014295459,
0.3642662764,
-0.0666235685,
-0.3273939788,
-0.2730422318,
-0.0660221204,
0.1583486348,
0.2635510862,
-0.2569995821,
-0.5107657909,
-0.3624103367,
-0.1273451298,
0.061213471,
-0.0181791,
0.1436537355,
-0.0218975171,
0.1327901632,
-0.5536369681,
-0.132584542,
-0.0512932986,
0.0886267796,
0.1417218,
0.1607361883,
0.0928459316,
0.1292498559,
-0.1415953934,
-0.1260416657,
0.3903656304,
-0.1621385366,
0.0360225625,
0.2577248812,
-0.0924994051,
-0.1074545607,
0.0643879548,
0.0723992586,
0.2739292979,
0.1976431906,
-0.0010044611,
0.1336931735,
-0.1010700837,
0.0452420898,
0.1197481155,
0.1179258451,
0.0919665471,
0.169841662,
0.3209154606,
-0.2819173336,
0.1523599923,
0.0381262302,
0.1092795506,
-0.2840995491,
0.0413362645,
0.3983521461,
0.118219696,
0.1158589497,
0.1436551809,
-0.4700783193,
0.2494655401,
-0.1497271508,
-0.1787224859,
0.39188236,
0.0440567732,
0.3303281665,
0.1552547812,
0.091312401,
0.1395710707,
-0.1830812991,
-0.0808199123,
-0.0182715505,
-0.2349541634,
-0.2111999094,
0.1829231381,
-0.1559449583,
0.1149327829,
0.2675923705,
-0.0742614046,
0.4607935548,
0.0024232457,
-0.2200834155,
0.5438047051,
-0.0912547708,
-0.0578333512,
0.2233761996,
-0.0099603822,
0.3393717408,
-0.3583168089,
0.2624289691,
-0.3040549159,
-0.3288432062,
0.0594859384,
0.2274774611,
-0.1664952636,
0.0810945705,
-0.0620435514,
0.3706511557,
0.0856918544,
-0.1516023129,
0.1391099691,
-0.1623870879,
-0.0605695434,
-0.3375452459,
0.0645385459,
0.1360531449,
-0.3584342599,
-0.1752726883,
0.2935862541,
0.0273461919,
-0.0241565146,
0.2092227489,
-0.3233005702,
0.1273104548,
-0.284419477,
-0.1381440163,
0.4818065166,
-0.2324437648,
-0.1423344463,
0.0824539363,
0.0480396673,
0.0100100469,
0.2708283961,
0.0321945213,
0.4170938134,
-0.2378053218,
-0.0037305236,
0.3913208246,
-0.1156212911,
0.1312516034,
-0.0213390738,
-0.3268261552,
0.3088168204,
-0.0774430707,
0.181285575,
0.0662338734,
-0.1394660622,
-0.123163633,
0.0990128741,
-0.2874062657,
0.1958291829,
0.0104520004,
0.0078425203,
-0.0304855853,
0.0173142962,
-0.1274906546,
-0.5588943958,
0.1192620993,
0.0513877571,
-0.1543222815,
0.0637497082,
-0.3875489533,
0.3068361878,
-0.182302773,
0.0166304205,
-0.173416391,
0.1263461262,
0.0949066132,
-0.1289847791,
-0.3197919726,
-0.3387368619,
0.0336850099,
0.2567538917,
-0.0512648113,
-0.1397843063,
-0.1444328725,
0.0968972072,
-0.327262491,
-0.0545728728,
-0.012942466,
0.1241914704,
-0.2285854369,
-0.0384016559,
0.2687452137,
-0.2723580897,
0.2025725991,
-0.3058187366,
0.264411509,
0.1508258134,
0.0977296829,
0.0222970899,
0.0894388333,
0.0301214252,
-0.0538836494,
-0.5827391148,
0.5392077565,
0.0472292118,
0.367169112,
0.029023746,
0.0304898843,
0.2101662755,
-0.2585622966,
-0.2018582374,
-0.2316630185,
-0.0322661549,
-0.0284082703,
0.1833218038,
0.0681270435,
-0.3163180649,
0.0742143616,
0.4280002713,
0.1842910945,
0.1775415689,
0.0538354516,
-0.0866624191,
0.036532335,
0.0897830427,
-0.2513158321,
0.503405869,
0.4248324633,
-0.0302398782,
-0.1864132583,
0.4455655217,
0.0070578316,
0.3381423354,
-0.0591842569,
-0.091057241,
0.0617815666,
0.2822963595,
0.0438253172,
-0.0081550712,
-0.3811834157,
0.0219591707,
-0.2403923273,
-0.1927343756,
-0.0890804455,
-0.1250677407,
-0.008821018,
-0.314447701,
0.0422882438,
0.0697155297,
-0.1530552655,
0.153704837,
0.0794717744,
-0.3295104206,
0.5333344936,
0.0237822141,
0.2676770091,
-0.0237308592,
-0.2467225641,
-0.2672999203,
-0.0282074343,
-0.0212831181,
0.1145432368,
-0.1010895967,
-0.3840890825,
0.4391748309,
0.0952684656,
0.1249656528,
-0.3364581466,
-0.0371294431,
0.1651225388,
-0.080031395,
0.0996182412,
0.4696497619,
0.01591276,
0.3220629394,
-0.2629352808,
0.2307863533,
-0.3487226367,
0.0483911559,
-0.2622113228,
-0.1272949576,
0.0986571163,
-0.2436850071,
-0.2485934198,
-0.0748002008,
-0.5598963499,
0.1625231057,
-0.2880703211,
0.1387999207,
-0.1178400591,
0.1292912066,
-0.1337203383,
0.0713165402,
0.1399289519,
0.0961507335,
-0.2601460516,
0.4839158058,
-0.16452232,
-0.1762311906,
-0.2410602272,
-0.1411270946,
-0.1873170137,
0.5462931395,
0.0236764532,
-0.038935069,
-0.1725804061,
0.4672320783,
-0.0205915328,
0.2864201963,
0.3053870499,
0.2586712837,
-0.2362637371,
-0.233671248,
0.0111400019,
-0.00225905,
-0.0002844383,
-0.0208157245,
0.3144409955,
0.246999532,
0.2486891598,
0.7835969925,
0.0702691898,
-0.405238837,
0.02708726,
0.0046301773,
0.1769881845,
0.0303648952,
-0.486405015,
-0.0015139253,
-0.0261201691,
0.2047630847,
0.2222324312,
-0.1338496953,
-0.2499235421,
-0.0055017886,
-0.1454305649,
-0.2401723266,
-0.1611364186,
0.4791346192,
-0.343084991,
0.2320963293,
-0.1471759975,
0.1909117699,
-0.2565993667,
0.070339784,
0.2374993116,
-0.0971841663,
0.363861233,
-0.0848785713,
-0.0137387821,
0.0407846235,
-0.2748414874,
0.4136999547,
0.0567238815,
0.223730132,
-0.0298417881,
-0.1916379929,
-0.0981765315,
0.0331683829,
0.7530317903,
-0.2349664271,
-0.1895805597,
0.0264923926,
-0.2578264475,
-0.2857514322,
-0.0450592861,
-0.1201685742,
0.125454247,
0.2796441615,
0.4619193077,
-0.1973955482,
-0.4259576201,
-0.007611128,
0.0936569721,
-0.0986048505,
-0.1110123768,
0.125186801,
-0.0206973329,
-0.2554388046,
0.2057139426,
0.1610021591,
-0.1980575621,
-0.213670522,
-0.0892595574,
-0.4171462953,
0.0508423261,
0.1457843781,
-0.2190222442,
0.1144380197,
0.0342115052,
0.0743680745,
0.0490458421,
0.3142302632,
0.1395398527,
0.0538948588,
-0.1722217202,
-0.1360665709,
-0.0955721587,
-0.0995448977,
0.3250500262,
0.337557435,
-0.0007609786,
0.2074069679,
-0.1562587619,
0.1078604758,
-0.2568590939,
-0.0337774828,
0.1575039327,
-0.1147872582,
-0.4579713047,
-0.5947855711,
0.2178185284,
0.2949564457,
-0.2173056006,
0.2090628892,
-0.4219106138,
-0.5313151479,
0.5193053484,
0.3247112632,
0.9087435603,
0.1879688203,
0.2210884541,
-0.0972600803,
-0.0779284909,
0.3075705767,
-0.2057857066,
0.0423342027,
-0.2170093507,
-0.3691226542,
-0.097855106,
-0.1656755656,
0.1285366565,
0.2725104392,
-0.4823839366,
0.3867567182,
-0.1825915724,
0.2123003602,
-0.0406106338,
0.1474622339,
0.0082960548,
-0.4369081855,
0.028706396,
0.1574228853,
-0.0008422023,
-0.0076983487,
-0.0075526675,
-0.1770840585,
-0.0614659376,
-0.1198028699,
-0.1128743514,
-0.0750016123,
-0.3318096697,
0.2200947404,
-0.2920873165,
-0.3687742949,
0.3064423203,
0.2540562451,
0.2096476108,
0.1678810865,
0.0023628664,
0.0724303126,
0.4070315659,
0.4604639113,
-0.1682729125,
-0.2011277825,
0.4773097932,
0.1418217868,
0.0867379606,
0.1206510067,
0.0313896574,
-0.0509096682,
-0.2618923485,
0.0034796356,
0.0325868614,
-0.4125154614,
-0.2625182569,
0.1173371077,
0.1820687801,
-0.1206526011,
0.1532192379,
0.1262998581,
0.0266418122,
0.5502889156,
-0.0240520183,
-0.0820456594,
-0.0692048967,
0.4325809181,
0.2066135556,
-0.1924602538,
0.2906914353,
-0.0007179449,
-0.3134611249,
-0.2610845566,
0.1250038147,
0.3683263659,
-0.5209848881,
0.3605054617,
-0.149099052,
-0.0088438326,
-0.0546833538,
0.2231437564,
-0.0613017753,
0.1025883183,
-0.3052518666,
0.0770846605,
-0.3019749522,
0.1950148344,
0.1693500876,
0.4361010492,
0.0631294996,
0.1890440136,
0.1414961368,
0.0973929539,
-0.4523159266,
-0.147583589,
0.1782573014,
0.311609894,
0.0091434075,
0.1404053569,
-0.187700212,
-0.0330674015,
0.0730681121,
-0.0063575949,
-0.1520677954,
-0.2644826472,
-0.2749755085,
0.1372967362,
-0.1477382183,
0.2083250731,
-0.1209605262,
-0.0079797748,
-0.0034107124,
-0.3663578331,
0.2334276438,
0.2783217728,
-0.0086479364,
0.3238651454,
0.199564904,
0.0645956025,
-0.1089358479,
0.1456303,
-0.0617993735,
-0.1108615473,
0.0036597545,
0.2925471961,
-0.1187305972,
-0.2121245712,
0.0939688757,
0.1077195257,
0.3819418848,
0.4249095321,
0.0527163148,
0.1762871593,
-0.0008610471,
0.2648797631,
0.2778300643,
0.0966617092,
-0.1794145107,
-0.0265333913,
0.3750528693,
0.2821809947,
-0.2625367343,
-0.0108152572,
0.028519623,
-0.0470926128,
0.2980300188,
0.1811056435,
-0.0442611985,
-0.025657963,
0.0172478203,
0.0120796449,
0.326659739,
-0.2660501003,
0.3034349978,
0.3937571943,
0.2505792081,
-0.096828714,
0.2915050685,
0.1370781809,
0.4064859748,
0.2093126625,
0.092245549,
0.547272265,
0.4569997489,
-0.1038236097,
0.3438938856,
-0.3219376206,
-0.0455686189,
-0.1752871722,
0.1547973901,
0.2427283674,
0.0807546899,
0.1976969391,
-0.0493952297,
-0.4262328446,
0.1364218295,
0.4556082785,
-0.0616323985,
-0.0974346995,
-0.1330558807,
-0.0388867967,
-0.0409993641,
-0.0311661381,
-0.1518514156,
0.0462473221,
0.5033505559,
0.1843592077,
0.3478688002,
0.0290020742,
0.2285538018,
-0.1270838231,
0.358676523,
-0.1690223217,
-0.1201022416,
0.1477771252,
-0.1029325947,
0.0910900161,
0.6200850606,
0.2220055461,
0.3420880437,
-0.2408844233,
0.1946896166,
-0.2592625618,
-0.0615672469,
-0.2760489285,
0.1338412762,
-0.274359405,
-0.1112396345,
0.2309430689,
0.2479574978,
-0.1824750304,
0.2535674274,
-0.1445938498,
-0.2172811627,
-0.1662038267,
0.3114418685,
0.3852769732,
-0.4432465136,
0.1749040931,
-0.2044845223,
-0.0299717709,
-0.1815941334,
0.4254637063,
-0.223524034,
0.1259524524,
-0.0620464198,
0.1327807456,
0.1600364298,
0.1968140751,
-0.0262065809,
0.1178460568,
-0.1371293068,
-0.0518379621,
-0.0503228307,
-0.1952515244,
0.202998206,
0.2358451337,
-0.1042341664,
-0.142056182,
0.143153429,
-0.0434848703,
0.0275227651,
-0.2136359662,
-0.0035575437,
0.5908381343,
-0.1829554141,
-0.0672470704,
-0.2300382555,
0.2487132102,
0.1961361915,
-0.2552286983,
-0.1079864576,
0.103386268,
0.1642878652,
-0.2859107554,
-0.1265944093,
0.5060502291,
-0.0298945084,
0.5223243237,
0.1088634208,
0.1164958328,
-0.2133316249,
0.2277987897,
-0.1067652181,
0.0204788446,
-0.3012269139,
0.059575554,
0.1846677363,
0.0823774859,
-0.2825861871,
-0.250700742,
-0.1838871837,
0.0921175182,
0.0193811599,
0.2837998569,
-0.1884787232,
0.2018889934,
-0.2153795809,
-0.2580752969,
-0.1262609959,
0.3253003359,
-0.1304247975,
0.0533060059,
-0.4195710123,
-0.4012657702,
0.5072782636,
-0.4530012906,
-0.4264125824,
-0.2348614037,
0.058501143,
-0.0094390847,
0.2627059519,
-0.2372983545,
-0.2089120746,
0.3256151378,
0.0096700778,
-0.1485928744,
0.1800752431,
0.0455652326,
-0.172826916,
-0.2468682826,
0.4407259226,
0.1098800451,
-0.2165217996,
-0.3428208232,
-0.3184815943
] |
https://github.com/huggingface/datasets/issues/3381 | Unable to load audio_features from common_voice dataset | Hi ! Feel free to access `batch["audio"]["array"]` and `batch["audio"]["sampling_rate"]` instead
`datasets` 1.16 introduced some changes in `common_voice` and now the `path` field is no longer a path to a local file (but rather the path to the file in the archive it's extracted from) | ## Describe the bug
I am not able to load audio features from common_voice dataset
## Steps to reproduce the bug
```
from datasets import load_dataset
import torchaudio
test_dataset = load_dataset("common_voice", "hi", split="test[:2%]")
resampler = torchaudio.transforms.Resample(48_000, 16_000)
def speech_file_to_array_fn(batch):
speech_array, sampling_rate = torchaudio.load(batch["path"])
batch["speech"] = resampler(speech_array).squeeze().numpy()
return batch
test_dataset = test_dataset.map(speech_file_to_array_fn)
```
## Expected results
This piece of code should return test_dataset after loading audio features.
## Actual results
Reusing dataset common_voice (/home/jovyan/.cache/huggingface/datasets/common_voice/hi/6.1.0/b879a355caa529b11f2249400b61cadd0d9433f334d5c60f8c7216ccedfecfe1)
/opt/conda/lib/python3.7/site-packages/transformers/configuration_utils.py:341: UserWarning: Passing `gradient_checkpointing` to a config initialization is deprecated and will be removed in v5 Transformers. Using `model.gradient_checkpointing_enable()` instead, or if you are using the `Trainer` API, pass `gradient_checkpointing=True` in your `TrainingArguments`.
"Passing `gradient_checkpointing` to a config initialization is deprecated and will be removed in v5 "
Special tokens have been added in the vocabulary, make sure the associated word embeddings are fine-tuned or trained.
0%| | 0/3 [00:00<?, ?ex/s]formats: can't open input file `common_voice_hi_23795358.mp3': No such file or directory
0%| | 0/3 [00:00<?, ?ex/s]
Traceback (most recent call last):
File "demo_file.py", line 23, in <module>
test_dataset = test_dataset.map(speech_file_to_array_fn)
File "/opt/conda/lib/python3.7/site-packages/datasets/arrow_dataset.py", line 2036, in map
desc=desc,
File "/opt/conda/lib/python3.7/site-packages/datasets/arrow_dataset.py", line 518, in wrapper
out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs)
File "/opt/conda/lib/python3.7/site-packages/datasets/arrow_dataset.py", line 485, in wrapper
out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs)
File "/opt/conda/lib/python3.7/site-packages/datasets/fingerprint.py", line 411, in wrapper
out = func(self, *args, **kwargs)
File "/opt/conda/lib/python3.7/site-packages/datasets/arrow_dataset.py", line 2368, in _map_single
example = apply_function_on_filtered_inputs(example, i, offset=offset)
File "/opt/conda/lib/python3.7/site-packages/datasets/arrow_dataset.py", line 2277, in apply_function_on_filtered_inputs
processed_inputs = function(*fn_args, *additional_args, **fn_kwargs)
File "/opt/conda/lib/python3.7/site-packages/datasets/arrow_dataset.py", line 1978, in decorated
result = f(decorated_item, *args, **kwargs)
File "demo_file.py", line 19, in speech_file_to_array_fn
speech_array, sampling_rate = torchaudio.load(batch["path"])
File "/opt/conda/lib/python3.7/site-packages/torchaudio/backend/sox_io_backend.py", line 154, in load
filepath, frame_offset, num_frames, normalize, channels_first, format)
RuntimeError: Error loading audio file: failed to open file common_voice_hi_23795358.mp3
## Environment info
- `datasets` version: 1.16.1
- Platform: Linux-4.14.243 with-debian-bullseye-sid
- Python version: 3.7.9
- PyArrow version: 6.0.1
| 44 | Unable to load audio_features from common_voice dataset
## Describe the bug
I am not able to load audio features from common_voice dataset
## Steps to reproduce the bug
```
from datasets import load_dataset
import torchaudio
test_dataset = load_dataset("common_voice", "hi", split="test[:2%]")
resampler = torchaudio.transforms.Resample(48_000, 16_000)
def speech_file_to_array_fn(batch):
speech_array, sampling_rate = torchaudio.load(batch["path"])
batch["speech"] = resampler(speech_array).squeeze().numpy()
return batch
test_dataset = test_dataset.map(speech_file_to_array_fn)
```
## Expected results
This piece of code should return test_dataset after loading audio features.
## Actual results
Reusing dataset common_voice (/home/jovyan/.cache/huggingface/datasets/common_voice/hi/6.1.0/b879a355caa529b11f2249400b61cadd0d9433f334d5c60f8c7216ccedfecfe1)
/opt/conda/lib/python3.7/site-packages/transformers/configuration_utils.py:341: UserWarning: Passing `gradient_checkpointing` to a config initialization is deprecated and will be removed in v5 Transformers. Using `model.gradient_checkpointing_enable()` instead, or if you are using the `Trainer` API, pass `gradient_checkpointing=True` in your `TrainingArguments`.
"Passing `gradient_checkpointing` to a config initialization is deprecated and will be removed in v5 "
Special tokens have been added in the vocabulary, make sure the associated word embeddings are fine-tuned or trained.
0%| | 0/3 [00:00<?, ?ex/s]formats: can't open input file `common_voice_hi_23795358.mp3': No such file or directory
0%| | 0/3 [00:00<?, ?ex/s]
Traceback (most recent call last):
File "demo_file.py", line 23, in <module>
test_dataset = test_dataset.map(speech_file_to_array_fn)
File "/opt/conda/lib/python3.7/site-packages/datasets/arrow_dataset.py", line 2036, in map
desc=desc,
File "/opt/conda/lib/python3.7/site-packages/datasets/arrow_dataset.py", line 518, in wrapper
out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs)
File "/opt/conda/lib/python3.7/site-packages/datasets/arrow_dataset.py", line 485, in wrapper
out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs)
File "/opt/conda/lib/python3.7/site-packages/datasets/fingerprint.py", line 411, in wrapper
out = func(self, *args, **kwargs)
File "/opt/conda/lib/python3.7/site-packages/datasets/arrow_dataset.py", line 2368, in _map_single
example = apply_function_on_filtered_inputs(example, i, offset=offset)
File "/opt/conda/lib/python3.7/site-packages/datasets/arrow_dataset.py", line 2277, in apply_function_on_filtered_inputs
processed_inputs = function(*fn_args, *additional_args, **fn_kwargs)
File "/opt/conda/lib/python3.7/site-packages/datasets/arrow_dataset.py", line 1978, in decorated
result = f(decorated_item, *args, **kwargs)
File "demo_file.py", line 19, in speech_file_to_array_fn
speech_array, sampling_rate = torchaudio.load(batch["path"])
File "/opt/conda/lib/python3.7/site-packages/torchaudio/backend/sox_io_backend.py", line 154, in load
filepath, frame_offset, num_frames, normalize, channels_first, format)
RuntimeError: Error loading audio file: failed to open file common_voice_hi_23795358.mp3
## Environment info
- `datasets` version: 1.16.1
- Platform: Linux-4.14.243 with-debian-bullseye-sid
- Python version: 3.7.9
- PyArrow version: 6.0.1
Hi ! Feel free to access `batch["audio"]["array"]` and `batch["audio"]["sampling_rate"]` instead
`datasets` 1.16 introduced some changes in `common_voice` and now the `path` field is no longer a path to a local file (but rather the path to the file in the archive it's extracted from) | [
-0.2775656283,
-0.3776993155,
-0.0082472647,
0.4291621149,
0.3689377308,
-0.1360182017,
0.2537411451,
0.2359366417,
-0.0651013181,
0.1566340774,
-0.4660598338,
0.40844661,
-0.0926309898,
-0.199382022,
-0.2011776865,
-0.3714813292,
-0.0002535676,
0.0689454377,
-0.0112086162,
-0.3186630607,
-0.1640423685,
0.1519650817,
-0.289106071,
0.2532100081,
-0.2725462914,
-0.0168539882,
0.3209070265,
0.4006576538,
-0.0706237853,
-0.2248729765,
0.1625490636,
-0.0675302669,
0.2533233464,
0.4339751005,
-0.0001023701,
-0.0965340063,
0.4900019169,
-0.1168495789,
-0.1525067985,
-0.3558964431,
-0.1749287993,
0.0059508723,
-0.1245109513,
0.0786948204,
-0.0639635175,
-0.1642856151,
-0.1353453845,
-0.3594503105,
0.4507935643,
0.3419062793,
0.282289505,
0.034008868,
0.0251499228,
-0.0112966392,
0.1772440672,
-0.0688359588,
-0.0507032014,
0.1708281487,
0.5350547433,
-0.1520442069,
0.0684928969,
0.1815200299,
-0.3204144835,
0.0101026604,
-0.0052159214,
-0.0850396231,
-0.1120698825,
-0.4039649665,
0.1757858247,
0.3050140738,
0.5727847219,
0.0104113631,
-0.1909098625,
-0.027471086,
-0.0009551758,
-0.1399877816,
0.2221496552,
0.0908387676,
-0.43337515,
0.1356167793,
-0.1859804541,
0.0185718667,
0.0616507009,
0.1024598554,
0.128092736,
-0.0766601935,
-0.0983077511,
0.0021528006,
0.2859976888,
-0.194478631,
-0.0382417552,
0.0539522581,
0.0376481302,
0.4715971947,
-0.3221790493,
0.1839038283,
0.070710063,
-0.4383623004,
0.2763041258,
-0.079498291,
0.1557020992,
0.2056287974,
-0.3275071979,
0.1634935439,
0.1494418383,
0.1401917338,
-0.068709448,
0.1186098382,
0.2255806476,
0.0223583747,
-0.1316258311,
-0.1353686303,
-0.2598270476,
-0.088894017,
0.1838303357,
0.0430765413,
0.2547590435,
-0.3414801657,
-0.4240109324,
0.0397765562,
-0.2352278233,
0.0677125603,
0.1790914088,
0.3522340953,
0.0764998868,
0.2863868475,
0.1509806067,
0.3391671777,
-0.1082463562,
0.0291214958,
-0.0664998665,
-0.0595574155,
-0.2695512176,
0.0288379304,
0.3297537267,
-0.1249559522,
0.3503782451,
0.0845231265,
0.301160574,
-0.3452721834,
-0.0260547325,
0.0206895955,
-0.2218716592,
-0.0104033258,
-0.0430315621,
0.2822882533,
0.0537844189,
0.3718708456,
-0.0474209376,
0.3020959795,
-0.2758892179,
-0.2245313972,
0.0279696342,
0.2639410496,
0.0790087506,
0.2853379548,
-0.1614023,
0.0973911285,
0.0320809558,
-0.3944585621,
-0.0308325887,
-0.2836866677,
-0.2875130177,
-0.0840969309,
0.3244912922,
0.148311466,
-0.142721653,
-0.0767551288,
0.1045793369,
-0.0893753394,
0.0931410789,
0.347902745,
-0.3023243845,
-0.1048498154,
-0.2285099775,
0.3357652426,
0.368268162,
-0.4564194679,
-0.4650276899,
0.0562664978,
-0.0527330339,
0.398204565,
-0.1469584107,
-0.0041051214,
0.1404031962,
0.0567934215,
0.5036771894,
0.601747632,
0.1836446077,
-0.0060183979,
-0.1497828811,
-0.1466088295,
0.1342189163,
0.161694482,
-0.1128837317,
0.1052241325,
-0.0919599608,
0.029522568,
0.275580138,
-0.0831503719,
-0.1115478128,
0.1827259064,
0.1846420914,
-0.0329643935,
-0.0071785841,
-0.1592686027,
-0.0524026006,
0.2403716147,
-0.1235482767,
-0.1075155586,
0.143625617,
-0.028121965,
-0.3436088562,
-0.1753863245,
-0.4537355006,
-0.0588073842,
0.1134342998,
0.2467362434,
-0.2134529352,
-0.1574382633,
-0.1915021092,
0.3806436956,
0.0662561208,
-0.0140020773,
-0.2688518167,
0.348633945,
-0.0817005411,
-0.0421658568,
0.2161830813,
0.3973359764,
0.2929592729,
0.1073887572,
-0.3877900243,
0.2837316394,
-0.0288241338,
0.3062717915,
-0.5626253486,
-0.1135610566,
0.1104352623,
-0.5467312336,
0.2170505673,
0.3450061381,
0.2646122575,
-0.2000184655,
0.0419416241,
0.3249726593,
0.3049278557,
0.0450547151,
0.1000535488,
0.0238694102,
0.375621289,
0.0265681744,
0.0113285473,
0.1897275597,
0.232913807,
-0.1197356656,
0.1864086092,
-0.0041919993,
-0.4241919219,
-0.2908018529,
0.2186310142,
-0.0906429067,
0.0691501051,
0.0861341283,
-0.248180747,
-0.0917136297,
0.0827762336,
-0.4892905653,
0.4508749843,
0.161406368,
0.0551868714,
0.0061133835,
0.0868340135,
0.0113806101,
0.0658005029,
0.1446921825,
-0.0056244982,
0.421150744,
0.1876623034,
0.1031543911,
-0.2897182703,
-0.1250756234,
-0.0392512828,
0.0202460289,
-0.3657716811,
-0.0641542375,
-0.1013477445,
0.2084374577,
-0.1297470033,
-0.3509401977,
-0.2030803412,
0.0944958106,
0.1675642133,
0.5011948347,
0.0834652409,
0.2807447314,
0.1111176684,
0.1322643012,
0.3202249706,
-0.084860459,
-0.1125429869,
0.2408457547,
-0.3072723746,
0.0831201896,
0.2101167887,
0.2146777958,
-0.1189008951,
0.208383128,
-0.0339248069,
-0.163277775,
0.1330923736,
0.0975151733,
0.1069639698,
0.2580432892,
-0.1872931719,
0.0731263757,
0.0813564286,
-0.3987402618,
0.159854874,
-0.0720450282,
-0.2160228491,
0.2186234444,
0.1455627531,
0.1081678569,
-0.0057014511,
-0.5721538067,
-0.3993855715,
-0.6159622073,
0.1075038388,
-0.1923453063,
0.0420981348,
0.2383657694,
0.0311728492,
0.11632137,
0.30178231,
0.243066445,
-0.314201951,
0.1047225669,
0.3863097727,
-0.1617360115,
-0.2655930817,
-0.2917965055,
-0.0094004478,
0.186047256,
0.0848334059,
-0.1888924837,
0.062136855,
-0.0022720359,
0.1255514771,
-0.2125147432,
-0.0585290343,
0.0535393208,
0.0995997563,
-0.0033101351,
0.0606535263,
-0.0625484586,
-0.1536844373,
0.2901513577,
0.3029937744,
0.0839190707,
0.3193398118,
-0.3014785647,
0.7779851556,
0.2231449783,
-0.0067082508,
0.1364191473,
-0.1222056299,
0.0535374023,
-0.314112097,
-0.3926666677,
0.0127629805,
-0.2338945121,
-0.1656204313,
0.1382952034,
0.1443331093,
-0.1803063005,
-0.192719847,
-0.0874613151,
-0.0969569311,
-0.1210340038,
0.0861170515,
-0.2263968438,
0.1752779484,
0.0244234558,
0.2689166665,
0.1144144833,
-0.0007015354,
0.0746662915,
0.0079749683,
0.0355682783,
-0.0821630135,
-0.3445731997,
-0.1732861102,
-0.1225753948,
0.1232130751,
0.2523660064,
0.5931093097,
-0.2285600454,
-0.0618403405,
-0.0251807384,
0.1983923018,
0.2744522691,
-0.0347915888,
0.1432389319,
0.224539578,
0.1686675847,
0.1079663783,
-0.1283828169,
-0.0928617492,
0.1111634895,
0.2386082262,
0.2421314269,
0.0759218857,
-0.0167227369,
-0.1276572943,
0.4179242849,
0.0036316984,
-0.0219185092,
-0.1984860599,
-0.2623964548,
-0.4287225902,
0.0371089727,
0.1399363726,
0.4724187851,
-0.399966836,
-0.2393102944,
0.299063772,
-0.0821679756,
0.3847708404,
0.0233366285,
0.359151721,
-0.0283463355,
0.3869360089,
0.2825085521,
-0.0142185744,
0.0892983377,
0.5933654904,
0.0290681068,
0.0104649439,
0.1265380234,
-0.0994549543,
0.1578973979,
0.3057092428,
-0.047724627,
-0.1067712083,
0.0144443205,
-0.0729010627,
0.0152449375,
0.1383894235,
0.3538694382,
0.0649704114,
-0.2871334255,
-0.2802413702,
0.4617189169,
-0.0008596765,
-0.1762373,
0.3594687879,
-0.2212922871,
-0.1102515683,
0.3707256913,
-0.3837511241,
0.8764624596,
0.0708293319,
0.1084736809,
0.3227963448,
0.0989101231,
-0.380833894,
-0.2795464694,
0.1421331614,
-0.1090360135,
-0.1840049922,
-0.0839042887,
-0.1289487183,
-0.1171469539,
0.1004980877,
-0.2110882699,
0.0496228747,
0.0002943946,
-0.0362539031,
0.1818130612,
-0.0122617921,
0.0027212326,
-0.2454779595,
-0.0778449774,
0.1370348632,
0.0707497969,
0.4157439172,
0.1571428478,
-0.1578107625,
-0.0006147256,
-0.3533928692,
-0.2018729746,
0.3469679952,
-0.281111598,
0.2563441396,
0.1692028791,
-0.3195557296,
0.2291394919,
0.2050092071,
-0.0580193065,
0.146836102,
-0.1854092628,
0.1503602415,
0.3394881487,
0.1636098772,
-0.1074402407,
-0.0992685929,
0.4505633414,
0.0023451783,
-0.3948910534,
0.3027384877,
-0.0366473533,
-0.1028057411,
-0.2446802557,
-0.128025353,
0.395668447,
-0.2602630556,
-0.2483677566,
0.0726762787,
0.0158214923,
-0.1586063802,
0.1971174628,
0.0951083153,
-0.4574140906,
0.0282148644,
0.315030545,
0.0891056508,
0.1058246642,
0.5308808684,
0.0150433611,
-0.3627030253,
0.5061199665,
0.1381922066,
-0.0677703321,
-0.2327655256,
-0.0393127948,
0.2710117996,
-0.1926365793,
-0.1103977636,
-0.0097814705,
-0.1917663515,
-0.1967784166,
0.3186353147,
0.0587892532,
-0.1559911519,
-0.0577647761,
-0.4568291008,
-0.5657244921,
0.1586943716,
-0.1017867774,
0.208977282,
-0.1678105146,
-0.1895646006,
-0.0267611872,
-0.0589294024,
-0.3870601356,
0.0548060797,
-0.0629780516,
0.0999606773,
0.2727042437,
-0.1642632335,
0.0447426736,
0.026562063,
0.237691775,
0.1752901524,
-0.0552950837,
-0.1856774241,
-0.0130158449,
0.175048098,
0.0867262408,
-0.3237159848,
-0.2292890847,
-0.146490261,
-0.1371443272,
-0.2236765623,
0.1038496196,
0.3640613258,
-0.0227916259,
0.0116909621,
-0.4050293565,
0.0824614391,
-0.0227244142,
0.1384685934,
-0.1226204932,
-0.0948358625,
0.1254441589,
0.1173161045,
-0.040981669,
-0.1395500451,
-0.5215927958,
0.0282290354,
0.1668887287,
-0.082876347,
0.2885006964,
-0.2074260563,
0.0233511925,
0.1534864753,
0.1783402711,
0.2290477753,
-0.4050220847,
0.1176889315,
0.1557597071,
0.3094681799,
-0.1979726553,
-0.1951977909,
-0.0555686802,
-0.3566170931,
-0.0404467843,
0.0997571051,
0.2639098167,
-0.2722426951,
0.0946088731,
-0.0635541826,
0.1149567366,
-0.0548704937,
0.0792760476,
0.2719778717,
0.0299536027,
-0.0729421452,
0.0918743759,
0.029944554,
0.2167277932,
0.5923703313,
-0.4247998595,
0.4326709211,
0.0075412216,
0.0145901563,
0.0859142989,
-0.5453366041,
-0.2712047398,
0.0135653978,
-0.2391560525,
0.1048220545,
-0.1249179095,
0.3304630518,
-0.4854198992,
-0.1703902185,
-0.1272078007,
-0.0533742756,
-0.2614302039,
-0.0968867689,
0.05321531,
-0.30268085,
-0.4047577679,
-0.1039195284,
-0.0108319968,
0.2150084376,
0.1584154963,
-0.0385054909,
-0.14627406,
-0.0074776602,
-0.0707793459,
0.3752868772,
-0.0927484781,
-0.244647339,
0.2193421125,
-0.012609086,
-0.0482432023,
0.4177976847,
0.1585616618,
0.3129561245,
0.3220406175,
-0.3420366049,
0.0735457167,
0.0566938333,
-0.1152908951,
0.1148511991,
0.3271974325,
0.1394390762,
0.3860528767,
0.1174217761,
0.2328113317,
-0.1968530864,
0.0947716311,
0.1058150977,
0.0853717029,
-0.4008973539,
0.2165904045,
-0.2477887869,
-0.2202736139,
-0.3081435263,
-0.1853176653,
-0.2964020967,
-0.177270785,
0.4417189956,
0.263834089,
0.2341616005,
-0.0154466154,
0.1204776391,
-0.1890435666,
-0.0524006933,
0.4060726464,
-0.0002388666,
-0.1810925454,
-0.0158085022,
-0.6611711979,
0.2545551956,
0.3181432486,
-0.05659898,
0.0791685879,
-0.0399325974,
0.1182331964,
0.0135496845,
-0.0089086927,
-0.2718969584,
-0.030505836,
-0.0282494295,
-0.1785373688,
-0.3677853346,
0.0287022833,
0.3526729643,
-0.0643632635,
-0.6398676634,
0.0371239111,
-0.0783630162,
0.1214115694,
-0.0991529375,
-0.2847298086,
-0.2997359335,
0.1232629716,
0.2765541673,
0.0773289725,
0.5063247085,
-0.1573219299,
-0.0077476855,
-0.2325657606,
-0.261767894,
0.1448506415,
-0.2761179805,
-0.0246341247,
0.6653169394,
0.0366607942,
0.16386953,
-0.3734435141,
0.0234404765,
0.0439297482,
-0.4295025468,
-0.4782462716,
0.1420397311,
-0.3743582368,
0.2113018781,
0.1343370676,
0.1192421392,
-0.1825226545,
0.0701647699,
-0.3490596712,
-0.4036956429,
0.5995510221,
-0.1338319927,
-0.4719957411,
-0.2161679715,
0.4260187447,
0.0523112267,
0.170532316,
-0.7036728859,
0.1421887875,
0.2175483704,
-0.057165876,
-0.1100411862,
0.0073118596,
-0.0814165398,
-0.1231750324,
-0.1164364442,
0.2122146338,
0.098608315,
-0.0790395439,
0.3134402037,
-0.2978109419
] |
https://github.com/huggingface/datasets/issues/3374 | NonMatchingChecksumError for the CLUE:cluewsc2020, chid, c3 and tnews | Seems like the issue still exists,:
`Downloading and preparing dataset clue/chid (download: 127.15 MiB, generated: 259.71 MiB, post-processed: Unknown size, total: 386.86 MiB) to /mnt/cache/tanhaochen/.cache/huggingface/datasets/clue/chid/1.0.0/e55b490cb7809dcd8db31b9a87119f2e2ec87cdc060da8a9ac070b070ca3e379...
Traceback (most recent call last):
File "/mnt/cache/tanhaochen/PromptCLUE/test_datasets.py", line 3, in <module>
cluewsc2020 = datasets.load_dataset("clue","chid")
File "/mnt/cache/tanhaochen/dependencies/datasets/src/datasets/load.py", line 1667, in load_dataset
builder_instance.download_and_prepare(
File "/mnt/cache/tanhaochen/dependencies/datasets/src/datasets/builder.py", line 593, in download_and_prepare
self._download_and_prepare(
File "/mnt/cache/tanhaochen/dependencies/datasets/src/datasets/builder.py", line 663, in _download_and_prepare
verify_checksums(
File "/mnt/cache/tanhaochen/dependencies/datasets/src/datasets/utils/info_utils.py", line 40, in verify_checksums
raise NonMatchingChecksumError(error_msg + str(bad_urls))
datasets.utils.info_utils.NonMatchingChecksumError: Checksums didn't match for dataset source files:
['https://storage.googleapis.com/cluebenchmark/tasks/chid_public.zip']
` | Hi, it seems like there are updates in cluewsc2020, chid, c3 and tnews, since i could not load them due to the checksum error. | 80 | NonMatchingChecksumError for the CLUE:cluewsc2020, chid, c3 and tnews
Hi, it seems like there are updates in cluewsc2020, chid, c3 and tnews, since i could not load them due to the checksum error.
Seems like the issue still exists,:
`Downloading and preparing dataset clue/chid (download: 127.15 MiB, generated: 259.71 MiB, post-processed: Unknown size, total: 386.86 MiB) to /mnt/cache/tanhaochen/.cache/huggingface/datasets/clue/chid/1.0.0/e55b490cb7809dcd8db31b9a87119f2e2ec87cdc060da8a9ac070b070ca3e379...
Traceback (most recent call last):
File "/mnt/cache/tanhaochen/PromptCLUE/test_datasets.py", line 3, in <module>
cluewsc2020 = datasets.load_dataset("clue","chid")
File "/mnt/cache/tanhaochen/dependencies/datasets/src/datasets/load.py", line 1667, in load_dataset
builder_instance.download_and_prepare(
File "/mnt/cache/tanhaochen/dependencies/datasets/src/datasets/builder.py", line 593, in download_and_prepare
self._download_and_prepare(
File "/mnt/cache/tanhaochen/dependencies/datasets/src/datasets/builder.py", line 663, in _download_and_prepare
verify_checksums(
File "/mnt/cache/tanhaochen/dependencies/datasets/src/datasets/utils/info_utils.py", line 40, in verify_checksums
raise NonMatchingChecksumError(error_msg + str(bad_urls))
datasets.utils.info_utils.NonMatchingChecksumError: Checksums didn't match for dataset source files:
['https://storage.googleapis.com/cluebenchmark/tasks/chid_public.zip']
` | [
0.0205239393,
0.0295573045,
-0.0395496488,
0.0844482556,
0.0949641019,
-0.0198280979,
0.0076568038,
0.3946432173,
-0.0262058005,
0.2592139542,
-0.1515903771,
0.1983184665,
0.0484179668,
-0.0398282781,
-0.2823028564,
0.4482048154,
0.1787071675,
0.0810302421,
-0.2217120677,
-0.0004592529,
-0.2948581874,
0.2038862854,
-0.0992099866,
-0.1695188731,
-0.2627165616,
0.0780272111,
0.0153833218,
0.1001415923,
-0.1690970808,
-0.6268137097,
0.3006021678,
0.1955676675,
-0.0522344597,
0.2808871269,
-0.0001166118,
0.0365727469,
0.3726640046,
-0.073075138,
-0.5593643188,
-0.0717509836,
-0.2208905071,
-0.2990595698,
-0.0081483545,
-0.1059825197,
0.0529326312,
0.43246153,
0.25306651,
0.1263706982,
0.0239466522,
0.212744996,
0.187034443,
0.542283535,
0.2504798472,
0.02149342,
0.381503433,
-0.3100494444,
-0.0011442831,
0.3562996984,
0.426805824,
0.0999453291,
-0.1088327914,
0.2821002305,
-0.0572432019,
0.1274631917,
0.1216994673,
-0.1302727312,
0.4892974794,
-0.2158912122,
0.0929882154,
0.3567411005,
0.069911547,
0.052594997,
-0.3715976477,
-0.1843431443,
-0.2772145569,
-0.0401454046,
0.4424698055,
-0.0774371997,
-0.3009836972,
-0.1931091398,
-0.3348333538,
0.2341248244,
0.0404925086,
0.1558526903,
0.1404580325,
0.200237751,
0.0396489836,
-0.1774278134,
-0.0274127424,
-0.2429529876,
0.0445172675,
-0.1543335617,
-0.1262359023,
0.0155008566,
-0.5700603127,
-0.1589836329,
0.2233875692,
0.5097833276,
0.2235782444,
0.3083148003,
0.1559409946,
0.4460000992,
-0.1267974377,
0.1355057508,
0.1128792092,
-0.008892158,
0.2417919636,
-0.065219596,
0.2127414346,
0.4899517596,
0.0348530039,
0.1085475832,
-0.1093509421,
-0.2123648375,
0.0701455474,
0.2057519853,
0.393455714,
-0.5251979232,
-0.2844409645,
0.092378974,
0.2056831121,
0.0305034388,
0.0872602165,
0.4240474701,
-0.3059846461,
0.3214539886,
-0.0781189501,
-0.1183027774,
-0.0742104799,
-0.1966412216,
-0.2594106197,
-0.1555036604,
-0.1906236112,
0.201448068,
0.11322961,
-0.1996067613,
0.2181131989,
-0.045657374,
0.528175652,
-0.0101789255,
-0.0427705944,
-0.046104379,
-0.0070127645,
0.2603494823,
-0.3032834232,
0.0928971618,
0.3188850284,
-0.0124075199,
-0.1309747845,
0.0017804346,
-0.1467471272,
-0.102906391,
-0.0309225526,
0.2080093771,
-0.3245437145,
-0.0507243015,
0.0004419328,
-0.3149621189,
0.3503745198,
-0.2040687203,
0.0790614337,
-0.3314083815,
-0.4112188816,
-0.3049839735,
0.0769908652,
0.1819637418,
0.1176731363,
0.0247489959,
0.320245415,
-0.1532862335,
-0.054933887,
0.2173607647,
-0.0079661086,
-0.0670026988,
-0.2816360295,
-0.1776653975,
0.1303810626,
-0.364354521,
-0.3068808615,
0.0444916561,
0.2426499724,
0.3270708025,
-0.0078732688,
-0.089635931,
-0.1705189198,
-0.3500797153,
0.1046049297,
-0.1888489276,
-0.1031407267,
0.0409991108,
-0.2448414564,
-0.2807189822,
0.2566519082,
0.0839844421,
0.0220419895,
-0.0129628098,
0.1029782295,
-0.3444347978,
0.2949877977,
-0.194067806,
-0.0485760905,
0.1569759995,
0.4601086974,
0.2263916582,
0.1617743522,
-0.1967441291,
-0.5187572837,
0.3473886847,
-0.1065845862,
0.14709346,
0.0592959672,
-0.2350486368,
-0.1692435741,
-0.2112556547,
-0.1805661768,
0.0260026734,
0.11999017,
0.3110151887,
0.208296597,
-0.0654687434,
-0.2179185599,
0.1659243554,
-0.3537534475,
0.1140284762,
-0.4319521487,
0.0390790179,
-0.1189012825,
-0.1733824462,
0.0607833527,
0.1820878536,
0.2217693031,
0.0144961635,
-0.1520422399,
0.5043878555,
0.0016952618,
-0.1385993063,
-0.4013765752,
0.3150391877,
-0.0464491472,
-0.120220378,
-0.1866141558,
0.3891030252,
-0.0158158019,
-0.1253191233,
0.0248358455,
0.398247838,
-0.1922909617,
0.2257640362,
0.2527516484,
-0.0866007134,
0.1290862262,
-0.1463697851,
-0.1449083984,
-0.1126569882,
0.2302120924,
-0.0087924525,
-0.2811586261,
0.0898897797,
0.1059202999,
0.0317416154,
0.1645517349,
-0.0207192451,
0.0350656994,
-0.0535593554,
0.3409253061,
-0.1307247281,
-0.1482589692,
0.5637937188,
0.2120074928,
0.1402404606,
0.0405662656,
0.1079324484,
-0.0075813695,
-0.048769664,
0.0493098274,
0.0707462132,
0.0628285408,
0.6440425515,
0.1324831098,
-0.1079412848,
-0.2843614221,
0.1643864959,
0.0573911443,
0.2595636547,
-0.2986545563,
-0.0714280456,
-0.4167110324,
-0.0769736692,
-0.0337848812,
0.0185283329,
-0.241277054,
-0.3044417799,
0.0462789498,
0.3548656106,
-0.1571391821,
0.355268389,
-0.6084524989,
-0.0246781409,
-0.0805026069,
0.0413974002,
-0.2579576671,
-0.2071685791,
-0.1221652701,
0.00742266,
0.3467196524,
0.0039420505,
0.23556979,
-0.4542527497,
-0.0809828937,
-0.3740086555,
-0.4232891202,
-0.026577482,
0.0168994591,
0.0706500188,
0.4562716782,
0.0762859955,
-0.2394340485,
-0.3309544325,
0.3979721069,
-0.4438554347,
-0.4625355005,
-0.0032545668,
-0.0718426555,
0.0076433541,
0.0243233312,
-0.2051755935,
0.0700264052,
-0.2006367445,
-0.0726418272,
0.0031584522,
0.1411225945,
0.4890058935,
-0.1666829586,
0.0116966711,
-0.324367255,
0.3560530543,
-0.2300129533,
-0.603892386,
0.5373361707,
0.0041271877,
-0.2508695126,
0.1404350847,
-0.2338135391,
0.1576086134,
0.1112471744,
-0.2945535779,
-0.2656663656,
-0.2629796565,
0.1558065265,
0.2234703302,
-0.3144834936,
0.1815429628,
-0.0736285001,
-0.1675925106,
-0.205290705,
-0.2486675233,
0.1280169636,
0.1054416671,
0.6178348064,
-0.1078163758,
0.4386001825,
0.106279254,
0.0664527863,
0.2654342949,
-0.0730496943,
0.1673178524,
0.1916292608,
0.4449683726,
0.0619921684,
-0.1254076809,
0.2031221688,
0.0201304406,
-0.0111202858,
0.1670359671,
0.0133449091,
-0.0120825116,
-0.1122233421,
0.0453818627,
-0.2770016193,
-0.2579876781,
-0.1144359112,
-0.0551878773,
0.2183942646,
0.0913466513,
-0.0559117049,
-0.0838789195,
-0.340973258,
0.2581699491,
0.2606914043,
-0.0653027222,
-0.1729129851,
-0.4955695271,
0.1446737349,
-0.0747656375,
0.1945996135,
0.3899949193,
0.5194447041,
-0.0148660252,
-0.1915920526,
-0.0279868618,
-0.0975452885,
0.2853043377,
-0.2776025534,
0.2794273198,
0.1410768181,
-0.0560629293,
0.0982168466,
-0.1859871447,
0.107362166,
-0.1812734604,
0.4319729805,
0.5027450323,
-0.2847529948,
-0.0371529274,
0.2642957866,
0.2209361941,
-0.0686655864,
-0.0402398258,
-0.4832042754,
-0.3760227561,
-0.2263736874,
-0.1188293546,
0.0133511676,
0.2314745188,
0.040371757,
0.0580943078,
0.0702851936,
0.2202136666,
0.1954810917,
0.0710578263,
0.0898738801,
0.2550933063,
0.2448249906,
0.0276722666,
0.1892066598,
0.3239457309,
0.5519055724,
-0.2263009548,
-0.423548907,
-0.1594569534,
0.12195611,
-0.0795147568,
0.2515517771,
0.0687141716,
-0.0143433828,
0.2096746415,
-0.0894426629,
0.3019871712,
-0.0346551687,
0.0069572218,
0.010422796,
-0.1727429479,
-0.1060307175,
-0.1021535918,
-0.2906179726,
0.0139973853,
0.0701923072,
-0.0572509691,
0.0729517266,
0.0333608314,
0.3499593437,
0.9044593573,
-0.0299703535,
-0.0015055919,
0.1364489794,
-0.2064926475,
0.3105818033,
-0.013108246,
0.1289232671,
-0.4047332406,
-0.3417665958,
0.0526773259,
-0.1292409152,
0.134412691,
0.0754792765,
0.0223153066,
0.4246022999,
0.2549257576,
0.5559670329,
0.1533725262,
0.0063621108,
-0.3285195529,
0.1550164223,
0.1077425256,
0.1577843577,
-0.1823287755,
0.1269424409,
-0.2822146714,
0.0604691133,
0.2293860912,
-0.3839116991,
-0.1244064271,
0.2561452091,
-0.4004997015,
0.297000885,
0.5153928995,
-0.2753521502,
-0.1944656223,
0.3843435347,
0.5611315966,
-0.0708706602,
-0.0479690693,
0.2429404557,
0.3300194144,
-0.0065500317,
-0.1101761535,
-0.0839330778,
0.1322522908,
-0.0656413138,
-0.2005913109,
-0.0851284936,
0.0477794521,
-0.4899038374,
0.0339001864,
-0.0799511671,
0.026674591,
-0.0278382841,
0.0006544117,
-0.3558601141,
0.1623045206,
-0.2985118628,
0.1752178222,
0.1393658072,
0.0201457925,
0.0010199316,
0.042370189,
-0.2721039355,
0.080144316,
0.432990253,
-0.1337448806,
-0.6535669565,
0.4542873502,
-0.0044528465,
-0.427800566,
-0.1909634322,
0.0794078335,
-0.2627647221,
-0.1131934971,
0.0568245389,
0.0419521555,
0.2401195616,
0.0060260566,
0.6591310501,
0.349126786,
0.1657244861,
0.1519950926,
-0.3658511043,
-0.2822930217,
0.1685167402,
0.0478576645,
0.5778890252,
-0.4022092819,
-0.2981970608,
-0.1359141171,
-0.0355885215,
-0.3124454916,
0.0486098006,
-0.3601729572,
0.0275778342,
-0.0807597786,
-0.0149016259,
0.1408480257,
-0.0015862485,
0.1234096661,
0.0164146479,
-0.1872555166,
-0.1987183988,
-0.0346603021,
0.1408710331,
0.2437601686,
-0.0594170988,
0.0090194512,
0.1353696734,
0.1089002639,
-0.2279275358,
-0.0814334154,
0.292734921,
-0.1028111428,
0.2149898261,
0.0307762772,
0.0726333931,
0.2026615143,
0.1297966689,
-0.2202096283,
0.0214358363,
0.0893647671,
-0.1559029967,
-0.133702442,
-0.0021033017,
0.5497700572,
0.1885076612,
-0.0517642573,
-0.2756682634,
0.1358587444,
-0.3187865913,
-0.4152075946,
0.2543829083,
-0.07570678,
0.2736639977,
-0.2111430466,
-0.1400436461,
0.4734270871,
0.2392010242,
-0.2305586487,
0.1665593386,
0.3649606407,
0.0390076563,
0.0511604473,
0.0604013316,
-0.167709589,
-0.7426767349,
0.5581026077,
0.130588904,
0.0065328553,
-0.4413611591,
0.175213173,
0.4062717855,
0.0407058783,
-0.2686922252,
0.2571073771,
-0.2379042357,
0.0444536544,
-0.0426583141,
0.110375084,
0.281981647,
-0.3454333544,
0.2616587579,
-0.1711386591,
-0.3084184527,
0.1316393614,
0.3534331918,
-0.1062842235,
-0.0799939409,
0.1559260637,
0.268129766,
-0.0105115697,
0.2158251405,
-0.5092619658,
-0.045997344,
-0.1351702958,
-0.1586690843,
-0.2395314574,
-0.2128157914,
-0.067041494,
0.2391541749,
0.0508103855,
0.0522366427,
0.2560403049,
0.0951372162,
-0.1300094575,
-0.2945826352,
-0.2070965916,
-0.0247078314,
0.1287183464,
-0.1773539037,
0.1372964978,
0.3348054886,
-0.011430731,
0.1443640441,
0.4518358707,
0.4200796783,
0.4497851133,
-0.0109917261,
0.15258196,
-0.2663467526,
0.0896033943,
0.0001821036,
0.6130698323,
0.0318993963,
-0.0901795551,
0.2523986995,
0.0682900175,
-0.1130865067,
-0.0179424249,
-0.4529593885,
-0.3976384401,
0.0925564319,
0.4579899311,
0.0501078218,
0.2200133204,
0.0806459561,
0.3446928561,
-0.3360456824,
-0.4264796078,
0.1056549847,
0.1569307148,
0.1843223721,
0.1847590208,
0.08211153,
-0.1814023405,
0.3130005598,
0.3953270614,
0.0391334966,
-0.1528163701,
-0.4517784715,
-0.633782506,
0.2174782157,
-0.0283924583,
0.142777279,
0.0718788058,
0.1151875034,
-0.0479998104,
0.1786781102,
0.2834110558,
-0.2628543079,
0.0079200035,
0.0707142651,
-0.1517154574,
0.0402613729,
0.1363260895,
-0.2921319008,
-0.0486329012,
-0.3082424998,
0.020424407,
0.2583465576,
0.0640818626,
-0.0241082627,
0.0546922088,
-0.216287449,
-0.0675585791,
0.0373142548,
0.1723099202,
0.680749774,
0.0211214088,
-0.2488488853,
-0.1345450133,
-0.3774263859,
0.0411603376,
0.3479447663,
-0.2653796971,
0.182635501,
0.0585581958,
0.1079766154,
-0.2556758821,
0.4046164155,
-0.054809127,
-0.4098207653,
-0.0956558809,
0.1009878442,
-0.035522107,
0.1058405042,
-0.0079621542,
-0.10153687,
0.0883194059,
0.2780563533,
-0.2106959373,
-0.2945198417,
0.7754062414,
-0.3177819848,
-0.1068809554,
-0.4317738116,
0.3329099119,
-0.1518368572,
-0.1776156425,
-0.7246079445,
0.0826957002,
0.3022236526,
0.4292643964,
-0.3144785464,
0.1821931899,
-0.3561338484,
0.1288217902,
-0.086051397,
0.3488552272,
-0.130796954,
-0.0561627373,
-0.2573386431,
-0.1736699343
] |
https://github.com/huggingface/datasets/issues/3369 | [Audio] Allow resampling for audio datasets in streaming mode | This requires implementing `cast_column` for iterable datasets, it could be a very nice addition !
<s>It can also be useful to be able to disable the audio/image decoding for the dataset viewer (see PR https://github.com/huggingface/datasets/pull/3430) cc @severo </s>
EDIT: actually following https://github.com/huggingface/datasets/issues/3145 the dataset viewer might not need it anymore | Many audio datasets like Common Voice always need to be resampled. This can very easily be done in non-streaming mode as follows:
```python
from datasets import load_dataset
ds = load_dataset("common_voice", "ab", split="test")
ds = ds.cast_column("audio", Audio(sampling_rate=16_000))
```
However in streaming mode it fails currently:
```python
from datasets import load_dataset
ds = load_dataset("common_voice", "ab", split="test", streaming=True)
ds = ds.cast_column("audio", Audio(sampling_rate=16_000))
```
with the following error:
```
AttributeError: 'IterableDataset' object has no attribute 'cast_column'
```
It would be great if we could add such a feature (I'm not 100% sure though how complex this would be) | 50 | [Audio] Allow resampling for audio datasets in streaming mode
Many audio datasets like Common Voice always need to be resampled. This can very easily be done in non-streaming mode as follows:
```python
from datasets import load_dataset
ds = load_dataset("common_voice", "ab", split="test")
ds = ds.cast_column("audio", Audio(sampling_rate=16_000))
```
However in streaming mode it fails currently:
```python
from datasets import load_dataset
ds = load_dataset("common_voice", "ab", split="test", streaming=True)
ds = ds.cast_column("audio", Audio(sampling_rate=16_000))
```
with the following error:
```
AttributeError: 'IterableDataset' object has no attribute 'cast_column'
```
It would be great if we could add such a feature (I'm not 100% sure though how complex this would be)
This requires implementing `cast_column` for iterable datasets, it could be a very nice addition !
<s>It can also be useful to be able to disable the audio/image decoding for the dataset viewer (see PR https://github.com/huggingface/datasets/pull/3430) cc @severo </s>
EDIT: actually following https://github.com/huggingface/datasets/issues/3145 the dataset viewer might not need it anymore | [
-0.5598964691,
-0.0399098508,
-0.0683553293,
-0.1406607926,
0.4281196594,
0.0794278383,
-0.0197002161,
0.3021991849,
-0.033088278,
0.3280914128,
-0.4938262999,
0.2927232385,
-0.2910311222,
0.2312466949,
0.0701237321,
-0.5171606541,
0.1303917319,
0.2717285156,
-0.3455243707,
0.1398271471,
-0.2682449222,
-0.0654539838,
-0.2622652948,
-0.2252087444,
0.1560017914,
-0.0156698041,
0.1735278666,
-0.3102470636,
-0.0653297603,
-0.4529252946,
-0.0891469643,
0.3677960634,
0.1712239832,
0.1947066486,
-0.0001203669,
-0.0321224108,
0.2326768935,
0.0323263891,
-0.3381857574,
0.0335203744,
-0.4890123904,
-0.098366797,
0.0262745451,
0.0182975195,
-0.0871642679,
-0.3974843919,
-0.0674021021,
-0.4369142652,
0.2930742502,
0.1030170694,
0.1569401622,
0.1917748153,
-0.2427002043,
0.1174413711,
-0.0916100442,
0.2473447323,
-0.3325561285,
-0.041915454,
0.4605768323,
0.3699425459,
0.0335211605,
0.4571172297,
-0.2985770404,
-0.0418990105,
0.2328646481,
-0.1949791163,
-0.3876962066,
-0.4129319787,
0.1136504859,
0.3623906076,
0.8246936798,
-0.4015908837,
-0.6885800958,
-0.3606872857,
0.4200985432,
-0.28961882,
0.0069405716,
0.1210591942,
0.0363535881,
0.3133989275,
-0.6834567785,
-0.0354338773,
-0.0789949745,
0.0939757451,
0.2813484967,
0.0568506531,
-0.0956186801,
0.1105108559,
0.4091547728,
-0.0617096163,
0.015261515,
-0.0467480421,
0.1105088145,
0.2546934783,
-0.433901459,
-0.3304507136,
-0.1578675658,
0.0685289428,
0.1256449074,
0.2860119343,
0.2917950451,
0.1781577468,
0.1397670209,
0.0354885198,
0.2003245056,
-0.0622386783,
-0.1327773184,
-0.1232486218,
0.3926630914,
0.0761820748,
0.1704778224,
-0.1057643592,
0.0450054817,
0.0572168715,
0.1658797413,
0.1689324081,
0.0899032056,
0.0406297967,
-0.0986580774,
-0.1070592701,
-0.2073839307,
-0.1325086951,
0.1452479511,
-0.0369638018,
0.1878554821,
0.3012838364,
-0.1913865358,
0.430410862,
0.1752293855,
-0.3052101731,
0.0226301104,
-0.1105509549,
0.0853921846,
0.2571443319,
0.3357307315,
-0.2983858585,
0.0257936716,
0.2341619581,
0.1361132562,
-0.0246286597,
0.1538066715,
-0.0182856824,
-0.1262567192,
0.3877311349,
-0.1808005273,
0.0116172452,
-0.0810279846,
0.203710407,
-0.1931934208,
0.1173009574,
0.0319549255,
-0.2637952566,
-0.1154090837,
0.0591807626,
-0.2955646515,
-0.0894156545,
-0.1874346733,
0.4970229566,
-0.1415202171,
-0.3647657335,
0.3241900504,
-0.0609259754,
-0.2746298015,
0.0272674859,
0.4525730908,
0.0354374051,
-0.3755996823,
-0.2120317966,
-0.2530657947,
-0.2939555943,
0.0297839604,
0.0827855095,
-0.0162831489,
-0.1302708089,
0.0117435837,
0.0667450055,
0.5063064694,
-0.2447976768,
-0.4294306338,
0.043009188,
0.1563765556,
0.3383908272,
0.3311876655,
0.1683517992,
0.3549141586,
-0.0742811337,
-0.2611412108,
0.4684113264,
-0.2120689601,
-0.1101263165,
0.0261666868,
-0.238448292,
0.0417777598,
0.3851337433,
0.0402712859,
0.4039867222,
0.0888828337,
-0.0697816908,
0.0750931874,
-0.2377978712,
0.2597146928,
-0.2038574964,
0.1237972006,
-0.069607541,
-0.0331981145,
-0.662914753,
-0.1328340322,
-0.0041190078,
0.3424854279,
-0.079508014,
-0.0707865953,
-0.3367102742,
0.0916643664,
-0.1431745142,
-0.1482677013,
0.1533523351,
-0.0225262828,
0.0875021815,
0.1096364036,
-0.0746959224,
-0.555377543,
0.2079331279,
-0.1297472864,
-0.046614524,
-0.0533398278,
0.1536363661,
0.2858563066,
0.0079616075,
-0.085196279,
0.3947863281,
-0.0918582007,
0.0338212326,
-0.043201901,
0.3198714256,
-0.158431381,
0.4796307683,
-0.3276027441,
0.4650476873,
0.2236869484,
-0.322612226,
0.1083135903,
-0.1004635617,
0.1354130656,
-0.1560813785,
0.0584064387,
0.3667319119,
-0.0449779965,
0.3632375896,
0.0312744305,
0.0641759634,
0.0913880244,
0.1403015256,
-0.5115069747,
-0.1760685891,
-0.0995323583,
-0.379497081,
0.2250062376,
-0.2498202175,
-0.5284560919,
-0.1130747423,
0.2394347936,
-0.2140520215,
0.0055777691,
0.1783907264,
-0.1548200548,
-0.0143348835,
0.2795885205,
0.2609133422,
0.3595249951,
0.2127410769,
0.1786491424,
0.1582677811,
0.1146974489,
0.0140508972,
0.1314160079,
0.2866766453,
-0.0658218041,
0.3254795671,
0.0162510462,
0.142925635,
-0.3953852654,
-0.2037037015,
-0.003360735,
0.0095853284,
-0.1751021743,
-0.202412352,
-0.2956284881,
-0.2708905041,
-0.0857384577,
-0.122995764,
0.0645835325,
-0.0795368701,
0.1414581537,
0.4497592449,
-0.3392569721,
0.4384878874,
-0.2527059317,
0.3999792039,
-0.1697008312,
-0.2039752007,
-0.2398076355,
0.2169280946,
0.1976420283,
0.0144114401,
0.071507372,
-0.2192699164,
0.2823610306,
0.00472291,
0.1325935721,
-0.1955919266,
-0.1182722598,
0.130611375,
-0.1359402835,
0.1313453913,
0.189599812,
0.0327004269,
-0.0404893123,
-0.4407273233,
0.229077667,
-0.0287529528,
0.1128964797,
0.1084502935,
0.0070406785,
0.2582616806,
-0.094579719,
-0.0233602282,
-0.3155885041,
-0.6960616708,
0.2818810046,
-0.3225008547,
0.0250319056,
0.1615467668,
0.0628371909,
0.1684764475,
-0.0432701893,
0.3091671169,
-0.1517888457,
-0.2186588496,
0.3302001953,
-0.1230873168,
-0.1245761737,
-0.2127514184,
-0.0225110203,
0.1818176061,
0.4256775975,
-0.3486188054,
-0.0656613559,
-0.1732284725,
0.0241670422,
-0.0624977164,
0.0327278636,
0.1499395818,
0.1444973648,
0.0231250301,
0.0023073454,
-0.1343536377,
-0.4355955422,
0.273970753,
-0.0955987498,
0.1293878406,
0.5151429772,
-0.1318726838,
0.447442621,
0.3629910052,
0.313344866,
0.2865398526,
-0.0460871197,
0.2860625386,
-0.2387082577,
-0.378744036,
0.173796013,
-0.0590652078,
0.0332940407,
0.1377925575,
0.184261471,
-0.207221821,
-0.1810016781,
-0.078748472,
0.1151814461,
-0.1860613376,
0.0834218934,
-0.1951420456,
0.253248632,
-0.1600842625,
0.156817928,
-0.034590181,
-0.0581875667,
-0.0279612467,
0.0836129487,
0.2791209519,
-0.0833002776,
-0.3066179454,
-0.4866763651,
-0.2914270163,
0.0955871344,
0.1750320196,
0.5122283101,
-0.068771407,
-0.1692860723,
0.1857670993,
0.3781017661,
0.4815124273,
-0.5776332617,
-0.3868358731,
0.0207089242,
0.0037420865,
-0.1410171688,
0.0809448957,
0.0158830751,
-0.0862482563,
-0.1432167739,
0.193152234,
0.1532208025,
-0.0627321377,
0.4182988703,
0.4994646311,
0.1091144681,
-0.1783352047,
-0.0539808832,
-0.2999812067,
-0.2225380987,
-0.0408959873,
0.0028835689,
0.0062606046,
0.1057181135,
-0.1147127002,
0.0693343356,
-0.1486614794,
0.2531566024,
0.1648678631,
-0.0569326654,
0.2117245495,
0.3611032367,
0.2800352275,
-0.3783785403,
0.0692654699,
0.5230358243,
0.0088702114,
-0.2370611131,
0.0127735427,
-0.0012619888,
0.4562956095,
0.0436406247,
-0.0141555201,
0.2382112443,
0.1924015731,
0.2572331727,
-0.4802798629,
-0.2088842541,
0.3378113508,
0.005960572,
-0.4411755204,
-0.6721192598,
0.6792968512,
0.1450143456,
-0.1142187789,
0.4305589497,
0.3736321032,
-0.1858484894,
0.0795414671,
-0.1085572839,
0.9664979577,
0.1818275154,
-0.0300857332,
0.0671295449,
-0.5536279678,
0.3821775615,
-0.2383625954,
0.1900320053,
0.3980686963,
-0.2658903897,
-0.2206993997,
0.0083441669,
0.330568254,
0.0218019132,
-0.5635305643,
0.124225527,
-0.1040978059,
0.1128504276,
-0.0590708852,
0.0643362254,
-0.6190642118,
-0.3866361976,
-0.1121423021,
0.0485296808,
0.069637239,
-0.1246291175,
0.1827076674,
0.1125911027,
0.4296973348,
0.1243007854,
-0.4868308306,
-0.1984970123,
0.1318761855,
-0.1331038177,
-0.1318739057,
-0.4116138518,
0.6284086108,
0.2727989554,
0.0072207353,
-0.0612161756,
-0.1836084723,
0.1065217257,
0.0265174843,
0.5215782523,
-0.0324294008,
-0.0070759812,
0.4097795188,
0.0251554269,
-0.2747701406,
0.1247873828,
0.1791251153,
-0.0945370346,
-0.0071252361,
-0.2265263349,
0.2767662406,
-0.3535380661,
0.0665820017,
-0.0603306442,
0.2217217535,
-0.2974176407,
0.0587467998,
-0.1907995045,
-0.1143996343,
0.3893796802,
-0.158321932,
-0.1215271056,
-0.1899536997,
0.4219995439,
0.0474538766,
-0.069248192,
0.3565942049,
-0.0880388021,
-0.3439073861,
-0.2002018541,
-0.0193752367,
-0.102767624,
-0.3906252384,
0.117496103,
0.0868699551,
-0.1683556288,
-0.1642104089,
-0.0576984882,
-0.1250843704,
-0.0705861226,
-0.2967187166,
-0.1362574697,
-0.3736180067,
0.1372410208,
0.1628299505,
0.3150419891,
-0.2694858611,
0.0932945237,
-0.0231873617,
-0.1227902323,
-0.233065024,
-0.30393067,
-0.0167637356,
-0.0294770673,
0.1320686042,
0.2449350059,
0.0717916712,
-0.0114134559,
0.0847046375,
0.0469744429,
-0.2014749348,
-0.0037202467,
-0.2259809673,
0.2696405351,
0.098644644,
-0.3075965643,
0.1587889344,
-0.0193347465,
-0.3103268743,
-0.2964799106,
0.2524902523,
0.1398341805,
0.0560438931,
0.2703605592,
0.0654859915,
-0.136561051,
0.0654378161,
-0.0009241416,
0.0183535088,
0.082098946,
-0.013750758,
0.2751152515,
0.2115260065,
-0.0503411666,
-0.1750101,
0.3620119393,
0.2055371404,
-0.323936224,
0.4945879281,
0.2106821239,
0.223815605,
0.1718094796,
0.6017055511,
0.3104684949,
-0.0894114971,
-0.1237309799,
0.2935155034,
0.1610098779,
-0.2413635701,
-0.0555547588,
-0.0306255016,
0.089942798,
0.2706997395,
0.1324170232,
0.0480885543,
-0.0290389843,
0.2829750776,
-0.2252671421,
0.5118091702,
-0.234639883,
0.450938195,
0.6072260737,
0.2393103093,
-0.093172282,
0.1447882801,
0.1498686075,
-0.002036223,
0.0123884371,
-0.4864763319,
0.280949384,
0.1860972047,
0.0765745342,
0.152640745,
-0.1864564866,
0.3067274094,
0.2064673603,
-0.2009883523,
0.2020995766,
0.1064390242,
0.2596050203,
-0.3584662378,
0.0255974252,
-0.1057291254,
0.2342340499,
0.1223959774,
-0.0370592698,
-0.0668819919,
-0.1858843565,
-0.0621016845,
-0.0485922545,
0.1945038289,
0.0871449038,
0.4197335243,
0.0125046186,
0.2163473368,
-0.3203943074,
-0.050633803,
0.0508360974,
0.407980442,
-0.1929759234,
-0.0404133201,
0.3457545042,
0.0474933311,
0.5418798327,
0.4310179949,
0.1690517813,
-0.0378618389,
-0.0142378332,
0.2116012424,
-0.1586613655,
-0.1254811734,
0.0493007638,
0.4199091792,
0.106191881,
0.3339324594,
0.1359175742,
0.0237521362,
0.0078207003,
0.1582541168,
-0.2044133097,
0.0477126241,
-0.6289092302,
0.244742766,
-0.0383940935,
-0.218982473,
0.0458650291,
-0.2910510004,
-0.1088510901,
-0.0264407229,
0.2676314712,
-0.3767401278,
-0.0979489759,
0.0708763525,
0.0155715169,
-0.0025131456,
0.2264439017,
0.2725876868,
-0.1274739355,
0.1182962134,
-0.110064283,
-0.3450423777,
-0.3014411926,
0.2346454561,
-0.3035306633,
0.2549259663,
-0.0963407531,
0.0561595745,
0.1659161597,
0.0617334843,
-0.2606555521,
-0.252851665,
0.1175475493,
0.0788260102,
-0.4296088517,
0.0098488638,
0.3841173947,
-0.1937493831,
-0.2261958718,
0.1589923203,
0.0942537934,
-0.0759707391,
-0.2563559711,
0.0820444301,
-0.0969725624,
-0.3684614897,
0.2380080521,
0.1630129367,
0.4598295391,
-0.1915070713,
0.1268432885,
-0.0694108382,
-0.241810739,
-0.3325923979,
-0.0238560047,
-0.0346762165,
0.60032022,
-0.1719807982,
-0.0737830102,
-0.146972701,
0.1752538681,
-0.1168584526,
0.0474711619,
-0.3408417106,
0.2346305102,
-0.2626020014,
0.2083830833,
0.0286019593,
-0.1527557671,
0.0587040409,
0.2868026495,
-0.2934838831,
-0.4076113701,
0.5044672489,
-0.1380756646,
-0.3618250787,
-0.0542218126,
0.2434622794,
-0.0854940787,
-0.002067388,
-0.8937118053,
0.0056289169,
0.2358639389,
-0.1175250411,
0.1431512386,
0.6481894851,
0.1067203283,
-0.2441443354,
-0.133555904,
0.229168117,
0.0310167652,
-0.0794960707,
0.106856741,
-0.2885811329
] |
https://github.com/huggingface/datasets/issues/3369 | [Audio] Allow resampling for audio datasets in streaming mode | Just to clarify a bit. This feature is **always** needed when using the common voice dataset in streaming mode. So I think it's quite important | Many audio datasets like Common Voice always need to be resampled. This can very easily be done in non-streaming mode as follows:
```python
from datasets import load_dataset
ds = load_dataset("common_voice", "ab", split="test")
ds = ds.cast_column("audio", Audio(sampling_rate=16_000))
```
However in streaming mode it fails currently:
```python
from datasets import load_dataset
ds = load_dataset("common_voice", "ab", split="test", streaming=True)
ds = ds.cast_column("audio", Audio(sampling_rate=16_000))
```
with the following error:
```
AttributeError: 'IterableDataset' object has no attribute 'cast_column'
```
It would be great if we could add such a feature (I'm not 100% sure though how complex this would be) | 25 | [Audio] Allow resampling for audio datasets in streaming mode
Many audio datasets like Common Voice always need to be resampled. This can very easily be done in non-streaming mode as follows:
```python
from datasets import load_dataset
ds = load_dataset("common_voice", "ab", split="test")
ds = ds.cast_column("audio", Audio(sampling_rate=16_000))
```
However in streaming mode it fails currently:
```python
from datasets import load_dataset
ds = load_dataset("common_voice", "ab", split="test", streaming=True)
ds = ds.cast_column("audio", Audio(sampling_rate=16_000))
```
with the following error:
```
AttributeError: 'IterableDataset' object has no attribute 'cast_column'
```
It would be great if we could add such a feature (I'm not 100% sure though how complex this would be)
Just to clarify a bit. This feature is **always** needed when using the common voice dataset in streaming mode. So I think it's quite important | [
-0.6024314761,
-0.0808148235,
-0.0422009751,
-0.2135421187,
0.3806146681,
0.1127745584,
0.0144633567,
0.2519489825,
0.0138039561,
0.2485650629,
-0.3896241188,
0.1837809682,
-0.3210382164,
0.1334297508,
0.1642042547,
-0.5897549987,
0.0861243829,
0.2284358144,
-0.229306072,
0.167026341,
-0.298789233,
-0.0955020189,
-0.3329717517,
-0.1571077406,
0.1022993848,
0.1447293907,
0.222540617,
-0.3377623558,
0.0548393019,
-0.3384966552,
-0.0646334738,
0.2114457786,
0.2674554288,
0.0965918079,
-0.0001257374,
-0.0854984671,
0.2478480786,
-0.0679958835,
-0.3901005685,
0.158953324,
-0.5542157888,
0.067680493,
-0.1004353091,
0.0476201624,
-0.1302351654,
-0.1908661127,
-0.0563311353,
-0.5732032657,
0.136859268,
0.1082517803,
0.1278051436,
0.2179529667,
-0.2663604617,
0.1351760179,
-0.1616491824,
0.1694020927,
-0.2354830354,
-0.0537659526,
0.5048764944,
0.3012889326,
0.2511204481,
0.3638688326,
-0.2726716101,
-0.1642736793,
0.0922270417,
-0.1838952303,
-0.295701772,
-0.2303821743,
0.1350542009,
0.2944710553,
0.8150236607,
-0.3671538234,
-0.6954243183,
-0.2497062981,
0.4832060039,
-0.2975670099,
-0.0328977592,
0.0806670487,
-0.0124632381,
0.2951920033,
-0.5460269451,
-0.1597818434,
0.0051028579,
0.0898863003,
0.4040819705,
0.1940104961,
0.004753965,
0.2358748913,
0.2245159447,
0.0899889395,
-0.1039953306,
-0.0183037166,
0.0602892339,
0.2668855488,
-0.4264030457,
-0.3326765001,
-0.1683619022,
-0.0646401867,
0.0576083176,
0.344330281,
0.30420807,
0.0380650423,
0.2318453342,
0.0078521781,
0.2900830507,
0.0886502415,
-0.0438121744,
-0.090109244,
0.3457846045,
-0.0072194068,
0.1294018477,
-0.1127484068,
-0.0147214793,
0.1465836167,
0.3457089663,
0.314378649,
-0.0088048326,
0.0818370879,
-0.1239767745,
-0.2211269289,
-0.3167391121,
-0.1105653271,
0.1200031415,
-0.0954627916,
0.1746875346,
0.3110337555,
-0.1437131464,
0.3815573454,
0.1939740181,
-0.3401262164,
0.0880545974,
-0.0682978109,
0.0888450667,
0.1828062683,
0.2651686966,
-0.2585707605,
-0.0408046395,
0.068243891,
0.1754034162,
-0.0550496802,
0.0423604175,
0.1111363396,
-0.2742334902,
0.3944738209,
-0.2122160494,
0.0233510416,
-0.1102669984,
0.2369284034,
-0.2043551952,
0.199848175,
-0.0419021547,
-0.3743374944,
-0.1691484153,
0.0395264477,
-0.0982367471,
-0.1607602686,
-0.1427269876,
0.3999090493,
0.0501883775,
-0.5179522634,
0.3408996463,
-0.0464132279,
-0.2597556412,
0.0350754261,
0.3868282139,
-0.1138804331,
-0.3601966202,
-0.2531297207,
-0.3627951741,
-0.1765453368,
0.1159471571,
0.0598623231,
-0.072766304,
-0.1781722307,
-0.0272693783,
0.112395592,
0.565053761,
-0.2266338021,
-0.3823522329,
-0.0494315736,
0.0712145716,
0.1906712204,
0.3396057785,
0.2029527277,
0.3147723377,
-0.0605216064,
-0.1098324507,
0.5848615766,
-0.3147225976,
-0.2007442713,
0.1251938194,
-0.1108497605,
0.1276840419,
0.2793222666,
0.0600063764,
0.5081894994,
0.117060408,
0.1362504959,
0.0914392546,
-0.1538921893,
0.3566672206,
-0.2688870728,
0.1758111566,
-0.1388545632,
0.0520280935,
-0.7049440742,
0.0672563389,
-0.0748038962,
0.4246906042,
0.0107120052,
0.0067703184,
-0.354839921,
0.0119817751,
-0.1269952804,
-0.0495496467,
0.0889951587,
-0.1090162322,
0.0868242979,
0.1365493536,
-0.1654486358,
-0.490814656,
0.090920426,
-0.1161014885,
-0.1705885679,
0.055459369,
0.190637961,
0.2443395555,
-0.0303744636,
-0.1688749939,
0.4183925986,
-0.1460687816,
0.136845693,
-0.0649684593,
0.2457858175,
-0.2650140524,
0.3029287159,
-0.4057220817,
0.4702973962,
0.117788516,
-0.2647189498,
0.0033727454,
-0.0010421678,
0.1368799657,
-0.2313432246,
0.1890958101,
0.2984489202,
0.0341685191,
0.3643500507,
-0.014410113,
0.1199474409,
0.0379282422,
0.2009968311,
-0.4103998244,
-0.1297922283,
-0.1634488851,
-0.4099448621,
0.0937633887,
-0.4416301847,
-0.412093699,
-0.0799752921,
0.2196521163,
-0.1746465564,
0.1808496714,
0.0953845531,
-0.087336354,
0.0672309026,
0.2640421689,
0.2320888489,
0.4842663407,
0.1886729002,
0.1950706989,
0.1433523446,
0.1232796386,
0.036126107,
0.1084078848,
0.1832451671,
-0.0764604956,
0.3511442542,
-0.0441496596,
0.1738618314,
-0.3206017017,
-0.3172958791,
0.0518085957,
0.1127602607,
-0.1752172709,
-0.2109659016,
-0.1153058708,
-0.0869181305,
-0.1331063211,
-0.1700467318,
0.1246145666,
-0.0940027609,
0.1345459819,
0.3608813584,
-0.296995312,
0.4194316864,
-0.3233666122,
0.2849726081,
-0.0968680829,
-0.3261500597,
-0.1435248405,
0.2672150433,
0.1383121759,
-0.02013609,
-0.0094703669,
-0.329898715,
0.1966285706,
0.0633454099,
0.211581558,
-0.1016057134,
-0.1822285205,
0.0812003911,
-0.1094365641,
0.0419492759,
0.1577656269,
-0.036188487,
0.0174966715,
-0.4359198511,
0.2111794651,
-0.0911222622,
-0.0363245755,
0.2014133334,
0.03565358,
0.2645157874,
-0.1226748601,
-0.1137769744,
-0.3491102159,
-0.589599967,
0.114550136,
-0.4072106183,
-0.0446325578,
0.0487248972,
0.0761516467,
0.0665820464,
-0.0000295839,
0.2822223306,
-0.1683340371,
-0.0392492265,
0.2877062559,
-0.0090125324,
-0.0097020473,
-0.3064914644,
-0.1010028273,
0.2183203101,
0.4222792685,
-0.1188966036,
0.0237120334,
-0.0312064663,
0.0597121567,
-0.1193271354,
0.0539657511,
0.2710428238,
0.1264553368,
0.0650934279,
0.1222976968,
-0.0701295659,
-0.4205694199,
0.5263473392,
-0.0548206419,
0.1206317097,
0.4947753251,
-0.1967800707,
0.4123308957,
0.2588609159,
0.3553023338,
0.2561068833,
-0.1436946988,
0.1715216339,
-0.2904478312,
-0.3604464233,
0.2238664627,
-0.0934182778,
-0.1450110823,
0.0026306072,
0.2520749569,
-0.1932735443,
-0.1433030218,
-0.1926013678,
0.1502802372,
-0.0768266916,
0.1203026325,
-0.1739227474,
0.3177134097,
-0.1544357091,
0.0748130083,
-0.0053069582,
-0.0749394372,
0.0409085415,
0.0888643265,
0.2233667672,
-0.0632054806,
-0.2276120931,
-0.6805044413,
-0.127472192,
0.0430451967,
0.3156878352,
0.6950064301,
-0.1332972944,
-0.1316452622,
0.1083313227,
0.3656454384,
0.3605049849,
-0.6083496809,
-0.316737175,
-0.0296354108,
0.1873720884,
-0.021030793,
0.0179990828,
0.138529405,
0.0089869779,
-0.1513687819,
0.0883045867,
0.1176567897,
0.1365620941,
0.4329197407,
0.5436357856,
0.0419225171,
-0.2869544923,
-0.1035443693,
-0.239187181,
-0.2503901422,
-0.1199545562,
0.1128803045,
0.1459534764,
0.2381519973,
-0.0022267904,
0.1109278426,
-0.2509694695,
0.3066801727,
0.0057876608,
-0.1298122704,
0.2391673177,
0.3006612659,
0.1039879024,
-0.4084689617,
-0.064318791,
0.551053524,
0.0421652533,
-0.1001242697,
0.0288333744,
0.0753879845,
0.6066588163,
-0.0975558683,
-0.0274867285,
0.2787375748,
0.2440752089,
0.143839702,
-0.3275044858,
-0.3098326921,
0.2340461314,
0.0554769225,
-0.3882561922,
-0.703047812,
0.6461317539,
0.0611024164,
-0.0543817393,
0.4734863937,
0.2848436832,
-0.1898483932,
0.0397215039,
-0.3447401822,
0.9931418896,
0.1852611154,
0.0094927941,
-0.0191229247,
-0.5150282979,
0.2438690513,
-0.2308770418,
0.2319349349,
0.3214798272,
-0.1391092837,
-0.2702376246,
0.0128266187,
0.26456967,
0.0635699928,
-0.5469481945,
0.1371050328,
-0.218783468,
0.1465163082,
0.0070338747,
-0.0360291116,
-0.6089008451,
-0.2526057959,
-0.0019336896,
-0.0515012108,
0.0979466289,
-0.0461574867,
0.2848577201,
0.1800874472,
0.3531498015,
0.0530972667,
-0.5285074711,
-0.1348243654,
0.1775377393,
-0.1918285191,
-0.0866895169,
-0.2824349105,
0.5665386915,
0.1802237034,
-0.1427269429,
-0.0097018741,
-0.1670137197,
0.1509014815,
0.0408581346,
0.4737108052,
0.0164008364,
-0.026239166,
0.4340789914,
-0.0002761588,
-0.4203281403,
0.2530021071,
0.0798565745,
-0.3311153948,
-0.0788619965,
-0.1614262611,
0.4523147345,
-0.2848683894,
-0.0206157081,
0.140073061,
0.1920530945,
-0.3493876159,
0.0247834381,
-0.1556294709,
-0.1710518152,
0.402901113,
-0.1684316546,
-0.0183689091,
-0.1857442856,
0.5400934219,
0.1764063984,
0.0262718182,
0.4037335515,
-0.2301867008,
-0.2897693813,
-0.1598509848,
-0.1497057527,
-0.0471161343,
-0.343002677,
0.1004360765,
0.0430770144,
-0.1567969024,
-0.1158228368,
-0.0480733514,
-0.1084845364,
0.0570447855,
-0.4257650375,
-0.2962469459,
-0.3870545328,
0.0756919831,
0.2115496546,
0.103431128,
-0.2722021937,
0.1900083125,
0.0014473525,
-0.1328640282,
-0.19158566,
-0.48238644,
0.1275786161,
0.0316581912,
0.0696974769,
0.2834917605,
0.0904593095,
0.0518180951,
0.1039908901,
0.0260460638,
-0.0675844848,
0.0547261909,
-0.110293515,
0.2813775241,
0.1335515827,
-0.1073102504,
0.0632827729,
-0.0543725081,
-0.3630374074,
-0.2520644069,
0.1569718868,
0.1408705264,
0.0051173535,
0.1829425991,
0.0379601792,
-0.2728694081,
-0.0086255539,
0.0659201816,
-0.0194208138,
0.1096877232,
-0.0177254062,
0.3624049127,
0.2917512357,
-0.0009839782,
-0.3663062751,
0.2785957456,
0.0815032274,
-0.3289595842,
0.4984934628,
0.0992349014,
0.2033848166,
0.0725248456,
0.6048859358,
0.2688616812,
0.0445691645,
-0.0649256855,
0.2292846888,
0.108352825,
-0.2772327363,
-0.0676426291,
-0.1790800095,
0.1209861711,
0.226547569,
0.1403031498,
0.0710871816,
-0.1587757617,
0.310094893,
-0.2894697189,
0.4034778476,
-0.1760330498,
0.3369939327,
0.6436725259,
0.3651531637,
-0.0163837764,
0.1497217268,
0.0524562187,
-0.0695545152,
-0.0810746476,
-0.5119350553,
0.3511393964,
0.2934449613,
-0.027000552,
0.1541671753,
-0.1355478317,
0.4003796875,
0.144538179,
-0.099381417,
0.276653707,
0.2369731069,
0.2902300358,
-0.3972688913,
0.1528083235,
-0.0593015999,
0.0786136538,
0.0531954132,
0.0381766483,
-0.0092663122,
-0.1603259742,
-0.0321440957,
-0.1524918824,
0.2856950462,
0.1986968964,
0.3741995692,
-0.148901239,
0.1901917756,
-0.1423004568,
-0.1492924988,
0.1258466393,
0.2830109894,
-0.2641780078,
-0.1395477504,
0.2567257881,
-0.0706348494,
0.6358197331,
0.3744282424,
0.2094076127,
0.0410662517,
0.1003370807,
0.1939475536,
-0.1542173177,
-0.1253535599,
0.0786667019,
0.4311345518,
0.2293377519,
0.2606241703,
0.0432942733,
0.0039330246,
0.0369875655,
0.2256598175,
-0.0995877683,
0.0464404114,
-0.4851085842,
0.2229608446,
-0.0733315125,
-0.2908384502,
-0.0352896377,
-0.1674087793,
0.015291566,
-0.0466685928,
0.2858061194,
-0.442235142,
-0.2159961909,
-0.0245831609,
-0.0144531336,
-0.0361220315,
0.1648850292,
0.3060340881,
-0.1535622925,
0.1875351518,
-0.0690221339,
-0.3030700982,
-0.2277741134,
0.2888991833,
-0.3881798685,
0.2339209467,
-0.1242176741,
0.1246043071,
0.2060777694,
0.0872233063,
-0.3023259342,
-0.3128600717,
0.103367351,
0.0580964424,
-0.5446746349,
0.0855553225,
0.4497941434,
-0.2139407992,
-0.316955179,
0.1590073705,
0.0572275221,
-0.0849835947,
-0.3678277433,
-0.0310678538,
0.0050241966,
-0.1004659235,
0.28436777,
0.0218719877,
0.649459362,
-0.2226049155,
0.2141833007,
0.0471928269,
-0.1830638498,
-0.2443289459,
-0.0553258471,
-0.0558792278,
0.5360149741,
-0.1836546957,
0.0613008775,
-0.1803109348,
0.2150432318,
-0.1740372926,
-0.1114083603,
-0.2488977015,
0.3276143968,
-0.3831015229,
0.241018638,
0.0358808003,
-0.1951785386,
0.0761359707,
0.2039012462,
-0.1825244725,
-0.3136612773,
0.4729765654,
-0.1506649703,
-0.4185021222,
-0.1036046669,
0.2821314633,
-0.1493181288,
0.0643491521,
-0.844047606,
-0.0510831624,
0.287345171,
-0.0319113918,
0.316352278,
0.5712406635,
0.0826131478,
-0.1572128236,
-0.0681430548,
0.2154383808,
-0.1368511766,
-0.0736022443,
0.0551107228,
-0.2370811254
] |
https://github.com/huggingface/datasets/issues/3358 | add new field, and get errors | Hi,
could you please post this question on our [Forum](https://discuss.huggingface.co/) as we keep issues for bugs and feature requests? | after adding new field **tokenized_examples["example_id"]**, and get errors below,
I think it is due to changing data to tensor, and **tokenized_examples["example_id"]** is string list
**all fields**
```
***************** train_dataset 1: Dataset({
features: ['attention_mask', 'end_positions', 'example_id', 'input_ids', 'start_positions', 'token_type_ids'],
num_rows: 87714
})
```
**Errors**
```
Traceback (most recent call last):
File "/usr/local/lib/python3.7/site-packages/transformers/tokenization_utils_base.py", line 705, in convert_to_tensors
tensor = as_tensor(value)
ValueError: too many dimensions 'str'
``` | 19 | add new field, and get errors
after adding new field **tokenized_examples["example_id"]**, and get errors below,
I think it is due to changing data to tensor, and **tokenized_examples["example_id"]** is string list
**all fields**
```
***************** train_dataset 1: Dataset({
features: ['attention_mask', 'end_positions', 'example_id', 'input_ids', 'start_positions', 'token_type_ids'],
num_rows: 87714
})
```
**Errors**
```
Traceback (most recent call last):
File "/usr/local/lib/python3.7/site-packages/transformers/tokenization_utils_base.py", line 705, in convert_to_tensors
tensor = as_tensor(value)
ValueError: too many dimensions 'str'
```
Hi,
could you please post this question on our [Forum](https://discuss.huggingface.co/) as we keep issues for bugs and feature requests? | [
0.0446220003,
-0.4576034844,
-0.0584968813,
0.2161904573,
0.3088058829,
0.2219411433,
0.5154497623,
0.3203382194,
-0.0904990807,
0.1890572011,
0.3385350406,
-0.0441404544,
-0.0989081934,
0.1437216103,
0.1367520243,
-0.3522278368,
0.2309164554,
-0.0397231579,
0.359590739,
0.0779784247,
-0.219248727,
0.0378068984,
-0.1065840274,
0.1154233292,
-0.7237384915,
-0.1941586584,
-0.2546229064,
-0.2827744782,
-0.1466881782,
-0.4635561407,
-0.0825901181,
-0.1970272958,
0.2082853168,
0.3800864518,
-0.0001139818,
-0.0404987969,
-0.0150443288,
0.1434163898,
0.0611624569,
-0.3147650361,
0.1230476797,
-0.5089915395,
0.174309805,
-0.2210367918,
-0.0483462289,
-0.3103239536,
-0.3012204766,
0.0458651409,
0.2487177998,
0.6076465845,
0.2137982547,
0.2830813825,
0.1171637177,
-0.0181477759,
0.2810867727,
0.1623565108,
-0.1728270501,
-0.1105571464,
-0.0643431991,
0.2139479965,
0.2913607061,
0.1005751491,
-0.0676633045,
-0.1330505311,
-0.0318386219,
0.1859572679,
-0.021072235,
-0.3448808789,
-0.0947987214,
0.227545321,
0.0556192733,
-0.0420611352,
-0.2763982117,
-0.2649901807,
0.1436311901,
-0.809959352,
0.0012090624,
-0.0860656053,
0.1295827925,
-0.105718784,
0.1332157552,
-0.192544952,
-0.2147680819,
0.2539899647,
-0.0858546197,
0.2904105186,
0.040425092,
0.0571674183,
-0.0245738588,
-0.3039744496,
-0.2368770838,
0.2091245353,
0.0920471773,
0.050156042,
-0.3265354037,
-0.3274368942,
-0.1703888774,
-0.8460083008,
-0.0299202539,
-0.1182312146,
0.1251399815,
0.0753531083,
-0.1153563112,
0.1488346457,
-0.150354147,
0.4299972355,
-0.2797854543,
0.2987673879,
0.0322862975,
0.0120423706,
0.0897737592,
-0.2124059945,
-0.0341499411,
0.0868646279,
-0.2197143883,
-0.0784657672,
0.2798909843,
0.174460575,
-0.2266585529,
0.2378373742,
-0.3714286387,
-0.0909556597,
0.3268613219,
0.3037384152,
0.0055436669,
-0.0557930395,
-0.0189899784,
0.3329693377,
0.1059241295,
0.0204252377,
-0.1132065803,
0.2120198011,
0.0381298773,
0.0965389088,
-0.0058014006,
0.2804949284,
0.1685733348,
0.1821445078,
0.17556265,
-0.0857189447,
0.0457808189,
-0.3274509907,
-0.011850833,
0.2446746081,
-0.1623959392,
0.1455687582,
0.1246650741,
-0.3176642954,
-0.0973011702,
0.1179915592,
-0.4138359129,
-0.2887553573,
-0.2761715353,
0.2304320931,
0.0657451078,
-0.21114631,
-0.1523579359,
0.4108951688,
0.1562711149,
0.0524635278,
0.0791322067,
-0.0865104944,
-0.2089457065,
-0.2159809023,
-0.0745531395,
-0.029309012,
0.101232402,
-0.0627332777,
0.2538982928,
0.2006561905,
0.222848773,
0.3601807356,
-0.0876552686,
0.2013072222,
-0.114015922,
0.6337585449,
0.4993644059,
-0.0895024166,
0.1043233275,
0.0455629788,
-0.1139138788,
0.0050773718,
0.0811743215,
-0.0712763965,
0.348025322,
0.2525149286,
0.0780985728,
-0.0568570606,
-0.1666350067,
0.0286887866,
-0.2039123029,
-0.073533915,
0.480720669,
-0.0569706857,
0.08602795,
0.1536120325,
-0.1173826531,
0.3899246156,
-0.1076802388,
-0.2517130673,
-0.0525260903,
0.2105347961,
0.4232125282,
0.0780982152,
0.0164373964,
-0.276966542,
-0.2415753007,
-0.1016659662,
-0.0081162052,
0.3129793406,
0.1241564229,
-0.1528926194,
-0.0839768276,
0.0989383608,
0.0118385963,
-0.0427590497,
0.1705907136,
-0.1378072202,
-0.0615183711,
-0.1409421861,
-0.3574697971,
-0.1961769909,
-0.2665219307,
0.3215979934,
-0.0003469989,
0.0916645527,
-0.1947570443,
-0.2752850056,
-0.345780015,
0.1982825398,
0.4347094893,
-0.316983223,
-0.1452714801,
0.2065375447,
0.0871854499,
-0.1272456348,
-0.1812451184,
0.5701868534,
0.4766018689,
0.0866388902,
-0.0747884139,
0.0949785635,
-0.1977113783,
0.048640389,
0.3017029464,
0.2552409172,
0.0416257009,
0.0938948542,
0.0158951487,
-0.0102518564,
0.2805344164,
-0.0362953097,
-0.0667171255,
-0.247740835,
0.0430447012,
-0.0225866921,
-0.2755206823,
-0.2058905214,
-0.4156096578,
0.011675044,
0.4111002684,
0.0203661248,
0.126545459,
0.3353298008,
0.0606937483,
-0.0228044502,
-0.1744241863,
-0.1834819615,
0.1863714606,
0.2162739933,
-0.0374850854,
0.1751075238,
-0.0426386744,
-0.0725331828,
0.3225393295,
0.0858470201,
-0.0405556634,
0.1921251565,
0.2531506419,
0.041651886,
-0.0641871393,
-0.1857984364,
0.1590702981,
0.3861254454,
-0.3332989216,
0.0226855744,
-0.1354020238,
0.1158884317,
-0.3470712602,
-0.5211394429,
-0.1947541684,
-0.0913080797,
0.1333253533,
0.1650413275,
-0.0584058091,
-0.0323028155,
0.2328933179,
0.1811704785,
0.1520466954,
0.2503387332,
-0.251413703,
0.1881197542,
-0.0800516903,
0.0893895999,
0.1086506173,
-0.3676973581,
0.2004423887,
-0.0079556061,
-0.0673935711,
-0.2073692232,
-0.6939557791,
0.0577144884,
-0.1616672128,
0.1495814323,
0.0504746176,
0.2029707283,
-0.3174254298,
-0.5606150031,
0.373503089,
0.0631292313,
-0.1898202151,
0.1862787157,
-0.1757304668,
0.0598119348,
-0.0711750686,
-0.5066557527,
0.00872871,
-0.0905137211,
0.3779674172,
0.126460284,
0.2532250881,
0.36407125,
0.1149852648,
0.1696968675,
0.0441515818,
0.181990236,
-0.22746782,
-0.2646888494,
0.0925270468,
-0.2859389782,
-0.2445725352,
0.0285744518,
-0.2139010429,
0.0977190211,
0.0379899926,
-0.2318935394,
-0.1881389618,
-0.0705095902,
0.1189883277,
-0.1183357835,
-0.030238986,
0.4418148398,
-0.0818211287,
-0.0792925879,
0.1701036096,
-0.1621062309,
0.0114003122,
0.1895053089,
0.3329734206,
-0.0826741084,
0.5983764529,
0.1236734465,
0.7153536677,
-0.0196637083,
-0.2459450662,
0.430966109,
-0.5590496063,
-0.0680036545,
-0.1401233524,
-0.5432994366,
-0.0148107624,
-0.1787278503,
-0.1317052245,
-0.1355524957,
-0.3162792921,
0.2789734006,
0.217008546,
0.1701368093,
-0.1825227886,
-0.1418356597,
0.2199385017,
-0.073405005,
0.4575762749,
-0.1082655266,
-0.1558029652,
-0.369302243,
-0.228490755,
0.0210162215,
0.2008310556,
-0.1674786359,
-0.2568633854,
-0.6143186688,
-0.573110044,
-0.3450019956,
0.3149638474,
0.2399879992,
0.4874070883,
-0.0830027014,
-0.0944669545,
0.0188853834,
0.2062711716,
0.7086455226,
-0.0368620083,
-0.5987602472,
0.0819607079,
-0.2926777005,
-0.2008366734,
-0.1690640897,
-0.2925713062,
-0.1302606612,
0.3646199703,
0.8734953403,
-0.3121635616,
-0.0440133736,
0.2601391375,
0.0978197157,
-0.1561843604,
0.2237067372,
-0.3871949911,
-0.104886815,
-0.3852130473,
0.0460145138,
-0.1986435801,
0.3438090682,
0.1452090889,
-0.1324704438,
-0.0914504305,
-0.0811558291,
0.0826059282,
0.1697082222,
0.0627928898,
0.1927865595,
-0.0041823629,
-0.0717866123,
0.1471410692,
0.2993489206,
-0.0195542164,
0.0354686491,
-0.2924565375,
0.0299446043,
0.1222809404,
0.3590201437,
0.1429048181,
0.0664468557,
0.6035637259,
-0.2023627907,
0.3839762211,
-0.2639629841,
0.6173537374,
0.6800709367,
0.2154117525,
-0.0557123013,
-0.1018904746,
0.0488873683,
-0.0058707758,
0.0911957845,
0.1675245017,
0.1358763278,
-0.114721112,
0.564960897,
0.1323613971,
0.9209089875,
-0.0548381954,
0.0074018356,
0.3799510598,
-0.0571518056,
0.3875162899,
-0.4085487127,
0.2735811472,
-0.3664184213,
-0.07450293,
0.0839588344,
-0.1389715523,
0.315384239,
-0.1464491934,
-0.1719273925,
-0.1110394523,
-0.1129573882,
0.3294655681,
-0.2870986164,
0.3370654583,
0.1720125526,
-0.2142113298,
-0.1558536738,
0.1408771276,
-0.1951574981,
-0.1457795948,
0.0149400374,
0.1584214717,
-0.2615333498,
-0.4068404138,
-0.10012687,
-0.3024352491,
-0.0616003312,
0.1445634961,
0.277652353,
-0.2915424705,
0.0683615059,
0.0596266426,
0.4977323711,
0.0285794046,
-0.1124930531,
-0.2288389653,
-0.2999640703,
-0.1160035804,
-0.100704737,
-0.1825149357,
0.2425773591,
-0.0907476321,
-0.2336039692,
0.2267445326,
0.1540641785,
-0.0722181275,
-0.35917449,
-0.0608298741,
0.2245548815,
-0.6635258198,
-0.0404822677,
-0.0153465914,
0.0136738978,
-0.2944806516,
0.1488354504,
-0.1106570363,
-0.290138334,
0.0312959664,
0.2372221202,
-0.0173722655,
-0.0903862342,
0.1809824705,
0.071844548,
0.0570993945,
0.5330719948,
-0.0443918146,
0.0244822334,
-0.1559264362,
0.3619891107,
0.2380404472,
-0.03660281,
0.0640054867,
0.0948874578,
-0.284432739,
-0.2006245106,
0.4143895805,
0.0532434434,
0.4472990036,
0.0981037766,
-0.0144180702,
-0.5266487598,
0.0741713122,
-0.0671725422,
0.230892092,
-0.0957487896,
0.598772943,
-0.3658435643,
0.1108484119,
-0.3123613298,
0.0559382774,
-0.3213581741,
0.2998354435,
-0.0733286142,
-0.2608671784,
0.2100671381,
-0.0199605208,
0.186050579,
0.1335760653,
0.1441167891,
-0.213493973,
-0.2920658588,
0.0587217025,
0.2845340669,
-0.156116426,
-0.1701492965,
0.1679783314,
0.0683798641,
-0.0878399909,
-0.0024535598,
0.0835555792,
-0.0041013714,
0.2937973738,
-0.0992411524,
0.072281301,
0.212443769,
-0.3502048552,
-0.008314875,
0.1851734966,
0.2298775464,
0.0969946608,
-0.2138759196,
-0.0526070297,
-0.2925547361,
0.2591092288,
0.3123401701,
-0.3182159662,
0.3317007422,
-0.2950999737,
0.0347885378,
0.0482712686,
-0.0460090339,
0.104310967,
-0.3572026789,
0.1490047127,
0.2870800197,
0.2078305483,
-0.1878944635,
-0.0201071985,
0.2344609648,
-0.3607134521,
-0.0213413369,
0.2761381567,
0.2924713194,
0.2032135874,
-0.080973357,
-0.0572834201,
0.1189952195,
-0.0772985145,
0.066383034,
0.0112138288,
-0.402402848,
-0.0751746818,
0.3983100951,
0.136963442,
0.0919150189,
0.0784203112,
-0.0976665989,
0.2543125451,
-0.1864063889,
-0.0137935989,
0.2807988524,
-0.1560862064,
0.0723205954,
-0.1369105279,
0.1403692663,
-0.1618686467,
-0.1285780519,
0.1604976356,
0.1578114629,
-0.0883963257,
-0.0235108491,
0.2402556837,
-0.3905501366,
0.0821195617,
0.0064962814,
0.0336039364,
-0.1384821832,
-0.2922402918,
-0.0221094526,
-0.2037473917,
-0.1520661265,
-0.0863025561,
-0.1994646341,
0.1156274974,
-0.0578466691,
0.1729414016,
0.142707184,
-0.1755815297,
0.2703374326,
0.1340903789,
-0.1919850409,
-0.1299098581,
0.2330935001,
0.4941275716,
0.2244008631,
0.0668667853,
0.2426386476,
-0.3219453394,
-0.0920073166,
0.2962193191,
0.2156580091,
0.3809562325,
0.2333525419,
-0.1993570179,
0.0307846721,
-0.1665662676,
0.0178862121,
0.0012010644,
0.0339894742,
-0.1117896885,
0.3315588534,
0.001176991,
-0.2301671356,
-0.2568456531,
-0.1010821238,
-0.2445573658,
0.0886172578,
0.4669312537,
-0.0014024497,
0.1044065431,
-0.1049203947,
0.0894497856,
0.1352821887,
0.1738068014,
0.1857275963,
-0.1369360387,
-0.3224231899,
0.0098843379,
-0.2122129351,
0.2836524248,
0.1567548513,
0.2753317058,
0.1874272227,
0.3362752199,
-0.1225935817,
-0.0988694429,
0.1245355606,
-0.2642428875,
0.0174058806,
0.1140478477,
-0.1186603084,
0.2816109359,
-0.2329095006,
0.0960176066,
0.1716545224,
0.2633220255,
0.2418783903,
0.0459170192,
-0.0400084518,
-0.252314955,
0.1260715276,
-0.2248920202,
-0.0517847911,
0.2285369039,
0.0884419531,
0.3985225856,
-0.1261552125,
-0.076879181,
0.1191301569,
-0.2358283848,
-0.2963832915,
0.3659539521,
0.0241903588,
0.1685485989,
0.1918427646,
-0.3437746167,
-0.305934459,
0.1064456105,
0.1542983055,
-0.6872484684,
-0.3395142257,
0.5021569729,
0.1389461011,
0.0347153023,
0.2454320937,
0.3067839146,
0.1933327317,
0.3114824593,
-0.0780344382,
-0.3688541055,
0.5684379935,
-0.1946577281,
-0.064661555,
-0.168902576,
0.2144985944,
0.2917206287,
0.0163481198,
-0.7518455982,
-0.4328045845,
0.3851223886,
-0.0753274485,
-0.1681839377,
0.2477854341,
0.0987442359,
-0.0498053953,
-0.0060499636,
0.1428134143,
-0.0625169799,
-0.0073622754,
0.1540183723,
-0.1129574329
] |
https://github.com/huggingface/datasets/issues/3358 | add new field, and get errors | > Hi,
>
> could you please post this question on our [Forum](https://discuss.huggingface.co/) as we keep issues for bugs and feature requests?
ok. | after adding new field **tokenized_examples["example_id"]**, and get errors below,
I think it is due to changing data to tensor, and **tokenized_examples["example_id"]** is string list
**all fields**
```
***************** train_dataset 1: Dataset({
features: ['attention_mask', 'end_positions', 'example_id', 'input_ids', 'start_positions', 'token_type_ids'],
num_rows: 87714
})
```
**Errors**
```
Traceback (most recent call last):
File "/usr/local/lib/python3.7/site-packages/transformers/tokenization_utils_base.py", line 705, in convert_to_tensors
tensor = as_tensor(value)
ValueError: too many dimensions 'str'
``` | 23 | add new field, and get errors
after adding new field **tokenized_examples["example_id"]**, and get errors below,
I think it is due to changing data to tensor, and **tokenized_examples["example_id"]** is string list
**all fields**
```
***************** train_dataset 1: Dataset({
features: ['attention_mask', 'end_positions', 'example_id', 'input_ids', 'start_positions', 'token_type_ids'],
num_rows: 87714
})
```
**Errors**
```
Traceback (most recent call last):
File "/usr/local/lib/python3.7/site-packages/transformers/tokenization_utils_base.py", line 705, in convert_to_tensors
tensor = as_tensor(value)
ValueError: too many dimensions 'str'
```
> Hi,
>
> could you please post this question on our [Forum](https://discuss.huggingface.co/) as we keep issues for bugs and feature requests?
ok. | [
0.0494639538,
-0.4595842957,
-0.0416366979,
0.2271222323,
0.2988955081,
0.2176527977,
0.5312832594,
0.3263185918,
-0.1052214578,
0.1934479922,
0.3319590092,
-0.0534846149,
-0.0954505578,
0.14284724,
0.1321327686,
-0.376542449,
0.2242110372,
-0.0373567082,
0.3674286008,
0.0773196742,
-0.2338250279,
0.0381776765,
-0.0949909538,
0.1430580616,
-0.7133247852,
-0.1978125423,
-0.2818616629,
-0.2980216742,
-0.1502491087,
-0.4651328623,
-0.0985193774,
-0.1978337467,
0.2355629206,
0.3881618381,
-0.0001145084,
-0.0445216075,
-0.0141637679,
0.1363517642,
0.0911904499,
-0.303522259,
0.1415074617,
-0.509467423,
0.1612446606,
-0.2362726778,
-0.0425680466,
-0.3196818829,
-0.2887627184,
0.0572747886,
0.2534806132,
0.6204358339,
0.2075403184,
0.2654421031,
0.0896599665,
-0.0128372358,
0.2806482315,
0.1333432496,
-0.1583306789,
-0.1135855317,
-0.0719464272,
0.206691131,
0.3191039562,
0.1022605523,
-0.0878219828,
-0.1461720169,
-0.0177597571,
0.2018308789,
-0.0110338759,
-0.3475725353,
-0.0969160795,
0.2371204495,
0.0367233083,
-0.0419363976,
-0.2668240368,
-0.2703270912,
0.149817571,
-0.8005068898,
-0.006583476,
-0.0847314522,
0.1513306051,
-0.094447121,
0.1208645925,
-0.1834401935,
-0.2301211059,
0.2683455348,
-0.0701835155,
0.2840690911,
0.0611523502,
0.0771477297,
-0.0084743211,
-0.2995909452,
-0.2273301035,
0.2170155793,
0.083633177,
0.0467170104,
-0.3409611583,
-0.3207488358,
-0.2056906074,
-0.8456069827,
-0.0296181235,
-0.1311086565,
0.1418230832,
0.0743329525,
-0.1018708125,
0.150777787,
-0.1690870672,
0.422164917,
-0.276763469,
0.3298919201,
0.0317755342,
-0.0018062516,
0.0915051252,
-0.211987406,
-0.0534382574,
0.074663952,
-0.2136529386,
-0.0881642103,
0.2710969448,
0.1766837835,
-0.2154184431,
0.2351105809,
-0.3669191897,
-0.08394894,
0.3222771883,
0.3090446293,
-0.0106381942,
-0.0633710474,
-0.0220611561,
0.3528704941,
0.0900325403,
0.0262563657,
-0.1002127379,
0.2345604748,
0.0377743021,
0.0894365236,
-0.0110398382,
0.2604201734,
0.1594394445,
0.163472876,
0.1630769372,
-0.0813460723,
0.0659968853,
-0.3340253532,
-0.0173032265,
0.2424567938,
-0.1721290201,
0.1367067993,
0.1150896922,
-0.3379415274,
-0.0994394794,
0.1372864693,
-0.4385377765,
-0.2794567943,
-0.2625277638,
0.2261704654,
0.0745768026,
-0.2050846815,
-0.1418495178,
0.4258648455,
0.1783704758,
0.0411144979,
0.0866138712,
-0.1189158931,
-0.2182136029,
-0.2205145359,
-0.0835607573,
-0.0261224452,
0.0987566635,
-0.0741421953,
0.2488526702,
0.2132144421,
0.2448011637,
0.3794907928,
-0.0955207273,
0.1853252798,
-0.1021115631,
0.6436732411,
0.5139327645,
-0.1069780886,
0.0839939415,
0.0497979857,
-0.1087115183,
-0.010399106,
0.0872986168,
-0.0677112341,
0.3736268282,
0.2547337413,
0.0640835539,
-0.0496171266,
-0.1789565235,
0.0178277232,
-0.2095885426,
-0.0576371402,
0.48780936,
-0.0416233391,
0.0859873593,
0.1384146214,
-0.122391969,
0.390397191,
-0.1192837358,
-0.2377113551,
-0.0500201732,
0.2092348337,
0.4296059906,
0.0549882539,
0.0136456508,
-0.2713926136,
-0.2155061662,
-0.104823716,
-0.0285402425,
0.3129202724,
0.1287527084,
-0.1671163589,
-0.084913753,
0.0855233669,
0.0060468065,
-0.0615009516,
0.1639477015,
-0.1279583126,
-0.0668621659,
-0.1708505005,
-0.3525912762,
-0.1777635664,
-0.2689228654,
0.3091740608,
-0.0066090538,
0.0919995829,
-0.2017161846,
-0.2708845437,
-0.3419153988,
0.1802117378,
0.4479684234,
-0.3205734193,
-0.1500425935,
0.2228434235,
0.0955761001,
-0.1470213532,
-0.1798633933,
0.5841494799,
0.4731904864,
0.0507565103,
-0.0493944772,
0.1052468494,
-0.2080089003,
0.0479799882,
0.2988726497,
0.2580317259,
0.0668036044,
0.0963129252,
0.007230117,
-0.021752473,
0.2727023661,
-0.0496849902,
-0.0714725927,
-0.248445794,
0.0305010006,
-0.0220689755,
-0.2882014811,
-0.1962402016,
-0.4023242593,
0.0277793482,
0.4156402051,
0.0347076692,
0.1178904325,
0.3482180834,
0.0441488698,
-0.010266508,
-0.191149205,
-0.1355472207,
0.1785566062,
0.214329049,
-0.040032398,
0.1805182099,
-0.0463349484,
-0.0707812831,
0.3125256896,
0.0875536129,
-0.020563405,
0.1875154823,
0.2390922159,
0.0449140407,
-0.0473151989,
-0.1932894439,
0.1837452799,
0.4113523364,
-0.3289890587,
0.0441014692,
-0.1352260262,
0.1138924211,
-0.3598470092,
-0.509256959,
-0.1970312148,
-0.0758055896,
0.141743049,
0.1488672793,
-0.0544110909,
-0.0259820316,
0.248410508,
0.1901663095,
0.1533095986,
0.2289119363,
-0.2110155374,
0.1808116436,
-0.0996080488,
0.0820936337,
0.1093161106,
-0.3672043979,
0.1935216933,
-0.0142106609,
-0.0737366378,
-0.2033661157,
-0.6990793347,
0.0333572514,
-0.1648027897,
0.150153622,
0.0350847915,
0.2067215741,
-0.3207108974,
-0.5492855906,
0.368083775,
0.0411165506,
-0.173754096,
0.1930922568,
-0.1984652728,
0.0747520626,
-0.0703590512,
-0.5334659219,
-0.0048902119,
-0.0804618225,
0.3707929552,
0.1231151447,
0.2492717952,
0.3679781854,
0.1191719025,
0.1723248065,
0.0613852404,
0.1761806458,
-0.2066814899,
-0.2650457621,
0.1120147184,
-0.3018297255,
-0.2515169382,
0.029344175,
-0.2135268897,
0.0985988826,
0.0209950823,
-0.2288408726,
-0.1682466716,
-0.0633464158,
0.0883186609,
-0.1324808747,
-0.027765058,
0.4366389215,
-0.0834536999,
-0.0677979141,
0.1670205444,
-0.1521578431,
0.0277896915,
0.2006298155,
0.3603651226,
-0.075744465,
0.595431447,
0.1214718819,
0.6986410022,
-0.0174063668,
-0.2562650442,
0.4088597894,
-0.5466685295,
-0.0796643496,
-0.1242736056,
-0.531889379,
-0.0100125689,
-0.1634501368,
-0.118982397,
-0.1374527663,
-0.3081322312,
0.2487964928,
0.2063053548,
0.1559760422,
-0.1808675826,
-0.1306672841,
0.2160066813,
-0.0682979748,
0.4520582259,
-0.1112936214,
-0.1769374013,
-0.3607892692,
-0.2329179943,
0.017142212,
0.1880160272,
-0.1855877936,
-0.2484458089,
-0.6180877686,
-0.5673623085,
-0.3287164867,
0.3219515681,
0.2286327779,
0.4899326265,
-0.0784393102,
-0.0735514164,
0.0205422267,
0.1969932616,
0.7031794786,
-0.0588721223,
-0.6067174673,
0.0834370106,
-0.2709706724,
-0.2153509259,
-0.180275321,
-0.2888658047,
-0.1516874433,
0.3666365445,
0.8600209355,
-0.3151839674,
-0.0282464474,
0.2559084296,
0.1161367297,
-0.1559812129,
0.2093017995,
-0.3855769038,
-0.0952529535,
-0.3891747296,
0.0568671823,
-0.2012707144,
0.3361486495,
0.1331972629,
-0.1539323777,
-0.0675235465,
-0.0790545121,
0.0860460848,
0.1875106841,
0.0710928589,
0.1916081011,
0.0012773497,
-0.0765910521,
0.1293989718,
0.3282063603,
-0.0072726998,
0.0281986985,
-0.2846324146,
0.0362908132,
0.1154833809,
0.3558549583,
0.1270955056,
0.0722705498,
0.613491118,
-0.19806467,
0.3982449472,
-0.2351782769,
0.6314564347,
0.6877592206,
0.2208260298,
-0.0484137349,
-0.1219517216,
0.0398662724,
-0.022931274,
0.097858049,
0.1660848707,
0.1274122447,
-0.0948020518,
0.5684190989,
0.1284689605,
0.9635353088,
-0.0572538041,
-0.017959943,
0.3407963514,
-0.0852862969,
0.3971395493,
-0.4192535579,
0.260578692,
-0.3792166114,
-0.0912235528,
0.0954647735,
-0.1323112547,
0.3142621815,
-0.1323078126,
-0.1837193817,
-0.1296415329,
-0.1184397265,
0.3153228462,
-0.2798679173,
0.3478438854,
0.1742373109,
-0.2103657126,
-0.1415958107,
0.1364421397,
-0.2131080031,
-0.1860268563,
0.0197239053,
0.175603658,
-0.2688117921,
-0.3944829404,
-0.0756257027,
-0.2826619744,
-0.0527838618,
0.1354981214,
0.2703760564,
-0.3007279634,
0.0738693327,
0.0745893121,
0.5060700774,
0.046359349,
-0.1142863706,
-0.2204647511,
-0.2859408557,
-0.1274978369,
-0.0938149393,
-0.1873399913,
0.2595443726,
-0.1010699719,
-0.2667845786,
0.2272014618,
0.1762266755,
-0.0741175115,
-0.3238299191,
-0.0751759484,
0.2465198487,
-0.6283187866,
-0.0248815939,
-0.0293557514,
0.0110661471,
-0.2994451523,
0.1467154026,
-0.1112179086,
-0.2998708189,
0.0376290753,
0.2425623685,
-0.0264868047,
-0.082476899,
0.1724595428,
0.0804714561,
0.0441137366,
0.539472878,
-0.0324116051,
0.0305269379,
-0.1510880291,
0.3717612028,
0.2351387292,
-0.0136060594,
0.040915478,
0.1096522734,
-0.2587922812,
-0.1838649958,
0.4098017812,
0.0531292967,
0.4500695169,
0.0865276903,
-0.018145984,
-0.5363943577,
0.0665004551,
-0.0798095092,
0.2340278178,
-0.0904002264,
0.6041975617,
-0.3543819189,
0.1495545506,
-0.3114897013,
0.0609285496,
-0.3129850328,
0.3193208277,
-0.085022904,
-0.2566007674,
0.2127739936,
-0.0184965786,
0.1647147685,
0.1547671258,
0.1509687304,
-0.2020496428,
-0.3024661541,
0.065057084,
0.3099929392,
-0.1491392702,
-0.1671668142,
0.1380031407,
0.0636846721,
-0.0819587559,
-0.0132393036,
0.0958310664,
-0.018738782,
0.3100917637,
-0.0779311806,
0.0480037667,
0.2054154426,
-0.3653732836,
-0.0259699672,
0.1739974767,
0.2398445308,
0.0804485083,
-0.209069699,
-0.0773124769,
-0.294223696,
0.2483984977,
0.3181611598,
-0.3267731667,
0.3419548273,
-0.2937618494,
0.0572943985,
0.0509228297,
-0.0546598099,
0.1083742902,
-0.3477485478,
0.1496900469,
0.2948278189,
0.1987546086,
-0.1988360435,
-0.0140682468,
0.224419117,
-0.3686127663,
-0.0334945805,
0.2937746346,
0.2891243696,
0.2162142247,
-0.0852123275,
-0.0575823896,
0.1283723265,
-0.0852478817,
0.0832876563,
0.0088261077,
-0.4133600295,
-0.0778456032,
0.4086759388,
0.1309713423,
0.0807659328,
0.0668451637,
-0.1075111926,
0.2344190627,
-0.1890749931,
-0.0167937707,
0.2703411877,
-0.158430174,
0.0631731972,
-0.1473558843,
0.1443453431,
-0.1643208414,
-0.13474527,
0.1691461205,
0.1768138856,
-0.0883908123,
-0.0152938394,
0.2405862063,
-0.3689981401,
0.0913911387,
-0.0240325313,
0.0490603745,
-0.1493786275,
-0.2885390222,
-0.0113102347,
-0.1952949315,
-0.1432773024,
-0.0698492005,
-0.2060877234,
0.1207890287,
-0.0620189235,
0.1766550541,
0.1460344046,
-0.1988005936,
0.2617154121,
0.1356791258,
-0.1781061739,
-0.1403428763,
0.2010852844,
0.4723496735,
0.2323899865,
0.0531996787,
0.2582347095,
-0.2955990732,
-0.0806133822,
0.325101018,
0.1943747252,
0.3955979943,
0.2218880504,
-0.1966993213,
0.0187681392,
-0.1585986912,
0.019640388,
0.0045835893,
0.0449226983,
-0.1011080667,
0.3011159599,
0.0368576199,
-0.2269064784,
-0.2595173717,
-0.1005252451,
-0.2826698422,
0.0699965283,
0.4721247852,
-0.0088554937,
0.0943096727,
-0.1241419315,
0.0877710506,
0.1286721826,
0.1913784891,
0.1826369166,
-0.1322566569,
-0.3455516994,
-0.0047365823,
-0.2026624531,
0.3043243289,
0.1389161795,
0.2789458036,
0.1812717319,
0.3066741526,
-0.1346644759,
-0.0976492614,
0.1341664493,
-0.2404660285,
0.0249589477,
0.10757339,
-0.1193420365,
0.2629646361,
-0.2547931075,
0.0982110575,
0.1763952076,
0.2799112499,
0.2255416214,
0.0369434059,
-0.0501716733,
-0.2412914932,
0.1084045619,
-0.2099595219,
-0.0396102071,
0.2259697914,
0.0765038356,
0.4098381698,
-0.1237947717,
-0.0594206378,
0.1488907188,
-0.2221011072,
-0.308509171,
0.3641909063,
0.0328496471,
0.156915307,
0.1878360808,
-0.3507217765,
-0.3045069575,
0.1042558998,
0.1455893666,
-0.7004938722,
-0.3431568444,
0.4897275269,
0.1549558491,
0.0235574432,
0.2542874813,
0.2820852399,
0.1898351461,
0.306163758,
-0.0780771449,
-0.3755782247,
0.5800887942,
-0.15999268,
-0.0616733246,
-0.1620818973,
0.2129563093,
0.2848193347,
0.0450598374,
-0.7709115148,
-0.4359219074,
0.3805273771,
-0.055630248,
-0.1802977026,
0.2399852574,
0.1072673947,
-0.0453876108,
-0.0118457964,
0.15140073,
-0.0657606572,
0.027599914,
0.1340048164,
-0.1173574328
] |
https://github.com/huggingface/datasets/issues/3353 | add one field "example_id", but I can't see it in the "comput_loss" function | Hi ! Your function looks fine, I used to map `squad` locally and it indeed added the `example_id` field correctly.
However I think that in the `compute_loss` method only a subset of the fields are available: the model inputs. Since `example_id` is not a model input (it's not passed as a parameter to the model), the data loader doesn't need to return it by default.
However you can disable this behavior by setting `remove_unused_columns` to `False` to your training arguments. In this case in `compute_loss` you will get the full item with all the fields.
Note that since the model doesn't take `example_id` as input, you will have to remove it from the inputs when `model(**inputs)` is called | Hi, I add one field **example_id**, but I can't see it in the **comput_loss** function, how can I do this? below is the information of inputs
```
*********************** inputs: {'attention_mask': tensor([[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
...,
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0]], device='cuda:0'), 'end_positions': tensor([ 25, 97, 93, 44, 25, 112, 109, 134], device='cuda:0'), 'input_ids': tensor([[ 101, 2054, 2390, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2106, ..., 0, 0, 0],
...,
[ 101, 2339, 2001, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2003, ..., 0, 0, 0]], device='cuda:0'), 'start_positions': tensor([ 20, 90, 89, 41, 25, 96, 106, 132], device='cuda:0'), 'token_type_ids': tensor([[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
...,
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0]], device='cuda:0')}
```
```
# This function preprocesses a question answering dataset, tokenizing the question and context text
# and finding the right offsets for the answer spans in the tokenized context (to use as labels).
# Adapted from https://github.com/huggingface/transformers/blob/master/examples/pytorch/question-answering/run_qa.py
def prepare_train_dataset_qa(examples, tokenizer, max_seq_length=None):
questions = [q.lstrip() for q in examples["question"]]
max_seq_length = tokenizer.model_max_length
# tokenize both questions and the corresponding context
# if the context length is longer than max_length, we split it to several
# chunks of max_length
tokenized_examples = tokenizer(
questions,
examples["context"],
truncation="only_second",
max_length=max_seq_length,
stride=min(max_seq_length // 2, 128),
return_overflowing_tokens=True,
return_offsets_mapping=True,
padding="max_length"
)
# Since one example might give us several features if it has a long context,
# we need a map from a feature to its corresponding example.
sample_mapping = tokenized_examples.pop("overflow_to_sample_mapping")
# The offset mappings will give us a map from token to character position
# in the original context. This will help us compute the start_positions
# and end_positions to get the final answer string.
offset_mapping = tokenized_examples.pop("offset_mapping")
tokenized_examples["start_positions"] = []
tokenized_examples["end_positions"] = []
tokenized_examples["example_id"] = []
for i, offsets in enumerate(offset_mapping):
input_ids = tokenized_examples["input_ids"][i]
# We will label features not containing the answer the index of the CLS token.
cls_index = input_ids.index(tokenizer.cls_token_id)
sequence_ids = tokenized_examples.sequence_ids(i)
# from the feature idx to sample idx
sample_index = sample_mapping[i]
# get the answer for a feature
answers = examples["answers"][sample_index]
tokenized_examples["example_id"].append(examples["id"][sample_index])
if len(answers["answer_start"]) == 0:
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Start/end character index of the answer in the text.
start_char = answers["answer_start"][0]
end_char = start_char + len(answers["text"][0])
# Start token index of the current span in the text.
token_start_index = 0
while sequence_ids[token_start_index] != 1:
token_start_index += 1
# End token index of the current span in the text.
token_end_index = len(input_ids) - 1
while sequence_ids[token_end_index] != 1:
token_end_index -= 1
# Detect if the answer is out of the span (in which case this feature is labeled with the CLS index).
if not (offsets[token_start_index][0] <= start_char and
offsets[token_end_index][1] >= end_char):
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Otherwise move the token_start_index and token_end_index to the two ends of the answer.
# Note: we could go after the last offset if the answer is the last word (edge case).
while token_start_index < len(offsets) and \
offsets[token_start_index][0] <= start_char:
token_start_index += 1
tokenized_examples["start_positions"].append(
token_start_index - 1)
while offsets[token_end_index][1] >= end_char:
token_end_index -= 1
tokenized_examples["end_positions"].append(token_end_index + 1)
return tokenized_examples
```
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/3333#issuecomment-983457161_ | 118 | add one field "example_id", but I can't see it in the "comput_loss" function
Hi, I add one field **example_id**, but I can't see it in the **comput_loss** function, how can I do this? below is the information of inputs
```
*********************** inputs: {'attention_mask': tensor([[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
...,
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0]], device='cuda:0'), 'end_positions': tensor([ 25, 97, 93, 44, 25, 112, 109, 134], device='cuda:0'), 'input_ids': tensor([[ 101, 2054, 2390, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2106, ..., 0, 0, 0],
...,
[ 101, 2339, 2001, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2003, ..., 0, 0, 0]], device='cuda:0'), 'start_positions': tensor([ 20, 90, 89, 41, 25, 96, 106, 132], device='cuda:0'), 'token_type_ids': tensor([[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
...,
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0]], device='cuda:0')}
```
```
# This function preprocesses a question answering dataset, tokenizing the question and context text
# and finding the right offsets for the answer spans in the tokenized context (to use as labels).
# Adapted from https://github.com/huggingface/transformers/blob/master/examples/pytorch/question-answering/run_qa.py
def prepare_train_dataset_qa(examples, tokenizer, max_seq_length=None):
questions = [q.lstrip() for q in examples["question"]]
max_seq_length = tokenizer.model_max_length
# tokenize both questions and the corresponding context
# if the context length is longer than max_length, we split it to several
# chunks of max_length
tokenized_examples = tokenizer(
questions,
examples["context"],
truncation="only_second",
max_length=max_seq_length,
stride=min(max_seq_length // 2, 128),
return_overflowing_tokens=True,
return_offsets_mapping=True,
padding="max_length"
)
# Since one example might give us several features if it has a long context,
# we need a map from a feature to its corresponding example.
sample_mapping = tokenized_examples.pop("overflow_to_sample_mapping")
# The offset mappings will give us a map from token to character position
# in the original context. This will help us compute the start_positions
# and end_positions to get the final answer string.
offset_mapping = tokenized_examples.pop("offset_mapping")
tokenized_examples["start_positions"] = []
tokenized_examples["end_positions"] = []
tokenized_examples["example_id"] = []
for i, offsets in enumerate(offset_mapping):
input_ids = tokenized_examples["input_ids"][i]
# We will label features not containing the answer the index of the CLS token.
cls_index = input_ids.index(tokenizer.cls_token_id)
sequence_ids = tokenized_examples.sequence_ids(i)
# from the feature idx to sample idx
sample_index = sample_mapping[i]
# get the answer for a feature
answers = examples["answers"][sample_index]
tokenized_examples["example_id"].append(examples["id"][sample_index])
if len(answers["answer_start"]) == 0:
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Start/end character index of the answer in the text.
start_char = answers["answer_start"][0]
end_char = start_char + len(answers["text"][0])
# Start token index of the current span in the text.
token_start_index = 0
while sequence_ids[token_start_index] != 1:
token_start_index += 1
# End token index of the current span in the text.
token_end_index = len(input_ids) - 1
while sequence_ids[token_end_index] != 1:
token_end_index -= 1
# Detect if the answer is out of the span (in which case this feature is labeled with the CLS index).
if not (offsets[token_start_index][0] <= start_char and
offsets[token_end_index][1] >= end_char):
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Otherwise move the token_start_index and token_end_index to the two ends of the answer.
# Note: we could go after the last offset if the answer is the last word (edge case).
while token_start_index < len(offsets) and \
offsets[token_start_index][0] <= start_char:
token_start_index += 1
tokenized_examples["start_positions"].append(
token_start_index - 1)
while offsets[token_end_index][1] >= end_char:
token_end_index -= 1
tokenized_examples["end_positions"].append(token_end_index + 1)
return tokenized_examples
```
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/3333#issuecomment-983457161_
Hi ! Your function looks fine, I used to map `squad` locally and it indeed added the `example_id` field correctly.
However I think that in the `compute_loss` method only a subset of the fields are available: the model inputs. Since `example_id` is not a model input (it's not passed as a parameter to the model), the data loader doesn't need to return it by default.
However you can disable this behavior by setting `remove_unused_columns` to `False` to your training arguments. In this case in `compute_loss` you will get the full item with all the fields.
Note that since the model doesn't take `example_id` as input, you will have to remove it from the inputs when `model(**inputs)` is called | [
-0.1465506107,
-0.5799238086,
-0.274071902,
0.1202487126,
0.1545111835,
0.0243577175,
0.518656373,
0.1191996783,
0.2118413895,
0.4652202725,
0.3532586992,
0.3118036389,
0.2009701878,
-0.1237443164,
0.3787087202,
0.0022589611,
-0.0379148796,
0.224128589,
0.2628958523,
-0.1642495841,
-0.183089748,
-0.0878601,
-0.218925029,
0.0226238295,
-0.2868743539,
-0.208893016,
0.0530895069,
-0.1255611032,
-0.0868299603,
-0.0424166285,
0.1870988011,
-0.1108928472,
-0.2399868071,
0.199706316,
-0.0001078606,
0.1045567244,
0.1533192098,
-0.0608258732,
-0.0272859689,
-0.1543922424,
-0.2217087746,
-0.2605636418,
-0.0360182188,
-0.3241762221,
-0.0498114787,
0.1234708503,
-0.1091194451,
-0.3235187232,
0.0795222297,
0.2246320397,
0.2008235306,
-0.1087317839,
0.1274075657,
-0.0000119107,
0.2504412234,
0.0550517887,
0.0921009034,
-0.2274120599,
-0.2579442263,
-0.0577589981,
0.4909737408,
0.4897180498,
0.3399707079,
-0.1195267215,
0.0124899726,
0.2712908983,
0.2939135432,
-0.1918281168,
0.0852965564,
-0.1495800912,
-0.2388664931,
-0.0874888822,
-0.0544351488,
0.1071323305,
0.1659787893,
-0.7740447521,
-0.2672750056,
-0.0151067004,
0.0079791779,
0.0360805653,
0.2593709826,
0.0940451175,
-0.3109925091,
0.4295270443,
0.0709782764,
0.2999991179,
0.0571777672,
0.1011035219,
0.1933594793,
-0.0105596436,
-0.0151527831,
0.3169314563,
0.3318520784,
0.0747607127,
-0.3491978645,
0.0346172415,
-0.0871883109,
-0.4820678234,
-0.1534082443,
-0.2185961902,
0.3559982777,
0.1997032613,
0.2166689783,
0.4776992798,
-0.3577488065,
0.2326746285,
-0.1546849757,
0.0067086807,
0.0488918722,
-0.0942224711,
0.0168210939,
-0.24926579,
-0.0476013683,
0.2071011811,
0.0075180656,
0.1878779531,
0.0598699823,
0.2564727068,
-0.3819018602,
-0.0711564273,
-0.0432543829,
-0.1892253906,
0.2999635935,
0.3324873149,
0.1197899133,
0.1190501079,
0.1769399643,
0.0945180506,
-0.0657149106,
-0.0995360166,
-0.3446668088,
0.3517922759,
-0.0081031248,
-0.0312071461,
0.229830265,
0.1371507198,
0.2383444458,
-0.1337921917,
0.2179640383,
-0.0860011131,
0.1516470909,
-0.1166076884,
0.4551613331,
0.2630287409,
-0.1637019664,
0.0134522561,
0.2568819225,
-0.2118529975,
0.0206137281,
0.1065059751,
-0.2221775204,
-0.0247162618,
-0.2702471018,
0.1769711524,
0.3174368739,
-0.0659502074,
0.1990665644,
0.4340725839,
0.0306911245,
-0.1820393652,
0.1591261029,
0.2752167881,
-0.4124224484,
-0.2381926775,
0.3947790563,
-0.1607451886,
-0.1401053369,
-0.141785562,
-0.2604891956,
0.1221225783,
0.1909762174,
-0.0842138007,
-0.0475603007,
-0.0282747149,
0.0637511387,
0.3494353592,
0.8107308149,
-0.3744962215,
-0.2795385122,
-0.0711329207,
-0.2432867438,
-0.3155626655,
0.3230952919,
0.1094321683,
-0.0346453451,
0.350897491,
0.3981733024,
-0.2225913256,
-0.058040645,
-0.0951701924,
-0.157324627,
0.1440274864,
0.2992529869,
-0.0405863933,
-0.032645002,
0.229087308,
0.1560370028,
-0.046294827,
0.17617625,
0.0521368645,
0.0390579067,
-0.0493439548,
0.4451039433,
-0.3515290916,
-0.0790179148,
-0.3894447684,
0.0563286431,
0.0327258483,
0.105559513,
-0.1064713523,
0.2491143793,
-0.3219109476,
-0.156619519,
-0.1171730235,
0.2654783726,
0.1461737156,
0.2600670159,
0.1603276432,
-0.1780048907,
-0.2101499736,
-0.1849679351,
0.2014156878,
0.1087631285,
-0.1175370067,
-0.0605794899,
0.108806923,
-0.2590561807,
-0.3654018342,
-0.2350620776,
0.1987408698,
0.5106500983,
-0.070552513,
0.1146341339,
0.2025002986,
0.0576812178,
-0.1379923075,
-0.0804836676,
0.247410059,
0.238827616,
0.1963553131,
-0.092208907,
-0.0410733148,
-0.0662460774,
-0.0322654434,
0.0253206398,
0.1264405251,
0.1489983648,
-0.1023368761,
-0.0388093181,
-0.0366984978,
0.0363957137,
0.1048706323,
-0.0081957802,
-0.2124927044,
-0.0292192549,
-0.02710413,
-0.1880142242,
-0.3396835029,
-0.6948493719,
0.2774123251,
0.3753505945,
0.2250716835,
0.0887846723,
-0.1543403417,
0.1054508239,
0.3096154928,
0.1741134822,
-0.0688997656,
0.2824614942,
0.2431523055,
-0.0006570601,
-0.1929287612,
-0.1459147185,
0.0332997181,
-0.1217951626,
0.0161180329,
-0.0088923573,
0.0553401932,
0.0460408255,
-0.1220655963,
-0.0741402805,
0.1098109409,
-0.0425804891,
0.1530542374,
-0.1819598377,
0.0745958239,
-0.2065949589,
-0.1701564938,
-0.0176640656,
-0.1878846288,
0.4881099164,
-0.2357124686,
0.108563371,
0.0685065687,
-0.0312240217,
0.1133598611,
0.3010867834,
0.3493435383,
0.0032124056,
0.4118727446,
-0.5014944673,
0.0754358545,
0.0803720653,
0.1347717345,
-0.323775351,
0.2229703069,
0.0899232253,
0.1199859902,
0.163475275,
0.1981916577,
-0.5742998719,
-0.0457441844,
-0.1828483492,
-0.1081298813,
-0.2321815789,
0.3006094992,
-0.4940449893,
-0.4426555336,
0.0445017219,
-0.1192849278,
-0.1709110141,
-0.0220641308,
-0.109759666,
0.0612727888,
-0.3739386499,
-0.4167387784,
-0.2716556787,
-0.2535756528,
0.3533881605,
0.1404966414,
0.1286893487,
-0.0205969587,
0.1233990565,
0.0022618512,
0.390040338,
0.3684777617,
-0.2363982499,
-0.3898071647,
0.2644088864,
-0.4682346284,
-0.2753450274,
0.1190086529,
-0.2428461909,
0.3059527278,
-0.0551914908,
-0.0429992825,
-0.1326035708,
0.1728417873,
-0.1390807033,
-0.1978014708,
0.250329107,
0.5233486295,
-0.126338914,
-0.1503020376,
-0.1779243052,
-0.4433750212,
0.1343268305,
0.3658438623,
0.2038741261,
-0.3099858463,
0.2279687226,
-0.0131086791,
0.5472481847,
0.0150866266,
-0.5900515914,
0.1056579351,
-0.359562546,
-0.0319627449,
0.2820094228,
-0.389461875,
-0.0417868495,
0.1235161722,
0.0056943861,
-0.1467068046,
-0.4287927449,
-0.2567921579,
-0.0766892061,
0.0805044174,
-0.5425463319,
0.0181248747,
-0.1387891471,
0.0470177382,
-0.0577977635,
-0.1137975454,
-0.0473476201,
-0.4487857223,
0.063312687,
0.202952534,
0.1094742194,
-0.0809170008,
-0.2151966393,
0.1158836111,
-0.7709780931,
-0.2294573784,
0.215963006,
-0.0320693888,
0.0548228025,
-0.0477108881,
-0.189836666,
-0.0463781394,
0.1821792424,
0.410623461,
-0.2682365179,
-0.3791665137,
0.3391001523,
-0.1767856777,
0.0223890692,
0.0805483386,
-0.1487300098,
-0.0903297812,
0.3995429277,
0.2576504648,
-0.2826338112,
0.1514883488,
0.4574837983,
0.017806109,
-0.1433134526,
0.1389861107,
-0.407248795,
0.0921383128,
-0.2252016515,
0.0633089542,
0.1053115055,
0.2456721961,
0.3113098741,
-0.1568218917,
-0.0494199097,
-0.2709628344,
0.0991963446,
0.1898778826,
0.1328711063,
0.4358684421,
-0.1194885224,
0.2090510279,
0.2822466791,
-0.2177584022,
-0.0802924186,
0.0966512933,
-0.0369397104,
0.1970512718,
-0.0768765062,
0.4107712507,
0.0712356344,
0.0180286653,
0.2601253986,
-0.154182598,
0.3188805878,
-0.0546550639,
0.2812376618,
0.3012107313,
0.0483411327,
0.2414410412,
-0.1765300333,
0.059619505,
-0.0958827287,
-0.1697422415,
0.3887868226,
-0.0318235382,
-0.0489952751,
0.2164387703,
0.1120499,
0.9591209292,
-0.1575283259,
-0.2097389996,
0.010101567,
-0.0759112835,
0.246584028,
-0.5863705277,
0.2355298549,
0.0334868543,
-0.4988214374,
-0.0105420575,
-0.0881967917,
0.044007767,
0.0403953083,
-0.2475857139,
-0.1044775248,
-0.0600731559,
0.1326296777,
-0.2600261271,
0.1042772382,
0.5729569793,
-0.0145095149,
0.1290891767,
0.1071654633,
0.2161007077,
-0.1032794267,
0.0142463967,
0.043840792,
-0.3111595213,
-0.1651967317,
-0.0577949472,
-0.2926233709,
-0.3724552989,
0.0779147893,
-0.2301871926,
-0.3371114433,
-0.1382795125,
0.2469748259,
0.5074902773,
-0.0876613185,
-0.0729399547,
0.0783381015,
0.0328867845,
-0.0796208233,
-0.4444467127,
-0.0946100354,
0.136764273,
-0.2206638753,
-0.4410490096,
0.5772229433,
0.1857408732,
-0.1705364585,
-0.1899651885,
0.2871699929,
-0.0383694619,
0.129547134,
0.010304179,
0.3733169138,
-0.0053962925,
-0.3326701522,
0.1627595574,
0.0596208572,
-0.3349808156,
0.0551164001,
0.1015768796,
-0.059681952,
-0.1164965257,
0.2710948884,
0.1846642196,
0.1101191193,
0.153046295,
-0.3730731905,
-0.1292416602,
-0.2302129269,
-0.4134919643,
0.2596665025,
0.163496092,
-0.2700080276,
0.0250566378,
-0.2863544226,
0.0119892936,
0.113785319,
-0.1277266592,
0.4657014906,
-0.2920139432,
-0.1193426102,
-0.6847845912,
0.084660612,
0.0923071578,
0.2418773472,
-0.0910454616,
0.3085485995,
-0.1139217988,
0.4207445979,
-0.383130312,
-0.1236377805,
-0.095174022,
0.0261606872,
-0.1424012929,
0.1253938079,
0.1052283198,
0.0120824063,
0.2795462012,
0.1791643053,
0.0852370411,
-0.2446636856,
0.0206562113,
0.0673325509,
-0.012857384,
0.1886310875,
-0.143785134,
0.1827834398,
-0.0340192355,
0.0805035532,
0.0635812059,
-0.2142196745,
0.0720005184,
0.5170302391,
0.001559679,
0.3738712668,
0.2085385472,
-0.3807269931,
0.1647592634,
0.1969907582,
0.0629086643,
0.0796953812,
0.0315674543,
-0.1974562407,
-0.2258631438,
-0.1494313031,
-0.1706695855,
-0.1023815945,
0.1594367772,
-0.0842019618,
0.0489150174,
-0.2541467547,
-0.2469742894,
-0.1922261417,
-0.1377260685,
0.40273875,
-0.166105479,
0.3383505344,
-0.3222352266,
0.2194848508,
0.1384897381,
-0.2340570539,
0.403858006,
0.166889742,
0.0815947056,
0.1041587368,
0.1086277813,
0.0006812685,
-0.2021349519,
-0.3151361346,
-0.0145554813,
-0.2254245728,
-0.1450472027,
-0.0520639792,
-0.0086746113,
0.4659986198,
0.1152551845,
0.0580728427,
-0.0347970277,
0.312800169,
0.0291871708,
-0.2569917738,
-0.1333462149,
0.2735691965,
0.2254725844,
0.1482052356,
-0.2445322424,
-0.2448830605,
0.2093804926,
0.014736101,
0.259924233,
0.1151595265,
0.0879939124,
0.0245630685,
-0.0748739988,
0.1329130828,
-0.1615413874,
0.0272864364,
0.0083126044,
-0.4961479604,
0.4540582597,
0.0197916124,
0.3592812121,
0.0094491504,
-0.1366972327,
0.3265838325,
-0.1150179505,
0.2745340765,
0.291270107,
0.0145206889,
-0.0274460278,
0.1890660375,
-0.2468674332,
0.0273045711,
0.1485269219,
0.1980179101,
-0.1725937724,
0.1242914498,
0.2728430331,
0.1988863945,
-0.4539814591,
-0.0438922457,
0.0097732535,
0.3897031248,
0.1741363257,
-0.1174858138,
0.2516443431,
-0.2438939661,
0.0432756506,
0.1727748215,
0.2546553612,
-0.2248341441,
0.0309997182,
-0.323312968,
-0.2758279741,
-0.1908756346,
-0.0567898154,
-0.2546935976,
0.1486682147,
-0.0284461807,
-0.1154245734,
0.0920688063,
-0.1310922801,
0.0961888134,
-0.054417517,
0.2366347015,
-0.3606317639,
0.0298498701,
-0.248138845,
-0.2751562297,
-0.1471740454,
0.2483398765,
0.1515551805,
-0.1386951655,
0.0534884296,
0.318356812,
0.041216258,
-0.1101803705,
0.3300687373,
-0.6668446064,
0.1768387854,
0.358001858,
-0.3746558726,
0.0164402295,
-0.2233828157,
-0.0211764351,
0.422237277,
0.2050825655,
0.0705492049,
0.1290493906,
0.1250909418,
-0.2997333407,
0.2207965404,
-0.1879361719,
0.4197393656,
0.3551920354,
-0.1828262061,
0.4042818248,
-0.3066492677,
0.2137334645,
0.3719344437,
0.1562607288,
-0.2533104122,
0.1702733338,
0.3084546328,
0.2727311552,
0.1707512289,
-0.2394830585,
-0.0878330916,
0.243628487,
0.1005045399,
-0.6387304068,
0.119463332,
0.4051736891,
-0.0529855117,
0.1463834643,
0.1399642229,
0.0316314958,
0.1003136411,
0.1197821647,
0.0374338143,
-0.2836812735,
0.4032078683,
-0.0077173966,
-0.2011442333,
-0.3372564614,
0.251296401,
-0.0798204318,
0.4243530333,
-0.6292932034,
-0.1902176589,
0.2446600497,
-0.2690584362,
-0.1225004941,
0.4333189726,
-0.1099830344,
0.0640582889,
0.068426989,
-0.0047873608,
0.2105076462,
0.3445385098,
-0.1536096781,
-0.2668265104
] |
https://github.com/huggingface/datasets/issues/3353 | add one field "example_id", but I can't see it in the "comput_loss" function | Hi, I have set **args.remove_unused_columns=False** and **training_args.remove_unused_columns=False**, but the field doesn't been contained yet.
```
def main():
argp = HfArgumentParser(TrainingArguments)
# The HfArgumentParser object collects command-line arguments into an object (and provides default values for unspecified arguments).
# In particular, TrainingArguments has several keys that you'll need/want to specify (when you call run.py from the command line):
# --do_train
# When included, this argument tells the script to train a model.
# See docstrings for "--task" and "--dataset" for how the training dataset is selected.
# --do_eval
# When included, this argument tells the script to evaluate the trained/loaded model on the validation split of the selected dataset.
# --per_device_train_batch_size <int, default=8>
# This is the training batch size.
# If you're running on GPU, you should try to make this as large as you can without getting CUDA out-of-memory errors.
# For reference, with --max_length=128 and the default ELECTRA-small model, a batch size of 32 should fit in 4gb of GPU memory.
# --num_train_epochs <float, default=3.0>
# How many passes to do through the training data.
# --output_dir <path>
# Where to put the trained model checkpoint(s) and any eval predictions.
# *This argument is required*.
argp.add_argument('--model', type=str,
default='google/electra-small-discriminator',
help="""This argument specifies the base model to fine-tune.
This should either be a HuggingFace model ID (see https://huggingface.co/models)
or a path to a saved model checkpoint (a folder containing config.json and pytorch_model.bin).""")
argp.add_argument('--task', type=str, choices=['nli', 'qa'], required=True,
help="""This argument specifies which task to train/evaluate on.
Pass "nli" for natural language inference or "qa" for question answering.
By default, "nli" will use the SNLI dataset, and "qa" will use the SQuAD dataset.""")
argp.add_argument('--dataset', type=str, default=None,
help="""This argument overrides the default dataset used for the specified task.""")
argp.add_argument('--max_length', type=int, default=128,
help="""This argument limits the maximum sequence length used during training/evaluation.
Shorter sequence lengths need less memory and computation time, but some examples may end up getting truncated.""")
argp.add_argument('--max_train_samples', type=int, default=None,
help='Limit the number of examples to train on.')
argp.add_argument('--max_eval_samples', type=int, default=None,
help='Limit the number of examples to evaluate on.')
argp.remove_unused_columns = False
training_args, args = argp.parse_args_into_dataclasses()
args.remove_unused_columns=False
training_args.remove_unused_columns=False
```
```
**************** train_dataset: Dataset({
features: ['id', 'title', 'context', 'question', 'answers'],
num_rows: 87599
})
**************** train_dataset_featurized: Dataset({
features: ['attention_mask', 'end_positions', 'input_ids', 'start_positions', 'token_type_ids'],
num_rows: 87714
})
``` | Hi, I add one field **example_id**, but I can't see it in the **comput_loss** function, how can I do this? below is the information of inputs
```
*********************** inputs: {'attention_mask': tensor([[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
...,
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0]], device='cuda:0'), 'end_positions': tensor([ 25, 97, 93, 44, 25, 112, 109, 134], device='cuda:0'), 'input_ids': tensor([[ 101, 2054, 2390, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2106, ..., 0, 0, 0],
...,
[ 101, 2339, 2001, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2003, ..., 0, 0, 0]], device='cuda:0'), 'start_positions': tensor([ 20, 90, 89, 41, 25, 96, 106, 132], device='cuda:0'), 'token_type_ids': tensor([[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
...,
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0]], device='cuda:0')}
```
```
# This function preprocesses a question answering dataset, tokenizing the question and context text
# and finding the right offsets for the answer spans in the tokenized context (to use as labels).
# Adapted from https://github.com/huggingface/transformers/blob/master/examples/pytorch/question-answering/run_qa.py
def prepare_train_dataset_qa(examples, tokenizer, max_seq_length=None):
questions = [q.lstrip() for q in examples["question"]]
max_seq_length = tokenizer.model_max_length
# tokenize both questions and the corresponding context
# if the context length is longer than max_length, we split it to several
# chunks of max_length
tokenized_examples = tokenizer(
questions,
examples["context"],
truncation="only_second",
max_length=max_seq_length,
stride=min(max_seq_length // 2, 128),
return_overflowing_tokens=True,
return_offsets_mapping=True,
padding="max_length"
)
# Since one example might give us several features if it has a long context,
# we need a map from a feature to its corresponding example.
sample_mapping = tokenized_examples.pop("overflow_to_sample_mapping")
# The offset mappings will give us a map from token to character position
# in the original context. This will help us compute the start_positions
# and end_positions to get the final answer string.
offset_mapping = tokenized_examples.pop("offset_mapping")
tokenized_examples["start_positions"] = []
tokenized_examples["end_positions"] = []
tokenized_examples["example_id"] = []
for i, offsets in enumerate(offset_mapping):
input_ids = tokenized_examples["input_ids"][i]
# We will label features not containing the answer the index of the CLS token.
cls_index = input_ids.index(tokenizer.cls_token_id)
sequence_ids = tokenized_examples.sequence_ids(i)
# from the feature idx to sample idx
sample_index = sample_mapping[i]
# get the answer for a feature
answers = examples["answers"][sample_index]
tokenized_examples["example_id"].append(examples["id"][sample_index])
if len(answers["answer_start"]) == 0:
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Start/end character index of the answer in the text.
start_char = answers["answer_start"][0]
end_char = start_char + len(answers["text"][0])
# Start token index of the current span in the text.
token_start_index = 0
while sequence_ids[token_start_index] != 1:
token_start_index += 1
# End token index of the current span in the text.
token_end_index = len(input_ids) - 1
while sequence_ids[token_end_index] != 1:
token_end_index -= 1
# Detect if the answer is out of the span (in which case this feature is labeled with the CLS index).
if not (offsets[token_start_index][0] <= start_char and
offsets[token_end_index][1] >= end_char):
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Otherwise move the token_start_index and token_end_index to the two ends of the answer.
# Note: we could go after the last offset if the answer is the last word (edge case).
while token_start_index < len(offsets) and \
offsets[token_start_index][0] <= start_char:
token_start_index += 1
tokenized_examples["start_positions"].append(
token_start_index - 1)
while offsets[token_end_index][1] >= end_char:
token_end_index -= 1
tokenized_examples["end_positions"].append(token_end_index + 1)
return tokenized_examples
```
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/3333#issuecomment-983457161_ | 373 | add one field "example_id", but I can't see it in the "comput_loss" function
Hi, I add one field **example_id**, but I can't see it in the **comput_loss** function, how can I do this? below is the information of inputs
```
*********************** inputs: {'attention_mask': tensor([[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
...,
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0]], device='cuda:0'), 'end_positions': tensor([ 25, 97, 93, 44, 25, 112, 109, 134], device='cuda:0'), 'input_ids': tensor([[ 101, 2054, 2390, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2106, ..., 0, 0, 0],
...,
[ 101, 2339, 2001, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2003, ..., 0, 0, 0]], device='cuda:0'), 'start_positions': tensor([ 20, 90, 89, 41, 25, 96, 106, 132], device='cuda:0'), 'token_type_ids': tensor([[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
...,
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0]], device='cuda:0')}
```
```
# This function preprocesses a question answering dataset, tokenizing the question and context text
# and finding the right offsets for the answer spans in the tokenized context (to use as labels).
# Adapted from https://github.com/huggingface/transformers/blob/master/examples/pytorch/question-answering/run_qa.py
def prepare_train_dataset_qa(examples, tokenizer, max_seq_length=None):
questions = [q.lstrip() for q in examples["question"]]
max_seq_length = tokenizer.model_max_length
# tokenize both questions and the corresponding context
# if the context length is longer than max_length, we split it to several
# chunks of max_length
tokenized_examples = tokenizer(
questions,
examples["context"],
truncation="only_second",
max_length=max_seq_length,
stride=min(max_seq_length // 2, 128),
return_overflowing_tokens=True,
return_offsets_mapping=True,
padding="max_length"
)
# Since one example might give us several features if it has a long context,
# we need a map from a feature to its corresponding example.
sample_mapping = tokenized_examples.pop("overflow_to_sample_mapping")
# The offset mappings will give us a map from token to character position
# in the original context. This will help us compute the start_positions
# and end_positions to get the final answer string.
offset_mapping = tokenized_examples.pop("offset_mapping")
tokenized_examples["start_positions"] = []
tokenized_examples["end_positions"] = []
tokenized_examples["example_id"] = []
for i, offsets in enumerate(offset_mapping):
input_ids = tokenized_examples["input_ids"][i]
# We will label features not containing the answer the index of the CLS token.
cls_index = input_ids.index(tokenizer.cls_token_id)
sequence_ids = tokenized_examples.sequence_ids(i)
# from the feature idx to sample idx
sample_index = sample_mapping[i]
# get the answer for a feature
answers = examples["answers"][sample_index]
tokenized_examples["example_id"].append(examples["id"][sample_index])
if len(answers["answer_start"]) == 0:
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Start/end character index of the answer in the text.
start_char = answers["answer_start"][0]
end_char = start_char + len(answers["text"][0])
# Start token index of the current span in the text.
token_start_index = 0
while sequence_ids[token_start_index] != 1:
token_start_index += 1
# End token index of the current span in the text.
token_end_index = len(input_ids) - 1
while sequence_ids[token_end_index] != 1:
token_end_index -= 1
# Detect if the answer is out of the span (in which case this feature is labeled with the CLS index).
if not (offsets[token_start_index][0] <= start_char and
offsets[token_end_index][1] >= end_char):
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Otherwise move the token_start_index and token_end_index to the two ends of the answer.
# Note: we could go after the last offset if the answer is the last word (edge case).
while token_start_index < len(offsets) and \
offsets[token_start_index][0] <= start_char:
token_start_index += 1
tokenized_examples["start_positions"].append(
token_start_index - 1)
while offsets[token_end_index][1] >= end_char:
token_end_index -= 1
tokenized_examples["end_positions"].append(token_end_index + 1)
return tokenized_examples
```
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/3333#issuecomment-983457161_
Hi, I have set **args.remove_unused_columns=False** and **training_args.remove_unused_columns=False**, but the field doesn't been contained yet.
```
def main():
argp = HfArgumentParser(TrainingArguments)
# The HfArgumentParser object collects command-line arguments into an object (and provides default values for unspecified arguments).
# In particular, TrainingArguments has several keys that you'll need/want to specify (when you call run.py from the command line):
# --do_train
# When included, this argument tells the script to train a model.
# See docstrings for "--task" and "--dataset" for how the training dataset is selected.
# --do_eval
# When included, this argument tells the script to evaluate the trained/loaded model on the validation split of the selected dataset.
# --per_device_train_batch_size <int, default=8>
# This is the training batch size.
# If you're running on GPU, you should try to make this as large as you can without getting CUDA out-of-memory errors.
# For reference, with --max_length=128 and the default ELECTRA-small model, a batch size of 32 should fit in 4gb of GPU memory.
# --num_train_epochs <float, default=3.0>
# How many passes to do through the training data.
# --output_dir <path>
# Where to put the trained model checkpoint(s) and any eval predictions.
# *This argument is required*.
argp.add_argument('--model', type=str,
default='google/electra-small-discriminator',
help="""This argument specifies the base model to fine-tune.
This should either be a HuggingFace model ID (see https://huggingface.co/models)
or a path to a saved model checkpoint (a folder containing config.json and pytorch_model.bin).""")
argp.add_argument('--task', type=str, choices=['nli', 'qa'], required=True,
help="""This argument specifies which task to train/evaluate on.
Pass "nli" for natural language inference or "qa" for question answering.
By default, "nli" will use the SNLI dataset, and "qa" will use the SQuAD dataset.""")
argp.add_argument('--dataset', type=str, default=None,
help="""This argument overrides the default dataset used for the specified task.""")
argp.add_argument('--max_length', type=int, default=128,
help="""This argument limits the maximum sequence length used during training/evaluation.
Shorter sequence lengths need less memory and computation time, but some examples may end up getting truncated.""")
argp.add_argument('--max_train_samples', type=int, default=None,
help='Limit the number of examples to train on.')
argp.add_argument('--max_eval_samples', type=int, default=None,
help='Limit the number of examples to evaluate on.')
argp.remove_unused_columns = False
training_args, args = argp.parse_args_into_dataclasses()
args.remove_unused_columns=False
training_args.remove_unused_columns=False
```
```
**************** train_dataset: Dataset({
features: ['id', 'title', 'context', 'question', 'answers'],
num_rows: 87599
})
**************** train_dataset_featurized: Dataset({
features: ['attention_mask', 'end_positions', 'input_ids', 'start_positions', 'token_type_ids'],
num_rows: 87714
})
``` | [
-0.1465506107,
-0.5799238086,
-0.274071902,
0.1202487126,
0.1545111835,
0.0243577175,
0.518656373,
0.1191996783,
0.2118413895,
0.4652202725,
0.3532586992,
0.3118036389,
0.2009701878,
-0.1237443164,
0.3787087202,
0.0022589611,
-0.0379148796,
0.224128589,
0.2628958523,
-0.1642495841,
-0.183089748,
-0.0878601,
-0.218925029,
0.0226238295,
-0.2868743539,
-0.208893016,
0.0530895069,
-0.1255611032,
-0.0868299603,
-0.0424166285,
0.1870988011,
-0.1108928472,
-0.2399868071,
0.199706316,
-0.0001078606,
0.1045567244,
0.1533192098,
-0.0608258732,
-0.0272859689,
-0.1543922424,
-0.2217087746,
-0.2605636418,
-0.0360182188,
-0.3241762221,
-0.0498114787,
0.1234708503,
-0.1091194451,
-0.3235187232,
0.0795222297,
0.2246320397,
0.2008235306,
-0.1087317839,
0.1274075657,
-0.0000119107,
0.2504412234,
0.0550517887,
0.0921009034,
-0.2274120599,
-0.2579442263,
-0.0577589981,
0.4909737408,
0.4897180498,
0.3399707079,
-0.1195267215,
0.0124899726,
0.2712908983,
0.2939135432,
-0.1918281168,
0.0852965564,
-0.1495800912,
-0.2388664931,
-0.0874888822,
-0.0544351488,
0.1071323305,
0.1659787893,
-0.7740447521,
-0.2672750056,
-0.0151067004,
0.0079791779,
0.0360805653,
0.2593709826,
0.0940451175,
-0.3109925091,
0.4295270443,
0.0709782764,
0.2999991179,
0.0571777672,
0.1011035219,
0.1933594793,
-0.0105596436,
-0.0151527831,
0.3169314563,
0.3318520784,
0.0747607127,
-0.3491978645,
0.0346172415,
-0.0871883109,
-0.4820678234,
-0.1534082443,
-0.2185961902,
0.3559982777,
0.1997032613,
0.2166689783,
0.4776992798,
-0.3577488065,
0.2326746285,
-0.1546849757,
0.0067086807,
0.0488918722,
-0.0942224711,
0.0168210939,
-0.24926579,
-0.0476013683,
0.2071011811,
0.0075180656,
0.1878779531,
0.0598699823,
0.2564727068,
-0.3819018602,
-0.0711564273,
-0.0432543829,
-0.1892253906,
0.2999635935,
0.3324873149,
0.1197899133,
0.1190501079,
0.1769399643,
0.0945180506,
-0.0657149106,
-0.0995360166,
-0.3446668088,
0.3517922759,
-0.0081031248,
-0.0312071461,
0.229830265,
0.1371507198,
0.2383444458,
-0.1337921917,
0.2179640383,
-0.0860011131,
0.1516470909,
-0.1166076884,
0.4551613331,
0.2630287409,
-0.1637019664,
0.0134522561,
0.2568819225,
-0.2118529975,
0.0206137281,
0.1065059751,
-0.2221775204,
-0.0247162618,
-0.2702471018,
0.1769711524,
0.3174368739,
-0.0659502074,
0.1990665644,
0.4340725839,
0.0306911245,
-0.1820393652,
0.1591261029,
0.2752167881,
-0.4124224484,
-0.2381926775,
0.3947790563,
-0.1607451886,
-0.1401053369,
-0.141785562,
-0.2604891956,
0.1221225783,
0.1909762174,
-0.0842138007,
-0.0475603007,
-0.0282747149,
0.0637511387,
0.3494353592,
0.8107308149,
-0.3744962215,
-0.2795385122,
-0.0711329207,
-0.2432867438,
-0.3155626655,
0.3230952919,
0.1094321683,
-0.0346453451,
0.350897491,
0.3981733024,
-0.2225913256,
-0.058040645,
-0.0951701924,
-0.157324627,
0.1440274864,
0.2992529869,
-0.0405863933,
-0.032645002,
0.229087308,
0.1560370028,
-0.046294827,
0.17617625,
0.0521368645,
0.0390579067,
-0.0493439548,
0.4451039433,
-0.3515290916,
-0.0790179148,
-0.3894447684,
0.0563286431,
0.0327258483,
0.105559513,
-0.1064713523,
0.2491143793,
-0.3219109476,
-0.156619519,
-0.1171730235,
0.2654783726,
0.1461737156,
0.2600670159,
0.1603276432,
-0.1780048907,
-0.2101499736,
-0.1849679351,
0.2014156878,
0.1087631285,
-0.1175370067,
-0.0605794899,
0.108806923,
-0.2590561807,
-0.3654018342,
-0.2350620776,
0.1987408698,
0.5106500983,
-0.070552513,
0.1146341339,
0.2025002986,
0.0576812178,
-0.1379923075,
-0.0804836676,
0.247410059,
0.238827616,
0.1963553131,
-0.092208907,
-0.0410733148,
-0.0662460774,
-0.0322654434,
0.0253206398,
0.1264405251,
0.1489983648,
-0.1023368761,
-0.0388093181,
-0.0366984978,
0.0363957137,
0.1048706323,
-0.0081957802,
-0.2124927044,
-0.0292192549,
-0.02710413,
-0.1880142242,
-0.3396835029,
-0.6948493719,
0.2774123251,
0.3753505945,
0.2250716835,
0.0887846723,
-0.1543403417,
0.1054508239,
0.3096154928,
0.1741134822,
-0.0688997656,
0.2824614942,
0.2431523055,
-0.0006570601,
-0.1929287612,
-0.1459147185,
0.0332997181,
-0.1217951626,
0.0161180329,
-0.0088923573,
0.0553401932,
0.0460408255,
-0.1220655963,
-0.0741402805,
0.1098109409,
-0.0425804891,
0.1530542374,
-0.1819598377,
0.0745958239,
-0.2065949589,
-0.1701564938,
-0.0176640656,
-0.1878846288,
0.4881099164,
-0.2357124686,
0.108563371,
0.0685065687,
-0.0312240217,
0.1133598611,
0.3010867834,
0.3493435383,
0.0032124056,
0.4118727446,
-0.5014944673,
0.0754358545,
0.0803720653,
0.1347717345,
-0.323775351,
0.2229703069,
0.0899232253,
0.1199859902,
0.163475275,
0.1981916577,
-0.5742998719,
-0.0457441844,
-0.1828483492,
-0.1081298813,
-0.2321815789,
0.3006094992,
-0.4940449893,
-0.4426555336,
0.0445017219,
-0.1192849278,
-0.1709110141,
-0.0220641308,
-0.109759666,
0.0612727888,
-0.3739386499,
-0.4167387784,
-0.2716556787,
-0.2535756528,
0.3533881605,
0.1404966414,
0.1286893487,
-0.0205969587,
0.1233990565,
0.0022618512,
0.390040338,
0.3684777617,
-0.2363982499,
-0.3898071647,
0.2644088864,
-0.4682346284,
-0.2753450274,
0.1190086529,
-0.2428461909,
0.3059527278,
-0.0551914908,
-0.0429992825,
-0.1326035708,
0.1728417873,
-0.1390807033,
-0.1978014708,
0.250329107,
0.5233486295,
-0.126338914,
-0.1503020376,
-0.1779243052,
-0.4433750212,
0.1343268305,
0.3658438623,
0.2038741261,
-0.3099858463,
0.2279687226,
-0.0131086791,
0.5472481847,
0.0150866266,
-0.5900515914,
0.1056579351,
-0.359562546,
-0.0319627449,
0.2820094228,
-0.389461875,
-0.0417868495,
0.1235161722,
0.0056943861,
-0.1467068046,
-0.4287927449,
-0.2567921579,
-0.0766892061,
0.0805044174,
-0.5425463319,
0.0181248747,
-0.1387891471,
0.0470177382,
-0.0577977635,
-0.1137975454,
-0.0473476201,
-0.4487857223,
0.063312687,
0.202952534,
0.1094742194,
-0.0809170008,
-0.2151966393,
0.1158836111,
-0.7709780931,
-0.2294573784,
0.215963006,
-0.0320693888,
0.0548228025,
-0.0477108881,
-0.189836666,
-0.0463781394,
0.1821792424,
0.410623461,
-0.2682365179,
-0.3791665137,
0.3391001523,
-0.1767856777,
0.0223890692,
0.0805483386,
-0.1487300098,
-0.0903297812,
0.3995429277,
0.2576504648,
-0.2826338112,
0.1514883488,
0.4574837983,
0.017806109,
-0.1433134526,
0.1389861107,
-0.407248795,
0.0921383128,
-0.2252016515,
0.0633089542,
0.1053115055,
0.2456721961,
0.3113098741,
-0.1568218917,
-0.0494199097,
-0.2709628344,
0.0991963446,
0.1898778826,
0.1328711063,
0.4358684421,
-0.1194885224,
0.2090510279,
0.2822466791,
-0.2177584022,
-0.0802924186,
0.0966512933,
-0.0369397104,
0.1970512718,
-0.0768765062,
0.4107712507,
0.0712356344,
0.0180286653,
0.2601253986,
-0.154182598,
0.3188805878,
-0.0546550639,
0.2812376618,
0.3012107313,
0.0483411327,
0.2414410412,
-0.1765300333,
0.059619505,
-0.0958827287,
-0.1697422415,
0.3887868226,
-0.0318235382,
-0.0489952751,
0.2164387703,
0.1120499,
0.9591209292,
-0.1575283259,
-0.2097389996,
0.010101567,
-0.0759112835,
0.246584028,
-0.5863705277,
0.2355298549,
0.0334868543,
-0.4988214374,
-0.0105420575,
-0.0881967917,
0.044007767,
0.0403953083,
-0.2475857139,
-0.1044775248,
-0.0600731559,
0.1326296777,
-0.2600261271,
0.1042772382,
0.5729569793,
-0.0145095149,
0.1290891767,
0.1071654633,
0.2161007077,
-0.1032794267,
0.0142463967,
0.043840792,
-0.3111595213,
-0.1651967317,
-0.0577949472,
-0.2926233709,
-0.3724552989,
0.0779147893,
-0.2301871926,
-0.3371114433,
-0.1382795125,
0.2469748259,
0.5074902773,
-0.0876613185,
-0.0729399547,
0.0783381015,
0.0328867845,
-0.0796208233,
-0.4444467127,
-0.0946100354,
0.136764273,
-0.2206638753,
-0.4410490096,
0.5772229433,
0.1857408732,
-0.1705364585,
-0.1899651885,
0.2871699929,
-0.0383694619,
0.129547134,
0.010304179,
0.3733169138,
-0.0053962925,
-0.3326701522,
0.1627595574,
0.0596208572,
-0.3349808156,
0.0551164001,
0.1015768796,
-0.059681952,
-0.1164965257,
0.2710948884,
0.1846642196,
0.1101191193,
0.153046295,
-0.3730731905,
-0.1292416602,
-0.2302129269,
-0.4134919643,
0.2596665025,
0.163496092,
-0.2700080276,
0.0250566378,
-0.2863544226,
0.0119892936,
0.113785319,
-0.1277266592,
0.4657014906,
-0.2920139432,
-0.1193426102,
-0.6847845912,
0.084660612,
0.0923071578,
0.2418773472,
-0.0910454616,
0.3085485995,
-0.1139217988,
0.4207445979,
-0.383130312,
-0.1236377805,
-0.095174022,
0.0261606872,
-0.1424012929,
0.1253938079,
0.1052283198,
0.0120824063,
0.2795462012,
0.1791643053,
0.0852370411,
-0.2446636856,
0.0206562113,
0.0673325509,
-0.012857384,
0.1886310875,
-0.143785134,
0.1827834398,
-0.0340192355,
0.0805035532,
0.0635812059,
-0.2142196745,
0.0720005184,
0.5170302391,
0.001559679,
0.3738712668,
0.2085385472,
-0.3807269931,
0.1647592634,
0.1969907582,
0.0629086643,
0.0796953812,
0.0315674543,
-0.1974562407,
-0.2258631438,
-0.1494313031,
-0.1706695855,
-0.1023815945,
0.1594367772,
-0.0842019618,
0.0489150174,
-0.2541467547,
-0.2469742894,
-0.1922261417,
-0.1377260685,
0.40273875,
-0.166105479,
0.3383505344,
-0.3222352266,
0.2194848508,
0.1384897381,
-0.2340570539,
0.403858006,
0.166889742,
0.0815947056,
0.1041587368,
0.1086277813,
0.0006812685,
-0.2021349519,
-0.3151361346,
-0.0145554813,
-0.2254245728,
-0.1450472027,
-0.0520639792,
-0.0086746113,
0.4659986198,
0.1152551845,
0.0580728427,
-0.0347970277,
0.312800169,
0.0291871708,
-0.2569917738,
-0.1333462149,
0.2735691965,
0.2254725844,
0.1482052356,
-0.2445322424,
-0.2448830605,
0.2093804926,
0.014736101,
0.259924233,
0.1151595265,
0.0879939124,
0.0245630685,
-0.0748739988,
0.1329130828,
-0.1615413874,
0.0272864364,
0.0083126044,
-0.4961479604,
0.4540582597,
0.0197916124,
0.3592812121,
0.0094491504,
-0.1366972327,
0.3265838325,
-0.1150179505,
0.2745340765,
0.291270107,
0.0145206889,
-0.0274460278,
0.1890660375,
-0.2468674332,
0.0273045711,
0.1485269219,
0.1980179101,
-0.1725937724,
0.1242914498,
0.2728430331,
0.1988863945,
-0.4539814591,
-0.0438922457,
0.0097732535,
0.3897031248,
0.1741363257,
-0.1174858138,
0.2516443431,
-0.2438939661,
0.0432756506,
0.1727748215,
0.2546553612,
-0.2248341441,
0.0309997182,
-0.323312968,
-0.2758279741,
-0.1908756346,
-0.0567898154,
-0.2546935976,
0.1486682147,
-0.0284461807,
-0.1154245734,
0.0920688063,
-0.1310922801,
0.0961888134,
-0.054417517,
0.2366347015,
-0.3606317639,
0.0298498701,
-0.248138845,
-0.2751562297,
-0.1471740454,
0.2483398765,
0.1515551805,
-0.1386951655,
0.0534884296,
0.318356812,
0.041216258,
-0.1101803705,
0.3300687373,
-0.6668446064,
0.1768387854,
0.358001858,
-0.3746558726,
0.0164402295,
-0.2233828157,
-0.0211764351,
0.422237277,
0.2050825655,
0.0705492049,
0.1290493906,
0.1250909418,
-0.2997333407,
0.2207965404,
-0.1879361719,
0.4197393656,
0.3551920354,
-0.1828262061,
0.4042818248,
-0.3066492677,
0.2137334645,
0.3719344437,
0.1562607288,
-0.2533104122,
0.1702733338,
0.3084546328,
0.2727311552,
0.1707512289,
-0.2394830585,
-0.0878330916,
0.243628487,
0.1005045399,
-0.6387304068,
0.119463332,
0.4051736891,
-0.0529855117,
0.1463834643,
0.1399642229,
0.0316314958,
0.1003136411,
0.1197821647,
0.0374338143,
-0.2836812735,
0.4032078683,
-0.0077173966,
-0.2011442333,
-0.3372564614,
0.251296401,
-0.0798204318,
0.4243530333,
-0.6292932034,
-0.1902176589,
0.2446600497,
-0.2690584362,
-0.1225004941,
0.4333189726,
-0.1099830344,
0.0640582889,
0.068426989,
-0.0047873608,
0.2105076462,
0.3445385098,
-0.1536096781,
-0.2668265104
] |
https://github.com/huggingface/datasets/issues/3353 | add one field "example_id", but I can't see it in the "comput_loss" function | Hi, I print the value, all are set to False, but don't work.
```
********************* training_args: TrainingArguments(
_n_gpu=1,
adafactor=False,
adam_beta1=0.9,
adam_beta2=0.999,
adam_epsilon=1e-08,
dataloader_drop_last=False,
dataloader_num_workers=0,
dataloader_pin_memory=True,
ddp_find_unused_parameters=None,
debug=[],
deepspeed=None,
disable_tqdm=False,
do_eval=False,
do_predict=False,
do_train=True,
eval_accumulation_steps=None,
eval_steps=None,
evaluation_strategy=IntervalStrategy.NO,
fp16=False,
fp16_backend=auto,
fp16_full_eval=False,
fp16_opt_level=O1,
gradient_accumulation_steps=1,
greater_is_better=None,
group_by_length=False,
ignore_data_skip=False,
label_names=None,
label_smoothing_factor=0.0,
learning_rate=5e-05,
length_column_name=length,
load_best_model_at_end=False,
local_rank=-1,
log_level=-1,
log_level_replica=-1,
log_on_each_node=True,
logging_dir=./re_trained_model/runs/Dec01_14-15-08_399b9290604c,
logging_first_step=False,
logging_steps=500,
logging_strategy=IntervalStrategy.STEPS,
lr_scheduler_type=SchedulerType.LINEAR,
max_grad_norm=1.0,
max_steps=-1,
metric_for_best_model=None,
mp_parameters=,
no_cuda=False,
num_train_epochs=3.0,
output_dir=./re_trained_model,
overwrite_output_dir=False,
past_index=-1,
per_device_eval_batch_size=8,
per_device_train_batch_size=8,
prediction_loss_only=False,
push_to_hub=False,
push_to_hub_model_id=re_trained_model,
push_to_hub_organization=None,
push_to_hub_token=None,
remove_unused_columns=False,
report_to=['tensorboard'],
resume_from_checkpoint=None,
run_name=./re_trained_model,
save_on_each_node=False,
save_steps=500,
save_strategy=IntervalStrategy.STEPS,
save_total_limit=None,
seed=42,
sharded_ddp=[],
skip_memory_metrics=True,
tpu_metrics_debug=False,
tpu_num_cores=None,
use_legacy_prediction_loop=False,
warmup_ratio=0.0,
warmup_steps=0,
weight_decay=0.0,
)
```
```
********************* args: Namespace(dataset='squad', max_eval_samples=None, max_length=128, max_train_samples=None, model='google/electra-small-discriminator', remove_unused_columns=False, task='qa')
2021-12-01 14:15:10,048 - WARNING - datasets.builder - Reusing dataset squad (/root/.cache/huggingface/datasets/squad/plain_text/1.0.0/d6ec3ceb99ca480ce37cdd35555d6cb2511d223b9150cce08a837ef62ffea453)
Some weights of the model checkpoint at google/electra-small-discriminator were not used when initializing ElectraForQuestionAnswering: ['discriminator_predictions.dense_prediction.weight', 'discriminator_predictions.dense_prediction.bias', 'discriminator_predictions.dense.weight', 'discriminator_predictions.dense.bias']
- This IS expected if you are initializing ElectraForQuestionAnswering from the checkpoint of a model trained on another task or with another architecture (e.g. initializing a BertForSequenceClassification model from a BertForPreTraining model).
- This IS NOT expected if you are initializing ElectraForQuestionAnswering from the checkpoint of a model that you expect to be exactly identical (initializing a BertForSequenceClassification model from a BertForSequenceClassification model).
Some weights of ElectraForQuestionAnswering were not initialized from the model checkpoint at google/electra-small-discriminator and are newly initialized: ['qa_outputs.bias', 'qa_outputs.weight']
You should probably TRAIN this model on a down-stream task to be able to use it for predictions and inference.
Preprocessing data... (this takes a little bit, should only happen once per dataset)
``` | Hi, I add one field **example_id**, but I can't see it in the **comput_loss** function, how can I do this? below is the information of inputs
```
*********************** inputs: {'attention_mask': tensor([[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
...,
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0]], device='cuda:0'), 'end_positions': tensor([ 25, 97, 93, 44, 25, 112, 109, 134], device='cuda:0'), 'input_ids': tensor([[ 101, 2054, 2390, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2106, ..., 0, 0, 0],
...,
[ 101, 2339, 2001, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2003, ..., 0, 0, 0]], device='cuda:0'), 'start_positions': tensor([ 20, 90, 89, 41, 25, 96, 106, 132], device='cuda:0'), 'token_type_ids': tensor([[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
...,
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0]], device='cuda:0')}
```
```
# This function preprocesses a question answering dataset, tokenizing the question and context text
# and finding the right offsets for the answer spans in the tokenized context (to use as labels).
# Adapted from https://github.com/huggingface/transformers/blob/master/examples/pytorch/question-answering/run_qa.py
def prepare_train_dataset_qa(examples, tokenizer, max_seq_length=None):
questions = [q.lstrip() for q in examples["question"]]
max_seq_length = tokenizer.model_max_length
# tokenize both questions and the corresponding context
# if the context length is longer than max_length, we split it to several
# chunks of max_length
tokenized_examples = tokenizer(
questions,
examples["context"],
truncation="only_second",
max_length=max_seq_length,
stride=min(max_seq_length // 2, 128),
return_overflowing_tokens=True,
return_offsets_mapping=True,
padding="max_length"
)
# Since one example might give us several features if it has a long context,
# we need a map from a feature to its corresponding example.
sample_mapping = tokenized_examples.pop("overflow_to_sample_mapping")
# The offset mappings will give us a map from token to character position
# in the original context. This will help us compute the start_positions
# and end_positions to get the final answer string.
offset_mapping = tokenized_examples.pop("offset_mapping")
tokenized_examples["start_positions"] = []
tokenized_examples["end_positions"] = []
tokenized_examples["example_id"] = []
for i, offsets in enumerate(offset_mapping):
input_ids = tokenized_examples["input_ids"][i]
# We will label features not containing the answer the index of the CLS token.
cls_index = input_ids.index(tokenizer.cls_token_id)
sequence_ids = tokenized_examples.sequence_ids(i)
# from the feature idx to sample idx
sample_index = sample_mapping[i]
# get the answer for a feature
answers = examples["answers"][sample_index]
tokenized_examples["example_id"].append(examples["id"][sample_index])
if len(answers["answer_start"]) == 0:
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Start/end character index of the answer in the text.
start_char = answers["answer_start"][0]
end_char = start_char + len(answers["text"][0])
# Start token index of the current span in the text.
token_start_index = 0
while sequence_ids[token_start_index] != 1:
token_start_index += 1
# End token index of the current span in the text.
token_end_index = len(input_ids) - 1
while sequence_ids[token_end_index] != 1:
token_end_index -= 1
# Detect if the answer is out of the span (in which case this feature is labeled with the CLS index).
if not (offsets[token_start_index][0] <= start_char and
offsets[token_end_index][1] >= end_char):
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Otherwise move the token_start_index and token_end_index to the two ends of the answer.
# Note: we could go after the last offset if the answer is the last word (edge case).
while token_start_index < len(offsets) and \
offsets[token_start_index][0] <= start_char:
token_start_index += 1
tokenized_examples["start_positions"].append(
token_start_index - 1)
while offsets[token_end_index][1] >= end_char:
token_end_index -= 1
tokenized_examples["end_positions"].append(token_end_index + 1)
return tokenized_examples
```
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/3333#issuecomment-983457161_ | 247 | add one field "example_id", but I can't see it in the "comput_loss" function
Hi, I add one field **example_id**, but I can't see it in the **comput_loss** function, how can I do this? below is the information of inputs
```
*********************** inputs: {'attention_mask': tensor([[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
...,
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0]], device='cuda:0'), 'end_positions': tensor([ 25, 97, 93, 44, 25, 112, 109, 134], device='cuda:0'), 'input_ids': tensor([[ 101, 2054, 2390, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2106, ..., 0, 0, 0],
...,
[ 101, 2339, 2001, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2003, ..., 0, 0, 0]], device='cuda:0'), 'start_positions': tensor([ 20, 90, 89, 41, 25, 96, 106, 132], device='cuda:0'), 'token_type_ids': tensor([[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
...,
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0]], device='cuda:0')}
```
```
# This function preprocesses a question answering dataset, tokenizing the question and context text
# and finding the right offsets for the answer spans in the tokenized context (to use as labels).
# Adapted from https://github.com/huggingface/transformers/blob/master/examples/pytorch/question-answering/run_qa.py
def prepare_train_dataset_qa(examples, tokenizer, max_seq_length=None):
questions = [q.lstrip() for q in examples["question"]]
max_seq_length = tokenizer.model_max_length
# tokenize both questions and the corresponding context
# if the context length is longer than max_length, we split it to several
# chunks of max_length
tokenized_examples = tokenizer(
questions,
examples["context"],
truncation="only_second",
max_length=max_seq_length,
stride=min(max_seq_length // 2, 128),
return_overflowing_tokens=True,
return_offsets_mapping=True,
padding="max_length"
)
# Since one example might give us several features if it has a long context,
# we need a map from a feature to its corresponding example.
sample_mapping = tokenized_examples.pop("overflow_to_sample_mapping")
# The offset mappings will give us a map from token to character position
# in the original context. This will help us compute the start_positions
# and end_positions to get the final answer string.
offset_mapping = tokenized_examples.pop("offset_mapping")
tokenized_examples["start_positions"] = []
tokenized_examples["end_positions"] = []
tokenized_examples["example_id"] = []
for i, offsets in enumerate(offset_mapping):
input_ids = tokenized_examples["input_ids"][i]
# We will label features not containing the answer the index of the CLS token.
cls_index = input_ids.index(tokenizer.cls_token_id)
sequence_ids = tokenized_examples.sequence_ids(i)
# from the feature idx to sample idx
sample_index = sample_mapping[i]
# get the answer for a feature
answers = examples["answers"][sample_index]
tokenized_examples["example_id"].append(examples["id"][sample_index])
if len(answers["answer_start"]) == 0:
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Start/end character index of the answer in the text.
start_char = answers["answer_start"][0]
end_char = start_char + len(answers["text"][0])
# Start token index of the current span in the text.
token_start_index = 0
while sequence_ids[token_start_index] != 1:
token_start_index += 1
# End token index of the current span in the text.
token_end_index = len(input_ids) - 1
while sequence_ids[token_end_index] != 1:
token_end_index -= 1
# Detect if the answer is out of the span (in which case this feature is labeled with the CLS index).
if not (offsets[token_start_index][0] <= start_char and
offsets[token_end_index][1] >= end_char):
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Otherwise move the token_start_index and token_end_index to the two ends of the answer.
# Note: we could go after the last offset if the answer is the last word (edge case).
while token_start_index < len(offsets) and \
offsets[token_start_index][0] <= start_char:
token_start_index += 1
tokenized_examples["start_positions"].append(
token_start_index - 1)
while offsets[token_end_index][1] >= end_char:
token_end_index -= 1
tokenized_examples["end_positions"].append(token_end_index + 1)
return tokenized_examples
```
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/3333#issuecomment-983457161_
Hi, I print the value, all are set to False, but don't work.
```
********************* training_args: TrainingArguments(
_n_gpu=1,
adafactor=False,
adam_beta1=0.9,
adam_beta2=0.999,
adam_epsilon=1e-08,
dataloader_drop_last=False,
dataloader_num_workers=0,
dataloader_pin_memory=True,
ddp_find_unused_parameters=None,
debug=[],
deepspeed=None,
disable_tqdm=False,
do_eval=False,
do_predict=False,
do_train=True,
eval_accumulation_steps=None,
eval_steps=None,
evaluation_strategy=IntervalStrategy.NO,
fp16=False,
fp16_backend=auto,
fp16_full_eval=False,
fp16_opt_level=O1,
gradient_accumulation_steps=1,
greater_is_better=None,
group_by_length=False,
ignore_data_skip=False,
label_names=None,
label_smoothing_factor=0.0,
learning_rate=5e-05,
length_column_name=length,
load_best_model_at_end=False,
local_rank=-1,
log_level=-1,
log_level_replica=-1,
log_on_each_node=True,
logging_dir=./re_trained_model/runs/Dec01_14-15-08_399b9290604c,
logging_first_step=False,
logging_steps=500,
logging_strategy=IntervalStrategy.STEPS,
lr_scheduler_type=SchedulerType.LINEAR,
max_grad_norm=1.0,
max_steps=-1,
metric_for_best_model=None,
mp_parameters=,
no_cuda=False,
num_train_epochs=3.0,
output_dir=./re_trained_model,
overwrite_output_dir=False,
past_index=-1,
per_device_eval_batch_size=8,
per_device_train_batch_size=8,
prediction_loss_only=False,
push_to_hub=False,
push_to_hub_model_id=re_trained_model,
push_to_hub_organization=None,
push_to_hub_token=None,
remove_unused_columns=False,
report_to=['tensorboard'],
resume_from_checkpoint=None,
run_name=./re_trained_model,
save_on_each_node=False,
save_steps=500,
save_strategy=IntervalStrategy.STEPS,
save_total_limit=None,
seed=42,
sharded_ddp=[],
skip_memory_metrics=True,
tpu_metrics_debug=False,
tpu_num_cores=None,
use_legacy_prediction_loop=False,
warmup_ratio=0.0,
warmup_steps=0,
weight_decay=0.0,
)
```
```
********************* args: Namespace(dataset='squad', max_eval_samples=None, max_length=128, max_train_samples=None, model='google/electra-small-discriminator', remove_unused_columns=False, task='qa')
2021-12-01 14:15:10,048 - WARNING - datasets.builder - Reusing dataset squad (/root/.cache/huggingface/datasets/squad/plain_text/1.0.0/d6ec3ceb99ca480ce37cdd35555d6cb2511d223b9150cce08a837ef62ffea453)
Some weights of the model checkpoint at google/electra-small-discriminator were not used when initializing ElectraForQuestionAnswering: ['discriminator_predictions.dense_prediction.weight', 'discriminator_predictions.dense_prediction.bias', 'discriminator_predictions.dense.weight', 'discriminator_predictions.dense.bias']
- This IS expected if you are initializing ElectraForQuestionAnswering from the checkpoint of a model trained on another task or with another architecture (e.g. initializing a BertForSequenceClassification model from a BertForPreTraining model).
- This IS NOT expected if you are initializing ElectraForQuestionAnswering from the checkpoint of a model that you expect to be exactly identical (initializing a BertForSequenceClassification model from a BertForSequenceClassification model).
Some weights of ElectraForQuestionAnswering were not initialized from the model checkpoint at google/electra-small-discriminator and are newly initialized: ['qa_outputs.bias', 'qa_outputs.weight']
You should probably TRAIN this model on a down-stream task to be able to use it for predictions and inference.
Preprocessing data... (this takes a little bit, should only happen once per dataset)
``` | [
-0.1465506107,
-0.5799238086,
-0.274071902,
0.1202487126,
0.1545111835,
0.0243577175,
0.518656373,
0.1191996783,
0.2118413895,
0.4652202725,
0.3532586992,
0.3118036389,
0.2009701878,
-0.1237443164,
0.3787087202,
0.0022589611,
-0.0379148796,
0.224128589,
0.2628958523,
-0.1642495841,
-0.183089748,
-0.0878601,
-0.218925029,
0.0226238295,
-0.2868743539,
-0.208893016,
0.0530895069,
-0.1255611032,
-0.0868299603,
-0.0424166285,
0.1870988011,
-0.1108928472,
-0.2399868071,
0.199706316,
-0.0001078606,
0.1045567244,
0.1533192098,
-0.0608258732,
-0.0272859689,
-0.1543922424,
-0.2217087746,
-0.2605636418,
-0.0360182188,
-0.3241762221,
-0.0498114787,
0.1234708503,
-0.1091194451,
-0.3235187232,
0.0795222297,
0.2246320397,
0.2008235306,
-0.1087317839,
0.1274075657,
-0.0000119107,
0.2504412234,
0.0550517887,
0.0921009034,
-0.2274120599,
-0.2579442263,
-0.0577589981,
0.4909737408,
0.4897180498,
0.3399707079,
-0.1195267215,
0.0124899726,
0.2712908983,
0.2939135432,
-0.1918281168,
0.0852965564,
-0.1495800912,
-0.2388664931,
-0.0874888822,
-0.0544351488,
0.1071323305,
0.1659787893,
-0.7740447521,
-0.2672750056,
-0.0151067004,
0.0079791779,
0.0360805653,
0.2593709826,
0.0940451175,
-0.3109925091,
0.4295270443,
0.0709782764,
0.2999991179,
0.0571777672,
0.1011035219,
0.1933594793,
-0.0105596436,
-0.0151527831,
0.3169314563,
0.3318520784,
0.0747607127,
-0.3491978645,
0.0346172415,
-0.0871883109,
-0.4820678234,
-0.1534082443,
-0.2185961902,
0.3559982777,
0.1997032613,
0.2166689783,
0.4776992798,
-0.3577488065,
0.2326746285,
-0.1546849757,
0.0067086807,
0.0488918722,
-0.0942224711,
0.0168210939,
-0.24926579,
-0.0476013683,
0.2071011811,
0.0075180656,
0.1878779531,
0.0598699823,
0.2564727068,
-0.3819018602,
-0.0711564273,
-0.0432543829,
-0.1892253906,
0.2999635935,
0.3324873149,
0.1197899133,
0.1190501079,
0.1769399643,
0.0945180506,
-0.0657149106,
-0.0995360166,
-0.3446668088,
0.3517922759,
-0.0081031248,
-0.0312071461,
0.229830265,
0.1371507198,
0.2383444458,
-0.1337921917,
0.2179640383,
-0.0860011131,
0.1516470909,
-0.1166076884,
0.4551613331,
0.2630287409,
-0.1637019664,
0.0134522561,
0.2568819225,
-0.2118529975,
0.0206137281,
0.1065059751,
-0.2221775204,
-0.0247162618,
-0.2702471018,
0.1769711524,
0.3174368739,
-0.0659502074,
0.1990665644,
0.4340725839,
0.0306911245,
-0.1820393652,
0.1591261029,
0.2752167881,
-0.4124224484,
-0.2381926775,
0.3947790563,
-0.1607451886,
-0.1401053369,
-0.141785562,
-0.2604891956,
0.1221225783,
0.1909762174,
-0.0842138007,
-0.0475603007,
-0.0282747149,
0.0637511387,
0.3494353592,
0.8107308149,
-0.3744962215,
-0.2795385122,
-0.0711329207,
-0.2432867438,
-0.3155626655,
0.3230952919,
0.1094321683,
-0.0346453451,
0.350897491,
0.3981733024,
-0.2225913256,
-0.058040645,
-0.0951701924,
-0.157324627,
0.1440274864,
0.2992529869,
-0.0405863933,
-0.032645002,
0.229087308,
0.1560370028,
-0.046294827,
0.17617625,
0.0521368645,
0.0390579067,
-0.0493439548,
0.4451039433,
-0.3515290916,
-0.0790179148,
-0.3894447684,
0.0563286431,
0.0327258483,
0.105559513,
-0.1064713523,
0.2491143793,
-0.3219109476,
-0.156619519,
-0.1171730235,
0.2654783726,
0.1461737156,
0.2600670159,
0.1603276432,
-0.1780048907,
-0.2101499736,
-0.1849679351,
0.2014156878,
0.1087631285,
-0.1175370067,
-0.0605794899,
0.108806923,
-0.2590561807,
-0.3654018342,
-0.2350620776,
0.1987408698,
0.5106500983,
-0.070552513,
0.1146341339,
0.2025002986,
0.0576812178,
-0.1379923075,
-0.0804836676,
0.247410059,
0.238827616,
0.1963553131,
-0.092208907,
-0.0410733148,
-0.0662460774,
-0.0322654434,
0.0253206398,
0.1264405251,
0.1489983648,
-0.1023368761,
-0.0388093181,
-0.0366984978,
0.0363957137,
0.1048706323,
-0.0081957802,
-0.2124927044,
-0.0292192549,
-0.02710413,
-0.1880142242,
-0.3396835029,
-0.6948493719,
0.2774123251,
0.3753505945,
0.2250716835,
0.0887846723,
-0.1543403417,
0.1054508239,
0.3096154928,
0.1741134822,
-0.0688997656,
0.2824614942,
0.2431523055,
-0.0006570601,
-0.1929287612,
-0.1459147185,
0.0332997181,
-0.1217951626,
0.0161180329,
-0.0088923573,
0.0553401932,
0.0460408255,
-0.1220655963,
-0.0741402805,
0.1098109409,
-0.0425804891,
0.1530542374,
-0.1819598377,
0.0745958239,
-0.2065949589,
-0.1701564938,
-0.0176640656,
-0.1878846288,
0.4881099164,
-0.2357124686,
0.108563371,
0.0685065687,
-0.0312240217,
0.1133598611,
0.3010867834,
0.3493435383,
0.0032124056,
0.4118727446,
-0.5014944673,
0.0754358545,
0.0803720653,
0.1347717345,
-0.323775351,
0.2229703069,
0.0899232253,
0.1199859902,
0.163475275,
0.1981916577,
-0.5742998719,
-0.0457441844,
-0.1828483492,
-0.1081298813,
-0.2321815789,
0.3006094992,
-0.4940449893,
-0.4426555336,
0.0445017219,
-0.1192849278,
-0.1709110141,
-0.0220641308,
-0.109759666,
0.0612727888,
-0.3739386499,
-0.4167387784,
-0.2716556787,
-0.2535756528,
0.3533881605,
0.1404966414,
0.1286893487,
-0.0205969587,
0.1233990565,
0.0022618512,
0.390040338,
0.3684777617,
-0.2363982499,
-0.3898071647,
0.2644088864,
-0.4682346284,
-0.2753450274,
0.1190086529,
-0.2428461909,
0.3059527278,
-0.0551914908,
-0.0429992825,
-0.1326035708,
0.1728417873,
-0.1390807033,
-0.1978014708,
0.250329107,
0.5233486295,
-0.126338914,
-0.1503020376,
-0.1779243052,
-0.4433750212,
0.1343268305,
0.3658438623,
0.2038741261,
-0.3099858463,
0.2279687226,
-0.0131086791,
0.5472481847,
0.0150866266,
-0.5900515914,
0.1056579351,
-0.359562546,
-0.0319627449,
0.2820094228,
-0.389461875,
-0.0417868495,
0.1235161722,
0.0056943861,
-0.1467068046,
-0.4287927449,
-0.2567921579,
-0.0766892061,
0.0805044174,
-0.5425463319,
0.0181248747,
-0.1387891471,
0.0470177382,
-0.0577977635,
-0.1137975454,
-0.0473476201,
-0.4487857223,
0.063312687,
0.202952534,
0.1094742194,
-0.0809170008,
-0.2151966393,
0.1158836111,
-0.7709780931,
-0.2294573784,
0.215963006,
-0.0320693888,
0.0548228025,
-0.0477108881,
-0.189836666,
-0.0463781394,
0.1821792424,
0.410623461,
-0.2682365179,
-0.3791665137,
0.3391001523,
-0.1767856777,
0.0223890692,
0.0805483386,
-0.1487300098,
-0.0903297812,
0.3995429277,
0.2576504648,
-0.2826338112,
0.1514883488,
0.4574837983,
0.017806109,
-0.1433134526,
0.1389861107,
-0.407248795,
0.0921383128,
-0.2252016515,
0.0633089542,
0.1053115055,
0.2456721961,
0.3113098741,
-0.1568218917,
-0.0494199097,
-0.2709628344,
0.0991963446,
0.1898778826,
0.1328711063,
0.4358684421,
-0.1194885224,
0.2090510279,
0.2822466791,
-0.2177584022,
-0.0802924186,
0.0966512933,
-0.0369397104,
0.1970512718,
-0.0768765062,
0.4107712507,
0.0712356344,
0.0180286653,
0.2601253986,
-0.154182598,
0.3188805878,
-0.0546550639,
0.2812376618,
0.3012107313,
0.0483411327,
0.2414410412,
-0.1765300333,
0.059619505,
-0.0958827287,
-0.1697422415,
0.3887868226,
-0.0318235382,
-0.0489952751,
0.2164387703,
0.1120499,
0.9591209292,
-0.1575283259,
-0.2097389996,
0.010101567,
-0.0759112835,
0.246584028,
-0.5863705277,
0.2355298549,
0.0334868543,
-0.4988214374,
-0.0105420575,
-0.0881967917,
0.044007767,
0.0403953083,
-0.2475857139,
-0.1044775248,
-0.0600731559,
0.1326296777,
-0.2600261271,
0.1042772382,
0.5729569793,
-0.0145095149,
0.1290891767,
0.1071654633,
0.2161007077,
-0.1032794267,
0.0142463967,
0.043840792,
-0.3111595213,
-0.1651967317,
-0.0577949472,
-0.2926233709,
-0.3724552989,
0.0779147893,
-0.2301871926,
-0.3371114433,
-0.1382795125,
0.2469748259,
0.5074902773,
-0.0876613185,
-0.0729399547,
0.0783381015,
0.0328867845,
-0.0796208233,
-0.4444467127,
-0.0946100354,
0.136764273,
-0.2206638753,
-0.4410490096,
0.5772229433,
0.1857408732,
-0.1705364585,
-0.1899651885,
0.2871699929,
-0.0383694619,
0.129547134,
0.010304179,
0.3733169138,
-0.0053962925,
-0.3326701522,
0.1627595574,
0.0596208572,
-0.3349808156,
0.0551164001,
0.1015768796,
-0.059681952,
-0.1164965257,
0.2710948884,
0.1846642196,
0.1101191193,
0.153046295,
-0.3730731905,
-0.1292416602,
-0.2302129269,
-0.4134919643,
0.2596665025,
0.163496092,
-0.2700080276,
0.0250566378,
-0.2863544226,
0.0119892936,
0.113785319,
-0.1277266592,
0.4657014906,
-0.2920139432,
-0.1193426102,
-0.6847845912,
0.084660612,
0.0923071578,
0.2418773472,
-0.0910454616,
0.3085485995,
-0.1139217988,
0.4207445979,
-0.383130312,
-0.1236377805,
-0.095174022,
0.0261606872,
-0.1424012929,
0.1253938079,
0.1052283198,
0.0120824063,
0.2795462012,
0.1791643053,
0.0852370411,
-0.2446636856,
0.0206562113,
0.0673325509,
-0.012857384,
0.1886310875,
-0.143785134,
0.1827834398,
-0.0340192355,
0.0805035532,
0.0635812059,
-0.2142196745,
0.0720005184,
0.5170302391,
0.001559679,
0.3738712668,
0.2085385472,
-0.3807269931,
0.1647592634,
0.1969907582,
0.0629086643,
0.0796953812,
0.0315674543,
-0.1974562407,
-0.2258631438,
-0.1494313031,
-0.1706695855,
-0.1023815945,
0.1594367772,
-0.0842019618,
0.0489150174,
-0.2541467547,
-0.2469742894,
-0.1922261417,
-0.1377260685,
0.40273875,
-0.166105479,
0.3383505344,
-0.3222352266,
0.2194848508,
0.1384897381,
-0.2340570539,
0.403858006,
0.166889742,
0.0815947056,
0.1041587368,
0.1086277813,
0.0006812685,
-0.2021349519,
-0.3151361346,
-0.0145554813,
-0.2254245728,
-0.1450472027,
-0.0520639792,
-0.0086746113,
0.4659986198,
0.1152551845,
0.0580728427,
-0.0347970277,
0.312800169,
0.0291871708,
-0.2569917738,
-0.1333462149,
0.2735691965,
0.2254725844,
0.1482052356,
-0.2445322424,
-0.2448830605,
0.2093804926,
0.014736101,
0.259924233,
0.1151595265,
0.0879939124,
0.0245630685,
-0.0748739988,
0.1329130828,
-0.1615413874,
0.0272864364,
0.0083126044,
-0.4961479604,
0.4540582597,
0.0197916124,
0.3592812121,
0.0094491504,
-0.1366972327,
0.3265838325,
-0.1150179505,
0.2745340765,
0.291270107,
0.0145206889,
-0.0274460278,
0.1890660375,
-0.2468674332,
0.0273045711,
0.1485269219,
0.1980179101,
-0.1725937724,
0.1242914498,
0.2728430331,
0.1988863945,
-0.4539814591,
-0.0438922457,
0.0097732535,
0.3897031248,
0.1741363257,
-0.1174858138,
0.2516443431,
-0.2438939661,
0.0432756506,
0.1727748215,
0.2546553612,
-0.2248341441,
0.0309997182,
-0.323312968,
-0.2758279741,
-0.1908756346,
-0.0567898154,
-0.2546935976,
0.1486682147,
-0.0284461807,
-0.1154245734,
0.0920688063,
-0.1310922801,
0.0961888134,
-0.054417517,
0.2366347015,
-0.3606317639,
0.0298498701,
-0.248138845,
-0.2751562297,
-0.1471740454,
0.2483398765,
0.1515551805,
-0.1386951655,
0.0534884296,
0.318356812,
0.041216258,
-0.1101803705,
0.3300687373,
-0.6668446064,
0.1768387854,
0.358001858,
-0.3746558726,
0.0164402295,
-0.2233828157,
-0.0211764351,
0.422237277,
0.2050825655,
0.0705492049,
0.1290493906,
0.1250909418,
-0.2997333407,
0.2207965404,
-0.1879361719,
0.4197393656,
0.3551920354,
-0.1828262061,
0.4042818248,
-0.3066492677,
0.2137334645,
0.3719344437,
0.1562607288,
-0.2533104122,
0.1702733338,
0.3084546328,
0.2727311552,
0.1707512289,
-0.2394830585,
-0.0878330916,
0.243628487,
0.1005045399,
-0.6387304068,
0.119463332,
0.4051736891,
-0.0529855117,
0.1463834643,
0.1399642229,
0.0316314958,
0.1003136411,
0.1197821647,
0.0374338143,
-0.2836812735,
0.4032078683,
-0.0077173966,
-0.2011442333,
-0.3372564614,
0.251296401,
-0.0798204318,
0.4243530333,
-0.6292932034,
-0.1902176589,
0.2446600497,
-0.2690584362,
-0.1225004941,
0.4333189726,
-0.1099830344,
0.0640582889,
0.068426989,
-0.0047873608,
0.2105076462,
0.3445385098,
-0.1536096781,
-0.2668265104
] |
https://github.com/huggingface/datasets/issues/3353 | add one field "example_id", but I can't see it in the "comput_loss" function | Hmmm, it might be because the default data collator removes all the fields with `string` type:
https://github.com/huggingface/transformers/blob/4c0dd199c8305903564c2edeae23d294edd4b321/src/transformers/data/data_collator.py#L107-L112
I guess you also need a custom data collator that doesn't remove them. | Hi, I add one field **example_id**, but I can't see it in the **comput_loss** function, how can I do this? below is the information of inputs
```
*********************** inputs: {'attention_mask': tensor([[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
...,
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0]], device='cuda:0'), 'end_positions': tensor([ 25, 97, 93, 44, 25, 112, 109, 134], device='cuda:0'), 'input_ids': tensor([[ 101, 2054, 2390, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2106, ..., 0, 0, 0],
...,
[ 101, 2339, 2001, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2003, ..., 0, 0, 0]], device='cuda:0'), 'start_positions': tensor([ 20, 90, 89, 41, 25, 96, 106, 132], device='cuda:0'), 'token_type_ids': tensor([[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
...,
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0]], device='cuda:0')}
```
```
# This function preprocesses a question answering dataset, tokenizing the question and context text
# and finding the right offsets for the answer spans in the tokenized context (to use as labels).
# Adapted from https://github.com/huggingface/transformers/blob/master/examples/pytorch/question-answering/run_qa.py
def prepare_train_dataset_qa(examples, tokenizer, max_seq_length=None):
questions = [q.lstrip() for q in examples["question"]]
max_seq_length = tokenizer.model_max_length
# tokenize both questions and the corresponding context
# if the context length is longer than max_length, we split it to several
# chunks of max_length
tokenized_examples = tokenizer(
questions,
examples["context"],
truncation="only_second",
max_length=max_seq_length,
stride=min(max_seq_length // 2, 128),
return_overflowing_tokens=True,
return_offsets_mapping=True,
padding="max_length"
)
# Since one example might give us several features if it has a long context,
# we need a map from a feature to its corresponding example.
sample_mapping = tokenized_examples.pop("overflow_to_sample_mapping")
# The offset mappings will give us a map from token to character position
# in the original context. This will help us compute the start_positions
# and end_positions to get the final answer string.
offset_mapping = tokenized_examples.pop("offset_mapping")
tokenized_examples["start_positions"] = []
tokenized_examples["end_positions"] = []
tokenized_examples["example_id"] = []
for i, offsets in enumerate(offset_mapping):
input_ids = tokenized_examples["input_ids"][i]
# We will label features not containing the answer the index of the CLS token.
cls_index = input_ids.index(tokenizer.cls_token_id)
sequence_ids = tokenized_examples.sequence_ids(i)
# from the feature idx to sample idx
sample_index = sample_mapping[i]
# get the answer for a feature
answers = examples["answers"][sample_index]
tokenized_examples["example_id"].append(examples["id"][sample_index])
if len(answers["answer_start"]) == 0:
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Start/end character index of the answer in the text.
start_char = answers["answer_start"][0]
end_char = start_char + len(answers["text"][0])
# Start token index of the current span in the text.
token_start_index = 0
while sequence_ids[token_start_index] != 1:
token_start_index += 1
# End token index of the current span in the text.
token_end_index = len(input_ids) - 1
while sequence_ids[token_end_index] != 1:
token_end_index -= 1
# Detect if the answer is out of the span (in which case this feature is labeled with the CLS index).
if not (offsets[token_start_index][0] <= start_char and
offsets[token_end_index][1] >= end_char):
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Otherwise move the token_start_index and token_end_index to the two ends of the answer.
# Note: we could go after the last offset if the answer is the last word (edge case).
while token_start_index < len(offsets) and \
offsets[token_start_index][0] <= start_char:
token_start_index += 1
tokenized_examples["start_positions"].append(
token_start_index - 1)
while offsets[token_end_index][1] >= end_char:
token_end_index -= 1
tokenized_examples["end_positions"].append(token_end_index + 1)
return tokenized_examples
```
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/3333#issuecomment-983457161_ | 30 | add one field "example_id", but I can't see it in the "comput_loss" function
Hi, I add one field **example_id**, but I can't see it in the **comput_loss** function, how can I do this? below is the information of inputs
```
*********************** inputs: {'attention_mask': tensor([[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
...,
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0]], device='cuda:0'), 'end_positions': tensor([ 25, 97, 93, 44, 25, 112, 109, 134], device='cuda:0'), 'input_ids': tensor([[ 101, 2054, 2390, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2106, ..., 0, 0, 0],
...,
[ 101, 2339, 2001, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2003, ..., 0, 0, 0]], device='cuda:0'), 'start_positions': tensor([ 20, 90, 89, 41, 25, 96, 106, 132], device='cuda:0'), 'token_type_ids': tensor([[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
...,
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0]], device='cuda:0')}
```
```
# This function preprocesses a question answering dataset, tokenizing the question and context text
# and finding the right offsets for the answer spans in the tokenized context (to use as labels).
# Adapted from https://github.com/huggingface/transformers/blob/master/examples/pytorch/question-answering/run_qa.py
def prepare_train_dataset_qa(examples, tokenizer, max_seq_length=None):
questions = [q.lstrip() for q in examples["question"]]
max_seq_length = tokenizer.model_max_length
# tokenize both questions and the corresponding context
# if the context length is longer than max_length, we split it to several
# chunks of max_length
tokenized_examples = tokenizer(
questions,
examples["context"],
truncation="only_second",
max_length=max_seq_length,
stride=min(max_seq_length // 2, 128),
return_overflowing_tokens=True,
return_offsets_mapping=True,
padding="max_length"
)
# Since one example might give us several features if it has a long context,
# we need a map from a feature to its corresponding example.
sample_mapping = tokenized_examples.pop("overflow_to_sample_mapping")
# The offset mappings will give us a map from token to character position
# in the original context. This will help us compute the start_positions
# and end_positions to get the final answer string.
offset_mapping = tokenized_examples.pop("offset_mapping")
tokenized_examples["start_positions"] = []
tokenized_examples["end_positions"] = []
tokenized_examples["example_id"] = []
for i, offsets in enumerate(offset_mapping):
input_ids = tokenized_examples["input_ids"][i]
# We will label features not containing the answer the index of the CLS token.
cls_index = input_ids.index(tokenizer.cls_token_id)
sequence_ids = tokenized_examples.sequence_ids(i)
# from the feature idx to sample idx
sample_index = sample_mapping[i]
# get the answer for a feature
answers = examples["answers"][sample_index]
tokenized_examples["example_id"].append(examples["id"][sample_index])
if len(answers["answer_start"]) == 0:
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Start/end character index of the answer in the text.
start_char = answers["answer_start"][0]
end_char = start_char + len(answers["text"][0])
# Start token index of the current span in the text.
token_start_index = 0
while sequence_ids[token_start_index] != 1:
token_start_index += 1
# End token index of the current span in the text.
token_end_index = len(input_ids) - 1
while sequence_ids[token_end_index] != 1:
token_end_index -= 1
# Detect if the answer is out of the span (in which case this feature is labeled with the CLS index).
if not (offsets[token_start_index][0] <= start_char and
offsets[token_end_index][1] >= end_char):
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Otherwise move the token_start_index and token_end_index to the two ends of the answer.
# Note: we could go after the last offset if the answer is the last word (edge case).
while token_start_index < len(offsets) and \
offsets[token_start_index][0] <= start_char:
token_start_index += 1
tokenized_examples["start_positions"].append(
token_start_index - 1)
while offsets[token_end_index][1] >= end_char:
token_end_index -= 1
tokenized_examples["end_positions"].append(token_end_index + 1)
return tokenized_examples
```
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/3333#issuecomment-983457161_
Hmmm, it might be because the default data collator removes all the fields with `string` type:
https://github.com/huggingface/transformers/blob/4c0dd199c8305903564c2edeae23d294edd4b321/src/transformers/data/data_collator.py#L107-L112
I guess you also need a custom data collator that doesn't remove them. | [
-0.1465506107,
-0.5799238086,
-0.274071902,
0.1202487126,
0.1545111835,
0.0243577175,
0.518656373,
0.1191996783,
0.2118413895,
0.4652202725,
0.3532586992,
0.3118036389,
0.2009701878,
-0.1237443164,
0.3787087202,
0.0022589611,
-0.0379148796,
0.224128589,
0.2628958523,
-0.1642495841,
-0.183089748,
-0.0878601,
-0.218925029,
0.0226238295,
-0.2868743539,
-0.208893016,
0.0530895069,
-0.1255611032,
-0.0868299603,
-0.0424166285,
0.1870988011,
-0.1108928472,
-0.2399868071,
0.199706316,
-0.0001078606,
0.1045567244,
0.1533192098,
-0.0608258732,
-0.0272859689,
-0.1543922424,
-0.2217087746,
-0.2605636418,
-0.0360182188,
-0.3241762221,
-0.0498114787,
0.1234708503,
-0.1091194451,
-0.3235187232,
0.0795222297,
0.2246320397,
0.2008235306,
-0.1087317839,
0.1274075657,
-0.0000119107,
0.2504412234,
0.0550517887,
0.0921009034,
-0.2274120599,
-0.2579442263,
-0.0577589981,
0.4909737408,
0.4897180498,
0.3399707079,
-0.1195267215,
0.0124899726,
0.2712908983,
0.2939135432,
-0.1918281168,
0.0852965564,
-0.1495800912,
-0.2388664931,
-0.0874888822,
-0.0544351488,
0.1071323305,
0.1659787893,
-0.7740447521,
-0.2672750056,
-0.0151067004,
0.0079791779,
0.0360805653,
0.2593709826,
0.0940451175,
-0.3109925091,
0.4295270443,
0.0709782764,
0.2999991179,
0.0571777672,
0.1011035219,
0.1933594793,
-0.0105596436,
-0.0151527831,
0.3169314563,
0.3318520784,
0.0747607127,
-0.3491978645,
0.0346172415,
-0.0871883109,
-0.4820678234,
-0.1534082443,
-0.2185961902,
0.3559982777,
0.1997032613,
0.2166689783,
0.4776992798,
-0.3577488065,
0.2326746285,
-0.1546849757,
0.0067086807,
0.0488918722,
-0.0942224711,
0.0168210939,
-0.24926579,
-0.0476013683,
0.2071011811,
0.0075180656,
0.1878779531,
0.0598699823,
0.2564727068,
-0.3819018602,
-0.0711564273,
-0.0432543829,
-0.1892253906,
0.2999635935,
0.3324873149,
0.1197899133,
0.1190501079,
0.1769399643,
0.0945180506,
-0.0657149106,
-0.0995360166,
-0.3446668088,
0.3517922759,
-0.0081031248,
-0.0312071461,
0.229830265,
0.1371507198,
0.2383444458,
-0.1337921917,
0.2179640383,
-0.0860011131,
0.1516470909,
-0.1166076884,
0.4551613331,
0.2630287409,
-0.1637019664,
0.0134522561,
0.2568819225,
-0.2118529975,
0.0206137281,
0.1065059751,
-0.2221775204,
-0.0247162618,
-0.2702471018,
0.1769711524,
0.3174368739,
-0.0659502074,
0.1990665644,
0.4340725839,
0.0306911245,
-0.1820393652,
0.1591261029,
0.2752167881,
-0.4124224484,
-0.2381926775,
0.3947790563,
-0.1607451886,
-0.1401053369,
-0.141785562,
-0.2604891956,
0.1221225783,
0.1909762174,
-0.0842138007,
-0.0475603007,
-0.0282747149,
0.0637511387,
0.3494353592,
0.8107308149,
-0.3744962215,
-0.2795385122,
-0.0711329207,
-0.2432867438,
-0.3155626655,
0.3230952919,
0.1094321683,
-0.0346453451,
0.350897491,
0.3981733024,
-0.2225913256,
-0.058040645,
-0.0951701924,
-0.157324627,
0.1440274864,
0.2992529869,
-0.0405863933,
-0.032645002,
0.229087308,
0.1560370028,
-0.046294827,
0.17617625,
0.0521368645,
0.0390579067,
-0.0493439548,
0.4451039433,
-0.3515290916,
-0.0790179148,
-0.3894447684,
0.0563286431,
0.0327258483,
0.105559513,
-0.1064713523,
0.2491143793,
-0.3219109476,
-0.156619519,
-0.1171730235,
0.2654783726,
0.1461737156,
0.2600670159,
0.1603276432,
-0.1780048907,
-0.2101499736,
-0.1849679351,
0.2014156878,
0.1087631285,
-0.1175370067,
-0.0605794899,
0.108806923,
-0.2590561807,
-0.3654018342,
-0.2350620776,
0.1987408698,
0.5106500983,
-0.070552513,
0.1146341339,
0.2025002986,
0.0576812178,
-0.1379923075,
-0.0804836676,
0.247410059,
0.238827616,
0.1963553131,
-0.092208907,
-0.0410733148,
-0.0662460774,
-0.0322654434,
0.0253206398,
0.1264405251,
0.1489983648,
-0.1023368761,
-0.0388093181,
-0.0366984978,
0.0363957137,
0.1048706323,
-0.0081957802,
-0.2124927044,
-0.0292192549,
-0.02710413,
-0.1880142242,
-0.3396835029,
-0.6948493719,
0.2774123251,
0.3753505945,
0.2250716835,
0.0887846723,
-0.1543403417,
0.1054508239,
0.3096154928,
0.1741134822,
-0.0688997656,
0.2824614942,
0.2431523055,
-0.0006570601,
-0.1929287612,
-0.1459147185,
0.0332997181,
-0.1217951626,
0.0161180329,
-0.0088923573,
0.0553401932,
0.0460408255,
-0.1220655963,
-0.0741402805,
0.1098109409,
-0.0425804891,
0.1530542374,
-0.1819598377,
0.0745958239,
-0.2065949589,
-0.1701564938,
-0.0176640656,
-0.1878846288,
0.4881099164,
-0.2357124686,
0.108563371,
0.0685065687,
-0.0312240217,
0.1133598611,
0.3010867834,
0.3493435383,
0.0032124056,
0.4118727446,
-0.5014944673,
0.0754358545,
0.0803720653,
0.1347717345,
-0.323775351,
0.2229703069,
0.0899232253,
0.1199859902,
0.163475275,
0.1981916577,
-0.5742998719,
-0.0457441844,
-0.1828483492,
-0.1081298813,
-0.2321815789,
0.3006094992,
-0.4940449893,
-0.4426555336,
0.0445017219,
-0.1192849278,
-0.1709110141,
-0.0220641308,
-0.109759666,
0.0612727888,
-0.3739386499,
-0.4167387784,
-0.2716556787,
-0.2535756528,
0.3533881605,
0.1404966414,
0.1286893487,
-0.0205969587,
0.1233990565,
0.0022618512,
0.390040338,
0.3684777617,
-0.2363982499,
-0.3898071647,
0.2644088864,
-0.4682346284,
-0.2753450274,
0.1190086529,
-0.2428461909,
0.3059527278,
-0.0551914908,
-0.0429992825,
-0.1326035708,
0.1728417873,
-0.1390807033,
-0.1978014708,
0.250329107,
0.5233486295,
-0.126338914,
-0.1503020376,
-0.1779243052,
-0.4433750212,
0.1343268305,
0.3658438623,
0.2038741261,
-0.3099858463,
0.2279687226,
-0.0131086791,
0.5472481847,
0.0150866266,
-0.5900515914,
0.1056579351,
-0.359562546,
-0.0319627449,
0.2820094228,
-0.389461875,
-0.0417868495,
0.1235161722,
0.0056943861,
-0.1467068046,
-0.4287927449,
-0.2567921579,
-0.0766892061,
0.0805044174,
-0.5425463319,
0.0181248747,
-0.1387891471,
0.0470177382,
-0.0577977635,
-0.1137975454,
-0.0473476201,
-0.4487857223,
0.063312687,
0.202952534,
0.1094742194,
-0.0809170008,
-0.2151966393,
0.1158836111,
-0.7709780931,
-0.2294573784,
0.215963006,
-0.0320693888,
0.0548228025,
-0.0477108881,
-0.189836666,
-0.0463781394,
0.1821792424,
0.410623461,
-0.2682365179,
-0.3791665137,
0.3391001523,
-0.1767856777,
0.0223890692,
0.0805483386,
-0.1487300098,
-0.0903297812,
0.3995429277,
0.2576504648,
-0.2826338112,
0.1514883488,
0.4574837983,
0.017806109,
-0.1433134526,
0.1389861107,
-0.407248795,
0.0921383128,
-0.2252016515,
0.0633089542,
0.1053115055,
0.2456721961,
0.3113098741,
-0.1568218917,
-0.0494199097,
-0.2709628344,
0.0991963446,
0.1898778826,
0.1328711063,
0.4358684421,
-0.1194885224,
0.2090510279,
0.2822466791,
-0.2177584022,
-0.0802924186,
0.0966512933,
-0.0369397104,
0.1970512718,
-0.0768765062,
0.4107712507,
0.0712356344,
0.0180286653,
0.2601253986,
-0.154182598,
0.3188805878,
-0.0546550639,
0.2812376618,
0.3012107313,
0.0483411327,
0.2414410412,
-0.1765300333,
0.059619505,
-0.0958827287,
-0.1697422415,
0.3887868226,
-0.0318235382,
-0.0489952751,
0.2164387703,
0.1120499,
0.9591209292,
-0.1575283259,
-0.2097389996,
0.010101567,
-0.0759112835,
0.246584028,
-0.5863705277,
0.2355298549,
0.0334868543,
-0.4988214374,
-0.0105420575,
-0.0881967917,
0.044007767,
0.0403953083,
-0.2475857139,
-0.1044775248,
-0.0600731559,
0.1326296777,
-0.2600261271,
0.1042772382,
0.5729569793,
-0.0145095149,
0.1290891767,
0.1071654633,
0.2161007077,
-0.1032794267,
0.0142463967,
0.043840792,
-0.3111595213,
-0.1651967317,
-0.0577949472,
-0.2926233709,
-0.3724552989,
0.0779147893,
-0.2301871926,
-0.3371114433,
-0.1382795125,
0.2469748259,
0.5074902773,
-0.0876613185,
-0.0729399547,
0.0783381015,
0.0328867845,
-0.0796208233,
-0.4444467127,
-0.0946100354,
0.136764273,
-0.2206638753,
-0.4410490096,
0.5772229433,
0.1857408732,
-0.1705364585,
-0.1899651885,
0.2871699929,
-0.0383694619,
0.129547134,
0.010304179,
0.3733169138,
-0.0053962925,
-0.3326701522,
0.1627595574,
0.0596208572,
-0.3349808156,
0.0551164001,
0.1015768796,
-0.059681952,
-0.1164965257,
0.2710948884,
0.1846642196,
0.1101191193,
0.153046295,
-0.3730731905,
-0.1292416602,
-0.2302129269,
-0.4134919643,
0.2596665025,
0.163496092,
-0.2700080276,
0.0250566378,
-0.2863544226,
0.0119892936,
0.113785319,
-0.1277266592,
0.4657014906,
-0.2920139432,
-0.1193426102,
-0.6847845912,
0.084660612,
0.0923071578,
0.2418773472,
-0.0910454616,
0.3085485995,
-0.1139217988,
0.4207445979,
-0.383130312,
-0.1236377805,
-0.095174022,
0.0261606872,
-0.1424012929,
0.1253938079,
0.1052283198,
0.0120824063,
0.2795462012,
0.1791643053,
0.0852370411,
-0.2446636856,
0.0206562113,
0.0673325509,
-0.012857384,
0.1886310875,
-0.143785134,
0.1827834398,
-0.0340192355,
0.0805035532,
0.0635812059,
-0.2142196745,
0.0720005184,
0.5170302391,
0.001559679,
0.3738712668,
0.2085385472,
-0.3807269931,
0.1647592634,
0.1969907582,
0.0629086643,
0.0796953812,
0.0315674543,
-0.1974562407,
-0.2258631438,
-0.1494313031,
-0.1706695855,
-0.1023815945,
0.1594367772,
-0.0842019618,
0.0489150174,
-0.2541467547,
-0.2469742894,
-0.1922261417,
-0.1377260685,
0.40273875,
-0.166105479,
0.3383505344,
-0.3222352266,
0.2194848508,
0.1384897381,
-0.2340570539,
0.403858006,
0.166889742,
0.0815947056,
0.1041587368,
0.1086277813,
0.0006812685,
-0.2021349519,
-0.3151361346,
-0.0145554813,
-0.2254245728,
-0.1450472027,
-0.0520639792,
-0.0086746113,
0.4659986198,
0.1152551845,
0.0580728427,
-0.0347970277,
0.312800169,
0.0291871708,
-0.2569917738,
-0.1333462149,
0.2735691965,
0.2254725844,
0.1482052356,
-0.2445322424,
-0.2448830605,
0.2093804926,
0.014736101,
0.259924233,
0.1151595265,
0.0879939124,
0.0245630685,
-0.0748739988,
0.1329130828,
-0.1615413874,
0.0272864364,
0.0083126044,
-0.4961479604,
0.4540582597,
0.0197916124,
0.3592812121,
0.0094491504,
-0.1366972327,
0.3265838325,
-0.1150179505,
0.2745340765,
0.291270107,
0.0145206889,
-0.0274460278,
0.1890660375,
-0.2468674332,
0.0273045711,
0.1485269219,
0.1980179101,
-0.1725937724,
0.1242914498,
0.2728430331,
0.1988863945,
-0.4539814591,
-0.0438922457,
0.0097732535,
0.3897031248,
0.1741363257,
-0.1174858138,
0.2516443431,
-0.2438939661,
0.0432756506,
0.1727748215,
0.2546553612,
-0.2248341441,
0.0309997182,
-0.323312968,
-0.2758279741,
-0.1908756346,
-0.0567898154,
-0.2546935976,
0.1486682147,
-0.0284461807,
-0.1154245734,
0.0920688063,
-0.1310922801,
0.0961888134,
-0.054417517,
0.2366347015,
-0.3606317639,
0.0298498701,
-0.248138845,
-0.2751562297,
-0.1471740454,
0.2483398765,
0.1515551805,
-0.1386951655,
0.0534884296,
0.318356812,
0.041216258,
-0.1101803705,
0.3300687373,
-0.6668446064,
0.1768387854,
0.358001858,
-0.3746558726,
0.0164402295,
-0.2233828157,
-0.0211764351,
0.422237277,
0.2050825655,
0.0705492049,
0.1290493906,
0.1250909418,
-0.2997333407,
0.2207965404,
-0.1879361719,
0.4197393656,
0.3551920354,
-0.1828262061,
0.4042818248,
-0.3066492677,
0.2137334645,
0.3719344437,
0.1562607288,
-0.2533104122,
0.1702733338,
0.3084546328,
0.2727311552,
0.1707512289,
-0.2394830585,
-0.0878330916,
0.243628487,
0.1005045399,
-0.6387304068,
0.119463332,
0.4051736891,
-0.0529855117,
0.1463834643,
0.1399642229,
0.0316314958,
0.1003136411,
0.1197821647,
0.0374338143,
-0.2836812735,
0.4032078683,
-0.0077173966,
-0.2011442333,
-0.3372564614,
0.251296401,
-0.0798204318,
0.4243530333,
-0.6292932034,
-0.1902176589,
0.2446600497,
-0.2690584362,
-0.1225004941,
0.4333189726,
-0.1099830344,
0.0640582889,
0.068426989,
-0.0047873608,
0.2105076462,
0.3445385098,
-0.1536096781,
-0.2668265104
] |
https://github.com/huggingface/datasets/issues/3353 | add one field "example_id", but I can't see it in the "comput_loss" function | I overwrite **get_train_dataloader**, and remove **_remove_unused_columns**, but it doesn't work.
```
def get_train_dataloader(self) -> DataLoader:
"""
Returns the training :class:`~torch.utils.data.DataLoader`.
Will use no sampler if :obj:`self.train_dataset` does not implement :obj:`__len__`, a random sampler (adapted
to distributed training if necessary) otherwise.
Subclass and override this method if you want to inject some custom behavior.
"""
if self.train_dataset is None:
raise ValueError("Trainer: training requires a train_dataset.")
train_dataset = self.train_dataset
# if is_datasets_available() and isinstance(train_dataset, datasets.Dataset):
# train_dataset = self._remove_unused_columns(train_dataset, description="training")
if isinstance(train_dataset, torch.utils.data.IterableDataset):
if self.args.world_size > 1:
train_dataset = IterableDatasetShard(
train_dataset,
batch_size=self.args.train_batch_size,
drop_last=self.args.dataloader_drop_last,
num_processes=self.args.world_size,
process_index=self.args.process_index,
)
return DataLoader(
train_dataset,
batch_size=self.args.train_batch_size,
collate_fn=self.data_collator,
num_workers=self.args.dataloader_num_workers,
pin_memory=self.args.dataloader_pin_memory,
)
train_sampler = self._get_train_sampler()
return DataLoader(
train_dataset,
batch_size=self.args.train_batch_size,
sampler=train_sampler,
collate_fn=self.data_collator,
drop_last=self.args.dataloader_drop_last,
num_workers=self.args.dataloader_num_workers,
pin_memory=self.args.dataloader_pin_memory,
)
``` | Hi, I add one field **example_id**, but I can't see it in the **comput_loss** function, how can I do this? below is the information of inputs
```
*********************** inputs: {'attention_mask': tensor([[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
...,
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0]], device='cuda:0'), 'end_positions': tensor([ 25, 97, 93, 44, 25, 112, 109, 134], device='cuda:0'), 'input_ids': tensor([[ 101, 2054, 2390, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2106, ..., 0, 0, 0],
...,
[ 101, 2339, 2001, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2003, ..., 0, 0, 0]], device='cuda:0'), 'start_positions': tensor([ 20, 90, 89, 41, 25, 96, 106, 132], device='cuda:0'), 'token_type_ids': tensor([[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
...,
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0]], device='cuda:0')}
```
```
# This function preprocesses a question answering dataset, tokenizing the question and context text
# and finding the right offsets for the answer spans in the tokenized context (to use as labels).
# Adapted from https://github.com/huggingface/transformers/blob/master/examples/pytorch/question-answering/run_qa.py
def prepare_train_dataset_qa(examples, tokenizer, max_seq_length=None):
questions = [q.lstrip() for q in examples["question"]]
max_seq_length = tokenizer.model_max_length
# tokenize both questions and the corresponding context
# if the context length is longer than max_length, we split it to several
# chunks of max_length
tokenized_examples = tokenizer(
questions,
examples["context"],
truncation="only_second",
max_length=max_seq_length,
stride=min(max_seq_length // 2, 128),
return_overflowing_tokens=True,
return_offsets_mapping=True,
padding="max_length"
)
# Since one example might give us several features if it has a long context,
# we need a map from a feature to its corresponding example.
sample_mapping = tokenized_examples.pop("overflow_to_sample_mapping")
# The offset mappings will give us a map from token to character position
# in the original context. This will help us compute the start_positions
# and end_positions to get the final answer string.
offset_mapping = tokenized_examples.pop("offset_mapping")
tokenized_examples["start_positions"] = []
tokenized_examples["end_positions"] = []
tokenized_examples["example_id"] = []
for i, offsets in enumerate(offset_mapping):
input_ids = tokenized_examples["input_ids"][i]
# We will label features not containing the answer the index of the CLS token.
cls_index = input_ids.index(tokenizer.cls_token_id)
sequence_ids = tokenized_examples.sequence_ids(i)
# from the feature idx to sample idx
sample_index = sample_mapping[i]
# get the answer for a feature
answers = examples["answers"][sample_index]
tokenized_examples["example_id"].append(examples["id"][sample_index])
if len(answers["answer_start"]) == 0:
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Start/end character index of the answer in the text.
start_char = answers["answer_start"][0]
end_char = start_char + len(answers["text"][0])
# Start token index of the current span in the text.
token_start_index = 0
while sequence_ids[token_start_index] != 1:
token_start_index += 1
# End token index of the current span in the text.
token_end_index = len(input_ids) - 1
while sequence_ids[token_end_index] != 1:
token_end_index -= 1
# Detect if the answer is out of the span (in which case this feature is labeled with the CLS index).
if not (offsets[token_start_index][0] <= start_char and
offsets[token_end_index][1] >= end_char):
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Otherwise move the token_start_index and token_end_index to the two ends of the answer.
# Note: we could go after the last offset if the answer is the last word (edge case).
while token_start_index < len(offsets) and \
offsets[token_start_index][0] <= start_char:
token_start_index += 1
tokenized_examples["start_positions"].append(
token_start_index - 1)
while offsets[token_end_index][1] >= end_char:
token_end_index -= 1
tokenized_examples["end_positions"].append(token_end_index + 1)
return tokenized_examples
```
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/3333#issuecomment-983457161_ | 116 | add one field "example_id", but I can't see it in the "comput_loss" function
Hi, I add one field **example_id**, but I can't see it in the **comput_loss** function, how can I do this? below is the information of inputs
```
*********************** inputs: {'attention_mask': tensor([[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
...,
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0]], device='cuda:0'), 'end_positions': tensor([ 25, 97, 93, 44, 25, 112, 109, 134], device='cuda:0'), 'input_ids': tensor([[ 101, 2054, 2390, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2106, ..., 0, 0, 0],
...,
[ 101, 2339, 2001, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2003, ..., 0, 0, 0]], device='cuda:0'), 'start_positions': tensor([ 20, 90, 89, 41, 25, 96, 106, 132], device='cuda:0'), 'token_type_ids': tensor([[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
...,
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0]], device='cuda:0')}
```
```
# This function preprocesses a question answering dataset, tokenizing the question and context text
# and finding the right offsets for the answer spans in the tokenized context (to use as labels).
# Adapted from https://github.com/huggingface/transformers/blob/master/examples/pytorch/question-answering/run_qa.py
def prepare_train_dataset_qa(examples, tokenizer, max_seq_length=None):
questions = [q.lstrip() for q in examples["question"]]
max_seq_length = tokenizer.model_max_length
# tokenize both questions and the corresponding context
# if the context length is longer than max_length, we split it to several
# chunks of max_length
tokenized_examples = tokenizer(
questions,
examples["context"],
truncation="only_second",
max_length=max_seq_length,
stride=min(max_seq_length // 2, 128),
return_overflowing_tokens=True,
return_offsets_mapping=True,
padding="max_length"
)
# Since one example might give us several features if it has a long context,
# we need a map from a feature to its corresponding example.
sample_mapping = tokenized_examples.pop("overflow_to_sample_mapping")
# The offset mappings will give us a map from token to character position
# in the original context. This will help us compute the start_positions
# and end_positions to get the final answer string.
offset_mapping = tokenized_examples.pop("offset_mapping")
tokenized_examples["start_positions"] = []
tokenized_examples["end_positions"] = []
tokenized_examples["example_id"] = []
for i, offsets in enumerate(offset_mapping):
input_ids = tokenized_examples["input_ids"][i]
# We will label features not containing the answer the index of the CLS token.
cls_index = input_ids.index(tokenizer.cls_token_id)
sequence_ids = tokenized_examples.sequence_ids(i)
# from the feature idx to sample idx
sample_index = sample_mapping[i]
# get the answer for a feature
answers = examples["answers"][sample_index]
tokenized_examples["example_id"].append(examples["id"][sample_index])
if len(answers["answer_start"]) == 0:
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Start/end character index of the answer in the text.
start_char = answers["answer_start"][0]
end_char = start_char + len(answers["text"][0])
# Start token index of the current span in the text.
token_start_index = 0
while sequence_ids[token_start_index] != 1:
token_start_index += 1
# End token index of the current span in the text.
token_end_index = len(input_ids) - 1
while sequence_ids[token_end_index] != 1:
token_end_index -= 1
# Detect if the answer is out of the span (in which case this feature is labeled with the CLS index).
if not (offsets[token_start_index][0] <= start_char and
offsets[token_end_index][1] >= end_char):
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Otherwise move the token_start_index and token_end_index to the two ends of the answer.
# Note: we could go after the last offset if the answer is the last word (edge case).
while token_start_index < len(offsets) and \
offsets[token_start_index][0] <= start_char:
token_start_index += 1
tokenized_examples["start_positions"].append(
token_start_index - 1)
while offsets[token_end_index][1] >= end_char:
token_end_index -= 1
tokenized_examples["end_positions"].append(token_end_index + 1)
return tokenized_examples
```
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/3333#issuecomment-983457161_
I overwrite **get_train_dataloader**, and remove **_remove_unused_columns**, but it doesn't work.
```
def get_train_dataloader(self) -> DataLoader:
"""
Returns the training :class:`~torch.utils.data.DataLoader`.
Will use no sampler if :obj:`self.train_dataset` does not implement :obj:`__len__`, a random sampler (adapted
to distributed training if necessary) otherwise.
Subclass and override this method if you want to inject some custom behavior.
"""
if self.train_dataset is None:
raise ValueError("Trainer: training requires a train_dataset.")
train_dataset = self.train_dataset
# if is_datasets_available() and isinstance(train_dataset, datasets.Dataset):
# train_dataset = self._remove_unused_columns(train_dataset, description="training")
if isinstance(train_dataset, torch.utils.data.IterableDataset):
if self.args.world_size > 1:
train_dataset = IterableDatasetShard(
train_dataset,
batch_size=self.args.train_batch_size,
drop_last=self.args.dataloader_drop_last,
num_processes=self.args.world_size,
process_index=self.args.process_index,
)
return DataLoader(
train_dataset,
batch_size=self.args.train_batch_size,
collate_fn=self.data_collator,
num_workers=self.args.dataloader_num_workers,
pin_memory=self.args.dataloader_pin_memory,
)
train_sampler = self._get_train_sampler()
return DataLoader(
train_dataset,
batch_size=self.args.train_batch_size,
sampler=train_sampler,
collate_fn=self.data_collator,
drop_last=self.args.dataloader_drop_last,
num_workers=self.args.dataloader_num_workers,
pin_memory=self.args.dataloader_pin_memory,
)
``` | [
-0.1465506107,
-0.5799238086,
-0.274071902,
0.1202487126,
0.1545111835,
0.0243577175,
0.518656373,
0.1191996783,
0.2118413895,
0.4652202725,
0.3532586992,
0.3118036389,
0.2009701878,
-0.1237443164,
0.3787087202,
0.0022589611,
-0.0379148796,
0.224128589,
0.2628958523,
-0.1642495841,
-0.183089748,
-0.0878601,
-0.218925029,
0.0226238295,
-0.2868743539,
-0.208893016,
0.0530895069,
-0.1255611032,
-0.0868299603,
-0.0424166285,
0.1870988011,
-0.1108928472,
-0.2399868071,
0.199706316,
-0.0001078606,
0.1045567244,
0.1533192098,
-0.0608258732,
-0.0272859689,
-0.1543922424,
-0.2217087746,
-0.2605636418,
-0.0360182188,
-0.3241762221,
-0.0498114787,
0.1234708503,
-0.1091194451,
-0.3235187232,
0.0795222297,
0.2246320397,
0.2008235306,
-0.1087317839,
0.1274075657,
-0.0000119107,
0.2504412234,
0.0550517887,
0.0921009034,
-0.2274120599,
-0.2579442263,
-0.0577589981,
0.4909737408,
0.4897180498,
0.3399707079,
-0.1195267215,
0.0124899726,
0.2712908983,
0.2939135432,
-0.1918281168,
0.0852965564,
-0.1495800912,
-0.2388664931,
-0.0874888822,
-0.0544351488,
0.1071323305,
0.1659787893,
-0.7740447521,
-0.2672750056,
-0.0151067004,
0.0079791779,
0.0360805653,
0.2593709826,
0.0940451175,
-0.3109925091,
0.4295270443,
0.0709782764,
0.2999991179,
0.0571777672,
0.1011035219,
0.1933594793,
-0.0105596436,
-0.0151527831,
0.3169314563,
0.3318520784,
0.0747607127,
-0.3491978645,
0.0346172415,
-0.0871883109,
-0.4820678234,
-0.1534082443,
-0.2185961902,
0.3559982777,
0.1997032613,
0.2166689783,
0.4776992798,
-0.3577488065,
0.2326746285,
-0.1546849757,
0.0067086807,
0.0488918722,
-0.0942224711,
0.0168210939,
-0.24926579,
-0.0476013683,
0.2071011811,
0.0075180656,
0.1878779531,
0.0598699823,
0.2564727068,
-0.3819018602,
-0.0711564273,
-0.0432543829,
-0.1892253906,
0.2999635935,
0.3324873149,
0.1197899133,
0.1190501079,
0.1769399643,
0.0945180506,
-0.0657149106,
-0.0995360166,
-0.3446668088,
0.3517922759,
-0.0081031248,
-0.0312071461,
0.229830265,
0.1371507198,
0.2383444458,
-0.1337921917,
0.2179640383,
-0.0860011131,
0.1516470909,
-0.1166076884,
0.4551613331,
0.2630287409,
-0.1637019664,
0.0134522561,
0.2568819225,
-0.2118529975,
0.0206137281,
0.1065059751,
-0.2221775204,
-0.0247162618,
-0.2702471018,
0.1769711524,
0.3174368739,
-0.0659502074,
0.1990665644,
0.4340725839,
0.0306911245,
-0.1820393652,
0.1591261029,
0.2752167881,
-0.4124224484,
-0.2381926775,
0.3947790563,
-0.1607451886,
-0.1401053369,
-0.141785562,
-0.2604891956,
0.1221225783,
0.1909762174,
-0.0842138007,
-0.0475603007,
-0.0282747149,
0.0637511387,
0.3494353592,
0.8107308149,
-0.3744962215,
-0.2795385122,
-0.0711329207,
-0.2432867438,
-0.3155626655,
0.3230952919,
0.1094321683,
-0.0346453451,
0.350897491,
0.3981733024,
-0.2225913256,
-0.058040645,
-0.0951701924,
-0.157324627,
0.1440274864,
0.2992529869,
-0.0405863933,
-0.032645002,
0.229087308,
0.1560370028,
-0.046294827,
0.17617625,
0.0521368645,
0.0390579067,
-0.0493439548,
0.4451039433,
-0.3515290916,
-0.0790179148,
-0.3894447684,
0.0563286431,
0.0327258483,
0.105559513,
-0.1064713523,
0.2491143793,
-0.3219109476,
-0.156619519,
-0.1171730235,
0.2654783726,
0.1461737156,
0.2600670159,
0.1603276432,
-0.1780048907,
-0.2101499736,
-0.1849679351,
0.2014156878,
0.1087631285,
-0.1175370067,
-0.0605794899,
0.108806923,
-0.2590561807,
-0.3654018342,
-0.2350620776,
0.1987408698,
0.5106500983,
-0.070552513,
0.1146341339,
0.2025002986,
0.0576812178,
-0.1379923075,
-0.0804836676,
0.247410059,
0.238827616,
0.1963553131,
-0.092208907,
-0.0410733148,
-0.0662460774,
-0.0322654434,
0.0253206398,
0.1264405251,
0.1489983648,
-0.1023368761,
-0.0388093181,
-0.0366984978,
0.0363957137,
0.1048706323,
-0.0081957802,
-0.2124927044,
-0.0292192549,
-0.02710413,
-0.1880142242,
-0.3396835029,
-0.6948493719,
0.2774123251,
0.3753505945,
0.2250716835,
0.0887846723,
-0.1543403417,
0.1054508239,
0.3096154928,
0.1741134822,
-0.0688997656,
0.2824614942,
0.2431523055,
-0.0006570601,
-0.1929287612,
-0.1459147185,
0.0332997181,
-0.1217951626,
0.0161180329,
-0.0088923573,
0.0553401932,
0.0460408255,
-0.1220655963,
-0.0741402805,
0.1098109409,
-0.0425804891,
0.1530542374,
-0.1819598377,
0.0745958239,
-0.2065949589,
-0.1701564938,
-0.0176640656,
-0.1878846288,
0.4881099164,
-0.2357124686,
0.108563371,
0.0685065687,
-0.0312240217,
0.1133598611,
0.3010867834,
0.3493435383,
0.0032124056,
0.4118727446,
-0.5014944673,
0.0754358545,
0.0803720653,
0.1347717345,
-0.323775351,
0.2229703069,
0.0899232253,
0.1199859902,
0.163475275,
0.1981916577,
-0.5742998719,
-0.0457441844,
-0.1828483492,
-0.1081298813,
-0.2321815789,
0.3006094992,
-0.4940449893,
-0.4426555336,
0.0445017219,
-0.1192849278,
-0.1709110141,
-0.0220641308,
-0.109759666,
0.0612727888,
-0.3739386499,
-0.4167387784,
-0.2716556787,
-0.2535756528,
0.3533881605,
0.1404966414,
0.1286893487,
-0.0205969587,
0.1233990565,
0.0022618512,
0.390040338,
0.3684777617,
-0.2363982499,
-0.3898071647,
0.2644088864,
-0.4682346284,
-0.2753450274,
0.1190086529,
-0.2428461909,
0.3059527278,
-0.0551914908,
-0.0429992825,
-0.1326035708,
0.1728417873,
-0.1390807033,
-0.1978014708,
0.250329107,
0.5233486295,
-0.126338914,
-0.1503020376,
-0.1779243052,
-0.4433750212,
0.1343268305,
0.3658438623,
0.2038741261,
-0.3099858463,
0.2279687226,
-0.0131086791,
0.5472481847,
0.0150866266,
-0.5900515914,
0.1056579351,
-0.359562546,
-0.0319627449,
0.2820094228,
-0.389461875,
-0.0417868495,
0.1235161722,
0.0056943861,
-0.1467068046,
-0.4287927449,
-0.2567921579,
-0.0766892061,
0.0805044174,
-0.5425463319,
0.0181248747,
-0.1387891471,
0.0470177382,
-0.0577977635,
-0.1137975454,
-0.0473476201,
-0.4487857223,
0.063312687,
0.202952534,
0.1094742194,
-0.0809170008,
-0.2151966393,
0.1158836111,
-0.7709780931,
-0.2294573784,
0.215963006,
-0.0320693888,
0.0548228025,
-0.0477108881,
-0.189836666,
-0.0463781394,
0.1821792424,
0.410623461,
-0.2682365179,
-0.3791665137,
0.3391001523,
-0.1767856777,
0.0223890692,
0.0805483386,
-0.1487300098,
-0.0903297812,
0.3995429277,
0.2576504648,
-0.2826338112,
0.1514883488,
0.4574837983,
0.017806109,
-0.1433134526,
0.1389861107,
-0.407248795,
0.0921383128,
-0.2252016515,
0.0633089542,
0.1053115055,
0.2456721961,
0.3113098741,
-0.1568218917,
-0.0494199097,
-0.2709628344,
0.0991963446,
0.1898778826,
0.1328711063,
0.4358684421,
-0.1194885224,
0.2090510279,
0.2822466791,
-0.2177584022,
-0.0802924186,
0.0966512933,
-0.0369397104,
0.1970512718,
-0.0768765062,
0.4107712507,
0.0712356344,
0.0180286653,
0.2601253986,
-0.154182598,
0.3188805878,
-0.0546550639,
0.2812376618,
0.3012107313,
0.0483411327,
0.2414410412,
-0.1765300333,
0.059619505,
-0.0958827287,
-0.1697422415,
0.3887868226,
-0.0318235382,
-0.0489952751,
0.2164387703,
0.1120499,
0.9591209292,
-0.1575283259,
-0.2097389996,
0.010101567,
-0.0759112835,
0.246584028,
-0.5863705277,
0.2355298549,
0.0334868543,
-0.4988214374,
-0.0105420575,
-0.0881967917,
0.044007767,
0.0403953083,
-0.2475857139,
-0.1044775248,
-0.0600731559,
0.1326296777,
-0.2600261271,
0.1042772382,
0.5729569793,
-0.0145095149,
0.1290891767,
0.1071654633,
0.2161007077,
-0.1032794267,
0.0142463967,
0.043840792,
-0.3111595213,
-0.1651967317,
-0.0577949472,
-0.2926233709,
-0.3724552989,
0.0779147893,
-0.2301871926,
-0.3371114433,
-0.1382795125,
0.2469748259,
0.5074902773,
-0.0876613185,
-0.0729399547,
0.0783381015,
0.0328867845,
-0.0796208233,
-0.4444467127,
-0.0946100354,
0.136764273,
-0.2206638753,
-0.4410490096,
0.5772229433,
0.1857408732,
-0.1705364585,
-0.1899651885,
0.2871699929,
-0.0383694619,
0.129547134,
0.010304179,
0.3733169138,
-0.0053962925,
-0.3326701522,
0.1627595574,
0.0596208572,
-0.3349808156,
0.0551164001,
0.1015768796,
-0.059681952,
-0.1164965257,
0.2710948884,
0.1846642196,
0.1101191193,
0.153046295,
-0.3730731905,
-0.1292416602,
-0.2302129269,
-0.4134919643,
0.2596665025,
0.163496092,
-0.2700080276,
0.0250566378,
-0.2863544226,
0.0119892936,
0.113785319,
-0.1277266592,
0.4657014906,
-0.2920139432,
-0.1193426102,
-0.6847845912,
0.084660612,
0.0923071578,
0.2418773472,
-0.0910454616,
0.3085485995,
-0.1139217988,
0.4207445979,
-0.383130312,
-0.1236377805,
-0.095174022,
0.0261606872,
-0.1424012929,
0.1253938079,
0.1052283198,
0.0120824063,
0.2795462012,
0.1791643053,
0.0852370411,
-0.2446636856,
0.0206562113,
0.0673325509,
-0.012857384,
0.1886310875,
-0.143785134,
0.1827834398,
-0.0340192355,
0.0805035532,
0.0635812059,
-0.2142196745,
0.0720005184,
0.5170302391,
0.001559679,
0.3738712668,
0.2085385472,
-0.3807269931,
0.1647592634,
0.1969907582,
0.0629086643,
0.0796953812,
0.0315674543,
-0.1974562407,
-0.2258631438,
-0.1494313031,
-0.1706695855,
-0.1023815945,
0.1594367772,
-0.0842019618,
0.0489150174,
-0.2541467547,
-0.2469742894,
-0.1922261417,
-0.1377260685,
0.40273875,
-0.166105479,
0.3383505344,
-0.3222352266,
0.2194848508,
0.1384897381,
-0.2340570539,
0.403858006,
0.166889742,
0.0815947056,
0.1041587368,
0.1086277813,
0.0006812685,
-0.2021349519,
-0.3151361346,
-0.0145554813,
-0.2254245728,
-0.1450472027,
-0.0520639792,
-0.0086746113,
0.4659986198,
0.1152551845,
0.0580728427,
-0.0347970277,
0.312800169,
0.0291871708,
-0.2569917738,
-0.1333462149,
0.2735691965,
0.2254725844,
0.1482052356,
-0.2445322424,
-0.2448830605,
0.2093804926,
0.014736101,
0.259924233,
0.1151595265,
0.0879939124,
0.0245630685,
-0.0748739988,
0.1329130828,
-0.1615413874,
0.0272864364,
0.0083126044,
-0.4961479604,
0.4540582597,
0.0197916124,
0.3592812121,
0.0094491504,
-0.1366972327,
0.3265838325,
-0.1150179505,
0.2745340765,
0.291270107,
0.0145206889,
-0.0274460278,
0.1890660375,
-0.2468674332,
0.0273045711,
0.1485269219,
0.1980179101,
-0.1725937724,
0.1242914498,
0.2728430331,
0.1988863945,
-0.4539814591,
-0.0438922457,
0.0097732535,
0.3897031248,
0.1741363257,
-0.1174858138,
0.2516443431,
-0.2438939661,
0.0432756506,
0.1727748215,
0.2546553612,
-0.2248341441,
0.0309997182,
-0.323312968,
-0.2758279741,
-0.1908756346,
-0.0567898154,
-0.2546935976,
0.1486682147,
-0.0284461807,
-0.1154245734,
0.0920688063,
-0.1310922801,
0.0961888134,
-0.054417517,
0.2366347015,
-0.3606317639,
0.0298498701,
-0.248138845,
-0.2751562297,
-0.1471740454,
0.2483398765,
0.1515551805,
-0.1386951655,
0.0534884296,
0.318356812,
0.041216258,
-0.1101803705,
0.3300687373,
-0.6668446064,
0.1768387854,
0.358001858,
-0.3746558726,
0.0164402295,
-0.2233828157,
-0.0211764351,
0.422237277,
0.2050825655,
0.0705492049,
0.1290493906,
0.1250909418,
-0.2997333407,
0.2207965404,
-0.1879361719,
0.4197393656,
0.3551920354,
-0.1828262061,
0.4042818248,
-0.3066492677,
0.2137334645,
0.3719344437,
0.1562607288,
-0.2533104122,
0.1702733338,
0.3084546328,
0.2727311552,
0.1707512289,
-0.2394830585,
-0.0878330916,
0.243628487,
0.1005045399,
-0.6387304068,
0.119463332,
0.4051736891,
-0.0529855117,
0.1463834643,
0.1399642229,
0.0316314958,
0.1003136411,
0.1197821647,
0.0374338143,
-0.2836812735,
0.4032078683,
-0.0077173966,
-0.2011442333,
-0.3372564614,
0.251296401,
-0.0798204318,
0.4243530333,
-0.6292932034,
-0.1902176589,
0.2446600497,
-0.2690584362,
-0.1225004941,
0.4333189726,
-0.1099830344,
0.0640582889,
0.068426989,
-0.0047873608,
0.2105076462,
0.3445385098,
-0.1536096781,
-0.2668265104
] |
https://github.com/huggingface/datasets/issues/3353 | add one field "example_id", but I can't see it in the "comput_loss" function | Hi, it works now, thank you.
1. **args.remove_unused_columns=False** and **training_args.remove_unused_columns=False**
2. overwrite **get_train_dataloader**, and remove **_remove_unused_columns**
3. add new fields, and can be got in **inputs**. | Hi, I add one field **example_id**, but I can't see it in the **comput_loss** function, how can I do this? below is the information of inputs
```
*********************** inputs: {'attention_mask': tensor([[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
...,
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0]], device='cuda:0'), 'end_positions': tensor([ 25, 97, 93, 44, 25, 112, 109, 134], device='cuda:0'), 'input_ids': tensor([[ 101, 2054, 2390, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2106, ..., 0, 0, 0],
...,
[ 101, 2339, 2001, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2003, ..., 0, 0, 0]], device='cuda:0'), 'start_positions': tensor([ 20, 90, 89, 41, 25, 96, 106, 132], device='cuda:0'), 'token_type_ids': tensor([[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
...,
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0]], device='cuda:0')}
```
```
# This function preprocesses a question answering dataset, tokenizing the question and context text
# and finding the right offsets for the answer spans in the tokenized context (to use as labels).
# Adapted from https://github.com/huggingface/transformers/blob/master/examples/pytorch/question-answering/run_qa.py
def prepare_train_dataset_qa(examples, tokenizer, max_seq_length=None):
questions = [q.lstrip() for q in examples["question"]]
max_seq_length = tokenizer.model_max_length
# tokenize both questions and the corresponding context
# if the context length is longer than max_length, we split it to several
# chunks of max_length
tokenized_examples = tokenizer(
questions,
examples["context"],
truncation="only_second",
max_length=max_seq_length,
stride=min(max_seq_length // 2, 128),
return_overflowing_tokens=True,
return_offsets_mapping=True,
padding="max_length"
)
# Since one example might give us several features if it has a long context,
# we need a map from a feature to its corresponding example.
sample_mapping = tokenized_examples.pop("overflow_to_sample_mapping")
# The offset mappings will give us a map from token to character position
# in the original context. This will help us compute the start_positions
# and end_positions to get the final answer string.
offset_mapping = tokenized_examples.pop("offset_mapping")
tokenized_examples["start_positions"] = []
tokenized_examples["end_positions"] = []
tokenized_examples["example_id"] = []
for i, offsets in enumerate(offset_mapping):
input_ids = tokenized_examples["input_ids"][i]
# We will label features not containing the answer the index of the CLS token.
cls_index = input_ids.index(tokenizer.cls_token_id)
sequence_ids = tokenized_examples.sequence_ids(i)
# from the feature idx to sample idx
sample_index = sample_mapping[i]
# get the answer for a feature
answers = examples["answers"][sample_index]
tokenized_examples["example_id"].append(examples["id"][sample_index])
if len(answers["answer_start"]) == 0:
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Start/end character index of the answer in the text.
start_char = answers["answer_start"][0]
end_char = start_char + len(answers["text"][0])
# Start token index of the current span in the text.
token_start_index = 0
while sequence_ids[token_start_index] != 1:
token_start_index += 1
# End token index of the current span in the text.
token_end_index = len(input_ids) - 1
while sequence_ids[token_end_index] != 1:
token_end_index -= 1
# Detect if the answer is out of the span (in which case this feature is labeled with the CLS index).
if not (offsets[token_start_index][0] <= start_char and
offsets[token_end_index][1] >= end_char):
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Otherwise move the token_start_index and token_end_index to the two ends of the answer.
# Note: we could go after the last offset if the answer is the last word (edge case).
while token_start_index < len(offsets) and \
offsets[token_start_index][0] <= start_char:
token_start_index += 1
tokenized_examples["start_positions"].append(
token_start_index - 1)
while offsets[token_end_index][1] >= end_char:
token_end_index -= 1
tokenized_examples["end_positions"].append(token_end_index + 1)
return tokenized_examples
```
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/3333#issuecomment-983457161_ | 26 | add one field "example_id", but I can't see it in the "comput_loss" function
Hi, I add one field **example_id**, but I can't see it in the **comput_loss** function, how can I do this? below is the information of inputs
```
*********************** inputs: {'attention_mask': tensor([[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
...,
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0]], device='cuda:0'), 'end_positions': tensor([ 25, 97, 93, 44, 25, 112, 109, 134], device='cuda:0'), 'input_ids': tensor([[ 101, 2054, 2390, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2106, ..., 0, 0, 0],
...,
[ 101, 2339, 2001, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2003, ..., 0, 0, 0]], device='cuda:0'), 'start_positions': tensor([ 20, 90, 89, 41, 25, 96, 106, 132], device='cuda:0'), 'token_type_ids': tensor([[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
...,
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0]], device='cuda:0')}
```
```
# This function preprocesses a question answering dataset, tokenizing the question and context text
# and finding the right offsets for the answer spans in the tokenized context (to use as labels).
# Adapted from https://github.com/huggingface/transformers/blob/master/examples/pytorch/question-answering/run_qa.py
def prepare_train_dataset_qa(examples, tokenizer, max_seq_length=None):
questions = [q.lstrip() for q in examples["question"]]
max_seq_length = tokenizer.model_max_length
# tokenize both questions and the corresponding context
# if the context length is longer than max_length, we split it to several
# chunks of max_length
tokenized_examples = tokenizer(
questions,
examples["context"],
truncation="only_second",
max_length=max_seq_length,
stride=min(max_seq_length // 2, 128),
return_overflowing_tokens=True,
return_offsets_mapping=True,
padding="max_length"
)
# Since one example might give us several features if it has a long context,
# we need a map from a feature to its corresponding example.
sample_mapping = tokenized_examples.pop("overflow_to_sample_mapping")
# The offset mappings will give us a map from token to character position
# in the original context. This will help us compute the start_positions
# and end_positions to get the final answer string.
offset_mapping = tokenized_examples.pop("offset_mapping")
tokenized_examples["start_positions"] = []
tokenized_examples["end_positions"] = []
tokenized_examples["example_id"] = []
for i, offsets in enumerate(offset_mapping):
input_ids = tokenized_examples["input_ids"][i]
# We will label features not containing the answer the index of the CLS token.
cls_index = input_ids.index(tokenizer.cls_token_id)
sequence_ids = tokenized_examples.sequence_ids(i)
# from the feature idx to sample idx
sample_index = sample_mapping[i]
# get the answer for a feature
answers = examples["answers"][sample_index]
tokenized_examples["example_id"].append(examples["id"][sample_index])
if len(answers["answer_start"]) == 0:
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Start/end character index of the answer in the text.
start_char = answers["answer_start"][0]
end_char = start_char + len(answers["text"][0])
# Start token index of the current span in the text.
token_start_index = 0
while sequence_ids[token_start_index] != 1:
token_start_index += 1
# End token index of the current span in the text.
token_end_index = len(input_ids) - 1
while sequence_ids[token_end_index] != 1:
token_end_index -= 1
# Detect if the answer is out of the span (in which case this feature is labeled with the CLS index).
if not (offsets[token_start_index][0] <= start_char and
offsets[token_end_index][1] >= end_char):
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Otherwise move the token_start_index and token_end_index to the two ends of the answer.
# Note: we could go after the last offset if the answer is the last word (edge case).
while token_start_index < len(offsets) and \
offsets[token_start_index][0] <= start_char:
token_start_index += 1
tokenized_examples["start_positions"].append(
token_start_index - 1)
while offsets[token_end_index][1] >= end_char:
token_end_index -= 1
tokenized_examples["end_positions"].append(token_end_index + 1)
return tokenized_examples
```
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/3333#issuecomment-983457161_
Hi, it works now, thank you.
1. **args.remove_unused_columns=False** and **training_args.remove_unused_columns=False**
2. overwrite **get_train_dataloader**, and remove **_remove_unused_columns**
3. add new fields, and can be got in **inputs**. | [
-0.1465506107,
-0.5799238086,
-0.274071902,
0.1202487126,
0.1545111835,
0.0243577175,
0.518656373,
0.1191996783,
0.2118413895,
0.4652202725,
0.3532586992,
0.3118036389,
0.2009701878,
-0.1237443164,
0.3787087202,
0.0022589611,
-0.0379148796,
0.224128589,
0.2628958523,
-0.1642495841,
-0.183089748,
-0.0878601,
-0.218925029,
0.0226238295,
-0.2868743539,
-0.208893016,
0.0530895069,
-0.1255611032,
-0.0868299603,
-0.0424166285,
0.1870988011,
-0.1108928472,
-0.2399868071,
0.199706316,
-0.0001078606,
0.1045567244,
0.1533192098,
-0.0608258732,
-0.0272859689,
-0.1543922424,
-0.2217087746,
-0.2605636418,
-0.0360182188,
-0.3241762221,
-0.0498114787,
0.1234708503,
-0.1091194451,
-0.3235187232,
0.0795222297,
0.2246320397,
0.2008235306,
-0.1087317839,
0.1274075657,
-0.0000119107,
0.2504412234,
0.0550517887,
0.0921009034,
-0.2274120599,
-0.2579442263,
-0.0577589981,
0.4909737408,
0.4897180498,
0.3399707079,
-0.1195267215,
0.0124899726,
0.2712908983,
0.2939135432,
-0.1918281168,
0.0852965564,
-0.1495800912,
-0.2388664931,
-0.0874888822,
-0.0544351488,
0.1071323305,
0.1659787893,
-0.7740447521,
-0.2672750056,
-0.0151067004,
0.0079791779,
0.0360805653,
0.2593709826,
0.0940451175,
-0.3109925091,
0.4295270443,
0.0709782764,
0.2999991179,
0.0571777672,
0.1011035219,
0.1933594793,
-0.0105596436,
-0.0151527831,
0.3169314563,
0.3318520784,
0.0747607127,
-0.3491978645,
0.0346172415,
-0.0871883109,
-0.4820678234,
-0.1534082443,
-0.2185961902,
0.3559982777,
0.1997032613,
0.2166689783,
0.4776992798,
-0.3577488065,
0.2326746285,
-0.1546849757,
0.0067086807,
0.0488918722,
-0.0942224711,
0.0168210939,
-0.24926579,
-0.0476013683,
0.2071011811,
0.0075180656,
0.1878779531,
0.0598699823,
0.2564727068,
-0.3819018602,
-0.0711564273,
-0.0432543829,
-0.1892253906,
0.2999635935,
0.3324873149,
0.1197899133,
0.1190501079,
0.1769399643,
0.0945180506,
-0.0657149106,
-0.0995360166,
-0.3446668088,
0.3517922759,
-0.0081031248,
-0.0312071461,
0.229830265,
0.1371507198,
0.2383444458,
-0.1337921917,
0.2179640383,
-0.0860011131,
0.1516470909,
-0.1166076884,
0.4551613331,
0.2630287409,
-0.1637019664,
0.0134522561,
0.2568819225,
-0.2118529975,
0.0206137281,
0.1065059751,
-0.2221775204,
-0.0247162618,
-0.2702471018,
0.1769711524,
0.3174368739,
-0.0659502074,
0.1990665644,
0.4340725839,
0.0306911245,
-0.1820393652,
0.1591261029,
0.2752167881,
-0.4124224484,
-0.2381926775,
0.3947790563,
-0.1607451886,
-0.1401053369,
-0.141785562,
-0.2604891956,
0.1221225783,
0.1909762174,
-0.0842138007,
-0.0475603007,
-0.0282747149,
0.0637511387,
0.3494353592,
0.8107308149,
-0.3744962215,
-0.2795385122,
-0.0711329207,
-0.2432867438,
-0.3155626655,
0.3230952919,
0.1094321683,
-0.0346453451,
0.350897491,
0.3981733024,
-0.2225913256,
-0.058040645,
-0.0951701924,
-0.157324627,
0.1440274864,
0.2992529869,
-0.0405863933,
-0.032645002,
0.229087308,
0.1560370028,
-0.046294827,
0.17617625,
0.0521368645,
0.0390579067,
-0.0493439548,
0.4451039433,
-0.3515290916,
-0.0790179148,
-0.3894447684,
0.0563286431,
0.0327258483,
0.105559513,
-0.1064713523,
0.2491143793,
-0.3219109476,
-0.156619519,
-0.1171730235,
0.2654783726,
0.1461737156,
0.2600670159,
0.1603276432,
-0.1780048907,
-0.2101499736,
-0.1849679351,
0.2014156878,
0.1087631285,
-0.1175370067,
-0.0605794899,
0.108806923,
-0.2590561807,
-0.3654018342,
-0.2350620776,
0.1987408698,
0.5106500983,
-0.070552513,
0.1146341339,
0.2025002986,
0.0576812178,
-0.1379923075,
-0.0804836676,
0.247410059,
0.238827616,
0.1963553131,
-0.092208907,
-0.0410733148,
-0.0662460774,
-0.0322654434,
0.0253206398,
0.1264405251,
0.1489983648,
-0.1023368761,
-0.0388093181,
-0.0366984978,
0.0363957137,
0.1048706323,
-0.0081957802,
-0.2124927044,
-0.0292192549,
-0.02710413,
-0.1880142242,
-0.3396835029,
-0.6948493719,
0.2774123251,
0.3753505945,
0.2250716835,
0.0887846723,
-0.1543403417,
0.1054508239,
0.3096154928,
0.1741134822,
-0.0688997656,
0.2824614942,
0.2431523055,
-0.0006570601,
-0.1929287612,
-0.1459147185,
0.0332997181,
-0.1217951626,
0.0161180329,
-0.0088923573,
0.0553401932,
0.0460408255,
-0.1220655963,
-0.0741402805,
0.1098109409,
-0.0425804891,
0.1530542374,
-0.1819598377,
0.0745958239,
-0.2065949589,
-0.1701564938,
-0.0176640656,
-0.1878846288,
0.4881099164,
-0.2357124686,
0.108563371,
0.0685065687,
-0.0312240217,
0.1133598611,
0.3010867834,
0.3493435383,
0.0032124056,
0.4118727446,
-0.5014944673,
0.0754358545,
0.0803720653,
0.1347717345,
-0.323775351,
0.2229703069,
0.0899232253,
0.1199859902,
0.163475275,
0.1981916577,
-0.5742998719,
-0.0457441844,
-0.1828483492,
-0.1081298813,
-0.2321815789,
0.3006094992,
-0.4940449893,
-0.4426555336,
0.0445017219,
-0.1192849278,
-0.1709110141,
-0.0220641308,
-0.109759666,
0.0612727888,
-0.3739386499,
-0.4167387784,
-0.2716556787,
-0.2535756528,
0.3533881605,
0.1404966414,
0.1286893487,
-0.0205969587,
0.1233990565,
0.0022618512,
0.390040338,
0.3684777617,
-0.2363982499,
-0.3898071647,
0.2644088864,
-0.4682346284,
-0.2753450274,
0.1190086529,
-0.2428461909,
0.3059527278,
-0.0551914908,
-0.0429992825,
-0.1326035708,
0.1728417873,
-0.1390807033,
-0.1978014708,
0.250329107,
0.5233486295,
-0.126338914,
-0.1503020376,
-0.1779243052,
-0.4433750212,
0.1343268305,
0.3658438623,
0.2038741261,
-0.3099858463,
0.2279687226,
-0.0131086791,
0.5472481847,
0.0150866266,
-0.5900515914,
0.1056579351,
-0.359562546,
-0.0319627449,
0.2820094228,
-0.389461875,
-0.0417868495,
0.1235161722,
0.0056943861,
-0.1467068046,
-0.4287927449,
-0.2567921579,
-0.0766892061,
0.0805044174,
-0.5425463319,
0.0181248747,
-0.1387891471,
0.0470177382,
-0.0577977635,
-0.1137975454,
-0.0473476201,
-0.4487857223,
0.063312687,
0.202952534,
0.1094742194,
-0.0809170008,
-0.2151966393,
0.1158836111,
-0.7709780931,
-0.2294573784,
0.215963006,
-0.0320693888,
0.0548228025,
-0.0477108881,
-0.189836666,
-0.0463781394,
0.1821792424,
0.410623461,
-0.2682365179,
-0.3791665137,
0.3391001523,
-0.1767856777,
0.0223890692,
0.0805483386,
-0.1487300098,
-0.0903297812,
0.3995429277,
0.2576504648,
-0.2826338112,
0.1514883488,
0.4574837983,
0.017806109,
-0.1433134526,
0.1389861107,
-0.407248795,
0.0921383128,
-0.2252016515,
0.0633089542,
0.1053115055,
0.2456721961,
0.3113098741,
-0.1568218917,
-0.0494199097,
-0.2709628344,
0.0991963446,
0.1898778826,
0.1328711063,
0.4358684421,
-0.1194885224,
0.2090510279,
0.2822466791,
-0.2177584022,
-0.0802924186,
0.0966512933,
-0.0369397104,
0.1970512718,
-0.0768765062,
0.4107712507,
0.0712356344,
0.0180286653,
0.2601253986,
-0.154182598,
0.3188805878,
-0.0546550639,
0.2812376618,
0.3012107313,
0.0483411327,
0.2414410412,
-0.1765300333,
0.059619505,
-0.0958827287,
-0.1697422415,
0.3887868226,
-0.0318235382,
-0.0489952751,
0.2164387703,
0.1120499,
0.9591209292,
-0.1575283259,
-0.2097389996,
0.010101567,
-0.0759112835,
0.246584028,
-0.5863705277,
0.2355298549,
0.0334868543,
-0.4988214374,
-0.0105420575,
-0.0881967917,
0.044007767,
0.0403953083,
-0.2475857139,
-0.1044775248,
-0.0600731559,
0.1326296777,
-0.2600261271,
0.1042772382,
0.5729569793,
-0.0145095149,
0.1290891767,
0.1071654633,
0.2161007077,
-0.1032794267,
0.0142463967,
0.043840792,
-0.3111595213,
-0.1651967317,
-0.0577949472,
-0.2926233709,
-0.3724552989,
0.0779147893,
-0.2301871926,
-0.3371114433,
-0.1382795125,
0.2469748259,
0.5074902773,
-0.0876613185,
-0.0729399547,
0.0783381015,
0.0328867845,
-0.0796208233,
-0.4444467127,
-0.0946100354,
0.136764273,
-0.2206638753,
-0.4410490096,
0.5772229433,
0.1857408732,
-0.1705364585,
-0.1899651885,
0.2871699929,
-0.0383694619,
0.129547134,
0.010304179,
0.3733169138,
-0.0053962925,
-0.3326701522,
0.1627595574,
0.0596208572,
-0.3349808156,
0.0551164001,
0.1015768796,
-0.059681952,
-0.1164965257,
0.2710948884,
0.1846642196,
0.1101191193,
0.153046295,
-0.3730731905,
-0.1292416602,
-0.2302129269,
-0.4134919643,
0.2596665025,
0.163496092,
-0.2700080276,
0.0250566378,
-0.2863544226,
0.0119892936,
0.113785319,
-0.1277266592,
0.4657014906,
-0.2920139432,
-0.1193426102,
-0.6847845912,
0.084660612,
0.0923071578,
0.2418773472,
-0.0910454616,
0.3085485995,
-0.1139217988,
0.4207445979,
-0.383130312,
-0.1236377805,
-0.095174022,
0.0261606872,
-0.1424012929,
0.1253938079,
0.1052283198,
0.0120824063,
0.2795462012,
0.1791643053,
0.0852370411,
-0.2446636856,
0.0206562113,
0.0673325509,
-0.012857384,
0.1886310875,
-0.143785134,
0.1827834398,
-0.0340192355,
0.0805035532,
0.0635812059,
-0.2142196745,
0.0720005184,
0.5170302391,
0.001559679,
0.3738712668,
0.2085385472,
-0.3807269931,
0.1647592634,
0.1969907582,
0.0629086643,
0.0796953812,
0.0315674543,
-0.1974562407,
-0.2258631438,
-0.1494313031,
-0.1706695855,
-0.1023815945,
0.1594367772,
-0.0842019618,
0.0489150174,
-0.2541467547,
-0.2469742894,
-0.1922261417,
-0.1377260685,
0.40273875,
-0.166105479,
0.3383505344,
-0.3222352266,
0.2194848508,
0.1384897381,
-0.2340570539,
0.403858006,
0.166889742,
0.0815947056,
0.1041587368,
0.1086277813,
0.0006812685,
-0.2021349519,
-0.3151361346,
-0.0145554813,
-0.2254245728,
-0.1450472027,
-0.0520639792,
-0.0086746113,
0.4659986198,
0.1152551845,
0.0580728427,
-0.0347970277,
0.312800169,
0.0291871708,
-0.2569917738,
-0.1333462149,
0.2735691965,
0.2254725844,
0.1482052356,
-0.2445322424,
-0.2448830605,
0.2093804926,
0.014736101,
0.259924233,
0.1151595265,
0.0879939124,
0.0245630685,
-0.0748739988,
0.1329130828,
-0.1615413874,
0.0272864364,
0.0083126044,
-0.4961479604,
0.4540582597,
0.0197916124,
0.3592812121,
0.0094491504,
-0.1366972327,
0.3265838325,
-0.1150179505,
0.2745340765,
0.291270107,
0.0145206889,
-0.0274460278,
0.1890660375,
-0.2468674332,
0.0273045711,
0.1485269219,
0.1980179101,
-0.1725937724,
0.1242914498,
0.2728430331,
0.1988863945,
-0.4539814591,
-0.0438922457,
0.0097732535,
0.3897031248,
0.1741363257,
-0.1174858138,
0.2516443431,
-0.2438939661,
0.0432756506,
0.1727748215,
0.2546553612,
-0.2248341441,
0.0309997182,
-0.323312968,
-0.2758279741,
-0.1908756346,
-0.0567898154,
-0.2546935976,
0.1486682147,
-0.0284461807,
-0.1154245734,
0.0920688063,
-0.1310922801,
0.0961888134,
-0.054417517,
0.2366347015,
-0.3606317639,
0.0298498701,
-0.248138845,
-0.2751562297,
-0.1471740454,
0.2483398765,
0.1515551805,
-0.1386951655,
0.0534884296,
0.318356812,
0.041216258,
-0.1101803705,
0.3300687373,
-0.6668446064,
0.1768387854,
0.358001858,
-0.3746558726,
0.0164402295,
-0.2233828157,
-0.0211764351,
0.422237277,
0.2050825655,
0.0705492049,
0.1290493906,
0.1250909418,
-0.2997333407,
0.2207965404,
-0.1879361719,
0.4197393656,
0.3551920354,
-0.1828262061,
0.4042818248,
-0.3066492677,
0.2137334645,
0.3719344437,
0.1562607288,
-0.2533104122,
0.1702733338,
0.3084546328,
0.2727311552,
0.1707512289,
-0.2394830585,
-0.0878330916,
0.243628487,
0.1005045399,
-0.6387304068,
0.119463332,
0.4051736891,
-0.0529855117,
0.1463834643,
0.1399642229,
0.0316314958,
0.1003136411,
0.1197821647,
0.0374338143,
-0.2836812735,
0.4032078683,
-0.0077173966,
-0.2011442333,
-0.3372564614,
0.251296401,
-0.0798204318,
0.4243530333,
-0.6292932034,
-0.1902176589,
0.2446600497,
-0.2690584362,
-0.1225004941,
0.4333189726,
-0.1099830344,
0.0640582889,
0.068426989,
-0.0047873608,
0.2105076462,
0.3445385098,
-0.1536096781,
-0.2668265104
] |
https://github.com/huggingface/datasets/issues/3346 | Failed to convert `string` with pyarrow for QED since 1.15.0 | Actually, re-opening this issue cause the error persists
```python
>>> load_dataset("qed")
Downloading and preparing dataset qed/qed (download: 13.43 MiB, generated: 9.70 MiB, post-processed: Unknown size, total: 23.14 MiB) to /home/victor_huggingface_co/.cache/huggingface/datasets/qed/qed/1.0.0/47d8b6f033393aa520a8402d4baf2d6bdc1b2fbde3dc156e595d2ef34caf7d75...
100%|███████████████████████████████████████████████████████████████████████| 2/2 [00:00<00:00, 2228.64it/s]
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/victor_huggingface_co/miniconda3/envs/promptsource/lib/python3.7/site-packages/datasets/load.py", line 1669, in load_dataset
use_auth_token=use_auth_token,
File "/home/victor_huggingface_co/miniconda3/envs/promptsource/lib/python3.7/site-packages/datasets/builder.py", line 594, in download_and_prepare
dl_manager=dl_manager, verify_infos=verify_infos, **download_and_prepare_kwargs
File "/home/victor_huggingface_co/miniconda3/envs/promptsource/lib/python3.7/site-packages/datasets/builder.py", line 681, in _download_and_prepare
self._prepare_split(split_generator, **prepare_split_kwargs)
File "/home/victor_huggingface_co/miniconda3/envs/promptsource/lib/python3.7/site-packages/datasets/builder.py", line 1083, in _prepare_split
num_examples, num_bytes = writer.finalize()
File "/home/victor_huggingface_co/miniconda3/envs/promptsource/lib/python3.7/site-packages/datasets/arrow_writer.py", line 468, in finalize
self.write_examples_on_file()
File "/home/victor_huggingface_co/miniconda3/envs/promptsource/lib/python3.7/site-packages/datasets/arrow_writer.py", line 339, in write_examples_on_file
pa_array = pa.array(typed_sequence)
File "pyarrow/array.pxi", line 229, in pyarrow.lib.array
File "pyarrow/array.pxi", line 110, in pyarrow.lib._handle_arrow_array_protocol
File "/home/victor_huggingface_co/miniconda3/envs/promptsource/lib/python3.7/site-packages/datasets/arrow_writer.py", line 125, in __arrow_array__
out = pa.array(cast_to_python_objects(self.data, only_1d_for_numpy=True), type=type)
File "pyarrow/array.pxi", line 315, in pyarrow.lib.array
File "pyarrow/array.pxi", line 39, in pyarrow.lib._sequence_to_array
File "pyarrow/error.pxi", line 143, in pyarrow.lib.pyarrow_internal_check_status
File "pyarrow/error.pxi", line 99, in pyarrow.lib.check_status
pyarrow.lib.ArrowInvalid: Could not convert 'in' with type str: tried to convert to boolean
```
Environment (datasets and pyarrow):
```bash
(promptsource) victor_huggingface_co@victor-dev:~/promptsource$ datasets-cli env
Copy-and-paste the text below in your GitHub issue.
- `datasets` version: 1.16.1
- Platform: Linux-5.0.0-1020-gcp-x86_64-with-debian-buster-sid
- Python version: 3.7.11
- PyArrow version: 6.0.1
```
```bash
(promptsource) victor_huggingface_co@victor-dev:~/promptsource$ pip show pyarrow
Name: pyarrow
Version: 6.0.1
Summary: Python library for Apache Arrow
Home-page: https://arrow.apache.org/
Author:
Author-email:
License: Apache License, Version 2.0
Location: /home/victor_huggingface_co/miniconda3/envs/promptsource/lib/python3.7/site-packages
Requires: numpy
Required-by: streamlit, datasets
``` | ## Describe the bug
Loading QED was fine until 1.15.0.
related: bigscience-workshop/promptsource#659, bigscience-workshop/promptsource#670
Not sure where the root cause is, but here are some candidates:
- #3158
- #3120
- #3196
- #2891
## Steps to reproduce the bug
```python
load_dataset("qed")
```
## Expected results
Loading completed.
## Actual results
```shell
ArrowInvalid: Could not convert in with type str: tried to convert to boolean
Traceback:
File "/Users/s0s0cr3/Library/Python/3.9/lib/python/site-packages/streamlit/script_runner.py", line 354, in _run_script
exec(code, module.__dict__)
File "/Users/s0s0cr3/Documents/GitHub/promptsource/promptsource/app.py", line 260, in <module>
dataset = get_dataset(dataset_key, str(conf_option.name) if conf_option else None)
File "/Users/s0s0cr3/Library/Python/3.9/lib/python/site-packages/streamlit/caching.py", line 543, in wrapped_func
return get_or_create_cached_value()
File "/Users/s0s0cr3/Library/Python/3.9/lib/python/site-packages/streamlit/caching.py", line 527, in get_or_create_cached_value
return_value = func(*args, **kwargs)
File "/Users/s0s0cr3/Documents/GitHub/promptsource/promptsource/utils.py", line 49, in get_dataset
builder_instance.download_and_prepare()
File "/Users/s0s0cr3/Library/Python/3.9/lib/python/site-packages/datasets/builder.py", line 607, in download_and_prepare
self._download_and_prepare(
File "/Users/s0s0cr3/Library/Python/3.9/lib/python/site-packages/datasets/builder.py", line 697, in _download_and_prepare
self._prepare_split(split_generator, **prepare_split_kwargs)
File "/Users/s0s0cr3/Library/Python/3.9/lib/python/site-packages/datasets/builder.py", line 1106, in _prepare_split
num_examples, num_bytes = writer.finalize()
File "/Users/s0s0cr3/Library/Python/3.9/lib/python/site-packages/datasets/arrow_writer.py", line 456, in finalize
self.write_examples_on_file()
File "/Users/s0s0cr3/Library/Python/3.9/lib/python/site-packages/datasets/arrow_writer.py", line 325, in write_examples_on_file
pa_array = pa.array(typed_sequence)
File "pyarrow/array.pxi", line 222, in pyarrow.lib.array
File "pyarrow/array.pxi", line 110, in pyarrow.lib._handle_arrow_array_protocol
File "/Users/s0s0cr3/Library/Python/3.9/lib/python/site-packages/datasets/arrow_writer.py", line 121, in __arrow_array__
out = pa.array(cast_to_python_objects(self.data, only_1d_for_numpy=True), type=type)
File "pyarrow/array.pxi", line 305, in pyarrow.lib.array
File "pyarrow/array.pxi", line 39, in pyarrow.lib._sequence_to_array
File "pyarrow/error.pxi", line 122, in pyarrow.lib.pyarrow_internal_check_status
File "pyarrow/error.pxi", line 84, in pyarrow.lib.check_status
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.15.0, 1.16.1
- Platform: macOS 1.15.7 or above
- Python version: 3.7.12 and 3.9
- PyArrow version: 3.0.0, 5.0.0, 6.0.1
| 222 | Failed to convert `string` with pyarrow for QED since 1.15.0
## Describe the bug
Loading QED was fine until 1.15.0.
related: bigscience-workshop/promptsource#659, bigscience-workshop/promptsource#670
Not sure where the root cause is, but here are some candidates:
- #3158
- #3120
- #3196
- #2891
## Steps to reproduce the bug
```python
load_dataset("qed")
```
## Expected results
Loading completed.
## Actual results
```shell
ArrowInvalid: Could not convert in with type str: tried to convert to boolean
Traceback:
File "/Users/s0s0cr3/Library/Python/3.9/lib/python/site-packages/streamlit/script_runner.py", line 354, in _run_script
exec(code, module.__dict__)
File "/Users/s0s0cr3/Documents/GitHub/promptsource/promptsource/app.py", line 260, in <module>
dataset = get_dataset(dataset_key, str(conf_option.name) if conf_option else None)
File "/Users/s0s0cr3/Library/Python/3.9/lib/python/site-packages/streamlit/caching.py", line 543, in wrapped_func
return get_or_create_cached_value()
File "/Users/s0s0cr3/Library/Python/3.9/lib/python/site-packages/streamlit/caching.py", line 527, in get_or_create_cached_value
return_value = func(*args, **kwargs)
File "/Users/s0s0cr3/Documents/GitHub/promptsource/promptsource/utils.py", line 49, in get_dataset
builder_instance.download_and_prepare()
File "/Users/s0s0cr3/Library/Python/3.9/lib/python/site-packages/datasets/builder.py", line 607, in download_and_prepare
self._download_and_prepare(
File "/Users/s0s0cr3/Library/Python/3.9/lib/python/site-packages/datasets/builder.py", line 697, in _download_and_prepare
self._prepare_split(split_generator, **prepare_split_kwargs)
File "/Users/s0s0cr3/Library/Python/3.9/lib/python/site-packages/datasets/builder.py", line 1106, in _prepare_split
num_examples, num_bytes = writer.finalize()
File "/Users/s0s0cr3/Library/Python/3.9/lib/python/site-packages/datasets/arrow_writer.py", line 456, in finalize
self.write_examples_on_file()
File "/Users/s0s0cr3/Library/Python/3.9/lib/python/site-packages/datasets/arrow_writer.py", line 325, in write_examples_on_file
pa_array = pa.array(typed_sequence)
File "pyarrow/array.pxi", line 222, in pyarrow.lib.array
File "pyarrow/array.pxi", line 110, in pyarrow.lib._handle_arrow_array_protocol
File "/Users/s0s0cr3/Library/Python/3.9/lib/python/site-packages/datasets/arrow_writer.py", line 121, in __arrow_array__
out = pa.array(cast_to_python_objects(self.data, only_1d_for_numpy=True), type=type)
File "pyarrow/array.pxi", line 305, in pyarrow.lib.array
File "pyarrow/array.pxi", line 39, in pyarrow.lib._sequence_to_array
File "pyarrow/error.pxi", line 122, in pyarrow.lib.pyarrow_internal_check_status
File "pyarrow/error.pxi", line 84, in pyarrow.lib.check_status
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.15.0, 1.16.1
- Platform: macOS 1.15.7 or above
- Python version: 3.7.12 and 3.9
- PyArrow version: 3.0.0, 5.0.0, 6.0.1
Actually, re-opening this issue cause the error persists
```python
>>> load_dataset("qed")
Downloading and preparing dataset qed/qed (download: 13.43 MiB, generated: 9.70 MiB, post-processed: Unknown size, total: 23.14 MiB) to /home/victor_huggingface_co/.cache/huggingface/datasets/qed/qed/1.0.0/47d8b6f033393aa520a8402d4baf2d6bdc1b2fbde3dc156e595d2ef34caf7d75...
100%|███████████████████████████████████████████████████████████████████████| 2/2 [00:00<00:00, 2228.64it/s]
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/victor_huggingface_co/miniconda3/envs/promptsource/lib/python3.7/site-packages/datasets/load.py", line 1669, in load_dataset
use_auth_token=use_auth_token,
File "/home/victor_huggingface_co/miniconda3/envs/promptsource/lib/python3.7/site-packages/datasets/builder.py", line 594, in download_and_prepare
dl_manager=dl_manager, verify_infos=verify_infos, **download_and_prepare_kwargs
File "/home/victor_huggingface_co/miniconda3/envs/promptsource/lib/python3.7/site-packages/datasets/builder.py", line 681, in _download_and_prepare
self._prepare_split(split_generator, **prepare_split_kwargs)
File "/home/victor_huggingface_co/miniconda3/envs/promptsource/lib/python3.7/site-packages/datasets/builder.py", line 1083, in _prepare_split
num_examples, num_bytes = writer.finalize()
File "/home/victor_huggingface_co/miniconda3/envs/promptsource/lib/python3.7/site-packages/datasets/arrow_writer.py", line 468, in finalize
self.write_examples_on_file()
File "/home/victor_huggingface_co/miniconda3/envs/promptsource/lib/python3.7/site-packages/datasets/arrow_writer.py", line 339, in write_examples_on_file
pa_array = pa.array(typed_sequence)
File "pyarrow/array.pxi", line 229, in pyarrow.lib.array
File "pyarrow/array.pxi", line 110, in pyarrow.lib._handle_arrow_array_protocol
File "/home/victor_huggingface_co/miniconda3/envs/promptsource/lib/python3.7/site-packages/datasets/arrow_writer.py", line 125, in __arrow_array__
out = pa.array(cast_to_python_objects(self.data, only_1d_for_numpy=True), type=type)
File "pyarrow/array.pxi", line 315, in pyarrow.lib.array
File "pyarrow/array.pxi", line 39, in pyarrow.lib._sequence_to_array
File "pyarrow/error.pxi", line 143, in pyarrow.lib.pyarrow_internal_check_status
File "pyarrow/error.pxi", line 99, in pyarrow.lib.check_status
pyarrow.lib.ArrowInvalid: Could not convert 'in' with type str: tried to convert to boolean
```
Environment (datasets and pyarrow):
```bash
(promptsource) victor_huggingface_co@victor-dev:~/promptsource$ datasets-cli env
Copy-and-paste the text below in your GitHub issue.
- `datasets` version: 1.16.1
- Platform: Linux-5.0.0-1020-gcp-x86_64-with-debian-buster-sid
- Python version: 3.7.11
- PyArrow version: 6.0.1
```
```bash
(promptsource) victor_huggingface_co@victor-dev:~/promptsource$ pip show pyarrow
Name: pyarrow
Version: 6.0.1
Summary: Python library for Apache Arrow
Home-page: https://arrow.apache.org/
Author:
Author-email:
License: Apache License, Version 2.0
Location: /home/victor_huggingface_co/miniconda3/envs/promptsource/lib/python3.7/site-packages
Requires: numpy
Required-by: streamlit, datasets
``` | [
-0.3966264427,
-0.0293868184,
-0.0101254024,
-0.0253717583,
0.437127471,
-0.2806428671,
0.3386761248,
0.556179285,
-0.4660204649,
0.315726459,
0.0433580056,
0.4963358641,
-0.044431705,
0.2531987429,
-0.0515403748,
-0.0324558951,
0.3282588124,
0.0855189115,
-0.1907031983,
0.1468900144,
-0.2902027965,
0.4182665348,
-0.3476004601,
0.2766410708,
-0.035912551,
0.0112014115,
-0.0338216498,
0.2789126933,
-0.0952879041,
-0.3773418069,
0.0384189822,
-0.2121872008,
0.0456232131,
0.0974894688,
-0.0001167218,
-0.137723282,
0.5200442672,
0.0448611118,
-0.6164503694,
-0.3640908003,
-0.0084976591,
-0.1379765421,
0.2750954032,
0.0643834323,
0.3526573777,
-0.1664236188,
0.123278074,
-0.0857830569,
0.0488290191,
0.3775561154,
0.1874645203,
0.3224671185,
0.044700399,
-0.1101857722,
0.3798225224,
0.2187084407,
-0.1128101423,
0.2455447018,
0.5145853162,
-0.0340349451,
-0.2871374488,
-0.0507837906,
-0.03063084,
0.0147015629,
0.1840147525,
0.1609505564,
0.2144820094,
-0.0955493078,
0.0505981408,
0.1994389594,
-0.075740397,
-0.0409259163,
-0.3641888499,
-0.2433148324,
-0.0481205955,
-0.2821283937,
0.0636921674,
0.145778954,
-0.3126292229,
0.0823408812,
0.0190416053,
-0.1535234302,
-0.1970094442,
-0.0278271344,
-0.2780686021,
0.4535441101,
0.161358133,
0.0663333833,
-0.1642298251,
-0.4638274014,
-0.0472771525,
0.2076614201,
-0.2762575448,
-0.0243575145,
-0.3566706181,
0.1805441827,
-0.1669729948,
0.2387900949,
0.4651682675,
0.0979774892,
0.1155491844,
0.1662838459,
0.2505278885,
-0.0958273038,
0.0706762895,
0.175477311,
0.0591557547,
0.2348844856,
0.2076438367,
0.1650788635,
-0.1005599946,
0.1501936615,
-0.3113727868,
-0.1383321583,
-0.0215176549,
0.2842209637,
0.4755913913,
-0.1113109961,
-0.1448829919,
-0.0547552742,
-0.3113931119,
0.1721538603,
-0.1202061549,
0.424700141,
0.068102479,
0.2945426404,
0.0428204574,
0.2780851126,
-0.082872428,
-0.3413934112,
-0.0051559107,
-0.231515184,
-0.071772173,
-0.1258574724,
0.0893809721,
-0.4185523689,
0.2296047509,
-0.0135393264,
-0.0290311594,
-0.0224329401,
-0.3403317332,
0.0309361685,
0.1752630174,
0.1766824424,
-0.3072060943,
0.1894590557,
0.2229715139,
0.0236804001,
0.0641341358,
0.5335205793,
-0.1982446611,
-0.3022825718,
-0.283778429,
0.1756766438,
-0.0722577423,
-0.2957755923,
-0.0797065496,
0.08669395,
0.0207260717,
-0.0144152734,
-0.0071354355,
-0.5170386434,
-0.0840358287,
-0.1501352787,
0.137449652,
0.0908866301,
-0.6552961469,
-0.0289990809,
0.1703258604,
0.03076143,
0.0892122015,
0.1232458204,
-0.2585837543,
0.0791957527,
-0.2034781426,
0.1814236492,
0.3232538402,
-0.5484135151,
-0.3085803092,
0.200067848,
-0.2893205285,
-0.007870879,
0.1027715206,
-0.2278965414,
0.1128431931,
-0.1517161578,
0.015039742,
0.464767009,
-0.0549881347,
0.2338287383,
-0.3825125694,
-0.3578754663,
0.0035755793,
0.1658768207,
0.250806421,
0.006790325,
-0.0521403812,
-0.0682172477,
0.4362272024,
-0.263792485,
0.1180773973,
-0.0263772141,
0.3087871373,
-0.2272907794,
0.383990258,
-0.0633910224,
0.0071238787,
0.1212887093,
-0.6558685303,
-0.016595237,
-0.3919719458,
-0.0005629908,
-0.385884732,
0.3725190163,
-0.2480868846,
0.0378618948,
0.1214369982,
0.0975749493,
-0.0871543139,
0.1424746662,
-0.2106296122,
0.0392822996,
-0.0430693142,
0.2750284374,
0.0161686894,
-0.2037835866,
0.0728906021,
-0.4691082835,
0.123485148,
-0.0325083956,
0.2151665241,
0.207092151,
-0.1841935813,
0.3152258396,
-0.0673098564,
-0.0118660191,
-0.2884595692,
-0.3085127771,
0.0796827525,
-0.0351028442,
0.098922953,
0.2596393228,
0.0966892466,
0.0801635012,
0.0345881507,
0.3738894761,
-0.1309759915,
0.4032331109,
0.1047164872,
0.0102851763,
0.0815374628,
-0.0230390187,
0.1245809346,
-0.0283416137,
0.2938503325,
0.3636018932,
0.2539676428,
-0.2051210254,
-0.2609892488,
0.3616353273,
0.4327277243,
-0.0231247153,
0.0440304019,
0.2438743711,
-0.3290321231,
-0.2158550918,
0.0043332078,
0.0351129137,
0.2334617972,
0.2212926745,
0.0079238396,
0.0766538233,
0.1275395006,
-0.2352775335,
0.4961217642,
0.1232407913,
0.1517974585,
0.2934263051,
0.5204678774,
-0.2894452512,
-0.0357437395,
-0.0686139837,
0.1008450314,
0.1341222227,
-0.5281246901,
0.0634803027,
-0.3993853033,
-0.0690145269,
-0.0223655887,
-0.2730377316,
0.0266030077,
-0.4870315194,
0.1566191018,
0.331299305,
0.097087495,
0.23251459,
0.2916694283,
0.0638573542,
0.2807582319,
-0.2097253352,
-0.4015879631,
-0.3157898188,
-0.6300775409,
0.092931889,
0.2213294357,
-0.1620728225,
-0.1523884237,
-0.11328578,
0.2214528769,
-0.4510794282,
-0.2491786331,
0.156538412,
-0.2109268606,
0.6037584543,
0.1827927977,
0.0282294396,
-0.2515259683,
-0.0682962686,
0.3746387959,
-0.0295668263,
-0.1904094219,
0.3366340995,
-0.1861752868,
0.0957381725,
-0.1751203537,
-0.1736467928,
-0.1435552537,
-0.1459583789,
0.1243358254,
-0.2053038329,
0.1318918318,
0.2372523397,
0.1952128261,
0.1596049517,
-0.1176490784,
-0.1415267736,
0.0838677883,
-0.0995760113,
0.4430106282,
-0.1271877885,
-0.4206480086,
-0.0131346798,
0.0995700657,
-0.2086511403,
0.1332319677,
-0.1357425749,
-0.0518980287,
0.0065725455,
0.3916832507,
0.0625959411,
-0.3102018535,
0.1457020789,
0.0947464928,
-0.075800404,
-0.1309308857,
-0.020206036,
0.2227568477,
-0.1657493562,
0.233538419,
0.0570842512,
0.3902115822,
0.1128184125,
0.6373870969,
-0.0524862073,
0.2561359107,
0.2227350324,
-0.29943645,
-0.1658242792,
-0.2255207151,
-0.0485541932,
-0.1799290776,
-0.2264750451,
-0.1106109545,
0.3079737723,
0.038308017,
-0.0771764144,
0.0262920372,
-0.3573785424,
-0.2329494953,
-0.2534929812,
0.130121246,
-0.3026338518,
0.0043335664,
-0.0650861487,
0.2166208774,
-0.0201308616,
-0.2319601327,
0.1100337729,
0.0247120559,
0.1257786602,
0.095540978,
0.2633619905,
-0.1614676267,
-0.3044529259,
0.2825227082,
0.1292722523,
0.5543057323,
-0.0597960763,
-0.2270094901,
0.1011032462,
-0.3767522871,
0.5178476572,
0.1249644458,
0.2951943278,
0.1013250276,
0.0702088475,
-0.2759866118,
-0.3344836533,
-0.3245622218,
-0.3352893293,
-0.1471043676,
0.2582192421,
-0.3400407135,
-0.1449511349,
0.1129990518,
0.1510785818,
-0.2412489504,
0.0983876735,
-0.4369594157,
-0.3268574178,
-0.2102308571,
0.0904218405,
0.061878562,
0.4255529046,
-0.1088852212,
0.0996782929,
-0.2236175686,
-0.0740635693,
0.1518763304,
-0.0463803113,
0.2966937125,
-0.4534736574,
0.071640864,
-0.0156232677,
0.1540164798,
0.2282691449,
0.1473333389,
0.3107077181,
-0.3316827118,
0.1837081164,
0.1032831594,
0.3398342431,
0.3543538749,
-0.4470532835,
0.1739647985,
0.1536146551,
0.0969751701,
0.0991464481,
-0.0957576185,
0.1761750281,
0.1350779086,
-0.1188733131,
0.1139437631,
0.2527821362,
0.0491685085,
-0.0247747749,
-0.0167868026,
0.1502289027,
-0.1952711791,
0.4510205388,
0.076991044,
0.6604393125,
-0.0245273579,
0.0836482942,
0.6889129281,
-0.4149240255,
0.0947879776,
0.2746942341,
0.1154940054,
-0.7608676553,
0.1863999516,
0.0497698672,
-0.118590489,
0.1262571216,
-0.2905394137,
-0.4932020605,
0.1283912808,
-0.4038132429,
-0.0633681193,
0.3008951545,
0.2234851122,
-0.1599833369,
0.003793369,
-0.3496327102,
0.0762680992,
-0.2014762759,
-0.0967222527,
0.0669584125,
-0.2826000154,
-0.3045318127,
-0.099907741,
-0.1600769013,
0.309007585,
-0.1748367995,
-0.1534027904,
0.1273959577,
-0.3968886137,
-0.2175243944,
0.3667871952,
0.0789973959,
-0.0761131346,
-0.1889599264,
0.1684749424,
-0.1538956016,
0.2620684803,
0.3644160628,
0.0197626241,
0.3370817602,
-0.0959564596,
-0.0681122541,
0.1653586626,
-0.2093863785,
0.0249285232,
-0.3664905727,
-0.1385969073,
0.0850629732,
-0.4446941316,
0.0821984336,
-0.2676554322,
0.1526348293,
-0.1179004088,
0.0697377175,
-0.2012613863,
0.1572143435,
0.0646595955,
0.1239013448,
-0.2696755826,
0.0468224883,
0.2036131471,
-0.1313973814,
0.0543608293,
0.5738536716,
0.1717341542,
-0.1447811127,
0.0158588476,
0.2638829648,
0.1437258422,
-0.4742690027,
0.3757937253,
-0.0839079246,
0.0710007921,
0.2530608475,
0.485992521,
0.0542181805,
-0.1083532944,
-0.2932958603,
-0.2589531243,
-0.3473466337,
0.2470989972,
-0.2716686428,
-0.2088464499,
0.0673539862,
-0.0651115254,
-0.0758077353,
-0.1838375926,
-0.2481263578,
-0.0121899648,
0.0392326266,
0.0444516055,
-0.7297603488,
-0.1557896733,
0.2145731002,
0.3354530632,
0.1064091399,
0.2258628905,
-0.05091957,
-0.1878619939,
-0.1999962032,
0.1320245117,
0.0430722497,
-0.0191010255,
-0.05162571,
0.1010140926,
0.1942317188,
-0.0965584964,
0.2449462265,
0.129448235,
-0.17450279,
-0.007147328,
0.3847126961,
0.2020655274,
-0.0508681461,
0.0613862723,
-0.0918903947,
0.0737019628,
-0.1489284486,
0.2074237913,
-0.2002661526,
-0.1199044958,
-0.0094052143,
0.1558917463,
0.4734352231,
0.1437500864,
0.4482921362,
-0.3801971972,
-0.2898279428,
-0.6394795775,
0.0803136826,
0.1834048778,
-0.2576931715,
-0.1251041442,
0.0258813761,
0.1234548092,
-0.1841157228,
0.0388722979,
-0.2384876013,
-0.2257269919,
-0.2459239662,
0.1589037031,
0.0380843952,
-0.4761715531,
0.240429163,
0.0822925195,
0.4149733782,
0.0401168503,
-0.2901086509,
0.3502666354,
-0.0590538643,
0.0691355392,
0.5991222262,
-0.0560796186,
-0.0254707411,
0.4060743153,
-0.3071376383,
0.2279812098,
0.2390895188,
0.3145491481,
0.2120660096,
-0.0114728324,
0.0436962582,
0.2646916211,
0.0711444765,
-0.1551605314,
0.0970384926,
0.5189216733,
0.0528011844,
0.1315408796,
-0.1771384776,
0.1026225239,
-0.386647284,
-0.352175951,
-0.2654831409,
-0.0806187391,
-0.0984239504,
0.0136290519,
-0.222851932,
-0.0620158575,
0.1414320916,
0.3663139045,
0.0850242898,
-0.2074570805,
-0.1791507304,
0.2524778545,
0.062233068,
-0.3512997627,
0.4280688763,
-0.0075732809,
0.0923484489,
0.4559710622,
0.2361955196,
0.5852956176,
0.571190238,
-0.3293547034,
-0.1508944035,
-0.18991898,
-0.0847660527,
0.2489919811,
0.2071053237,
0.1686581969,
0.5591821671,
0.2532341778,
0.1169549227,
-0.0688979104,
0.2050152719,
0.0113540674,
0.1067281291,
-0.0143366354,
-0.1395703256,
0.0041471724,
-0.0274964906,
0.0348281115,
-0.1842303276,
-0.3738332987,
0.1992004812,
0.3274312019,
0.4463910162,
0.1755767912,
0.0665299371,
0.0889660791,
0.2009438872,
0.0525245257,
0.2307693064,
0.1737601608,
-0.2764245868,
0.0650427118,
-0.2496349216,
0.2762867212,
0.2641424835,
-0.1135959849,
0.2564686835,
-0.0221663527,
0.0413082913,
0.0267838426,
0.1328698695,
-0.0622817688,
-0.2091931999,
0.345433414,
-0.3404601514,
-0.1161268875,
0.4240863621,
0.0979726017,
-0.081693083,
-0.4437100887,
0.391962558,
-0.1779021323,
0.0515942089,
-0.1807270795,
-0.371013999,
0.4445607066,
-0.0043336558,
0.0896209106,
0.1637361795,
0.2297699451,
0.1722549349,
-0.087324664,
-0.3548120558,
-0.1335435212,
-0.1465682834,
0.1035668105,
-0.1747061163,
0.2506834269,
0.2634966969,
-0.0711534172,
-0.1076607481,
0.0589554608,
-0.1442945451,
0.0274602864,
-0.3149678707,
0.194536522,
0.1456653923,
0.0341419615,
-0.2995273173,
0.0610692911,
0.1971810311,
0.1933806688,
-0.6450316906,
-0.3145316839,
0.4749608338,
-0.345410943,
-0.3426010907,
0.027816195,
0.1346042007,
0.117189154,
0.0646960065,
-0.7658609152,
-0.068892166,
0.2879169583,
0.1700969338,
0.0347717553,
0.0514551774,
0.3072243929,
0.3257615268,
-0.3666227162,
-0.17268534,
0.101712741,
0.10527464,
-0.3325513601,
-0.2277471572
] |
https://github.com/huggingface/datasets/issues/3345 | Failed to download species_800 from Google Drive zip file | Hi,
the dataset is downloaded normally on my machine. Maybe the URL was down at the time of your download. Could you try again? | ## Describe the bug
One can manually download the zip file on Google Drive, but `load_dataset()` cannot.
related: #3248
## Steps to reproduce the bug
```shell
> python
Python 3.7.12 (default, Sep 5 2021, 08:34:29)
[Clang 11.0.3 (clang-1103.0.32.62)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
```
```python
>>> from datasets import load_dataset
>>> s800 = load_dataset("species_800")
```
## Expected results
species_800 downloaded.
## Actual results
```shell
Downloading: 5.68kB [00:00, 1.22MB/s]
Downloading: 2.70kB [00:00, 691kB/s]
Downloading and preparing dataset species800/species_800 (download: 17.36 MiB, generated: 3.53 MiB, post-processed: Unknown size, total: 20.89 MiB) to /Users/mike/.cache/huggingface/datasets/species800/species_800/1.0.0/532167f0bb8fbc0d77d6d03c4fd642c8c55527b9c5f2b1da77f3d00b0e559976...
0%| | 0/1 [00:00<?, ?it/s]Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/load.py", line 1632, in load_dataset
use_auth_token=use_auth_token,
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/builder.py", line 608, in download_and_prepare
dl_manager=dl_manager, verify_infos=verify_infos, **download_and_prepare_kwargs
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/builder.py", line 675, in _download_and_prepare
split_generators = self._split_generators(dl_manager, **split_generators_kwargs)
File "/Users/mike/.cache/huggingface/modules/datasets_modules/datasets/species_800/532167f0bb8fbc0d77d6d03c4fd642c8c55527b9c5f2b1da77f3d00b0e559976/species_800.py", line 104, in _split_generators
downloaded_files = dl_manager.download_and_extract(urls_to_download)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/download_manager.py", line 284, in download_and_extract
return self.extract(self.download(url_or_urls))
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/download_manager.py", line 197, in download
download_func, url_or_urls, map_tuple=True, num_proc=download_config.num_proc, disable_tqdm=False
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/py_utils.py", line 209, in map_nested
for obj in utils.tqdm(iterable, disable=disable_tqdm)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/py_utils.py", line 209, in <listcomp>
for obj in utils.tqdm(iterable, disable=disable_tqdm)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/py_utils.py", line 143, in _single_map_nested
return function(data_struct)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/download_manager.py", line 217, in _download
return cached_path(url_or_filename, download_config=download_config)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/file_utils.py", line 305, in cached_path
use_auth_token=download_config.use_auth_token,
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/file_utils.py", line 594, in get_from_cache
raise ConnectionError("Couldn't reach {}".format(url))
ConnectionError: Couldn't reach https://drive.google.com/u/0/uc?id=1OletxmPYNkz2ltOr9pyT0b0iBtUWxslh&export=download/
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.14,0 1.15.0, 1.16.1
- Platform: macOS Catalina 10.15.7
- Python version: 3.7.12
- PyArrow version: 6.0.1
| 24 | Failed to download species_800 from Google Drive zip file
## Describe the bug
One can manually download the zip file on Google Drive, but `load_dataset()` cannot.
related: #3248
## Steps to reproduce the bug
```shell
> python
Python 3.7.12 (default, Sep 5 2021, 08:34:29)
[Clang 11.0.3 (clang-1103.0.32.62)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
```
```python
>>> from datasets import load_dataset
>>> s800 = load_dataset("species_800")
```
## Expected results
species_800 downloaded.
## Actual results
```shell
Downloading: 5.68kB [00:00, 1.22MB/s]
Downloading: 2.70kB [00:00, 691kB/s]
Downloading and preparing dataset species800/species_800 (download: 17.36 MiB, generated: 3.53 MiB, post-processed: Unknown size, total: 20.89 MiB) to /Users/mike/.cache/huggingface/datasets/species800/species_800/1.0.0/532167f0bb8fbc0d77d6d03c4fd642c8c55527b9c5f2b1da77f3d00b0e559976...
0%| | 0/1 [00:00<?, ?it/s]Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/load.py", line 1632, in load_dataset
use_auth_token=use_auth_token,
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/builder.py", line 608, in download_and_prepare
dl_manager=dl_manager, verify_infos=verify_infos, **download_and_prepare_kwargs
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/builder.py", line 675, in _download_and_prepare
split_generators = self._split_generators(dl_manager, **split_generators_kwargs)
File "/Users/mike/.cache/huggingface/modules/datasets_modules/datasets/species_800/532167f0bb8fbc0d77d6d03c4fd642c8c55527b9c5f2b1da77f3d00b0e559976/species_800.py", line 104, in _split_generators
downloaded_files = dl_manager.download_and_extract(urls_to_download)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/download_manager.py", line 284, in download_and_extract
return self.extract(self.download(url_or_urls))
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/download_manager.py", line 197, in download
download_func, url_or_urls, map_tuple=True, num_proc=download_config.num_proc, disable_tqdm=False
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/py_utils.py", line 209, in map_nested
for obj in utils.tqdm(iterable, disable=disable_tqdm)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/py_utils.py", line 209, in <listcomp>
for obj in utils.tqdm(iterable, disable=disable_tqdm)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/py_utils.py", line 143, in _single_map_nested
return function(data_struct)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/download_manager.py", line 217, in _download
return cached_path(url_or_filename, download_config=download_config)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/file_utils.py", line 305, in cached_path
use_auth_token=download_config.use_auth_token,
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/file_utils.py", line 594, in get_from_cache
raise ConnectionError("Couldn't reach {}".format(url))
ConnectionError: Couldn't reach https://drive.google.com/u/0/uc?id=1OletxmPYNkz2ltOr9pyT0b0iBtUWxslh&export=download/
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.14,0 1.15.0, 1.16.1
- Platform: macOS Catalina 10.15.7
- Python version: 3.7.12
- PyArrow version: 6.0.1
Hi,
the dataset is downloaded normally on my machine. Maybe the URL was down at the time of your download. Could you try again? | [
-0.3141798079,
-0.0384752676,
-0.0492311679,
0.202085346,
0.1646693647,
0.1617155075,
0.2258754224,
0.2475837171,
0.1551792473,
-0.010348252,
-0.1063770503,
0.2193597704,
-0.0180688519,
0.2488591969,
0.2162835598,
-0.0912972242,
-0.1193725467,
-0.0873610005,
0.1564017832,
0.04595346,
-0.3997566104,
0.3511322141,
-0.1499847621,
-0.1370418817,
0.102524288,
-0.0809271038,
-0.0141765112,
0.4140371382,
-0.1233640835,
-0.359628588,
0.2946698666,
-0.047692664,
0.1257543415,
0.3042757511,
-0.0001109521,
-0.0142269917,
0.5148410797,
0.066041179,
-0.5604020953,
-0.2934931815,
0.1227299348,
-0.1425184011,
-0.0646062344,
-0.2044624388,
0.1588469148,
-0.1592077017,
0.1022412628,
-0.3952917755,
0.3530472219,
0.305457145,
0.2533213496,
0.1408454329,
0.3898606598,
-0.166494146,
0.4034855962,
-0.0750306249,
-0.0450003482,
0.6451201439,
0.0823446363,
0.2718516886,
0.0425242148,
-0.0295167137,
0.0881071314,
0.0383990109,
0.0006941779,
0.074087061,
-0.2062598467,
-0.3297934234,
0.2224153578,
-0.0045587039,
0.4395232201,
-0.2389552146,
-0.4470049739,
-0.1738799214,
0.1314548403,
-0.4225739837,
0.4308348,
0.2705187798,
-0.1549898237,
0.0667553097,
-0.1866744459,
0.0041195322,
-0.0480876602,
0.0420016423,
-0.3033825457,
0.1795377731,
-0.1598045081,
0.1286745071,
-0.0108467704,
0.1046244055,
0.0993992761,
-0.2571163774,
-0.1561887711,
0.2032140493,
-0.375210315,
0.1464049816,
0.1148997992,
0.1149308681,
0.3292046189,
0.3075514138,
-0.1292122602,
-0.123900272,
-0.2372218817,
0.1114827693,
0.1988593638,
0.4007110894,
-0.1291655302,
0.0336219519,
0.2132978141,
0.3256240189,
0.0072206748,
-0.0009814486,
0.076609768,
-0.2363764346,
0.227457121,
0.1388336718,
0.455157578,
-0.0762315392,
-0.4224095643,
0.1605560482,
-0.4209617376,
-0.0498061925,
-0.1374264061,
0.1001048163,
-0.1145350039,
-0.0005766343,
0.1056683585,
0.210258767,
0.0547824241,
-0.2062687427,
-0.2014166117,
0.1310752332,
-0.0948300585,
-0.0711653978,
0.2246997803,
-0.3604337275,
0.2049078643,
0.0555513129,
-0.0399491489,
-0.1359736174,
-0.0607879423,
-0.1023945287,
-0.3439168632,
0.4209779799,
0.2723086774,
0.209945336,
0.0565683804,
-0.09603329,
-0.046122659,
0.0073451865,
-0.2212390304,
-0.0100188265,
-0.1647759676,
0.2118282467,
-0.2752349973,
-0.0880683735,
-0.3080986738,
-0.0777450651,
-0.1111669838,
0.0707625821,
-0.0259706788,
-0.058842808,
-0.2825124562,
-0.4713051319,
0.1577073783,
0.4734970033,
-0.2767035067,
0.1404643208,
-0.4503751993,
-0.0727281719,
0.3189189434,
0.1745324135,
-0.0535072871,
0.2142744362,
-0.4785751998,
0.2197947353,
0.2282408774,
-0.1628597677,
-0.5239959359,
0.2947417796,
-0.3254170418,
0.3206422627,
-0.0717684999,
-0.0690486208,
-0.0034134323,
0.1464300901,
0.1481629014,
0.4415034056,
-0.0463459082,
0.0235596057,
-0.2104187608,
-0.346362412,
0.0896225721,
0.3526124358,
0.0403664187,
0.1935520917,
0.3988821805,
-0.4314284027,
0.243265599,
-0.0537186377,
0.0368759148,
0.3293354213,
0.2900213301,
0.0741828308,
-0.0295129474,
-0.1137086228,
-0.8161108494,
0.3076701164,
-0.1643370539,
-0.0674317703,
-0.3801318407,
-0.0504241213,
-0.6161767244,
-0.0091839051,
-0.079606846,
-0.0979320332,
0.1177890077,
0.2380366623,
0.1952967942,
0.2244134396,
0.0221685208,
0.469276011,
0.0749241561,
0.2263448685,
-0.2785495222,
0.1771832258,
-0.0874420851,
-0.2783634067,
0.2419015616,
-0.1988477409,
0.1234325394,
-0.1083585322,
-0.2305093557,
0.3897269666,
-0.0546177961,
0.048146002,
-0.0299875215,
-0.1138609201,
0.1726948023,
-0.1660008878,
0.0772402585,
0.2172893435,
0.2041255981,
0.0600207336,
-0.5396811366,
0.186011076,
0.0372098871,
-0.0587153919,
-0.1854600608,
0.2006866336,
0.1545967758,
-0.1571740061,
0.1069497466,
0.2504680753,
0.3380044401,
0.0964783728,
0.7787850499,
-0.2652098536,
-0.1462592483,
0.0975311473,
0.3151348233,
-0.027911244,
0.1542780399,
0.2826802135,
-0.1724483222,
-0.1511733383,
0.0681392103,
0.4547289014,
0.5494405627,
0.1251671761,
0.363150686,
0.1061129868,
-0.0100027155,
-0.1754012257,
0.1537657082,
0.0370990261,
-0.0280965865,
0.0848379657,
0.2686849833,
0.0387531854,
-0.2527611256,
-0.0342042558,
0.0901519582,
0.1206785589,
-0.327927798,
0.2239741236,
-0.0853879675,
0.0961753204,
-0.0142297158,
0.3047954738,
-0.2716308534,
-0.3072175682,
-0.326221168,
0.3114142716,
0.0292224996,
-0.0398435816,
0.0980323777,
0.0405011252,
0.2946369648,
-0.3845742643,
-0.2616502643,
0.2500508726,
-0.2786937058,
0.0765002593,
0.352104336,
-0.1339194924,
0.4593881965,
0.0032710116,
0.0486195609,
-0.5828670859,
-0.3285715878,
0.0445327535,
-0.0769553706,
0.414881438,
0.2503486872,
0.2806973457,
-0.1553096324,
0.0032504173,
0.2041029483,
-0.1057123914,
-0.2289656401,
0.0168741159,
-0.0265190881,
0.1165464744,
-0.2804705501,
-0.2161669284,
-0.1667933315,
-0.2883911729,
0.4418581128,
0.270749718,
0.0808251426,
0.2550257146,
-0.0025097148,
0.1105968133,
0.2118404955,
-0.1537091434,
-0.308970958,
-0.3757974505,
0.4339389801,
-0.0978652909,
-0.3770108521,
0.045554202,
-0.0735115483,
0.0028513835,
0.3280913234,
-0.4320271313,
-0.0983475745,
-0.3765000403,
0.5410792232,
-0.3062829375,
0.194680661,
0.0396606363,
-0.0675368235,
-0.0794731826,
-0.0233076364,
-0.085149318,
-0.0072275037,
0.1908590496,
0.3523198962,
0.1263819188,
0.2312514633,
-0.0810244158,
0.11559356,
0.1947385371,
0.1424223334,
0.4200140536,
-0.0924703181,
0.2850717902,
-0.1047578231,
-0.0533397794,
-0.0980366692,
-0.1075427681,
-0.1674192399,
0.2470464557,
-0.0184311438,
-0.1849405915,
-0.0807927027,
-0.1951981783,
-0.4651195407,
-0.2075722218,
0.0574503765,
0.0589156635,
0.1602445394,
-0.0132292947,
-0.054693006,
0.0316445865,
-0.1284644306,
0.0514668822,
0.2576346099,
0.1376236975,
0.1586131155,
-0.1772044003,
0.143541038,
-0.4153490961,
0.3013409376,
-0.2719990313,
0.1783405244,
-0.0959233865,
0.2039421052,
0.1154715344,
-0.1845635176,
0.5941319466,
-0.2195526958,
0.3889464736,
0.1375601143,
0.1397218108,
0.0553891361,
-0.1787086427,
-0.1591162235,
0.0899572372,
0.1018381491,
0.2580936849,
-0.3964519203,
0.2316053659,
0.1664516777,
0.1830684841,
-0.0526355058,
-0.32474792,
-0.1970169991,
-0.5626170635,
-0.2390076667,
0.0165660009,
0.0660000667,
0.3151394725,
-0.1389137208,
0.1314137727,
-0.0549560189,
-0.1673580557,
0.0257362016,
-0.1238389462,
0.2914531231,
0.1203575879,
0.2208614349,
0.2079521716,
-0.0736903474,
-0.0236937776,
0.7968281507,
0.1111309901,
-0.3448218703,
0.1094036996,
-0.0630303174,
-0.0907483548,
0.2092819512,
-0.3266681135,
-0.2019654065,
-0.0000301455,
0.1876703352,
-0.0053782822,
0.016149547,
0.0787550285,
-0.0804265738,
-0.0525682308,
-0.3258219957,
0.6423517466,
0.1330873519,
-0.078893885,
0.457218349,
-0.0628391951,
-0.2809722722,
0.302823931,
-0.0614192188,
0.674405098,
-0.2074631006,
0.00626485,
0.2989005446,
-0.2328980267,
0.4780514538,
-0.0521135181,
0.0752845928,
-0.4610928595,
-0.1191899106,
0.0464383811,
-0.1367785186,
0.1565551758,
0.2056341618,
-0.3285841942,
0.2294414043,
-0.2635014653,
0.0411225036,
0.2386642247,
0.2831478715,
-0.4382478297,
-0.1093409508,
-0.294449836,
0.2128226757,
-0.2652935982,
0.5029411912,
-0.0922181755,
-0.1172888801,
-0.3791992068,
-0.4068582058,
-0.3460422158,
0.2422224432,
-0.2425498068,
0.1109371334,
-0.1323486716,
-0.3450956345,
0.0405500978,
0.0373903476,
0.1874451041,
0.2531139255,
-0.2236551791,
0.222467348,
-0.021124471,
-0.0206376854,
0.126280874,
0.0536437556,
0.1209004521,
0.0031680651,
0.0083963647,
0.0582263842,
-0.1437630653,
-0.2783736587,
0.1079577729,
0.0431331098,
-0.0722398832,
-0.0930835307,
-0.1362005323,
-0.3472467959,
0.0720216483,
-0.16148597,
0.1262127757,
0.1170986965,
0.2293575555,
0.0001288123,
-0.0441695936,
-0.255025059,
-0.1353898495,
0.4048899412,
-0.1570873559,
-0.1100188121,
0.2982642055,
0.2103372514,
-0.0321137495,
-0.1437608898,
0.0326506793,
-0.2303508967,
-0.3998271823,
0.4188895226,
-0.2503899336,
0.2387252301,
-0.3252814412,
0.1407638788,
0.119808875,
-0.0347978398,
0.2385182977,
-0.581230104,
-0.1436620355,
-0.0061093466,
-0.1386784315,
0.180455327,
-0.0270741601,
-0.0641653091,
0.2751458585,
-0.2976421416,
-0.3121730387,
0.1425504982,
-0.2980720401,
-0.2433869839,
0.4069213867,
0.0338501036,
0.3514270484,
0.0330442786,
0.2212505192,
0.0531475432,
-0.0231196918,
-0.2581776083,
-0.0759356618,
0.0996251777,
-0.1369615048,
-0.0495095216,
0.2458820641,
-0.2069416344,
-0.2828221917,
0.1267895252,
0.1550593972,
0.1226731762,
-0.0005350636,
-0.2239402533,
0.114474386,
0.1906476766,
-0.3373761773,
0.1662783027,
-0.3700557351,
0.0994457006,
-0.0703751519,
0.1960230768,
-0.0635828376,
0.0812006295,
-0.3058228791,
-0.2660926878,
-0.0109472014,
0.1469589621,
0.2719492316,
-0.2939621508,
-0.2045081556,
0.0314209349,
0.1434335262,
0.3744244874,
-0.4239740074,
-0.0489243828,
0.0730318949,
0.19796817,
-0.1849910766,
-0.057120584,
-0.0592719726,
0.0082338536,
-0.0164727867,
0.1056926474,
0.1547726095,
-0.0033404764,
-0.2006566674,
0.0100804744,
0.6570011973,
0.1752971113,
0.0270172823,
0.3850589693,
0.0233307742,
0.1239538342,
0.2832896411,
0.0459709875,
-0.0223147012,
0.4396225512,
-0.0504779071,
-0.1335068047,
-0.1743731499,
-0.0119659863,
0.0042828009,
-0.3351182342,
0.0757922456,
0.2811041772,
-0.151292786,
0.0644628704,
0.1218860745,
0.3900282085,
-0.4427158237,
0.0342355371,
-0.1804965883,
0.2151076049,
-0.0027280068,
0.1524378657,
0.0196515787,
-0.0512802899,
-0.4637365937,
0.2973272502,
-0.1109528765,
-0.1784162819,
0.3278419971,
0.1989335269,
-0.1134979203,
-0.1596430987,
-0.3788303733,
0.0923645198,
0.0458245017,
-0.4186378419,
0.2045313567,
0.2281176299,
-0.0769743249,
0.0767430067,
0.2434875816,
0.4869220257,
0.1680266261,
0.1220679134,
-0.1336020529,
-0.0036336568,
-0.0551223345,
-0.0423396677,
0.0178034939,
0.1073997542,
-0.0388363861,
0.3513838351,
0.205718264,
-0.2051291317,
0.039958369,
0.0511400364,
-0.0289697759,
-0.1343516558,
0.3138986528,
-0.3455215991,
-0.08757177,
-0.2171858847,
-0.0513285436,
-0.2142635137,
0.0458263345,
-0.018530786,
0.2594949901,
0.0478549078,
-0.0549204834,
0.0884926096,
0.0377769247,
0.2976367474,
0.3341208994,
0.1209082827,
-0.2648687065,
-0.3004694283,
-0.6649755836,
0.070399411,
-0.1858363599,
-0.0878621265,
0.1080959812,
0.1650424898,
-0.2850914001,
0.1554919928,
0.15975146,
0.3603071272,
-0.0145675885,
0.1925240159,
-0.1731229424,
-0.2458997518,
0.3004636168,
-0.1998405606,
-0.1391913146,
-0.4236563444,
0.2776136994,
-0.3155619204,
0.1364343464,
-0.267395556,
-0.1899685264,
0.0373907723,
-0.144747138,
0.669269681,
0.0729983971,
0.362126708,
-0.1162695438,
-0.54294765,
-0.3984391093,
-0.0250897985,
-0.0677857772,
0.2849219143,
-0.0472931005,
0.5349885225,
0.1111853942,
-0.0518118963,
-0.2850215137,
0.3580045998,
0.078401491,
0.0194908064,
-0.2955948412,
0.1473933309,
-0.1806369126,
0.2493708134,
0.1257130951,
0.1924650371,
-0.0530028753,
0.1355544031,
-0.3248472214,
-0.5054667592,
0.3653924167,
-0.1721520573,
-0.3038915992,
0.0407400019,
0.1347826868,
0.1327940077,
-0.1150985733,
-0.2983288169,
0.1924623847,
0.3338205218,
-0.1202746257,
-0.1841252595,
0.2295880318,
-0.1024255008,
-0.046189785,
0.087924026,
0.195561409,
0.0866081715,
-0.0872031897,
0.1778777093,
-0.1123300418
] |
https://github.com/huggingface/datasets/issues/3345 | Failed to download species_800 from Google Drive zip file | > Hi,
>
> the dataset is downloaded normally on my machine. Maybe the URL was down at the time of your download. Could you try again?
I have tried that many times with both load_dataset() and a browser almost simultaneously. The browser always works for me while load_dataset() fails. | ## Describe the bug
One can manually download the zip file on Google Drive, but `load_dataset()` cannot.
related: #3248
## Steps to reproduce the bug
```shell
> python
Python 3.7.12 (default, Sep 5 2021, 08:34:29)
[Clang 11.0.3 (clang-1103.0.32.62)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
```
```python
>>> from datasets import load_dataset
>>> s800 = load_dataset("species_800")
```
## Expected results
species_800 downloaded.
## Actual results
```shell
Downloading: 5.68kB [00:00, 1.22MB/s]
Downloading: 2.70kB [00:00, 691kB/s]
Downloading and preparing dataset species800/species_800 (download: 17.36 MiB, generated: 3.53 MiB, post-processed: Unknown size, total: 20.89 MiB) to /Users/mike/.cache/huggingface/datasets/species800/species_800/1.0.0/532167f0bb8fbc0d77d6d03c4fd642c8c55527b9c5f2b1da77f3d00b0e559976...
0%| | 0/1 [00:00<?, ?it/s]Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/load.py", line 1632, in load_dataset
use_auth_token=use_auth_token,
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/builder.py", line 608, in download_and_prepare
dl_manager=dl_manager, verify_infos=verify_infos, **download_and_prepare_kwargs
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/builder.py", line 675, in _download_and_prepare
split_generators = self._split_generators(dl_manager, **split_generators_kwargs)
File "/Users/mike/.cache/huggingface/modules/datasets_modules/datasets/species_800/532167f0bb8fbc0d77d6d03c4fd642c8c55527b9c5f2b1da77f3d00b0e559976/species_800.py", line 104, in _split_generators
downloaded_files = dl_manager.download_and_extract(urls_to_download)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/download_manager.py", line 284, in download_and_extract
return self.extract(self.download(url_or_urls))
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/download_manager.py", line 197, in download
download_func, url_or_urls, map_tuple=True, num_proc=download_config.num_proc, disable_tqdm=False
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/py_utils.py", line 209, in map_nested
for obj in utils.tqdm(iterable, disable=disable_tqdm)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/py_utils.py", line 209, in <listcomp>
for obj in utils.tqdm(iterable, disable=disable_tqdm)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/py_utils.py", line 143, in _single_map_nested
return function(data_struct)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/download_manager.py", line 217, in _download
return cached_path(url_or_filename, download_config=download_config)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/file_utils.py", line 305, in cached_path
use_auth_token=download_config.use_auth_token,
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/file_utils.py", line 594, in get_from_cache
raise ConnectionError("Couldn't reach {}".format(url))
ConnectionError: Couldn't reach https://drive.google.com/u/0/uc?id=1OletxmPYNkz2ltOr9pyT0b0iBtUWxslh&export=download/
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.14,0 1.15.0, 1.16.1
- Platform: macOS Catalina 10.15.7
- Python version: 3.7.12
- PyArrow version: 6.0.1
| 50 | Failed to download species_800 from Google Drive zip file
## Describe the bug
One can manually download the zip file on Google Drive, but `load_dataset()` cannot.
related: #3248
## Steps to reproduce the bug
```shell
> python
Python 3.7.12 (default, Sep 5 2021, 08:34:29)
[Clang 11.0.3 (clang-1103.0.32.62)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
```
```python
>>> from datasets import load_dataset
>>> s800 = load_dataset("species_800")
```
## Expected results
species_800 downloaded.
## Actual results
```shell
Downloading: 5.68kB [00:00, 1.22MB/s]
Downloading: 2.70kB [00:00, 691kB/s]
Downloading and preparing dataset species800/species_800 (download: 17.36 MiB, generated: 3.53 MiB, post-processed: Unknown size, total: 20.89 MiB) to /Users/mike/.cache/huggingface/datasets/species800/species_800/1.0.0/532167f0bb8fbc0d77d6d03c4fd642c8c55527b9c5f2b1da77f3d00b0e559976...
0%| | 0/1 [00:00<?, ?it/s]Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/load.py", line 1632, in load_dataset
use_auth_token=use_auth_token,
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/builder.py", line 608, in download_and_prepare
dl_manager=dl_manager, verify_infos=verify_infos, **download_and_prepare_kwargs
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/builder.py", line 675, in _download_and_prepare
split_generators = self._split_generators(dl_manager, **split_generators_kwargs)
File "/Users/mike/.cache/huggingface/modules/datasets_modules/datasets/species_800/532167f0bb8fbc0d77d6d03c4fd642c8c55527b9c5f2b1da77f3d00b0e559976/species_800.py", line 104, in _split_generators
downloaded_files = dl_manager.download_and_extract(urls_to_download)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/download_manager.py", line 284, in download_and_extract
return self.extract(self.download(url_or_urls))
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/download_manager.py", line 197, in download
download_func, url_or_urls, map_tuple=True, num_proc=download_config.num_proc, disable_tqdm=False
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/py_utils.py", line 209, in map_nested
for obj in utils.tqdm(iterable, disable=disable_tqdm)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/py_utils.py", line 209, in <listcomp>
for obj in utils.tqdm(iterable, disable=disable_tqdm)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/py_utils.py", line 143, in _single_map_nested
return function(data_struct)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/download_manager.py", line 217, in _download
return cached_path(url_or_filename, download_config=download_config)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/file_utils.py", line 305, in cached_path
use_auth_token=download_config.use_auth_token,
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/file_utils.py", line 594, in get_from_cache
raise ConnectionError("Couldn't reach {}".format(url))
ConnectionError: Couldn't reach https://drive.google.com/u/0/uc?id=1OletxmPYNkz2ltOr9pyT0b0iBtUWxslh&export=download/
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.14,0 1.15.0, 1.16.1
- Platform: macOS Catalina 10.15.7
- Python version: 3.7.12
- PyArrow version: 6.0.1
> Hi,
>
> the dataset is downloaded normally on my machine. Maybe the URL was down at the time of your download. Could you try again?
I have tried that many times with both load_dataset() and a browser almost simultaneously. The browser always works for me while load_dataset() fails. | [
-0.3141798079,
-0.0384752676,
-0.0492311679,
0.202085346,
0.1646693647,
0.1617155075,
0.2258754224,
0.2475837171,
0.1551792473,
-0.010348252,
-0.1063770503,
0.2193597704,
-0.0180688519,
0.2488591969,
0.2162835598,
-0.0912972242,
-0.1193725467,
-0.0873610005,
0.1564017832,
0.04595346,
-0.3997566104,
0.3511322141,
-0.1499847621,
-0.1370418817,
0.102524288,
-0.0809271038,
-0.0141765112,
0.4140371382,
-0.1233640835,
-0.359628588,
0.2946698666,
-0.047692664,
0.1257543415,
0.3042757511,
-0.0001109521,
-0.0142269917,
0.5148410797,
0.066041179,
-0.5604020953,
-0.2934931815,
0.1227299348,
-0.1425184011,
-0.0646062344,
-0.2044624388,
0.1588469148,
-0.1592077017,
0.1022412628,
-0.3952917755,
0.3530472219,
0.305457145,
0.2533213496,
0.1408454329,
0.3898606598,
-0.166494146,
0.4034855962,
-0.0750306249,
-0.0450003482,
0.6451201439,
0.0823446363,
0.2718516886,
0.0425242148,
-0.0295167137,
0.0881071314,
0.0383990109,
0.0006941779,
0.074087061,
-0.2062598467,
-0.3297934234,
0.2224153578,
-0.0045587039,
0.4395232201,
-0.2389552146,
-0.4470049739,
-0.1738799214,
0.1314548403,
-0.4225739837,
0.4308348,
0.2705187798,
-0.1549898237,
0.0667553097,
-0.1866744459,
0.0041195322,
-0.0480876602,
0.0420016423,
-0.3033825457,
0.1795377731,
-0.1598045081,
0.1286745071,
-0.0108467704,
0.1046244055,
0.0993992761,
-0.2571163774,
-0.1561887711,
0.2032140493,
-0.375210315,
0.1464049816,
0.1148997992,
0.1149308681,
0.3292046189,
0.3075514138,
-0.1292122602,
-0.123900272,
-0.2372218817,
0.1114827693,
0.1988593638,
0.4007110894,
-0.1291655302,
0.0336219519,
0.2132978141,
0.3256240189,
0.0072206748,
-0.0009814486,
0.076609768,
-0.2363764346,
0.227457121,
0.1388336718,
0.455157578,
-0.0762315392,
-0.4224095643,
0.1605560482,
-0.4209617376,
-0.0498061925,
-0.1374264061,
0.1001048163,
-0.1145350039,
-0.0005766343,
0.1056683585,
0.210258767,
0.0547824241,
-0.2062687427,
-0.2014166117,
0.1310752332,
-0.0948300585,
-0.0711653978,
0.2246997803,
-0.3604337275,
0.2049078643,
0.0555513129,
-0.0399491489,
-0.1359736174,
-0.0607879423,
-0.1023945287,
-0.3439168632,
0.4209779799,
0.2723086774,
0.209945336,
0.0565683804,
-0.09603329,
-0.046122659,
0.0073451865,
-0.2212390304,
-0.0100188265,
-0.1647759676,
0.2118282467,
-0.2752349973,
-0.0880683735,
-0.3080986738,
-0.0777450651,
-0.1111669838,
0.0707625821,
-0.0259706788,
-0.058842808,
-0.2825124562,
-0.4713051319,
0.1577073783,
0.4734970033,
-0.2767035067,
0.1404643208,
-0.4503751993,
-0.0727281719,
0.3189189434,
0.1745324135,
-0.0535072871,
0.2142744362,
-0.4785751998,
0.2197947353,
0.2282408774,
-0.1628597677,
-0.5239959359,
0.2947417796,
-0.3254170418,
0.3206422627,
-0.0717684999,
-0.0690486208,
-0.0034134323,
0.1464300901,
0.1481629014,
0.4415034056,
-0.0463459082,
0.0235596057,
-0.2104187608,
-0.346362412,
0.0896225721,
0.3526124358,
0.0403664187,
0.1935520917,
0.3988821805,
-0.4314284027,
0.243265599,
-0.0537186377,
0.0368759148,
0.3293354213,
0.2900213301,
0.0741828308,
-0.0295129474,
-0.1137086228,
-0.8161108494,
0.3076701164,
-0.1643370539,
-0.0674317703,
-0.3801318407,
-0.0504241213,
-0.6161767244,
-0.0091839051,
-0.079606846,
-0.0979320332,
0.1177890077,
0.2380366623,
0.1952967942,
0.2244134396,
0.0221685208,
0.469276011,
0.0749241561,
0.2263448685,
-0.2785495222,
0.1771832258,
-0.0874420851,
-0.2783634067,
0.2419015616,
-0.1988477409,
0.1234325394,
-0.1083585322,
-0.2305093557,
0.3897269666,
-0.0546177961,
0.048146002,
-0.0299875215,
-0.1138609201,
0.1726948023,
-0.1660008878,
0.0772402585,
0.2172893435,
0.2041255981,
0.0600207336,
-0.5396811366,
0.186011076,
0.0372098871,
-0.0587153919,
-0.1854600608,
0.2006866336,
0.1545967758,
-0.1571740061,
0.1069497466,
0.2504680753,
0.3380044401,
0.0964783728,
0.7787850499,
-0.2652098536,
-0.1462592483,
0.0975311473,
0.3151348233,
-0.027911244,
0.1542780399,
0.2826802135,
-0.1724483222,
-0.1511733383,
0.0681392103,
0.4547289014,
0.5494405627,
0.1251671761,
0.363150686,
0.1061129868,
-0.0100027155,
-0.1754012257,
0.1537657082,
0.0370990261,
-0.0280965865,
0.0848379657,
0.2686849833,
0.0387531854,
-0.2527611256,
-0.0342042558,
0.0901519582,
0.1206785589,
-0.327927798,
0.2239741236,
-0.0853879675,
0.0961753204,
-0.0142297158,
0.3047954738,
-0.2716308534,
-0.3072175682,
-0.326221168,
0.3114142716,
0.0292224996,
-0.0398435816,
0.0980323777,
0.0405011252,
0.2946369648,
-0.3845742643,
-0.2616502643,
0.2500508726,
-0.2786937058,
0.0765002593,
0.352104336,
-0.1339194924,
0.4593881965,
0.0032710116,
0.0486195609,
-0.5828670859,
-0.3285715878,
0.0445327535,
-0.0769553706,
0.414881438,
0.2503486872,
0.2806973457,
-0.1553096324,
0.0032504173,
0.2041029483,
-0.1057123914,
-0.2289656401,
0.0168741159,
-0.0265190881,
0.1165464744,
-0.2804705501,
-0.2161669284,
-0.1667933315,
-0.2883911729,
0.4418581128,
0.270749718,
0.0808251426,
0.2550257146,
-0.0025097148,
0.1105968133,
0.2118404955,
-0.1537091434,
-0.308970958,
-0.3757974505,
0.4339389801,
-0.0978652909,
-0.3770108521,
0.045554202,
-0.0735115483,
0.0028513835,
0.3280913234,
-0.4320271313,
-0.0983475745,
-0.3765000403,
0.5410792232,
-0.3062829375,
0.194680661,
0.0396606363,
-0.0675368235,
-0.0794731826,
-0.0233076364,
-0.085149318,
-0.0072275037,
0.1908590496,
0.3523198962,
0.1263819188,
0.2312514633,
-0.0810244158,
0.11559356,
0.1947385371,
0.1424223334,
0.4200140536,
-0.0924703181,
0.2850717902,
-0.1047578231,
-0.0533397794,
-0.0980366692,
-0.1075427681,
-0.1674192399,
0.2470464557,
-0.0184311438,
-0.1849405915,
-0.0807927027,
-0.1951981783,
-0.4651195407,
-0.2075722218,
0.0574503765,
0.0589156635,
0.1602445394,
-0.0132292947,
-0.054693006,
0.0316445865,
-0.1284644306,
0.0514668822,
0.2576346099,
0.1376236975,
0.1586131155,
-0.1772044003,
0.143541038,
-0.4153490961,
0.3013409376,
-0.2719990313,
0.1783405244,
-0.0959233865,
0.2039421052,
0.1154715344,
-0.1845635176,
0.5941319466,
-0.2195526958,
0.3889464736,
0.1375601143,
0.1397218108,
0.0553891361,
-0.1787086427,
-0.1591162235,
0.0899572372,
0.1018381491,
0.2580936849,
-0.3964519203,
0.2316053659,
0.1664516777,
0.1830684841,
-0.0526355058,
-0.32474792,
-0.1970169991,
-0.5626170635,
-0.2390076667,
0.0165660009,
0.0660000667,
0.3151394725,
-0.1389137208,
0.1314137727,
-0.0549560189,
-0.1673580557,
0.0257362016,
-0.1238389462,
0.2914531231,
0.1203575879,
0.2208614349,
0.2079521716,
-0.0736903474,
-0.0236937776,
0.7968281507,
0.1111309901,
-0.3448218703,
0.1094036996,
-0.0630303174,
-0.0907483548,
0.2092819512,
-0.3266681135,
-0.2019654065,
-0.0000301455,
0.1876703352,
-0.0053782822,
0.016149547,
0.0787550285,
-0.0804265738,
-0.0525682308,
-0.3258219957,
0.6423517466,
0.1330873519,
-0.078893885,
0.457218349,
-0.0628391951,
-0.2809722722,
0.302823931,
-0.0614192188,
0.674405098,
-0.2074631006,
0.00626485,
0.2989005446,
-0.2328980267,
0.4780514538,
-0.0521135181,
0.0752845928,
-0.4610928595,
-0.1191899106,
0.0464383811,
-0.1367785186,
0.1565551758,
0.2056341618,
-0.3285841942,
0.2294414043,
-0.2635014653,
0.0411225036,
0.2386642247,
0.2831478715,
-0.4382478297,
-0.1093409508,
-0.294449836,
0.2128226757,
-0.2652935982,
0.5029411912,
-0.0922181755,
-0.1172888801,
-0.3791992068,
-0.4068582058,
-0.3460422158,
0.2422224432,
-0.2425498068,
0.1109371334,
-0.1323486716,
-0.3450956345,
0.0405500978,
0.0373903476,
0.1874451041,
0.2531139255,
-0.2236551791,
0.222467348,
-0.021124471,
-0.0206376854,
0.126280874,
0.0536437556,
0.1209004521,
0.0031680651,
0.0083963647,
0.0582263842,
-0.1437630653,
-0.2783736587,
0.1079577729,
0.0431331098,
-0.0722398832,
-0.0930835307,
-0.1362005323,
-0.3472467959,
0.0720216483,
-0.16148597,
0.1262127757,
0.1170986965,
0.2293575555,
0.0001288123,
-0.0441695936,
-0.255025059,
-0.1353898495,
0.4048899412,
-0.1570873559,
-0.1100188121,
0.2982642055,
0.2103372514,
-0.0321137495,
-0.1437608898,
0.0326506793,
-0.2303508967,
-0.3998271823,
0.4188895226,
-0.2503899336,
0.2387252301,
-0.3252814412,
0.1407638788,
0.119808875,
-0.0347978398,
0.2385182977,
-0.581230104,
-0.1436620355,
-0.0061093466,
-0.1386784315,
0.180455327,
-0.0270741601,
-0.0641653091,
0.2751458585,
-0.2976421416,
-0.3121730387,
0.1425504982,
-0.2980720401,
-0.2433869839,
0.4069213867,
0.0338501036,
0.3514270484,
0.0330442786,
0.2212505192,
0.0531475432,
-0.0231196918,
-0.2581776083,
-0.0759356618,
0.0996251777,
-0.1369615048,
-0.0495095216,
0.2458820641,
-0.2069416344,
-0.2828221917,
0.1267895252,
0.1550593972,
0.1226731762,
-0.0005350636,
-0.2239402533,
0.114474386,
0.1906476766,
-0.3373761773,
0.1662783027,
-0.3700557351,
0.0994457006,
-0.0703751519,
0.1960230768,
-0.0635828376,
0.0812006295,
-0.3058228791,
-0.2660926878,
-0.0109472014,
0.1469589621,
0.2719492316,
-0.2939621508,
-0.2045081556,
0.0314209349,
0.1434335262,
0.3744244874,
-0.4239740074,
-0.0489243828,
0.0730318949,
0.19796817,
-0.1849910766,
-0.057120584,
-0.0592719726,
0.0082338536,
-0.0164727867,
0.1056926474,
0.1547726095,
-0.0033404764,
-0.2006566674,
0.0100804744,
0.6570011973,
0.1752971113,
0.0270172823,
0.3850589693,
0.0233307742,
0.1239538342,
0.2832896411,
0.0459709875,
-0.0223147012,
0.4396225512,
-0.0504779071,
-0.1335068047,
-0.1743731499,
-0.0119659863,
0.0042828009,
-0.3351182342,
0.0757922456,
0.2811041772,
-0.151292786,
0.0644628704,
0.1218860745,
0.3900282085,
-0.4427158237,
0.0342355371,
-0.1804965883,
0.2151076049,
-0.0027280068,
0.1524378657,
0.0196515787,
-0.0512802899,
-0.4637365937,
0.2973272502,
-0.1109528765,
-0.1784162819,
0.3278419971,
0.1989335269,
-0.1134979203,
-0.1596430987,
-0.3788303733,
0.0923645198,
0.0458245017,
-0.4186378419,
0.2045313567,
0.2281176299,
-0.0769743249,
0.0767430067,
0.2434875816,
0.4869220257,
0.1680266261,
0.1220679134,
-0.1336020529,
-0.0036336568,
-0.0551223345,
-0.0423396677,
0.0178034939,
0.1073997542,
-0.0388363861,
0.3513838351,
0.205718264,
-0.2051291317,
0.039958369,
0.0511400364,
-0.0289697759,
-0.1343516558,
0.3138986528,
-0.3455215991,
-0.08757177,
-0.2171858847,
-0.0513285436,
-0.2142635137,
0.0458263345,
-0.018530786,
0.2594949901,
0.0478549078,
-0.0549204834,
0.0884926096,
0.0377769247,
0.2976367474,
0.3341208994,
0.1209082827,
-0.2648687065,
-0.3004694283,
-0.6649755836,
0.070399411,
-0.1858363599,
-0.0878621265,
0.1080959812,
0.1650424898,
-0.2850914001,
0.1554919928,
0.15975146,
0.3603071272,
-0.0145675885,
0.1925240159,
-0.1731229424,
-0.2458997518,
0.3004636168,
-0.1998405606,
-0.1391913146,
-0.4236563444,
0.2776136994,
-0.3155619204,
0.1364343464,
-0.267395556,
-0.1899685264,
0.0373907723,
-0.144747138,
0.669269681,
0.0729983971,
0.362126708,
-0.1162695438,
-0.54294765,
-0.3984391093,
-0.0250897985,
-0.0677857772,
0.2849219143,
-0.0472931005,
0.5349885225,
0.1111853942,
-0.0518118963,
-0.2850215137,
0.3580045998,
0.078401491,
0.0194908064,
-0.2955948412,
0.1473933309,
-0.1806369126,
0.2493708134,
0.1257130951,
0.1924650371,
-0.0530028753,
0.1355544031,
-0.3248472214,
-0.5054667592,
0.3653924167,
-0.1721520573,
-0.3038915992,
0.0407400019,
0.1347826868,
0.1327940077,
-0.1150985733,
-0.2983288169,
0.1924623847,
0.3338205218,
-0.1202746257,
-0.1841252595,
0.2295880318,
-0.1024255008,
-0.046189785,
0.087924026,
0.195561409,
0.0866081715,
-0.0872031897,
0.1778777093,
-0.1123300418
] |
https://github.com/huggingface/datasets/issues/3345 | Failed to download species_800 from Google Drive zip file | @mariosasko
> the dataset is downloaded normally on my machine. Maybe the URL was down at the time of your download. Could you try again?
I've tried yet again just a moment ago. This time I realize that, the step `(... post-processed: Unknown size, total: 20.89 MiB) to /Users/mike/.cache/huggingface/datasets/species800/species_800/1.0.0/532167f0bb8fbc0d77d6d03c4fd642c8c55527b9c5f2b1da77f3d00b0e559976...` and the one after seem unstable. If I want to retry, I will have to delete it (and probably other cache lock files). It **_sometimes_** works.
But I didn't try `download_mode="force_redownload"` yet.
Anyway, I suppose this isn't really a pressing issue for the time being, so I'm going to close this. Thank you.
| ## Describe the bug
One can manually download the zip file on Google Drive, but `load_dataset()` cannot.
related: #3248
## Steps to reproduce the bug
```shell
> python
Python 3.7.12 (default, Sep 5 2021, 08:34:29)
[Clang 11.0.3 (clang-1103.0.32.62)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
```
```python
>>> from datasets import load_dataset
>>> s800 = load_dataset("species_800")
```
## Expected results
species_800 downloaded.
## Actual results
```shell
Downloading: 5.68kB [00:00, 1.22MB/s]
Downloading: 2.70kB [00:00, 691kB/s]
Downloading and preparing dataset species800/species_800 (download: 17.36 MiB, generated: 3.53 MiB, post-processed: Unknown size, total: 20.89 MiB) to /Users/mike/.cache/huggingface/datasets/species800/species_800/1.0.0/532167f0bb8fbc0d77d6d03c4fd642c8c55527b9c5f2b1da77f3d00b0e559976...
0%| | 0/1 [00:00<?, ?it/s]Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/load.py", line 1632, in load_dataset
use_auth_token=use_auth_token,
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/builder.py", line 608, in download_and_prepare
dl_manager=dl_manager, verify_infos=verify_infos, **download_and_prepare_kwargs
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/builder.py", line 675, in _download_and_prepare
split_generators = self._split_generators(dl_manager, **split_generators_kwargs)
File "/Users/mike/.cache/huggingface/modules/datasets_modules/datasets/species_800/532167f0bb8fbc0d77d6d03c4fd642c8c55527b9c5f2b1da77f3d00b0e559976/species_800.py", line 104, in _split_generators
downloaded_files = dl_manager.download_and_extract(urls_to_download)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/download_manager.py", line 284, in download_and_extract
return self.extract(self.download(url_or_urls))
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/download_manager.py", line 197, in download
download_func, url_or_urls, map_tuple=True, num_proc=download_config.num_proc, disable_tqdm=False
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/py_utils.py", line 209, in map_nested
for obj in utils.tqdm(iterable, disable=disable_tqdm)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/py_utils.py", line 209, in <listcomp>
for obj in utils.tqdm(iterable, disable=disable_tqdm)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/py_utils.py", line 143, in _single_map_nested
return function(data_struct)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/download_manager.py", line 217, in _download
return cached_path(url_or_filename, download_config=download_config)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/file_utils.py", line 305, in cached_path
use_auth_token=download_config.use_auth_token,
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/file_utils.py", line 594, in get_from_cache
raise ConnectionError("Couldn't reach {}".format(url))
ConnectionError: Couldn't reach https://drive.google.com/u/0/uc?id=1OletxmPYNkz2ltOr9pyT0b0iBtUWxslh&export=download/
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.14,0 1.15.0, 1.16.1
- Platform: macOS Catalina 10.15.7
- Python version: 3.7.12
- PyArrow version: 6.0.1
| 102 | Failed to download species_800 from Google Drive zip file
## Describe the bug
One can manually download the zip file on Google Drive, but `load_dataset()` cannot.
related: #3248
## Steps to reproduce the bug
```shell
> python
Python 3.7.12 (default, Sep 5 2021, 08:34:29)
[Clang 11.0.3 (clang-1103.0.32.62)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
```
```python
>>> from datasets import load_dataset
>>> s800 = load_dataset("species_800")
```
## Expected results
species_800 downloaded.
## Actual results
```shell
Downloading: 5.68kB [00:00, 1.22MB/s]
Downloading: 2.70kB [00:00, 691kB/s]
Downloading and preparing dataset species800/species_800 (download: 17.36 MiB, generated: 3.53 MiB, post-processed: Unknown size, total: 20.89 MiB) to /Users/mike/.cache/huggingface/datasets/species800/species_800/1.0.0/532167f0bb8fbc0d77d6d03c4fd642c8c55527b9c5f2b1da77f3d00b0e559976...
0%| | 0/1 [00:00<?, ?it/s]Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/load.py", line 1632, in load_dataset
use_auth_token=use_auth_token,
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/builder.py", line 608, in download_and_prepare
dl_manager=dl_manager, verify_infos=verify_infos, **download_and_prepare_kwargs
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/builder.py", line 675, in _download_and_prepare
split_generators = self._split_generators(dl_manager, **split_generators_kwargs)
File "/Users/mike/.cache/huggingface/modules/datasets_modules/datasets/species_800/532167f0bb8fbc0d77d6d03c4fd642c8c55527b9c5f2b1da77f3d00b0e559976/species_800.py", line 104, in _split_generators
downloaded_files = dl_manager.download_and_extract(urls_to_download)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/download_manager.py", line 284, in download_and_extract
return self.extract(self.download(url_or_urls))
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/download_manager.py", line 197, in download
download_func, url_or_urls, map_tuple=True, num_proc=download_config.num_proc, disable_tqdm=False
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/py_utils.py", line 209, in map_nested
for obj in utils.tqdm(iterable, disable=disable_tqdm)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/py_utils.py", line 209, in <listcomp>
for obj in utils.tqdm(iterable, disable=disable_tqdm)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/py_utils.py", line 143, in _single_map_nested
return function(data_struct)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/download_manager.py", line 217, in _download
return cached_path(url_or_filename, download_config=download_config)
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/file_utils.py", line 305, in cached_path
use_auth_token=download_config.use_auth_token,
File "/Users/mike/Library/Caches/pypoetry/virtualenvs/promptsource-hsdAcWsQ-py3.7/lib/python3.7/site-packages/datasets/utils/file_utils.py", line 594, in get_from_cache
raise ConnectionError("Couldn't reach {}".format(url))
ConnectionError: Couldn't reach https://drive.google.com/u/0/uc?id=1OletxmPYNkz2ltOr9pyT0b0iBtUWxslh&export=download/
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.14,0 1.15.0, 1.16.1
- Platform: macOS Catalina 10.15.7
- Python version: 3.7.12
- PyArrow version: 6.0.1
@mariosasko
> the dataset is downloaded normally on my machine. Maybe the URL was down at the time of your download. Could you try again?
I've tried yet again just a moment ago. This time I realize that, the step `(... post-processed: Unknown size, total: 20.89 MiB) to /Users/mike/.cache/huggingface/datasets/species800/species_800/1.0.0/532167f0bb8fbc0d77d6d03c4fd642c8c55527b9c5f2b1da77f3d00b0e559976...` and the one after seem unstable. If I want to retry, I will have to delete it (and probably other cache lock files). It **_sometimes_** works.
But I didn't try `download_mode="force_redownload"` yet.
Anyway, I suppose this isn't really a pressing issue for the time being, so I'm going to close this. Thank you.
| [
-0.3141798079,
-0.0384752676,
-0.0492311679,
0.202085346,
0.1646693647,
0.1617155075,
0.2258754224,
0.2475837171,
0.1551792473,
-0.010348252,
-0.1063770503,
0.2193597704,
-0.0180688519,
0.2488591969,
0.2162835598,
-0.0912972242,
-0.1193725467,
-0.0873610005,
0.1564017832,
0.04595346,
-0.3997566104,
0.3511322141,
-0.1499847621,
-0.1370418817,
0.102524288,
-0.0809271038,
-0.0141765112,
0.4140371382,
-0.1233640835,
-0.359628588,
0.2946698666,
-0.047692664,
0.1257543415,
0.3042757511,
-0.0001109521,
-0.0142269917,
0.5148410797,
0.066041179,
-0.5604020953,
-0.2934931815,
0.1227299348,
-0.1425184011,
-0.0646062344,
-0.2044624388,
0.1588469148,
-0.1592077017,
0.1022412628,
-0.3952917755,
0.3530472219,
0.305457145,
0.2533213496,
0.1408454329,
0.3898606598,
-0.166494146,
0.4034855962,
-0.0750306249,
-0.0450003482,
0.6451201439,
0.0823446363,
0.2718516886,
0.0425242148,
-0.0295167137,
0.0881071314,
0.0383990109,
0.0006941779,
0.074087061,
-0.2062598467,
-0.3297934234,
0.2224153578,
-0.0045587039,
0.4395232201,
-0.2389552146,
-0.4470049739,
-0.1738799214,
0.1314548403,
-0.4225739837,
0.4308348,
0.2705187798,
-0.1549898237,
0.0667553097,
-0.1866744459,
0.0041195322,
-0.0480876602,
0.0420016423,
-0.3033825457,
0.1795377731,
-0.1598045081,
0.1286745071,
-0.0108467704,
0.1046244055,
0.0993992761,
-0.2571163774,
-0.1561887711,
0.2032140493,
-0.375210315,
0.1464049816,
0.1148997992,
0.1149308681,
0.3292046189,
0.3075514138,
-0.1292122602,
-0.123900272,
-0.2372218817,
0.1114827693,
0.1988593638,
0.4007110894,
-0.1291655302,
0.0336219519,
0.2132978141,
0.3256240189,
0.0072206748,
-0.0009814486,
0.076609768,
-0.2363764346,
0.227457121,
0.1388336718,
0.455157578,
-0.0762315392,
-0.4224095643,
0.1605560482,
-0.4209617376,
-0.0498061925,
-0.1374264061,
0.1001048163,
-0.1145350039,
-0.0005766343,
0.1056683585,
0.210258767,
0.0547824241,
-0.2062687427,
-0.2014166117,
0.1310752332,
-0.0948300585,
-0.0711653978,
0.2246997803,
-0.3604337275,
0.2049078643,
0.0555513129,
-0.0399491489,
-0.1359736174,
-0.0607879423,
-0.1023945287,
-0.3439168632,
0.4209779799,
0.2723086774,
0.209945336,
0.0565683804,
-0.09603329,
-0.046122659,
0.0073451865,
-0.2212390304,
-0.0100188265,
-0.1647759676,
0.2118282467,
-0.2752349973,
-0.0880683735,
-0.3080986738,
-0.0777450651,
-0.1111669838,
0.0707625821,
-0.0259706788,
-0.058842808,
-0.2825124562,
-0.4713051319,
0.1577073783,
0.4734970033,
-0.2767035067,
0.1404643208,
-0.4503751993,
-0.0727281719,
0.3189189434,
0.1745324135,
-0.0535072871,
0.2142744362,
-0.4785751998,
0.2197947353,
0.2282408774,
-0.1628597677,
-0.5239959359,
0.2947417796,
-0.3254170418,
0.3206422627,
-0.0717684999,
-0.0690486208,
-0.0034134323,
0.1464300901,
0.1481629014,
0.4415034056,
-0.0463459082,
0.0235596057,
-0.2104187608,
-0.346362412,
0.0896225721,
0.3526124358,
0.0403664187,
0.1935520917,
0.3988821805,
-0.4314284027,
0.243265599,
-0.0537186377,
0.0368759148,
0.3293354213,
0.2900213301,
0.0741828308,
-0.0295129474,
-0.1137086228,
-0.8161108494,
0.3076701164,
-0.1643370539,
-0.0674317703,
-0.3801318407,
-0.0504241213,
-0.6161767244,
-0.0091839051,
-0.079606846,
-0.0979320332,
0.1177890077,
0.2380366623,
0.1952967942,
0.2244134396,
0.0221685208,
0.469276011,
0.0749241561,
0.2263448685,
-0.2785495222,
0.1771832258,
-0.0874420851,
-0.2783634067,
0.2419015616,
-0.1988477409,
0.1234325394,
-0.1083585322,
-0.2305093557,
0.3897269666,
-0.0546177961,
0.048146002,
-0.0299875215,
-0.1138609201,
0.1726948023,
-0.1660008878,
0.0772402585,
0.2172893435,
0.2041255981,
0.0600207336,
-0.5396811366,
0.186011076,
0.0372098871,
-0.0587153919,
-0.1854600608,
0.2006866336,
0.1545967758,
-0.1571740061,
0.1069497466,
0.2504680753,
0.3380044401,
0.0964783728,
0.7787850499,
-0.2652098536,
-0.1462592483,
0.0975311473,
0.3151348233,
-0.027911244,
0.1542780399,
0.2826802135,
-0.1724483222,
-0.1511733383,
0.0681392103,
0.4547289014,
0.5494405627,
0.1251671761,
0.363150686,
0.1061129868,
-0.0100027155,
-0.1754012257,
0.1537657082,
0.0370990261,
-0.0280965865,
0.0848379657,
0.2686849833,
0.0387531854,
-0.2527611256,
-0.0342042558,
0.0901519582,
0.1206785589,
-0.327927798,
0.2239741236,
-0.0853879675,
0.0961753204,
-0.0142297158,
0.3047954738,
-0.2716308534,
-0.3072175682,
-0.326221168,
0.3114142716,
0.0292224996,
-0.0398435816,
0.0980323777,
0.0405011252,
0.2946369648,
-0.3845742643,
-0.2616502643,
0.2500508726,
-0.2786937058,
0.0765002593,
0.352104336,
-0.1339194924,
0.4593881965,
0.0032710116,
0.0486195609,
-0.5828670859,
-0.3285715878,
0.0445327535,
-0.0769553706,
0.414881438,
0.2503486872,
0.2806973457,
-0.1553096324,
0.0032504173,
0.2041029483,
-0.1057123914,
-0.2289656401,
0.0168741159,
-0.0265190881,
0.1165464744,
-0.2804705501,
-0.2161669284,
-0.1667933315,
-0.2883911729,
0.4418581128,
0.270749718,
0.0808251426,
0.2550257146,
-0.0025097148,
0.1105968133,
0.2118404955,
-0.1537091434,
-0.308970958,
-0.3757974505,
0.4339389801,
-0.0978652909,
-0.3770108521,
0.045554202,
-0.0735115483,
0.0028513835,
0.3280913234,
-0.4320271313,
-0.0983475745,
-0.3765000403,
0.5410792232,
-0.3062829375,
0.194680661,
0.0396606363,
-0.0675368235,
-0.0794731826,
-0.0233076364,
-0.085149318,
-0.0072275037,
0.1908590496,
0.3523198962,
0.1263819188,
0.2312514633,
-0.0810244158,
0.11559356,
0.1947385371,
0.1424223334,
0.4200140536,
-0.0924703181,
0.2850717902,
-0.1047578231,
-0.0533397794,
-0.0980366692,
-0.1075427681,
-0.1674192399,
0.2470464557,
-0.0184311438,
-0.1849405915,
-0.0807927027,
-0.1951981783,
-0.4651195407,
-0.2075722218,
0.0574503765,
0.0589156635,
0.1602445394,
-0.0132292947,
-0.054693006,
0.0316445865,
-0.1284644306,
0.0514668822,
0.2576346099,
0.1376236975,
0.1586131155,
-0.1772044003,
0.143541038,
-0.4153490961,
0.3013409376,
-0.2719990313,
0.1783405244,
-0.0959233865,
0.2039421052,
0.1154715344,
-0.1845635176,
0.5941319466,
-0.2195526958,
0.3889464736,
0.1375601143,
0.1397218108,
0.0553891361,
-0.1787086427,
-0.1591162235,
0.0899572372,
0.1018381491,
0.2580936849,
-0.3964519203,
0.2316053659,
0.1664516777,
0.1830684841,
-0.0526355058,
-0.32474792,
-0.1970169991,
-0.5626170635,
-0.2390076667,
0.0165660009,
0.0660000667,
0.3151394725,
-0.1389137208,
0.1314137727,
-0.0549560189,
-0.1673580557,
0.0257362016,
-0.1238389462,
0.2914531231,
0.1203575879,
0.2208614349,
0.2079521716,
-0.0736903474,
-0.0236937776,
0.7968281507,
0.1111309901,
-0.3448218703,
0.1094036996,
-0.0630303174,
-0.0907483548,
0.2092819512,
-0.3266681135,
-0.2019654065,
-0.0000301455,
0.1876703352,
-0.0053782822,
0.016149547,
0.0787550285,
-0.0804265738,
-0.0525682308,
-0.3258219957,
0.6423517466,
0.1330873519,
-0.078893885,
0.457218349,
-0.0628391951,
-0.2809722722,
0.302823931,
-0.0614192188,
0.674405098,
-0.2074631006,
0.00626485,
0.2989005446,
-0.2328980267,
0.4780514538,
-0.0521135181,
0.0752845928,
-0.4610928595,
-0.1191899106,
0.0464383811,
-0.1367785186,
0.1565551758,
0.2056341618,
-0.3285841942,
0.2294414043,
-0.2635014653,
0.0411225036,
0.2386642247,
0.2831478715,
-0.4382478297,
-0.1093409508,
-0.294449836,
0.2128226757,
-0.2652935982,
0.5029411912,
-0.0922181755,
-0.1172888801,
-0.3791992068,
-0.4068582058,
-0.3460422158,
0.2422224432,
-0.2425498068,
0.1109371334,
-0.1323486716,
-0.3450956345,
0.0405500978,
0.0373903476,
0.1874451041,
0.2531139255,
-0.2236551791,
0.222467348,
-0.021124471,
-0.0206376854,
0.126280874,
0.0536437556,
0.1209004521,
0.0031680651,
0.0083963647,
0.0582263842,
-0.1437630653,
-0.2783736587,
0.1079577729,
0.0431331098,
-0.0722398832,
-0.0930835307,
-0.1362005323,
-0.3472467959,
0.0720216483,
-0.16148597,
0.1262127757,
0.1170986965,
0.2293575555,
0.0001288123,
-0.0441695936,
-0.255025059,
-0.1353898495,
0.4048899412,
-0.1570873559,
-0.1100188121,
0.2982642055,
0.2103372514,
-0.0321137495,
-0.1437608898,
0.0326506793,
-0.2303508967,
-0.3998271823,
0.4188895226,
-0.2503899336,
0.2387252301,
-0.3252814412,
0.1407638788,
0.119808875,
-0.0347978398,
0.2385182977,
-0.581230104,
-0.1436620355,
-0.0061093466,
-0.1386784315,
0.180455327,
-0.0270741601,
-0.0641653091,
0.2751458585,
-0.2976421416,
-0.3121730387,
0.1425504982,
-0.2980720401,
-0.2433869839,
0.4069213867,
0.0338501036,
0.3514270484,
0.0330442786,
0.2212505192,
0.0531475432,
-0.0231196918,
-0.2581776083,
-0.0759356618,
0.0996251777,
-0.1369615048,
-0.0495095216,
0.2458820641,
-0.2069416344,
-0.2828221917,
0.1267895252,
0.1550593972,
0.1226731762,
-0.0005350636,
-0.2239402533,
0.114474386,
0.1906476766,
-0.3373761773,
0.1662783027,
-0.3700557351,
0.0994457006,
-0.0703751519,
0.1960230768,
-0.0635828376,
0.0812006295,
-0.3058228791,
-0.2660926878,
-0.0109472014,
0.1469589621,
0.2719492316,
-0.2939621508,
-0.2045081556,
0.0314209349,
0.1434335262,
0.3744244874,
-0.4239740074,
-0.0489243828,
0.0730318949,
0.19796817,
-0.1849910766,
-0.057120584,
-0.0592719726,
0.0082338536,
-0.0164727867,
0.1056926474,
0.1547726095,
-0.0033404764,
-0.2006566674,
0.0100804744,
0.6570011973,
0.1752971113,
0.0270172823,
0.3850589693,
0.0233307742,
0.1239538342,
0.2832896411,
0.0459709875,
-0.0223147012,
0.4396225512,
-0.0504779071,
-0.1335068047,
-0.1743731499,
-0.0119659863,
0.0042828009,
-0.3351182342,
0.0757922456,
0.2811041772,
-0.151292786,
0.0644628704,
0.1218860745,
0.3900282085,
-0.4427158237,
0.0342355371,
-0.1804965883,
0.2151076049,
-0.0027280068,
0.1524378657,
0.0196515787,
-0.0512802899,
-0.4637365937,
0.2973272502,
-0.1109528765,
-0.1784162819,
0.3278419971,
0.1989335269,
-0.1134979203,
-0.1596430987,
-0.3788303733,
0.0923645198,
0.0458245017,
-0.4186378419,
0.2045313567,
0.2281176299,
-0.0769743249,
0.0767430067,
0.2434875816,
0.4869220257,
0.1680266261,
0.1220679134,
-0.1336020529,
-0.0036336568,
-0.0551223345,
-0.0423396677,
0.0178034939,
0.1073997542,
-0.0388363861,
0.3513838351,
0.205718264,
-0.2051291317,
0.039958369,
0.0511400364,
-0.0289697759,
-0.1343516558,
0.3138986528,
-0.3455215991,
-0.08757177,
-0.2171858847,
-0.0513285436,
-0.2142635137,
0.0458263345,
-0.018530786,
0.2594949901,
0.0478549078,
-0.0549204834,
0.0884926096,
0.0377769247,
0.2976367474,
0.3341208994,
0.1209082827,
-0.2648687065,
-0.3004694283,
-0.6649755836,
0.070399411,
-0.1858363599,
-0.0878621265,
0.1080959812,
0.1650424898,
-0.2850914001,
0.1554919928,
0.15975146,
0.3603071272,
-0.0145675885,
0.1925240159,
-0.1731229424,
-0.2458997518,
0.3004636168,
-0.1998405606,
-0.1391913146,
-0.4236563444,
0.2776136994,
-0.3155619204,
0.1364343464,
-0.267395556,
-0.1899685264,
0.0373907723,
-0.144747138,
0.669269681,
0.0729983971,
0.362126708,
-0.1162695438,
-0.54294765,
-0.3984391093,
-0.0250897985,
-0.0677857772,
0.2849219143,
-0.0472931005,
0.5349885225,
0.1111853942,
-0.0518118963,
-0.2850215137,
0.3580045998,
0.078401491,
0.0194908064,
-0.2955948412,
0.1473933309,
-0.1806369126,
0.2493708134,
0.1257130951,
0.1924650371,
-0.0530028753,
0.1355544031,
-0.3248472214,
-0.5054667592,
0.3653924167,
-0.1721520573,
-0.3038915992,
0.0407400019,
0.1347826868,
0.1327940077,
-0.1150985733,
-0.2983288169,
0.1924623847,
0.3338205218,
-0.1202746257,
-0.1841252595,
0.2295880318,
-0.1024255008,
-0.046189785,
0.087924026,
0.195561409,
0.0866081715,
-0.0872031897,
0.1778777093,
-0.1123300418
] |
https://github.com/huggingface/datasets/issues/3341 | Mirror the canonical datasets to the Hugging Face Hub | I created a GitHub project to keep track of what needs to be done:
https://github.com/huggingface/datasets/projects/3
I also store my code in a (private for now) repository at https://github.com/huggingface/mirror_canonical_datasets_on_hub | - [ ] create a repo on https://hf.co/datasets for every canonical dataset
- [ ] on every commit related to a dataset, update the hf.co repo
See https://github.com/huggingface/moon-landing/pull/1562
@SBrandeis: I let you edit this description if needed to precise the intent. | 28 | Mirror the canonical datasets to the Hugging Face Hub
- [ ] create a repo on https://hf.co/datasets for every canonical dataset
- [ ] on every commit related to a dataset, update the hf.co repo
See https://github.com/huggingface/moon-landing/pull/1562
@SBrandeis: I let you edit this description if needed to precise the intent.
I created a GitHub project to keep track of what needs to be done:
https://github.com/huggingface/datasets/projects/3
I also store my code in a (private for now) repository at https://github.com/huggingface/mirror_canonical_datasets_on_hub | [
-0.1399023533,
-0.2282226682,
-0.0447379313,
-0.0688015744,
-0.0952057987,
-0.0315396152,
0.2022988647,
0.3611529469,
0.2504813671,
0.2474522144,
-0.2225716561,
-0.0466736741,
-0.0990656614,
0.4645624757,
0.1602292359,
0.1148871407,
0.1948557794,
0.1492443234,
-0.3303130269,
-0.140197888,
-0.1915594488,
0.0548464246,
0.2164632827,
-0.1970640868,
-0.1881078333,
0.0603792444,
-0.1895807832,
0.1143200099,
0.0295007266,
-0.195064038,
0.1445318013,
0.550965488,
-0.0402589403,
0.4087873995,
-0.0001033234,
-0.1346433312,
-0.0946487337,
0.0361322798,
-0.2100019604,
0.2130617052,
0.0192187596,
0.0149118975,
-0.0886831954,
-0.1156553477,
-0.3502187729,
0.0998078585,
0.0849433169,
-0.0077919308,
0.612603724,
-0.1101512164,
0.275631845,
0.4718466103,
-0.0116705447,
-0.2119522244,
-0.0439753979,
0.4008793831,
-0.0202868711,
0.3190156817,
0.0643485785,
-0.0014483354,
-0.2037808299,
0.475446701,
0.1577782482,
-0.0874233693,
0.3538532555,
-0.0237654112,
-0.0397568382,
-0.1200760975,
-0.0564736836,
0.0358121321,
-0.0637293905,
-0.4478740692,
-0.3752834499,
-0.2629746199,
-0.08316385,
-0.1694615334,
-0.1591475755,
0.0379360691,
0.0586952344,
-0.0244181082,
-0.2698394954,
-0.4513089955,
-0.0766887367,
-0.0690581426,
0.0347738415,
0.0571262725,
-0.0905395895,
-0.1093541309,
0.1155042201,
-0.0496156216,
-0.2794249356,
-0.0523725897,
0.1169926748,
-0.0595500655,
-0.0034450118,
-0.3342265189,
-0.0795748532,
0.1460089386,
0.4641376734,
0.2129013538,
-0.1246608868,
0.1348952204,
-0.1669301987,
0.1390659064,
0.0510974787,
-0.0208208766,
-0.065281041,
-0.145249635,
0.4058584273,
0.2648104727,
-0.0449075215,
0.1653912961,
0.017110927,
0.1916995049,
-0.2810346186,
-0.1849981993,
0.133823365,
-0.3072552383,
0.0896307975,
0.0109799672,
0.0926088393,
0.0686038435,
-0.1082748622,
0.2600431442,
0.0268181134,
-0.016263783,
0.070961155,
0.0085892957,
-0.1388668865,
-0.1898212433,
-0.3074091971,
-0.0752348527,
-0.0117042474,
0.4674015939,
0.1131271198,
-0.3167950213,
0.2366051078,
0.0132524502,
0.5471705794,
0.019607367,
-0.1153745577,
0.2685265541,
-0.1479646116,
0.0516195744,
-0.1125051826,
-0.0726765469,
0.0955703855,
-0.0253882855,
-0.3246184886,
-0.3927954435,
0.0781564564,
-0.2184802592,
-0.0047748075,
0.259488523,
-0.3289781511,
-0.0521656387,
-0.2298799157,
0.1729380488,
-0.2020567209,
0.22690247,
0.0789086521,
0.2411812693,
0.1034420133,
-0.0977744609,
0.3712449372,
0.7181555033,
0.2240888178,
-0.2962021232,
0.308991015,
0.0191898365,
-0.1833182573,
0.274536401,
-0.1124358997,
-0.12903817,
-0.2643851936,
-0.1095258668,
-0.0685845837,
-0.2103895396,
-0.1687702686,
-0.0536149479,
-0.2934253216,
0.0378595665,
0.0605962798,
0.1442464739,
0.0733655244,
-0.2597305775,
-0.1364909559,
0.1940591186,
-0.0286559612,
0.0727795959,
-0.2650986016,
-0.4695101082,
-0.2597595155,
0.3346839845,
0.2301793844,
0.1090826169,
0.1431732178,
0.1876092106,
0.1667765826,
-0.1221534088,
0.2466913313,
0.1588566005,
0.4736773372,
0.1701833755,
-0.0724653006,
-0.147092402,
-0.2138134688,
0.0245010965,
-0.1168464273,
0.0989034548,
0.1524745822,
-0.6598364711,
-0.2047571689,
-0.0484350361,
-0.0828548446,
-0.2082474977,
0.2233775556,
0.3050118089,
0.19699727,
0.006314456,
-0.324336201,
0.4381787479,
-0.1723386496,
0.2119594812,
-0.3341872394,
0.4706757367,
-0.0964093655,
-0.0634111688,
0.2946989834,
0.3115990758,
0.026472576,
-0.3461869061,
0.15563941,
0.2419728488,
-0.3025359213,
0.3067392111,
0.5121623278,
0.3694115877,
0.2330257148,
-0.292722851,
0.1160171181,
0.0945655629,
-0.22200872,
0.082924962,
-0.1982329488,
0.5514416695,
-0.0466557071,
-0.0492703952,
-0.0392460413,
-0.0596488379,
-0.0259299874,
-0.0939503089,
-0.1644390821,
-0.3177976608,
0.0318957344,
-0.1396771073,
0.2996938229,
0.0881457403,
-0.4091950655,
0.2628262043,
0.3407303095,
0.0723773241,
0.0364971906,
0.0720488057,
-0.1174749583,
0.0301617496,
0.1883779615,
-0.1477156878,
-0.0670416281,
0.3184128404,
-0.012251447,
0.324370265,
0.0394374803,
-0.0790637508,
-0.0652415752,
-0.1389977634,
-0.088202171,
-0.0367088802,
0.0709697902,
0.0203162543,
-0.353516221,
-0.052729141,
-0.2075937092,
-0.0995934159,
-0.1265209615,
-0.1090334654,
-0.0529523082,
-0.2740832269,
-0.4831582308,
-0.0451838598,
-0.4293744266,
-0.0575637184,
0.2258362472,
0.1894542426,
-0.0532362945,
0.2586159408,
0.0437617376,
0.4665673077,
-0.1506016552,
-0.0626195446,
-0.2527848482,
-0.0300515592,
0.0647437871,
0.148618117,
0.0087537905,
-0.0962686837,
0.5035098195,
-0.149956733,
0.1034429893,
-0.464330852,
-0.4791470468,
0.0241393726,
-0.1156019643,
-0.2302285284,
0.080373846,
-0.0009891081,
-0.1144005507,
-0.1072421744,
-0.0019781964,
-0.3191399872,
-0.0884397179,
-0.257243216,
-0.1016823426,
0.0148525797,
-0.0970645249,
0.0132962624,
-0.0992896631,
-0.5056049228,
0.308539927,
0.0319680721,
0.1280540377,
-0.0779342577,
-0.0701950788,
0.1173269451,
-0.2701736987,
-0.1916800439,
-0.1832655668,
-0.2178165913,
0.0406893641,
-0.3897846341,
-0.1344101876,
0.0628089458,
-0.0778939724,
0.0769378915,
-0.0639378056,
-0.515750289,
-0.7135968208,
-0.0089077195,
0.323741585,
0.1254696548,
0.2077849358,
0.192958802,
0.0059289704,
-0.1847057641,
-0.0044500637,
-0.279012531,
0.2138218433,
0.1777517498,
-0.0929936394,
0.0460872129,
-0.0708605275,
-0.065419659,
0.4560538828,
0.6146111488,
-0.0961876363,
0.2441710383,
0.1187478974,
0.4676628411,
-0.0517686121,
-0.0545240566,
0.1335539073,
0.1578788161,
0.1002848521,
0.5140282512,
0.1256559789,
0.326200515,
-0.1220476329,
-0.2664565146,
-0.1666927785,
-0.4211669862,
-0.2397913188,
-0.0523459353,
0.2430579513,
-0.1751526296,
-0.1972378939,
0.1549853235,
0.0752772838,
0.4027348459,
0.3217835426,
0.1350094527,
0.110309422,
-0.2279893011,
0.0178970974,
-0.3434245288,
0.3060064018,
-0.1834244728,
-0.0588515364,
-0.1241227388,
-0.0347671732,
-0.0052298922,
-0.161324814,
0.507661283,
-0.0265595578,
0.0959707797,
-0.3405352235,
-0.4307338595,
-0.245881021,
0.2021623701,
-0.0065410309,
-0.0990927592,
-0.0081218937,
0.6480221152,
-0.4897233844,
-0.3599331677,
0.2727825046,
0.0889588073,
-0.1265107244,
0.133055374,
0.0111787263,
-0.3035042286,
-0.2570504546,
0.1533643156,
-0.2030338198,
-0.0739753991,
0.092183955,
0.0033713467,
-0.140220955,
-0.1461009383,
0.1282831877,
0.1249440089,
0.1226571575,
0.2564352751,
0.1391530335,
0.3078390658,
0.0511622652,
0.1718890369,
0.6361913085,
-0.113397643,
-0.3152341545,
-0.2484557182,
0.1717941016,
0.069022119,
0.5813091993,
0.2667126656,
0.3531083167,
0.2000271082,
0.3608621359,
-0.2983387411,
0.109536238,
-0.1485601515,
0.0487097204,
-0.204545334,
-0.1193866059,
0.1945147812,
-0.0937047377,
-0.083405219,
0.0399012603,
0.503811121,
-0.1143048853,
0.214062646,
0.2380134612,
0.989028573,
-0.0302038081,
0.2163103968,
0.0550284721,
-0.3130507469,
0.3550366759,
-0.133269459,
-0.1088198796,
-0.3737487197,
-0.0502001494,
0.0345309302,
0.1007671282,
0.003382721,
-0.1941052377,
-0.2423226982,
0.1759078056,
0.238094449,
0.419206202,
-0.164172709,
0.2004980743,
-0.1440517604,
-0.3520836532,
-0.3815653622,
0.275662899,
-0.0986883268,
0.3733544648,
-0.0955948532,
-0.2765478492,
0.1026359946,
-0.0191034712,
0.0603102632,
-0.0014139152,
-0.1069252342,
-0.1937707663,
0.1098662391,
0.0166731253,
-0.0927766934,
-0.0600429997,
0.6999337077,
0.173927933,
-0.1955553591,
-0.0572814457,
-0.1542628855,
-0.0389704518,
-0.2810975015,
0.0063598673,
0.2197892368,
-0.0718325749,
-0.1835569739,
0.0637910664,
0.2955997586,
-0.1983086169,
-0.2933478057,
-0.1158881783,
-0.2789234519,
0.0335644223,
0.4687604606,
0.2539413273,
-0.0822506174,
-0.1790533066,
0.207608372,
-0.0686694309,
-0.1785226315,
0.009158466,
0.262154758,
-0.0367398523,
-0.2209457308,
0.2614955008,
-0.082072027,
-0.0686694086,
0.0223002136,
0.0212268773,
0.0114599625,
-0.3249545097,
-0.1974633932,
0.3402916193,
-0.4243670106,
0.069017306,
-0.1396691799,
-0.2156922519,
0.1439349353,
0.2201015949,
0.4490905404,
-0.0458871461,
-0.0837510601,
-0.1464511156,
-0.3876766264,
0.3465759754,
0.0311517511,
0.3140193224,
0.2257671207,
0.1658825427,
-0.1649288386,
0.299902916,
-0.493604809,
0.0459582135,
-0.1741528511,
-0.0297681317,
0.1666031182,
-0.222839579,
0.2574187517,
0.0247420799,
0.1748765707,
0.1358647346,
-0.5806103349,
-0.258954227,
-0.2691528201,
0.0753572583,
-0.0892320126,
0.0785390288,
-0.006691555,
0.2052045017,
0.0445133708,
-0.2560144365,
0.4494893253,
-0.0030644457,
-0.0497829914,
0.0522934943,
0.1932918876,
-0.0331123061,
-0.0490094014,
-0.0542999282,
0.39315027,
0.2224264294,
-0.0048413151,
-0.01447846,
-0.3160014749,
-0.1477532834,
0.1693096757,
0.372056216,
0.4015280306,
0.017769631,
0.1417634934,
0.0724607557,
-0.1411540806,
0.1071197391,
0.6487594843,
-0.0478556752,
-0.0464519225,
-0.0414075777,
0.2387631387,
0.3007478714,
-0.2311000228,
-0.1372553855,
0.325546205,
-0.1950747967,
0.2420935333,
0.5243371129,
0.5401988626,
0.0979157761,
0.117917344,
0.1139651462,
0.4956557751,
-0.0157584026,
0.090172857,
0.0907646939,
-0.0018359518,
-0.0631813332,
0.0737333745,
0.4364312589,
0.3332228661,
-0.0666704774,
-0.2168461084,
0.3986555934,
-0.2188325524,
0.0679019913,
0.4345089793,
0.0443349928,
0.2066629529,
0.1648755819,
0.3531227112,
0.0921627656,
-0.1174201071,
0.3947370648,
-0.1519473046,
-0.478543818,
-0.0852364004,
0.3324009478,
0.1344048977,
0.1449956,
0.0161644835,
-0.0361403972,
-0.3376882076,
0.1514297426,
0.1655679941,
-0.5153265595,
0.1904328316,
0.086630024,
0.1030553728,
-0.3396085203,
0.0741639361,
0.1303795278,
0.2890021801,
0.0322767124,
0.1061773002,
0.0602871403,
-0.1244122386,
0.193932429,
0.3119542301,
0.0716371834,
-0.1497938782,
0.0619584136,
0.4056937993,
0.0937814415,
0.0126078883,
-0.1308081597,
-0.2619306147,
-0.2184398174,
-0.2820012271,
0.1779809445,
0.2102434337,
-0.2854185402,
-0.1070709378,
-0.2872100174,
0.0146185337,
-0.1756372005,
0.2839369476,
-0.0356668532,
-0.0373780765,
0.0345163755,
-0.0501580797,
-0.4302805662,
-0.1301438957,
0.0805731192,
-0.1032023132,
0.0253956076,
0.0373907275,
0.1174691617,
0.0311139133,
0.3875575066,
0.1686722785,
0.1012173966,
0.0549155101,
-0.3878116906,
-0.3843784928,
0.2360704988,
0.1400943398,
-0.0776292086,
0.0426419154,
-0.0614682995,
-0.0261548106,
-0.0524865687,
-0.044642292,
-0.2529151738,
0.1379033774,
-0.0974474847,
-0.1766635031,
0.1493365467,
-0.0592393652,
-0.0342769921,
0.2913416922,
-0.0906301588,
0.1111602038,
0.055530306,
0.0618161187,
0.1787401438,
0.3020837903,
-0.0051871594,
-0.534901917,
0.3680496514,
-0.0322127715,
-0.0450133346,
-0.2557497323,
-0.3081435561,
-0.0491418503,
-0.274764657,
-0.4787774384,
0.1290780604,
-0.2805128098,
0.3825716674,
-0.0256527364,
-0.5653016567,
-0.2041245699,
0.2111649364,
0.3130302429,
-0.1337998956,
0.1981332898,
0.2955261469,
-0.181684196,
-0.0765215531,
0.2911252975,
0.4357482791,
0.0360771082,
-0.0023696367,
-0.2444383204,
-0.1634980887,
0.5291973948,
-0.1545636356,
-0.0869566202,
-0.0551072061,
0.3777815104,
0.1581695676,
-0.4270443022,
-0.5805011988,
0.1676480919,
0.0819053799,
0.0962521732,
-0.1066229716,
0.4081889391,
-0.1586284637,
-0.1798069328,
-0.0828202143,
0.0240464397,
0.0367215909,
-0.2051170617,
0.0730194598,
-0.2260536402
] |
https://github.com/huggingface/datasets/issues/3341 | Mirror the canonical datasets to the Hugging Face Hub | I understand that the datasets are mirrored on the Hub now, right? Might I close @lhoestq @SBrandeis? | - [ ] create a repo on https://hf.co/datasets for every canonical dataset
- [ ] on every commit related to a dataset, update the hf.co repo
See https://github.com/huggingface/moon-landing/pull/1562
@SBrandeis: I let you edit this description if needed to precise the intent. | 17 | Mirror the canonical datasets to the Hugging Face Hub
- [ ] create a repo on https://hf.co/datasets for every canonical dataset
- [ ] on every commit related to a dataset, update the hf.co repo
See https://github.com/huggingface/moon-landing/pull/1562
@SBrandeis: I let you edit this description if needed to precise the intent.
I understand that the datasets are mirrored on the Hub now, right? Might I close @lhoestq @SBrandeis? | [
-0.0218214002,
-0.2926822007,
-0.0275672581,
-0.1817803234,
-0.1919669509,
0.0057732016,
0.216266185,
0.2935411334,
0.2686594427,
0.1937051266,
-0.3167091608,
-0.1450394541,
0.0045881737,
0.3757871985,
0.0550457276,
0.1298285872,
0.1976609677,
0.1898720264,
-0.2652083933,
-0.2824346125,
-0.2384757698,
0.0123708388,
0.1730353087,
-0.1519570798,
-0.093828775,
0.0122940456,
-0.1356134415,
0.2138771266,
-0.0551212914,
-0.1670190394,
0.1510976553,
0.6337313652,
-0.0726585463,
0.3463306427,
-0.0001053099,
-0.0973948613,
0.0144190621,
0.0948004425,
-0.2404112816,
0.3264090717,
0.0050093834,
0.0500164554,
-0.0646001622,
-0.1321754605,
-0.2558147609,
0.1050241366,
0.1518677026,
0.0905962139,
0.5624606609,
-0.1270119697,
0.2543605566,
0.4386525452,
0.0299655702,
-0.3103618026,
-0.0414287969,
0.4238120317,
-0.0261311922,
0.3576439023,
0.0475738384,
0.0977611542,
-0.1371967196,
0.4285320342,
0.0065379562,
-0.0360506102,
0.296001941,
-0.0313617624,
0.0644045323,
-0.0579183958,
-0.0268405527,
-0.0102301724,
0.040475931,
-0.3807881474,
-0.35908705,
-0.1884663552,
-0.1839014441,
-0.1905450672,
-0.2730263472,
0.0020521064,
-0.003942579,
0.0795400143,
-0.300011605,
-0.5658153296,
-0.0108987689,
-0.0649695992,
-0.1422231048,
0.1140114143,
-0.0877540335,
-0.0375647694,
0.0703083873,
0.015205388,
-0.3035495877,
0.0074991719,
0.1118225753,
-0.0976149663,
-0.032295756,
-0.348542124,
-0.0638640821,
0.1652539819,
0.4128495455,
0.3043965101,
-0.2273898274,
0.0146060186,
-0.1820361763,
0.0990082547,
-0.0426914394,
0.1156102642,
-0.038052123,
-0.0659449846,
0.2804881632,
0.3567701876,
0.0229426492,
0.1754249632,
0.0347151272,
0.0708048493,
-0.3577210009,
-0.076896213,
0.3003355563,
-0.2974946797,
-0.0276855938,
0.163564384,
0.0752161667,
0.0721251965,
-0.1698843539,
0.2924942374,
0.0735982805,
0.0191696249,
0.1317878217,
-0.0431975089,
-0.2409158945,
-0.1613030136,
-0.3374613822,
-0.0195217449,
-0.0286910329,
0.4527658522,
-0.0279122312,
-0.2202877104,
0.2044320703,
0.0341650546,
0.5450915098,
0.0470953286,
-0.1392822415,
0.253968358,
-0.1160717458,
0.1782584637,
-0.1136857122,
0.1272505075,
0.0902973115,
0.0773172006,
-0.2726747096,
-0.1671631187,
0.0160483271,
-0.1571702808,
-0.0402470753,
0.2682975233,
-0.4291770458,
-0.1025259048,
-0.3170415461,
0.0463068895,
-0.3252805173,
0.1584798992,
0.2011328936,
0.2662881613,
0.13550511,
-0.1291638613,
0.4017511904,
0.6870619655,
0.1591595113,
-0.2488238215,
0.248810634,
0.0117175514,
0.0157248918,
0.3531040847,
-0.1227923408,
-0.0872582942,
-0.2512489259,
-0.0900222957,
-0.1207002774,
-0.1847312748,
-0.1018739715,
-0.0368502997,
-0.3213783205,
0.0844707415,
0.0417047255,
-0.014234595,
0.0449572466,
-0.27356112,
-0.1126333997,
0.0316141099,
-0.0527457483,
-0.042845428,
-0.4392006993,
-0.4809529781,
-0.2098054439,
0.3541742563,
0.2265409976,
0.062011078,
0.0619759671,
0.2830610275,
0.2196985483,
-0.0884099007,
0.2387377024,
0.1584240198,
0.5632195473,
0.0910493731,
-0.1354204416,
-0.0370655693,
-0.2818970978,
0.0016203253,
-0.0459903516,
0.1686670929,
0.2280526161,
-0.5953662992,
-0.3070707321,
-0.0784885138,
-0.1321387887,
-0.314088732,
0.1747407019,
0.2362263799,
0.1078009158,
-0.0034134511,
-0.3685555756,
0.4250988662,
-0.2594370842,
0.2197353542,
-0.3629525006,
0.4800727367,
-0.0724891424,
0.0557169653,
0.0464253947,
0.2748458683,
0.0563068055,
-0.3659335673,
0.198226437,
0.1892869622,
-0.3005182743,
0.3458782136,
0.5258868337,
0.2588586807,
0.2914502621,
-0.3805139661,
0.1299025267,
0.083092913,
-0.2028670311,
0.1108668298,
-0.1950130463,
0.4615956247,
-0.0090223858,
-0.1067106724,
-0.0645100698,
-0.0760198161,
-0.0593145825,
-0.1829431057,
-0.2460245043,
-0.2128321826,
0.1173892617,
-0.0294125918,
0.1833400875,
0.1420514584,
-0.3397107124,
0.2268888056,
0.4386556149,
0.0185125005,
-0.0749196485,
0.0695069432,
-0.0537118278,
0.0584684424,
0.1515891552,
-0.1466594487,
-0.0823470354,
0.2955560982,
-0.0113157183,
0.4402499199,
0.0904372185,
-0.0387270898,
-0.0965715423,
-0.1113953143,
-0.0246220659,
0.0118821878,
0.0491148531,
0.0301627517,
-0.1877589375,
-0.1010331511,
-0.0862021297,
-0.066211313,
-0.1249442697,
-0.2768996358,
0.068246454,
-0.1115698665,
-0.4919812381,
-0.0915015116,
-0.4487619102,
-0.1324346066,
0.2169879675,
0.1636693925,
-0.0669251457,
0.311101228,
0.0834342688,
0.4831862152,
-0.1601680964,
0.0268928576,
-0.2360665053,
0.049643103,
0.093050234,
0.1226129159,
-0.0973443687,
-0.1443714499,
0.3948915005,
-0.1509772241,
0.061091233,
-0.5150555968,
-0.4390874207,
0.0326614939,
-0.1198552623,
-0.2736370862,
0.0401639044,
0.1439701915,
-0.1890547276,
-0.0685721561,
0.0489357784,
-0.2940534353,
-0.0749469176,
-0.2676690221,
-0.1542600691,
0.0336210243,
-0.0516556874,
-0.0469633155,
-0.1099486277,
-0.5106429458,
0.2915963531,
0.0150192352,
0.1118054688,
-0.0178025551,
-0.0577167422,
0.0614601672,
-0.1838100851,
-0.34693259,
-0.258043468,
-0.2924161255,
-0.0466104932,
-0.3319174051,
-0.0370068587,
0.118637152,
0.0211686213,
0.1263956726,
-0.136608094,
-0.4263139069,
-0.8204240799,
-0.0712866858,
0.2312678695,
0.0739469975,
0.2300859839,
0.1596164852,
-0.1323047131,
-0.1988429874,
0.0714449659,
-0.3366409242,
0.171646893,
0.2706881166,
-0.1137542203,
-0.0332694948,
-0.0260625388,
-0.1642004848,
0.5518659353,
0.6206752658,
0.0372574702,
0.0966652408,
0.2313500196,
0.3692435324,
-0.1080571488,
-0.0850097165,
0.1023280844,
0.223929897,
-0.0777845681,
0.4713027477,
0.0840552598,
0.3305986524,
-0.0470091701,
-0.2661803663,
-0.1024172083,
-0.401717484,
-0.2353919894,
-0.0052436534,
0.1728996783,
-0.2528967857,
-0.2505499125,
0.1019809321,
0.0877844468,
0.3063919842,
0.3677116632,
0.0705666617,
0.0740620419,
-0.3127058744,
0.0009270154,
-0.3791626096,
0.3363241255,
-0.3094920516,
0.0034326606,
-0.1050409749,
0.0155809121,
0.0817021132,
-0.2015516162,
0.6067957282,
0.0662026033,
0.1173710227,
-0.3440834284,
-0.3018549979,
-0.2871341705,
0.0885767564,
0.0292379744,
-0.0194761902,
0.0033778662,
0.7058644891,
-0.406789273,
-0.3740426898,
0.3369012475,
-0.0243020579,
-0.0978248864,
0.1089848056,
-0.0744381994,
-0.4136753678,
-0.2542654574,
0.1364701986,
-0.0713644698,
-0.1202220172,
0.0018035515,
0.0470230058,
0.0466986783,
-0.1232610047,
0.1453763545,
0.0361259542,
0.0564222783,
0.3164789677,
0.0709990039,
0.3336903155,
0.0201248769,
0.1010588482,
0.7753582001,
-0.0202491973,
-0.2564119101,
-0.1642632037,
0.1637806296,
0.0604040809,
0.6948400736,
0.2468128204,
0.3408786654,
0.172481522,
0.4956528842,
-0.3051200509,
0.0899293795,
-0.1135964468,
0.0703359395,
-0.3086583316,
-0.084713988,
0.1871122122,
-0.1582247019,
-0.0962942839,
0.0165085923,
0.7106702924,
-0.0564871617,
0.2105633914,
0.1447678953,
1.0647166967,
-0.0555852279,
0.2797975242,
0.0478848368,
-0.309199065,
0.389046818,
-0.237229079,
-0.1476948857,
-0.355586201,
0.0265679657,
0.0571272969,
0.0943193063,
0.0353391282,
-0.2975216508,
-0.2871132791,
0.1061552688,
0.1715763807,
0.3973005116,
-0.0237785429,
0.1828989238,
-0.0364901498,
-0.1953719705,
-0.3216533363,
0.2410639375,
-0.0941856802,
0.4041636884,
-0.1149396375,
-0.1649306864,
0.0309358872,
-0.0068452605,
0.0175880846,
-0.0032266718,
-0.0385741591,
-0.1920199245,
0.132010594,
0.0784281194,
-0.0942510143,
-0.2418949455,
0.7294855714,
0.1592629999,
-0.1621498019,
-0.0011621778,
-0.1566251814,
-0.0591803081,
-0.3138424158,
0.0395376422,
0.2396104038,
-0.0791787878,
-0.2638865411,
0.1612934917,
0.2083791047,
-0.2686733305,
-0.3606295288,
-0.1485975087,
-0.1450478584,
-0.044711642,
0.3346866667,
0.2523461282,
-0.1118493378,
-0.1284445971,
0.1815654635,
-0.0783483014,
-0.2497726828,
-0.0914953277,
0.273152858,
-0.1697188914,
-0.1436728984,
0.2658727765,
0.0209371746,
-0.0915482417,
0.1490493417,
0.0457267128,
0.0157154873,
-0.2974873781,
-0.2507079244,
0.476082772,
-0.5225657821,
0.1281034499,
-0.1785650402,
-0.1415403187,
0.1648405194,
0.1836937964,
0.4674336612,
-0.0399782807,
-0.1403286457,
-0.1864223182,
-0.3216147125,
0.3420345485,
-0.0605624765,
0.349306196,
0.3121605814,
0.2765005827,
-0.1250592023,
0.216037333,
-0.4721601307,
0.1543756723,
-0.3096099198,
-0.0637792274,
0.096327059,
-0.3281147778,
0.2364388555,
-0.0017317998,
0.1499033123,
0.0756104514,
-0.601988554,
-0.2153498232,
-0.2302559763,
0.0918310881,
-0.0458037518,
0.0399513729,
0.080277212,
0.2401284277,
0.1295122504,
-0.0465234183,
0.5299503803,
0.0389461517,
-0.0107423021,
0.1356265843,
0.307859391,
-0.1547781527,
-0.1952047199,
-0.0912948474,
0.4753021598,
0.1368316412,
-0.0950689912,
-0.0356508568,
-0.3100043535,
-0.1387943327,
0.1470579952,
0.3525357842,
0.4026694298,
0.1918292493,
0.1141449511,
0.0425981246,
-0.0346096121,
0.0051393313,
0.6270985603,
-0.1111770496,
-0.0701628253,
-0.0967133343,
0.2152674198,
0.2729760408,
-0.180697754,
-0.0380243137,
0.4682377875,
-0.1295484006,
0.1832825989,
0.4169034958,
0.5480712652,
0.0973582417,
0.2217655033,
0.1264103502,
0.6257138252,
-0.0786210522,
0.1733865887,
0.1773725152,
-0.0683634952,
-0.0060468614,
0.0948261246,
0.3745378256,
0.3080381155,
0.0211794768,
-0.232064262,
0.4543011487,
-0.0380903222,
0.1456534863,
0.4162993431,
-0.1094781011,
0.2219494879,
0.2168457061,
0.3309825063,
0.0926411599,
-0.152114287,
0.3066319525,
-0.0966195613,
-0.5169858336,
-0.0485641211,
0.2878256738,
0.051016435,
0.1154709086,
-0.0088197775,
-0.1240244508,
-0.3409627378,
0.1448242664,
0.0163511541,
-0.4886070788,
0.2300803065,
-0.0339965634,
-0.0148752769,
-0.1757525057,
0.0525566339,
0.0247851517,
0.2449548244,
0.0704144537,
0.0905324221,
0.0517211556,
-0.1820815951,
0.1540605426,
0.3488805294,
0.0592271388,
-0.0866760239,
0.0794627219,
0.4360509515,
0.1795405895,
0.0000487761,
-0.0067457021,
-0.3157811165,
-0.2050717622,
-0.348477155,
0.0381044336,
0.2520003915,
-0.2970354259,
-0.0606533252,
-0.2872273624,
-0.0515922457,
-0.1605934352,
0.2710283101,
-0.0813807994,
-0.0689229369,
0.0442942865,
-0.0105725406,
-0.4657319784,
-0.1488102376,
0.1603946388,
-0.1270540804,
0.0638430044,
0.0616984665,
0.1091911122,
-0.1055470183,
0.3311451375,
0.2800434232,
0.0989661068,
0.0133972373,
-0.3458634913,
-0.2173766345,
0.3066421151,
0.1451249719,
-0.0978314355,
0.2005333453,
-0.0235289987,
-0.0343078449,
-0.1108413637,
-0.0875903964,
-0.238470301,
-0.0025447824,
-0.0994138718,
-0.1409809142,
0.2177417874,
0.0485340282,
-0.0412318595,
0.201878652,
-0.1160671413,
0.1947402954,
0.1395554245,
0.0337982364,
0.215270564,
0.2779577374,
0.1766945124,
-0.4929922819,
0.2101412117,
-0.0246609412,
-0.0475144982,
-0.1632738709,
-0.2676053345,
-0.0896401778,
-0.2133842856,
-0.4116508365,
0.0051597776,
-0.3357595205,
0.3559480906,
0.0398725457,
-0.5045144558,
-0.1957787275,
0.0943268836,
0.247380659,
-0.0505929776,
0.058138188,
0.3418606818,
-0.1692088991,
-0.1343865395,
0.3153551817,
0.4563074708,
0.0918283015,
-0.0650704354,
-0.3788181245,
-0.0765351355,
0.5845479965,
-0.1102514863,
-0.1431554407,
-0.009615154,
0.333629787,
0.089944236,
-0.3159917891,
-0.6316223741,
0.163125515,
0.084057577,
0.0402929112,
-0.1441311091,
0.4407647848,
-0.0847870409,
-0.2513004541,
-0.0191377867,
-0.0495888367,
0.0522270016,
-0.1664751619,
0.0526465923,
-0.2382731587
] |
https://github.com/huggingface/datasets/issues/3339 | to_tf_dataset fails on TPU | This might be related to https://github.com/tensorflow/tensorflow/issues/38762 , what do you think @Rocketknight1 ?
> Dataset.from_generator is expected to not work with TPUs as it uses py_function underneath which is incompatible with Cloud TPU 2VM setup. If you would like to read from large datasets, maybe try to materialize it on disk and use TFRecordDataest instead. | Using `to_tf_dataset` to create a dataset and then putting it in `model.fit` results in an internal error on TPUs. I've only tried on Colab and Kaggle TPUs, not GCP TPUs.
## Steps to reproduce the bug
I made a colab to show the error. https://colab.research.google.com/drive/12x_PFKzGouFxqD4OuWfnycW_1TaT276z?usp=sharing
## Expected results
dataset from `to_tf_dataset` works in `model.fit`
Right below the first error in the colab I use `tf.data.Dataset.from_tensor_slices` and `model.fit` works just fine. This is the desired outcome.
## Actual results
```
InternalError: 5 root error(s) found.
(0) INTERNAL: {{function_node __inference_train_function_30558}} failed to connect to all addresses
Additional GRPC error information from remote target /job:localhost/replica:0/task:0/device:CPU:0:
:{"created":"@1638231897.932218653","description":"Failed to pick subchannel","file":"third_party/grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3151,"referenced_errors":[{"created":"@1638231897.932216754","description":"failed to connect to all addresses","file":"third_party/grpc/src/core/lib/transport/error_utils.cc","file_line":161,"grpc_status":14}]}
[[{{node StatefulPartitionedCall}}]]
[[MultiDeviceIteratorGetNextFromShard]]
Executing non-communication op <MultiDeviceIteratorGetNextFromShard> originally returned UnavailableError, and was replaced by InternalError to avoid invoking TF network error handling logic.
[[RemoteCall]]
[[IteratorGetNextAsOptional]]
[[tpu_compile_succeeded_assert/_14023832043698465348/_7/_439]]
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.16.1
- Platform: Linux-5.4.104+-x86_64-with-Ubuntu-18.04-bionic
- Python version: 3.7.12
- PyArrow version: 3.0.0
- Tensorflow 2.7.0
- `transformers` 4.12.5
| 55 | to_tf_dataset fails on TPU
Using `to_tf_dataset` to create a dataset and then putting it in `model.fit` results in an internal error on TPUs. I've only tried on Colab and Kaggle TPUs, not GCP TPUs.
## Steps to reproduce the bug
I made a colab to show the error. https://colab.research.google.com/drive/12x_PFKzGouFxqD4OuWfnycW_1TaT276z?usp=sharing
## Expected results
dataset from `to_tf_dataset` works in `model.fit`
Right below the first error in the colab I use `tf.data.Dataset.from_tensor_slices` and `model.fit` works just fine. This is the desired outcome.
## Actual results
```
InternalError: 5 root error(s) found.
(0) INTERNAL: {{function_node __inference_train_function_30558}} failed to connect to all addresses
Additional GRPC error information from remote target /job:localhost/replica:0/task:0/device:CPU:0:
:{"created":"@1638231897.932218653","description":"Failed to pick subchannel","file":"third_party/grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3151,"referenced_errors":[{"created":"@1638231897.932216754","description":"failed to connect to all addresses","file":"third_party/grpc/src/core/lib/transport/error_utils.cc","file_line":161,"grpc_status":14}]}
[[{{node StatefulPartitionedCall}}]]
[[MultiDeviceIteratorGetNextFromShard]]
Executing non-communication op <MultiDeviceIteratorGetNextFromShard> originally returned UnavailableError, and was replaced by InternalError to avoid invoking TF network error handling logic.
[[RemoteCall]]
[[IteratorGetNextAsOptional]]
[[tpu_compile_succeeded_assert/_14023832043698465348/_7/_439]]
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.16.1
- Platform: Linux-5.4.104+-x86_64-with-Ubuntu-18.04-bionic
- Python version: 3.7.12
- PyArrow version: 3.0.0
- Tensorflow 2.7.0
- `transformers` 4.12.5
This might be related to https://github.com/tensorflow/tensorflow/issues/38762 , what do you think @Rocketknight1 ?
> Dataset.from_generator is expected to not work with TPUs as it uses py_function underneath which is incompatible with Cloud TPU 2VM setup. If you would like to read from large datasets, maybe try to materialize it on disk and use TFRecordDataest instead. | [
-0.2377156913,
-0.1358828992,
0.1592501402,
0.2036827803,
0.4153629541,
0.0100355959,
0.3643489182,
0.0257144328,
-0.4569853246,
0.1801205426,
-0.0554240905,
0.2911762893,
0.2514830828,
0.4929235876,
0.1305931658,
-0.0885017514,
-0.14083004,
0.0494023189,
-0.0877252072,
-0.1319961995,
-0.1496612281,
0.401570648,
0.0868343338,
0.0567882359,
-0.5214211941,
-0.1575677842,
0.2263303548,
-0.0939755142,
0.1207184047,
0.1129213795,
0.3648658395,
-0.3170058429,
-0.181627661,
0.7030664682,
-0.0001187178,
0.3797948062,
-0.0694344267,
-0.1777595133,
-0.1031217948,
-0.0664446354,
-0.3455985785,
0.1405737251,
0.0220209807,
-0.0226529185,
-0.3122110367,
0.3715749383,
0.091908671,
0.327147752,
0.2484272867,
0.4748539329,
0.1062795669,
0.5870953798,
0.1409716308,
-0.1173629239,
-0.0748100206,
-0.1198629811,
-0.4575205743,
0.2642862201,
-0.2550958991,
0.008434481,
0.2066530734,
-0.2624971271,
0.1700141579,
-0.1378923506,
0.0388896167,
0.1986298859,
0.2847883999,
-0.5665248036,
0.0617814884,
0.3099964261,
0.4110126495,
-0.4460215569,
-0.3044812679,
-0.0078700436,
-0.1459916532,
-0.257471472,
0.2615571022,
-0.1098164022,
-0.2194308043,
0.2189638317,
-0.1486360282,
0.0512510501,
-0.1517456174,
0.0437368415,
-0.1780232489,
0.2540245652,
0.1723249257,
0.1105856374,
-0.0783793628,
-0.0591197871,
0.3977127373,
0.0053142062,
0.0010843854,
-0.1233213618,
-0.4784841537,
-0.2640333176,
-0.035225071,
-0.2578029335,
-0.1654641926,
-0.3697740734,
0.2542355061,
-0.1878967434,
0.0652358383,
0.1911206692,
0.2713412344,
-0.0521752089,
-0.4298447967,
0.4683071673,
-0.0494385473,
-0.2337642908,
-0.2360999733,
0.0086180829,
0.2236471176,
-0.2119260132,
-0.1250924468,
-0.2815614939,
0.0683930293,
-0.2035695463,
-0.2338639051,
0.0085222162,
-0.276479274,
0.2113040388,
-0.145904392,
0.016297359,
0.2459677905,
0.1817945093,
0.1868250072,
0.0181061663,
-0.3681666851,
0.1552917659,
-0.2345890999,
-0.1149433106,
-0.051060196,
0.0272473339,
0.048222214,
-0.2405117601,
-0.112962842,
-0.1761605293,
0.1284231246,
0.1661120653,
-0.0290869903,
-0.2764333785,
0.0377805717,
0.6523355842,
-0.0119726527,
-0.1389116198,
0.0409137979,
-0.2477667034,
-0.004475439,
0.1105828881,
-0.3303798437,
-0.3795882761,
0.1784085184,
0.0613013469,
-0.0765635967,
-0.1235888675,
-0.1698184162,
0.3062875867,
0.1762576401,
-0.3321533799,
-0.137178421,
-0.4028519094,
-0.5160397887,
-0.0465580709,
0.3421142399,
0.2293464839,
-0.3999686241,
0.1405466199,
0.3465245664,
-0.1311472505,
0.3667520285,
0.2631674409,
0.1796577126,
0.2890563309,
-0.0087553086,
0.120787248,
0.3746039271,
-0.0532492474,
-0.3076036274,
0.2929520607,
-0.4511580169,
-0.0498887971,
-0.3144190311,
-0.074894391,
-0.2482598871,
-0.1482324302,
0.1959412694,
0.3359014392,
-0.4545333385,
0.1155398414,
-0.355928421,
-0.1035044417,
0.0948313847,
0.0270726644,
0.1515791416,
0.1515682489,
0.1807979643,
0.0927195698,
0.1558757275,
-0.0527645163,
-0.146371305,
0.0524281599,
0.6204757094,
-0.3251644969,
0.0734889358,
0.355219394,
-0.245455429,
0.227078855,
0.0642021596,
0.4079866707,
0.1751741469,
0.1910035014,
0.0165361576,
0.2132797986,
0.2460155934,
-0.0692218691,
0.0280522928,
0.1479060948,
-0.2696961761,
-0.1228911877,
-0.012478481,
0.401840955,
-0.2534156442,
-0.0039208671,
-0.4376435578,
0.5116253495,
0.0371225029,
-0.3100266755,
0.0485630259,
0.1247183904,
0.0814706385,
0.0130942166,
-0.2894964814,
0.2103201151,
0.0579834282,
0.2898692489,
-0.1763061136,
0.3690994084,
0.0451593548,
-0.3981793225,
-0.42264539,
0.0784713924,
0.1535725296,
0.0689357072,
0.0463582203,
0.0261187274,
-0.0124220513,
-0.0486867689,
0.0855246633,
-0.0038226051,
0.0663367659,
0.0859495252,
0.1466535628,
-0.0413408354,
-0.1051914245,
0.1442933977,
-0.2223656625,
0.1559816003,
-0.4287632108,
0.4230032265,
0.3258286417,
0.0899129212,
-0.087971434,
0.1292704046,
0.2320270985,
-0.2631542683,
0.2595541775,
0.4011158943,
0.3372506201,
0.1074675843,
-0.031285163,
0.0652007982,
-0.3169073164,
-0.3241820037,
0.0318319313,
0.058880318,
0.1356631666,
0.3109446466,
0.2310613096,
0.4301351607,
-0.1165127158,
-0.0366036333,
0.0924786851,
0.2334310412,
-0.5189219117,
0.0243091881,
-0.1007748619,
-0.1003218293,
0.0185870156,
0.2401235998,
-0.003311923,
-0.3447381258,
-0.0645324513,
0.1211463138,
-0.2095202506,
0.1038530245,
-0.14294599,
0.1682709455,
0.0045915134,
-0.2821530402,
-0.0071255928,
-0.2306578308,
-0.2735158801,
0.0589576885,
0.1348590255,
0.3670639098,
0.0600000285,
-0.1300419271,
-0.1335043311,
0.1996670216,
-0.4904163182,
0.3301842213,
-0.2673294246,
0.6307036281,
0.0753396228,
0.1596300751,
-0.3512653112,
-0.3435929716,
0.19549869,
-0.2150817662,
-0.226736322,
0.1991049796,
-0.3109489083,
-0.1440780908,
-0.0591996536,
-0.2922247052,
-0.1498135477,
-0.2958478034,
0.1066616327,
-0.0361902639,
0.1189289466,
0.5792869925,
0.2318672836,
0.0879401341,
0.2316232324,
-0.1162112802,
-0.0752680153,
-0.0175886583,
0.2094079703,
-0.0206164829,
-0.305455178,
0.0456143767,
0.0830291063,
0.1659787893,
0.3440008163,
-0.5312432647,
-0.1311130077,
-0.2157509476,
0.0798155591,
0.0384741314,
-0.1743491888,
0.1771759689,
0.01826212,
0.0340932608,
-0.2266960889,
-0.4738584459,
0.2424235195,
0.6612286568,
0.1286108196,
0.0130047863,
0.3885802627,
-0.0767250806,
0.3667708337,
-0.0940793082,
-0.3093858361,
0.1707792133,
-0.2439338267,
0.1991696954,
-0.2772429585,
-0.1312865317,
0.4598912001,
-0.083759971,
-0.3251048028,
0.0416609645,
-0.2754912674,
-0.1894610375,
-0.1993924081,
0.0008013277,
-0.1722548008,
-0.3638682961,
0.0436517112,
0.1790497005,
0.17523323,
0.1977655888,
-0.0633706301,
-0.1011735722,
-0.1433611959,
-0.0638721883,
0.0281384569,
0.2383130789,
0.1677356958,
0.284989506,
-0.2148858607,
-0.4850689471,
0.0196997393,
0.155763343,
0.5570329428,
-0.4624986351,
-0.049285505,
-0.2705088258,
0.0526408479,
0.1381969452,
-0.5062898397,
0.1252445728,
0.4707213044,
-0.2327638865,
-0.2381845564,
0.1354453415,
-0.04023825,
-0.0775069296,
0.1454480737,
0.5163575411,
0.0244076252,
-0.0011555036,
0.102841109,
0.1391420066,
-0.0137606291,
0.0479761921,
-0.1127211526,
-0.4224164784,
0.0315473154,
-0.0520157702,
0.2348564565,
0.2681127787,
0.0090605887,
-0.0248570051,
0.0639617145,
0.0555859543,
-0.0136338184,
0.1730490923,
0.0811261162,
0.0432884954,
0.2867955267,
-0.1952414066,
0.1164328679,
0.270521611,
0.6125136018,
-0.0961357877,
-0.1644971967,
0.4197415709,
0.2101632655,
0.1094644368,
0.2773973644,
-0.1253114641,
-0.2054560781,
-0.3309932947,
0.1134591252,
0.3007660806,
0.2804313004,
-0.0181552209,
-0.0401604697,
-0.1287620366,
0.0228469595,
0.166452691,
-0.0307443105,
0.1580541283,
0.4151937366,
0.033031825,
-0.1036501676,
0.4487224817,
0.335606575,
0.7207568884,
0.0106940884,
0.0525911897,
0.5778244138,
0.0135507174,
0.4246169925,
-0.2746321261,
0.2748579979,
-0.2519744039,
-0.5210760832,
0.0441949777,
-0.1171971411,
-0.3844120204,
0.1134795249,
-0.1938159466,
0.0158413071,
0.4071490467,
0.0687509775,
0.3557627797,
0.0647052228,
0.3553376794,
-0.3262241781,
-0.3602842093,
0.1078309268,
0.0950333327,
-0.0484300219,
0.0105486661,
-0.2763650119,
-0.2692651749,
0.0536679775,
-0.1283836514,
0.2209372073,
-0.793356657,
-0.0858923793,
0.2042955011,
-0.2239294201,
0.154962033,
0.2518289387,
0.373355329,
0.1179984361,
-0.3078553081,
0.0873976573,
0.1203665137,
0.0649081469,
0.1244639903,
-0.0916919485,
0.474537462,
-0.1940166056,
-0.0660568476,
-0.1898191571,
-0.0558325388,
-0.2215318978,
0.4300836921,
-0.3863453269,
-0.435774982,
-0.0372986458,
-0.0546231717,
-0.0380802155,
-0.2631296217,
-0.063341856,
0.0647726059,
-0.1656986624,
-0.0996732637,
0.095204927,
-0.1294159591,
-0.3429450691,
0.0616355985,
0.2117563635,
-0.1679017842,
0.1182900295,
0.1500209719,
0.2262631357,
0.0406456254,
-0.1507024765,
0.1242414862,
0.1295841336,
-0.4625426233,
0.1372897476,
-0.1432674676,
-0.0740371272,
0.2033184022,
0.6734072566,
0.0757523775,
0.0588200316,
0.0195528921,
-0.0443896428,
-0.4824236929,
-0.0466347039,
-0.0589359067,
0.1743708551,
-0.0147307208,
0.6068685055,
0.185361132,
0.0985842124,
-0.224135384,
-0.1940156519,
-0.4560902417,
0.004823843,
0.2563571632,
-0.1427137703,
0.1501272023,
-0.0192628726,
0.0053430758,
0.3450675309,
-0.1361493617,
-0.1245510727,
0.0562012419,
0.1394144595,
0.5006350875,
-0.2530396283,
-0.2139217705,
0.2002836466,
-0.4576193988,
-0.167702809,
0.3107051849,
0.2047922462,
-0.2968538404,
-0.2138679326,
0.2578503489,
0.1204037443,
-0.1960658133,
-0.0265863333,
0.3249149024,
0.11860203,
0.0342661887,
0.0629600435,
-0.1406481713,
0.0397775806,
0.1906415522,
0.0736060441,
-0.0283294674,
0.0315635763,
0.2545517087,
-0.3750663102,
-0.2104622126,
-0.1406093687,
-0.0481709912,
-0.030850647,
-0.1764022708,
0.0688384026,
0.0254645497,
0.0473620556,
-0.0868703946,
0.0438387878,
0.464027971,
0.073264055,
-0.0526998937,
0.1923798323,
0.3951918781,
-0.0742517486,
-0.2395330966,
0.1657420993,
0.064168945,
-0.1330350637,
0.0289942455,
0.4475801289,
-0.1157911941,
0.366954565,
-0.2056462914,
-0.1071943641,
0.0172422323,
-0.0756315216,
0.0272690058,
-0.0004786641,
-0.2425743341,
-0.1459872574,
0.208420068,
-0.4114046991,
0.0355993435,
-0.0254087821,
-0.022808075,
0.1327159107,
-0.0852563754,
-0.098498933,
-0.1730840206,
-0.2286589295,
-0.1912234724,
0.1018280685,
-0.2621099949,
0.1494060308,
-0.1802429706,
-0.0455489531,
-0.2522966564,
-0.1624832302,
-0.2017872036,
0.0757135451,
0.0014230027,
0.1324417889,
-0.0869175345,
0.2283083498,
-0.4671306014,
0.0846142322,
-0.0741762072,
-0.0414437987,
0.5216245055,
-0.2772120237,
-0.391620636,
-0.2933711112,
0.3712118268,
0.4211888313,
0.0998307616,
0.1075814366,
0.1789456308,
0.3164710104,
0.1173969209,
0.2259040028,
0.2093449086,
-0.0680332333,
-0.0713440999,
0.3802039027,
-0.0306152627,
-0.0672217831,
-0.0244907588,
0.0067518856,
0.454017967,
-0.3554112911,
0.1385698467,
0.1038019508,
-0.0160817988,
-0.0885442123,
0.1836745143,
-0.0407799967,
0.2201063931,
0.5140337348,
-0.2947468758,
0.1866614372,
0.0398609601,
0.0568319187,
-0.1250899285,
0.6414741874,
0.2015043199,
0.0785873607,
-0.2548238635,
-0.0080224611,
-0.3166708052,
0.451793015,
-0.0249779671,
0.2112790644,
0.2599021792,
0.0018528112,
0.3646708429,
0.205744043,
-0.1213349998,
0.3731504083,
-0.0493989736,
0.1811481863,
-0.1128758937,
-0.3199303448,
-0.6019216776,
-0.1749903262,
-0.0303009152,
-0.0980022922,
0.0699096099,
0.0650304854,
0.0756998286,
0.0069905487,
-0.3138490319,
0.2409635633,
0.3974547386,
0.2500318587,
0.2661223114,
0.3924698532,
-0.1516639292,
0.058021497,
-0.1057915539,
-0.4218706191,
-0.3414775133,
-0.1440109313,
-0.218783021,
0.2718350291,
0.0243693832,
0.1895829588,
-0.2418980598,
-0.4366143048,
-0.0312265009,
0.2030085325,
0.190729335,
0.1129376516,
-0.1146407127,
0.0326742977,
0.5494960546,
0.2126706243,
0.1125396043,
0.0165644493,
-0.2421236783,
-0.3317566514,
0.2751049101,
-0.2684333622,
-0.0808742791,
-0.1443079114,
-0.0826439187,
0.0082007656,
0.2455913574,
-0.2214616835,
0.0346161351,
0.1733164787,
-0.1256736219,
-0.2450556457,
0.0937880352,
-0.0133095495,
0.2144186795,
0.002996546,
0.2994556725,
0.1801258177,
-0.0606589466,
-0.1818603873,
-0.038555339
] |
https://github.com/huggingface/datasets/issues/3339 | to_tf_dataset fails on TPU | Hi @lhoestq @nbroad1881, I think it's very similar, yes. Unfortunately `to_tf_dataset` uses `tf.numpy_function` which can't be compiled - this is a necessary evil to load from the underlying Arrow dataset. We need to update the notebooks/examples to clarify that this won't work, or to identify a workaround. You may be able to get it to work on an actual cloud TPU VM, but those are quite new and we haven't tested it yet. | Using `to_tf_dataset` to create a dataset and then putting it in `model.fit` results in an internal error on TPUs. I've only tried on Colab and Kaggle TPUs, not GCP TPUs.
## Steps to reproduce the bug
I made a colab to show the error. https://colab.research.google.com/drive/12x_PFKzGouFxqD4OuWfnycW_1TaT276z?usp=sharing
## Expected results
dataset from `to_tf_dataset` works in `model.fit`
Right below the first error in the colab I use `tf.data.Dataset.from_tensor_slices` and `model.fit` works just fine. This is the desired outcome.
## Actual results
```
InternalError: 5 root error(s) found.
(0) INTERNAL: {{function_node __inference_train_function_30558}} failed to connect to all addresses
Additional GRPC error information from remote target /job:localhost/replica:0/task:0/device:CPU:0:
:{"created":"@1638231897.932218653","description":"Failed to pick subchannel","file":"third_party/grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3151,"referenced_errors":[{"created":"@1638231897.932216754","description":"failed to connect to all addresses","file":"third_party/grpc/src/core/lib/transport/error_utils.cc","file_line":161,"grpc_status":14}]}
[[{{node StatefulPartitionedCall}}]]
[[MultiDeviceIteratorGetNextFromShard]]
Executing non-communication op <MultiDeviceIteratorGetNextFromShard> originally returned UnavailableError, and was replaced by InternalError to avoid invoking TF network error handling logic.
[[RemoteCall]]
[[IteratorGetNextAsOptional]]
[[tpu_compile_succeeded_assert/_14023832043698465348/_7/_439]]
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.16.1
- Platform: Linux-5.4.104+-x86_64-with-Ubuntu-18.04-bionic
- Python version: 3.7.12
- PyArrow version: 3.0.0
- Tensorflow 2.7.0
- `transformers` 4.12.5
| 73 | to_tf_dataset fails on TPU
Using `to_tf_dataset` to create a dataset and then putting it in `model.fit` results in an internal error on TPUs. I've only tried on Colab and Kaggle TPUs, not GCP TPUs.
## Steps to reproduce the bug
I made a colab to show the error. https://colab.research.google.com/drive/12x_PFKzGouFxqD4OuWfnycW_1TaT276z?usp=sharing
## Expected results
dataset from `to_tf_dataset` works in `model.fit`
Right below the first error in the colab I use `tf.data.Dataset.from_tensor_slices` and `model.fit` works just fine. This is the desired outcome.
## Actual results
```
InternalError: 5 root error(s) found.
(0) INTERNAL: {{function_node __inference_train_function_30558}} failed to connect to all addresses
Additional GRPC error information from remote target /job:localhost/replica:0/task:0/device:CPU:0:
:{"created":"@1638231897.932218653","description":"Failed to pick subchannel","file":"third_party/grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3151,"referenced_errors":[{"created":"@1638231897.932216754","description":"failed to connect to all addresses","file":"third_party/grpc/src/core/lib/transport/error_utils.cc","file_line":161,"grpc_status":14}]}
[[{{node StatefulPartitionedCall}}]]
[[MultiDeviceIteratorGetNextFromShard]]
Executing non-communication op <MultiDeviceIteratorGetNextFromShard> originally returned UnavailableError, and was replaced by InternalError to avoid invoking TF network error handling logic.
[[RemoteCall]]
[[IteratorGetNextAsOptional]]
[[tpu_compile_succeeded_assert/_14023832043698465348/_7/_439]]
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.16.1
- Platform: Linux-5.4.104+-x86_64-with-Ubuntu-18.04-bionic
- Python version: 3.7.12
- PyArrow version: 3.0.0
- Tensorflow 2.7.0
- `transformers` 4.12.5
Hi @lhoestq @nbroad1881, I think it's very similar, yes. Unfortunately `to_tf_dataset` uses `tf.numpy_function` which can't be compiled - this is a necessary evil to load from the underlying Arrow dataset. We need to update the notebooks/examples to clarify that this won't work, or to identify a workaround. You may be able to get it to work on an actual cloud TPU VM, but those are quite new and we haven't tested it yet. | [
-0.2377156913,
-0.1358828992,
0.1592501402,
0.2036827803,
0.4153629541,
0.0100355959,
0.3643489182,
0.0257144328,
-0.4569853246,
0.1801205426,
-0.0554240905,
0.2911762893,
0.2514830828,
0.4929235876,
0.1305931658,
-0.0885017514,
-0.14083004,
0.0494023189,
-0.0877252072,
-0.1319961995,
-0.1496612281,
0.401570648,
0.0868343338,
0.0567882359,
-0.5214211941,
-0.1575677842,
0.2263303548,
-0.0939755142,
0.1207184047,
0.1129213795,
0.3648658395,
-0.3170058429,
-0.181627661,
0.7030664682,
-0.0001187178,
0.3797948062,
-0.0694344267,
-0.1777595133,
-0.1031217948,
-0.0664446354,
-0.3455985785,
0.1405737251,
0.0220209807,
-0.0226529185,
-0.3122110367,
0.3715749383,
0.091908671,
0.327147752,
0.2484272867,
0.4748539329,
0.1062795669,
0.5870953798,
0.1409716308,
-0.1173629239,
-0.0748100206,
-0.1198629811,
-0.4575205743,
0.2642862201,
-0.2550958991,
0.008434481,
0.2066530734,
-0.2624971271,
0.1700141579,
-0.1378923506,
0.0388896167,
0.1986298859,
0.2847883999,
-0.5665248036,
0.0617814884,
0.3099964261,
0.4110126495,
-0.4460215569,
-0.3044812679,
-0.0078700436,
-0.1459916532,
-0.257471472,
0.2615571022,
-0.1098164022,
-0.2194308043,
0.2189638317,
-0.1486360282,
0.0512510501,
-0.1517456174,
0.0437368415,
-0.1780232489,
0.2540245652,
0.1723249257,
0.1105856374,
-0.0783793628,
-0.0591197871,
0.3977127373,
0.0053142062,
0.0010843854,
-0.1233213618,
-0.4784841537,
-0.2640333176,
-0.035225071,
-0.2578029335,
-0.1654641926,
-0.3697740734,
0.2542355061,
-0.1878967434,
0.0652358383,
0.1911206692,
0.2713412344,
-0.0521752089,
-0.4298447967,
0.4683071673,
-0.0494385473,
-0.2337642908,
-0.2360999733,
0.0086180829,
0.2236471176,
-0.2119260132,
-0.1250924468,
-0.2815614939,
0.0683930293,
-0.2035695463,
-0.2338639051,
0.0085222162,
-0.276479274,
0.2113040388,
-0.145904392,
0.016297359,
0.2459677905,
0.1817945093,
0.1868250072,
0.0181061663,
-0.3681666851,
0.1552917659,
-0.2345890999,
-0.1149433106,
-0.051060196,
0.0272473339,
0.048222214,
-0.2405117601,
-0.112962842,
-0.1761605293,
0.1284231246,
0.1661120653,
-0.0290869903,
-0.2764333785,
0.0377805717,
0.6523355842,
-0.0119726527,
-0.1389116198,
0.0409137979,
-0.2477667034,
-0.004475439,
0.1105828881,
-0.3303798437,
-0.3795882761,
0.1784085184,
0.0613013469,
-0.0765635967,
-0.1235888675,
-0.1698184162,
0.3062875867,
0.1762576401,
-0.3321533799,
-0.137178421,
-0.4028519094,
-0.5160397887,
-0.0465580709,
0.3421142399,
0.2293464839,
-0.3999686241,
0.1405466199,
0.3465245664,
-0.1311472505,
0.3667520285,
0.2631674409,
0.1796577126,
0.2890563309,
-0.0087553086,
0.120787248,
0.3746039271,
-0.0532492474,
-0.3076036274,
0.2929520607,
-0.4511580169,
-0.0498887971,
-0.3144190311,
-0.074894391,
-0.2482598871,
-0.1482324302,
0.1959412694,
0.3359014392,
-0.4545333385,
0.1155398414,
-0.355928421,
-0.1035044417,
0.0948313847,
0.0270726644,
0.1515791416,
0.1515682489,
0.1807979643,
0.0927195698,
0.1558757275,
-0.0527645163,
-0.146371305,
0.0524281599,
0.6204757094,
-0.3251644969,
0.0734889358,
0.355219394,
-0.245455429,
0.227078855,
0.0642021596,
0.4079866707,
0.1751741469,
0.1910035014,
0.0165361576,
0.2132797986,
0.2460155934,
-0.0692218691,
0.0280522928,
0.1479060948,
-0.2696961761,
-0.1228911877,
-0.012478481,
0.401840955,
-0.2534156442,
-0.0039208671,
-0.4376435578,
0.5116253495,
0.0371225029,
-0.3100266755,
0.0485630259,
0.1247183904,
0.0814706385,
0.0130942166,
-0.2894964814,
0.2103201151,
0.0579834282,
0.2898692489,
-0.1763061136,
0.3690994084,
0.0451593548,
-0.3981793225,
-0.42264539,
0.0784713924,
0.1535725296,
0.0689357072,
0.0463582203,
0.0261187274,
-0.0124220513,
-0.0486867689,
0.0855246633,
-0.0038226051,
0.0663367659,
0.0859495252,
0.1466535628,
-0.0413408354,
-0.1051914245,
0.1442933977,
-0.2223656625,
0.1559816003,
-0.4287632108,
0.4230032265,
0.3258286417,
0.0899129212,
-0.087971434,
0.1292704046,
0.2320270985,
-0.2631542683,
0.2595541775,
0.4011158943,
0.3372506201,
0.1074675843,
-0.031285163,
0.0652007982,
-0.3169073164,
-0.3241820037,
0.0318319313,
0.058880318,
0.1356631666,
0.3109446466,
0.2310613096,
0.4301351607,
-0.1165127158,
-0.0366036333,
0.0924786851,
0.2334310412,
-0.5189219117,
0.0243091881,
-0.1007748619,
-0.1003218293,
0.0185870156,
0.2401235998,
-0.003311923,
-0.3447381258,
-0.0645324513,
0.1211463138,
-0.2095202506,
0.1038530245,
-0.14294599,
0.1682709455,
0.0045915134,
-0.2821530402,
-0.0071255928,
-0.2306578308,
-0.2735158801,
0.0589576885,
0.1348590255,
0.3670639098,
0.0600000285,
-0.1300419271,
-0.1335043311,
0.1996670216,
-0.4904163182,
0.3301842213,
-0.2673294246,
0.6307036281,
0.0753396228,
0.1596300751,
-0.3512653112,
-0.3435929716,
0.19549869,
-0.2150817662,
-0.226736322,
0.1991049796,
-0.3109489083,
-0.1440780908,
-0.0591996536,
-0.2922247052,
-0.1498135477,
-0.2958478034,
0.1066616327,
-0.0361902639,
0.1189289466,
0.5792869925,
0.2318672836,
0.0879401341,
0.2316232324,
-0.1162112802,
-0.0752680153,
-0.0175886583,
0.2094079703,
-0.0206164829,
-0.305455178,
0.0456143767,
0.0830291063,
0.1659787893,
0.3440008163,
-0.5312432647,
-0.1311130077,
-0.2157509476,
0.0798155591,
0.0384741314,
-0.1743491888,
0.1771759689,
0.01826212,
0.0340932608,
-0.2266960889,
-0.4738584459,
0.2424235195,
0.6612286568,
0.1286108196,
0.0130047863,
0.3885802627,
-0.0767250806,
0.3667708337,
-0.0940793082,
-0.3093858361,
0.1707792133,
-0.2439338267,
0.1991696954,
-0.2772429585,
-0.1312865317,
0.4598912001,
-0.083759971,
-0.3251048028,
0.0416609645,
-0.2754912674,
-0.1894610375,
-0.1993924081,
0.0008013277,
-0.1722548008,
-0.3638682961,
0.0436517112,
0.1790497005,
0.17523323,
0.1977655888,
-0.0633706301,
-0.1011735722,
-0.1433611959,
-0.0638721883,
0.0281384569,
0.2383130789,
0.1677356958,
0.284989506,
-0.2148858607,
-0.4850689471,
0.0196997393,
0.155763343,
0.5570329428,
-0.4624986351,
-0.049285505,
-0.2705088258,
0.0526408479,
0.1381969452,
-0.5062898397,
0.1252445728,
0.4707213044,
-0.2327638865,
-0.2381845564,
0.1354453415,
-0.04023825,
-0.0775069296,
0.1454480737,
0.5163575411,
0.0244076252,
-0.0011555036,
0.102841109,
0.1391420066,
-0.0137606291,
0.0479761921,
-0.1127211526,
-0.4224164784,
0.0315473154,
-0.0520157702,
0.2348564565,
0.2681127787,
0.0090605887,
-0.0248570051,
0.0639617145,
0.0555859543,
-0.0136338184,
0.1730490923,
0.0811261162,
0.0432884954,
0.2867955267,
-0.1952414066,
0.1164328679,
0.270521611,
0.6125136018,
-0.0961357877,
-0.1644971967,
0.4197415709,
0.2101632655,
0.1094644368,
0.2773973644,
-0.1253114641,
-0.2054560781,
-0.3309932947,
0.1134591252,
0.3007660806,
0.2804313004,
-0.0181552209,
-0.0401604697,
-0.1287620366,
0.0228469595,
0.166452691,
-0.0307443105,
0.1580541283,
0.4151937366,
0.033031825,
-0.1036501676,
0.4487224817,
0.335606575,
0.7207568884,
0.0106940884,
0.0525911897,
0.5778244138,
0.0135507174,
0.4246169925,
-0.2746321261,
0.2748579979,
-0.2519744039,
-0.5210760832,
0.0441949777,
-0.1171971411,
-0.3844120204,
0.1134795249,
-0.1938159466,
0.0158413071,
0.4071490467,
0.0687509775,
0.3557627797,
0.0647052228,
0.3553376794,
-0.3262241781,
-0.3602842093,
0.1078309268,
0.0950333327,
-0.0484300219,
0.0105486661,
-0.2763650119,
-0.2692651749,
0.0536679775,
-0.1283836514,
0.2209372073,
-0.793356657,
-0.0858923793,
0.2042955011,
-0.2239294201,
0.154962033,
0.2518289387,
0.373355329,
0.1179984361,
-0.3078553081,
0.0873976573,
0.1203665137,
0.0649081469,
0.1244639903,
-0.0916919485,
0.474537462,
-0.1940166056,
-0.0660568476,
-0.1898191571,
-0.0558325388,
-0.2215318978,
0.4300836921,
-0.3863453269,
-0.435774982,
-0.0372986458,
-0.0546231717,
-0.0380802155,
-0.2631296217,
-0.063341856,
0.0647726059,
-0.1656986624,
-0.0996732637,
0.095204927,
-0.1294159591,
-0.3429450691,
0.0616355985,
0.2117563635,
-0.1679017842,
0.1182900295,
0.1500209719,
0.2262631357,
0.0406456254,
-0.1507024765,
0.1242414862,
0.1295841336,
-0.4625426233,
0.1372897476,
-0.1432674676,
-0.0740371272,
0.2033184022,
0.6734072566,
0.0757523775,
0.0588200316,
0.0195528921,
-0.0443896428,
-0.4824236929,
-0.0466347039,
-0.0589359067,
0.1743708551,
-0.0147307208,
0.6068685055,
0.185361132,
0.0985842124,
-0.224135384,
-0.1940156519,
-0.4560902417,
0.004823843,
0.2563571632,
-0.1427137703,
0.1501272023,
-0.0192628726,
0.0053430758,
0.3450675309,
-0.1361493617,
-0.1245510727,
0.0562012419,
0.1394144595,
0.5006350875,
-0.2530396283,
-0.2139217705,
0.2002836466,
-0.4576193988,
-0.167702809,
0.3107051849,
0.2047922462,
-0.2968538404,
-0.2138679326,
0.2578503489,
0.1204037443,
-0.1960658133,
-0.0265863333,
0.3249149024,
0.11860203,
0.0342661887,
0.0629600435,
-0.1406481713,
0.0397775806,
0.1906415522,
0.0736060441,
-0.0283294674,
0.0315635763,
0.2545517087,
-0.3750663102,
-0.2104622126,
-0.1406093687,
-0.0481709912,
-0.030850647,
-0.1764022708,
0.0688384026,
0.0254645497,
0.0473620556,
-0.0868703946,
0.0438387878,
0.464027971,
0.073264055,
-0.0526998937,
0.1923798323,
0.3951918781,
-0.0742517486,
-0.2395330966,
0.1657420993,
0.064168945,
-0.1330350637,
0.0289942455,
0.4475801289,
-0.1157911941,
0.366954565,
-0.2056462914,
-0.1071943641,
0.0172422323,
-0.0756315216,
0.0272690058,
-0.0004786641,
-0.2425743341,
-0.1459872574,
0.208420068,
-0.4114046991,
0.0355993435,
-0.0254087821,
-0.022808075,
0.1327159107,
-0.0852563754,
-0.098498933,
-0.1730840206,
-0.2286589295,
-0.1912234724,
0.1018280685,
-0.2621099949,
0.1494060308,
-0.1802429706,
-0.0455489531,
-0.2522966564,
-0.1624832302,
-0.2017872036,
0.0757135451,
0.0014230027,
0.1324417889,
-0.0869175345,
0.2283083498,
-0.4671306014,
0.0846142322,
-0.0741762072,
-0.0414437987,
0.5216245055,
-0.2772120237,
-0.391620636,
-0.2933711112,
0.3712118268,
0.4211888313,
0.0998307616,
0.1075814366,
0.1789456308,
0.3164710104,
0.1173969209,
0.2259040028,
0.2093449086,
-0.0680332333,
-0.0713440999,
0.3802039027,
-0.0306152627,
-0.0672217831,
-0.0244907588,
0.0067518856,
0.454017967,
-0.3554112911,
0.1385698467,
0.1038019508,
-0.0160817988,
-0.0885442123,
0.1836745143,
-0.0407799967,
0.2201063931,
0.5140337348,
-0.2947468758,
0.1866614372,
0.0398609601,
0.0568319187,
-0.1250899285,
0.6414741874,
0.2015043199,
0.0785873607,
-0.2548238635,
-0.0080224611,
-0.3166708052,
0.451793015,
-0.0249779671,
0.2112790644,
0.2599021792,
0.0018528112,
0.3646708429,
0.205744043,
-0.1213349998,
0.3731504083,
-0.0493989736,
0.1811481863,
-0.1128758937,
-0.3199303448,
-0.6019216776,
-0.1749903262,
-0.0303009152,
-0.0980022922,
0.0699096099,
0.0650304854,
0.0756998286,
0.0069905487,
-0.3138490319,
0.2409635633,
0.3974547386,
0.2500318587,
0.2661223114,
0.3924698532,
-0.1516639292,
0.058021497,
-0.1057915539,
-0.4218706191,
-0.3414775133,
-0.1440109313,
-0.218783021,
0.2718350291,
0.0243693832,
0.1895829588,
-0.2418980598,
-0.4366143048,
-0.0312265009,
0.2030085325,
0.190729335,
0.1129376516,
-0.1146407127,
0.0326742977,
0.5494960546,
0.2126706243,
0.1125396043,
0.0165644493,
-0.2421236783,
-0.3317566514,
0.2751049101,
-0.2684333622,
-0.0808742791,
-0.1443079114,
-0.0826439187,
0.0082007656,
0.2455913574,
-0.2214616835,
0.0346161351,
0.1733164787,
-0.1256736219,
-0.2450556457,
0.0937880352,
-0.0133095495,
0.2144186795,
0.002996546,
0.2994556725,
0.1801258177,
-0.0606589466,
-0.1818603873,
-0.038555339
] |
https://github.com/huggingface/datasets/issues/3339 | to_tf_dataset fails on TPU | Thank you for the explanation. I didn't realize the nuances of `tf.numpy_function`. In this scenario, would it be better to use `export(format='tfrecord')` ? It's not quite the same, but for very large datasets that don't fit in memory it looks like it is the only option. I haven't used `export` before, but I do recall reading that there are suggestions for how big and how many tfrecords there should be to not bottleneck the TPU. It might be nice if there were a way for the `export` method to split the files up into appropriate chunk sizes depending on the size of the dataset and the number of devices. And if that is too much, it would be nice to be able to specify the number of files that would be created when using `export`. Well... maybe the user should just do the chunking themselves and call `export` a bunch of times. Whatever the case, you have been helpful. Thanks Tensorflow boy ;-) | Using `to_tf_dataset` to create a dataset and then putting it in `model.fit` results in an internal error on TPUs. I've only tried on Colab and Kaggle TPUs, not GCP TPUs.
## Steps to reproduce the bug
I made a colab to show the error. https://colab.research.google.com/drive/12x_PFKzGouFxqD4OuWfnycW_1TaT276z?usp=sharing
## Expected results
dataset from `to_tf_dataset` works in `model.fit`
Right below the first error in the colab I use `tf.data.Dataset.from_tensor_slices` and `model.fit` works just fine. This is the desired outcome.
## Actual results
```
InternalError: 5 root error(s) found.
(0) INTERNAL: {{function_node __inference_train_function_30558}} failed to connect to all addresses
Additional GRPC error information from remote target /job:localhost/replica:0/task:0/device:CPU:0:
:{"created":"@1638231897.932218653","description":"Failed to pick subchannel","file":"third_party/grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3151,"referenced_errors":[{"created":"@1638231897.932216754","description":"failed to connect to all addresses","file":"third_party/grpc/src/core/lib/transport/error_utils.cc","file_line":161,"grpc_status":14}]}
[[{{node StatefulPartitionedCall}}]]
[[MultiDeviceIteratorGetNextFromShard]]
Executing non-communication op <MultiDeviceIteratorGetNextFromShard> originally returned UnavailableError, and was replaced by InternalError to avoid invoking TF network error handling logic.
[[RemoteCall]]
[[IteratorGetNextAsOptional]]
[[tpu_compile_succeeded_assert/_14023832043698465348/_7/_439]]
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.16.1
- Platform: Linux-5.4.104+-x86_64-with-Ubuntu-18.04-bionic
- Python version: 3.7.12
- PyArrow version: 3.0.0
- Tensorflow 2.7.0
- `transformers` 4.12.5
| 163 | to_tf_dataset fails on TPU
Using `to_tf_dataset` to create a dataset and then putting it in `model.fit` results in an internal error on TPUs. I've only tried on Colab and Kaggle TPUs, not GCP TPUs.
## Steps to reproduce the bug
I made a colab to show the error. https://colab.research.google.com/drive/12x_PFKzGouFxqD4OuWfnycW_1TaT276z?usp=sharing
## Expected results
dataset from `to_tf_dataset` works in `model.fit`
Right below the first error in the colab I use `tf.data.Dataset.from_tensor_slices` and `model.fit` works just fine. This is the desired outcome.
## Actual results
```
InternalError: 5 root error(s) found.
(0) INTERNAL: {{function_node __inference_train_function_30558}} failed to connect to all addresses
Additional GRPC error information from remote target /job:localhost/replica:0/task:0/device:CPU:0:
:{"created":"@1638231897.932218653","description":"Failed to pick subchannel","file":"third_party/grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3151,"referenced_errors":[{"created":"@1638231897.932216754","description":"failed to connect to all addresses","file":"third_party/grpc/src/core/lib/transport/error_utils.cc","file_line":161,"grpc_status":14}]}
[[{{node StatefulPartitionedCall}}]]
[[MultiDeviceIteratorGetNextFromShard]]
Executing non-communication op <MultiDeviceIteratorGetNextFromShard> originally returned UnavailableError, and was replaced by InternalError to avoid invoking TF network error handling logic.
[[RemoteCall]]
[[IteratorGetNextAsOptional]]
[[tpu_compile_succeeded_assert/_14023832043698465348/_7/_439]]
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.16.1
- Platform: Linux-5.4.104+-x86_64-with-Ubuntu-18.04-bionic
- Python version: 3.7.12
- PyArrow version: 3.0.0
- Tensorflow 2.7.0
- `transformers` 4.12.5
Thank you for the explanation. I didn't realize the nuances of `tf.numpy_function`. In this scenario, would it be better to use `export(format='tfrecord')` ? It's not quite the same, but for very large datasets that don't fit in memory it looks like it is the only option. I haven't used `export` before, but I do recall reading that there are suggestions for how big and how many tfrecords there should be to not bottleneck the TPU. It might be nice if there were a way for the `export` method to split the files up into appropriate chunk sizes depending on the size of the dataset and the number of devices. And if that is too much, it would be nice to be able to specify the number of files that would be created when using `export`. Well... maybe the user should just do the chunking themselves and call `export` a bunch of times. Whatever the case, you have been helpful. Thanks Tensorflow boy ;-) | [
-0.2377156913,
-0.1358828992,
0.1592501402,
0.2036827803,
0.4153629541,
0.0100355959,
0.3643489182,
0.0257144328,
-0.4569853246,
0.1801205426,
-0.0554240905,
0.2911762893,
0.2514830828,
0.4929235876,
0.1305931658,
-0.0885017514,
-0.14083004,
0.0494023189,
-0.0877252072,
-0.1319961995,
-0.1496612281,
0.401570648,
0.0868343338,
0.0567882359,
-0.5214211941,
-0.1575677842,
0.2263303548,
-0.0939755142,
0.1207184047,
0.1129213795,
0.3648658395,
-0.3170058429,
-0.181627661,
0.7030664682,
-0.0001187178,
0.3797948062,
-0.0694344267,
-0.1777595133,
-0.1031217948,
-0.0664446354,
-0.3455985785,
0.1405737251,
0.0220209807,
-0.0226529185,
-0.3122110367,
0.3715749383,
0.091908671,
0.327147752,
0.2484272867,
0.4748539329,
0.1062795669,
0.5870953798,
0.1409716308,
-0.1173629239,
-0.0748100206,
-0.1198629811,
-0.4575205743,
0.2642862201,
-0.2550958991,
0.008434481,
0.2066530734,
-0.2624971271,
0.1700141579,
-0.1378923506,
0.0388896167,
0.1986298859,
0.2847883999,
-0.5665248036,
0.0617814884,
0.3099964261,
0.4110126495,
-0.4460215569,
-0.3044812679,
-0.0078700436,
-0.1459916532,
-0.257471472,
0.2615571022,
-0.1098164022,
-0.2194308043,
0.2189638317,
-0.1486360282,
0.0512510501,
-0.1517456174,
0.0437368415,
-0.1780232489,
0.2540245652,
0.1723249257,
0.1105856374,
-0.0783793628,
-0.0591197871,
0.3977127373,
0.0053142062,
0.0010843854,
-0.1233213618,
-0.4784841537,
-0.2640333176,
-0.035225071,
-0.2578029335,
-0.1654641926,
-0.3697740734,
0.2542355061,
-0.1878967434,
0.0652358383,
0.1911206692,
0.2713412344,
-0.0521752089,
-0.4298447967,
0.4683071673,
-0.0494385473,
-0.2337642908,
-0.2360999733,
0.0086180829,
0.2236471176,
-0.2119260132,
-0.1250924468,
-0.2815614939,
0.0683930293,
-0.2035695463,
-0.2338639051,
0.0085222162,
-0.276479274,
0.2113040388,
-0.145904392,
0.016297359,
0.2459677905,
0.1817945093,
0.1868250072,
0.0181061663,
-0.3681666851,
0.1552917659,
-0.2345890999,
-0.1149433106,
-0.051060196,
0.0272473339,
0.048222214,
-0.2405117601,
-0.112962842,
-0.1761605293,
0.1284231246,
0.1661120653,
-0.0290869903,
-0.2764333785,
0.0377805717,
0.6523355842,
-0.0119726527,
-0.1389116198,
0.0409137979,
-0.2477667034,
-0.004475439,
0.1105828881,
-0.3303798437,
-0.3795882761,
0.1784085184,
0.0613013469,
-0.0765635967,
-0.1235888675,
-0.1698184162,
0.3062875867,
0.1762576401,
-0.3321533799,
-0.137178421,
-0.4028519094,
-0.5160397887,
-0.0465580709,
0.3421142399,
0.2293464839,
-0.3999686241,
0.1405466199,
0.3465245664,
-0.1311472505,
0.3667520285,
0.2631674409,
0.1796577126,
0.2890563309,
-0.0087553086,
0.120787248,
0.3746039271,
-0.0532492474,
-0.3076036274,
0.2929520607,
-0.4511580169,
-0.0498887971,
-0.3144190311,
-0.074894391,
-0.2482598871,
-0.1482324302,
0.1959412694,
0.3359014392,
-0.4545333385,
0.1155398414,
-0.355928421,
-0.1035044417,
0.0948313847,
0.0270726644,
0.1515791416,
0.1515682489,
0.1807979643,
0.0927195698,
0.1558757275,
-0.0527645163,
-0.146371305,
0.0524281599,
0.6204757094,
-0.3251644969,
0.0734889358,
0.355219394,
-0.245455429,
0.227078855,
0.0642021596,
0.4079866707,
0.1751741469,
0.1910035014,
0.0165361576,
0.2132797986,
0.2460155934,
-0.0692218691,
0.0280522928,
0.1479060948,
-0.2696961761,
-0.1228911877,
-0.012478481,
0.401840955,
-0.2534156442,
-0.0039208671,
-0.4376435578,
0.5116253495,
0.0371225029,
-0.3100266755,
0.0485630259,
0.1247183904,
0.0814706385,
0.0130942166,
-0.2894964814,
0.2103201151,
0.0579834282,
0.2898692489,
-0.1763061136,
0.3690994084,
0.0451593548,
-0.3981793225,
-0.42264539,
0.0784713924,
0.1535725296,
0.0689357072,
0.0463582203,
0.0261187274,
-0.0124220513,
-0.0486867689,
0.0855246633,
-0.0038226051,
0.0663367659,
0.0859495252,
0.1466535628,
-0.0413408354,
-0.1051914245,
0.1442933977,
-0.2223656625,
0.1559816003,
-0.4287632108,
0.4230032265,
0.3258286417,
0.0899129212,
-0.087971434,
0.1292704046,
0.2320270985,
-0.2631542683,
0.2595541775,
0.4011158943,
0.3372506201,
0.1074675843,
-0.031285163,
0.0652007982,
-0.3169073164,
-0.3241820037,
0.0318319313,
0.058880318,
0.1356631666,
0.3109446466,
0.2310613096,
0.4301351607,
-0.1165127158,
-0.0366036333,
0.0924786851,
0.2334310412,
-0.5189219117,
0.0243091881,
-0.1007748619,
-0.1003218293,
0.0185870156,
0.2401235998,
-0.003311923,
-0.3447381258,
-0.0645324513,
0.1211463138,
-0.2095202506,
0.1038530245,
-0.14294599,
0.1682709455,
0.0045915134,
-0.2821530402,
-0.0071255928,
-0.2306578308,
-0.2735158801,
0.0589576885,
0.1348590255,
0.3670639098,
0.0600000285,
-0.1300419271,
-0.1335043311,
0.1996670216,
-0.4904163182,
0.3301842213,
-0.2673294246,
0.6307036281,
0.0753396228,
0.1596300751,
-0.3512653112,
-0.3435929716,
0.19549869,
-0.2150817662,
-0.226736322,
0.1991049796,
-0.3109489083,
-0.1440780908,
-0.0591996536,
-0.2922247052,
-0.1498135477,
-0.2958478034,
0.1066616327,
-0.0361902639,
0.1189289466,
0.5792869925,
0.2318672836,
0.0879401341,
0.2316232324,
-0.1162112802,
-0.0752680153,
-0.0175886583,
0.2094079703,
-0.0206164829,
-0.305455178,
0.0456143767,
0.0830291063,
0.1659787893,
0.3440008163,
-0.5312432647,
-0.1311130077,
-0.2157509476,
0.0798155591,
0.0384741314,
-0.1743491888,
0.1771759689,
0.01826212,
0.0340932608,
-0.2266960889,
-0.4738584459,
0.2424235195,
0.6612286568,
0.1286108196,
0.0130047863,
0.3885802627,
-0.0767250806,
0.3667708337,
-0.0940793082,
-0.3093858361,
0.1707792133,
-0.2439338267,
0.1991696954,
-0.2772429585,
-0.1312865317,
0.4598912001,
-0.083759971,
-0.3251048028,
0.0416609645,
-0.2754912674,
-0.1894610375,
-0.1993924081,
0.0008013277,
-0.1722548008,
-0.3638682961,
0.0436517112,
0.1790497005,
0.17523323,
0.1977655888,
-0.0633706301,
-0.1011735722,
-0.1433611959,
-0.0638721883,
0.0281384569,
0.2383130789,
0.1677356958,
0.284989506,
-0.2148858607,
-0.4850689471,
0.0196997393,
0.155763343,
0.5570329428,
-0.4624986351,
-0.049285505,
-0.2705088258,
0.0526408479,
0.1381969452,
-0.5062898397,
0.1252445728,
0.4707213044,
-0.2327638865,
-0.2381845564,
0.1354453415,
-0.04023825,
-0.0775069296,
0.1454480737,
0.5163575411,
0.0244076252,
-0.0011555036,
0.102841109,
0.1391420066,
-0.0137606291,
0.0479761921,
-0.1127211526,
-0.4224164784,
0.0315473154,
-0.0520157702,
0.2348564565,
0.2681127787,
0.0090605887,
-0.0248570051,
0.0639617145,
0.0555859543,
-0.0136338184,
0.1730490923,
0.0811261162,
0.0432884954,
0.2867955267,
-0.1952414066,
0.1164328679,
0.270521611,
0.6125136018,
-0.0961357877,
-0.1644971967,
0.4197415709,
0.2101632655,
0.1094644368,
0.2773973644,
-0.1253114641,
-0.2054560781,
-0.3309932947,
0.1134591252,
0.3007660806,
0.2804313004,
-0.0181552209,
-0.0401604697,
-0.1287620366,
0.0228469595,
0.166452691,
-0.0307443105,
0.1580541283,
0.4151937366,
0.033031825,
-0.1036501676,
0.4487224817,
0.335606575,
0.7207568884,
0.0106940884,
0.0525911897,
0.5778244138,
0.0135507174,
0.4246169925,
-0.2746321261,
0.2748579979,
-0.2519744039,
-0.5210760832,
0.0441949777,
-0.1171971411,
-0.3844120204,
0.1134795249,
-0.1938159466,
0.0158413071,
0.4071490467,
0.0687509775,
0.3557627797,
0.0647052228,
0.3553376794,
-0.3262241781,
-0.3602842093,
0.1078309268,
0.0950333327,
-0.0484300219,
0.0105486661,
-0.2763650119,
-0.2692651749,
0.0536679775,
-0.1283836514,
0.2209372073,
-0.793356657,
-0.0858923793,
0.2042955011,
-0.2239294201,
0.154962033,
0.2518289387,
0.373355329,
0.1179984361,
-0.3078553081,
0.0873976573,
0.1203665137,
0.0649081469,
0.1244639903,
-0.0916919485,
0.474537462,
-0.1940166056,
-0.0660568476,
-0.1898191571,
-0.0558325388,
-0.2215318978,
0.4300836921,
-0.3863453269,
-0.435774982,
-0.0372986458,
-0.0546231717,
-0.0380802155,
-0.2631296217,
-0.063341856,
0.0647726059,
-0.1656986624,
-0.0996732637,
0.095204927,
-0.1294159591,
-0.3429450691,
0.0616355985,
0.2117563635,
-0.1679017842,
0.1182900295,
0.1500209719,
0.2262631357,
0.0406456254,
-0.1507024765,
0.1242414862,
0.1295841336,
-0.4625426233,
0.1372897476,
-0.1432674676,
-0.0740371272,
0.2033184022,
0.6734072566,
0.0757523775,
0.0588200316,
0.0195528921,
-0.0443896428,
-0.4824236929,
-0.0466347039,
-0.0589359067,
0.1743708551,
-0.0147307208,
0.6068685055,
0.185361132,
0.0985842124,
-0.224135384,
-0.1940156519,
-0.4560902417,
0.004823843,
0.2563571632,
-0.1427137703,
0.1501272023,
-0.0192628726,
0.0053430758,
0.3450675309,
-0.1361493617,
-0.1245510727,
0.0562012419,
0.1394144595,
0.5006350875,
-0.2530396283,
-0.2139217705,
0.2002836466,
-0.4576193988,
-0.167702809,
0.3107051849,
0.2047922462,
-0.2968538404,
-0.2138679326,
0.2578503489,
0.1204037443,
-0.1960658133,
-0.0265863333,
0.3249149024,
0.11860203,
0.0342661887,
0.0629600435,
-0.1406481713,
0.0397775806,
0.1906415522,
0.0736060441,
-0.0283294674,
0.0315635763,
0.2545517087,
-0.3750663102,
-0.2104622126,
-0.1406093687,
-0.0481709912,
-0.030850647,
-0.1764022708,
0.0688384026,
0.0254645497,
0.0473620556,
-0.0868703946,
0.0438387878,
0.464027971,
0.073264055,
-0.0526998937,
0.1923798323,
0.3951918781,
-0.0742517486,
-0.2395330966,
0.1657420993,
0.064168945,
-0.1330350637,
0.0289942455,
0.4475801289,
-0.1157911941,
0.366954565,
-0.2056462914,
-0.1071943641,
0.0172422323,
-0.0756315216,
0.0272690058,
-0.0004786641,
-0.2425743341,
-0.1459872574,
0.208420068,
-0.4114046991,
0.0355993435,
-0.0254087821,
-0.022808075,
0.1327159107,
-0.0852563754,
-0.098498933,
-0.1730840206,
-0.2286589295,
-0.1912234724,
0.1018280685,
-0.2621099949,
0.1494060308,
-0.1802429706,
-0.0455489531,
-0.2522966564,
-0.1624832302,
-0.2017872036,
0.0757135451,
0.0014230027,
0.1324417889,
-0.0869175345,
0.2283083498,
-0.4671306014,
0.0846142322,
-0.0741762072,
-0.0414437987,
0.5216245055,
-0.2772120237,
-0.391620636,
-0.2933711112,
0.3712118268,
0.4211888313,
0.0998307616,
0.1075814366,
0.1789456308,
0.3164710104,
0.1173969209,
0.2259040028,
0.2093449086,
-0.0680332333,
-0.0713440999,
0.3802039027,
-0.0306152627,
-0.0672217831,
-0.0244907588,
0.0067518856,
0.454017967,
-0.3554112911,
0.1385698467,
0.1038019508,
-0.0160817988,
-0.0885442123,
0.1836745143,
-0.0407799967,
0.2201063931,
0.5140337348,
-0.2947468758,
0.1866614372,
0.0398609601,
0.0568319187,
-0.1250899285,
0.6414741874,
0.2015043199,
0.0785873607,
-0.2548238635,
-0.0080224611,
-0.3166708052,
0.451793015,
-0.0249779671,
0.2112790644,
0.2599021792,
0.0018528112,
0.3646708429,
0.205744043,
-0.1213349998,
0.3731504083,
-0.0493989736,
0.1811481863,
-0.1128758937,
-0.3199303448,
-0.6019216776,
-0.1749903262,
-0.0303009152,
-0.0980022922,
0.0699096099,
0.0650304854,
0.0756998286,
0.0069905487,
-0.3138490319,
0.2409635633,
0.3974547386,
0.2500318587,
0.2661223114,
0.3924698532,
-0.1516639292,
0.058021497,
-0.1057915539,
-0.4218706191,
-0.3414775133,
-0.1440109313,
-0.218783021,
0.2718350291,
0.0243693832,
0.1895829588,
-0.2418980598,
-0.4366143048,
-0.0312265009,
0.2030085325,
0.190729335,
0.1129376516,
-0.1146407127,
0.0326742977,
0.5494960546,
0.2126706243,
0.1125396043,
0.0165644493,
-0.2421236783,
-0.3317566514,
0.2751049101,
-0.2684333622,
-0.0808742791,
-0.1443079114,
-0.0826439187,
0.0082007656,
0.2455913574,
-0.2214616835,
0.0346161351,
0.1733164787,
-0.1256736219,
-0.2450556457,
0.0937880352,
-0.0133095495,
0.2144186795,
0.002996546,
0.2994556725,
0.1801258177,
-0.0606589466,
-0.1818603873,
-0.038555339
] |
https://github.com/huggingface/datasets/issues/3339 | to_tf_dataset fails on TPU | Yeah, this is something we really should have a proper guide on. I'll make a note to test some things and make a 'TF TPU best practices' notebook at some point, but in the meantime I think your solution of exporting TFRecords will probably work. | Using `to_tf_dataset` to create a dataset and then putting it in `model.fit` results in an internal error on TPUs. I've only tried on Colab and Kaggle TPUs, not GCP TPUs.
## Steps to reproduce the bug
I made a colab to show the error. https://colab.research.google.com/drive/12x_PFKzGouFxqD4OuWfnycW_1TaT276z?usp=sharing
## Expected results
dataset from `to_tf_dataset` works in `model.fit`
Right below the first error in the colab I use `tf.data.Dataset.from_tensor_slices` and `model.fit` works just fine. This is the desired outcome.
## Actual results
```
InternalError: 5 root error(s) found.
(0) INTERNAL: {{function_node __inference_train_function_30558}} failed to connect to all addresses
Additional GRPC error information from remote target /job:localhost/replica:0/task:0/device:CPU:0:
:{"created":"@1638231897.932218653","description":"Failed to pick subchannel","file":"third_party/grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3151,"referenced_errors":[{"created":"@1638231897.932216754","description":"failed to connect to all addresses","file":"third_party/grpc/src/core/lib/transport/error_utils.cc","file_line":161,"grpc_status":14}]}
[[{{node StatefulPartitionedCall}}]]
[[MultiDeviceIteratorGetNextFromShard]]
Executing non-communication op <MultiDeviceIteratorGetNextFromShard> originally returned UnavailableError, and was replaced by InternalError to avoid invoking TF network error handling logic.
[[RemoteCall]]
[[IteratorGetNextAsOptional]]
[[tpu_compile_succeeded_assert/_14023832043698465348/_7/_439]]
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.16.1
- Platform: Linux-5.4.104+-x86_64-with-Ubuntu-18.04-bionic
- Python version: 3.7.12
- PyArrow version: 3.0.0
- Tensorflow 2.7.0
- `transformers` 4.12.5
| 45 | to_tf_dataset fails on TPU
Using `to_tf_dataset` to create a dataset and then putting it in `model.fit` results in an internal error on TPUs. I've only tried on Colab and Kaggle TPUs, not GCP TPUs.
## Steps to reproduce the bug
I made a colab to show the error. https://colab.research.google.com/drive/12x_PFKzGouFxqD4OuWfnycW_1TaT276z?usp=sharing
## Expected results
dataset from `to_tf_dataset` works in `model.fit`
Right below the first error in the colab I use `tf.data.Dataset.from_tensor_slices` and `model.fit` works just fine. This is the desired outcome.
## Actual results
```
InternalError: 5 root error(s) found.
(0) INTERNAL: {{function_node __inference_train_function_30558}} failed to connect to all addresses
Additional GRPC error information from remote target /job:localhost/replica:0/task:0/device:CPU:0:
:{"created":"@1638231897.932218653","description":"Failed to pick subchannel","file":"third_party/grpc/src/core/ext/filters/client_channel/client_channel.cc","file_line":3151,"referenced_errors":[{"created":"@1638231897.932216754","description":"failed to connect to all addresses","file":"third_party/grpc/src/core/lib/transport/error_utils.cc","file_line":161,"grpc_status":14}]}
[[{{node StatefulPartitionedCall}}]]
[[MultiDeviceIteratorGetNextFromShard]]
Executing non-communication op <MultiDeviceIteratorGetNextFromShard> originally returned UnavailableError, and was replaced by InternalError to avoid invoking TF network error handling logic.
[[RemoteCall]]
[[IteratorGetNextAsOptional]]
[[tpu_compile_succeeded_assert/_14023832043698465348/_7/_439]]
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.16.1
- Platform: Linux-5.4.104+-x86_64-with-Ubuntu-18.04-bionic
- Python version: 3.7.12
- PyArrow version: 3.0.0
- Tensorflow 2.7.0
- `transformers` 4.12.5
Yeah, this is something we really should have a proper guide on. I'll make a note to test some things and make a 'TF TPU best practices' notebook at some point, but in the meantime I think your solution of exporting TFRecords will probably work. | [
-0.2377156913,
-0.1358828992,
0.1592501402,
0.2036827803,
0.4153629541,
0.0100355959,
0.3643489182,
0.0257144328,
-0.4569853246,
0.1801205426,
-0.0554240905,
0.2911762893,
0.2514830828,
0.4929235876,
0.1305931658,
-0.0885017514,
-0.14083004,
0.0494023189,
-0.0877252072,
-0.1319961995,
-0.1496612281,
0.401570648,
0.0868343338,
0.0567882359,
-0.5214211941,
-0.1575677842,
0.2263303548,
-0.0939755142,
0.1207184047,
0.1129213795,
0.3648658395,
-0.3170058429,
-0.181627661,
0.7030664682,
-0.0001187178,
0.3797948062,
-0.0694344267,
-0.1777595133,
-0.1031217948,
-0.0664446354,
-0.3455985785,
0.1405737251,
0.0220209807,
-0.0226529185,
-0.3122110367,
0.3715749383,
0.091908671,
0.327147752,
0.2484272867,
0.4748539329,
0.1062795669,
0.5870953798,
0.1409716308,
-0.1173629239,
-0.0748100206,
-0.1198629811,
-0.4575205743,
0.2642862201,
-0.2550958991,
0.008434481,
0.2066530734,
-0.2624971271,
0.1700141579,
-0.1378923506,
0.0388896167,
0.1986298859,
0.2847883999,
-0.5665248036,
0.0617814884,
0.3099964261,
0.4110126495,
-0.4460215569,
-0.3044812679,
-0.0078700436,
-0.1459916532,
-0.257471472,
0.2615571022,
-0.1098164022,
-0.2194308043,
0.2189638317,
-0.1486360282,
0.0512510501,
-0.1517456174,
0.0437368415,
-0.1780232489,
0.2540245652,
0.1723249257,
0.1105856374,
-0.0783793628,
-0.0591197871,
0.3977127373,
0.0053142062,
0.0010843854,
-0.1233213618,
-0.4784841537,
-0.2640333176,
-0.035225071,
-0.2578029335,
-0.1654641926,
-0.3697740734,
0.2542355061,
-0.1878967434,
0.0652358383,
0.1911206692,
0.2713412344,
-0.0521752089,
-0.4298447967,
0.4683071673,
-0.0494385473,
-0.2337642908,
-0.2360999733,
0.0086180829,
0.2236471176,
-0.2119260132,
-0.1250924468,
-0.2815614939,
0.0683930293,
-0.2035695463,
-0.2338639051,
0.0085222162,
-0.276479274,
0.2113040388,
-0.145904392,
0.016297359,
0.2459677905,
0.1817945093,
0.1868250072,
0.0181061663,
-0.3681666851,
0.1552917659,
-0.2345890999,
-0.1149433106,
-0.051060196,
0.0272473339,
0.048222214,
-0.2405117601,
-0.112962842,
-0.1761605293,
0.1284231246,
0.1661120653,
-0.0290869903,
-0.2764333785,
0.0377805717,
0.6523355842,
-0.0119726527,
-0.1389116198,
0.0409137979,
-0.2477667034,
-0.004475439,
0.1105828881,
-0.3303798437,
-0.3795882761,
0.1784085184,
0.0613013469,
-0.0765635967,
-0.1235888675,
-0.1698184162,
0.3062875867,
0.1762576401,
-0.3321533799,
-0.137178421,
-0.4028519094,
-0.5160397887,
-0.0465580709,
0.3421142399,
0.2293464839,
-0.3999686241,
0.1405466199,
0.3465245664,
-0.1311472505,
0.3667520285,
0.2631674409,
0.1796577126,
0.2890563309,
-0.0087553086,
0.120787248,
0.3746039271,
-0.0532492474,
-0.3076036274,
0.2929520607,
-0.4511580169,
-0.0498887971,
-0.3144190311,
-0.074894391,
-0.2482598871,
-0.1482324302,
0.1959412694,
0.3359014392,
-0.4545333385,
0.1155398414,
-0.355928421,
-0.1035044417,
0.0948313847,
0.0270726644,
0.1515791416,
0.1515682489,
0.1807979643,
0.0927195698,
0.1558757275,
-0.0527645163,
-0.146371305,
0.0524281599,
0.6204757094,
-0.3251644969,
0.0734889358,
0.355219394,
-0.245455429,
0.227078855,
0.0642021596,
0.4079866707,
0.1751741469,
0.1910035014,
0.0165361576,
0.2132797986,
0.2460155934,
-0.0692218691,
0.0280522928,
0.1479060948,
-0.2696961761,
-0.1228911877,
-0.012478481,
0.401840955,
-0.2534156442,
-0.0039208671,
-0.4376435578,
0.5116253495,
0.0371225029,
-0.3100266755,
0.0485630259,
0.1247183904,
0.0814706385,
0.0130942166,
-0.2894964814,
0.2103201151,
0.0579834282,
0.2898692489,
-0.1763061136,
0.3690994084,
0.0451593548,
-0.3981793225,
-0.42264539,
0.0784713924,
0.1535725296,
0.0689357072,
0.0463582203,
0.0261187274,
-0.0124220513,
-0.0486867689,
0.0855246633,
-0.0038226051,
0.0663367659,
0.0859495252,
0.1466535628,
-0.0413408354,
-0.1051914245,
0.1442933977,
-0.2223656625,
0.1559816003,
-0.4287632108,
0.4230032265,
0.3258286417,
0.0899129212,
-0.087971434,
0.1292704046,
0.2320270985,
-0.2631542683,
0.2595541775,
0.4011158943,
0.3372506201,
0.1074675843,
-0.031285163,
0.0652007982,
-0.3169073164,
-0.3241820037,
0.0318319313,
0.058880318,
0.1356631666,
0.3109446466,
0.2310613096,
0.4301351607,
-0.1165127158,
-0.0366036333,
0.0924786851,
0.2334310412,
-0.5189219117,
0.0243091881,
-0.1007748619,
-0.1003218293,
0.0185870156,
0.2401235998,
-0.003311923,
-0.3447381258,
-0.0645324513,
0.1211463138,
-0.2095202506,
0.1038530245,
-0.14294599,
0.1682709455,
0.0045915134,
-0.2821530402,
-0.0071255928,
-0.2306578308,
-0.2735158801,
0.0589576885,
0.1348590255,
0.3670639098,
0.0600000285,
-0.1300419271,
-0.1335043311,
0.1996670216,
-0.4904163182,
0.3301842213,
-0.2673294246,
0.6307036281,
0.0753396228,
0.1596300751,
-0.3512653112,
-0.3435929716,
0.19549869,
-0.2150817662,
-0.226736322,
0.1991049796,
-0.3109489083,
-0.1440780908,
-0.0591996536,
-0.2922247052,
-0.1498135477,
-0.2958478034,
0.1066616327,
-0.0361902639,
0.1189289466,
0.5792869925,
0.2318672836,
0.0879401341,
0.2316232324,
-0.1162112802,
-0.0752680153,
-0.0175886583,
0.2094079703,
-0.0206164829,
-0.305455178,
0.0456143767,
0.0830291063,
0.1659787893,
0.3440008163,
-0.5312432647,
-0.1311130077,
-0.2157509476,
0.0798155591,
0.0384741314,
-0.1743491888,
0.1771759689,
0.01826212,
0.0340932608,
-0.2266960889,
-0.4738584459,
0.2424235195,
0.6612286568,
0.1286108196,
0.0130047863,
0.3885802627,
-0.0767250806,
0.3667708337,
-0.0940793082,
-0.3093858361,
0.1707792133,
-0.2439338267,
0.1991696954,
-0.2772429585,
-0.1312865317,
0.4598912001,
-0.083759971,
-0.3251048028,
0.0416609645,
-0.2754912674,
-0.1894610375,
-0.1993924081,
0.0008013277,
-0.1722548008,
-0.3638682961,
0.0436517112,
0.1790497005,
0.17523323,
0.1977655888,
-0.0633706301,
-0.1011735722,
-0.1433611959,
-0.0638721883,
0.0281384569,
0.2383130789,
0.1677356958,
0.284989506,
-0.2148858607,
-0.4850689471,
0.0196997393,
0.155763343,
0.5570329428,
-0.4624986351,
-0.049285505,
-0.2705088258,
0.0526408479,
0.1381969452,
-0.5062898397,
0.1252445728,
0.4707213044,
-0.2327638865,
-0.2381845564,
0.1354453415,
-0.04023825,
-0.0775069296,
0.1454480737,
0.5163575411,
0.0244076252,
-0.0011555036,
0.102841109,
0.1391420066,
-0.0137606291,
0.0479761921,
-0.1127211526,
-0.4224164784,
0.0315473154,
-0.0520157702,
0.2348564565,
0.2681127787,
0.0090605887,
-0.0248570051,
0.0639617145,
0.0555859543,
-0.0136338184,
0.1730490923,
0.0811261162,
0.0432884954,
0.2867955267,
-0.1952414066,
0.1164328679,
0.270521611,
0.6125136018,
-0.0961357877,
-0.1644971967,
0.4197415709,
0.2101632655,
0.1094644368,
0.2773973644,
-0.1253114641,
-0.2054560781,
-0.3309932947,
0.1134591252,
0.3007660806,
0.2804313004,
-0.0181552209,
-0.0401604697,
-0.1287620366,
0.0228469595,
0.166452691,
-0.0307443105,
0.1580541283,
0.4151937366,
0.033031825,
-0.1036501676,
0.4487224817,
0.335606575,
0.7207568884,
0.0106940884,
0.0525911897,
0.5778244138,
0.0135507174,
0.4246169925,
-0.2746321261,
0.2748579979,
-0.2519744039,
-0.5210760832,
0.0441949777,
-0.1171971411,
-0.3844120204,
0.1134795249,
-0.1938159466,
0.0158413071,
0.4071490467,
0.0687509775,
0.3557627797,
0.0647052228,
0.3553376794,
-0.3262241781,
-0.3602842093,
0.1078309268,
0.0950333327,
-0.0484300219,
0.0105486661,
-0.2763650119,
-0.2692651749,
0.0536679775,
-0.1283836514,
0.2209372073,
-0.793356657,
-0.0858923793,
0.2042955011,
-0.2239294201,
0.154962033,
0.2518289387,
0.373355329,
0.1179984361,
-0.3078553081,
0.0873976573,
0.1203665137,
0.0649081469,
0.1244639903,
-0.0916919485,
0.474537462,
-0.1940166056,
-0.0660568476,
-0.1898191571,
-0.0558325388,
-0.2215318978,
0.4300836921,
-0.3863453269,
-0.435774982,
-0.0372986458,
-0.0546231717,
-0.0380802155,
-0.2631296217,
-0.063341856,
0.0647726059,
-0.1656986624,
-0.0996732637,
0.095204927,
-0.1294159591,
-0.3429450691,
0.0616355985,
0.2117563635,
-0.1679017842,
0.1182900295,
0.1500209719,
0.2262631357,
0.0406456254,
-0.1507024765,
0.1242414862,
0.1295841336,
-0.4625426233,
0.1372897476,
-0.1432674676,
-0.0740371272,
0.2033184022,
0.6734072566,
0.0757523775,
0.0588200316,
0.0195528921,
-0.0443896428,
-0.4824236929,
-0.0466347039,
-0.0589359067,
0.1743708551,
-0.0147307208,
0.6068685055,
0.185361132,
0.0985842124,
-0.224135384,
-0.1940156519,
-0.4560902417,
0.004823843,
0.2563571632,
-0.1427137703,
0.1501272023,
-0.0192628726,
0.0053430758,
0.3450675309,
-0.1361493617,
-0.1245510727,
0.0562012419,
0.1394144595,
0.5006350875,
-0.2530396283,
-0.2139217705,
0.2002836466,
-0.4576193988,
-0.167702809,
0.3107051849,
0.2047922462,
-0.2968538404,
-0.2138679326,
0.2578503489,
0.1204037443,
-0.1960658133,
-0.0265863333,
0.3249149024,
0.11860203,
0.0342661887,
0.0629600435,
-0.1406481713,
0.0397775806,
0.1906415522,
0.0736060441,
-0.0283294674,
0.0315635763,
0.2545517087,
-0.3750663102,
-0.2104622126,
-0.1406093687,
-0.0481709912,
-0.030850647,
-0.1764022708,
0.0688384026,
0.0254645497,
0.0473620556,
-0.0868703946,
0.0438387878,
0.464027971,
0.073264055,
-0.0526998937,
0.1923798323,
0.3951918781,
-0.0742517486,
-0.2395330966,
0.1657420993,
0.064168945,
-0.1330350637,
0.0289942455,
0.4475801289,
-0.1157911941,
0.366954565,
-0.2056462914,
-0.1071943641,
0.0172422323,
-0.0756315216,
0.0272690058,
-0.0004786641,
-0.2425743341,
-0.1459872574,
0.208420068,
-0.4114046991,
0.0355993435,
-0.0254087821,
-0.022808075,
0.1327159107,
-0.0852563754,
-0.098498933,
-0.1730840206,
-0.2286589295,
-0.1912234724,
0.1018280685,
-0.2621099949,
0.1494060308,
-0.1802429706,
-0.0455489531,
-0.2522966564,
-0.1624832302,
-0.2017872036,
0.0757135451,
0.0014230027,
0.1324417889,
-0.0869175345,
0.2283083498,
-0.4671306014,
0.0846142322,
-0.0741762072,
-0.0414437987,
0.5216245055,
-0.2772120237,
-0.391620636,
-0.2933711112,
0.3712118268,
0.4211888313,
0.0998307616,
0.1075814366,
0.1789456308,
0.3164710104,
0.1173969209,
0.2259040028,
0.2093449086,
-0.0680332333,
-0.0713440999,
0.3802039027,
-0.0306152627,
-0.0672217831,
-0.0244907588,
0.0067518856,
0.454017967,
-0.3554112911,
0.1385698467,
0.1038019508,
-0.0160817988,
-0.0885442123,
0.1836745143,
-0.0407799967,
0.2201063931,
0.5140337348,
-0.2947468758,
0.1866614372,
0.0398609601,
0.0568319187,
-0.1250899285,
0.6414741874,
0.2015043199,
0.0785873607,
-0.2548238635,
-0.0080224611,
-0.3166708052,
0.451793015,
-0.0249779671,
0.2112790644,
0.2599021792,
0.0018528112,
0.3646708429,
0.205744043,
-0.1213349998,
0.3731504083,
-0.0493989736,
0.1811481863,
-0.1128758937,
-0.3199303448,
-0.6019216776,
-0.1749903262,
-0.0303009152,
-0.0980022922,
0.0699096099,
0.0650304854,
0.0756998286,
0.0069905487,
-0.3138490319,
0.2409635633,
0.3974547386,
0.2500318587,
0.2661223114,
0.3924698532,
-0.1516639292,
0.058021497,
-0.1057915539,
-0.4218706191,
-0.3414775133,
-0.1440109313,
-0.218783021,
0.2718350291,
0.0243693832,
0.1895829588,
-0.2418980598,
-0.4366143048,
-0.0312265009,
0.2030085325,
0.190729335,
0.1129376516,
-0.1146407127,
0.0326742977,
0.5494960546,
0.2126706243,
0.1125396043,
0.0165644493,
-0.2421236783,
-0.3317566514,
0.2751049101,
-0.2684333622,
-0.0808742791,
-0.1443079114,
-0.0826439187,
0.0082007656,
0.2455913574,
-0.2214616835,
0.0346161351,
0.1733164787,
-0.1256736219,
-0.2450556457,
0.0937880352,
-0.0133095495,
0.2144186795,
0.002996546,
0.2994556725,
0.1801258177,
-0.0606589466,
-0.1818603873,
-0.038555339
] |
https://github.com/huggingface/datasets/issues/3337 | Typing of Dataset.__getitem__ could be improved. | Hi ! Thanks for the suggestion, I didn't know about this decorator.
If you are interesting in contributing, feel free to open a pull request to add the overload methods for each typing combination :) To assign you to this issue, you can comment `#self-assign` in this thread.
`Dataset.__getitem__` is defined right here: https://github.com/huggingface/datasets/blob/e6f1352fe19679de897f3d962e616936a17094f5/src/datasets/arrow_dataset.py#L1840 | ## Describe the bug
The newly added typing for Dataset.__getitem__ is Union[Dict, List]. This makes tools like mypy a bit awkward to use as we need to check the type manually. We could use type overloading to make this easier. [Documentation](https://docs.python.org/3/library/typing.html#typing.overload)
## Steps to reproduce the bug
Let's have a file `test.py`
```python
from typing import List, Dict, Any
from datasets import Dataset
ds = Dataset.from_dict({
'a': [1,2,3],
'b': ["1", "2", "3"]
})
one_colum: List[str] = ds['a']
some_index: Dict[Any, Any] = ds[1]
```
## Expected results
Running `mypy test.py` should not give any error.
## Actual results
```
test.py:10: error: Incompatible types in assignment (expression has type "Union[Dict[Any, Any], List[Any]]", variable has type "List[str]")
test.py:11: error: Incompatible types in assignment (expression has type "Union[Dict[Any, Any], List[Any]]", variable has type "Dict[Any, Any]")
Found 2 errors in 1 file (checked 1 source file)
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.13.3
- Platform: macOS-10.16-x86_64-i386-64bit
- Python version: 3.8.8
- PyArrow version: 6.0.1
| 54 | Typing of Dataset.__getitem__ could be improved.
## Describe the bug
The newly added typing for Dataset.__getitem__ is Union[Dict, List]. This makes tools like mypy a bit awkward to use as we need to check the type manually. We could use type overloading to make this easier. [Documentation](https://docs.python.org/3/library/typing.html#typing.overload)
## Steps to reproduce the bug
Let's have a file `test.py`
```python
from typing import List, Dict, Any
from datasets import Dataset
ds = Dataset.from_dict({
'a': [1,2,3],
'b': ["1", "2", "3"]
})
one_colum: List[str] = ds['a']
some_index: Dict[Any, Any] = ds[1]
```
## Expected results
Running `mypy test.py` should not give any error.
## Actual results
```
test.py:10: error: Incompatible types in assignment (expression has type "Union[Dict[Any, Any], List[Any]]", variable has type "List[str]")
test.py:11: error: Incompatible types in assignment (expression has type "Union[Dict[Any, Any], List[Any]]", variable has type "Dict[Any, Any]")
Found 2 errors in 1 file (checked 1 source file)
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.13.3
- Platform: macOS-10.16-x86_64-i386-64bit
- Python version: 3.8.8
- PyArrow version: 6.0.1
Hi ! Thanks for the suggestion, I didn't know about this decorator.
If you are interesting in contributing, feel free to open a pull request to add the overload methods for each typing combination :) To assign you to this issue, you can comment `#self-assign` in this thread.
`Dataset.__getitem__` is defined right here: https://github.com/huggingface/datasets/blob/e6f1352fe19679de897f3d962e616936a17094f5/src/datasets/arrow_dataset.py#L1840 | [
-0.2796022892,
-0.0664095283,
-0.0474868305,
0.262614429,
0.2142491788,
0.0547710843,
0.2549815774,
0.2996378839,
-0.0091785342,
0.0392907523,
0.0025685763,
0.4478225708,
-0.0814645141,
-0.0109510459,
-0.1863645613,
0.1429159939,
-0.0522088856,
-0.0558121763,
-0.0211947504,
-0.062976867,
-0.4044336677,
-0.0674049184,
-0.3512150645,
0.0151487626,
0.0128554432,
-0.2228805721,
-0.1409818083,
0.1535912156,
-0.1487655342,
-0.3038251698,
0.2481650114,
0.3039277196,
-0.0327398479,
0.2038253695,
-0.0001065116,
-0.0136200907,
0.3284390569,
-0.0232826844,
-0.435105443,
-0.3687723875,
0.0240747873,
-0.3340192735,
0.1772280782,
-0.193883121,
-0.0166596603,
-0.4151796997,
-0.1775921285,
-0.1853571087,
-0.0326844193,
0.1454485059,
0.2430755645,
0.360787034,
0.0685977638,
-0.144119367,
0.3199517131,
0.3037068546,
0.0098496769,
0.0882955194,
0.5188885331,
0.0147876991,
0.1696603894,
-0.0611496903,
-0.3055456281,
0.0719096288,
0.0347743072,
0.1830783933,
0.0074509671,
0.0611500703,
-0.0064468435,
0.1542085409,
0.4755382836,
-0.2544187903,
-0.3730419874,
-0.1602843553,
0.054194577,
-0.1839572638,
0.1542216241,
-0.0073541151,
-0.1935938299,
0.0478637964,
0.1324908584,
0.0566960946,
0.0288909059,
0.3768603802,
-0.000717356,
0.2198068649,
-0.1891785264,
0.152048856,
0.1567245275,
-0.1045779437,
0.1624635905,
-0.1003980711,
-0.1079102904,
0.1523641348,
-0.1989558041,
-0.1655279696,
0.1633061618,
0.1905063987,
0.0704546347,
0.1820978224,
0.0495836809,
0.1806574017,
-0.2978617251,
0.2671373785,
0.618426621,
0.052629333,
0.0447510257,
0.4063335657,
0.0557260774,
0.1749698371,
-0.0967900977,
0.1385848969,
0.1108839065,
-0.2377769947,
0.2419948578,
0.1733099818,
0.4391001463,
-0.1246812269,
-0.4228262901,
-0.0432099365,
-0.1312478334,
-0.1781645119,
0.1670830697,
0.3955493867,
-0.1682320833,
0.040157944,
0.0233479626,
0.3062453568,
-0.0432143621,
-0.1581343263,
-0.2335503697,
0.2383704782,
0.0201740582,
-0.2095246166,
0.0974878967,
0.1135699302,
-0.1247684285,
0.3159053326,
0.2518858612,
-0.0152661456,
0.0434117801,
-0.1543094516,
0.2863591909,
-0.054459177,
0.0041961963,
0.079422392,
0.3952661455,
-0.5772262216,
-0.2667461932,
-0.1275113374,
-0.2022867203,
-0.1471027434,
-0.0997003913,
0.2397101969,
0.0149676427,
0.0599063747,
-0.5099042654,
0.0382077843,
0.089581497,
-0.0090131257,
-0.027848307,
-0.1388060898,
0.0365501158,
-0.3465172946,
0.0883143246,
0.2977977395,
-0.2803248763,
0.0200109072,
-0.221866101,
-0.0866009071,
0.2857556939,
0.2482025027,
-0.1637759805,
0.0854368135,
-0.2965476215,
-0.2305731028,
0.4879125357,
-0.1577480584,
-0.3666644096,
0.1320343763,
0.0957010984,
0.2301549166,
-0.0255683772,
-0.0123714367,
0.1269333065,
-0.2514193356,
0.2697210014,
0.0997306779,
0.0339657292,
-0.1119746566,
-0.3627689779,
-0.1752889454,
0.2077656686,
-0.121901527,
-0.2117949575,
0.0882813185,
-0.0303944089,
-0.3006584048,
0.2887593806,
-0.1460958421,
-0.1627717763,
0.0552928969,
0.3377375901,
0.2344460487,
0.0556504615,
-0.0962403566,
-0.4533874094,
0.1052768975,
0.1079089642,
0.267893672,
-0.4865045249,
-0.3877125978,
-0.0425436012,
0.0735733956,
-0.3656573892,
0.0511283018,
0.2038023472,
0.1148201153,
0.1551491022,
-0.1428939402,
0.0237295553,
-0.0555862375,
-0.1853064448,
0.0318891928,
-0.1272137761,
0.080911383,
0.0534985624,
-0.1363701522,
-0.1341291815,
0.2929622233,
0.0831591859,
-0.0863516629,
-0.0486012474,
0.213978231,
0.2388865501,
-0.1766700894,
-0.3539279699,
-0.005783461,
0.0110869445,
-0.0440077186,
-0.1972834468,
0.1135690212,
0.0527294017,
-0.047034312,
-0.1163835004,
0.6227251291,
-0.1970679164,
0.1833122522,
-0.1425445676,
0.0899821818,
0.1153505296,
0.2138426304,
-0.0477778316,
-0.4353244305,
-0.04726924,
0.3997893631,
0.1384519637,
0.0750222206,
-0.3753089607,
0.0959940851,
0.1255281717,
-0.0023151934,
0.4840839803,
-0.0193727743,
0.1247450039,
0.0681099668,
-0.1985037625,
0.1477678567,
0.5327912569,
0.2021311522,
-0.0856720507,
0.0717660785,
-0.028346274,
-0.0357356183,
0.1984356791,
0.0653792024,
-0.1585174054,
-0.2034297734,
0.1496975124,
0.0546601452,
-0.003387586,
0.0678649321,
-0.1354679465,
0.4031822979,
-0.413834691,
-0.0116246035,
-0.5524863005,
-0.1250686049,
-0.1896511763,
0.0707700923,
0.0613801852,
-0.3632348478,
-0.2144396156,
-0.0272506047,
-0.0964697376,
0.0766007528,
0.1910220534,
0.080841586,
0.0133176912,
-0.4815385938,
0.2559185624,
-0.2066607922,
-0.3399110734,
0.1311070472,
0.3597626686,
-0.1295370907,
0.3798180819,
0.075991787,
-0.1888564825,
-0.1901475787,
-0.3298048079,
0.1118971109,
-0.1700221151,
0.0926393718,
0.61581707,
0.2519293129,
-0.0133002847,
-0.4168690741,
0.2064260095,
0.0888149738,
-0.1660304219,
0.1280056983,
0.1207987219,
-0.1967271715,
-0.2331974953,
-0.1772845834,
-0.3471643925,
-0.3320070803,
0.3797878623,
0.0406690836,
0.2066346556,
-0.1206040978,
-0.027176965,
0.0175669398,
0.0109275756,
0.2905511856,
-0.2859281301,
-0.1140550524,
0.3358368576,
0.0643341541,
-0.2079266459,
-0.2164973766,
-0.35174945,
0.0502877869,
-0.0333638228,
-0.2998277545,
-0.3190508187,
-0.0641168281,
0.4638201594,
0.0675681159,
0.2006416768,
0.1210058928,
0.3785342574,
-0.121568419,
-0.1298147291,
-0.0126091884,
-0.1152309775,
0.0932177529,
0.0271595772,
0.1062432751,
0.0284794979,
-0.0303543713,
0.3134739399,
0.3495991528,
-0.2811840773,
0.3105437458,
-0.1921563447,
0.17943497,
-0.0567952543,
-0.5907226205,
-0.2905480862,
-0.116141215,
-0.0071065412,
0.1610617489,
-0.2289995849,
-0.2312005907,
-0.0477797948,
-0.0100890594,
-0.1940448433,
-0.4878822565,
0.1939696223,
-0.0493652858,
-0.1275152713,
-0.0359777138,
0.1133367568,
-0.1335929632,
0.0218892209,
0.2212483585,
0.1692975163,
-0.4124911129,
-0.2251180857,
-0.3189085424,
-0.2587536871,
0.0053245192,
0.377322644,
0.0896736532,
0.1873203963,
0.2162250876,
-0.1519013345,
-0.1974112988,
0.1285243332,
0.5627636909,
-0.5325298905,
-0.1684951931,
0.1895119101,
0.0238863546,
-0.2176803797,
-0.0414135233,
-0.2267187834,
0.3740670085,
0.176375702,
0.4700760841,
-0.2755717337,
-0.1524495929,
0.2990037799,
0.2586216927,
-0.0909592584,
-0.0555491261,
-0.2701479197,
-0.3359208703,
-0.0925010592,
0.0076313517,
0.120384939,
0.3168711066,
0.0163306259,
0.0147679197,
-0.3122981489,
0.0154831298,
0.2914529741,
0.0095241955,
0.4702901542,
-0.0554130934,
0.0840186775,
-0.1117363945,
0.2147882283,
0.336722672,
0.6354139447,
-0.2957417369,
-0.619247973,
-0.0246738717,
-0.2115582228,
0.4302344918,
0.041900266,
-0.1830987483,
0.2715955079,
-0.297888726,
0.0775192082,
-0.2486502826,
-0.0722732618,
0.2444065362,
0.1277003586,
-0.238644585,
-0.7209606767,
0.4090701044,
0.2944042981,
-0.0529447608,
0.3387177289,
0.2224580497,
-0.3635887802,
0.395880729,
0.1669404805,
0.7942460775,
0.1660560817,
0.0354651138,
0.1905630082,
0.1310753971,
0.4491100609,
0.2719234228,
-0.0776662976,
-0.2220377326,
-0.2672673166,
0.017542446,
-0.2045957595,
0.2140194923,
0.0485848375,
-0.6654350162,
0.246040076,
-0.5236364603,
0.1517446339,
0.1159525067,
0.3012497127,
-0.1945955753,
-0.0651856437,
-0.158876732,
0.1311975569,
0.1629864126,
-0.0412308238,
0.0611908138,
0.0536398254,
-0.0743526369,
-0.1743151695,
-0.4620513618,
-0.1146173924,
-0.2778320909,
0.3187304735,
0.2900184393,
-0.0121877166,
0.5403353572,
0.2164749354,
0.1346751899,
0.321220547,
0.004359331,
-0.0960847139,
0.3098760247,
0.3537328839,
0.1141645983,
-0.1622699648,
0.3218625784,
0.2169443071,
-0.0446134061,
0.1081365868,
0.0377003849,
0.1283408403,
-0.1309261173,
0.1738066822,
0.0622481406,
-0.6301295757,
-0.2826620042,
-0.1298517734,
0.0610263012,
-0.2067145407,
0.1633213609,
0.1617761701,
-0.1596037745,
0.3297953308,
0.0218352657,
-0.2484065592,
0.0068576732,
0.1638349742,
0.2956539392,
-0.0006788447,
0.4913626313,
0.1465239227,
-0.1930167079,
-0.3153566718,
0.2468998432,
0.1777416617,
-0.2670606673,
0.4268441498,
-0.2039185464,
0.068577759,
0.0644777343,
0.3335309625,
0.0129091423,
0.2594059408,
-0.3463073969,
-0.2694501281,
0.0035210589,
0.1963197142,
0.358263582,
0.1613542289,
-0.1079623178,
0.1552136391,
-0.1052980721,
-0.0444983803,
-0.4013831019,
-0.1680880487,
-0.1192974821,
0.0514472462,
-0.0530614778,
-0.0009606692,
0.2084301114,
0.0012583591,
0.292311132,
0.0163512491,
0.0023266922,
-0.2801184058,
-0.1416259855,
0.0703856051,
-0.2352384776,
0.058925949,
0.0784760267,
-0.0346697867,
0.1042151973,
-0.2789613008,
-0.0579211749,
-0.0441226661,
0.0004714112,
0.1225083396,
0.3078541756,
0.0785953104,
-0.1180775017,
0.0353355221,
-0.3075398505,
0.0931350514,
0.1973363906,
0.2546813786,
-0.0020499728,
-0.0497080125,
0.2352343053,
0.2729166448,
0.1113613099,
-0.0544878095,
0.0647615939,
-0.1569723785,
-0.1346291155,
0.1085531563,
0.2909243703,
0.4231290817,
-0.0195773318,
-0.1578873247,
0.0794144794,
0.231228143,
-0.3293629587,
-0.055917386,
0.1575553864,
0.150383994,
0.2122109383,
0.5638538599,
-0.26031214,
-0.0232410263,
-0.2008129358,
-0.2866866291,
0.3272131085,
-0.3607384562,
0.3233345151,
0.3867396116,
0.1464571804,
-0.1238745376,
0.1169860885,
0.0279681906,
0.1260960847,
-0.1222903952,
-0.0871784091,
0.0651242882,
-0.029632939,
-0.0792222247,
0.3036196828,
-0.3095431924,
0.6653962731,
0.32263726,
-0.0570463799,
0.1280767769,
0.1019462645,
0.4953681529,
-0.2213779986,
0.0483605191,
0.0731269494,
0.1042274907,
-0.1350301355,
-0.1769699156,
-0.0217062365,
-0.1053060293,
-0.3541707993,
-0.2637284994,
0.0957868099,
-0.4576804638,
-0.212077722,
-0.1158125773,
0.2537442148,
-0.4005762041,
0.2789246142,
-0.1997974366,
0.3453926742,
-0.1694005579,
-0.0581316054,
0.2541085482,
0.091606386,
0.0001182982,
0.083621487,
0.5898519754,
0.5907136798,
-0.2560918033,
-0.0920148864,
-0.240917027,
-0.1859837472,
-0.2189225405,
-0.1356481761,
-0.3270620108,
-0.0497313552,
0.2962363064,
0.2410627156,
-0.1394643933,
-0.149065122,
0.1195565313,
-0.0028037138,
-0.1599690467,
0.617713809,
-0.0035460198,
-0.2395348698,
-0.098119311,
0.0291044973,
-0.2856376767,
-0.4152321815,
0.5212286711,
0.2530001104,
0.2037751675,
0.1350676268,
0.1662145555,
0.1682378501,
0.4293179512,
0.2705540657,
0.236334011,
-0.2016277909,
0.0863233358,
-0.5376328826,
0.1386292577,
0.015073441,
-0.4867238998,
0.299434185,
0.5338932872,
0.1141512096,
0.145161882,
0.1522628218,
0.0069691632,
0.1025502682,
0.2309766561,
-0.2790846825,
-0.3037138581,
-0.0010894517,
-0.2525641918,
0.0350746326,
-0.2686050832,
-0.0551922433,
-0.2541101575,
0.1819713712,
-0.3898144662,
-0.0909061655,
0.0458048917,
0.043544963,
0.2162008882,
0.0623651929,
0.1838320345,
0.0046361545,
-0.0263068713,
-0.0536712408,
-0.1131511256,
-0.1223370284,
0.5583117604,
0.1340253353,
0.1007717252,
-0.128154397,
0.1024554446,
-0.2520332038,
0.0864054188,
0.2723734677,
-0.2634895146,
-0.2493172288,
0.4293448627,
0.0723553449,
-0.0555134304,
-0.2927335799,
0.0119154677,
0.0216391943,
0.2238797247,
-0.0397557765,
-0.4481374323,
0.4462409616,
-0.2653863728,
-0.1552029699,
-0.2167512774,
0.1836298853,
-0.2750813663,
-0.028980311,
-0.3704345822,
-0.2622202933,
0.5128495097,
-0.0818513632,
-0.1903055757,
0.2471524328,
0.0653875396,
0.1789705157,
-0.1748546809,
0.112932615,
-0.1325937808,
-0.1212325469,
0.2352540046,
-0.2211929858
] |
https://github.com/huggingface/datasets/issues/3333 | load JSON files, get the errors | Hi ! The message you're getting is not an error. It simply says that your JSON dataset is being prepared to a location in `/root/.cache/huggingface/datasets` | Hi, does this bug be fixed? when I load JSON files, I get the same errors by the command
`!python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/`
change the dateset to load json by refering to https://huggingface.co/docs/datasets/loading.html
`dataset = datasets.load_dataset('json', data_files=args.dataset)`
Errors:
`Downloading and preparing dataset json/default (download: Unknown size, generated: Unknown size, post-processed: Unknown size, total: Unknown size) to /root/.cache/huggingface/datasets/json/default-c1e124ad488911b8/0.0.0/45636811569ec4a6630521c18235dfbbab83b7ab572e3393c5ba68ccabe98264...
`
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/730#issuecomment-981095050_ | 25 | load JSON files, get the errors
Hi, does this bug be fixed? when I load JSON files, I get the same errors by the command
`!python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/`
change the dateset to load json by refering to https://huggingface.co/docs/datasets/loading.html
`dataset = datasets.load_dataset('json', data_files=args.dataset)`
Errors:
`Downloading and preparing dataset json/default (download: Unknown size, generated: Unknown size, post-processed: Unknown size, total: Unknown size) to /root/.cache/huggingface/datasets/json/default-c1e124ad488911b8/0.0.0/45636811569ec4a6630521c18235dfbbab83b7ab572e3393c5ba68ccabe98264...
`
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/730#issuecomment-981095050_
Hi ! The message you're getting is not an error. It simply says that your JSON dataset is being prepared to a location in `/root/.cache/huggingface/datasets` | [
0.1340622455,
-0.435693115,
-0.0010808157,
0.4408900142,
0.4953264296,
0.118478559,
0.0806621313,
0.37969926,
0.1051829904,
-0.0702866912,
-0.0352998264,
0.1957522631,
-0.0973738283,
0.3266998827,
-0.1525483578,
-0.0933607519,
0.0823304802,
0.074096337,
-0.1414859295,
0.0792015344,
-0.2150725275,
0.3840418458,
-0.0021207056,
0.0098338807,
-0.2920079827,
-0.1203963161,
0.0398100875,
0.2432675511,
-0.2985906303,
-0.5010698438,
0.2849068642,
-0.0953261256,
0.2465160191,
0.4338198304,
-0.0001125735,
0.0708660483,
0.2820902467,
-0.1743133366,
-0.3865676522,
-0.3857505023,
-0.1431331336,
-0.3407212198,
0.3662092388,
-0.076244764,
-0.1111861169,
-0.1300685555,
-0.0994508341,
-0.1398905516,
0.8514150977,
0.2543052435,
0.2727746665,
0.3182745874,
0.1154009849,
-0.1199784279,
0.036331851,
0.3197355568,
-0.0676279366,
0.5441520214,
0.0516465195,
0.1807157993,
0.1949742287,
0.2008492053,
0.1186136752,
0.0050871125,
0.3977428675,
0.0041697118,
-0.1350828707,
-0.3455569148,
-0.189727813,
0.0538931787,
0.3800941706,
-0.2095680535,
-0.6211258173,
-0.5102396011,
0.150698036,
-0.3400242329,
0.3419012129,
0.2085122317,
-0.051651042,
-0.0215204898,
-0.3525160253,
-0.1947467178,
-0.0643090457,
-0.0507134944,
0.3227287233,
-0.1489929259,
-0.3083497584,
0.0252660643,
0.1538553238,
-0.2023447901,
-0.169150874,
0.1035900638,
-0.2362827957,
0.3077510893,
-0.2608383298,
-0.1753766388,
-0.1506361067,
-0.1923894435,
0.0591601878,
0.2445789576,
-0.0059724492,
-0.1902678609,
-0.0174390394,
0.119974412,
0.3295112252,
0.4092618227,
0.009220385,
-0.0294193048,
0.0697397664,
0.4435242712,
0.0228275321,
-0.2053290904,
-0.0686552376,
-0.1908246875,
-0.1360353827,
-0.076735273,
0.0681496114,
-0.2350077927,
-0.1345689148,
0.126638487,
-0.2146113068,
-0.1963226348,
-0.0224326793,
0.3087322116,
-0.2215251178,
0.1493364722,
0.1597045511,
0.3573339283,
-0.1844121516,
-0.0163932033,
-0.0940118656,
-0.007566256,
-0.201606676,
0.0842856169,
0.214108482,
-0.0777736977,
0.3825953901,
0.0076727476,
0.1340124905,
-0.3007406592,
0.0501454175,
-0.0096909516,
-0.2060446739,
0.2486510426,
0.0477758348,
0.0714097321,
0.1079404727,
-0.0929204002,
-0.1341293305,
-0.1648007184,
-0.3751430809,
-0.2794171572,
-0.0167892594,
0.2042694837,
-0.1478004009,
0.0965824798,
-0.5965676308,
0.0244276188,
0.0365937278,
-0.0513622425,
0.1082155406,
-0.099075079,
-0.0027629717,
-0.2225878835,
0.3280194104,
0.3251006603,
-0.1108144075,
-0.3228885531,
0.2291618139,
-0.2921516299,
-0.0484709591,
0.4269497395,
-0.0420740545,
0.2859463692,
-0.3817112148,
-0.015628105,
0.0396365188,
-0.3100794554,
-0.0865108222,
0.1363205761,
-0.0696504563,
0.159179762,
0.0549554788,
-0.1607619524,
-0.0790631399,
0.092443414,
0.2820345461,
0.202505976,
0.0589467548,
0.0510977767,
-0.2899796963,
-0.3715032339,
-0.1747858971,
0.1306508183,
-0.2812929451,
0.1759980172,
-0.0246574767,
-0.0887700096,
0.1605493277,
-0.1388169676,
0.0418550931,
0.4429998696,
0.177680701,
0.1887318194,
-0.0643885434,
0.0584284924,
-0.6988534331,
0.2129922509,
-0.1795331091,
0.0366330706,
-0.055967737,
-0.108321242,
-0.2770814002,
-0.0816366374,
-0.0650961772,
-0.1553680003,
0.0964670628,
-0.0308582522,
0.3887806833,
0.2674199939,
-0.2402366251,
0.2569640875,
-0.0213554017,
0.3883883655,
-0.5748906732,
0.160411343,
0.0129473489,
-0.0904934034,
0.1975715309,
0.1584275961,
-0.0000820394,
-0.1781267971,
-0.1681417525,
0.2582543492,
-0.0293079782,
0.269243449,
0.0506382957,
0.0325425714,
0.0919508412,
0.1784379035,
-0.188067317,
0.0594682619,
0.0560128018,
-0.045939628,
-0.0248478297,
0.4908507466,
-0.1477125436,
0.1264650673,
0.0272342917,
-0.1383652389,
0.1904550046,
0.1250164211,
-0.1197296083,
-0.1933060586,
0.1668935716,
0.1320361942,
0.0804203674,
-0.023113722,
-0.2956244349,
-0.3768154085,
0.4740641415,
-0.0043986542,
-0.0997622162,
0.4230206907,
-0.0092097307,
0.1029040962,
-0.0497177318,
0.1985417008,
0.4678190649,
0.0438464805,
-0.2617487609,
0.1859253943,
0.1294295639,
-0.1906596124,
0.047607895,
-0.0608780496,
0.3754660189,
0.1994158924,
0.2241749316,
-0.0287386123,
-0.296584934,
0.0996709615,
-0.1363719553,
0.1992976367,
-0.4380294085,
0.0708349943,
-0.140792191,
-0.1407706738,
-0.2005560547,
-0.004102468,
-0.4785353541,
-0.1014898792,
-0.0444215313,
0.2648246288,
-0.0711330175,
-0.0435951054,
0.0643010437,
0.2944274843,
0.0029919227,
0.0631746873,
-0.1944443733,
0.0938575715,
-0.2495763004,
-0.00247799,
0.1381831914,
-0.332460016,
0.2893589139,
-0.4716009498,
-0.0355373099,
-0.009951055,
-0.1204721108,
0.1316304356,
-0.1494602412,
0.4472638071,
0.203219831,
0.33924824,
-0.2161583304,
-0.1259274185,
0.4162802696,
0.0124712549,
-0.4368579984,
-0.138222754,
0.0863294303,
0.245411858,
-0.2399862707,
-0.3534658551,
-0.1518461257,
-0.3174444437,
0.7419291735,
0.1069435179,
0.0040570926,
0.1505645216,
0.1832239032,
0.0978755653,
-0.3299697638,
0.249665603,
-0.256390065,
-0.7169764042,
0.2397577465,
-0.2577950954,
-0.3208524287,
0.0848459303,
0.0991513133,
0.2634999752,
-0.3823284507,
-0.5710347891,
-0.4254977703,
0.0067326743,
-0.0262237769,
-0.1655315608,
0.1221013218,
0.1177673042,
-0.0972591266,
-0.0105258962,
-0.0508951247,
-0.2957680523,
0.0626532733,
0.0256575998,
0.2425008565,
-0.078323096,
0.6527789235,
-0.1599173099,
0.5840442777,
0.3300723732,
-0.0495453142,
0.3927124739,
-0.0520349853,
0.3143522143,
-0.236016795,
-0.1461935639,
0.029611649,
-0.1927468032,
0.071150288,
0.0857987478,
0.2293048799,
0.2238518447,
-0.1641144902,
0.1595300287,
-0.4253579378,
-0.1583390981,
-0.0344582126,
-0.0564320683,
0.005484316,
0.0018622061,
0.0996495709,
-0.0002288686,
0.0204395186,
-0.0278526973,
0.2176710069,
0.3336057365,
0.1025146917,
-0.4362815619,
-0.3230217993,
-0.2973849475,
0.2481842339,
-0.0271037985,
0.2555793822,
-0.0499068052,
0.0319886692,
0.187724039,
-0.0463547073,
0.7925149798,
0.0703984946,
-0.1607737988,
0.0557488538,
-0.1127779782,
-0.4081825316,
-0.069703415,
-0.0250246413,
-0.0280679017,
0.3262040913,
0.7346365452,
-0.3563609421,
-0.1811156422,
-0.187676236,
0.1418287605,
-0.1587868184,
-0.1228863895,
-0.3223749399,
-0.2828170359,
-0.5322406888,
0.0736042857,
-0.0174547229,
0.2441320866,
-0.0339005478,
0.1387684345,
0.1372120529,
0.0660135299,
-0.0342580117,
0.1931527555,
0.4103873074,
0.0294019934,
0.2749971449,
0.4091403782,
0.235754475,
0.3540491164,
0.7526971698,
0.0688144565,
-0.2087614834,
-0.1136478707,
0.1468507499,
0.2318738997,
0.1508880556,
0.0938645005,
0.1266574562,
0.1901506037,
0.3605615199,
-0.4025827348,
-0.0793936327,
0.5813174844,
-0.0447366498,
-0.1141672805,
-0.2138582915,
0.3504940867,
0.0006263164,
0.1867368966,
-0.0129266623,
0.069272697,
-0.1550435722,
0.1800278723,
-0.0012653979,
0.8067187071,
-0.0385166965,
0.3022587597,
0.4475620091,
-0.3992950022,
0.6552965045,
-0.2778069675,
0.1566909701,
-0.3522605896,
0.1286009401,
0.1100831181,
-0.1503259093,
-0.0268520787,
0.1976934969,
-0.0403654315,
0.203817755,
-0.133274883,
0.1544137597,
-0.200930506,
0.189239338,
-0.284280628,
-0.2461882085,
-0.4956708252,
0.1360195726,
-0.1346138418,
0.3271985054,
-0.1570352614,
-0.1266618073,
0.1035416424,
-0.2703901827,
-0.206816569,
0.0600091107,
-0.0235972684,
0.0282875821,
0.4787153602,
-0.1240817159,
0.0631102249,
0.1164438799,
0.1761609167,
0.1395091265,
-0.2699512839,
0.0651552752,
-0.0797500163,
-0.046436239,
-0.1858535558,
0.1663826555,
0.1576026529,
-0.0935037062,
-0.1911889911,
-0.0605717637,
-0.221479699,
-0.1011768505,
-0.1569961458,
-0.0140330782,
-0.4428221881,
-0.3836001456,
-0.2075892985,
-0.1542838365,
0.2072437406,
-0.1132706478,
0.171530664,
0.1646678597,
-0.0661211312,
0.0672155619,
0.3009991348,
-0.2569856346,
-0.2389198095,
0.5717566013,
-0.1144135967,
-0.2339369953,
0.6413202882,
0.2900601029,
-0.077781789,
-0.1676806211,
0.1166525781,
0.1949625164,
-0.4031940699,
0.2468224019,
0.2105838805,
0.1117135063,
-0.1669828147,
0.1412332058,
0.2819283307,
-0.283235997,
0.3919395208,
-0.4272793233,
-0.4593523145,
0.3773728311,
0.0017409704,
0.1053920835,
0.1269798577,
0.0095410282,
0.0152039956,
-0.0586178415,
-0.2950775921,
0.1761218011,
-0.2605942488,
-0.0143351266,
0.05642296,
-0.1125541404,
0.2744501233,
-0.0883275941,
0.0915718302,
0.118145518,
-0.2984952927,
-0.1849182397,
-0.0930974558,
0.1195990369,
0.0205426607,
-0.0912624747,
0.0466471203,
-0.0361720063,
-0.1068777889,
-0.1336556673,
0.0170099474,
0.2348416597,
0.0857202485,
0.0874138176,
-0.0276915208,
0.1010566428,
0.1211645082,
-0.0837150738,
0.1928306222,
0.3255059421,
0.0810020044,
-0.0938395634,
-0.2158463597,
0.0899150595,
-0.2969085872,
0.1306848079,
0.0522853844,
0.1465899497,
0.2017666847,
-0.4242673814,
0.1250004619,
0.0041468181,
0.3254988492,
0.3533188701,
-0.3212663829,
0.1479370594,
0.2711660862,
0.2059146911,
-0.0804168954,
-0.0507625677,
0.0894215554,
0.0437840559,
-0.2706934214,
0.1749968976,
0.1040010825,
0.0285723247,
-0.0026307702,
0.1567645967,
0.2878856659,
0.1121625379,
0.2411188781,
0.0408978984,
-0.1476525962,
-0.1125507206,
0.1746117175,
-0.0265907999,
0.2233216465,
0.0582086965,
-0.0185628328,
0.0468398966,
-0.2435885221,
0.2578294575,
-0.1573895365,
-0.490596354,
-0.0969728976,
0.1844129562,
0.0209786054,
0.1307487339,
-0.1196051911,
0.5166469812,
-0.225631699,
-0.3046168685,
-0.3545424938,
0.1852952689,
-0.2139059752,
-0.1760935485,
-0.1120363325,
-0.1744343489,
-0.0729868785,
0.1554760337,
-0.1676075459,
-0.1555930525,
0.040195588,
-0.0306795817,
-0.1785716265,
-0.3445289135,
-0.0317729786,
0.1746888906,
0.2827553153,
-0.1007506028,
0.3618614376,
0.2140589207,
-0.1271410882,
0.225045532,
0.3797437847,
0.4490361214,
0.3273972273,
0.0093471417,
0.0429303274,
-0.1555467695,
0.149565205,
0.00480597,
0.4253971875,
0.2872951627,
-0.0972843319,
0.2278933525,
0.2152621746,
-0.2106927484,
0.1148266867,
-0.1965652108,
0.3319434524,
-0.2905265391,
0.238103345,
-0.241715759,
0.0983362868,
-0.197907567,
-0.0066550407,
-0.5765227079,
0.1236624345,
0.0856586546,
0.2294650972,
0.0922978073,
-0.157579273,
0.0983085707,
-0.0548679456,
0.5374792218,
0.4525358081,
-0.0414353684,
-0.2050852627,
-0.0999368355,
-0.3525184989,
0.0136599038,
-0.065559797,
0.2734163404,
0.0289833266,
0.0191172566,
-0.109436214,
0.0157947931,
0.1691408008,
0.0122081861,
-0.2380128801,
-0.0446238555,
-0.3186275065,
-0.222596243,
-0.2541845143,
0.1101072282,
0.2134765834,
-0.018474739,
0.1306258142,
-0.2255218923,
-0.0120805223,
0.0013774,
0.2250000834,
-0.262904048,
-0.0043020197,
0.4019522965,
0.1535183638,
0.1511688828,
-0.037028987,
-0.4409730434,
-0.1909698546,
-0.4757491946,
-0.0594765991,
0.310862124,
-0.2110104263,
0.5644007921,
-0.3049836755,
-0.023048982,
-0.4494195282,
0.0936062485,
-0.0342450626,
-0.2485236228,
-0.1765886545,
0.0838285685,
0.0308501944,
0.0633820817,
0.2748424113,
0.3875700831,
-0.0950620547,
0.2504840195,
-0.3160367012,
-0.1371269822,
0.6417095661,
-0.290546149,
-0.0155381756,
0.2659297884,
0.1550039053,
0.1089676246,
-0.3436472416,
-0.6332704425,
0.2570720017,
0.3498011529,
-0.0589662679,
-0.1556456536,
0.1701830029,
-0.2635735869,
-0.2715687752,
0.0064622145,
0.3916607499,
-0.0097736437,
-0.1509391814,
0.2254832238,
-0.1068342701
] |
https://github.com/huggingface/datasets/issues/3333 | load JSON files, get the errors | >
but I want to load local JSON file by command
`python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/`
**squad-retrain-data/train-v2.0.json** is the local JSON file, how to load it and map it to a special structure? | Hi, does this bug be fixed? when I load JSON files, I get the same errors by the command
`!python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/`
change the dateset to load json by refering to https://huggingface.co/docs/datasets/loading.html
`dataset = datasets.load_dataset('json', data_files=args.dataset)`
Errors:
`Downloading and preparing dataset json/default (download: Unknown size, generated: Unknown size, post-processed: Unknown size, total: Unknown size) to /root/.cache/huggingface/datasets/json/default-c1e124ad488911b8/0.0.0/45636811569ec4a6630521c18235dfbbab83b7ab572e3393c5ba68ccabe98264...
`
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/730#issuecomment-981095050_ | 37 | load JSON files, get the errors
Hi, does this bug be fixed? when I load JSON files, I get the same errors by the command
`!python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/`
change the dateset to load json by refering to https://huggingface.co/docs/datasets/loading.html
`dataset = datasets.load_dataset('json', data_files=args.dataset)`
Errors:
`Downloading and preparing dataset json/default (download: Unknown size, generated: Unknown size, post-processed: Unknown size, total: Unknown size) to /root/.cache/huggingface/datasets/json/default-c1e124ad488911b8/0.0.0/45636811569ec4a6630521c18235dfbbab83b7ab572e3393c5ba68ccabe98264...
`
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/730#issuecomment-981095050_
>
but I want to load local JSON file by command
`python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/`
**squad-retrain-data/train-v2.0.json** is the local JSON file, how to load it and map it to a special structure? | [
0.1912293732,
-0.3675380945,
-0.0029149048,
0.5285809636,
0.3912636936,
0.0750025883,
0.0855832845,
0.4642633796,
0.2954299152,
-0.0933140218,
-0.1045986786,
0.2233937085,
0.004662368,
0.2920066416,
-0.0838339925,
-0.1504721642,
0.0743770301,
0.101179719,
-0.0999642834,
0.0778007284,
-0.3029292822,
0.39278391,
0.0348864272,
0.0766872913,
-0.1023583487,
0.0633739159,
0.0872770548,
0.2624526024,
-0.2257564217,
-0.5375310779,
0.3394761384,
-0.149169296,
0.2267313153,
0.4444762468,
-0.0001136894,
0.2170353681,
0.3353905976,
-0.213992849,
-0.2998426855,
-0.4525948167,
-0.230682075,
-0.2641102076,
0.4249494076,
-0.1163707599,
-0.1196724549,
-0.3074536026,
-0.0818142369,
-0.1540305465,
0.8801874518,
0.1835417747,
0.2141236961,
0.2607221305,
0.1658613086,
-0.0820159912,
0.0980498344,
0.4361202419,
-0.0139492126,
0.7154095769,
0.1889702678,
0.1951343119,
0.1510667801,
0.0087778177,
0.0577953532,
0.0780884326,
0.2958555818,
-0.0589197166,
-0.0400353,
-0.1861751676,
-0.1422234029,
0.1445471793,
0.4441283345,
-0.2424720228,
-0.5932987332,
-0.3637836277,
0.0628299266,
-0.2452017367,
0.3591326177,
0.2384508103,
-0.1228507683,
0.0713816807,
-0.2872864902,
-0.2093149424,
-0.1736642867,
0.0911527574,
0.3180142343,
-0.082069695,
-0.3231347501,
0.0564124584,
0.1946078688,
-0.2423977256,
-0.1302844435,
0.0313822143,
-0.2208382338,
0.3378196657,
-0.124652423,
-0.0939465836,
-0.2683624625,
-0.2254652828,
0.119509466,
0.0364672504,
0.0275181737,
-0.1408472508,
-0.1272028387,
0.2469894886,
0.3131502569,
0.380384028,
0.0913557038,
0.0493855625,
-0.0073371148,
0.4342576861,
-0.0779131055,
-0.1418357939,
-0.1238730848,
-0.2145093381,
-0.3287106752,
-0.0635164157,
0.0370170511,
-0.2447979897,
0.0240324475,
0.0534049496,
-0.3331883252,
-0.1773035228,
0.141680479,
0.3235248923,
-0.1732910126,
0.1130928025,
0.1211701334,
0.2992586792,
-0.1081555113,
0.070911102,
-0.0560328476,
0.0868370086,
-0.09428747,
0.0710742176,
0.2012320757,
-0.1018955931,
0.3712412119,
-0.0131494347,
-0.0123235919,
-0.261122793,
0.0087422552,
-0.0069008931,
-0.191203326,
0.271969825,
0.0515650623,
0.1196875423,
0.1977694631,
-0.1753091067,
-0.2226876915,
-0.1032701433,
-0.4090570211,
-0.3200069964,
-0.065914996,
0.1496840417,
-0.1829794794,
0.1491930932,
-0.6432976723,
-0.1194921955,
-0.0764721632,
-0.1589270234,
-0.0060212919,
-0.0606162995,
-0.1479971409,
-0.135248065,
0.2835026383,
0.3367240131,
-0.2618971467,
-0.2712305784,
0.2087919712,
-0.3465014398,
-0.0459196679,
0.4752024412,
-0.1166171059,
0.3254610002,
-0.4514960945,
-0.0105211949,
0.1742402315,
-0.4279031456,
-0.0977692455,
0.3394382298,
-0.0401220359,
0.1480509192,
0.0978166014,
-0.2316546887,
-0.2067902833,
0.0999718308,
0.3258712888,
0.1744320542,
0.2001135051,
0.0621653311,
-0.2348698825,
-0.314637661,
-0.1985312551,
0.2130947411,
-0.3558549881,
0.1898595244,
0.0605410896,
-0.0163100287,
0.1433538646,
-0.1817374229,
0.0742747635,
0.4196126759,
0.1361921728,
0.098461315,
-0.033488851,
0.1216342896,
-0.736227572,
0.145326525,
-0.2350457758,
-0.0737107843,
-0.0516410545,
-0.0817967802,
-0.3076820076,
-0.0445505567,
-0.1600229889,
0.053691376,
0.0590227544,
-0.0046989825,
0.380521208,
0.2092679888,
-0.2081826925,
0.179726392,
-0.0701906011,
0.2510398328,
-0.5658290386,
0.1460466236,
0.0013767525,
-0.0452428609,
0.1973353475,
0.1152989864,
0.1028407216,
-0.3353866041,
-0.2073403895,
0.1647701561,
0.0589471385,
0.3073956072,
-0.059152402,
-0.0197471734,
0.0676507428,
0.1818959415,
-0.2474109232,
0.1101118922,
0.1068464592,
-0.0730079934,
-0.1315912604,
0.4609126151,
-0.150770545,
0.1780732274,
0.0676781684,
-0.1789704561,
0.3120941818,
0.0886196271,
-0.172532931,
-0.2643621564,
0.0998166353,
0.2826198041,
0.188258633,
0.0748644695,
-0.2423676848,
-0.4787538052,
0.4757588506,
-0.0576794147,
-0.1356115937,
0.3550503552,
-0.0595937446,
0.0680702627,
-0.0408706814,
0.1811364889,
0.4471726716,
-0.0281945188,
-0.2612181604,
0.2123825848,
0.2633501887,
-0.1909308285,
0.0192346387,
-0.0617693327,
0.2918366194,
0.3174840212,
0.1602708697,
-0.1294073611,
-0.2976813614,
0.0273035727,
-0.1031809524,
0.1893873811,
-0.4977818727,
-0.0283131655,
-0.2322119623,
-0.2172590345,
-0.3347575366,
-0.062016204,
-0.2776678801,
-0.0503216162,
-0.1042950526,
0.2689659595,
-0.1751222312,
-0.0872199386,
0.1427212507,
0.1581701189,
-0.0402798243,
-0.1668701917,
-0.2561635375,
0.0510844402,
-0.2559106052,
-0.0398732126,
0.3317065537,
-0.1843767613,
0.1513111293,
-0.5701093078,
-0.1720833033,
0.0125820395,
-0.0481999852,
0.219621107,
-0.0286842007,
0.4075642526,
0.1101521999,
0.3714239001,
-0.2840047479,
-0.1259314865,
0.4607097208,
0.0760358423,
-0.4325692654,
-0.1421156377,
-0.0211801883,
0.2068890035,
-0.1878802925,
-0.3427134752,
-0.254912883,
-0.441506505,
0.876768291,
0.145683229,
0.1659605801,
0.0908500031,
0.1034666821,
0.1967275441,
-0.2484890372,
0.2396029681,
-0.1621098369,
-0.8245723844,
0.2767784595,
-0.316261977,
-0.2588115931,
0.0380943418,
0.0502998047,
0.2674009204,
-0.3577706218,
-0.5028181076,
-0.3877106607,
0.0689652339,
-0.0732421651,
-0.080218628,
0.0684035942,
0.1067420244,
-0.1099840254,
0.0555104315,
-0.0454004556,
-0.2853200734,
0.0675488785,
0.1838707179,
0.1419322938,
0.1764857024,
0.5833239555,
-0.2115714401,
0.5565188527,
0.2927148342,
-0.0426829644,
0.435893774,
-0.0981550515,
0.2216472179,
-0.2796320319,
-0.1350140274,
-0.066992119,
-0.0818269923,
0.042814862,
0.0491472818,
0.2640855014,
0.2382373959,
-0.2305213362,
-0.0596508011,
-0.4987774491,
-0.1514483839,
-0.0264986921,
0.1092741564,
-0.047997158,
-0.1051209122,
-0.0262897722,
0.0599977747,
0.0531240553,
0.0859394222,
0.3848917782,
0.3026916981,
0.224409163,
-0.5301485062,
-0.3605169654,
-0.1653915346,
0.2959607244,
0.0827593654,
0.2861739397,
-0.0484626405,
0.0533833615,
0.1007062122,
-0.0492156819,
0.6344498992,
0.0786139891,
0.0026856747,
0.2067781389,
-0.1607989073,
-0.4870443046,
-0.0319044963,
0.0570648648,
0.1010727659,
0.3432613015,
0.8691844344,
-0.2493836135,
-0.2646576166,
-0.2219927758,
0.2522115111,
-0.2181966454,
-0.2777365744,
-0.2459964305,
-0.2748655975,
-0.4525979161,
-0.0694034323,
-0.0174036343,
0.2462990284,
0.1585631073,
0.0200243574,
0.1497354954,
0.0464910679,
-0.0862562805,
0.1268500239,
0.3286949396,
0.028560359,
0.2394528091,
0.4048813283,
0.2738454342,
0.3695836663,
0.7944923043,
0.0786672756,
-0.2009389848,
-0.0882939547,
0.2146520913,
0.1853646785,
-0.0426577441,
0.1090020388,
-0.0438240506,
0.1901617795,
0.2069192082,
-0.4004653692,
-0.070651643,
0.3984904587,
-0.1137660667,
-0.0404009596,
-0.3637516499,
0.4448527694,
0.0249877758,
0.0594037883,
0.0133973993,
-0.0292485468,
-0.1527159363,
0.2286529094,
-0.0987095833,
0.5484420657,
-0.201505214,
0.2203295827,
0.4033139646,
-0.3815214336,
0.4677105546,
-0.2572650015,
0.0876420662,
-0.3252791464,
0.2435621172,
0.0763301477,
-0.205369845,
0.0298476629,
0.2322973609,
0.0312207006,
0.2671053112,
-0.0886107162,
0.1623751819,
-0.2308690846,
0.2546730936,
-0.1373788565,
-0.2601052225,
-0.5787106156,
0.0872458294,
-0.1100236103,
0.4069189429,
-0.0867525935,
-0.1577883512,
0.0374475867,
-0.2520647645,
-0.0544951186,
0.0552397631,
-0.011728758,
0.049306497,
0.5020217896,
-0.0817580745,
0.0906351358,
0.238703981,
-0.0146363722,
0.0968753174,
-0.3091351092,
0.0090005109,
-0.0563713536,
-0.0286686458,
-0.2516252995,
0.2045852393,
0.1514523625,
-0.0440695882,
-0.0770457983,
-0.1309244484,
-0.2133753747,
-0.1627034396,
-0.2336633801,
-0.0319132656,
-0.431202352,
-0.3321757913,
-0.3035154939,
-0.2407470047,
0.1545862257,
-0.0247126576,
0.1256914288,
0.0718751401,
-0.0700326413,
-0.0317497924,
0.2574243546,
-0.2753088474,
-0.0454471931,
0.6496859789,
-0.0901973173,
-0.1430401951,
0.6076926589,
0.2726017237,
-0.0193749145,
-0.1740954071,
0.1805088818,
0.3148407638,
-0.2545682192,
0.2091476619,
0.2190262526,
0.1233141348,
-0.1424863487,
0.1994011402,
0.3231082261,
-0.2206694931,
0.4623319209,
-0.5156756043,
-0.5367416739,
0.4130326509,
0.0036371374,
0.0245717838,
0.1977900267,
0.106352441,
0.0050383685,
-0.1101176143,
-0.2465595007,
0.2511585653,
-0.2627580762,
-0.0807275325,
0.1373565495,
0.0273009446,
0.2553498149,
-0.029533077,
0.108348012,
0.0527867004,
-0.3209771514,
-0.1584552974,
-0.1135817245,
0.1242210865,
0.0859673321,
-0.0827006549,
-0.0700713545,
-0.0918682292,
0.0157573316,
-0.0848881975,
0.0197394136,
0.2311703563,
0.0204540007,
0.1879907399,
-0.0531809665,
0.0802962407,
0.0929307044,
0.1056346074,
0.1410659105,
0.4327982962,
-0.0491753928,
-0.0555150472,
-0.1355328262,
0.0993431136,
-0.2593221366,
0.0245016217,
0.0646203309,
0.1784575135,
0.221374169,
-0.3052851558,
0.223669678,
0.0797159895,
0.3341032863,
0.2704327106,
-0.4050736427,
0.2957229912,
0.3183573484,
0.1551464349,
-0.0469919853,
-0.102934368,
0.2809844613,
-0.044076737,
-0.2510866523,
0.0888144299,
0.1954009384,
-0.1009828299,
-0.0680446476,
0.0171546452,
0.3132055402,
0.2453852296,
0.1305508018,
0.1410522312,
-0.2025654763,
-0.1651695371,
0.1035507694,
0.0253327116,
0.2848575711,
0.0640077963,
-0.0613907166,
-0.1065438911,
-0.2322794646,
0.4506886303,
-0.0450057127,
-0.4761050642,
-0.0381084755,
0.2935726047,
0.0675475821,
0.1134167016,
-0.1115276963,
0.5254428387,
-0.1265084445,
-0.1276541799,
-0.2094820291,
0.1732720137,
-0.1096064225,
-0.2748480439,
-0.2506292164,
-0.1610803008,
-0.0643853769,
0.1741747707,
-0.1884614378,
-0.1231173798,
0.0333762132,
0.0060265381,
-0.07929039,
-0.1551663578,
0.0026324736,
0.1860651374,
0.162664637,
-0.2234140784,
0.4230595529,
0.15757294,
-0.1396059692,
0.1523597986,
0.2647969425,
0.3840493262,
0.348773092,
-0.01773444,
0.0231235493,
-0.1927487999,
0.0777326897,
-0.0140045863,
0.4140713513,
0.1413849294,
-0.1012321413,
0.2971645594,
0.185569033,
-0.146434173,
0.2064338326,
-0.2629524171,
0.3048344553,
-0.2138105631,
0.2421512157,
-0.2789008021,
0.0138477013,
-0.0965253264,
-0.0228054635,
-0.5449867249,
-0.0297637787,
0.1125079021,
0.261498183,
0.2404624075,
-0.0200727172,
0.0768770128,
-0.0599948876,
0.5629414916,
0.2754071653,
-0.0717526674,
-0.0878709257,
-0.1201518551,
-0.3224684894,
0.1033020616,
-0.0374185666,
0.2484189719,
0.0527929924,
-0.032452669,
-0.1001716703,
0.0277284645,
-0.0185963362,
-0.074157238,
-0.1925022304,
-0.0348728299,
-0.1812154353,
-0.2447658777,
-0.0694934428,
0.1759234965,
0.1787610203,
-0.1009546667,
0.1665916443,
-0.2537095547,
-0.0461436622,
-0.0890161619,
0.2784920931,
-0.1861369312,
-0.1135485694,
0.3811737001,
0.1425652951,
0.2148556709,
-0.0714208335,
-0.3252110481,
-0.0370627232,
-0.4737115502,
0.0244661942,
0.3747083247,
-0.2519492805,
0.4961650372,
-0.3246629536,
0.0188040938,
-0.4963471293,
-0.1159723401,
-0.2065752149,
-0.2451589555,
-0.140620023,
0.0241222158,
-0.1278427839,
-0.0354423486,
0.2276364118,
0.3553679585,
-0.0867879614,
0.1595481783,
-0.233133778,
-0.0528257079,
0.6324391961,
-0.3880778253,
0.0083958125,
0.3808794618,
0.0442012623,
0.007342305,
-0.2618236542,
-0.5002601147,
0.3133553267,
0.4384312332,
-0.1079327837,
-0.084606491,
0.1195298806,
-0.2316407561,
-0.2032340765,
-0.0546208583,
0.1502521485,
0.1214151531,
-0.1453276426,
0.1052677855,
-0.1778894067
] |
https://github.com/huggingface/datasets/issues/3333 | load JSON files, get the errors | You can load it with `dataset = datasets.load_dataset('json', data_files=args.dataset)` as you said.
Then if you need to apply additional processing to map it to a special structure, you can use rename columns or use `dataset.map`. For more information, you can check the documentation here: https://huggingface.co/docs/datasets/process.html
Also feel free to share your `run.py` code so we can take a look | Hi, does this bug be fixed? when I load JSON files, I get the same errors by the command
`!python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/`
change the dateset to load json by refering to https://huggingface.co/docs/datasets/loading.html
`dataset = datasets.load_dataset('json', data_files=args.dataset)`
Errors:
`Downloading and preparing dataset json/default (download: Unknown size, generated: Unknown size, post-processed: Unknown size, total: Unknown size) to /root/.cache/huggingface/datasets/json/default-c1e124ad488911b8/0.0.0/45636811569ec4a6630521c18235dfbbab83b7ab572e3393c5ba68ccabe98264...
`
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/730#issuecomment-981095050_ | 59 | load JSON files, get the errors
Hi, does this bug be fixed? when I load JSON files, I get the same errors by the command
`!python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/`
change the dateset to load json by refering to https://huggingface.co/docs/datasets/loading.html
`dataset = datasets.load_dataset('json', data_files=args.dataset)`
Errors:
`Downloading and preparing dataset json/default (download: Unknown size, generated: Unknown size, post-processed: Unknown size, total: Unknown size) to /root/.cache/huggingface/datasets/json/default-c1e124ad488911b8/0.0.0/45636811569ec4a6630521c18235dfbbab83b7ab572e3393c5ba68ccabe98264...
`
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/730#issuecomment-981095050_
You can load it with `dataset = datasets.load_dataset('json', data_files=args.dataset)` as you said.
Then if you need to apply additional processing to map it to a special structure, you can use rename columns or use `dataset.map`. For more information, you can check the documentation here: https://huggingface.co/docs/datasets/process.html
Also feel free to share your `run.py` code so we can take a look | [
0.0703725219,
-0.3985922933,
0.025265472,
0.4247381091,
0.493349582,
0.1074073315,
0.0497881137,
0.4321736097,
0.103668198,
-0.0652427748,
-0.1320444494,
0.3324909508,
-0.0747636333,
0.4676976204,
-0.113608636,
-0.1721077263,
0.0741180331,
0.0452481471,
-0.2256746143,
0.1473302692,
-0.2754347026,
0.3163520694,
0.0427871197,
0.0132884383,
-0.185868904,
-0.1375373602,
-0.0373366959,
0.2066911161,
-0.3033355772,
-0.4769492745,
0.1730832309,
-0.0827132463,
0.2531701624,
0.4677781165,
-0.000109723,
0.0578101352,
0.1936286092,
-0.1824490577,
-0.360940963,
-0.3822130561,
-0.0739112869,
-0.3502306342,
0.3194869757,
-0.1232313067,
-0.1459574401,
-0.1347856522,
-0.1264760047,
-0.0717578232,
0.8670138717,
0.2895651758,
0.2806135416,
0.3998850286,
0.2383020371,
-0.164092049,
0.0306958891,
0.2805212736,
-0.0770492032,
0.5343003273,
0.0823052153,
0.1997468919,
0.1642789692,
0.1720385551,
0.0796993226,
-0.0098203504,
0.3793886304,
-0.0246607512,
-0.0725719258,
-0.3107659519,
-0.1735554338,
0.1293847114,
0.3077870607,
-0.2608633339,
-0.5859311819,
-0.4616161287,
0.1625500172,
-0.3640615642,
0.2680617869,
0.2270880938,
-0.0080614984,
-0.0377451181,
-0.295768261,
-0.1404732764,
-0.0817793086,
0.0074223867,
0.2751145363,
-0.171590656,
-0.3041860461,
0.0575622581,
0.2095819563,
-0.2520678341,
-0.1877590865,
0.1086136252,
-0.1658946723,
0.2826685011,
-0.2700920999,
-0.2205715328,
-0.1726428717,
-0.1785247475,
0.0938300565,
0.1520287097,
-0.0410982408,
-0.1395684928,
0.0223734807,
0.0986385792,
0.2394898087,
0.3708788455,
-0.0080097122,
0.0659443736,
0.0075084455,
0.4621218741,
0.0178012419,
-0.1932153553,
-0.0753491223,
-0.1608521491,
-0.2629655004,
-0.0912578627,
0.0314075984,
-0.1571424305,
-0.1212538481,
0.0525370799,
-0.1963322312,
-0.1172300205,
0.0026974673,
0.3732107282,
-0.1924458593,
0.0230272934,
0.1408442408,
0.3320848048,
-0.1323203743,
0.0303623118,
-0.1105095521,
0.0151419137,
-0.1938458383,
0.1033454463,
0.1868408769,
-0.1240086481,
0.3627925515,
0.0531598106,
0.01113242,
-0.2739455402,
0.0649161413,
-0.0123837134,
-0.1874192208,
0.2228443027,
0.085340023,
0.0578289852,
0.1612575352,
-0.1000031978,
-0.1528233439,
-0.1835718602,
-0.3468770087,
-0.2931379974,
-0.0567968041,
0.2192597538,
-0.1986157,
0.0930024683,
-0.5223020911,
0.0227601286,
-0.0002302512,
-0.0459594727,
0.0232623052,
-0.0975180045,
-0.0395165123,
-0.2022597492,
0.3352074027,
0.2626446486,
-0.1094164774,
-0.2541510165,
0.2200586647,
-0.2962450683,
-0.0611259975,
0.3544145823,
-0.0066236574,
0.2606213093,
-0.3168215454,
-0.0324466638,
0.0182419792,
-0.2816698551,
-0.0390796848,
0.1208284497,
-0.0786177441,
0.1466310173,
0.0105941538,
-0.1567109078,
0.0040431423,
0.0603400692,
0.1928289533,
0.1340051293,
0.1056910902,
0.0673351884,
-0.255954057,
-0.3624229729,
-0.153294906,
0.1213543117,
-0.2730080187,
0.2050554454,
-0.0703260526,
-0.094520703,
0.1474417001,
-0.2143445611,
0.0708316937,
0.3668999374,
0.1404758096,
0.1957305074,
-0.0381482877,
-0.0275049973,
-0.6883353591,
0.1786344051,
-0.1644844264,
0.0874574631,
-0.0424023904,
-0.1518631279,
-0.3249442577,
-0.0952046067,
-0.0358740725,
-0.1439607739,
0.1286502481,
-0.0567195788,
0.4008744657,
0.1912903637,
-0.2470026314,
0.2000565827,
-0.0704786554,
0.3918797076,
-0.4898610413,
0.1099926829,
-0.0237063766,
-0.1076389104,
0.2443421036,
0.155842036,
0.0273248721,
-0.2059372365,
-0.0907209292,
0.2640828788,
-0.0158810392,
0.2190218121,
-0.0380670913,
0.0164426807,
0.0505054258,
0.2449370623,
-0.1663501412,
0.0345549136,
0.1137269661,
-0.0455764867,
-0.0712486207,
0.5071190596,
-0.1718536317,
0.163057968,
0.0932125598,
-0.0799176395,
0.1827468574,
0.0708497614,
-0.1407689005,
-0.2390191853,
0.0689661801,
0.1030494943,
0.1264152676,
-0.0056612059,
-0.3391360044,
-0.348300159,
0.549818635,
-0.0310205594,
-0.1417655051,
0.4043052495,
-0.0718732625,
0.1478959024,
-0.0706515387,
0.2480635941,
0.3892068267,
0.0948704034,
-0.2737033665,
0.2339658141,
0.0724964514,
-0.1814326048,
0.067800194,
-0.0136298873,
0.3392952681,
0.1566801369,
0.2276384234,
-0.0488614514,
-0.3238663673,
0.1023097858,
-0.1196433827,
0.2325890809,
-0.4538965821,
-0.0564423278,
-0.1094006374,
-0.1673055887,
-0.2384125143,
-0.0456554517,
-0.4120345712,
-0.1298426092,
-0.0302206259,
0.2443805933,
-0.1469566375,
0.0303665977,
0.1395323873,
0.2253272682,
-0.0204017498,
0.0702984706,
-0.2057427317,
0.0112300431,
-0.1855909526,
0.0430761799,
0.167333737,
-0.2190201879,
0.3210680187,
-0.4617028832,
-0.0546445362,
-0.0692960992,
-0.1930751204,
0.1542294621,
-0.2678239942,
0.4431123734,
0.1877370626,
0.3884457946,
-0.1918163598,
-0.1760344803,
0.4210590124,
0.0133261001,
-0.3891231716,
-0.0761321634,
0.036897853,
0.1985435188,
-0.2337907255,
-0.4123492837,
-0.1441268176,
-0.391670078,
0.7527725697,
0.0604848862,
0.0834000036,
0.1221925095,
0.1933640838,
0.1957612038,
-0.3832634091,
0.2597778141,
-0.2306113094,
-0.6465620995,
0.2809683681,
-0.3070638478,
-0.3586702943,
0.0714103878,
0.0961654782,
0.2726450861,
-0.3408721387,
-0.4914922416,
-0.402503252,
-0.0046538264,
-0.0624764487,
-0.0595574789,
0.1217772216,
0.135226801,
-0.0624094121,
-0.0427169055,
-0.0431683548,
-0.2507207692,
0.0856824443,
0.0805795789,
0.2080333531,
-0.0569233708,
0.7160333991,
-0.1528279781,
0.5577391982,
0.4198951423,
-0.1067895442,
0.3364963233,
-0.1727113277,
0.2940631509,
-0.2248265594,
-0.1734181792,
0.0171203297,
-0.2210286409,
0.1470173597,
0.1152174026,
0.2084407657,
0.2365386635,
-0.1604072154,
0.1290770918,
-0.3797780275,
-0.2251794189,
0.0493639745,
0.0081036268,
0.094191283,
0.0071804663,
0.0717722699,
-0.0541822091,
-0.0306179188,
0.0052569089,
0.2173846215,
0.2955657542,
0.0874537826,
-0.440761447,
-0.2856667042,
-0.3269706368,
0.2900492251,
-0.0386103019,
0.1671547741,
-0.0441018939,
-0.0562896207,
0.1181751639,
-0.0395550393,
0.7340012789,
0.0790587217,
-0.1714370698,
0.0968707204,
-0.1648405939,
-0.5471045971,
0.0088954326,
-0.0856072754,
-0.0636024773,
0.3190202415,
0.8368182778,
-0.4225840569,
-0.2185326517,
-0.1176173091,
0.2093622684,
-0.1394256949,
-0.1142311767,
-0.274964124,
-0.3043213189,
-0.5292322636,
0.1126277894,
-0.0354805961,
0.2458962351,
-0.008768226,
0.053318277,
0.0976163372,
0.01687048,
0.0287223924,
0.3016627133,
0.3883906901,
0.0759109035,
0.2756661773,
0.3730110526,
0.1691590548,
0.3744546473,
0.7063231468,
-0.0146093629,
-0.1986384094,
-0.1666446626,
0.0588321537,
0.2242786139,
0.1310791075,
0.1113162115,
0.1179542169,
0.1832784414,
0.386798352,
-0.4217381179,
-0.0389481038,
0.5530493259,
0.002964013,
-0.1162123978,
-0.2618106902,
0.2956803739,
0.0219184365,
0.1387237012,
0.002172142,
0.1100506559,
-0.1464600265,
0.2616618276,
-0.0563447401,
0.8089488745,
-0.149396643,
0.2634298205,
0.5230691433,
-0.3781480789,
0.5905070305,
-0.2210824192,
0.1133011952,
-0.3195421398,
0.1332802176,
0.1436818838,
-0.0931378007,
0.0624585859,
0.2126176208,
-0.1077503935,
0.2370340526,
-0.0842521861,
0.2126704156,
-0.2013313025,
0.2793424129,
-0.2306766957,
-0.2842108011,
-0.5432648659,
0.1715533733,
-0.1114053577,
0.2264931649,
-0.0647848621,
-0.1306565106,
0.0660784468,
-0.2673806846,
-0.1248094514,
0.0184399579,
-0.0540054254,
-0.0224638488,
0.3971422613,
-0.0868465155,
0.1134122163,
0.1624400169,
0.1127464399,
0.1612868458,
-0.249105379,
0.0508534051,
-0.0694032535,
-0.0544885769,
-0.1683551818,
0.1185629591,
0.18097426,
-0.112348102,
-0.1572165936,
-0.0478117652,
-0.1518009156,
-0.0119321384,
-0.1240691021,
-0.0513878055,
-0.4404783249,
-0.4734363258,
-0.1726478487,
-0.1877650619,
0.1449200511,
-0.1477211714,
0.1946681589,
0.0273046065,
-0.0811183155,
0.1360401362,
0.2969045341,
-0.256483674,
-0.1878830343,
0.5116215944,
-0.1248875186,
-0.1095165908,
0.6556460261,
0.2998521924,
-0.0628592893,
-0.184754923,
0.0708607063,
0.1725733429,
-0.4152124524,
0.3021733761,
0.225275591,
0.0909281895,
-0.1204944551,
0.2101087421,
0.2303873897,
-0.2721886933,
0.3507484794,
-0.3850921392,
-0.4948269725,
0.4177366495,
0.1068129316,
0.1044998392,
0.1248221546,
0.1914814115,
-0.0305644944,
0.0100634368,
-0.3362653255,
0.2028798461,
-0.2859587371,
0.0793785676,
0.1170343235,
-0.1468740553,
0.2823810875,
-0.0827153921,
0.1292522401,
0.1442167461,
-0.2972226441,
-0.2133364677,
-0.1525696516,
0.097173363,
-0.0201641768,
-0.0572677962,
0.0755969658,
-0.0366660766,
-0.1353224814,
-0.1746825576,
0.0569725297,
0.1942479014,
0.0600291975,
0.0819235891,
-0.0481972881,
0.0709091723,
0.1518405676,
-0.105569914,
0.152337566,
0.297973156,
0.0651992112,
-0.0420662723,
-0.2783065438,
0.0777018294,
-0.2023554891,
0.1413250715,
0.0940153301,
0.0894486532,
0.2979354262,
-0.2805712521,
0.0739323869,
0.0161400642,
0.3780816197,
0.3466022611,
-0.2770085633,
0.1398737282,
0.2704969943,
0.2181360275,
-0.1664750576,
0.0747722611,
0.1279468983,
-0.0408606157,
-0.1322592348,
0.1732794046,
0.0859661698,
0.0714937821,
-0.1207067221,
0.1064042524,
0.3148009777,
0.1011691689,
0.2069777697,
0.0865606293,
-0.1560529172,
-0.1155684516,
0.2259796262,
-0.0610968657,
0.1864801496,
0.0253824946,
-0.0102534592,
0.0233383849,
-0.2616201937,
0.322627306,
-0.0081289662,
-0.3902718127,
-0.0848672986,
0.2183959782,
-0.0098104654,
0.1138965786,
-0.132411316,
0.6113591194,
-0.2042775601,
-0.2626852095,
-0.3138301373,
0.2499363422,
-0.167223081,
-0.2159889191,
-0.1731801927,
-0.2090415955,
-0.0696155503,
0.1059531495,
-0.1494270265,
-0.1615026593,
0.1458560526,
-0.0503673293,
-0.0813757181,
-0.3342858851,
-0.0874962136,
0.1483086199,
0.3127479553,
-0.1251249015,
0.3292639852,
0.2471528351,
-0.1337465942,
0.1871478558,
0.3746241927,
0.4774814248,
0.1962043941,
0.0071326676,
0.1139640957,
-0.1311943829,
0.0900600031,
0.0557618625,
0.4046570659,
0.3058723509,
-0.0340862796,
0.2853882015,
0.2283955663,
-0.2431591302,
-0.036990568,
-0.2354350686,
0.3646394312,
-0.2395327985,
0.2397941053,
-0.1751510054,
0.045814205,
-0.1995305419,
-0.090118289,
-0.5609384775,
0.1386687458,
0.1349658817,
0.1606658399,
0.1209723279,
-0.1419629902,
0.1095559523,
-0.0391387083,
0.590231061,
0.3638341129,
-0.093636997,
-0.2227378935,
-0.1449877322,
-0.3490262926,
-0.0246353168,
-0.1140016839,
0.2190917283,
-0.0060804072,
-0.0114403199,
-0.0153806508,
-0.0227104183,
0.1301382631,
-0.0298280157,
-0.2931882143,
-0.0108909011,
-0.2912649512,
-0.1895820349,
-0.3054026663,
0.1209132224,
0.2581987083,
-0.0187928677,
0.1204952598,
-0.1636448056,
-0.00636634,
-0.010807531,
0.2576000392,
-0.1914405823,
-0.129685238,
0.3884375095,
0.1228144467,
0.1693532616,
-0.0849755406,
-0.415142715,
-0.1467976421,
-0.4593445063,
-0.0696996972,
0.35845384,
-0.1362999678,
0.5045983791,
-0.2230804265,
-0.0538324751,
-0.4301382303,
0.0044131526,
-0.0681537464,
-0.2732040286,
-0.1704654694,
0.1049176306,
0.0822279826,
-0.0102842292,
0.2686017454,
0.486720711,
-0.0710539296,
0.2211951613,
-0.2948991954,
-0.2033214569,
0.6595597863,
-0.316162616,
-0.0735290274,
0.3516038656,
0.1021448895,
0.0870842487,
-0.2730059326,
-0.6608111262,
0.2708336413,
0.318977803,
-0.049988281,
-0.1685454994,
0.1982540339,
-0.2522906959,
-0.240891397,
-0.0114103639,
0.3800038695,
0.0255629439,
-0.1998890489,
0.1467221379,
-0.1335833669
] |
https://github.com/huggingface/datasets/issues/3333 | load JSON files, get the errors | ```
# Dataset selection
if args.dataset.endswith('.json') or args.dataset.endswith('.jsonl'):
dataset_id = None
# Load from local json/jsonl file
dataset = datasets.load_dataset('json', data_files=args.dataset)
# By default, the "json" dataset loader places all examples in the train split,
# so if we want to use a jsonl file for evaluation we need to get the "train" split
# from the loaded dataset
eval_split = 'train'
else:
default_datasets = {'qa': ('squad',), 'nli': ('snli',)}
dataset_id = tuple(args.dataset.split(':')) if args.dataset is not None else \
default_datasets[args.task]
# MNLI has two validation splits (one with matched domains and one with mismatched domains). Most datasets just have one "validation" split
eval_split = 'validation_matched' if dataset_id == ('glue', 'mnli') else 'validation'
# Load the raw data
dataset = datasets.load_dataset(*dataset_id)
```
I want to load JSON squad dataset instead `dataset = datasets.load_dataset('squad')` to retrain the model.
| Hi, does this bug be fixed? when I load JSON files, I get the same errors by the command
`!python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/`
change the dateset to load json by refering to https://huggingface.co/docs/datasets/loading.html
`dataset = datasets.load_dataset('json', data_files=args.dataset)`
Errors:
`Downloading and preparing dataset json/default (download: Unknown size, generated: Unknown size, post-processed: Unknown size, total: Unknown size) to /root/.cache/huggingface/datasets/json/default-c1e124ad488911b8/0.0.0/45636811569ec4a6630521c18235dfbbab83b7ab572e3393c5ba68ccabe98264...
`
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/730#issuecomment-981095050_ | 136 | load JSON files, get the errors
Hi, does this bug be fixed? when I load JSON files, I get the same errors by the command
`!python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/`
change the dateset to load json by refering to https://huggingface.co/docs/datasets/loading.html
`dataset = datasets.load_dataset('json', data_files=args.dataset)`
Errors:
`Downloading and preparing dataset json/default (download: Unknown size, generated: Unknown size, post-processed: Unknown size, total: Unknown size) to /root/.cache/huggingface/datasets/json/default-c1e124ad488911b8/0.0.0/45636811569ec4a6630521c18235dfbbab83b7ab572e3393c5ba68ccabe98264...
`
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/730#issuecomment-981095050_
```
# Dataset selection
if args.dataset.endswith('.json') or args.dataset.endswith('.jsonl'):
dataset_id = None
# Load from local json/jsonl file
dataset = datasets.load_dataset('json', data_files=args.dataset)
# By default, the "json" dataset loader places all examples in the train split,
# so if we want to use a jsonl file for evaluation we need to get the "train" split
# from the loaded dataset
eval_split = 'train'
else:
default_datasets = {'qa': ('squad',), 'nli': ('snli',)}
dataset_id = tuple(args.dataset.split(':')) if args.dataset is not None else \
default_datasets[args.task]
# MNLI has two validation splits (one with matched domains and one with mismatched domains). Most datasets just have one "validation" split
eval_split = 'validation_matched' if dataset_id == ('glue', 'mnli') else 'validation'
# Load the raw data
dataset = datasets.load_dataset(*dataset_id)
```
I want to load JSON squad dataset instead `dataset = datasets.load_dataset('squad')` to retrain the model.
| [
0.115154922,
-0.4231142402,
0.0051270495,
0.5085046291,
0.3968496621,
0.1231366545,
0.1628357172,
0.3834851384,
0.1097671911,
-0.162881285,
-0.0096488977,
0.3028328419,
-0.1650662273,
0.2532165647,
-0.2283037752,
-0.135631308,
0.1069716215,
0.0491518341,
-0.0499630086,
0.1049180776,
-0.2675151527,
0.3844015896,
-0.0711609051,
0.0436927862,
-0.1823635399,
-0.0679678768,
0.0222141407,
0.1651019752,
-0.2507682741,
-0.4363207519,
0.2745265663,
-0.1926700026,
0.2205815911,
0.3976734877,
-0.0001144831,
0.1155017018,
0.3670407236,
-0.1546171606,
-0.3594563603,
-0.4974839985,
-0.196093753,
-0.2519211769,
0.4365656078,
-0.1233203933,
-0.0567997321,
-0.1526563913,
-0.2029228956,
-0.1339872032,
0.8560736179,
0.2490430027,
0.2436867058,
0.4152714014,
0.0363909751,
-0.1244819164,
0.1265602708,
0.3864963949,
-0.0502393171,
0.5789740682,
0.0095605766,
0.1913311034,
0.1931608319,
0.1817901433,
0.0637401268,
0.019912865,
0.2823930681,
-0.0419906937,
-0.1429135352,
-0.2199681848,
-0.255461514,
0.1037243083,
0.3343482018,
-0.1914708167,
-0.5883919001,
-0.5273309946,
0.1797508895,
-0.3252034783,
0.3438082933,
0.2003412247,
-0.0524594076,
-0.0206276048,
-0.3045543432,
-0.1489672363,
-0.0603743382,
0.01363918,
0.3119155169,
-0.04422497,
-0.3107208908,
0.0653428137,
0.1871763319,
-0.1399032474,
-0.1317639202,
0.0527862832,
-0.2574831545,
0.1933316439,
-0.1934455037,
-0.1582631469,
-0.2024597675,
-0.3106692731,
0.0610066131,
0.2480496466,
-0.0570772253,
-0.3021195531,
-0.0394040011,
0.1576770544,
0.4314782023,
0.3482896686,
0.0546974987,
0.0542732365,
0.0635230839,
0.4671571553,
0.0356316864,
-0.1379923522,
-0.1034611613,
-0.1994125992,
-0.209197402,
-0.0487180911,
0.0821285769,
-0.2137954533,
-0.1844109446,
0.0768030807,
-0.3701885939,
-0.2570813596,
0.0774946138,
0.2857018113,
-0.2290334702,
0.1629439443,
0.1929098815,
0.3248440027,
-0.1220192835,
-0.0420767367,
-0.0501533933,
0.0670062229,
-0.159244135,
0.0389008224,
0.1803867966,
-0.0867385268,
0.3818193376,
0.0401841626,
0.0921658799,
-0.3538573086,
-0.003208105,
-0.0678691417,
-0.2303743511,
0.1984225065,
0.0741806328,
0.1317721754,
0.1278306544,
-0.1131033525,
-0.1956662238,
-0.1276558936,
-0.3680233061,
-0.2253899872,
-0.0008966093,
0.1988530904,
-0.2186917514,
0.0545959584,
-0.6963660121,
-0.0509544164,
-0.0419291854,
-0.0464196019,
0.0845763534,
-0.1989386827,
-0.0067008729,
-0.1512913108,
0.2821941674,
0.3203701973,
-0.1023371071,
-0.3406152427,
0.1919257045,
-0.275454849,
-0.0196079705,
0.4326659739,
-0.1196046919,
0.3191314042,
-0.4245502651,
0.0054523423,
0.1131412461,
-0.3381482363,
-0.0048068683,
0.2169421166,
0.0092139319,
0.232269913,
0.0359769501,
-0.2388061434,
-0.1298641115,
0.0910003781,
0.3294608593,
0.1763609499,
0.1139989719,
0.0156232035,
-0.2624560893,
-0.3958942294,
-0.1333959997,
0.1869225353,
-0.2713267207,
0.0921688825,
-0.0596274622,
-0.0232312661,
0.2330236435,
-0.1433590651,
0.0127937179,
0.4333834648,
0.155869171,
0.1573786885,
-0.061277993,
0.0932181925,
-0.6979959607,
0.1328967065,
-0.0690755323,
0.0120620662,
-0.0227208622,
-0.071153,
-0.2446413934,
-0.0678765625,
-0.0997857153,
-0.1033035666,
0.0711105466,
0.010174728,
0.3387506902,
0.2818097472,
-0.246356234,
0.1922811866,
-0.049421113,
0.2872020006,
-0.5857246518,
0.1933600157,
-0.0093663707,
-0.0926667526,
0.1968166381,
0.1675875336,
-0.0514307916,
-0.1823319942,
-0.1827307791,
0.1993961781,
0.1029932052,
0.2051813155,
-0.1032669619,
-0.0284450725,
0.094530642,
0.1075310782,
-0.2653549016,
0.0603615008,
0.078157939,
0.0286740512,
-0.0418726057,
0.5341287851,
-0.1148446575,
0.2213409841,
0.0766219795,
-0.10443189,
0.2141028494,
0.0639370754,
-0.1881943047,
-0.237731874,
0.2143947482,
0.138001129,
0.1106339544,
-0.0020108812,
-0.3137222826,
-0.5011649132,
0.5217190981,
-0.0168396998,
-0.1254667491,
0.3644662201,
-0.0574157052,
0.1340657771,
-0.058686059,
0.2645537257,
0.4018251896,
0.0265592411,
-0.2938234806,
0.2048301995,
0.1147208139,
-0.2163889706,
0.1398201883,
0.0095037557,
0.4020665288,
0.2714263499,
0.1444056034,
-0.0333297178,
-0.3379943967,
-0.0209021326,
-0.0710308924,
0.2027644962,
-0.5042114258,
0.0478346311,
-0.2015907466,
-0.1951348186,
-0.1955136359,
-0.0087175714,
-0.3526833653,
-0.1619843692,
-0.1104398146,
0.2864406109,
-0.1634217203,
-0.0450172983,
0.0513242967,
0.1841050386,
-0.0129033653,
0.0241813287,
-0.2525187433,
-0.0483512506,
-0.3117141128,
-0.0078159804,
0.2585226595,
-0.2897990048,
0.2653307021,
-0.4591294825,
-0.1182123646,
0.007527573,
-0.1000631079,
0.1988496184,
-0.1559775025,
0.4537517726,
0.2338897437,
0.2243228704,
-0.2807896733,
-0.1702593267,
0.4613271058,
0.0503283963,
-0.4220076203,
-0.0879084095,
0.1139320955,
0.2057726383,
-0.2229391783,
-0.3621909618,
-0.1776330173,
-0.3771743178,
0.6544156671,
0.0726229101,
-0.0296465643,
0.2495339215,
0.1801407188,
0.1754177213,
-0.250353992,
0.2039492577,
-0.2125451267,
-0.6592340469,
0.2696394026,
-0.216662243,
-0.2896184623,
-0.0027302359,
0.0093040783,
0.248526603,
-0.3560528159,
-0.619069159,
-0.4293156564,
0.0659179091,
-0.061191991,
-0.16194278,
0.0458928496,
0.0071959435,
-0.0986526012,
0.050584361,
-0.0661337897,
-0.2864847183,
0.0818164051,
0.0266982298,
0.1894084215,
0.008636876,
0.7049926519,
-0.1662607789,
0.5409069657,
0.3434601426,
-0.0701491162,
0.3889723718,
-0.0936021954,
0.2095706463,
-0.1691486388,
-0.1462808251,
-0.0268659126,
-0.1617912352,
0.0717206076,
0.0588047951,
0.1540789157,
0.1976181418,
-0.2083401978,
0.1552497,
-0.4492764473,
-0.1839313209,
-0.0461466573,
-0.0946728438,
0.0315794647,
-0.0106512969,
0.0896676928,
0.127778694,
0.1054071561,
0.0371168479,
0.2056740075,
0.314006567,
0.061304003,
-0.4587744176,
-0.3308938146,
-0.2036664188,
0.2401332557,
0.1003948972,
0.3333870173,
-0.0022292139,
0.0095439833,
0.1171923801,
-0.0433093011,
0.7829500437,
0.0229544919,
-0.1166758686,
0.1596716493,
-0.1625589877,
-0.4724912345,
-0.1087148339,
-0.133836776,
-0.0483324267,
0.3722941577,
0.8682687879,
-0.3360642493,
-0.1985802203,
-0.0987327844,
0.1553071737,
-0.1306389719,
-0.187066704,
-0.3030403256,
-0.2799439728,
-0.4903612137,
0.0596249551,
0.0329061262,
0.2734743655,
-0.0380799994,
0.1360523552,
0.1459161639,
-0.0076578162,
-0.0049632117,
0.210031718,
0.4084856808,
-0.0098689664,
0.3402072787,
0.3098992109,
0.249102354,
0.3677905798,
0.7469066381,
0.0636732578,
-0.2964291573,
-0.0552903973,
0.1199039817,
0.2270906568,
-0.0142233195,
0.0701462999,
0.0987492055,
0.170416519,
0.3289013803,
-0.3388036191,
-0.0540237576,
0.5773521066,
-0.0147733008,
-0.1686761081,
-0.3146701753,
0.3603610098,
0.0742139816,
0.1956618577,
-0.0543625169,
0.0128701925,
-0.1717940867,
0.1986907423,
-0.0580897294,
0.6426671147,
0.041034136,
0.2202431262,
0.5174716711,
-0.3893911839,
0.6693493724,
-0.1723386645,
0.1359887719,
-0.3668430448,
0.2025949955,
0.1137449443,
-0.2214799523,
-0.0057905712,
0.118041575,
-0.0245310199,
0.1728488058,
-0.0594638251,
0.120569095,
-0.2271813303,
0.2292222977,
-0.1973718256,
-0.1767253578,
-0.4899870157,
0.1108957306,
-0.106315285,
0.3157327771,
-0.1119737029,
-0.1421793401,
0.0486256219,
-0.3089966774,
-0.1911001056,
0.0872482285,
0.0307390988,
0.0864578858,
0.5069152713,
-0.1722017676,
0.1963101625,
0.1368945986,
0.0575768277,
0.0785309002,
-0.2300154716,
0.0443574786,
-0.1107219309,
-0.0008314709,
-0.1347521394,
0.2036358565,
0.2695465088,
-0.0969243869,
-0.1381716579,
-0.0848918706,
-0.1955979764,
-0.1309943944,
-0.1497298479,
-0.0125661017,
-0.4126690626,
-0.4154501557,
-0.2140529901,
-0.1833785474,
0.1914477199,
-0.1703625321,
0.1283924878,
0.1161877066,
-0.1064132154,
0.0747165978,
0.2552984357,
-0.3055809736,
-0.1695125997,
0.5493264794,
-0.1176681295,
-0.1337290555,
0.6553979516,
0.3517473638,
-0.0721328259,
-0.1893496662,
0.1886556447,
0.2534579635,
-0.4216069877,
0.294614464,
0.1764449328,
0.1769771725,
-0.1669337004,
0.1598338038,
0.2890992463,
-0.1827304661,
0.449313283,
-0.4461555481,
-0.3589730263,
0.4695273936,
0.0019768814,
0.0396901928,
0.1364274323,
0.0713223815,
-0.0435879566,
-0.21863693,
-0.2505391538,
0.223689571,
-0.2346875817,
0.0015197775,
0.0722896978,
-0.0833659247,
0.262863636,
-0.0550882407,
0.1258090883,
0.0181683768,
-0.2430793345,
-0.1703760624,
-0.21988675,
0.1022371277,
0.0916893333,
-0.0825781152,
-0.021422917,
-0.0095979962,
-0.0524590462,
-0.0974018648,
-0.051132381,
0.1828258783,
0.0304386634,
0.1656942815,
-0.0667007044,
0.124261789,
0.0737923905,
0.0544174425,
0.1397259086,
0.3586376607,
0.0709488615,
0.0079622334,
-0.021438079,
0.1426149458,
-0.3928214014,
0.0468650907,
0.0296994634,
0.1558367461,
0.1975919753,
-0.40179196,
0.2436898947,
0.0290441066,
0.3491036892,
0.4257697165,
-0.3299903274,
0.1761911064,
0.2828635275,
0.1883086413,
-0.078606911,
-0.004289947,
0.1354809254,
0.0848242715,
-0.2222461551,
0.1510528326,
0.0843078643,
0.0678326041,
-0.056127809,
0.0868750811,
0.3202267289,
0.239423126,
0.3058688343,
0.2223344743,
-0.195542112,
-0.0938358679,
0.074269928,
-0.0799549669,
0.2401864231,
0.0005881279,
-0.0545161739,
0.0338519812,
-0.2134518325,
0.3194333315,
-0.071999684,
-0.4417429566,
-0.0709563568,
0.228935346,
0.0511632115,
0.1648878604,
-0.1775567383,
0.4963746071,
-0.211997807,
-0.1648306698,
-0.2633141875,
0.1758677512,
-0.2053365111,
-0.2065399587,
-0.215198338,
-0.1676559299,
-0.1347580999,
0.2014636844,
-0.1771533489,
-0.0966489539,
-0.0321691409,
0.0779949129,
-0.1797043085,
-0.3269407451,
-0.0170994643,
0.1791392863,
0.2103992254,
-0.2002665997,
0.3669706285,
0.1837556213,
-0.052306734,
0.1637097597,
0.3483298719,
0.4240888357,
0.3204253614,
0.0127492566,
-0.0784213021,
-0.1569111198,
0.1721219867,
-0.0072618015,
0.4151534438,
0.3016722202,
-0.0031570832,
0.2723674178,
0.2047588825,
-0.1988955438,
0.1950961798,
-0.2120902836,
0.1915848553,
-0.3537285924,
0.3471528292,
-0.2910782695,
0.0533866324,
-0.131799832,
-0.0303770415,
-0.5330359936,
0.1089277193,
0.1380347311,
0.2585886717,
0.1249771565,
-0.0668072551,
0.0806054026,
-0.060285043,
0.5182250142,
0.4697231948,
-0.0676173717,
-0.1682688445,
-0.0918279439,
-0.3658511937,
0.0036741698,
-0.0419382043,
0.251224786,
0.0493086576,
0.0020497481,
-0.1228635311,
0.0443270579,
0.1156296432,
0.0135102905,
-0.2387488037,
-0.023170989,
-0.3098828793,
-0.2353609949,
-0.1282880604,
0.1051923707,
0.196744144,
-0.0563616566,
0.1240238547,
-0.1950150281,
-0.061294876,
-0.0586340837,
0.1792267114,
-0.2045845687,
-0.0162188672,
0.401927352,
0.1814273745,
0.264839381,
-0.0185227208,
-0.4301638305,
-0.149386704,
-0.5540161133,
0.0070735915,
0.4055223167,
-0.2410167158,
0.5479884148,
-0.3040449023,
0.0796021149,
-0.4800192714,
-0.0059700073,
-0.1186262891,
-0.2518825531,
-0.217388764,
0.044599209,
-0.0655938089,
0.0814151391,
0.2365541011,
0.3868668675,
-0.115786396,
0.2363210618,
-0.3685119152,
-0.1168655753,
0.5598025918,
-0.3521031141,
-0.007716882,
0.2889506817,
0.0990875661,
0.1163512319,
-0.2863300741,
-0.5784287453,
0.1735920757,
0.4648890197,
-0.068638131,
-0.1293683499,
0.1640017331,
-0.1718789786,
-0.1922334731,
0.0208100844,
0.2710583508,
0.0801740885,
-0.2423925996,
0.3271267414,
-0.1105744541
] |
https://github.com/huggingface/datasets/issues/3333 | load JSON files, get the errors | If your JSON has the same format as the SQuAD dataset, then you need to pass `field="data"` to `load_dataset`, since the SQuAD format is one big JSON object in which the "data" field contains the list of questions and answers.
```python
dataset = datasets.load_dataset('json', data_files=args.dataset, field="data")
```
Let me know if that helps :)
| Hi, does this bug be fixed? when I load JSON files, I get the same errors by the command
`!python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/`
change the dateset to load json by refering to https://huggingface.co/docs/datasets/loading.html
`dataset = datasets.load_dataset('json', data_files=args.dataset)`
Errors:
`Downloading and preparing dataset json/default (download: Unknown size, generated: Unknown size, post-processed: Unknown size, total: Unknown size) to /root/.cache/huggingface/datasets/json/default-c1e124ad488911b8/0.0.0/45636811569ec4a6630521c18235dfbbab83b7ab572e3393c5ba68ccabe98264...
`
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/730#issuecomment-981095050_ | 54 | load JSON files, get the errors
Hi, does this bug be fixed? when I load JSON files, I get the same errors by the command
`!python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/`
change the dateset to load json by refering to https://huggingface.co/docs/datasets/loading.html
`dataset = datasets.load_dataset('json', data_files=args.dataset)`
Errors:
`Downloading and preparing dataset json/default (download: Unknown size, generated: Unknown size, post-processed: Unknown size, total: Unknown size) to /root/.cache/huggingface/datasets/json/default-c1e124ad488911b8/0.0.0/45636811569ec4a6630521c18235dfbbab83b7ab572e3393c5ba68ccabe98264...
`
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/730#issuecomment-981095050_
If your JSON has the same format as the SQuAD dataset, then you need to pass `field="data"` to `load_dataset`, since the SQuAD format is one big JSON object in which the "data" field contains the list of questions and answers.
```python
dataset = datasets.load_dataset('json', data_files=args.dataset, field="data")
```
Let me know if that helps :)
| [
0.1509884447,
-0.4040397704,
0.009308829,
0.4606098533,
0.5046644211,
0.107641615,
0.1017882675,
0.380048871,
0.0705014169,
-0.0852152482,
-0.0908838287,
0.3143799901,
-0.0701697394,
0.2513686121,
-0.1658848226,
-0.0779561773,
0.0888331905,
0.0130545571,
-0.0961667895,
0.0574556291,
-0.2108668983,
0.3167819381,
-0.0635553077,
0.0575320981,
-0.1894326657,
-0.0899973065,
0.0082348455,
0.2288094163,
-0.3139980733,
-0.4765467942,
0.2592284679,
-0.1434778422,
0.2918537557,
0.4062541425,
-0.0001137175,
0.0604162738,
0.2810268998,
-0.182154268,
-0.3842883408,
-0.4302688241,
-0.0858106241,
-0.3285009563,
0.4134623408,
-0.0705341101,
-0.1023332626,
-0.07383205,
-0.0984489545,
-0.1354840994,
0.9241046309,
0.2639930844,
0.2411632389,
0.3660384417,
0.1523805857,
-0.1536723971,
0.1089029759,
0.3462021351,
-0.0603209026,
0.5437943935,
0.1788774431,
0.1844477803,
0.1970570982,
0.1332709491,
0.0792277381,
0.0119435489,
0.3227823377,
-0.0194670986,
-0.0851568282,
-0.3502999544,
-0.2069041431,
0.0802495927,
0.3580500782,
-0.2085027099,
-0.5740363598,
-0.4564510286,
0.2037748098,
-0.233047232,
0.3337393105,
0.2167317122,
-0.0390526205,
-0.0063426429,
-0.2889981568,
-0.1617598981,
-0.1154532805,
0.0545036942,
0.3631138206,
-0.0658692792,
-0.2739939392,
0.0649829432,
0.1216585264,
-0.2355511785,
-0.2081927955,
0.1158925518,
-0.2066939175,
0.3120718598,
-0.2958754301,
-0.2271512449,
-0.1802415103,
-0.3376176655,
0.1299241036,
0.2405915409,
0.014932015,
-0.1965971142,
0.0483106226,
0.10808523,
0.4441876709,
0.2970480323,
0.0925308838,
0.0338905491,
0.0369195193,
0.4481211305,
-0.0406338796,
-0.1473995298,
-0.1095407978,
-0.1277868897,
-0.1701502353,
-0.0653032437,
0.1303460896,
-0.225653246,
-0.1103648171,
0.1687685251,
-0.3327825665,
-0.1991238296,
-0.0055739908,
0.3101698458,
-0.2428603768,
0.140444234,
0.1365002692,
0.3748107255,
-0.1173209772,
-0.0520126,
-0.0323098078,
-0.0336030461,
-0.1304422319,
0.0716614872,
0.2569179833,
-0.0843582079,
0.3716450036,
0.0733498484,
0.1715623289,
-0.4003708661,
0.0115790265,
-0.0490624346,
-0.2556214035,
0.1656665504,
0.1443749815,
0.0673416033,
0.1018360183,
-0.1876984835,
-0.1008505896,
-0.0805239975,
-0.3622412384,
-0.1897530556,
-0.0696831867,
0.1900395155,
-0.1645860821,
0.01732211,
-0.5817547441,
0.0484974906,
-0.0205351356,
-0.0679493919,
0.1141840294,
-0.1037723944,
0.0274045672,
-0.1707321852,
0.2817678452,
0.3137201369,
-0.1730691046,
-0.3155516386,
0.2782933414,
-0.2604697347,
-0.1300697625,
0.4196873307,
-0.0348124541,
0.2817523479,
-0.3295409977,
-0.025624752,
0.1017982289,
-0.3967048228,
-0.0569439903,
0.1328180432,
-0.0231279414,
0.1753523648,
0.0101533514,
-0.1822167188,
0.0111483913,
0.1203569546,
0.2536340356,
0.2390412241,
0.0537195243,
0.0392453633,
-0.3092145026,
-0.391403079,
-0.1953722984,
0.2199300081,
-0.2394936979,
0.1532949358,
-0.0006975703,
-0.0329471491,
0.1821902096,
-0.1564652026,
0.01000439,
0.426333338,
0.179544881,
0.1940691024,
-0.0503816381,
-0.0042969952,
-0.7773267031,
0.1245454624,
-0.2235744447,
0.0473214835,
0.0327783898,
-0.1188036352,
-0.2765946686,
-0.1035673991,
-0.0736735985,
-0.0516600087,
0.0903172493,
-0.1092831716,
0.3410094976,
0.2877993286,
-0.2390748411,
0.1482575834,
-0.0836422369,
0.4305509627,
-0.5436580777,
0.1818381846,
-0.0285951328,
-0.1262467653,
0.2170760483,
0.1718534827,
0.04008637,
-0.1421132386,
-0.1317714006,
0.2209817916,
0.0142020825,
0.1882128417,
0.0597627722,
-0.0864121765,
0.15293549,
0.1528058201,
-0.2017225176,
0.1650889069,
0.1124668121,
-0.0377751291,
-0.0682965145,
0.4642000496,
-0.1274471581,
0.1565677822,
0.0093056178,
-0.0555118695,
0.1739483476,
0.0896923468,
-0.1511451006,
-0.1389352679,
0.1621342152,
0.1562859863,
0.0686654299,
-0.0742666572,
-0.2915638089,
-0.403565377,
0.5127905011,
-0.0609380417,
-0.0712401867,
0.439481169,
-0.0242189188,
0.1174093336,
-0.1215930581,
0.1456147879,
0.4512653649,
0.0260079205,
-0.3486895561,
0.1664756536,
0.1350357234,
-0.1467083544,
0.0859861821,
-0.00572715,
0.4057774544,
0.2141221762,
0.258756578,
-0.0067115319,
-0.2772932053,
0.056746576,
-0.1485978961,
0.2109827101,
-0.498267591,
-0.013587676,
-0.0764118358,
-0.1151041463,
-0.1543157399,
0.0320197046,
-0.4799400568,
-0.1024072841,
-0.0040106932,
0.2521389127,
-0.0906398371,
-0.0571440719,
0.1593225896,
0.3105985522,
0.0443306863,
0.0420967303,
-0.1780399382,
0.0037279478,
-0.253729552,
-0.0164598189,
0.1856947392,
-0.3560530245,
0.2357637882,
-0.4365238249,
-0.0895676166,
-0.0325217992,
-0.1421381235,
0.1426028907,
-0.181276083,
0.5109777451,
0.1030100062,
0.3385249078,
-0.3648154736,
-0.1404361427,
0.4575715363,
0.0080968915,
-0.3988077641,
-0.1104980558,
0.0646907091,
0.2117903531,
-0.2115660608,
-0.4209468067,
-0.2111951858,
-0.3019482493,
0.6834772229,
0.138897121,
-0.0035204338,
0.1959457994,
0.1852078736,
0.1516629606,
-0.3170526624,
0.2268946916,
-0.2718640864,
-0.6679094434,
0.2737726271,
-0.2587823272,
-0.3849782646,
0.028256977,
0.1564611495,
0.1358894408,
-0.4363437295,
-0.5586739779,
-0.5158256888,
0.0678529739,
-0.0710686967,
-0.2259964049,
0.1294164062,
0.0522616729,
-0.1508233994,
0.0223632306,
-0.0461570099,
-0.3275395632,
0.0922732428,
0.0741758719,
0.2326545119,
-0.1012454554,
0.6246879101,
-0.1615374833,
0.6484115124,
0.3887174129,
0.0148317879,
0.3194821775,
-0.0399645008,
0.2468174249,
-0.1572781205,
-0.1757112294,
0.0831988826,
-0.1874001622,
0.1111142039,
0.111395523,
0.2242416888,
0.1794013679,
-0.1618176997,
0.1847024113,
-0.441295296,
-0.1998859644,
-0.0516868792,
-0.0076706954,
-0.0502421893,
0.0161523353,
0.0968108252,
0.0259450544,
-0.0352617502,
-0.0191378165,
0.2304226011,
0.290119797,
0.0997559503,
-0.5272747874,
-0.3186487257,
-0.1658247709,
0.2804069519,
0.0194802154,
0.266494602,
-0.049220264,
0.0227408092,
0.194969207,
-0.0114703262,
0.760240972,
0.1191462353,
-0.1630523056,
0.0774101615,
-0.0565382242,
-0.48119241,
-0.0878241956,
-0.1233474091,
-0.0308891386,
0.3825471103,
0.7556053996,
-0.3792795837,
-0.1597597301,
-0.1202232614,
0.0868092328,
-0.1065294966,
-0.1007217318,
-0.3141183257,
-0.298763603,
-0.5528581738,
0.1074725613,
-0.0087534115,
0.2717385292,
-0.0187920816,
0.0798840299,
0.2022550851,
0.0726987496,
-0.0130653195,
0.2334717661,
0.398200959,
0.0515069552,
0.2653996646,
0.3393430114,
0.1905385703,
0.2868142724,
0.6921907663,
0.1060692519,
-0.2763177752,
-0.0999951065,
0.033709079,
0.2343094498,
0.1311189085,
0.0879621357,
0.1097293273,
0.1062411517,
0.3571222723,
-0.3401987851,
-0.1438456625,
0.5598685741,
-0.0519935489,
-0.1276729107,
-0.1829440594,
0.3120658398,
-0.0350378603,
0.1927145272,
-0.0408315212,
0.0746657103,
-0.1246732846,
0.2589412928,
-0.0528033189,
0.8256853223,
-0.0702441931,
0.2461864948,
0.4468618035,
-0.4051091671,
0.682687223,
-0.2507863045,
0.1453539282,
-0.3794082105,
0.178995505,
0.1450039297,
-0.1498985738,
0.0276818573,
0.2364230156,
-0.1200221404,
0.1377722174,
-0.1257295907,
0.1578961462,
-0.1863213331,
0.2348378748,
-0.2236119658,
-0.1955494434,
-0.5561304092,
0.1313774884,
-0.2109011114,
0.2602806985,
-0.1129459441,
-0.1390668899,
0.0218065064,
-0.3234155476,
-0.2336009592,
0.070680052,
-0.061073821,
0.0166098252,
0.5394458175,
-0.161224246,
0.1769842356,
0.2090089172,
0.1034217849,
0.1772256047,
-0.2668081224,
0.0987229049,
-0.1093769893,
-0.0057581649,
-0.1352314949,
0.175958842,
0.1704938114,
-0.110845685,
-0.205566898,
-0.0238589831,
-0.1637409776,
-0.1237409189,
-0.2407141179,
0.0440520048,
-0.3765313923,
-0.417599529,
-0.2273833752,
-0.2336921096,
0.1858914196,
-0.1329336017,
0.151159212,
0.108249113,
-0.0678939894,
0.1052338257,
0.3806173801,
-0.2371737212,
-0.1610136628,
0.5662915707,
-0.1429553628,
-0.2168228179,
0.633325398,
0.3785923719,
-0.0708335638,
-0.1960035264,
0.2308381945,
0.1025708988,
-0.4083161354,
0.2211985588,
0.2010829002,
0.1144567281,
-0.1685425937,
0.1348610222,
0.2433278114,
-0.2526735961,
0.4581858814,
-0.4793316722,
-0.397519052,
0.3743852377,
0.0561464727,
0.0029573482,
0.2205412686,
-0.0173650403,
0.0172305536,
-0.0520180613,
-0.2695714533,
0.2629310489,
-0.2961842716,
0.0282312352,
0.0485455841,
-0.1810189933,
0.2621257603,
-0.1117675081,
0.0806125402,
0.0668153241,
-0.2185501307,
-0.1781151742,
-0.1251763403,
0.1178087071,
0.0395116359,
-0.0915959701,
-0.0650563315,
-0.0515485108,
-0.0876062959,
-0.1068198979,
-0.0216622557,
0.1955141276,
0.1194053739,
0.1101342514,
-0.1074115857,
0.1096569225,
0.1123830676,
-0.0441413932,
0.1913999468,
0.3335889876,
0.096702911,
-0.0361067541,
-0.105802156,
0.1221558228,
-0.3424414694,
0.1218827888,
0.170606941,
0.2003532201,
0.2559936047,
-0.4321783185,
0.1386342496,
0.035853073,
0.2465950549,
0.3951205909,
-0.3866308928,
0.1818053573,
0.1975160837,
0.194957003,
-0.0878834426,
-0.0360596068,
0.2132616937,
-0.0032148641,
-0.2863660753,
0.1597023904,
0.0075280266,
0.0651938692,
0.0105619542,
0.1632225811,
0.366548717,
0.1968700886,
0.2581229806,
0.0397356413,
-0.1349520534,
-0.1380935758,
0.1082731113,
-0.1021068543,
0.1364914179,
-0.0014435831,
-0.0786891058,
0.0131429024,
-0.2321169227,
0.2592004836,
-0.0406074189,
-0.3574430048,
-0.0752228573,
0.2347521931,
0.0473146401,
0.1219080389,
-0.1521643698,
0.6368672252,
-0.2204053551,
-0.2777150273,
-0.3168070912,
0.1022549197,
-0.1590247452,
-0.1568717211,
-0.2029151469,
-0.1707223952,
-0.0942768008,
0.1126497686,
-0.1616447568,
-0.1699355245,
0.0090584457,
0.0491292514,
-0.1805889606,
-0.3565668464,
-0.061169222,
0.2049726546,
0.2614811659,
-0.1035222933,
0.3367489874,
0.1704491377,
-0.0328248292,
0.2327253968,
0.3907315135,
0.4232472181,
0.3361713588,
-0.0686805323,
0.0730429813,
-0.1447634399,
0.1169120595,
0.0757915601,
0.4168100357,
0.3448211551,
-0.1159628406,
0.2204666883,
0.2071309835,
-0.1845900714,
0.0676622093,
-0.1855190247,
0.2297208905,
-0.2958405316,
0.2098509818,
-0.2581589222,
0.0778531432,
-0.1857815534,
-0.1307394654,
-0.5594200492,
0.1407632977,
0.1128980666,
0.2870491445,
0.0948292911,
-0.1865877509,
0.0791609511,
-0.058346387,
0.4962323606,
0.4631526768,
-0.1232185364,
-0.217063725,
-0.0275554731,
-0.3539568484,
0.0249898862,
0.0002042896,
0.2708150148,
0.0654752851,
0.0690397173,
-0.0684145391,
0.1018344089,
0.1815822572,
-0.0939876363,
-0.2508916557,
-0.0044126255,
-0.3523718417,
-0.2206742913,
-0.192310974,
0.1513582468,
0.2137770951,
0.0024128777,
0.141297549,
-0.1858398467,
-0.0716446266,
-0.0307645667,
0.1216839775,
-0.2475351542,
-0.1124068946,
0.3767677248,
0.1233751029,
0.2569788098,
-0.0182945505,
-0.4469942153,
-0.1452417821,
-0.4878299236,
-0.0079329368,
0.3580108285,
-0.2052111328,
0.5472480059,
-0.2908646166,
-0.0030834265,
-0.4081866741,
0.0609137043,
-0.1088409871,
-0.2680747807,
-0.2279505134,
0.0016211666,
0.051766973,
0.0801772848,
0.1726200581,
0.35693717,
-0.1285444796,
0.3508350253,
-0.367197603,
-0.1293616742,
0.6051706076,
-0.3269460499,
-0.017461719,
0.2658371925,
0.1819409132,
0.0651489645,
-0.3210346401,
-0.6778943539,
0.1931592077,
0.363447845,
-0.0822665319,
-0.1599605978,
0.168157801,
-0.2583090961,
-0.2306867093,
-0.0214244574,
0.2568341196,
0.0261235517,
-0.1384713203,
0.2587220371,
-0.1107874811
] |
https://github.com/huggingface/datasets/issues/3333 | load JSON files, get the errors | Yes, code works. but the format is not as expected.
```
dataset = datasets.load_dataset('json', data_files=args.dataset, field="data")
```
```
python3 run.py --do_train --task qa --dataset squad --output_dir ./re_trained_model/
```
************ train_dataset: Dataset({
features: ['id', 'title', 'context', 'question', 'answers'],
num_rows: 87599
})
```
python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/
```
************ train_dataset: Dataset({
features: ['title', 'paragraphs'],
num_rows: 442
})
I want the JSON to have the same format as before features. https://github.com/huggingface/datasets/blob/master/datasets/squad_v2/squad_v2.py is the script dealing with **squad** but how can I apply it by using JSON? | Hi, does this bug be fixed? when I load JSON files, I get the same errors by the command
`!python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/`
change the dateset to load json by refering to https://huggingface.co/docs/datasets/loading.html
`dataset = datasets.load_dataset('json', data_files=args.dataset)`
Errors:
`Downloading and preparing dataset json/default (download: Unknown size, generated: Unknown size, post-processed: Unknown size, total: Unknown size) to /root/.cache/huggingface/datasets/json/default-c1e124ad488911b8/0.0.0/45636811569ec4a6630521c18235dfbbab83b7ab572e3393c5ba68ccabe98264...
`
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/730#issuecomment-981095050_ | 88 | load JSON files, get the errors
Hi, does this bug be fixed? when I load JSON files, I get the same errors by the command
`!python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/`
change the dateset to load json by refering to https://huggingface.co/docs/datasets/loading.html
`dataset = datasets.load_dataset('json', data_files=args.dataset)`
Errors:
`Downloading and preparing dataset json/default (download: Unknown size, generated: Unknown size, post-processed: Unknown size, total: Unknown size) to /root/.cache/huggingface/datasets/json/default-c1e124ad488911b8/0.0.0/45636811569ec4a6630521c18235dfbbab83b7ab572e3393c5ba68ccabe98264...
`
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/730#issuecomment-981095050_
Yes, code works. but the format is not as expected.
```
dataset = datasets.load_dataset('json', data_files=args.dataset, field="data")
```
```
python3 run.py --do_train --task qa --dataset squad --output_dir ./re_trained_model/
```
************ train_dataset: Dataset({
features: ['id', 'title', 'context', 'question', 'answers'],
num_rows: 87599
})
```
python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/
```
************ train_dataset: Dataset({
features: ['title', 'paragraphs'],
num_rows: 442
})
I want the JSON to have the same format as before features. https://github.com/huggingface/datasets/blob/master/datasets/squad_v2/squad_v2.py is the script dealing with **squad** but how can I apply it by using JSON? | [
0.2061130106,
-0.4305946231,
0.0149481921,
0.5158005357,
0.5084050298,
0.1291912496,
0.1452688873,
0.4161996543,
0.0887658671,
-0.1716812849,
-0.1046591774,
0.2278075069,
-0.0519552827,
0.2885661125,
-0.1512390822,
-0.1212860569,
0.1154834852,
0.0552953891,
-0.1520932615,
0.0953136981,
-0.243435666,
0.4135742784,
-0.0449634455,
0.0458582267,
-0.2311981171,
-0.0075423815,
-0.026032852,
0.1966623515,
-0.2593542337,
-0.4834583998,
0.2888892591,
-0.069297567,
0.2357516885,
0.5206592083,
-0.0001174146,
0.116442062,
0.3516381681,
-0.2140987366,
-0.3159610033,
-0.3655146956,
-0.1830621213,
-0.3017644584,
0.3520093262,
-0.0912421569,
-0.1478589773,
-0.2148845345,
-0.1609216928,
-0.1368544102,
0.8742623925,
0.3022543788,
0.2276326567,
0.3826766908,
0.1959200352,
-0.0906643942,
0.1101580113,
0.4140202403,
-0.1147764921,
0.5914291143,
0.0321309492,
0.2422958612,
0.25319314,
0.125805825,
0.1001682132,
-0.0267953966,
0.3157680631,
-0.0387089923,
-0.0838328004,
-0.2221704572,
-0.2339943349,
0.0980882272,
0.3543118238,
-0.2562561631,
-0.6356512904,
-0.4264783263,
0.1062531173,
-0.3537048995,
0.3422802985,
0.2250052094,
0.0407026187,
-0.0016651793,
-0.3230773807,
-0.1391910762,
-0.1144890264,
0.0024390491,
0.2946382761,
-0.1080076918,
-0.3187968433,
0.0398222469,
0.073179163,
-0.2072348148,
-0.1472720504,
0.0099832406,
-0.234082669,
0.1902386397,
-0.2444163561,
-0.1387061477,
-0.2858536839,
-0.2497537136,
0.0606405176,
0.2053048015,
-0.0088337688,
-0.2114350349,
-0.057049606,
0.1016672626,
0.3643039465,
0.3585780561,
0.0718226656,
-0.0236208197,
0.0123660322,
0.4854677022,
0.0094932383,
-0.2122617215,
-0.0756292567,
-0.1743626595,
-0.2650752068,
-0.0659875944,
0.0733828545,
-0.2097927183,
-0.1166841537,
0.0495800041,
-0.2787104249,
-0.1999545991,
-0.0063588023,
0.3127253354,
-0.2561377287,
0.1620384753,
0.1728066951,
0.428368479,
-0.107408911,
-0.0756640434,
-0.06256558,
0.0415009819,
-0.1423696131,
0.0403266363,
0.1787102669,
-0.1275203228,
0.3814765513,
0.0533715263,
0.091426447,
-0.3433823287,
-0.0687336102,
-0.0339517184,
-0.1920689046,
0.1935618073,
0.0449981354,
0.0993370786,
0.1131107137,
-0.0961431563,
-0.0982789323,
-0.1071085408,
-0.3540143073,
-0.1682465225,
-0.045646891,
0.1537541151,
-0.2045472115,
0.0901360288,
-0.6574035287,
-0.0157465227,
0.0338481478,
-0.1038096547,
0.1174586266,
-0.1769224703,
-0.0678002015,
-0.1381735355,
0.2899678648,
0.2946497202,
-0.1416330785,
-0.3596592247,
0.2928160131,
-0.2345815301,
0.0190362576,
0.4480595589,
0.0219790787,
0.2736575007,
-0.4250182807,
0.0113250185,
0.0445964225,
-0.3627954721,
-0.0063838609,
0.1355774999,
0.0687474161,
0.2526344657,
0.1284222454,
-0.2617494464,
-0.105646424,
0.027969623,
0.2540198565,
0.130075261,
0.1425857842,
0.0116481157,
-0.3129459918,
-0.3812325299,
-0.1091500744,
0.1649816334,
-0.3355951607,
0.1743215472,
-0.050482735,
-0.0431429856,
0.2366029173,
-0.1407580823,
0.0020736819,
0.4137507379,
0.0861231759,
0.1611580104,
-0.0212373417,
0.1204157397,
-0.7090196013,
0.1425542831,
-0.1899881661,
0.0125347897,
0.0075810212,
-0.1068433598,
-0.2919786572,
-0.0999622941,
-0.1440551877,
-0.096967034,
0.0589928292,
-0.0067921882,
0.3354394436,
0.3071916103,
-0.1444942206,
0.2049380988,
-0.0805597901,
0.3053248823,
-0.5643773079,
0.1701256931,
0.034325216,
-0.070785962,
0.1971992254,
0.1973825842,
0.0707662851,
-0.2331688553,
-0.15341115,
0.2138022035,
0.0852541998,
0.2559077442,
-0.0940630659,
-0.0405686125,
0.1203838438,
0.1957461238,
-0.2543295324,
0.1868866235,
0.103127785,
-0.0764722079,
-0.0797305778,
0.5365522504,
-0.0872211829,
0.1490648538,
0.0269344039,
-0.1150188819,
0.2336382717,
0.1241158023,
-0.1934087873,
-0.1873593777,
0.1825243831,
0.154763341,
0.0759758651,
-0.037235871,
-0.3220035732,
-0.4127444625,
0.5348066688,
-0.0168772042,
-0.1328965127,
0.3684910238,
-0.0431957133,
0.0792274177,
-0.099695988,
0.1422288716,
0.4004844129,
0.0014323189,
-0.3116363883,
0.2093225121,
0.2145602256,
-0.2527654171,
0.1336353719,
0.0168172661,
0.3109524846,
0.2287160903,
0.2334379107,
-0.0728178546,
-0.2663582265,
0.1003723368,
-0.1169019192,
0.1327106208,
-0.5769360662,
0.0480541103,
-0.1714625508,
-0.1691319495,
-0.1633888781,
-0.0006674596,
-0.342888236,
-0.1390709877,
-0.07617452,
0.2782786489,
-0.1336509883,
-0.0322081894,
0.0847498849,
0.2586755157,
0.0191056821,
0.0573821999,
-0.2683960199,
0.0745596439,
-0.2792833745,
-0.0412318669,
0.194907859,
-0.3436377645,
0.1997746676,
-0.5095863342,
-0.0742815584,
-0.035849534,
-0.1472098678,
0.2133054882,
-0.1665445119,
0.4363236725,
0.1522024572,
0.2663024962,
-0.2562440932,
-0.0528104156,
0.4624167085,
0.0438596569,
-0.4029266834,
-0.0970982313,
0.0722870752,
0.2193986028,
-0.2650433481,
-0.3015251458,
-0.1560795456,
-0.3573856354,
0.7496997118,
0.122276932,
0.0168400649,
0.2423315495,
0.068557784,
0.121046558,
-0.3173161447,
0.2082212865,
-0.2694396079,
-0.6865052581,
0.3272516727,
-0.2638544738,
-0.3699577153,
0.0067503108,
0.1217855737,
0.221666798,
-0.3509181738,
-0.5408876538,
-0.409371376,
0.0860442445,
-0.0866393894,
-0.1039408967,
0.082913585,
0.0052059647,
-0.1444039047,
0.0625453517,
-0.0687175915,
-0.2533124685,
0.1097290143,
0.0546210371,
0.171729818,
0.0452933162,
0.6456708312,
-0.1994399726,
0.5689505339,
0.3666399419,
-0.0270541478,
0.4356900454,
-0.1002852246,
0.302685529,
-0.2420795262,
-0.1352825016,
-0.0015865013,
-0.1397028565,
0.179650858,
0.1286831796,
0.1958289444,
0.3104723394,
-0.1693096608,
0.1158335805,
-0.4171031117,
-0.1731127948,
-0.043390248,
-0.0357712917,
-0.0061143516,
-0.0291720312,
0.1342587024,
0.1091986075,
0.0016371455,
0.0547057614,
0.2634055912,
0.3510291874,
0.124883391,
-0.4720061719,
-0.3028372824,
-0.2764238715,
0.2632085681,
0.0407383889,
0.3241458237,
-0.0241191518,
0.0496082455,
0.126244396,
0.0007799922,
0.835005343,
0.1634930074,
-0.1214956194,
0.1666294187,
-0.1563874334,
-0.5317157507,
-0.130801484,
-0.0966932997,
-0.0056877807,
0.3249115944,
0.7922841907,
-0.3855462968,
-0.2399872392,
-0.2058624178,
0.1715111583,
-0.140165925,
-0.1680975854,
-0.3126828671,
-0.2625283301,
-0.4483352304,
0.0034329144,
0.0404962003,
0.2725113034,
-0.1063091159,
0.0955965295,
0.095592685,
0.0085825529,
0.0024193421,
0.1409291178,
0.4672668278,
0.004803394,
0.3076625466,
0.3430783451,
0.165399,
0.354303211,
0.6921959519,
0.1155673489,
-0.2806415856,
-0.0597874597,
0.0466321744,
0.1513929963,
0.0923139527,
0.0599672385,
0.0880669057,
0.1521472782,
0.3008918762,
-0.3673485816,
-0.1277961284,
0.6147100329,
-0.0441106409,
-0.1645762771,
-0.3140997291,
0.3751055002,
0.0222129524,
0.209438622,
-0.0308075808,
0.1241217554,
-0.1825281531,
0.1726449132,
-0.1277877241,
0.7358425856,
0.014391019,
0.2932621837,
0.5251529813,
-0.3760667145,
0.6131054163,
-0.1867120713,
0.1572927088,
-0.3269699216,
0.178264007,
0.0989101157,
-0.1767887622,
-0.0121429414,
0.2044520974,
-0.0722518191,
0.2312464863,
-0.1767107695,
0.1401423365,
-0.1711807549,
0.1786286384,
-0.1625872105,
-0.178671211,
-0.5652278066,
0.0830826983,
-0.124417901,
0.2867746055,
-0.091090478,
-0.2062188089,
0.0526596792,
-0.2565294802,
-0.1800961643,
0.100729093,
0.0124080935,
0.0287694894,
0.5366863608,
-0.1598254591,
0.1836003214,
0.1233321354,
0.1081091389,
0.0779707059,
-0.2950475812,
0.0712519959,
-0.1137177125,
0.0231932867,
-0.1655205041,
0.1808456928,
0.1578592211,
-0.0819330066,
-0.0815593228,
-0.1380273402,
-0.2384666204,
-0.1099986807,
-0.1805966347,
0.0008035,
-0.4120289087,
-0.397307992,
-0.2789471745,
-0.2258621901,
0.192402333,
-0.1520188004,
0.1244817451,
0.1249070317,
-0.0311871283,
0.0433324911,
0.3077871799,
-0.2549962997,
-0.1798395663,
0.5609437227,
-0.1107717454,
-0.1613609344,
0.7274045944,
0.3813877702,
-0.0904845148,
-0.1219666675,
0.151115343,
0.2010421455,
-0.4590614438,
0.2944206297,
0.1552112848,
0.2126476169,
-0.2002245039,
0.2284742594,
0.2034381926,
-0.2661660016,
0.4616598189,
-0.4526697993,
-0.360049665,
0.35632658,
0.0006304613,
0.0248569772,
0.2384748757,
0.0739122704,
-0.0224892367,
-0.1865466237,
-0.2383468896,
0.2201843709,
-0.1650244892,
-0.047852546,
0.1062442735,
-0.0733814687,
0.287127018,
-0.0990564525,
0.078572236,
0.0895540491,
-0.2644101679,
-0.1478522122,
-0.2052019089,
0.1341886222,
0.0428252406,
-0.0824275315,
0.0091120414,
0.0121276658,
-0.1615235656,
-0.1239288896,
-0.0009266313,
0.243604973,
0.0597132072,
0.1205533966,
-0.0587401055,
0.1403401494,
0.0699145794,
-0.0193968099,
0.199185282,
0.3993862867,
0.0707242489,
-0.0489178598,
-0.1672523618,
0.1019106656,
-0.3491772115,
0.0841368586,
0.0733606592,
0.1667467058,
0.2447481602,
-0.425860256,
0.2328438908,
0.0318441428,
0.3305580914,
0.4131918252,
-0.3569900692,
0.1520959735,
0.1949506104,
0.1491041332,
-0.0712017193,
-0.0364608504,
0.099046424,
0.0308277234,
-0.2815726697,
0.1082047075,
0.1464000791,
-0.0113583487,
0.0263382997,
0.1351596266,
0.3333384991,
0.1635466665,
0.2818306386,
0.070274137,
-0.1367839873,
-0.0227975026,
0.1714441031,
-0.0584156774,
0.171099782,
-0.0004807374,
-0.0108038904,
-0.0108693466,
-0.104960151,
0.2942438424,
-0.0895362571,
-0.4479380548,
-0.1585709453,
0.204676345,
0.0154207051,
0.1831970215,
-0.1255076975,
0.5783656836,
-0.198301807,
-0.2141425759,
-0.2952985466,
0.104147315,
-0.1406799853,
-0.2111438066,
-0.1489300877,
-0.1625686735,
-0.1020327732,
0.113018617,
-0.2505210638,
-0.0611296594,
-0.0028273608,
0.031196408,
-0.1495077163,
-0.3135869503,
-0.0465793125,
0.1514934599,
0.2781594396,
-0.1492146403,
0.3616597354,
0.2631327212,
-0.1092082039,
0.2438036203,
0.3824659586,
0.5052365065,
0.2991342247,
0.0795328245,
-0.0645875409,
-0.1607971191,
0.1176295951,
0.0820320472,
0.4862825572,
0.3641564846,
-0.1263085455,
0.2361902893,
0.1867636591,
-0.1663878858,
0.1502044052,
-0.1557552516,
0.2887703478,
-0.300816983,
0.2633892,
-0.3334355056,
0.0293954294,
-0.146414116,
-0.0806163773,
-0.593200624,
0.1232644618,
0.1151592582,
0.295906961,
0.116378583,
-0.0923308209,
0.0732710287,
-0.0470359623,
0.5171356201,
0.3958493769,
-0.0712681562,
-0.1957490146,
-0.0652702674,
-0.2699632645,
0.0369406119,
0.0197654832,
0.2805942595,
0.0307394173,
-0.0117583293,
-0.0487364233,
-0.0355930142,
0.1636744738,
-0.100065127,
-0.2022202015,
-0.0812746957,
-0.3472241759,
-0.2017074376,
-0.1410690248,
0.136468932,
0.2036542445,
-0.0261340905,
0.2083741277,
-0.2109571397,
-0.0734031498,
-0.0419688635,
0.2450845391,
-0.2194975019,
-0.015589294,
0.3308268189,
0.1615817845,
0.2373785824,
-0.0678061023,
-0.4204509854,
-0.1690695733,
-0.4997727573,
0.050788369,
0.435341239,
-0.2635085583,
0.5479080677,
-0.261759609,
-0.0725763589,
-0.4386530221,
0.0768358484,
-0.1549559832,
-0.2966077328,
-0.2171893269,
0.0798921511,
-0.0479730181,
-0.0094370646,
0.2348696887,
0.3423480093,
-0.1154444069,
0.2102312893,
-0.3330458999,
-0.1584507078,
0.6149756908,
-0.3621975482,
-0.0271531492,
0.2828932703,
0.1041067913,
0.0921670943,
-0.2257668078,
-0.6240166426,
0.2712187469,
0.3878113925,
-0.0752569512,
-0.1005601212,
0.1980679631,
-0.2592178285,
-0.1773024946,
-0.0118563948,
0.3121727109,
0.0594360679,
-0.2330366224,
0.1737131923,
-0.1385999173
] |
https://github.com/huggingface/datasets/issues/3333 | load JSON files, get the errors | Ok I see, you have the paragraphs so you just need to process them to extract the questions and answers. I think you can process the SQuAD-like data this way:
```python
def process_squad(articles):
out = {
"title": [],
"context": [],
"question": [],
"id": [],
"answers": [],
}
for title, paragraphs in zip(articles["title"], articles["paragraphs"]):
for paragraph in paragraphs:
for qa in paragraph["qas"]:
out["title"].append(title)
out["context"].append(paragraph["context"])
out["question"].append(qa["question"])
out["id"].append(qa["id"])
out["answers"].append({
"answer_start": [answer["answer_start"] for answer in qa["answers"]],
"text": [answer["text"] for answer in qa["answers"]],
})
return out
dataset = dataset.map(process_squad, batched=True, remove_columns=["paragraphs"])
```
I adapted the code from [squad.py](https://github.com/huggingface/datasets/blob/master/datasets/squad/squad.py). The code takes as input a batch of articles (title + paragraphs) and gets all the questions and answers from the JSON structure.
The output is a dataset with `features: ['answers', 'context', 'id', 'question', 'title']`
Let me know if that helps !
| Hi, does this bug be fixed? when I load JSON files, I get the same errors by the command
`!python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/`
change the dateset to load json by refering to https://huggingface.co/docs/datasets/loading.html
`dataset = datasets.load_dataset('json', data_files=args.dataset)`
Errors:
`Downloading and preparing dataset json/default (download: Unknown size, generated: Unknown size, post-processed: Unknown size, total: Unknown size) to /root/.cache/huggingface/datasets/json/default-c1e124ad488911b8/0.0.0/45636811569ec4a6630521c18235dfbbab83b7ab572e3393c5ba68ccabe98264...
`
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/730#issuecomment-981095050_ | 135 | load JSON files, get the errors
Hi, does this bug be fixed? when I load JSON files, I get the same errors by the command
`!python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/`
change the dateset to load json by refering to https://huggingface.co/docs/datasets/loading.html
`dataset = datasets.load_dataset('json', data_files=args.dataset)`
Errors:
`Downloading and preparing dataset json/default (download: Unknown size, generated: Unknown size, post-processed: Unknown size, total: Unknown size) to /root/.cache/huggingface/datasets/json/default-c1e124ad488911b8/0.0.0/45636811569ec4a6630521c18235dfbbab83b7ab572e3393c5ba68ccabe98264...
`
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/730#issuecomment-981095050_
Ok I see, you have the paragraphs so you just need to process them to extract the questions and answers. I think you can process the SQuAD-like data this way:
```python
def process_squad(articles):
out = {
"title": [],
"context": [],
"question": [],
"id": [],
"answers": [],
}
for title, paragraphs in zip(articles["title"], articles["paragraphs"]):
for paragraph in paragraphs:
for qa in paragraph["qas"]:
out["title"].append(title)
out["context"].append(paragraph["context"])
out["question"].append(qa["question"])
out["id"].append(qa["id"])
out["answers"].append({
"answer_start": [answer["answer_start"] for answer in qa["answers"]],
"text": [answer["text"] for answer in qa["answers"]],
})
return out
dataset = dataset.map(process_squad, batched=True, remove_columns=["paragraphs"])
```
I adapted the code from [squad.py](https://github.com/huggingface/datasets/blob/master/datasets/squad/squad.py). The code takes as input a batch of articles (title + paragraphs) and gets all the questions and answers from the JSON structure.
The output is a dataset with `features: ['answers', 'context', 'id', 'question', 'title']`
Let me know if that helps !
| [
0.2765028477,
-0.3245532811,
-0.0041768397,
0.503570497,
0.491323024,
0.1213673949,
0.123728402,
0.4133349955,
-0.0751962215,
-0.0259798802,
-0.1301123351,
0.3398238719,
-0.0528954938,
0.1487220079,
-0.1727153063,
-0.0546034798,
0.1016581357,
-0.0482199714,
-0.0415603146,
0.0072895023,
-0.2067221701,
0.3235586286,
-0.10912285,
0.0373792872,
-0.203966558,
-0.1171854064,
-0.054248713,
0.2437567413,
-0.3019741178,
-0.4565348029,
0.1005724967,
-0.0376288705,
0.1664624661,
0.4242762625,
-0.000115848,
0.023682734,
0.1646317989,
-0.230063349,
-0.3505631983,
-0.3331952095,
0.1268618405,
-0.3761895299,
0.4304664433,
-0.2027410865,
-0.1258757114,
-0.1786091477,
-0.096114926,
-0.1968042552,
1.0008980036,
0.3400828242,
0.2102464736,
0.3470051289,
0.138079077,
-0.0819272026,
0.0969262794,
0.2541931868,
-0.0933299214,
0.323096633,
0.2164283842,
0.1647644639,
0.1258270293,
0.175049454,
-0.0443550311,
0.0169816334,
0.2572389543,
0.027770143,
-0.0930705816,
-0.3937783539,
-0.1838333309,
-0.0116598429,
0.3137212396,
-0.1443775594,
-0.5413430333,
-0.501717031,
0.1732726693,
-0.1106100008,
0.2216002941,
0.2464285493,
-0.1395855993,
0.0191116016,
-0.3186028898,
-0.1635537744,
-0.1161367297,
0.0203609578,
0.3762320578,
-0.0576741435,
-0.2415271401,
0.0588289872,
0.1568210274,
-0.1417901069,
-0.1105100811,
0.0353548676,
-0.0728627443,
0.3505921066,
-0.2951961458,
-0.271931231,
-0.1196780726,
-0.371740669,
0.1018879116,
0.2420260608,
0.1651290059,
-0.1785656512,
0.088618733,
0.1241168305,
0.4416556954,
0.2034079731,
0.1819426417,
0.0245944858,
0.0192096513,
0.4390806556,
-0.0542684421,
-0.1794511974,
-0.1601687074,
-0.0393954106,
-0.1938006431,
-0.0268855151,
0.1438040733,
-0.2174711227,
-0.1716738343,
0.2964206934,
-0.3927242756,
-0.1637424082,
-0.0833180994,
0.2997614443,
-0.2172036916,
0.2244902849,
0.1771828085,
0.3254438043,
-0.1757526249,
-0.0753755346,
-0.0627597347,
0.0800187439,
-0.1160257235,
0.1105471179,
0.3034595847,
-0.0264821891,
0.3090909123,
0.0536962412,
0.1259761006,
-0.463583529,
-0.0287315566,
-0.1711115837,
-0.155034855,
0.0838224292,
0.2033518404,
0.0537912138,
0.1703592241,
-0.2115065455,
-0.1047288701,
-0.0145347621,
-0.3091163337,
-0.1507850736,
0.0517887659,
0.1621658206,
-0.2003724575,
0.0260237511,
-0.526003778,
0.1792666316,
0.0211692117,
-0.0483963825,
0.0394394808,
-0.04629853,
-0.0367954858,
-0.193650499,
0.2110573053,
0.3823007047,
-0.2816328108,
-0.2164601833,
0.2524063587,
-0.2160269767,
-0.1254363209,
0.4440965652,
0.0330646634,
0.3277862966,
-0.2648508251,
0.0872756094,
0.0183770657,
-0.4131516814,
-0.0350493528,
0.1448047757,
-0.0338213742,
0.201466307,
0.0676670894,
-0.1952915937,
0.0580911301,
0.1379051805,
0.2548838258,
0.2368626595,
0.0818799138,
0.0482613966,
-0.2766849995,
-0.3185341358,
-0.202841565,
0.2648010552,
-0.1877451986,
0.1534410268,
-0.0259631332,
-0.0539905876,
0.2166586816,
-0.1516256779,
0.0617928728,
0.4533104002,
0.168512091,
0.2387801111,
-0.0217907317,
-0.0480427556,
-0.7455336452,
0.0684665665,
-0.0689237937,
0.1211681738,
-0.0239553154,
-0.1425930411,
-0.2511227131,
-0.1089350954,
-0.0805370733,
-0.1743043959,
0.1121965051,
-0.136313051,
0.2241234034,
0.2155308872,
-0.1689864695,
0.196332559,
-0.0395985283,
0.4472267926,
-0.5573826432,
0.2424889505,
-0.0983355418,
-0.19883807,
0.2147201449,
0.2011444867,
-0.0341328755,
-0.1126388237,
-0.0747611597,
0.1906286329,
0.0068866275,
0.2139624804,
0.1331869364,
-0.1052477732,
0.083883509,
0.1024440378,
-0.1973108202,
0.1743389219,
0.1744318008,
0.0047704056,
-0.1193331257,
0.5076286793,
-0.101006791,
0.1887679696,
0.0628640056,
-0.0756581426,
0.1690588444,
0.0063967914,
-0.1002160311,
-0.1184988618,
0.1551009566,
0.2553533316,
0.0458391495,
-0.0835983455,
-0.3061404228,
-0.2918837667,
0.5586373806,
-0.0590064675,
-0.0678206906,
0.3698512018,
0.0355379768,
0.1182520017,
-0.1043997109,
0.043455869,
0.4589352906,
0.0911522731,
-0.3391878307,
0.1972617358,
0.1484522521,
-0.1437979788,
0.1024159864,
0.0957408696,
0.4166865051,
0.3183400333,
0.300016135,
0.0597625673,
-0.3067358732,
0.1420870125,
-0.2083358765,
0.2186392844,
-0.4925418198,
0.0445043929,
-0.1151588783,
-0.1068990454,
-0.2028003335,
0.1134911701,
-0.3827403188,
-0.1413225979,
0.1015921608,
0.1646255106,
-0.1746529788,
-0.0745293796,
0.197020933,
0.3646428585,
0.0864870921,
0.1021097377,
-0.15326491,
-0.0959889144,
-0.1803577393,
-0.0108702499,
0.2143461853,
-0.264521569,
0.1915953159,
-0.3866003752,
-0.1071972847,
-0.0969465226,
-0.0862779468,
0.2008053213,
-0.2895600796,
0.5592088699,
-0.0038712083,
0.3736159801,
-0.2889701426,
-0.2385129631,
0.4713876247,
-0.1099328101,
-0.4625408053,
-0.0569936261,
0.1825453937,
0.1231878772,
-0.2012755722,
-0.5368165374,
-0.2449888289,
-0.3387767673,
0.6739482284,
0.1798684895,
0.091633305,
0.1191715822,
0.1584133059,
0.1084539741,
-0.2553289235,
0.2411590666,
-0.2630100846,
-0.5265827179,
0.264023006,
-0.2365656048,
-0.4236216545,
-0.031149175,
0.1406436861,
0.0516552627,
-0.4131503403,
-0.5645362139,
-0.4872906804,
0.1527820081,
-0.1334135085,
-0.23977907,
0.1840976775,
0.1705304086,
-0.1347416937,
-0.0131086931,
-0.0866543725,
-0.3071376383,
0.1541537791,
0.0357810408,
0.1699274927,
-0.1635738462,
0.6400694251,
-0.0140810059,
0.6470271945,
0.4268471897,
0.1050798446,
0.3005033135,
0.0220349915,
0.181221664,
-0.101510331,
-0.2334782034,
0.1251758188,
-0.3126174808,
0.0619451664,
0.2309833318,
0.175950408,
0.1368626803,
-0.218209058,
0.298258245,
-0.62665236,
-0.2740622461,
0.0167289767,
0.010467723,
0.0125339767,
0.0110400198,
0.0991448164,
-0.0016228112,
-0.0261733439,
-0.1088835597,
0.1585472226,
0.3288145661,
0.0343796127,
-0.5321623087,
-0.2200602889,
-0.243530035,
0.3540108502,
0.0739004388,
0.174432233,
-0.0215259604,
-0.0480258167,
0.224731341,
-0.070734933,
0.743400991,
0.1604297012,
-0.2463180423,
0.1011383981,
-0.0428366065,
-0.5279509425,
-0.0795992464,
-0.2327032089,
0.0449064523,
0.4115918875,
0.7351170182,
-0.4760126173,
-0.1883804947,
-0.0302230399,
0.0166337397,
-0.0812445134,
-0.100735873,
-0.2711491883,
-0.2549725473,
-0.6155122519,
0.1558487862,
0.0587849617,
0.2476944178,
-0.1452713758,
0.0048150173,
0.3155400455,
0.0463934354,
0.1001556963,
0.1843170971,
0.3522069752,
-0.0061875684,
0.2355441004,
0.3182715476,
0.1162930131,
0.2940475047,
0.7196810246,
0.116302833,
-0.2087450922,
-0.0571079813,
-0.0556137301,
0.3012185395,
0.3266745508,
0.07960096,
0.152179569,
0.0119932108,
0.3889198899,
-0.2978375852,
-0.1634100825,
0.6246681213,
-0.0736446977,
-0.0642019436,
-0.1872619838,
0.2811225951,
-0.0760675147,
0.1752185374,
-0.178733021,
0.080163762,
-0.1165285558,
0.3041051924,
-0.0480261184,
0.9530205131,
-0.0319699794,
0.2836970985,
0.3950023353,
-0.2479311526,
0.646124959,
-0.3499979675,
0.1775383949,
-0.3617726266,
0.1908336729,
0.1125159338,
-0.1214262098,
0.0549641177,
0.3301793337,
-0.1295477301,
0.1566776633,
-0.0767455325,
0.137094602,
-0.1382614076,
0.1903380454,
-0.2455642968,
-0.1657315195,
-0.618519187,
0.1025465652,
-0.1827121526,
0.1572474092,
-0.0923991576,
-0.1473573446,
-0.1551729292,
-0.3246771395,
-0.2407863736,
0.090394184,
-0.0665243417,
0.0758737922,
0.5519697666,
-0.2031155527,
0.1340702027,
0.2271727622,
0.0512005351,
0.2068567276,
-0.2352698594,
0.0311673637,
-0.1107930019,
-0.061625421,
-0.1121147722,
0.1132813394,
0.2415937036,
-0.1052269191,
-0.2029152215,
-0.0267034974,
-0.1529228985,
-0.255681783,
-0.1547581702,
0.0644759983,
-0.2566594779,
-0.4200190902,
-0.3319712281,
-0.1307718009,
0.0820602104,
-0.1662510931,
0.1344934106,
0.0810698941,
-0.1708879918,
0.1585079432,
0.2699715197,
-0.1156447083,
-0.1344988644,
0.5229884982,
-0.1111160889,
-0.1896015406,
0.6493116617,
0.4368522167,
-0.148358345,
-0.2378160655,
0.183817789,
0.1316276938,
-0.3388342857,
0.2567910254,
0.0973398983,
0.0051158252,
-0.1717458814,
0.115957737,
0.2222601175,
-0.2517636418,
0.3650594354,
-0.5673502684,
-0.3173675537,
0.443066597,
0.004531798,
-0.0631770715,
0.266823262,
0.1002568007,
-0.0338654406,
0.0832183659,
-0.272690773,
0.3007260263,
-0.3953948915,
0.0873906761,
0.0767683089,
-0.3047947884,
0.1863957793,
-0.1311238706,
0.08259397,
0.1605726331,
-0.2654210627,
-0.1715358347,
-0.1408917308,
0.1307606995,
0.0404507294,
-0.0404696539,
-0.0490467213,
0.0058026672,
-0.1521515846,
-0.1141717732,
-0.054956004,
0.1796036512,
0.1634298861,
0.1441388577,
0.0366873033,
0.1671602428,
0.1167046949,
-0.0782699957,
0.1362466663,
0.3435165286,
0.1033021957,
-0.0854399502,
-0.130088225,
0.0933182836,
-0.2415096462,
0.1696250439,
0.2493784428,
0.2326853126,
0.2996265888,
-0.3759667575,
0.1209995374,
0.0201388411,
0.309032023,
0.5209898949,
-0.3481749892,
0.2346975952,
0.0985876694,
0.1765886098,
-0.1556179225,
-0.0319513306,
0.3002459109,
-0.0750005543,
-0.2783229947,
0.2002016753,
-0.007398258,
0.1740996987,
0.086742878,
0.1911621243,
0.3895730376,
0.2434380502,
0.1822115928,
-0.0444995575,
-0.08327353,
-0.1289105266,
0.0936416984,
-0.1966638267,
0.1491061151,
-0.0261315722,
-0.0243433695,
-0.0458149686,
-0.2057256997,
0.3366066217,
-0.0207267702,
-0.2763654292,
-0.038359046,
0.1824206114,
0.1114759967,
0.1511596739,
-0.1772987992,
0.7104713321,
-0.1619060785,
-0.2514784336,
-0.2890086472,
0.2225731611,
-0.173623547,
-0.1278699338,
-0.134241581,
-0.2135271132,
-0.2012905031,
0.047111351,
-0.15831846,
-0.2291679531,
-0.0572525859,
0.0272274259,
-0.1408021152,
-0.2991466522,
-0.034090098,
0.1111767218,
0.3122478724,
-0.1557559371,
0.327848196,
0.1607192904,
0.0592375882,
0.1917221397,
0.4259861708,
0.3981618583,
0.2758071721,
-0.1555978209,
0.0373859555,
-0.215823859,
0.0209565908,
0.0811455995,
0.4270626903,
0.3053335845,
-0.0823899284,
0.2137798518,
0.1807217896,
-0.2147716135,
0.0002967252,
-0.1091972068,
0.1812512577,
-0.3129344285,
0.2085234821,
-0.2418721616,
-0.0866298452,
-0.1583322734,
-0.2290730774,
-0.5892874599,
0.2352297455,
0.0119448509,
0.1732791811,
0.0938077569,
-0.1813001186,
0.0752604082,
-0.0405870155,
0.5046569109,
0.4481284916,
-0.0792009085,
-0.236460641,
-0.0960720479,
-0.4669958055,
0.0528027155,
0.0771681443,
0.2201441377,
0.0857025757,
0.1303309053,
0.0565074831,
0.2685347795,
0.0522004217,
-0.138844654,
-0.3160133362,
0.0327815264,
-0.5403757095,
-0.1778922975,
-0.0178362429,
0.0589336343,
0.2315602601,
-0.007174978,
0.0853201747,
-0.0924973488,
-0.071291618,
0.0786533281,
0.0388262533,
-0.2220262736,
-0.0980626568,
0.2836254835,
0.1303463429,
0.3286895454,
-0.0526457652,
-0.4227827191,
-0.1128480211,
-0.453569442,
-0.0473563634,
0.324644357,
-0.1320025772,
0.6502724886,
-0.2625967264,
-0.0624933578,
-0.3085170388,
0.0252176486,
-0.1310903132,
-0.2969697714,
-0.2991312444,
-0.0061599202,
0.023059696,
0.199086085,
0.0862930492,
0.426420182,
-0.1701639742,
0.3555662334,
-0.4462171197,
-0.2260020822,
0.6370903254,
-0.3044462204,
-0.1028779224,
0.254001379,
0.1443258673,
0.1098193526,
-0.3229671121,
-0.6543385386,
0.0933880135,
0.3220583797,
-0.0832753405,
-0.1749875546,
0.1773537248,
-0.3135725558,
-0.2960959375,
0.0071627977,
0.1035661846,
0.118948251,
-0.0599967986,
0.1571033746,
-0.1968136579
] |
https://github.com/huggingface/datasets/issues/3333 | load JSON files, get the errors | Yes, this works. But how to get the training output during training the squad by **Trainer**
for example https://github.com/huggingface/transformers/blob/master/examples/pytorch/question-answering/trainer_qa.py
I want the training inputs, labels, outputs for every epoch and step to produce the training dynamic graph | Hi, does this bug be fixed? when I load JSON files, I get the same errors by the command
`!python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/`
change the dateset to load json by refering to https://huggingface.co/docs/datasets/loading.html
`dataset = datasets.load_dataset('json', data_files=args.dataset)`
Errors:
`Downloading and preparing dataset json/default (download: Unknown size, generated: Unknown size, post-processed: Unknown size, total: Unknown size) to /root/.cache/huggingface/datasets/json/default-c1e124ad488911b8/0.0.0/45636811569ec4a6630521c18235dfbbab83b7ab572e3393c5ba68ccabe98264...
`
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/730#issuecomment-981095050_ | 37 | load JSON files, get the errors
Hi, does this bug be fixed? when I load JSON files, I get the same errors by the command
`!python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/`
change the dateset to load json by refering to https://huggingface.co/docs/datasets/loading.html
`dataset = datasets.load_dataset('json', data_files=args.dataset)`
Errors:
`Downloading and preparing dataset json/default (download: Unknown size, generated: Unknown size, post-processed: Unknown size, total: Unknown size) to /root/.cache/huggingface/datasets/json/default-c1e124ad488911b8/0.0.0/45636811569ec4a6630521c18235dfbbab83b7ab572e3393c5ba68ccabe98264...
`
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/730#issuecomment-981095050_
Yes, this works. But how to get the training output during training the squad by **Trainer**
for example https://github.com/huggingface/transformers/blob/master/examples/pytorch/question-answering/trainer_qa.py
I want the training inputs, labels, outputs for every epoch and step to produce the training dynamic graph | [
0.163686946,
-0.5511723757,
0.0138233257,
0.5805276036,
0.5453881025,
0.0155081423,
0.1837683618,
0.3460627198,
-0.1402783394,
-0.0444165915,
-0.1037509963,
0.4005067945,
-0.0872832015,
0.3356801867,
-0.0048746583,
-0.1373547316,
-0.0322655141,
0.0883197039,
-0.2120637745,
-0.0435362309,
-0.0784141198,
0.3408167958,
-0.0657851622,
0.2159003615,
-0.3866488636,
-0.0749016851,
0.0160652697,
0.0193892214,
-0.2331289649,
-0.4273640215,
0.1822328568,
-0.1904927194,
0.22771056,
0.3537913561,
-0.0001214562,
0.181578055,
0.1696082205,
-0.2737131715,
-0.423627317,
-0.3394162655,
0.0149785569,
-0.2824375629,
0.4665516913,
-0.1831332445,
-0.1698014885,
-0.1088883355,
-0.0712161884,
-0.1378268301,
0.9953348041,
0.2467191815,
0.1447521746,
0.4332351983,
-0.1022328287,
-0.0538502038,
-0.0200032499,
0.4325115681,
-0.0042134449,
0.4011106193,
0.2766083181,
0.1857428998,
0.0921221897,
0.157747224,
0.2049372941,
-0.0969198719,
0.2966969907,
0.0850411132,
-0.0399082936,
-0.2561959326,
-0.0860438794,
0.0621354468,
0.3645497561,
-0.1956050992,
-0.6179219484,
-0.5118346214,
0.2931276262,
-0.2330159843,
0.2232118398,
0.29634884,
-0.1467442662,
-0.0116621954,
-0.4289112687,
-0.0551827215,
-0.2553482652,
-0.0105776777,
0.3951702416,
-0.1006113738,
-0.2855523527,
0.0074420567,
0.0503956489,
0.0152526442,
-0.1069204509,
0.2221347094,
-0.155901745,
0.338301003,
-0.2395807505,
-0.2506219745,
-0.2232428938,
-0.4823243618,
0.031642653,
0.1609173715,
0.1620075107,
-0.2096847296,
0.0228483174,
0.1549596488,
0.3680734932,
0.3324817717,
0.1612846851,
0.1982011497,
-0.0182245299,
0.4383017123,
-0.1205410287,
-0.1782143414,
-0.1792850345,
0.0185287781,
-0.0369252115,
0.0477473401,
-0.0190947559,
-0.1795269549,
-0.077494666,
0.0609938763,
-0.4027307928,
-0.206897378,
0.0330586024,
0.334228456,
-0.2777158916,
0.1090011448,
0.1962231547,
0.258677274,
-0.0926334038,
-0.1126774028,
-0.0327680707,
0.0419432037,
-0.276853025,
0.1217758134,
0.2523881495,
-0.0295944642,
0.4130054712,
-0.003239787,
0.1995082349,
-0.5130032301,
0.0108765615,
-0.0379753932,
0.0250342935,
0.1041555107,
0.0657615066,
-0.1694670022,
0.0324693806,
-0.1195275337,
-0.1300617307,
-0.0932945609,
-0.2749899924,
-0.2965888977,
-0.0377993137,
0.1096788421,
-0.1234786659,
0.1525319666,
-0.5942759514,
0.0849406272,
-0.0305689201,
-0.0276476797,
0.1082996055,
-0.0998896733,
0.0504889302,
-0.1010692343,
0.3797975183,
0.3399542272,
-0.2790544629,
-0.5189010501,
0.4864041507,
-0.2972992063,
-0.1337173432,
0.3298203945,
-0.1263602078,
0.4571653605,
-0.3179573417,
-0.0723779351,
0.2749305964,
-0.4058858454,
0.0231480394,
0.1057103649,
-0.0259383153,
0.0811941996,
0.2001481503,
-0.1397450715,
0.145031333,
0.2414657325,
0.2133339942,
0.2179440111,
0.0645202249,
-0.0375547297,
-0.1040745601,
-0.3301295042,
-0.2853244245,
0.2621781528,
-0.1091357991,
0.2208842486,
0.0041821869,
0.0738994032,
0.2792877555,
-0.1829613596,
0.0873226225,
0.3323088288,
-0.002860972,
0.2184588164,
-0.0164183322,
0.0409830622,
-0.7167809606,
0.1077467352,
-0.3189303875,
-0.013390895,
-0.06206543,
-0.1783909649,
-0.0774954036,
-0.0896683782,
-0.1359357536,
-0.1950786859,
0.012871433,
0.0002349828,
0.4143770635,
0.1440630853,
-0.2236946076,
0.279014796,
-0.2901725173,
0.2560233474,
-0.6140158772,
0.2614719868,
0.0539311692,
-0.1541178524,
0.1246305406,
0.2394160479,
-0.0194176901,
-0.181813553,
-0.1298755109,
0.1217082813,
0.0132020637,
0.2702403367,
0.0339034013,
-0.0618830435,
0.1169376299,
0.1872707456,
-0.1596768498,
-0.003973539,
0.0233438704,
-0.073323071,
0.0556841865,
0.4446071982,
-0.0728015006,
0.1837991625,
0.1037342623,
-0.1126606092,
0.0906701759,
0.1267680526,
-0.3286930919,
-0.0811035112,
0.1002115607,
0.1586807519,
0.1836834252,
-0.1704502702,
-0.4569679797,
-0.3868115246,
0.6421716809,
-0.1619443297,
-0.1573619395,
0.346047163,
-0.0100867189,
0.1197531298,
-0.0686173439,
0.1186649129,
0.3632771373,
0.0395904519,
-0.2718096673,
0.1451487094,
0.1324160695,
-0.1334784031,
0.1245175377,
0.0942168385,
0.4557117224,
0.2681281865,
0.1112350449,
0.0002304479,
-0.2283171266,
-0.0366319008,
-0.1264467537,
0.1129835173,
-0.4793060422,
0.165419057,
-0.0006628117,
-0.1219561696,
-0.2450583428,
0.0580630712,
-0.1922249347,
-0.0659724846,
-0.0722730234,
0.1515492201,
-0.0727948248,
-0.0135538848,
0.1813315302,
0.3344585001,
0.0216826536,
0.0280092973,
-0.1873616576,
-0.0256396234,
-0.267427057,
-0.07287772,
0.0704697147,
-0.3500688076,
0.1615644544,
-0.4621557593,
-0.1528128386,
-0.0528873801,
-0.0716813877,
0.2898320556,
-0.1096310019,
0.3271863759,
0.1288942844,
0.2515937686,
-0.3873898983,
-0.1634925902,
0.3807104826,
-0.0979524329,
-0.5009233356,
-0.1924827248,
0.0161121283,
0.2765608728,
-0.1665627658,
-0.4025957882,
-0.4009648561,
-0.2580576241,
0.7676857114,
0.025274124,
0.0870426148,
0.3073763847,
0.1251287311,
0.2890153527,
-0.3125253022,
0.3152788877,
-0.2609531283,
-0.738049686,
0.2494654953,
-0.2390487641,
-0.2945712209,
0.0000298277,
0.0465881154,
0.2449497133,
-0.3088510633,
-0.6073961854,
-0.5697601438,
0.2936200798,
-0.087556228,
-0.3498702645,
0.1662603915,
0.1067948043,
-0.2254951149,
0.0926649347,
0.0268216562,
-0.1911952645,
0.1900500804,
0.0409538448,
0.0953690037,
-0.1435953528,
0.5655424595,
-0.058300253,
0.7821043134,
0.3943070471,
-0.1291199625,
0.0915575475,
-0.1416793764,
0.2546263933,
-0.160550639,
-0.1398887336,
-0.0556355007,
-0.2983156145,
0.04310669,
0.0679723248,
0.1445896924,
0.195896104,
-0.1773213893,
0.2530802488,
-0.4974467754,
-0.1574530154,
-0.0188684817,
-0.0563591272,
0.0820872709,
-0.1022464931,
0.3245766461,
0.1026444733,
0.0527230091,
0.0427003689,
0.1338955611,
0.3989803493,
0.1588193327,
-0.4072778821,
-0.4444235861,
-0.0853748247,
0.1211698949,
0.1469735354,
0.1881542206,
-0.1232198253,
0.0128768878,
0.2555565536,
0.0676599964,
0.8317309618,
0.2287360579,
-0.0045191189,
0.1719678193,
-0.2570204437,
-0.2843801081,
-0.0751653165,
-0.1393699348,
-0.080839999,
0.4905983806,
0.8783761263,
-0.2641524374,
-0.2049923688,
0.0052386429,
0.0133153796,
-0.1565715969,
-0.042087175,
-0.2597936988,
-0.0859935358,
-0.4670432806,
0.1583226919,
-0.0241188891,
0.1528673321,
-0.07259316,
-0.0162092336,
0.2995471954,
0.1060516089,
-0.1162175909,
0.2957324982,
0.3716205657,
0.0892780125,
0.161787346,
0.52549541,
0.2688026428,
0.1923492998,
0.5247256756,
0.1414263248,
-0.2314034998,
0.0515422113,
0.0640688017,
0.3408684134,
0.2492058873,
0.1113244221,
0.0904632881,
0.0681969151,
0.3083610833,
-0.2559910417,
-0.0815154463,
0.5821503997,
0.05564522,
-0.1193457171,
-0.2664247751,
0.3737547696,
-0.0953347012,
0.2067753971,
-0.0689131171,
-0.0328898653,
-0.2475607395,
0.0398219265,
0.0204170365,
0.8380047679,
0.0567784682,
0.425747335,
0.5931443572,
-0.2961131632,
0.5786540508,
-0.2369558364,
0.1763043255,
-0.344278425,
0.2301274836,
0.086784862,
-0.2028400898,
-0.0723690167,
0.3147169054,
-0.1454660892,
0.1255647838,
-0.0544427708,
0.2352533638,
-0.1415759921,
0.1733841449,
-0.1304538101,
-0.2425499558,
-0.6795152426,
-0.0063215946,
-0.2305289656,
0.2604216635,
-0.101239264,
-0.2489715666,
0.0616178401,
-0.1480778158,
-0.1097159386,
0.1091271862,
-0.1478491575,
0.0311610531,
0.5874516964,
-0.3150258064,
0.1077308655,
0.2895165682,
0.004854254,
0.0262233615,
-0.1746097803,
0.0223345477,
-0.177639991,
0.058716204,
-0.140457496,
0.2310642153,
0.3106840253,
-0.0648305416,
-0.1326166987,
0.0840714946,
-0.1737693101,
-0.1136323437,
-0.133568868,
-0.0181638934,
-0.3121134341,
-0.3105227947,
-0.1317189485,
-0.1090113744,
0.0199525543,
-0.0844011977,
0.0655886382,
0.2124922723,
-0.3887865543,
0.0948619246,
0.3682168722,
-0.2288911045,
-0.1056741253,
0.5123487115,
-0.1088983938,
-0.1292361021,
0.748478055,
0.4016308188,
-0.0158009958,
-0.1422126442,
0.2874464393,
0.1527395397,
-0.3909366727,
0.1759583056,
0.2678562999,
0.1065823212,
-0.1598024964,
0.1311538666,
0.2372778207,
-0.1598068327,
0.2319428474,
-0.3876806498,
-0.5591206551,
0.249422431,
0.0262737554,
-0.0086353691,
0.3118999302,
0.1858780384,
0.0535289124,
0.0092078298,
-0.1895494759,
0.1348069757,
-0.2950351238,
0.0619999766,
0.1069977432,
-0.2577533126,
0.3248670995,
-0.0864987671,
-0.0209988225,
0.0582021698,
-0.267683208,
-0.0809369832,
-0.1266656071,
0.1405168176,
0.0461811163,
0.1471290886,
-0.104451023,
-0.0603686124,
-0.1310263574,
-0.0406734422,
0.0511321165,
0.1881683171,
0.1509443372,
0.2860046625,
-0.1188467443,
0.1997053772,
0.0663426667,
-0.0739734992,
0.1629689038,
0.3708366156,
0.0726258755,
-0.0364638343,
-0.1129422784,
0.0441496223,
-0.5025835037,
0.1810353696,
0.0607921369,
0.2144969404,
0.2749979198,
-0.3346999884,
0.1660024673,
-0.1775316,
0.2422744185,
0.2725015879,
-0.2607171834,
0.0936437473,
0.1343606114,
0.1208787709,
-0.0725203156,
-0.0234723128,
0.1132585183,
-0.1013448909,
-0.2381915748,
0.1833977252,
-0.0495560952,
0.0746710524,
0.093721427,
0.2112489343,
0.2279492766,
0.1004026905,
0.3370745182,
0.208589986,
-0.097538583,
0.0071421373,
0.0625200868,
0.1009302363,
0.0110044871,
-0.1580745131,
-0.0327446833,
0.0526555106,
-0.3899497986,
0.1916087568,
0.0173174068,
-0.3071177602,
-0.3694385886,
0.1535609812,
-0.1026702672,
0.2097996771,
-0.2943535149,
0.7300030589,
-0.227603212,
-0.2705595195,
-0.2460839897,
0.1452881545,
-0.2359758168,
-0.0272671469,
-0.1890137792,
-0.1167749912,
-0.0092138294,
0.1008278728,
-0.0383685939,
-0.1253132671,
0.0096944645,
0.0755296946,
-0.152235359,
-0.034944687,
-0.0673475862,
0.1296603084,
0.3570151329,
-0.1663996875,
0.295707643,
0.0185918696,
0.0614677779,
0.1739597023,
0.2840454578,
0.2618511319,
0.2082511336,
-0.0484082401,
0.0826328993,
-0.0418531895,
0.0528294779,
0.0878415033,
0.3700922132,
0.4053700566,
-0.3378475606,
0.2125355899,
0.1072709784,
-0.0935421959,
0.1343690902,
-0.08052551,
0.1981305033,
-0.2693756223,
0.369666189,
-0.1200878024,
-0.1601029038,
-0.172060892,
-0.0412731916,
-0.6431033015,
0.1722160727,
0.0359217934,
0.3265580535,
0.0600189082,
-0.1129810736,
0.0309389718,
-0.1290939897,
0.5253027678,
0.5115397573,
-0.0922550187,
-0.2206354737,
0.0534997061,
-0.2632261515,
0.0485234745,
0.1703178883,
0.2032615542,
0.0177069176,
0.0692138821,
-0.0150900176,
0.0428284518,
0.2160385549,
-0.1429884732,
-0.1600675881,
-0.058440689,
-0.4277309477,
-0.3538138568,
-0.1710809469,
0.3291657865,
0.1376777738,
0.0010792823,
0.1680967063,
-0.2326072305,
-0.1292226911,
0.1244490817,
0.2546024024,
-0.3065319061,
0.0634742752,
0.2882674634,
-0.0182289816,
0.2648481131,
0.0084703481,
-0.278940022,
-0.0448043458,
-0.4761584103,
0.1152988449,
0.2616071999,
-0.1186475307,
0.5204260349,
-0.3099737465,
-0.0461750031,
-0.4741902947,
-0.1543562114,
-0.0750093982,
-0.3354453444,
-0.2445769757,
-0.0130596431,
-0.0124478424,
0.0879683942,
0.248275578,
0.4933454096,
-0.1350580305,
0.094677642,
-0.4642789662,
-0.084183611,
0.6214460135,
-0.5367509127,
-0.1071176678,
0.2177047431,
0.1412962526,
0.1582473516,
-0.2566117048,
-0.5874668956,
0.2448253334,
0.3897714317,
-0.2024159878,
-0.0822426975,
0.1570065916,
-0.1789923608,
-0.1023439243,
-0.0387194306,
0.1868173033,
0.1108606458,
-0.1001547277,
0.1679992676,
-0.2779204845
] |
https://github.com/huggingface/datasets/issues/3333 | load JSON files, get the errors | I think you may need to implement your own Trainer, from the `QuestionAnsweringTrainer` for example.
This way you can have the flexibility of saving all the inputs/output used at each step | Hi, does this bug be fixed? when I load JSON files, I get the same errors by the command
`!python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/`
change the dateset to load json by refering to https://huggingface.co/docs/datasets/loading.html
`dataset = datasets.load_dataset('json', data_files=args.dataset)`
Errors:
`Downloading and preparing dataset json/default (download: Unknown size, generated: Unknown size, post-processed: Unknown size, total: Unknown size) to /root/.cache/huggingface/datasets/json/default-c1e124ad488911b8/0.0.0/45636811569ec4a6630521c18235dfbbab83b7ab572e3393c5ba68ccabe98264...
`
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/730#issuecomment-981095050_ | 31 | load JSON files, get the errors
Hi, does this bug be fixed? when I load JSON files, I get the same errors by the command
`!python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/`
change the dateset to load json by refering to https://huggingface.co/docs/datasets/loading.html
`dataset = datasets.load_dataset('json', data_files=args.dataset)`
Errors:
`Downloading and preparing dataset json/default (download: Unknown size, generated: Unknown size, post-processed: Unknown size, total: Unknown size) to /root/.cache/huggingface/datasets/json/default-c1e124ad488911b8/0.0.0/45636811569ec4a6630521c18235dfbbab83b7ab572e3393c5ba68ccabe98264...
`
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/730#issuecomment-981095050_
I think you may need to implement your own Trainer, from the `QuestionAnsweringTrainer` for example.
This way you can have the flexibility of saving all the inputs/output used at each step | [
0.1112693399,
-0.3947230875,
0.0247266795,
0.4891625047,
0.5235649943,
0.0685908943,
0.1418220997,
0.4170047343,
0.050956022,
0.0277666785,
-0.0371602811,
0.2889541984,
-0.2010877877,
0.4082460403,
-0.1074439138,
-0.1509508342,
0.0424837321,
0.1274573952,
-0.2073004991,
0.0787480846,
-0.1535555422,
0.2987521291,
0.0079987301,
0.0157946013,
-0.2861706018,
-0.1163588911,
0.0206435658,
0.1426507533,
-0.2493415475,
-0.4953288734,
0.2064926624,
-0.0817670748,
0.2906376421,
0.4381704926,
-0.0001140089,
0.1213438809,
0.2173854858,
-0.236740604,
-0.4340902567,
-0.3380367756,
-0.1292429119,
-0.292935282,
0.4220707417,
-0.1002357006,
-0.1599608809,
-0.0974551812,
-0.0706111789,
-0.0566465668,
0.9737885594,
0.313809365,
0.2417191118,
0.3806008101,
0.0472547151,
-0.1344993562,
0.0463561229,
0.3397572041,
-0.0675403178,
0.4890827239,
0.140189901,
0.2162849605,
0.1372413337,
0.140570581,
0.1628671438,
-0.0756562054,
0.3369667828,
-0.0443943627,
-0.037262477,
-0.3155043125,
-0.1580414325,
0.0994193181,
0.3612465858,
-0.1237344593,
-0.5696434379,
-0.5445700884,
0.2410782278,
-0.2802480459,
0.29995206,
0.1510307491,
-0.0831010491,
-0.0310342871,
-0.3698155582,
-0.1634980589,
-0.1596574187,
0.0137226731,
0.3107428253,
-0.1958818138,
-0.3178329468,
0.0343277641,
0.1845929027,
-0.1384473741,
-0.0885760263,
0.1549933553,
-0.1527045518,
0.2772503793,
-0.2310866863,
-0.248845011,
-0.1680763811,
-0.3051984012,
0.0344781168,
0.1920021474,
0.0658600852,
-0.1832508296,
0.0301988516,
0.0876914114,
0.3901365101,
0.4024858177,
-0.0058094133,
0.0245383345,
0.0436935723,
0.4756873548,
-0.0620948635,
-0.1859447062,
-0.1321344525,
-0.1020847559,
-0.1212423295,
-0.0402433276,
0.0006116466,
-0.2094421685,
-0.1407863498,
0.1252128333,
-0.2952104509,
-0.1797422767,
0.045612298,
0.2827428579,
-0.3114418089,
0.16173926,
0.1454575509,
0.340523988,
-0.1509453952,
-0.0836312398,
-0.0851377621,
-0.0374473855,
-0.2042680979,
0.1064240709,
0.2197379321,
-0.0977958068,
0.3945550323,
-0.0018306137,
0.1681860834,
-0.3759330511,
0.0131622562,
-0.0411354005,
-0.160789147,
0.1360068172,
0.0880337134,
-0.0644875988,
0.0387785621,
-0.1442570388,
-0.115930818,
-0.1377573162,
-0.3558433652,
-0.2305531502,
0.0153523209,
0.1844421774,
-0.1429658383,
0.0989891142,
-0.606356144,
0.1125728637,
-0.0346190855,
-0.0240638275,
0.0614718311,
-0.1473660022,
-0.0121833095,
-0.1890544742,
0.3378267884,
0.2633911073,
-0.1507254839,
-0.3629550934,
0.2698026597,
-0.2522869706,
-0.1143058538,
0.3930956423,
-0.1404330581,
0.4453261197,
-0.3221610785,
0.0198066365,
0.1262172014,
-0.3180973828,
-0.0329829492,
0.0996748284,
-0.0393248536,
0.157623291,
0.0374605879,
-0.1705540568,
0.087593101,
0.0572277494,
0.218862161,
0.2307674736,
0.033388868,
0.0083978977,
-0.25274387,
-0.3746702671,
-0.1956221014,
0.194452256,
-0.1616239399,
0.163029626,
-0.0483219884,
-0.0267105363,
0.1724976152,
-0.2421633899,
0.0542713217,
0.4215505719,
0.0995000973,
0.1931755841,
-0.1181516498,
0.0241059512,
-0.6393853426,
0.1503075063,
-0.1319378614,
-0.026298847,
0.0404380299,
-0.1306868494,
-0.2583485842,
-0.1017686352,
-0.1022325531,
-0.1450546086,
0.0952110291,
-0.0303214546,
0.3669009805,
0.2741232514,
-0.2381112576,
0.29083848,
-0.1309528053,
0.335565716,
-0.5414312482,
0.157889992,
0.0276837032,
-0.1312686056,
0.2576344013,
0.2335923165,
-0.0008011435,
-0.1693962961,
-0.1265757531,
0.2199384421,
-0.0653504208,
0.1718063205,
-0.0055357292,
-0.0469498299,
0.0682794675,
0.2018438131,
-0.2160984129,
0.0874309838,
0.0818208605,
-0.0454027876,
-0.0198064186,
0.5255048871,
-0.0763704404,
0.100080505,
0.0927753597,
-0.1207760349,
0.0670850649,
0.0784140602,
-0.1685929,
-0.1624524891,
0.1375780255,
0.1168840379,
0.098911345,
-0.1006553546,
-0.4091235995,
-0.4027704,
0.5495021939,
-0.0622509271,
-0.1097561345,
0.4458472133,
-0.0054175034,
0.1669325531,
-0.1080567688,
0.2115677297,
0.465670675,
0.0383253396,
-0.2399950773,
0.1940267384,
0.0928830057,
-0.1633369476,
0.0570113957,
-0.0006796471,
0.3799534738,
0.2334213406,
0.2277349383,
-0.0459860265,
-0.3135324717,
0.1105369776,
-0.1193028763,
0.2023750097,
-0.4381196201,
0.0814213678,
-0.1607337147,
-0.1157341823,
-0.2392389476,
0.0753248408,
-0.3798126876,
-0.0818892121,
0.0178928804,
0.2812097073,
-0.110371463,
-0.0334952623,
0.0980316028,
0.2951045632,
-0.0325164609,
0.0820782632,
-0.1111273691,
0.0646070912,
-0.3308163583,
-0.0052525206,
0.1982300282,
-0.3733585477,
0.2822649777,
-0.5003089309,
-0.0820920095,
-0.0285852943,
-0.1098650321,
0.1649471223,
-0.1672261953,
0.4625258148,
0.1636485755,
0.3259756863,
-0.297555685,
-0.1575576365,
0.4046213627,
-0.0387068428,
-0.4468813837,
-0.1739548296,
0.113121219,
0.2645466924,
-0.2008872926,
-0.4114427865,
-0.1932487488,
-0.3115307391,
0.7402426004,
0.0900960639,
0.0310146958,
0.1369761974,
0.2474393547,
0.1774308681,
-0.328471303,
0.243231222,
-0.2326191962,
-0.7112444043,
0.2540414333,
-0.2500847578,
-0.3740944564,
0.0360027626,
0.0750099793,
0.2772985995,
-0.3498451114,
-0.6203474998,
-0.4395764768,
0.1251161098,
-0.0509177186,
-0.2532444894,
0.1953413486,
0.1258715093,
-0.1450636983,
0.0215557851,
0.0108564273,
-0.2534982264,
0.1055740044,
0.0873023197,
0.2464201301,
-0.1551402062,
0.6245077252,
-0.1394655406,
0.6633350253,
0.2958068252,
-0.0927937329,
0.299783498,
-0.0751254633,
0.2868359089,
-0.2451336235,
-0.1252554655,
0.0751408562,
-0.2318371385,
0.0302593261,
0.1251488775,
0.206473127,
0.170482412,
-0.1645903438,
0.1588359326,
-0.3865007162,
-0.2467310876,
0.038553711,
-0.0763895139,
0.0256961957,
-0.0504208207,
0.1780036241,
0.0328493081,
0.016674092,
0.012331387,
0.1644658893,
0.3313747346,
0.1261807978,
-0.4280900955,
-0.3899422586,
-0.2463224232,
0.1962320656,
0.0085403984,
0.2186791301,
-0.0727266818,
-0.0043889247,
0.1802929342,
-0.0286810827,
0.7758820653,
0.0999448672,
-0.2006497234,
0.0670741871,
-0.1612171084,
-0.3714410961,
-0.0779527202,
-0.0546894521,
-0.1079080254,
0.2890191674,
0.7763618827,
-0.3411386609,
-0.228577286,
-0.1260022521,
0.1673667431,
-0.1525286585,
-0.0739659443,
-0.2391163558,
-0.2785341442,
-0.5131508708,
0.1292982548,
0.0221910998,
0.2375430614,
-0.0316394493,
0.1341816336,
0.1015875116,
0.0651499704,
-0.0134429736,
0.2214763612,
0.3617229462,
0.0724028721,
0.2755104601,
0.3984618485,
0.2633375227,
0.3449628651,
0.6400008798,
0.0792868137,
-0.1610259563,
-0.0685554892,
0.0943060815,
0.2982695401,
0.1992663741,
0.0910110623,
0.1228022724,
0.1441931576,
0.387678355,
-0.3301497698,
0.0039922511,
0.5787590146,
-0.0594979636,
-0.1247329265,
-0.2367385924,
0.3246135712,
0.01339796,
0.2085011154,
-0.0415475704,
-0.0045487257,
-0.161076799,
0.1771553904,
0.0006833529,
0.8215143085,
-0.0343378633,
0.3935206532,
0.5248087049,
-0.4211196303,
0.558781147,
-0.2912961543,
0.1645168364,
-0.3350260258,
0.2143214494,
0.1058895364,
-0.1222768798,
-0.0228033066,
0.207139954,
-0.1139045507,
0.1917750686,
-0.0814896375,
0.1694436371,
-0.227413252,
0.1935750544,
-0.174279362,
-0.251360625,
-0.5306381583,
0.1112042814,
-0.142084524,
0.2211715132,
-0.0990285128,
-0.2078653276,
0.109170422,
-0.2384995669,
-0.126789093,
0.0222029369,
-0.1241910011,
-0.0269681439,
0.5230191946,
-0.2016810328,
0.1527902633,
0.1837425679,
0.1138639078,
0.1181698516,
-0.2375080585,
0.0417152867,
-0.1601561457,
0.0405887999,
-0.1914357692,
0.1400212497,
0.2753218114,
-0.1021149158,
-0.1184714437,
0.0017874432,
-0.2042167485,
-0.0936871693,
-0.1915560067,
-0.0260241348,
-0.3386560082,
-0.4239073992,
-0.168924883,
-0.1344012767,
0.1809632033,
-0.1449206918,
0.1603072137,
0.1505442262,
-0.14530164,
0.1350743622,
0.3722400665,
-0.2179074585,
-0.1891683936,
0.5744349957,
-0.0926128551,
-0.1786764413,
0.7045936584,
0.3036358654,
-0.0390926115,
-0.2000051886,
0.1832995713,
0.2084228694,
-0.3732265532,
0.2414480895,
0.1590244025,
0.085777767,
-0.1777412444,
0.1631454378,
0.228304401,
-0.3209555745,
0.398886323,
-0.3366425931,
-0.5672003031,
0.3118487,
0.0852478743,
0.0856675431,
0.1328583211,
0.1202970073,
0.0205093864,
-0.045016218,
-0.2715071738,
0.1980015785,
-0.2929032445,
0.0496143587,
0.0507844687,
-0.1750070602,
0.2862136662,
-0.0596875176,
0.07036715,
0.1425969601,
-0.3150680661,
-0.1614528745,
-0.1621884406,
0.1081857458,
0.0220249146,
0.0328408815,
0.0413244367,
-0.0253761727,
-0.1046107337,
-0.0741079673,
-0.0123722292,
0.1651240885,
0.0939534605,
0.1248949021,
-0.0661665499,
0.1190234497,
0.1412833333,
-0.1164830476,
0.2110874653,
0.3467716277,
0.0547662489,
-0.12477348,
-0.1795785576,
0.0622745752,
-0.363509208,
0.1473478824,
0.1104738116,
0.1243832707,
0.2062910348,
-0.3962332308,
0.1048112735,
-0.0413154922,
0.2939444482,
0.3566551208,
-0.3575461507,
0.1454623491,
0.3468077183,
0.1739506871,
-0.0789156705,
0.0037140865,
0.1300908327,
-0.0194525905,
-0.2476770878,
0.2177491188,
0.000869279,
0.034827888,
-0.0102902884,
0.152595669,
0.0951138288,
0.1144936234,
0.2788360417,
0.1627915651,
-0.1987014562,
-0.1202581003,
0.1484648287,
-0.038335219,
0.1228297129,
0.053342279,
-0.0712984875,
0.045777075,
-0.2822198868,
0.2048921585,
-0.0853305981,
-0.3849215508,
-0.1930139363,
0.1659357995,
0.0327340998,
0.1366244853,
-0.169305563,
0.6250785589,
-0.1758904159,
-0.3372444808,
-0.2882419229,
0.172915116,
-0.2714415193,
-0.1597290635,
-0.1728616208,
-0.156611979,
-0.1234981939,
0.1654047966,
-0.1766019166,
-0.1719816774,
0.0494492315,
0.0483969487,
-0.1751833856,
-0.2874232233,
-0.1029758155,
0.1546610892,
0.3266077042,
-0.1194645911,
0.35796839,
0.1004981101,
-0.1103878319,
0.2040129006,
0.3315289617,
0.3669160903,
0.2588505447,
-0.0660696253,
0.0276593659,
-0.1157473922,
0.1394953281,
0.0271691512,
0.3889487386,
0.3722973466,
-0.0462669507,
0.3105042875,
0.1723852158,
-0.171669215,
0.1898117065,
-0.2260965556,
0.2418214381,
-0.3533913791,
0.2895663679,
-0.1374622583,
0.0694748014,
-0.2016350031,
-0.0796278939,
-0.5977993608,
0.181131348,
0.1218063533,
0.2856588364,
0.1404466629,
-0.1695675701,
0.0770327002,
-0.1126045659,
0.5716264844,
0.4575899839,
-0.166117385,
-0.237224251,
-0.0475903526,
-0.3407191038,
-0.0254241526,
-0.0516938306,
0.2477786988,
0.012769796,
0.013174396,
-0.0288942512,
0.0701338276,
0.195214808,
-0.093858391,
-0.194445014,
-0.0284850877,
-0.3636623919,
-0.2822248638,
-0.2471252978,
0.2038449049,
0.2504534721,
-0.0087801525,
0.1319518089,
-0.1943190545,
-0.0189350005,
0.0741246492,
0.2399551719,
-0.3028300405,
-0.0227473564,
0.4017783701,
0.0542163625,
0.1697157919,
-0.014727585,
-0.3620136976,
-0.1201949194,
-0.3835535347,
-0.0615179352,
0.2616623342,
-0.1411062926,
0.5869699121,
-0.3236883879,
0.0661180764,
-0.4810353518,
-0.0513420291,
-0.018345328,
-0.2321295142,
-0.184971869,
0.0674824268,
0.0785593316,
0.104326047,
0.312553674,
0.4679713249,
-0.1592958122,
0.1739435196,
-0.4369015992,
-0.1731126904,
0.6441699862,
-0.3494901657,
-0.0827798396,
0.2693640292,
0.1103199348,
0.1325227171,
-0.3077666163,
-0.72827214,
0.2447896302,
0.3348854482,
-0.1408524215,
-0.1310265958,
0.2466067821,
-0.2331882566,
-0.2066578865,
0.0487323701,
0.3509528041,
0.0446286052,
-0.1266274452,
0.2435969561,
-0.1781103015
] |
https://github.com/huggingface/datasets/issues/3333 | load JSON files, get the errors | > does there have any function to be overwritten to do this?
ok, I overwrote the compute_loss, thank you. | Hi, does this bug be fixed? when I load JSON files, I get the same errors by the command
`!python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/`
change the dateset to load json by refering to https://huggingface.co/docs/datasets/loading.html
`dataset = datasets.load_dataset('json', data_files=args.dataset)`
Errors:
`Downloading and preparing dataset json/default (download: Unknown size, generated: Unknown size, post-processed: Unknown size, total: Unknown size) to /root/.cache/huggingface/datasets/json/default-c1e124ad488911b8/0.0.0/45636811569ec4a6630521c18235dfbbab83b7ab572e3393c5ba68ccabe98264...
`
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/730#issuecomment-981095050_ | 19 | load JSON files, get the errors
Hi, does this bug be fixed? when I load JSON files, I get the same errors by the command
`!python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/`
change the dateset to load json by refering to https://huggingface.co/docs/datasets/loading.html
`dataset = datasets.load_dataset('json', data_files=args.dataset)`
Errors:
`Downloading and preparing dataset json/default (download: Unknown size, generated: Unknown size, post-processed: Unknown size, total: Unknown size) to /root/.cache/huggingface/datasets/json/default-c1e124ad488911b8/0.0.0/45636811569ec4a6630521c18235dfbbab83b7ab572e3393c5ba68ccabe98264...
`
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/730#issuecomment-981095050_
> does there have any function to be overwritten to do this?
ok, I overwrote the compute_loss, thank you. | [
0.081510745,
-0.3851127923,
-0.0033681933,
0.5282001495,
0.4719850421,
0.068586424,
0.0534329824,
0.3249766231,
0.1042508632,
-0.0913522989,
-0.0549960695,
0.2146299928,
-0.0638782531,
0.3335618079,
-0.1426368058,
-0.1661891937,
0.1353709847,
0.0852735117,
-0.1390956789,
0.032793276,
-0.2544143498,
0.3445379734,
-0.0886776298,
0.0139050772,
-0.1697129756,
-0.157609731,
0.0579530783,
0.189586401,
-0.3181059361,
-0.5252271891,
0.2614777684,
-0.1253006905,
0.2751364708,
0.403514266,
-0.0001189909,
0.10297025,
0.2764681578,
-0.2563678026,
-0.3061411977,
-0.256425947,
-0.1659698784,
-0.3197919428,
0.3621697426,
-0.1538837701,
-0.0046013216,
-0.2374948114,
-0.0991265625,
-0.1814702004,
0.9331389666,
0.3268533945,
0.1891917288,
0.3957658708,
0.1144272014,
-0.1014890894,
0.1067219973,
0.309815377,
-0.0428241566,
0.601036489,
0.0418397449,
0.1507997513,
0.1916324496,
0.1488132626,
0.1326558888,
-0.0158125479,
0.3911009133,
-0.0250444897,
-0.0712356642,
-0.2651064396,
-0.2939336896,
0.110525012,
0.3862320185,
-0.19405514,
-0.6282969713,
-0.4510046244,
0.1856747717,
-0.4028355479,
0.3375015259,
0.1678339541,
-0.0935890004,
-0.0623689368,
-0.349032104,
-0.1916537434,
-0.1163636297,
0.0280557349,
0.3780634105,
-0.1326920539,
-0.2840744555,
0.0458696149,
0.2118036151,
-0.1245929971,
-0.1790703684,
0.1955015957,
-0.2361700535,
0.2319699079,
-0.2474391907,
-0.18527174,
-0.2407612503,
-0.2753387988,
0.042159386,
0.1925021112,
0.0940272063,
-0.1818364263,
-0.0823090151,
0.1585897505,
0.3452524543,
0.4016543329,
-0.0060672164,
-0.0667778477,
0.0953677744,
0.5004612803,
-0.0045945845,
-0.2279393226,
-0.0114187365,
-0.1728969216,
-0.1625815183,
-0.0523584485,
0.0447969548,
-0.2103932947,
-0.2214603871,
0.0671897233,
-0.2621154785,
-0.2439331412,
-0.0079633119,
0.2383316755,
-0.2687319219,
0.1308760643,
0.2595641017,
0.3389330804,
-0.2051235735,
-0.0985279381,
-0.0696199164,
0.0056667104,
-0.1862442791,
0.1244392842,
0.1970195472,
0.0095495274,
0.3680538237,
-0.0101779494,
0.1319336295,
-0.3380236924,
0.0026698534,
-0.0390201919,
-0.1869773269,
0.1893361807,
-0.0753840581,
-0.0686884001,
0.1103457287,
-0.1576670259,
-0.1184557825,
-0.1389156729,
-0.3716672361,
-0.2018669546,
-0.0052352566,
0.1412646472,
-0.1360029131,
0.1149919778,
-0.6647447348,
0.0902223513,
-0.0484751351,
-0.1550231129,
0.0744195208,
-0.1414829344,
-0.093465969,
-0.1760891229,
0.3488271832,
0.3373163939,
-0.2466781884,
-0.39916116,
0.2335599214,
-0.2829957008,
0.020380659,
0.4823093712,
-0.0682214275,
0.3412549496,
-0.3668684661,
-0.0523322597,
0.1503230929,
-0.289457947,
-0.1069347486,
0.0522852764,
0.0113375811,
0.1207270995,
0.0726617724,
-0.1980824023,
-0.0639796108,
0.0795122609,
0.2676845193,
0.1009565815,
0.0686297566,
-0.0445028059,
-0.3383387923,
-0.3744316101,
-0.0976615921,
0.1635708064,
-0.2251801044,
0.2285778224,
0.0223913249,
-0.0699910894,
0.2082211822,
-0.1502608359,
0.0128797609,
0.4201382101,
0.1454185843,
0.040326979,
-0.0470445864,
0.0478820615,
-0.7126312852,
0.1205747724,
-0.2050233185,
0.0226244442,
0.0416320264,
-0.1089428067,
-0.2674765885,
-0.0955231935,
0.0063595497,
-0.0513180606,
0.0416354388,
-0.0330024101,
0.3359563649,
0.3123080134,
-0.2454069704,
0.2139022797,
-0.1700246781,
0.3526008725,
-0.521060586,
0.1758122295,
0.0569435693,
-0.1561981887,
0.1790101975,
0.1453889161,
0.0613236688,
-0.1435940862,
-0.1849977076,
0.2256604284,
-0.0623874106,
0.2801207006,
0.0218439847,
0.0008464792,
0.1380520463,
0.1400416791,
-0.1709460616,
0.1188801825,
0.0921264812,
-0.0821865052,
-0.0376461744,
0.4579936862,
-0.1763323694,
0.0831286013,
0.0901161134,
-0.1408577114,
0.1441387981,
0.0919499323,
-0.1875925809,
-0.1422730237,
0.1741371155,
0.1207565442,
0.0467612967,
-0.0530440994,
-0.3467596173,
-0.4706705213,
0.5727599859,
-0.0565964468,
-0.0813037008,
0.4223537147,
-0.0327578299,
0.0782271922,
-0.0316272378,
0.2191238403,
0.5283241272,
-0.0227326136,
-0.2587020695,
0.227575466,
0.1293734312,
-0.1822179556,
0.0481141843,
0.0408614352,
0.4017908573,
0.2405885756,
0.2302874923,
-0.044436805,
-0.3656554818,
0.0925274566,
-0.0660871267,
0.2045456171,
-0.530713439,
0.0837865099,
-0.1227015108,
-0.1303823739,
-0.235947594,
0.1148535758,
-0.4097821414,
-0.1618315428,
-0.0387159698,
0.2947399318,
-0.192437157,
-0.0186649598,
0.1006589234,
0.3383846581,
-0.0263523739,
0.0937045738,
-0.2746062875,
0.0553267486,
-0.3184815347,
-0.0438078307,
0.1332924068,
-0.3197989762,
0.1737985313,
-0.5357195735,
-0.1540904045,
0.0140068866,
-0.1190656573,
0.1248663142,
-0.0569649264,
0.5266490579,
0.1695621759,
0.3168803453,
-0.3487108946,
-0.1526944637,
0.4511870146,
-0.027228998,
-0.3706931174,
-0.1629492193,
0.0641994253,
0.3350776434,
-0.1933663636,
-0.4463436604,
-0.2355520725,
-0.3437547982,
0.796739459,
0.1176362485,
0.024135422,
0.1712928861,
0.1302338988,
0.0810916126,
-0.2753814161,
0.2693113387,
-0.2472350448,
-0.7731405497,
0.2217736393,
-0.1975828409,
-0.3153228164,
-0.0018348105,
0.1121477857,
0.2743994594,
-0.2884966135,
-0.6243687868,
-0.3899910152,
0.1217110381,
-0.0982479677,
-0.25659585,
0.1559388638,
0.0720928535,
-0.098655954,
0.0304497015,
-0.0180851556,
-0.265237838,
0.1116954461,
0.0686238036,
0.2659153938,
-0.0159346126,
0.6574980021,
-0.1699450612,
0.6400874257,
0.3261754811,
-0.0681585148,
0.4542732537,
-0.0662715957,
0.3172606826,
-0.1267100424,
-0.1092664823,
0.0392791033,
-0.2017263025,
0.0872569829,
-0.025656106,
0.1173822209,
0.1358108371,
-0.1729989201,
0.1025632247,
-0.4334982038,
-0.1841091961,
-0.0659706965,
-0.0121378778,
-0.0080285035,
0.0237761997,
0.1521562636,
0.0217133369,
0.0004194049,
0.0468550958,
0.2196790129,
0.395485729,
0.0834828764,
-0.4634079337,
-0.3110143244,
-0.3208113015,
0.218456313,
-0.0267485287,
0.3374694288,
-0.0114428708,
0.0332126133,
0.1101664081,
0.0182872098,
0.7727496624,
0.0533475503,
-0.1842333674,
0.1966051459,
-0.0526855104,
-0.4224468172,
-0.0628428608,
-0.0746388882,
-0.0719757676,
0.4105489254,
0.7462793589,
-0.308113873,
-0.2027797699,
-0.1137565076,
0.1526914239,
-0.1205298156,
-0.0700461417,
-0.3031401634,
-0.2522029877,
-0.4738824368,
0.1056588441,
-0.0164695159,
0.2358351052,
-0.0305987038,
0.133172527,
0.1068989486,
0.0804356188,
-0.0270131715,
0.1508330256,
0.4341317415,
0.0087533761,
0.2655788362,
0.3517333567,
0.216141656,
0.3843697011,
0.6933527589,
0.0620145798,
-0.2580074072,
-0.1021145731,
0.2100287974,
0.2487500757,
0.1203949302,
0.0839679837,
0.0690804422,
0.2123936862,
0.396176815,
-0.4539839029,
-0.0595486574,
0.5700047612,
-0.0490390845,
-0.1137561053,
-0.1749341637,
0.3970417678,
0.0366446413,
0.1076464206,
0.0162902735,
0.037803553,
-0.1846018434,
0.1561079174,
0.0297020897,
0.8459640741,
-0.0365314111,
0.3007990122,
0.4472215176,
-0.3312954009,
0.6608042717,
-0.3281382322,
0.1910329163,
-0.2878992856,
0.0323076844,
0.0925717726,
-0.1926682293,
0.0153418686,
0.1955812424,
-0.0450956821,
0.3049652576,
-0.0461741723,
0.1106823459,
-0.1904212981,
0.1738717556,
-0.1792833656,
-0.2191638201,
-0.5036196709,
0.0481455959,
-0.0777967721,
0.3003490865,
-0.1300290376,
-0.1272272319,
0.191509068,
-0.2379726917,
-0.2027592659,
0.0300657451,
-0.0853032693,
0.0226040147,
0.4470848441,
-0.1815255582,
0.1709267199,
0.1935528517,
0.1599686295,
0.1252699941,
-0.2576269507,
0.091992639,
-0.1813015193,
0.0190470871,
-0.1494315267,
0.2030849606,
0.2337596565,
-0.0752744749,
-0.2329535186,
-0.018668944,
-0.21004574,
-0.129974097,
-0.2240431905,
-0.0309234802,
-0.4357795417,
-0.3890441656,
-0.1382716298,
-0.2333711982,
0.1505097598,
-0.1727720797,
0.1136882231,
0.2021440566,
-0.1122317761,
0.1752967238,
0.3410333097,
-0.2718718648,
-0.1941211075,
0.6130883098,
-0.0666858032,
-0.1512485594,
0.7113177776,
0.3033588827,
-0.0423688479,
-0.1743440926,
0.1081526652,
0.2341929525,
-0.3858112395,
0.2853287756,
0.1635697484,
0.1634942442,
-0.1965902597,
0.2521213293,
0.2201312929,
-0.1846631914,
0.3970371187,
-0.4602293372,
-0.509713769,
0.4463845193,
0.0845471397,
0.0709240735,
0.2473088354,
-0.0433701277,
-0.043713361,
-0.0759890079,
-0.2276254594,
0.247446999,
-0.2723969817,
-0.0583555065,
0.0696130097,
-0.0040516066,
0.3371643126,
-0.0663060993,
0.029159138,
0.1659566015,
-0.2252063304,
-0.1026370898,
-0.1141894907,
0.1490142792,
0.0157989115,
-0.0949411243,
0.0305293463,
-0.0366920754,
-0.0493085533,
-0.0795775354,
-0.0415419973,
0.1084421054,
0.1223266944,
0.2088788748,
-0.0192376785,
0.137481153,
0.1624714583,
-0.0185538586,
0.2324575335,
0.4320117235,
-0.0117513081,
-0.0371901058,
-0.0898713246,
0.0506721586,
-0.3393851221,
0.0471429788,
0.0060306285,
0.1280434579,
0.2622934282,
-0.3644199073,
0.1403399706,
-0.053318955,
0.3357659876,
0.4139713943,
-0.2965271771,
0.1962916553,
0.2712626457,
0.13681826,
-0.1289539784,
-0.0629803985,
0.2094251066,
0.0685959384,
-0.2580851316,
0.1500543058,
0.0695893317,
0.063906692,
0.0078101391,
0.1036725044,
0.2170006782,
0.0857107341,
0.2869378328,
-0.0087442277,
-0.1625746489,
-0.1077872813,
0.079073593,
-0.0241637602,
0.208763212,
0.0623034053,
-0.0682238713,
0.0224277452,
-0.2596633434,
0.2893354595,
-0.2149322927,
-0.4602823555,
-0.1117466688,
0.2711260617,
0.0393495001,
0.2057520747,
-0.1427602768,
0.4745546579,
-0.1932334602,
-0.2643637061,
-0.2773834467,
0.1968331635,
-0.2065375,
-0.2208609581,
-0.2355650961,
-0.2278683484,
-0.0058224136,
0.2028194219,
-0.2092943639,
-0.0926429629,
0.0864007846,
0.0272981301,
-0.1165535599,
-0.294320792,
-0.0962036327,
0.18955715,
0.3570015132,
-0.1744363904,
0.3444285393,
0.2414892167,
-0.0734658986,
0.1880816817,
0.4095214903,
0.434882462,
0.2738961279,
-0.0046074623,
0.0708002374,
-0.0968067199,
0.1222762913,
0.0140012205,
0.4516343176,
0.4236487448,
-0.0329655334,
0.2170107514,
0.15483585,
-0.1469515562,
0.1238777936,
-0.2332241237,
0.2634750605,
-0.4034262002,
0.2503225207,
-0.263535291,
0.0318444595,
-0.2383142263,
-0.0813417956,
-0.4715985954,
0.1538455933,
0.0717266798,
0.2676657736,
0.1711576879,
-0.0985632613,
0.0528312437,
-0.0990049988,
0.5613049865,
0.4129604995,
-0.0530663282,
-0.2733244002,
-0.0807374641,
-0.342318207,
0.0643561706,
-0.0016269026,
0.2761929929,
0.0762674958,
-0.02517437,
-0.0353830867,
0.003440409,
0.2386139184,
-0.0110850446,
-0.1528087258,
-0.0407070667,
-0.390458703,
-0.272018224,
-0.2046863586,
0.0986212865,
0.2173561454,
-0.0624679811,
0.1840585172,
-0.1856428236,
-0.0995989218,
-0.0109635852,
0.2751019001,
-0.2542507946,
0.0320407078,
0.4798113704,
0.2068730295,
0.2477910668,
-0.0673936903,
-0.4788297117,
-0.1018346623,
-0.4949994087,
-0.0287392102,
0.3469106257,
-0.2529999316,
0.5655479431,
-0.3241971731,
0.048321601,
-0.4833295643,
0.0389347896,
-0.1266915053,
-0.2461968809,
-0.2663315833,
0.0326231197,
0.0911234021,
0.0036105018,
0.3389851153,
0.3571831286,
-0.0979763418,
0.2286850363,
-0.3563883901,
-0.1225446388,
0.6582744718,
-0.3078452647,
0.0385356136,
0.2483167648,
0.0709769428,
0.1259832531,
-0.2791226208,
-0.7433036566,
0.2390068471,
0.3728470802,
-0.0812362656,
-0.1113456413,
0.1910903305,
-0.200693965,
-0.1895646453,
0.0172622241,
0.3858794868,
0.026991738,
-0.2057538629,
0.2680240571,
-0.1529311687
] |
https://github.com/huggingface/datasets/issues/3333 | load JSON files, get the errors | Hi, I add one field **example_id**, but I can't see it in the **comput_loss** function, how can I do this? below is the information of inputs
```
*********************** inputs: {'attention_mask': tensor([[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
...,
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0]], device='cuda:0'), 'end_positions': tensor([ 25, 97, 93, 44, 25, 112, 109, 134], device='cuda:0'), 'input_ids': tensor([[ 101, 2054, 2390, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2106, ..., 0, 0, 0],
...,
[ 101, 2339, 2001, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2003, ..., 0, 0, 0]], device='cuda:0'), 'start_positions': tensor([ 20, 90, 89, 41, 25, 96, 106, 132], device='cuda:0'), 'token_type_ids': tensor([[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
...,
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0]], device='cuda:0')}
```
```
# This function preprocesses a question answering dataset, tokenizing the question and context text
# and finding the right offsets for the answer spans in the tokenized context (to use as labels).
# Adapted from https://github.com/huggingface/transformers/blob/master/examples/pytorch/question-answering/run_qa.py
def prepare_train_dataset_qa(examples, tokenizer, max_seq_length=None):
questions = [q.lstrip() for q in examples["question"]]
max_seq_length = tokenizer.model_max_length
# tokenize both questions and the corresponding context
# if the context length is longer than max_length, we split it to several
# chunks of max_length
tokenized_examples = tokenizer(
questions,
examples["context"],
truncation="only_second",
max_length=max_seq_length,
stride=min(max_seq_length // 2, 128),
return_overflowing_tokens=True,
return_offsets_mapping=True,
padding="max_length"
)
# Since one example might give us several features if it has a long context,
# we need a map from a feature to its corresponding example.
sample_mapping = tokenized_examples.pop("overflow_to_sample_mapping")
# The offset mappings will give us a map from token to character position
# in the original context. This will help us compute the start_positions
# and end_positions to get the final answer string.
offset_mapping = tokenized_examples.pop("offset_mapping")
tokenized_examples["start_positions"] = []
tokenized_examples["end_positions"] = []
tokenized_examples["example_id"] = []
for i, offsets in enumerate(offset_mapping):
input_ids = tokenized_examples["input_ids"][i]
# We will label features not containing the answer the index of the CLS token.
cls_index = input_ids.index(tokenizer.cls_token_id)
sequence_ids = tokenized_examples.sequence_ids(i)
# from the feature idx to sample idx
sample_index = sample_mapping[i]
# get the answer for a feature
answers = examples["answers"][sample_index]
tokenized_examples["example_id"].append(examples["id"][sample_index])
if len(answers["answer_start"]) == 0:
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Start/end character index of the answer in the text.
start_char = answers["answer_start"][0]
end_char = start_char + len(answers["text"][0])
# Start token index of the current span in the text.
token_start_index = 0
while sequence_ids[token_start_index] != 1:
token_start_index += 1
# End token index of the current span in the text.
token_end_index = len(input_ids) - 1
while sequence_ids[token_end_index] != 1:
token_end_index -= 1
# Detect if the answer is out of the span (in which case this feature is labeled with the CLS index).
if not (offsets[token_start_index][0] <= start_char and
offsets[token_end_index][1] >= end_char):
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Otherwise move the token_start_index and token_end_index to the two ends of the answer.
# Note: we could go after the last offset if the answer is the last word (edge case).
while token_start_index < len(offsets) and \
offsets[token_start_index][0] <= start_char:
token_start_index += 1
tokenized_examples["start_positions"].append(
token_start_index - 1)
while offsets[token_end_index][1] >= end_char:
token_end_index -= 1
tokenized_examples["end_positions"].append(token_end_index + 1)
return tokenized_examples
``` | Hi, does this bug be fixed? when I load JSON files, I get the same errors by the command
`!python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/`
change the dateset to load json by refering to https://huggingface.co/docs/datasets/loading.html
`dataset = datasets.load_dataset('json', data_files=args.dataset)`
Errors:
`Downloading and preparing dataset json/default (download: Unknown size, generated: Unknown size, post-processed: Unknown size, total: Unknown size) to /root/.cache/huggingface/datasets/json/default-c1e124ad488911b8/0.0.0/45636811569ec4a6630521c18235dfbbab83b7ab572e3393c5ba68ccabe98264...
`
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/730#issuecomment-981095050_ | 576 | load JSON files, get the errors
Hi, does this bug be fixed? when I load JSON files, I get the same errors by the command
`!python3 run.py --do_train --task qa --dataset squad-retrain-data/train-v2.0.json --output_dir ./re_trained_model/`
change the dateset to load json by refering to https://huggingface.co/docs/datasets/loading.html
`dataset = datasets.load_dataset('json', data_files=args.dataset)`
Errors:
`Downloading and preparing dataset json/default (download: Unknown size, generated: Unknown size, post-processed: Unknown size, total: Unknown size) to /root/.cache/huggingface/datasets/json/default-c1e124ad488911b8/0.0.0/45636811569ec4a6630521c18235dfbbab83b7ab572e3393c5ba68ccabe98264...
`
_Originally posted by @yanllearnn in https://github.com/huggingface/datasets/issues/730#issuecomment-981095050_
Hi, I add one field **example_id**, but I can't see it in the **comput_loss** function, how can I do this? below is the information of inputs
```
*********************** inputs: {'attention_mask': tensor([[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
...,
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0],
[1, 1, 1, ..., 0, 0, 0]], device='cuda:0'), 'end_positions': tensor([ 25, 97, 93, 44, 25, 112, 109, 134], device='cuda:0'), 'input_ids': tensor([[ 101, 2054, 2390, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2106, ..., 0, 0, 0],
...,
[ 101, 2339, 2001, ..., 0, 0, 0],
[ 101, 2054, 2515, ..., 0, 0, 0],
[ 101, 2054, 2003, ..., 0, 0, 0]], device='cuda:0'), 'start_positions': tensor([ 20, 90, 89, 41, 25, 96, 106, 132], device='cuda:0'), 'token_type_ids': tensor([[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
...,
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0],
[0, 0, 0, ..., 0, 0, 0]], device='cuda:0')}
```
```
# This function preprocesses a question answering dataset, tokenizing the question and context text
# and finding the right offsets for the answer spans in the tokenized context (to use as labels).
# Adapted from https://github.com/huggingface/transformers/blob/master/examples/pytorch/question-answering/run_qa.py
def prepare_train_dataset_qa(examples, tokenizer, max_seq_length=None):
questions = [q.lstrip() for q in examples["question"]]
max_seq_length = tokenizer.model_max_length
# tokenize both questions and the corresponding context
# if the context length is longer than max_length, we split it to several
# chunks of max_length
tokenized_examples = tokenizer(
questions,
examples["context"],
truncation="only_second",
max_length=max_seq_length,
stride=min(max_seq_length // 2, 128),
return_overflowing_tokens=True,
return_offsets_mapping=True,
padding="max_length"
)
# Since one example might give us several features if it has a long context,
# we need a map from a feature to its corresponding example.
sample_mapping = tokenized_examples.pop("overflow_to_sample_mapping")
# The offset mappings will give us a map from token to character position
# in the original context. This will help us compute the start_positions
# and end_positions to get the final answer string.
offset_mapping = tokenized_examples.pop("offset_mapping")
tokenized_examples["start_positions"] = []
tokenized_examples["end_positions"] = []
tokenized_examples["example_id"] = []
for i, offsets in enumerate(offset_mapping):
input_ids = tokenized_examples["input_ids"][i]
# We will label features not containing the answer the index of the CLS token.
cls_index = input_ids.index(tokenizer.cls_token_id)
sequence_ids = tokenized_examples.sequence_ids(i)
# from the feature idx to sample idx
sample_index = sample_mapping[i]
# get the answer for a feature
answers = examples["answers"][sample_index]
tokenized_examples["example_id"].append(examples["id"][sample_index])
if len(answers["answer_start"]) == 0:
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Start/end character index of the answer in the text.
start_char = answers["answer_start"][0]
end_char = start_char + len(answers["text"][0])
# Start token index of the current span in the text.
token_start_index = 0
while sequence_ids[token_start_index] != 1:
token_start_index += 1
# End token index of the current span in the text.
token_end_index = len(input_ids) - 1
while sequence_ids[token_end_index] != 1:
token_end_index -= 1
# Detect if the answer is out of the span (in which case this feature is labeled with the CLS index).
if not (offsets[token_start_index][0] <= start_char and
offsets[token_end_index][1] >= end_char):
tokenized_examples["start_positions"].append(cls_index)
tokenized_examples["end_positions"].append(cls_index)
else:
# Otherwise move the token_start_index and token_end_index to the two ends of the answer.
# Note: we could go after the last offset if the answer is the last word (edge case).
while token_start_index < len(offsets) and \
offsets[token_start_index][0] <= start_char:
token_start_index += 1
tokenized_examples["start_positions"].append(
token_start_index - 1)
while offsets[token_end_index][1] >= end_char:
token_end_index -= 1
tokenized_examples["end_positions"].append(token_end_index + 1)
return tokenized_examples
``` | [
0.0734394193,
-0.4256197512,
-0.025549721,
0.5651884675,
0.4744012356,
0.2006401718,
0.1329942197,
0.3065040112,
0.2205163687,
0.0062531428,
0.0286499094,
0.2669722438,
0.0389592573,
0.1274508685,
-0.0082309134,
-0.1110081747,
0.0925866067,
0.1436215639,
-0.0355725028,
0.0444258153,
-0.2226279974,
0.3515385985,
-0.0905132666,
0.0953721628,
-0.1538114697,
-0.187983036,
0.1928618401,
0.0973474309,
-0.2844778001,
-0.4531750679,
0.1854986548,
-0.1204206571,
0.1869037598,
0.3397419155,
-0.0001187606,
0.1675631553,
0.2767539024,
-0.2527776062,
-0.3382387459,
-0.4102110267,
-0.1842398793,
-0.3959102929,
0.3921870887,
-0.2321059555,
-0.0164645705,
-0.0914707631,
-0.0949387103,
-0.2592941225,
0.7659289837,
0.3204527795,
0.1627117097,
0.3860193491,
0.078950569,
-0.0791749582,
0.1321806908,
0.3757911325,
-0.0550888181,
0.4611626565,
-0.0343113728,
0.1833150536,
0.2392318547,
0.2369403094,
0.2409222871,
-0.0509432517,
0.3252275586,
0.1166689396,
-0.0642907843,
-0.2380518168,
-0.2407403737,
-0.0734933615,
0.2316923887,
-0.2415280491,
-0.5960057378,
-0.434780091,
0.2232937664,
-0.6285653114,
0.2418406457,
0.1741684526,
-0.1212804914,
0.0066747814,
-0.2380974442,
-0.0175323114,
-0.1596457958,
0.1040052399,
0.3331530094,
-0.1571333408,
-0.2528927624,
0.0471739732,
0.1946139783,
-0.0795101449,
-0.2403191626,
0.2129572779,
-0.0740979984,
0.2242096215,
-0.2987619638,
-0.1769326776,
-0.1814171821,
-0.5325212479,
-0.0188632663,
0.0768460557,
0.1770877391,
-0.1347456574,
-0.0793472454,
0.2505057752,
0.1819874942,
0.4582919478,
-0.0386063419,
-0.093545422,
0.1149280444,
0.4940602183,
0.0499888174,
-0.2923781574,
-0.0328950807,
-0.0665680543,
-0.1765023172,
0.0034105082,
0.0344031602,
-0.0937631354,
-0.3874073625,
0.1212293059,
-0.2318054587,
-0.2967306376,
0.1235926747,
0.3598922491,
-0.1907471716,
0.0916773528,
0.2797181308,
0.2974717021,
-0.1028389409,
-0.0707520843,
-0.1148176938,
0.0889630914,
-0.1894780397,
0.1372620165,
0.2890866995,
0.0291692242,
0.3907817006,
-0.0597166531,
0.1494920701,
-0.2826873064,
0.0416585878,
-0.0097008776,
-0.0377558693,
0.2885140479,
-0.0581158251,
0.0021443218,
0.2393062264,
-0.2837916017,
-0.1367072761,
-0.1845350415,
-0.3627349138,
-0.1417938769,
-0.0831720904,
0.0925736353,
-0.0685526133,
0.1240188479,
-0.5399178267,
0.1910125017,
-0.1105801687,
-0.1242895275,
0.1232272089,
-0.0056980695,
-0.1576616019,
-0.1617899388,
0.4235157967,
0.3245744109,
-0.2805079818,
-0.424662739,
0.1880576015,
-0.2004916221,
0.0336079672,
0.3087862134,
-0.0638915747,
0.2178491801,
-0.3114289343,
0.060470026,
0.3733690679,
-0.3340498507,
-0.14624843,
0.0040432801,
-0.1107433438,
0.0755164698,
0.2136194557,
-0.169455424,
-0.1256665885,
0.2007129639,
0.4060196877,
-0.0536811687,
0.0734872892,
-0.0922685117,
-0.2177323103,
-0.3475718498,
-0.0645836666,
0.1500951052,
-0.3166698813,
0.2475449592,
0.0707266927,
-0.0527215116,
0.237048164,
-0.1561663151,
0.0238061156,
0.3291129768,
0.2108855844,
0.0295297224,
-0.133593902,
0.0120211933,
-0.666310966,
0.1488208622,
-0.0559487529,
-0.0009937895,
-0.0998063758,
-0.1514712572,
-0.2187208831,
-0.0801244825,
0.0380751267,
-0.0244435798,
0.0414478853,
0.0157843195,
0.241167441,
0.235365808,
-0.2886300087,
0.2078379691,
-0.1041839272,
0.2989164293,
-0.5492712855,
0.1278223395,
0.0248352867,
-0.1582476348,
0.0840449631,
0.2374863774,
0.1258108914,
-0.1494404823,
-0.1179853976,
0.1566884667,
0.0252650231,
0.232209444,
-0.0003115217,
0.0346418992,
0.132690981,
0.2516832948,
-0.2333738804,
0.0421812795,
0.0467840508,
0.0403086431,
-0.0738917142,
0.4846026897,
-0.191347301,
0.0641465187,
0.0935701877,
-0.2057142556,
0.2349876463,
0.1714647263,
-0.1424400955,
-0.2587035298,
0.1169800833,
0.2050009221,
0.0689827949,
-0.1299412996,
-0.4739689529,
-0.3284457922,
0.5703593493,
-0.012435033,
-0.148832798,
0.3756954372,
-0.0743940994,
0.1801795512,
0.0327496454,
0.1573242098,
0.4894225597,
0.0761940777,
-0.2493571937,
0.1498813331,
0.0920978561,
-0.1665640324,
0.0879574865,
0.0694680363,
0.3957990706,
0.2393936068,
0.2204294354,
-0.0630614683,
-0.3578238785,
0.0461767614,
-0.1008006036,
0.2288715094,
-0.540614903,
0.1027877852,
-0.1649196297,
-0.1895330101,
-0.2369480729,
0.0537890531,
-0.145927459,
-0.1558593363,
-0.054086253,
0.2857053876,
-0.1443495452,
-0.0767286122,
0.0797318071,
0.4088663161,
-0.0956557021,
0.0871859044,
-0.4628472626,
0.0338210091,
-0.1774128675,
-0.0359383188,
0.0941319466,
-0.2826233208,
0.2023630142,
-0.4245279133,
-0.0510493033,
0.0838932917,
-0.2563055754,
0.1145426258,
-0.1513542831,
0.4081273973,
0.0721614137,
0.3661672473,
-0.3820366561,
-0.3003061712,
0.4887297153,
0.0281572882,
-0.4268240631,
-0.1026191488,
0.024901377,
0.2586900592,
-0.3081692755,
-0.4536314011,
-0.2857466042,
-0.350228399,
0.853935957,
0.1615090668,
0.0780879781,
0.1736645252,
0.1145957038,
0.182816118,
-0.0969465226,
0.3941989839,
-0.2449299544,
-0.8151061535,
0.2595803738,
-0.3140242696,
-0.323449254,
0.0767102838,
0.0374799781,
0.3545617759,
-0.3839532733,
-0.5797400475,
-0.3934492469,
0.1687810868,
-0.0965954885,
-0.2021878064,
0.2128165364,
0.2249820083,
-0.0814478025,
0.0024334616,
-0.0427055955,
-0.4610920548,
0.0501399375,
0.1897546947,
0.2239284217,
-0.1387491822,
0.6910790205,
-0.1712832302,
0.7668344378,
0.3957058489,
-0.1553560197,
0.4311772883,
-0.2050274462,
0.2339503616,
-0.0759226233,
-0.1769957095,
-0.0680524632,
-0.1702115983,
0.0597585775,
-0.0250553526,
-0.0717833415,
0.107727997,
-0.1933384091,
0.1895891726,
-0.6318452358,
-0.1630519331,
-0.0850124285,
0.0368718393,
-0.1317185611,
-0.0420752428,
0.0572096631,
-0.0729729012,
0.0233576782,
0.0937382653,
0.2334097028,
0.3231414557,
0.023558693,
-0.3343214691,
-0.5201777816,
-0.3817092478,
0.2106354535,
-0.0808222294,
0.28396523,
-0.0421881974,
-0.0672493875,
0.0904746726,
0.0408331193,
0.8095771074,
0.0277976859,
-0.2705002427,
0.2563486993,
-0.2227668017,
-0.3629088104,
-0.0304674804,
-0.1047113091,
-0.2299214751,
0.4082519114,
0.7595114112,
-0.3618242741,
-0.1599393189,
-0.0384788252,
0.0425843075,
-0.1195935011,
-0.0348260552,
-0.3746334612,
-0.1783660352,
-0.4848809242,
0.1306251138,
-0.0701140463,
0.3130149543,
0.1398452818,
0.1349059343,
0.1346078217,
0.0062143998,
0.0826330185,
0.2740853131,
0.3425336778,
0.2502034307,
0.2017178088,
0.4145720601,
0.3933869004,
0.269279927,
0.6987174153,
0.0677434579,
-0.3413714767,
0.0011323608,
0.2020280957,
0.347815752,
0.1272284687,
0.1037658602,
0.129101336,
0.1600742489,
0.4223600626,
-0.4709526598,
0.0455969572,
0.6265051365,
-0.0521031581,
-0.0100515122,
-0.1259759665,
0.3407675922,
-0.0194285046,
0.0674646199,
0.0920538753,
0.0782583132,
-0.1634327769,
0.1619417518,
0.0595146343,
0.8648947477,
-0.1066052988,
0.2600541711,
0.4690989256,
-0.3779262304,
0.7196049094,
-0.470708698,
0.2183848321,
-0.150191918,
-0.0554057062,
0.0589627177,
-0.1255757362,
0.0629854128,
0.1407044083,
-0.1244032681,
0.1111977547,
-0.0054493872,
0.0783786327,
-0.2812044621,
0.1752166599,
-0.0004323307,
-0.2816005349,
-0.4989723563,
0.0037139361,
0.0349742584,
0.2701417506,
-0.0425837077,
-0.14844504,
-0.0032915021,
-0.2172070295,
-0.1513861716,
-0.0881857648,
-0.1899681538,
0.0107151922,
0.3833094537,
-0.2234541476,
0.1564528346,
0.2033983916,
0.2272779495,
0.0000915621,
-0.2343194485,
0.0693407878,
-0.2444304675,
0.0055840663,
-0.1712701023,
0.1935164183,
0.3184748292,
-0.1197415367,
-0.2320295721,
0.1792652607,
-0.1126017198,
-0.0839025229,
-0.1208537817,
0.0061360695,
-0.4281987846,
-0.284021467,
-0.2311879545,
-0.1099760979,
0.1138860062,
-0.1742901355,
0.1006171629,
0.2067240179,
-0.1463466436,
-0.0115675135,
0.2707771957,
-0.2632132769,
-0.1994577497,
0.566531837,
-0.1302565187,
-0.2015734017,
0.5939401984,
0.1913933605,
-0.0722659826,
-0.1364934742,
0.0405355729,
0.3078954518,
-0.3276408613,
0.1016912758,
0.3056876063,
0.0478453897,
-0.1812466979,
0.2145636827,
0.2034875304,
-0.0541272908,
0.3080739975,
-0.4620715976,
-0.5775812268,
0.4163707793,
0.0744371712,
0.0900471061,
0.2602829039,
-0.0126600508,
-0.0895045921,
0.0557340123,
-0.2250109166,
0.170810014,
-0.232965067,
-0.1247457191,
0.0437649488,
0.0723707378,
0.3610202372,
-0.107961908,
0.0880709812,
0.1615574658,
-0.2085776776,
-0.0896838382,
-0.1546181738,
0.1351699829,
0.0504298396,
-0.0491667278,
-0.0369040221,
0.0493136346,
0.0474977493,
-0.1115641594,
-0.0054221633,
0.0257371515,
0.107133016,
0.364947468,
-0.1358088255,
0.1337990165,
0.1323012114,
-0.1156928614,
0.2883938551,
0.5410200953,
0.0610671528,
-0.0701089203,
-0.1712962389,
0.0852781609,
-0.3945021331,
0.0708455443,
-0.0606991649,
0.1039185151,
0.2729898691,
-0.3122030497,
0.127632305,
-0.1175600737,
0.1541357785,
0.2290902138,
-0.2723455131,
0.271612376,
0.1718831211,
0.1519799829,
-0.1747274101,
0.0368196592,
0.2012127489,
-0.0669612363,
-0.105395481,
0.1839504987,
0.0317794196,
0.1252236962,
0.0485225692,
0.0116729885,
0.1741972119,
0.1121090725,
0.2508539855,
-0.0138002541,
-0.133420065,
-0.0698316544,
0.034561377,
0.1528907567,
0.2056810707,
0.0053944374,
-0.1001702026,
0.0076991902,
-0.3579778969,
0.2294911593,
-0.3069826961,
-0.2855213881,
0.0433337018,
0.2459467202,
-0.110728085,
0.0901368484,
-0.1628960222,
0.4521387219,
-0.0831163526,
-0.175680235,
-0.164861694,
0.1015437245,
-0.148735553,
-0.1614115536,
-0.2630761266,
-0.1775742918,
0.0050991746,
0.092681013,
-0.0820326135,
-0.136395961,
0.064948827,
0.0563842244,
-0.1748272926,
-0.08864934,
-0.1264993548,
0.1850052327,
0.4179305136,
-0.1523256302,
0.2622702718,
0.2181356847,
-0.115540415,
0.1738740951,
0.358964175,
0.4218245745,
0.1847162694,
0.154825151,
0.0694528073,
-0.0352080688,
0.0007654218,
0.0023331507,
0.4219508469,
0.4782013893,
-0.0450248569,
0.1435636729,
0.1602469981,
-0.1614791602,
0.0633257553,
-0.1196274683,
0.2315679342,
-0.3844905198,
0.2339512855,
-0.379083097,
-0.097000882,
-0.1365483701,
-0.1306116283,
-0.4524414241,
0.2596846819,
0.0743769482,
0.1719322652,
0.1467285305,
-0.1057412848,
0.0586134158,
-0.1192003563,
0.4828847647,
0.2531328499,
-0.1007615477,
-0.3197245598,
-0.097106196,
-0.3635603786,
0.1263023764,
0.1350538433,
0.2315153927,
0.0431485362,
0.0862067342,
0.0343813971,
-0.0180753786,
0.2295441329,
-0.1687886864,
-0.1015738472,
-0.0227564517,
-0.3769593835,
-0.2338347286,
-0.2327063233,
0.1474642009,
0.2159460038,
0.1363027692,
0.2313365042,
-0.2149313092,
-0.089872092,
-0.1392393857,
0.4288900793,
-0.3691001534,
0.1379980594,
0.5177046061,
0.0582802668,
0.3416082859,
-0.1208798587,
-0.3715009987,
0.0407495685,
-0.4280413985,
-0.0406954437,
0.344247818,
-0.174963817,
0.6239513755,
-0.2089466602,
-0.0390264727,
-0.4285964966,
0.0448016785,
-0.0884374008,
-0.4930008054,
-0.1317243427,
0.1093159169,
0.0055492767,
0.0662215427,
0.3565759957,
0.3274890482,
0.0049248957,
0.205306381,
-0.280444026,
-0.1903407872,
0.5951341987,
-0.3497059643,
0.0417623185,
0.231068626,
0.0913775563,
0.0060376851,
-0.1664633751,
-0.8354552984,
0.237334311,
0.354821533,
-0.1618052721,
-0.1908494234,
0.2984506488,
-0.2421569079,
-0.1258029491,
0.0196145866,
0.3645001054,
0.0735343248,
-0.0709466413,
0.213054955,
-0.1687939912
] |
https://github.com/huggingface/datasets/issues/3331 | AttributeError: 'CommunityDatasetModuleFactoryWithoutScript' object has no attribute 'path' | Hi,
the fix was merged and will be available in the next release of `datasets`.
In the meantime, you can use it by installing `datasets` directly from master as follows:
```
pip install git+https://github.com/huggingface/datasets.git
``` | ## Describe the bug
I add a new question answering dataset to huggingface datasets manually. Here is the link: [luozhouyang/question-answering-datasets](https://huggingface.co/datasets/luozhouyang/question-answering-datasets)
But when I load the dataset, an error raised:
```bash
AttributeError: 'CommunityDatasetModuleFactoryWithoutScript' object has no attribute 'path'
```
## Steps to reproduce the bug
```python
from datasets import load_dataset
dataset = load_dataset("luozhouyang/question-answering-datasets", data_files=["dureader_robust.train.json"])
```
## Expected results
Load dataset successfully without any error.
## Actual results
```bash
Traceback (most recent call last):
File "/mnt/home/zhouyang.lzy/github/naivenlp/naivenlp/tests/question_answering_tests/dataset_test.py", line 89, in test_load_dataset_with_hf
data_files=["dureader_robust.train.json"],
File "/mnt/home/zhouyang.lzy/.conda/envs/naivenlp/lib/python3.6/site-packages/datasets/load.py", line 1616, in load_dataset
**config_kwargs,
File "/mnt/home/zhouyang.lzy/.conda/envs/naivenlp/lib/python3.6/site-packages/datasets/load.py", line 1443, in load_dataset_builder
path, revision=revision, download_config=download_config, download_mode=download_mode, data_files=data_files
File "/mnt/home/zhouyang.lzy/.conda/envs/naivenlp/lib/python3.6/site-packages/datasets/load.py", line 1157, in dataset_module_factory
raise e1 from None
File "/mnt/home/zhouyang.lzy/.conda/envs/naivenlp/lib/python3.6/site-packages/datasets/load.py", line 1144, in dataset_module_factory
download_mode=download_mode,
File "/mnt/home/zhouyang.lzy/.conda/envs/naivenlp/lib/python3.6/site-packages/datasets/load.py", line 798, in get_module
raise FileNotFoundError(f"No data files or dataset script found in {self.path}")
AttributeError: 'CommunityDatasetModuleFactoryWithoutScript' object has no attribute 'path'
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.15.1
- Platform: linux
- Python version: 3.6.13
- PyArrow version: 6.0.1
| 35 | AttributeError: 'CommunityDatasetModuleFactoryWithoutScript' object has no attribute 'path'
## Describe the bug
I add a new question answering dataset to huggingface datasets manually. Here is the link: [luozhouyang/question-answering-datasets](https://huggingface.co/datasets/luozhouyang/question-answering-datasets)
But when I load the dataset, an error raised:
```bash
AttributeError: 'CommunityDatasetModuleFactoryWithoutScript' object has no attribute 'path'
```
## Steps to reproduce the bug
```python
from datasets import load_dataset
dataset = load_dataset("luozhouyang/question-answering-datasets", data_files=["dureader_robust.train.json"])
```
## Expected results
Load dataset successfully without any error.
## Actual results
```bash
Traceback (most recent call last):
File "/mnt/home/zhouyang.lzy/github/naivenlp/naivenlp/tests/question_answering_tests/dataset_test.py", line 89, in test_load_dataset_with_hf
data_files=["dureader_robust.train.json"],
File "/mnt/home/zhouyang.lzy/.conda/envs/naivenlp/lib/python3.6/site-packages/datasets/load.py", line 1616, in load_dataset
**config_kwargs,
File "/mnt/home/zhouyang.lzy/.conda/envs/naivenlp/lib/python3.6/site-packages/datasets/load.py", line 1443, in load_dataset_builder
path, revision=revision, download_config=download_config, download_mode=download_mode, data_files=data_files
File "/mnt/home/zhouyang.lzy/.conda/envs/naivenlp/lib/python3.6/site-packages/datasets/load.py", line 1157, in dataset_module_factory
raise e1 from None
File "/mnt/home/zhouyang.lzy/.conda/envs/naivenlp/lib/python3.6/site-packages/datasets/load.py", line 1144, in dataset_module_factory
download_mode=download_mode,
File "/mnt/home/zhouyang.lzy/.conda/envs/naivenlp/lib/python3.6/site-packages/datasets/load.py", line 798, in get_module
raise FileNotFoundError(f"No data files or dataset script found in {self.path}")
AttributeError: 'CommunityDatasetModuleFactoryWithoutScript' object has no attribute 'path'
```
## Environment info
<!-- You can run the command `datasets-cli env` and copy-and-paste its output below. -->
- `datasets` version: 1.15.1
- Platform: linux
- Python version: 3.6.13
- PyArrow version: 6.0.1
Hi,
the fix was merged and will be available in the next release of `datasets`.
In the meantime, you can use it by installing `datasets` directly from master as follows:
```
pip install git+https://github.com/huggingface/datasets.git
``` | [
-0.2787340283,
0.0727966651,
0.1128334329,
0.4117526412,
0.4317401648,
-0.0501596369,
0.1598860174,
0.0534961484,
0.1838313639,
0.1735432744,
-0.0451257862,
0.5018624067,
-0.2404233962,
-0.0016095933,
0.0799399465,
-0.0443504453,
-0.0731380209,
0.0257308185,
-0.3315460682,
-0.1445064247,
-0.2158104181,
0.3164505064,
0.0473854803,
0.0706169531,
-0.274412632,
-0.009994695,
-0.1308163553,
0.3300018609,
0.1829963624,
-0.3933314979,
0.4219394624,
-0.1911420524,
-0.076078929,
0.8302137852,
-0.0001241489,
-0.0581912994,
0.3435770869,
-0.0268953219,
-0.5387424231,
-0.4684943259,
-0.1969981045,
0.1613381505,
0.2675486803,
-0.0240536109,
-0.1951377243,
0.1050667986,
-0.0505822375,
-0.519859314,
0.3432199359,
0.3468331993,
0.0895573124,
0.3002499938,
-0.0527706482,
-0.3051680923,
0.0375145227,
0.6560079455,
-0.1784094721,
0.4218843877,
0.0784147456,
-0.053355936,
0.1238531247,
0.0478964448,
-0.0214638896,
0.0967847705,
0.2469699979,
-0.0374892466,
-0.0424584523,
-0.0216725767,
0.2258142829,
0.4112519324,
0.4895050526,
-0.3064204454,
-0.4390740991,
-0.3401955962,
0.111901015,
0.0570530705,
0.2115946412,
-0.0131652234,
-0.0775132924,
0.1357526332,
-0.1250485182,
-0.2432109863,
-0.192559436,
0.3040337563,
0.0901342481,
0.0279239491,
-0.256978631,
0.1546837091,
-0.1775622219,
-0.0338032469,
-0.0682720244,
-0.1177263409,
-0.0370078497,
0.208971411,
0.1536235958,
0.0224301107,
0.2688306272,
0.2026349753,
0.3649172485,
0.3900004327,
0.0802996829,
-0.1274308264,
-0.2093178332,
-0.0985158533,
0.1546535045,
0.1029681638,
0.1492053568,
0.0320044495,
0.1339885294,
0.3810569346,
-0.2272236943,
-0.1392208338,
-0.1970353574,
0.02039483,
-0.0878244266,
-0.1841395646,
0.6454572678,
-0.176687777,
-0.2396269292,
-0.0721832663,
0.0869948566,
-0.012965899,
0.1286658943,
0.5554526448,
0.0107952999,
0.2388471216,
-0.0418210104,
0.2287647575,
-0.1212124899,
-0.3004398942,
-0.2074905038,
0.1726967543,
-0.116185762,
0.1238113791,
-0.0393627807,
-0.171591565,
0.5124007463,
-0.2206801474,
0.1060515493,
-0.2476586401,
-0.1734736264,
0.0296181198,
-0.0510949045,
0.1313425601,
-0.1482397169,
0.4764259756,
0.2352470607,
-0.3461240828,
-0.0996148139,
-0.0419312045,
-0.2728954554,
-0.5491749048,
-0.1891883463,
0.0548041202,
-0.3041194379,
-0.1654404998,
-0.2867374718,
-0.0131214829,
-0.0510401055,
-0.1129739508,
-0.0372951217,
0.0382949747,
-0.2160524875,
-0.1827797145,
0.3061755896,
0.9799980521,
-0.2187824994,
-0.1699769348,
-0.1888654977,
-0.0139103532,
0.0263882838,
-0.0016925609,
-0.2395437062,
0.5026779175,
-0.4195891023,
-0.3035010397,
0.3405176699,
-0.4972646832,
-0.4756470025,
0.4267510474,
-0.116237931,
0.3746602237,
0.2642251849,
0.0560592674,
-0.1689718068,
0.0794364363,
0.0365970246,
0.3520741463,
0.04966693,
0.0240141936,
-0.1700485647,
-0.1904862374,
0.2972669601,
0.0707357824,
0.0665838718,
0.2133275717,
0.0521334,
0.1122542322,
0.160221383,
-0.0184205696,
-0.0797748193,
0.1052499041,
0.2735484838,
0.2352921367,
0.0254204813,
-0.2940061986,
-0.4970040023,
0.1151013598,
0.0078880228,
-0.1258898377,
-0.2119795531,
-0.2105857283,
-0.5217483044,
0.1241694987,
-0.4467489123,
-0.4100622535,
-0.0837995037,
0.4493430257,
0.0561480671,
0.1213873327,
-0.330622226,
0.3420641124,
-0.126660794,
0.2076116502,
-0.2868248224,
0.2391593456,
-0.086154893,
-0.0626597703,
-0.2252286375,
0.1879992634,
0.1581410468,
-0.3349346817,
-0.0869564489,
0.4237733483,
0.0375112966,
0.308280617,
0.1722632796,
-0.0638063848,
0.2396487147,
-0.1734761,
-0.215906322,
0.395319581,
0.3319021463,
0.085104607,
-0.0501281843,
0.2219130397,
-0.1718686819,
0.3179699481,
0.0922974199,
0.0325308219,
0.1901166141,
0.0424591899,
-0.0509308688,
-0.0973386467,
0.2777732313,
-0.0241429713,
0.4420976043,
-0.1178542972,
-0.2573304176,
-0.0019315755,
0.0188097823,
0.1338549554,
0.1450871825,
0.0172664803,
-0.3486050665,
0.1133735925,
-0.0146007445,
0.2081742883,
0.5339447856,
0.136412397,
-0.1541599929,
0.2298395336,
0.0203442182,
-0.0414219238,
0.1381056458,
0.0853457972,
0.3150324821,
0.2272893935,
0.0788993314,
0.3679119349,
-0.3229431808,
-0.4072821736,
-0.0201156512,
0.2820461392,
-0.6839033365,
0.0197675675,
-0.0987126455,
-0.0736307949,
-0.1289499998,
-0.2198315412,
-0.103392452,
-0.2003270835,
-0.1801489741,
0.2355477661,
-0.1388645768,
0.1118920445,
0.0479039364,
0.3571163416,
0.0190722998,
-0.3948115706,
-0.1595096737,
-0.0772097781,
-0.1405281872,
-0.125569135,
0.1964595616,
-0.1358731985,
0.1873033792,
-0.2480548024,
0.0094127925,
-0.2849457562,
-0.2837103009,
0.0206099134,
0.0822134763,
0.5673216581,
0.1559120119,
0.1901233345,
0.0540247671,
-0.3113273084,
0.3967213631,
-0.1938397139,
-0.0980172753,
0.06547153,
0.066381231,
-0.1001559943,
-0.1059630811,
-0.4710606635,
-0.0091847442,
-0.3304136992,
0.1292520911,
0.1273685396,
0.0266621783,
0.4325394928,
0.1056145132,
0.2433225363,
-0.1540922225,
0.2641761005,
-0.1927032173,
-0.2663601637,
0.3511537015,
-0.3448969126,
-0.4108613729,
-0.124633491,
-0.1710557491,
0.1554294825,
-0.0010212783,
-0.4866924584,
-0.5058954358,
-0.2046460807,
0.3047649264,
-0.1422678083,
-0.0035875137,
0.5561563373,
0.0420226455,
0.0306226518,
-0.1046190634,
-0.2572965622,
0.2449805737,
-0.0316588618,
0.1902490556,
-0.0641972199,
0.3993233442,
0.0027091145,
0.4635828137,
0.1666258574,
0.1492880881,
0.2998661995,
-0.4329092503,
0.5911369324,
-0.274818033,
-0.4389500022,
0.0406975374,
0.1371319741,
-0.045602452,
0.1882247627,
0.1698393673,
0.4569084942,
-0.214908123,
-0.1791389436,
-0.2827067673,
-0.0416681729,
-0.1334552318,
-0.2659815848,
0.1053699702,
0.1596526057,
0.2054992765,
-0.1524992883,
0.0240033008,
0.2791730762,
0.2673998773,
0.1494543105,
0.0442686379,
-0.427862674,
-0.052544225,
-0.2875465751,
0.2266291827,
0.0285444148,
0.1030232385,
-0.1558599323,
0.0231958237,
0.0624854751,
0.0603294224,
0.7019478083,
-0.0164975896,
0.0712239593,
-0.0112347286,
-0.1376709491,
-0.5392107964,
0.103846021,
-0.0409770757,
0.4779797792,
-0.1717200577,
0.2350085825,
-0.1379676908,
0.0507512242,
0.2568917274,
0.2099237442,
-0.1625560373,
0.0230573919,
-0.2055904418,
-0.4918831587,
-0.3299149573,
0.0233825259,
-0.0275171027,
0.3842446208,
0.350333482,
0.0683584884,
-0.1312718689,
-0.0660023764,
-0.0342747532,
-0.0444442183,
0.3278781772,
0.0571187772,
0.1236668825,
-0.0538096875,
0.1751085073,
0.1861994565,
0.6252813339,
0.1186758205,
-0.6285971999,
-0.1102369279,
-0.0726251751,
0.2574779391,
0.4089296162,
-0.0967181474,
-0.1554743201,
-0.1457636505,
0.0037813566,
-0.1975343525,
0.2569234073,
0.3158521056,
-0.0950157866,
-0.0697387382,
-0.3476485908,
0.374658376,
-0.2681781352,
0.002671415,
0.2884298563,
0.7128959298,
-0.2902105451,
0.3816001713,
-0.3629167676,
1.0019774437,
0.1650566012,
0.0832917765,
0.4705965519,
-0.1663110703,
0.6760207415,
0.2474265397,
-0.1847129166,
-0.09558402,
0.0904604048,
0.0171125755,
-0.1512607932,
0.345010072,
0.0066592321,
0.0930150747,
0.3489609361,
-0.2344182581,
0.2027479559,
0.1148614734,
0.3186672628,
0.1074963808,
-0.0219646543,
-0.2550232708,
0.0073919236,
-0.0590415858,
0.542087853,
0.0623625405,
0.0355243795,
-0.1767581403,
-0.1868643165,
-0.3181147575,
-0.0086720958,
-0.3767070472,
0.0772633106,
0.3369964063,
-0.5181425214,
0.3336186707,
0.4085895419,
0.2426905334,
0.1839430779,
-0.2415093184,
0.3332203627,
-0.4159641862,
0.0255856458,
0.0194751918,
0.0169244092,
0.3247216642,
-0.0158193279,
-0.158318609,
0.1062783971,
-0.2937477231,
-0.2290444523,
0.286724478,
-0.1628218293,
0.524807632,
-0.3842600584,
-0.3737314343,
0.042000927,
0.1098988056,
-0.2573584318,
-0.0171207972,
0.0787214637,
-0.2287730575,
-0.2661396861,
0.2783182263,
-0.2717664838,
-0.1411599815,
0.3787459731,
-0.2432691306,
-0.0309691578,
0.661549747,
-0.0009176881,
-0.0800799429,
-0.152167365,
0.1919721216,
0.560413301,
-0.7355569601,
0.1190414056,
0.2020981312,
0.1891065091,
-0.160855934,
0.2685594857,
0.1707694381,
0.2333193421,
-0.1024113819,
-0.3815971613,
-0.1505308449,
0.1186594516,
-0.1645907015,
-0.0872197747,
0.305629313,
0.0191563908,
0.2222720534,
0.0131950574,
-0.1872652322,
0.0431094877,
-0.0888758525,
-0.0761865452,
0.1693675071,
0.2580812871,
0.2203367651,
-0.1114959195,
0.0328360721,
-0.1088554412,
-0.0201544259,
-0.0742438585,
-0.2175925225,
0.2370800674,
0.0504626445,
-0.0756708533,
-0.1178411916,
-0.1138703078,
0.0627679303,
-0.2425495088,
0.1326618046,
0.2944795191,
-0.1161164194,
0.039624881,
-0.0179623943,
0.0450026989,
-0.3808729649,
0.184928,
-0.1660050154,
0.2168846875,
0.2221114188,
0.061647322,
0.0863061547,
-0.074590683,
-0.1893829107,
0.041913379,
-0.0186685473,
-0.0091212112,
0.3465535939,
-0.4928763509,
-0.0146134943,
0.2096360177,
0.0930239707,
0.0632365644,
-0.3656355143,
0.1962024868,
0.3310142457,
0.0282156784,
-0.3681812882,
0.1096335277,
0.0990958065,
-0.0908842161,
0.0819606185,
0.1746339798,
0.0733734965,
-0.093433544,
0.1331771314,
0.0918074474,
0.5245449543,
-0.0159984827,
0.286460191,
0.0162667725,
-0.0985695422,
0.1187820435,
0.127972737,
0.4060655236,
-0.1215899363,
0.2968332767,
-0.2520127296,
0.1413648129,
-0.1304962635,
0.1213400066,
0.135517478,
-0.3353404403,
0.1668057293,
0.0698522031,
-0.0285430625,
-0.1297159791,
-0.1747997403,
0.4625313878,
-0.4536502659,
0.1438927054,
0.0766317621,
-0.0683755949,
-0.0677480772,
-0.1555930525,
0.0261348449,
-0.1386865824,
-0.2723875642,
-0.1203897744,
-0.0277706012,
-0.484701246,
0.0890589431,
-0.0999053791,
-0.2744548619,
-0.5020900965,
0.0911500007,
0.1644067615,
0.1206170171,
-0.2662755251,
0.4286083877,
0.0566819832,
0.0822844058,
0.1519384533,
0.5170126557,
0.4286176562,
0.2764211297,
0.0026739168,
0.2399050146,
-0.1359948814,
-0.19742468,
0.1129013523,
0.0325932354,
-0.0936391503,
0.196145013,
0.2748448849,
0.0709911138,
-0.0858402103,
0.0927909389,
0.127507329,
0.1658733636,
-0.4868199229,
0.3282394409,
-0.3632177711,
-0.0443049595,
-0.3375100791,
0.1650039107,
-0.2780698836,
-0.1088552698,
0.1368665397,
-0.1102426425,
-0.0595246069,
-0.1161278859,
0.0022628575,
0.080613777,
0.2869952321,
0.6250287294,
0.1566335857,
-0.2406406552,
-0.3755803704,
-0.6046668291,
0.2098079622,
0.1913375109,
-0.2354554385,
-0.1320455819,
0.1869553775,
-0.1424678564,
0.0468305238,
-0.0503819063,
-0.0186782852,
0.1220112294,
0.0202674884,
-0.136376977,
-0.1939659864,
-0.1754803807,
0.2383529693,
0.0811978504,
-0.0410964787,
-0.0380356275,
-0.0114093563,
-0.1731423289,
0.2293888777,
0.0405250303,
-0.1353957802,
-0.2024054676,
0.0474076122,
0.0532994457,
0.3413459957,
-0.0606255345,
-0.0235514827,
-0.320135057,
-0.3041515946,
-0.0639519244,
0.2841353118,
-0.0137483291,
0.3693424165,
-0.1394083053,
-0.1627157032,
-0.2706395686,
0.1224441379,
0.0562918186,
0.0108196493,
-0.2456724644,
0.2905614078,
-0.2874145508,
0.224486351,
0.0755696446,
-0.0314211436,
-0.1506590247,
0.1425739974,
-0.1684310436,
-0.3185251355,
0.4827649593,
-0.3959246576,
-0.2464743257,
-0.1156070083,
0.3964616656,
0.0745440274,
-0.3308053911,
-0.4404380023,
0.0033503002,
0.3503597677,
0.1772973239,
-0.1498307735,
0.1321498305,
-0.5354667306,
0.1707665026,
0.0087085087,
0.2975465357,
0.0278491378,
0.0115427123,
0.2526344955,
-0.295337379
] |
https://github.com/huggingface/datasets/issues/3329 | Map function: Type error on iter #999 | Hi, thanks for reporting.
It would be really helpful if you could provide the actual code of the `text_numbers_to_int` function so we can reproduce the error. | ## Describe the bug
Using the map function, it throws a type error on iter #999
Here is the code I am calling:
```
dataset = datasets.load_dataset('squad')
dataset['validation'].map(text_numbers_to_int, input_columns=['context'], fn_kwargs={'column': 'context'})
```
text_numbers_to_int returns the input text with numbers replaced in the format {'context': text}
It happens at
`
File "C:\Users\lonek\anaconda3\envs\ai\Lib\site-packages\datasets\arrow_writer.py", line 289, in <listcomp>
[row[0][col] for row in self.current_examples], type=col_type, try_type=col_try_type, col=col
`
The issue is that the list comprehension expects self.current_examples to be type tuple(dict, str), but for some reason 26 out of 1000 of the sefl.current_examples are type tuple(str, str)
Here is an example of what self.current_examples should be
({'context': 'Super Bowl 50 was an...merals 50.'}, '')
Here is an example of what self.current_examples are when it throws the error:
('The Panthers used th... Marriott.', '')
| 26 | Map function: Type error on iter #999
## Describe the bug
Using the map function, it throws a type error on iter #999
Here is the code I am calling:
```
dataset = datasets.load_dataset('squad')
dataset['validation'].map(text_numbers_to_int, input_columns=['context'], fn_kwargs={'column': 'context'})
```
text_numbers_to_int returns the input text with numbers replaced in the format {'context': text}
It happens at
`
File "C:\Users\lonek\anaconda3\envs\ai\Lib\site-packages\datasets\arrow_writer.py", line 289, in <listcomp>
[row[0][col] for row in self.current_examples], type=col_type, try_type=col_try_type, col=col
`
The issue is that the list comprehension expects self.current_examples to be type tuple(dict, str), but for some reason 26 out of 1000 of the sefl.current_examples are type tuple(str, str)
Here is an example of what self.current_examples should be
({'context': 'Super Bowl 50 was an...merals 50.'}, '')
Here is an example of what self.current_examples are when it throws the error:
('The Panthers used th... Marriott.', '')
Hi, thanks for reporting.
It would be really helpful if you could provide the actual code of the `text_numbers_to_int` function so we can reproduce the error. | [
-0.0695655048,
-0.2543754578,
-0.029409619,
0.3593807817,
0.1476682872,
0.0972299725,
0.3781249523,
0.3375345767,
0.4425684214,
-0.09956678,
0.1078727767,
0.6538008451,
0.1616187543,
0.1190466881,
-0.0926601514,
0.0629927963,
0.0863813534,
0.0088729793,
-0.1706884652,
0.1339479983,
-0.6150160432,
0.1419074088,
-0.6294470429,
0.3102442622,
0.0164313558,
-0.1642967016,
0.2603220642,
-0.0844828859,
-0.1403771788,
-0.2403951734,
0.263541013,
-0.3593073189,
0.192234531,
0.4690087438,
-0.0001219239,
-0.0597824454,
0.3256959021,
-0.164669469,
-0.1911893636,
-0.3309638798,
-0.195289135,
0.1504078656,
0.1113396659,
-0.066682145,
0.1873724014,
0.2067001611,
-0.1081770137,
-0.153156966,
0.1125665456,
0.3918090463,
0.1293401122,
0.0745217577,
0.1760331094,
-0.0504306331,
0.2677648365,
0.3218045235,
-0.1237009764,
0.1542298347,
0.2386262566,
-0.1731004864,
0.0830603465,
0.3859221935,
-0.1136511192,
-0.0934608951,
0.1458537579,
0.0005077525,
0.1521477997,
-0.4237282872,
-0.1612037122,
0.0075210771,
0.3200414777,
-0.1895658225,
-0.2354426831,
0.1293599457,
-0.3576366305,
-0.2898721993,
0.1887791455,
-0.2044632435,
-0.1991846412,
-0.0867751166,
0.0241219327,
0.2110587656,
-0.1696501672,
0.2874499261,
-0.2640111744,
0.1455149353,
-0.220543161,
0.2866030037,
0.2089034617,
-0.4654515982,
0.0121785402,
0.0986243859,
0.0768376514,
0.3226657212,
-0.562923193,
-0.3143524528,
-0.0953404829,
-0.3345665932,
-0.0250589531,
0.0041649351,
0.2986058593,
0.1036873162,
-0.128068313,
0.4851787388,
0.5331827402,
0.2682119012,
0.2365895957,
0.5884689093,
-0.0240520909,
0.0094613414,
0.036006432,
-0.0481562689,
0.0248188693,
-0.083849512,
0.1106438413,
-0.0415438637,
0.0830140412,
-0.2129335999,
-0.3643583357,
0.3378993869,
-0.6286010146,
0.0229481589,
0.0560773276,
0.2339650691,
0.1419186741,
0.3150425553,
0.2316494435,
0.2602644861,
-0.0119980732,
0.0174153987,
-0.0570916049,
0.0642896444,
-0.1081484705,
-0.2285645008,
-0.0442165434,
-0.0479405858,
0.1371887326,
0.0305914897,
-0.2859510481,
-0.221213758,
-0.0144983809,
-0.2416338176,
0.2745878994,
0.1652422547,
-0.2677916288,
0.165695563,
0.4336308241,
-0.2443248332,
0.0087349424,
0.3310341239,
-0.4402857721,
0.117335692,
-0.3285537958,
0.0324856788,
0.2645615041,
-0.0817038491,
-0.0967928469,
0.0765109286,
0.2883661091,
-0.4929042757,
0.181550622,
-0.3865412474,
-0.2560728192,
-0.3211379945,
-0.0873302072,
0.2857621908,
-0.5808784366,
-0.0517575592,
-0.0230429489,
0.0191444773,
0.2398421615,
0.4893763065,
-0.0137976445,
0.1687566936,
-0.1019254699,
0.6126769185,
0.6557567716,
-0.1722440273,
-0.1647563577,
0.4104527533,
0.2205375433,
-0.1191082373,
-0.2869555056,
0.0795079693,
0.2351704985,
-0.1696298867,
0.3588588834,
0.0405382924,
-0.0572187901,
0.0102605941,
-0.2569832504,
-0.0254552178,
0.5739946365,
0.0108685028,
-0.0007419799,
0.2869465947,
0.128588438,
-0.2854795158,
0.1132626161,
-0.0428413898,
0.0273093395,
0.0206922907,
0.2873139381,
0.1878447384,
0.1069873497,
-0.4308701754,
-0.0909725204,
-0.2478298843,
0.01142669,
-0.0869922116,
-0.0840533972,
0.2179150432,
-0.367428422,
0.243657127,
-0.1255198419,
0.0414347611,
0.1213186905,
-0.1705058366,
-0.0791584328,
-0.1233143955,
-0.0251193475,
-0.2009352744,
-0.1189175025,
0.1258533895,
-0.2395031452,
-0.0054368218,
-0.0917652324,
-0.3534819186,
-0.2883015871,
0.1287067235,
0.2094671428,
0.0962298736,
-0.2935905755,
0.1596087217,
0.1707469225,
-0.2016813606,
-0.2244099081,
0.0813144073,
0.0810286552,
0.1332652569,
-0.115196988,
0.5474796891,
0.2505154014,
-0.1415659487,
0.0464737639,
0.1887078732,
0.1749876589,
0.4248390794,
-0.3136245012,
0.4457043707,
-0.0536943823,
0.3130359054,
-0.028743837,
-0.1417189986,
-0.082821995,
0.1759939641,
0.3023210466,
-0.0885606706,
-0.0076479441,
0.0008892188,
0.166696474,
-0.1240789965,
0.3597769737,
0.2566116154,
-0.2081840336,
0.0375715345,
-0.0080952281,
-0.1759700626,
0.2340531498,
-0.2820883095,
-0.1806077808,
-0.1485557407,
-0.0424757451,
0.2266534716,
0.162413612,
0.3013558388,
0.3988277018,
0.0224945545,
-0.0561341122,
-0.053503558,
-0.058263097,
-0.0715882853,
-0.0936176777,
0.3342617154,
-0.5203602314,
0.0864693224,
-0.132066831,
-0.1436023712,
-0.0006678287,
-0.0683459565,
-0.0070216069,
-0.3734585643,
-0.2227048129,
0.2830422521,
-0.1167346761,
-0.0051348442,
0.164536804,
-0.1163395196,
0.5080774426,
0.1118963733,
-0.1097137854,
-0.2054327577,
-0.071142301,
0.0339056402,
0.2402525991,
-0.2218946218,
-0.0922775269,
0.2009497136,
0.0038180447,
-0.2439982295,
-0.3361804485,
0.2398134172,
-0.2234873474,
0.1015039533,
0.3957750201,
0.3984489143,
-0.2546173334,
-0.1787180752,
0.2923995852,
-0.0411954969,
-0.2352621108,
0.3793847263,
-0.0237309132,
0.1017158404,
-0.1177441403,
-0.2642738819,
-0.1338200122,
-0.2897909582,
0.4506814182,
0.1078315899,
0.3529075682,
-0.0236950684,
0.1627840549,
0.200650841,
0.049578879,
-0.2298317552,
-0.317162782,
0.1308652163,
0.1968706548,
-0.1634984463,
-0.1119229048,
-0.1869515032,
0.0558604747,
-0.0007267398,
-0.030592123,
-0.1211788058,
-0.3105865717,
-0.1756083071,
-0.0063936329,
-0.2528826594,
0.1740204245,
0.4018419087,
0.120680593,
0.0169336703,
-0.1384333521,
-0.3979095519,
0.1340524405,
0.2687706947,
0.2067527473,
0.3104080856,
0.3809590042,
0.0319610126,
0.2549995184,
0.5371599793,
-0.0497086532,
0.3001980186,
0.0078809755,
-0.0893397704,
-0.0461446829,
-0.057113722,
0.0432769954,
-0.3924379349,
-0.1410058439,
0.0631201193,
-0.1524356157,
-0.454233855,
0.0686304867,
-0.0165444557,
-0.412440002,
-0.203576535,
0.2011570781,
-0.1123742387,
-0.0785663202,
-0.1799052358,
0.0531223826,
-0.2914041877,
-0.0545443781,
0.187297225,
-0.1612816453,
0.2058494389,
-0.0528058484,
-0.3333384097,
-0.4120837152,
0.1111915335,
0.3864590824,
0.1588540375,
0.566327095,
0.0789782256,
-0.2584564984,
-0.1425779462,
0.2409024537,
0.5347713232,
-0.6153743267,
-0.1004013643,
0.1602583677,
0.3245459199,
-0.299351275,
-0.1082002297,
-0.4262551367,
0.3427459896,
0.3380501866,
0.3117088974,
-0.150192067,
0.0984089002,
0.1427152753,
0.0462444872,
-0.0316577405,
-0.0953184068,
0.0506323092,
-0.1582833827,
-0.4131896198,
0.1007796302,
0.314684391,
-0.0721289143,
0.260055542,
0.0505835563,
-0.0023302415,
0.0048911832,
0.0664386898,
-0.0588810407,
0.4126400352,
0.0184051115,
-0.2201867849,
0.0044442192,
0.1871816516,
-0.1292049438,
0.380515188,
0.1179338694,
-0.1980929971,
0.4522652328,
-0.1155581474,
0.3882244229,
0.1004927978,
-0.1367211342,
0.1211595908,
-0.2350829989,
0.2050103396,
-0.1254639328,
-0.3834755421,
0.5729427934,
0.2489295602,
-0.177368179,
-0.2555021644,
0.3539672196,
0.0775871426,
-0.1194352359,
0.5404184461,
-0.1737282127,
0.0101413988,
0.525391221,
0.2833394706,
0.9040064216,
-0.1102626175,
-0.0662208423,
0.1404304504,
0.3049687147,
0.1586986482,
0.0704493523,
-0.0299438611,
-0.558277905,
-0.0082143787,
-0.236684531,
-0.1103573367,
0.0251551941,
0.1342558861,
-0.5057885051,
0.2587187886,
-0.2885088325,
0.3344547153,
0.2845622301,
-0.3772441149,
0.0238804128,
-0.2882982194,
-0.1067162529,
0.11501766,
0.1615962386,
0.1286668628,
0.0874086022,
-0.1035111994,
-0.0592176132,
-0.3507212996,
-0.4191790521,
0.0507267602,
-0.5273362994,
0.118043758,
0.3719425797,
0.0774004385,
0.2286955863,
0.4529132843,
0.0303228125,
0.1225797608,
-0.1237738356,
-0.3049499691,
0.6015775204,
0.1871829629,
0.3185849786,
0.1369003356,
0.3281781077,
-0.0154425483,
-0.1355589628,
0.1346591711,
-0.0266329758,
-0.1701676846,
-0.268203795,
0.2126082033,
-0.0895552933,
-0.5962549448,
-0.245448336,
-0.3113125265,
-0.260807991,
-0.0953044072,
0.016059665,
0.1170540527,
-0.0213072356,
0.2530027926,
-0.0025145223,
-0.0990803689,
0.2924416363,
0.1696439534,
0.0473780297,
-0.0232748538,
0.3313793838,
0.1021782383,
-0.2562969923,
-0.143374458,
0.0015400301,
-0.1324682385,
-0.2037997693,
0.2618320882,
-0.2987755537,
-0.286894083,
-0.0765030533,
0.6176582575,
-0.0436692238,
0.2640354931,
-0.2866377234,
-0.5139837265,
-0.1069017276,
0.2267072052,
0.2403324693,
-0.0728572458,
-0.30531317,
-0.0762418956,
0.0288450774,
-0.1282640398,
-0.1977083534,
0.0886698067,
-0.3188826144,
0.350143373,
-0.1792533845,
0.1081913635,
0.1429683119,
0.095213525,
0.0141693857,
0.6018434167,
-0.1024371237,
-0.1084600613,
-0.1078036427,
0.1442945004,
0.0999301895,
-0.2720964253,
0.1189406961,
0.0909626633,
-0.0145454854,
-0.19608742,
-0.2759792209,
-0.0998071581,
-0.1131149828,
0.3755291998,
-0.0691281855,
-0.0470603742,
0.2306656837,
0.3200949132,
-0.2593322396,
0.1611350775,
-0.0722595379,
0.1367817521,
0.1004889235,
0.0023803439,
-0.1971405596,
0.1989262551,
0.0156789403,
-0.0131043922,
0.3470030129,
-0.5167505741,
-0.0848103613,
0.1125337258,
0.3679922819,
0.2878626287,
-0.4276922941,
0.0461977385,
-0.0871513039,
0.0968576521,
-0.2106999457,
0.0939195156,
0.1834602058,
-0.1608288139,
-0.0020229821,
0.4245438278,
-0.0233880803,
-0.2095774859,
0.2748401463,
-0.2979615629,
-0.1709305942,
-0.2626062334,
0.1447199285,
0.4373887181,
-0.2342559248,
-0.0273824409,
0.0813217685,
-0.1643158048,
0.0085291481,
-0.225314334,
0.1313749105,
-0.2352953404,
-0.0031566783,
-0.0111278193,
0.3951019943,
-0.1813291311,
0.6834610105,
0.3557899594,
-0.1440314502,
0.3301380873,
0.1529206932,
0.4438768327,
-0.3234804273,
0.0110196183,
-0.143833667,
-0.1555028707,
-0.3003567457,
-0.0582696497,
-0.1321522295,
-0.2754933536,
-0.2158465534,
-0.3727378547,
-0.2113935351,
-0.174175933,
0.4169175327,
0.1952472478,
0.0765886083,
-0.3720628321,
-0.374517709,
-0.1846863776,
0.3983650208,
-0.3469187319,
0.186944589,
-0.1694458425,
-0.1041446254,
0.0905981734,
0.4275341332,
0.5573438406,
0.5100725293,
-0.2411069721,
0.1398828477,
-0.2200687677,
-0.1671431363,
0.2982298732,
-0.0361772366,
0.1713202894,
-0.1576164961,
0.3751988113,
0.0107049467,
-0.0285773296,
0.041107893,
-0.0714580566,
0.3837415576,
0.015794551,
0.2023428082,
-0.2562130094,
-0.145612523,
-0.1401195973,
-0.4190109074,
-0.3071637452,
-0.0730982572,
0.2255738825,
-0.1275187135,
0.3679936826,
-0.0764601827,
0.0506548882,
0.1099380255,
0.2072081864,
0.0779084265,
-0.2576296628,
-0.2857398689,
0.0756513253,
-0.233567819,
0.1588982344,
-0.0521691553,
0.1071826294,
0.3112221956,
0.2362878323,
0.1756276041,
0.474858433,
0.1729637533,
-0.4625176191,
-0.1202157661,
0.5098289251,
-0.1539703459,
-0.3050228953,
0.1119635478,
0.1841174811,
0.2538101673,
-0.3058979511,
0.2468066365,
-0.055980809,
0.0427608564,
-0.2997754812,
0.0739777088,
-0.1994887143,
0.0561113581,
0.1746657938,
0.2942511141,
0.181123212,
0.0032182205,
-0.3335573673,
0.1368740797,
-0.0583995543,
-0.2929181457,
0.3238654733,
-0.0172773432,
0.3267585337,
-0.0076567652,
-0.0876559764,
-0.2723297179,
-0.1697116494,
-0.107412003,
-0.1337946355,
-0.5201791525,
0.1476606876,
0.0597048961,
-0.0200982559,
-0.0929741189,
0.0590314381,
0.0753867552,
0.3783298433,
-0.0665877536,
-0.534502089,
0.362896353,
-0.3975842297,
-0.3268277049,
0.1708774269,
-0.0988867581,
-0.1025626212,
0.0169787966,
-0.7437281013,
-0.0986654907,
0.2790268064,
0.0568351187,
0.0410640724,
0.0021503929,
-0.2367929369,
0.0099977078,
-0.1351994425,
0.4249641299,
0.1917418242,
0.0669614896,
0.1721039712,
-0.2593147457
] |
https://github.com/huggingface/datasets/issues/3329 | Map function: Type error on iter #999 | ```
def text_numbers_to_int(text, column=""):
"""
Convert text numbers to int.
:param text: text numbers
:return: int
"""
try:
numbers = find_numbers(text)
if not numbers:
return text
result = ""
i, j = 0, 0
while i < len(text):
if j < len(numbers) and i == numbers[j][1]:
n = int(numbers[j][0]) if numbers[j][0] % 1 == 0 else float(numbers[j][0])
result += str(n)
i = numbers[j][2] #end
j += 1
else:
result += text[i]
i += 1
if column:
return{column: result}
else:
return {column: result}
except Exception as e:
print(e)
return {column: result}
``` | ## Describe the bug
Using the map function, it throws a type error on iter #999
Here is the code I am calling:
```
dataset = datasets.load_dataset('squad')
dataset['validation'].map(text_numbers_to_int, input_columns=['context'], fn_kwargs={'column': 'context'})
```
text_numbers_to_int returns the input text with numbers replaced in the format {'context': text}
It happens at
`
File "C:\Users\lonek\anaconda3\envs\ai\Lib\site-packages\datasets\arrow_writer.py", line 289, in <listcomp>
[row[0][col] for row in self.current_examples], type=col_type, try_type=col_try_type, col=col
`
The issue is that the list comprehension expects self.current_examples to be type tuple(dict, str), but for some reason 26 out of 1000 of the sefl.current_examples are type tuple(str, str)
Here is an example of what self.current_examples should be
({'context': 'Super Bowl 50 was an...merals 50.'}, '')
Here is an example of what self.current_examples are when it throws the error:
('The Panthers used th... Marriott.', '')
| 91 | Map function: Type error on iter #999
## Describe the bug
Using the map function, it throws a type error on iter #999
Here is the code I am calling:
```
dataset = datasets.load_dataset('squad')
dataset['validation'].map(text_numbers_to_int, input_columns=['context'], fn_kwargs={'column': 'context'})
```
text_numbers_to_int returns the input text with numbers replaced in the format {'context': text}
It happens at
`
File "C:\Users\lonek\anaconda3\envs\ai\Lib\site-packages\datasets\arrow_writer.py", line 289, in <listcomp>
[row[0][col] for row in self.current_examples], type=col_type, try_type=col_try_type, col=col
`
The issue is that the list comprehension expects self.current_examples to be type tuple(dict, str), but for some reason 26 out of 1000 of the sefl.current_examples are type tuple(str, str)
Here is an example of what self.current_examples should be
({'context': 'Super Bowl 50 was an...merals 50.'}, '')
Here is an example of what self.current_examples are when it throws the error:
('The Panthers used th... Marriott.', '')
```
def text_numbers_to_int(text, column=""):
"""
Convert text numbers to int.
:param text: text numbers
:return: int
"""
try:
numbers = find_numbers(text)
if not numbers:
return text
result = ""
i, j = 0, 0
while i < len(text):
if j < len(numbers) and i == numbers[j][1]:
n = int(numbers[j][0]) if numbers[j][0] % 1 == 0 else float(numbers[j][0])
result += str(n)
i = numbers[j][2] #end
j += 1
else:
result += text[i]
i += 1
if column:
return{column: result}
else:
return {column: result}
except Exception as e:
print(e)
return {column: result}
``` | [
-0.1012620106,
-0.2614865601,
-0.0429167934,
0.360131681,
0.1728987098,
0.0626525655,
0.35847646,
0.3256571293,
0.5001993775,
-0.0529093295,
0.0537561253,
0.6227624416,
0.1381005049,
0.0644423664,
-0.1447207034,
0.016932277,
0.0577133074,
-0.001892627,
-0.1074982211,
0.1114239618,
-0.5638144612,
0.1433547586,
-0.5702192783,
0.2570311129,
0.004812466,
-0.2165426165,
0.2775196433,
-0.0957794711,
-0.1651195437,
-0.2181236595,
0.2940832675,
-0.2994800508,
0.1954320669,
0.4470334947,
-0.0001191251,
0.0142438365,
0.2757127285,
-0.1561256796,
-0.2020751834,
-0.3411087096,
-0.1604283154,
0.1284935772,
0.093246825,
-0.0646710545,
0.1391970813,
0.2439175695,
-0.1118628085,
-0.1573576927,
0.0779471695,
0.3774298131,
0.1603942961,
0.1574553251,
0.1495597661,
-0.0785645396,
0.2873197198,
0.2529652417,
-0.1549126804,
0.076988548,
0.2113075852,
-0.1963031888,
0.0052303378,
0.4048808813,
-0.1831412166,
-0.0796901211,
0.0490305461,
0.0325162448,
0.2132156938,
-0.4257721305,
-0.1276637018,
-0.0060884198,
0.2319153249,
-0.0629010722,
-0.2234012932,
0.1061327159,
-0.4001217186,
-0.2767654955,
0.1499402225,
-0.1544396728,
-0.2123502791,
-0.0588714369,
0.0398612022,
0.2911485434,
-0.1103023738,
0.2908606231,
-0.2672029734,
0.2287460119,
-0.2104376107,
0.2669142187,
0.2014146,
-0.4097217023,
-0.0574660487,
0.1127536371,
0.0565511063,
0.3152273893,
-0.5426425338,
-0.2525950074,
-0.0590486489,
-0.3645431399,
-0.0041888044,
0.0139535395,
0.3200324476,
0.1058875844,
-0.1163667068,
0.4758040309,
0.4637616575,
0.3127884567,
0.149824068,
0.6079448462,
-0.0720361769,
0.0112711517,
0.0230532978,
-0.0254174806,
0.0730161369,
-0.0537023284,
0.127738446,
-0.006875277,
0.1092816964,
-0.1468176246,
-0.3932795823,
0.3896170259,
-0.6453599334,
-0.0215465184,
0.1180631071,
0.2313045561,
0.1862020493,
0.3875601292,
0.2029905021,
0.203242898,
-0.013562954,
0.0693083853,
-0.0998436362,
0.0166544002,
-0.0535441227,
-0.2298490852,
-0.0852427483,
-0.0267488789,
0.1363468468,
-0.0070656165,
-0.2677710354,
-0.2192017138,
-0.0185924005,
-0.3035116494,
0.2954967618,
0.184457764,
-0.275049299,
0.1259486377,
0.4909397662,
-0.318144232,
0.0296582635,
0.2716630697,
-0.3922417164,
0.1617651433,
-0.2809867561,
0.0891973153,
0.3626573384,
-0.0899576545,
-0.1513997912,
0.0848011523,
0.2686975598,
-0.3607102334,
0.1525703967,
-0.3809399903,
-0.266595602,
-0.315623045,
-0.0845554918,
0.2466318607,
-0.4842208028,
-0.0631032288,
0.0042869281,
0.0539712869,
0.201974988,
0.5303295255,
-0.0069203088,
0.2024486512,
-0.1474526227,
0.5987240672,
0.6202794909,
-0.2132856846,
-0.2050489187,
0.4125593007,
0.2524662614,
-0.1173527688,
-0.2588871717,
0.0438407734,
0.2241846919,
-0.1479709893,
0.3191021085,
0.0392673537,
-0.0391227752,
-0.0080851456,
-0.2997053862,
-0.0363399684,
0.5437581539,
-0.0242019054,
0.1037484482,
0.2407695204,
0.1227888986,
-0.2245323658,
0.0773345903,
-0.0260762777,
-0.0452483408,
0.0198899209,
0.3008201718,
0.1016820148,
0.108648479,
-0.4381991625,
-0.1298137754,
-0.2238329053,
0.0499676391,
-0.0735044405,
-0.0823293179,
0.1805243045,
-0.3587853909,
0.2458988726,
-0.1618631333,
0.0253474321,
0.1940434873,
-0.104055047,
0.009252687,
-0.1525563598,
0.0393343121,
-0.2895756364,
-0.0878156647,
0.0923504531,
-0.1941938996,
0.046659369,
-0.1315993667,
-0.3022493422,
-0.3391084969,
0.1269529909,
0.2076937854,
0.1045774519,
-0.3300056756,
0.1553385854,
0.1557223499,
-0.1805666238,
-0.2013396621,
0.0896027088,
0.0279376954,
0.1424518973,
-0.236029461,
0.5354242921,
0.2369873971,
-0.1263152957,
0.1285616457,
0.1471897811,
0.1911659539,
0.4348577559,
-0.2396908551,
0.4494385421,
0.0178342499,
0.3127276599,
-0.0168226864,
-0.1778780371,
-0.0848628879,
0.2212905735,
0.3229800463,
-0.0723194331,
0.0034058879,
-0.0496547632,
0.2126948237,
-0.1040328518,
0.3284200728,
0.2107954025,
-0.1632693708,
0.0855949894,
-0.052865278,
-0.1505675912,
0.197793439,
-0.2186239213,
-0.1296835244,
-0.2180377692,
-0.0643807799,
0.2065323442,
0.174402386,
0.3573570549,
0.3666290343,
0.0445517525,
-0.0570885204,
-0.0575517677,
-0.1251293123,
-0.0708370581,
-0.0927407965,
0.3160718679,
-0.4278383255,
0.1411617845,
-0.0838347524,
-0.087532796,
0.0196733177,
-0.0955071822,
-0.0089004645,
-0.3626332581,
-0.2025992423,
0.2698570788,
-0.1165341288,
-0.0283370148,
0.1702146828,
-0.163916707,
0.5541732311,
0.0742101744,
-0.1538383067,
-0.2122325003,
-0.0665375069,
0.0640592948,
0.2733141184,
-0.3290651143,
-0.0375969708,
0.1813055128,
-0.0722204819,
-0.3015746176,
-0.3599544168,
0.2461034954,
-0.2555811405,
0.0714496002,
0.4253468812,
0.338393271,
-0.3542421758,
-0.2016048133,
0.3357477486,
-0.0218681954,
-0.2430839241,
0.380438149,
0.0100058252,
0.0402899794,
-0.1529441327,
-0.2635672987,
-0.1432644725,
-0.3321788013,
0.4326548278,
0.1367596537,
0.351734072,
-0.0060991845,
0.1067305654,
0.2188461423,
0.0693673119,
-0.2107564658,
-0.3670693934,
0.0845735595,
0.1728571653,
-0.135094136,
-0.1024474576,
-0.2162277848,
-0.0902397186,
0.0726038218,
-0.0005009639,
-0.1267652065,
-0.3413903415,
-0.2321779728,
0.0299262237,
-0.227728188,
0.1553224176,
0.4101739228,
0.1415108442,
-0.022510292,
-0.1417879909,
-0.375377804,
0.0969078615,
0.2652602196,
0.1715660989,
0.234004274,
0.3867046535,
0.0952090025,
0.3064414859,
0.4467326105,
-0.0570646487,
0.316068083,
0.0459347293,
-0.0914881155,
-0.1114187315,
-0.1228701025,
-0.0078294855,
-0.3909177482,
-0.1912151426,
0.0714301839,
-0.1665304154,
-0.4290461242,
0.0749104321,
0.0730864257,
-0.3995016217,
-0.2087577581,
0.1756790876,
-0.0889757276,
-0.0593477748,
-0.1497250944,
0.0860211179,
-0.2450999171,
-0.0277913995,
0.1091679335,
-0.1506131142,
0.2140817344,
-0.1089629456,
-0.2984604836,
-0.3309212327,
0.0969854891,
0.4240060151,
0.1640825272,
0.5171325207,
0.0730186403,
-0.2538285255,
-0.1466751546,
0.2135300338,
0.5097342134,
-0.5522745252,
-0.154398635,
0.1580405384,
0.2870237827,
-0.2839058936,
-0.106686458,
-0.4882437289,
0.269870162,
0.4095682204,
0.3465426266,
-0.1771759242,
0.0329381339,
0.1296326518,
0.0470510684,
-0.0383599363,
-0.0532866493,
-0.0087593729,
-0.1717443913,
-0.403444469,
0.1496557742,
0.3358283937,
-0.0677767694,
0.2675532103,
-0.0198530667,
-0.0634308606,
-0.0865886137,
0.0660763457,
-0.0845758989,
0.4402135313,
0.0892721862,
-0.2365160584,
-0.0441673175,
0.3055111766,
-0.1161243841,
0.3869123161,
0.0628964081,
-0.1302933395,
0.402431041,
-0.0696988031,
0.3289275169,
0.0558369569,
-0.1849001199,
0.1295917779,
-0.2439657003,
0.2996392846,
-0.1940478384,
-0.2972053289,
0.5750582218,
0.2287605256,
-0.1585208476,
-0.2115437388,
0.3293995559,
0.0585824884,
-0.1423002481,
0.4442334175,
-0.2254946083,
-0.0586122759,
0.5727233887,
0.2831387222,
0.8068002462,
-0.1284199953,
-0.0984444618,
0.1819881648,
0.3330500722,
0.1490362138,
0.135999769,
0.0338992961,
-0.4854657054,
-0.0055265501,
-0.2294669896,
-0.0791729018,
0.0159421414,
0.1625000238,
-0.5453808904,
0.2673581541,
-0.2340905517,
0.3128556311,
0.2847754955,
-0.3234637082,
0.0068740328,
-0.307715416,
-0.1462794244,
0.1341972798,
0.0936087593,
0.0825087503,
0.088344641,
-0.0481568836,
-0.0312809311,
-0.4307675362,
-0.3773893118,
0.0167602003,
-0.5646739602,
0.193795085,
0.321190685,
0.025622515,
0.1095898598,
0.4169858098,
-0.0729835853,
0.1515288949,
-0.0537651703,
-0.3029771447,
0.5903646946,
0.19728522,
0.2984776497,
0.0785366371,
0.3487033546,
0.0089228069,
-0.0902719572,
0.1383049935,
-0.0800298154,
-0.2460415214,
-0.326967746,
0.2371764332,
0.0656905621,
-0.5380497575,
-0.2359808385,
-0.3663820922,
-0.3710189164,
-0.1146815047,
0.051189065,
0.1494963467,
-0.0203326736,
0.2504939139,
0.0188336782,
-0.0977308825,
0.3009850085,
0.1282468438,
0.0347501151,
-0.0155792898,
0.3551585972,
0.0006954854,
-0.296665132,
-0.1989306957,
-0.0164832622,
-0.1816675812,
-0.1751445234,
0.3101787269,
-0.2834358811,
-0.2904998958,
-0.1024691239,
0.582850337,
-0.027119223,
0.2600955367,
-0.2914438844,
-0.5010274649,
-0.0926046148,
0.1799239665,
0.1961502135,
-0.0460021347,
-0.2239573002,
-0.0784530118,
-0.0399908945,
-0.028411489,
-0.2267916203,
0.0780332908,
-0.3355456293,
0.3777337968,
-0.2270907164,
0.0828858912,
0.199916333,
0.0999194831,
0.0694880784,
0.5783312321,
-0.1174663752,
-0.1547850668,
-0.1018586755,
0.1132899672,
0.1244230866,
-0.2779651284,
0.1311748028,
0.1536537111,
0.0651947856,
-0.2290614843,
-0.2765356004,
-0.1131062433,
-0.0898820385,
0.3723524213,
-0.0653581545,
-0.0021133553,
0.2286835611,
0.2309367955,
-0.2665779293,
0.1495545506,
-0.0245584734,
0.154350698,
0.1191193685,
0.0216080695,
-0.2032078058,
0.1186943352,
0.0255145561,
0.0024888592,
0.3641911447,
-0.5120122433,
-0.1601179689,
0.1091760695,
0.3304743171,
0.2237612456,
-0.4141859114,
0.004876073,
-0.0519612692,
0.1382750571,
-0.197028771,
0.1009360701,
0.2013688684,
-0.1543413252,
0.1069994122,
0.4884464741,
-0.066707857,
-0.1569433361,
0.2526204586,
-0.2464489043,
-0.1890673935,
-0.2075237483,
0.1875148714,
0.4563150704,
-0.1995437741,
-0.0215520598,
0.0250925049,
-0.2542681992,
-0.0033975213,
-0.2268770039,
0.1088450029,
-0.1410280466,
-0.0711141974,
0.0511501431,
0.4070850313,
-0.1431524754,
0.6716794372,
0.274736613,
-0.1061241627,
0.3462600112,
0.1248759478,
0.411996305,
-0.2899011075,
0.0082234237,
-0.1618100852,
-0.2016608864,
-0.3205522597,
-0.0597425438,
-0.0991261303,
-0.2524290681,
-0.1500808895,
-0.3411163688,
-0.1103343815,
-0.19748348,
0.3263033032,
0.2165119052,
0.0866807476,
-0.3156569004,
-0.3558529019,
-0.1358784139,
0.3744935393,
-0.3475209475,
0.2406776994,
-0.1075326502,
-0.0853710175,
0.056657467,
0.419739753,
0.4956643581,
0.5411375165,
-0.2272214741,
0.1191230193,
-0.1899434924,
-0.1692602187,
0.2167115957,
-0.0417596288,
0.0832095221,
-0.237281695,
0.4266637862,
0.0453167558,
-0.0789549574,
0.0392207876,
-0.0633792132,
0.3418256342,
0.0060495962,
0.259349376,
-0.1861279756,
-0.0799423605,
-0.1165414453,
-0.4250866175,
-0.3327088952,
-0.031140551,
0.1911046803,
-0.1083030105,
0.4301498234,
-0.1041436121,
0.0725725815,
0.1260557622,
0.1583550274,
0.0804858059,
-0.2414022535,
-0.3029028475,
0.1266164333,
-0.2329008579,
0.1489236057,
-0.0738435537,
0.0942313299,
0.3174408674,
0.2936143279,
0.1269073039,
0.5428951979,
0.1896747947,
-0.5437649488,
-0.0616619587,
0.4516439438,
-0.1297641844,
-0.2992648482,
0.1582460403,
0.1177573651,
0.2715988457,
-0.3974916935,
0.1587738842,
-0.0093357945,
0.0861515701,
-0.2984752059,
0.1432154775,
-0.2239461988,
0.0976533815,
0.1143469065,
0.355127126,
0.1391007304,
-0.0397059768,
-0.3220253289,
0.1028849259,
-0.0666416213,
-0.2970434129,
0.329164207,
-0.0086506745,
0.4060952067,
-0.0201613382,
-0.1241805777,
-0.302418083,
-0.0965959504,
-0.0574228577,
-0.1799395084,
-0.5031628013,
0.1517358124,
0.0366162322,
-0.0446594842,
-0.1316052377,
0.0819318518,
0.1160841286,
0.4037001431,
-0.087922737,
-0.6108808517,
0.3436936736,
-0.4050940275,
-0.3186047673,
0.2054010481,
-0.144639492,
-0.0598355643,
0.0282274876,
-0.7085930705,
-0.1489076018,
0.3234853446,
0.0556425564,
0.0667579174,
-0.0316413976,
-0.1333048791,
0.0461416692,
-0.1505689323,
0.3275339901,
0.1958417594,
0.0350861102,
0.2054267973,
-0.2698099911
] |
https://github.com/huggingface/datasets/issues/3329 | Map function: Type error on iter #999 | Maybe this is because of the `return text` line ? I think it should return a dictionary rather than a string | ## Describe the bug
Using the map function, it throws a type error on iter #999
Here is the code I am calling:
```
dataset = datasets.load_dataset('squad')
dataset['validation'].map(text_numbers_to_int, input_columns=['context'], fn_kwargs={'column': 'context'})
```
text_numbers_to_int returns the input text with numbers replaced in the format {'context': text}
It happens at
`
File "C:\Users\lonek\anaconda3\envs\ai\Lib\site-packages\datasets\arrow_writer.py", line 289, in <listcomp>
[row[0][col] for row in self.current_examples], type=col_type, try_type=col_try_type, col=col
`
The issue is that the list comprehension expects self.current_examples to be type tuple(dict, str), but for some reason 26 out of 1000 of the sefl.current_examples are type tuple(str, str)
Here is an example of what self.current_examples should be
({'context': 'Super Bowl 50 was an...merals 50.'}, '')
Here is an example of what self.current_examples are when it throws the error:
('The Panthers used th... Marriott.', '')
| 21 | Map function: Type error on iter #999
## Describe the bug
Using the map function, it throws a type error on iter #999
Here is the code I am calling:
```
dataset = datasets.load_dataset('squad')
dataset['validation'].map(text_numbers_to_int, input_columns=['context'], fn_kwargs={'column': 'context'})
```
text_numbers_to_int returns the input text with numbers replaced in the format {'context': text}
It happens at
`
File "C:\Users\lonek\anaconda3\envs\ai\Lib\site-packages\datasets\arrow_writer.py", line 289, in <listcomp>
[row[0][col] for row in self.current_examples], type=col_type, try_type=col_try_type, col=col
`
The issue is that the list comprehension expects self.current_examples to be type tuple(dict, str), but for some reason 26 out of 1000 of the sefl.current_examples are type tuple(str, str)
Here is an example of what self.current_examples should be
({'context': 'Super Bowl 50 was an...merals 50.'}, '')
Here is an example of what self.current_examples are when it throws the error:
('The Panthers used th... Marriott.', '')
Maybe this is because of the `return text` line ? I think it should return a dictionary rather than a string | [
-0.0686894432,
-0.2696540356,
-0.0422955789,
0.365426451,
0.1748293936,
0.0543161184,
0.3326847553,
0.3805121481,
0.4761452973,
-0.0788380057,
0.108046487,
0.6700221896,
0.1724000275,
0.1302317828,
-0.1137837693,
0.0445300005,
0.0352328643,
0.0365198441,
-0.1528561115,
0.0747834668,
-0.5479354262,
0.1117565855,
-0.5292416215,
0.2950784266,
-0.0602707043,
-0.2349833995,
0.3246434629,
-0.0630757287,
-0.2050000429,
-0.2597447932,
0.3776682913,
-0.3488462567,
0.2067826837,
0.4222956598,
-0.0001198307,
-0.021417385,
0.2757882476,
-0.1344311982,
-0.1674039066,
-0.4027249217,
-0.1668154001,
0.127300337,
0.1350903809,
-0.0476554111,
0.186307773,
0.1756334305,
-0.0951390415,
-0.2074330598,
0.0714429095,
0.3829611242,
0.1463649869,
0.0415227674,
0.1084849685,
-0.0328778438,
0.2921256125,
0.2899450958,
-0.1350662559,
0.1540344507,
0.2593453526,
-0.2070976496,
-0.010116633,
0.34322384,
-0.1706829965,
-0.0185353681,
0.133487314,
0.1127288714,
0.1783594787,
-0.3939208388,
-0.1218394861,
0.0567445084,
0.4024530649,
-0.0854341239,
-0.2382612228,
0.1115022749,
-0.3359946012,
-0.2304650247,
0.1750830114,
-0.1574292481,
-0.2841139138,
-0.0882408917,
0.0640474185,
0.1897380799,
-0.1639878899,
0.2687290907,
-0.3195162714,
0.2153178453,
-0.1862250268,
0.2960482538,
0.20946154,
-0.3590484858,
0.0621649735,
0.0695941746,
0.029967308,
0.3230365515,
-0.5244164467,
-0.2967147529,
-0.0433302298,
-0.3244771063,
0.0139750941,
-0.0020879789,
0.3403279781,
0.1067572534,
-0.1048840731,
0.4679482281,
0.5031508803,
0.2587525249,
0.2151273936,
0.6259542108,
-0.0082151592,
-0.0278181061,
-0.0018058687,
-0.0587355644,
0.0579485409,
-0.0438616872,
0.1305096745,
-0.002679867,
0.1037443802,
-0.2178778201,
-0.3496312201,
0.3881900311,
-0.6481949687,
-0.0233172029,
0.0208079834,
0.2240981609,
0.1293162256,
0.3716751933,
0.193624571,
0.1535267681,
0.0474586375,
0.0579404794,
-0.0559492037,
-0.0083917789,
-0.1238334104,
-0.2050890476,
-0.0657828227,
-0.0079832813,
0.112233907,
-0.0425151102,
-0.2641533017,
-0.2337825447,
-0.0333140194,
-0.2635461688,
0.2903018594,
0.1376017332,
-0.2577501237,
0.1850930899,
0.4700308442,
-0.2674596608,
0.0070901182,
0.2651000619,
-0.4260758758,
0.1423103064,
-0.3138372004,
0.0623275489,
0.3559264541,
-0.0760887563,
-0.1244782731,
0.0187851358,
0.2621826828,
-0.3580541909,
0.1467985958,
-0.3401735127,
-0.2922205329,
-0.3617962599,
-0.1189807504,
0.2194094062,
-0.6221220493,
-0.0389918797,
0.0293041803,
0.0358476676,
0.1758061349,
0.5387279987,
-0.027573863,
0.3044305146,
-0.1009461209,
0.5126520991,
0.6534242034,
-0.1932961196,
-0.2354239374,
0.433719784,
0.1764918119,
-0.0920255855,
-0.2372618765,
0.0590565093,
0.2687616944,
-0.1063235179,
0.3505551517,
0.0853100121,
-0.0602522939,
0.0210350771,
-0.2463189214,
-0.0285328552,
0.6285741329,
-0.0312919579,
0.0662516952,
0.2341379523,
0.1091751978,
-0.3038706481,
0.1160016879,
-0.0421339646,
0.0079542482,
-0.0061195516,
0.3182276487,
0.1533881724,
0.1062121913,
-0.4123133123,
-0.1530757844,
-0.1957252324,
0.0006539677,
-0.0749985501,
-0.0927463621,
0.1757587343,
-0.3380774558,
0.2665642202,
-0.1789149791,
-0.0017920566,
0.1710319072,
-0.1624206454,
-0.0345433205,
-0.0900175795,
0.0084238164,
-0.1976235509,
-0.0918163657,
0.1329421401,
-0.2062218934,
0.0468425415,
-0.1186158583,
-0.2593173385,
-0.3106772304,
0.1256726831,
0.1530165374,
0.0889088213,
-0.2601289153,
0.1165757626,
0.1337994337,
-0.1816498339,
-0.1828386635,
0.0437923782,
0.012919426,
0.1099364534,
-0.1850356758,
0.5195547342,
0.2707524002,
-0.1836748719,
0.0756869316,
0.1500282288,
0.2233214527,
0.4773690999,
-0.3321398199,
0.4480356276,
-0.0744824111,
0.3419991434,
0.0000645174,
-0.1106877849,
-0.1086888313,
0.1357492208,
0.3433451951,
-0.1265072525,
0.0875091031,
-0.0758462846,
0.2421654761,
-0.0976881906,
0.3472974598,
0.2054653764,
-0.1678188294,
0.0364412218,
-0.0129136322,
-0.1247250512,
0.2384887487,
-0.2398754209,
-0.1754917502,
-0.1774239987,
-0.0822335705,
0.2165113389,
0.165562436,
0.302880764,
0.4274270236,
0.0294879433,
-0.0622509457,
-0.053161934,
-0.1085270643,
-0.1026845798,
-0.1050811931,
0.345813483,
-0.4162859619,
0.0549236126,
-0.0989749357,
-0.1666133404,
0.032180734,
-0.0277484506,
-0.0188246667,
-0.3745053113,
-0.2282251418,
0.276008755,
-0.0453916565,
-0.0453235246,
0.1517932713,
-0.1377372444,
0.5304302573,
0.1245195419,
-0.1101671383,
-0.3187001646,
-0.0697820783,
0.0734073967,
0.229639858,
-0.3089492619,
-0.0121020405,
0.2041167319,
-0.0496993139,
-0.3020736873,
-0.2785300314,
0.2774637043,
-0.2655279338,
0.0679735243,
0.4710847735,
0.4688961506,
-0.255195111,
-0.1711310595,
0.3395121694,
-0.0443022288,
-0.2615584731,
0.3641839325,
-0.024020955,
0.0424531363,
-0.0734408721,
-0.2972636223,
-0.1208704114,
-0.2895594537,
0.4420585334,
0.1354487687,
0.3415409923,
-0.0261902921,
0.1276108921,
0.2026836425,
-0.0591656901,
-0.221399039,
-0.3325134814,
0.0289567374,
0.1610609591,
-0.1034121215,
-0.1207233369,
-0.1969657391,
0.0480870157,
0.0319184996,
-0.0063114972,
-0.1429532021,
-0.3022880852,
-0.193232134,
0.0867403895,
-0.2359449565,
0.1855719388,
0.4573392272,
0.1276038885,
-0.0033294787,
-0.1517773867,
-0.3672043383,
0.1125623956,
0.3016621172,
0.2307992429,
0.2729856074,
0.3949265182,
0.0774123892,
0.2350447774,
0.5061241984,
-0.06455376,
0.2726331055,
0.0031984109,
-0.0892849639,
-0.1130879745,
-0.1192120537,
-0.0247559473,
-0.4626017511,
-0.1816147864,
0.094910644,
-0.1275484264,
-0.4466019273,
-0.0156847369,
0.0263481941,
-0.3497274816,
-0.2119559795,
0.1844103336,
-0.1668491811,
-0.1175272986,
-0.1358843744,
0.123840481,
-0.2549351752,
-0.0403939858,
0.1517953426,
-0.2102866173,
0.2232137173,
-0.0940588713,
-0.377617538,
-0.3682343066,
0.0383080207,
0.3707078695,
0.2272664756,
0.4374275506,
0.1043956429,
-0.1980842054,
-0.0986111239,
0.2808298767,
0.6198734045,
-0.6304344535,
-0.1281614304,
0.0961878374,
0.3682439923,
-0.2435977161,
-0.0807752237,
-0.4608486593,
0.3733655214,
0.3068775535,
0.2807028294,
-0.1548626125,
0.0929401442,
0.0494208187,
0.0252382159,
-0.0607130565,
-0.0444430076,
0.0354932509,
-0.1168767661,
-0.3962552845,
0.0942896605,
0.2499739379,
-0.0613880567,
0.3168185055,
-0.0189041216,
0.0390632339,
0.0086201839,
0.0418528765,
-0.0129677681,
0.388537854,
-0.0442512333,
-0.2450059652,
0.0584390126,
0.317185998,
-0.0882605687,
0.4315929413,
0.0496558212,
-0.1310858727,
0.3779814839,
-0.1564725488,
0.4254128635,
0.1055529714,
-0.1903722882,
0.1215769053,
-0.2144636661,
0.2291757166,
-0.1548060477,
-0.3440304995,
0.6550675631,
0.1991006285,
-0.2358645797,
-0.2472988665,
0.3096125424,
0.0246147048,
-0.1439257413,
0.5379700065,
-0.1527560502,
-0.0670778602,
0.5585805774,
0.2637791038,
0.8329238296,
-0.1223008111,
-0.0182816647,
0.1319287717,
0.3041368723,
0.2506150305,
0.0921373069,
-0.0353093669,
-0.5041998029,
0.0159716289,
-0.2555930018,
-0.1103302017,
0.0189027078,
0.1500104368,
-0.4946009517,
0.2706397772,
-0.1561525017,
0.3459858298,
0.266214788,
-0.3297909498,
0.039562393,
-0.3122586906,
-0.117851913,
0.1259550005,
0.0497557111,
0.0782866925,
0.0542887188,
-0.0266490877,
-0.0591445044,
-0.4308163226,
-0.4156930149,
0.0101940418,
-0.5635714531,
0.1518601775,
0.3701201677,
-0.0087293908,
0.1136294901,
0.4090122283,
-0.0946700275,
0.1476905495,
-0.1251595765,
-0.3167482018,
0.5444476008,
0.2484872341,
0.3135419786,
0.0897098482,
0.3176915646,
0.0380779989,
-0.1418237239,
0.1621747762,
-0.0445408486,
-0.2405178696,
-0.2450960129,
0.2069380134,
-0.0292708501,
-0.5867343545,
-0.2253366709,
-0.3705737293,
-0.2879404724,
-0.1080118716,
0.0302304644,
0.1549013555,
0.006443039,
0.2860974073,
0.1008108333,
-0.1333712041,
0.2799804211,
0.1674968451,
0.0559175164,
-0.0001479676,
0.2979211807,
0.0962811112,
-0.2989430428,
-0.1663835347,
0.0293554515,
-0.1696301699,
-0.2207196653,
0.2432866395,
-0.2431569099,
-0.2895556092,
-0.1234562472,
0.6155185103,
-0.0113946041,
0.2477861643,
-0.2975314558,
-0.5232377052,
-0.1046241298,
0.2594071329,
0.1572718322,
-0.0660125837,
-0.270057261,
-0.0181335714,
0.0299951807,
-0.0798328966,
-0.2124579251,
0.0513307117,
-0.2435932606,
0.3656306267,
-0.2124851495,
0.1173059344,
0.2154251635,
0.0604683049,
0.0437035896,
0.5847087502,
-0.0870237127,
-0.1422540247,
-0.098717764,
0.1231652722,
0.1640154272,
-0.2694338858,
0.1549953222,
0.105822511,
0.0326949134,
-0.2364876866,
-0.2516805232,
-0.0957079828,
-0.0697562248,
0.3707571626,
-0.0285642762,
-0.019159589,
0.1751294732,
0.2683777511,
-0.3110221922,
0.096715875,
-0.0370985121,
0.1545803696,
0.0880325958,
0.0179656688,
-0.1513475776,
0.2158643156,
0.0479315221,
0.0016518597,
0.4424273372,
-0.4999356568,
-0.1275092512,
0.0858154073,
0.3875506222,
0.2669038475,
-0.3764379323,
0.0264124051,
-0.0914985985,
0.1192023009,
-0.1879848987,
0.087839976,
0.2145941406,
-0.1168620959,
0.0736593753,
0.4478645623,
-0.1091697291,
-0.1936970949,
0.2108454555,
-0.2718011737,
-0.0928257182,
-0.266135186,
0.1426440775,
0.4691185355,
-0.1644005775,
-0.046671778,
0.0656015575,
-0.1586800814,
-0.0196853429,
-0.1480029225,
0.1889824271,
-0.2101446092,
-0.0576951019,
-0.0109255994,
0.3919668198,
-0.177818194,
0.6537029147,
0.2860997319,
-0.1411613226,
0.2828805447,
0.1917086095,
0.3517751098,
-0.2454634309,
0.0246988945,
-0.1662469059,
-0.246259138,
-0.3175507188,
-0.0639352873,
-0.1621630192,
-0.250921756,
-0.1042250395,
-0.332487762,
-0.1786773801,
-0.2212524861,
0.3578242958,
0.1460266709,
0.0731540024,
-0.3923001289,
-0.3335272074,
-0.2393030375,
0.3847891092,
-0.3186617792,
0.233611688,
-0.182561934,
-0.0585699752,
0.0657491088,
0.4216234386,
0.45120731,
0.5373042822,
-0.2381309271,
0.1579477936,
-0.2785579264,
-0.2003945708,
0.2033707649,
-0.0210068487,
0.0994499251,
-0.214797914,
0.4190683663,
0.0530448258,
-0.0406105034,
0.0729336962,
-0.0411160029,
0.3476885855,
0.051304426,
0.1595071703,
-0.2123768777,
-0.1451217085,
-0.1084750667,
-0.3565243781,
-0.2787147462,
-0.0237231739,
0.182480216,
-0.1020960584,
0.3940360844,
-0.1337931901,
0.062791422,
0.1143083572,
0.212292701,
0.1425061226,
-0.1645840108,
-0.285611093,
0.1250227541,
-0.2272668332,
0.1704561561,
-0.1237928495,
0.076057829,
0.268582046,
0.251578629,
0.2073664963,
0.538487792,
0.207221359,
-0.4194052219,
-0.1695019901,
0.4486179054,
-0.1397387236,
-0.4203665555,
0.156264171,
0.1148474365,
0.2145298272,
-0.3656757772,
0.1775782853,
-0.015401084,
0.0739982054,
-0.3304442167,
0.0796625763,
-0.2406959385,
-0.0169545226,
0.1637578905,
0.3390467763,
0.1789101958,
-0.0275457576,
-0.3432611525,
0.0716647059,
-0.0577352643,
-0.3128173649,
0.3302438557,
0.0445539951,
0.4066325426,
-0.0120240124,
-0.0799500123,
-0.3037147522,
-0.0767612755,
-0.0718289018,
-0.0716380924,
-0.5616915822,
0.1140361875,
0.0624180362,
-0.112741515,
-0.133185789,
0.0212298334,
0.0835701004,
0.338607043,
-0.0791474208,
-0.5717996359,
0.3505366147,
-0.3985573649,
-0.3103999197,
0.2223210782,
-0.1076737493,
-0.0920747817,
-0.0695520267,
-0.7453980446,
-0.1266731173,
0.302438736,
0.0145813534,
0.0391746461,
-0.0821742862,
-0.2075332403,
0.0465327054,
-0.1395453811,
0.3583748937,
0.1099679619,
0.0311610717,
0.1420662254,
-0.317009747
] |
https://github.com/huggingface/datasets/issues/3317 | Add desc parameter to Dataset filter method | Hi,
`Dataset.map` allows more generic transforms compared to `Dataset.filter`, which purpose is very specific (to filter examples based on a condition). That's why I don't think we need the `desc` parameter there for consistency. #3196 has added descriptions to the `Dataset` methods that call `.map` internally, but not for the `filter` method, so we should do that.
Do you have a description in mind? Maybe `"Filtering the dataset"` or `"Filtering the indices"`? If yes, feel free to open a PR. | **Is your feature request related to a problem? Please describe.**
As I was filtering very large datasets I noticed the filter method doesn't have the desc parameter which is available in the map method. Why don't we add a desc parameter to the filter method both for consistency and it's nice to give some feedback to users during long operations on Datasets?
**Describe the solution you'd like**
Add desc parameter to Dataset filter method
**Describe alternatives you've considered**
N/A
**Additional context**
N/A
| 80 | Add desc parameter to Dataset filter method
**Is your feature request related to a problem? Please describe.**
As I was filtering very large datasets I noticed the filter method doesn't have the desc parameter which is available in the map method. Why don't we add a desc parameter to the filter method both for consistency and it's nice to give some feedback to users during long operations on Datasets?
**Describe the solution you'd like**
Add desc parameter to Dataset filter method
**Describe alternatives you've considered**
N/A
**Additional context**
N/A
Hi,
`Dataset.map` allows more generic transforms compared to `Dataset.filter`, which purpose is very specific (to filter examples based on a condition). That's why I don't think we need the `desc` parameter there for consistency. #3196 has added descriptions to the `Dataset` methods that call `.map` internally, but not for the `filter` method, so we should do that.
Do you have a description in mind? Maybe `"Filtering the dataset"` or `"Filtering the indices"`? If yes, feel free to open a PR. | [
-0.1674710065,
0.142106086,
-0.1380548179,
-0.3212193847,
0.1586352289,
-0.21651645,
-0.0088287583,
0.2359305024,
-0.1663409323,
0.3248026073,
0.245251447,
0.4766329825,
0.0076421858,
0.0727190673,
-0.0954583138,
0.0160770603,
-0.1457529068,
0.0721857771,
-0.15230079,
0.1824496239,
-0.2857272327,
-0.1695175022,
0.0116491485,
-0.3042528927,
0.1169238091,
0.1494061351,
-0.0654754862,
-0.1314251274,
-0.1852973402,
-0.5306233168,
0.3423238993,
0.640871048,
0.0924040824,
0.3349265158,
-0.0001124304,
-0.1106166691,
0.3982707858,
-0.078164719,
-0.0093144346,
-0.1041739509,
-0.5723861456,
-0.3134420216,
-0.0352412313,
-0.3201679885,
-0.0046513565,
0.3851122856,
-0.189924106,
-0.2564955652,
-0.0191109609,
0.1380065084,
0.2009866685,
-0.1863255203,
-0.4003852606,
-0.0136288973,
0.0284710042,
0.4224472642,
-0.1031910181,
0.0401758775,
0.7769063115,
0.0575910062,
0.0454163626,
0.0922719985,
-0.0856381804,
-0.2676769495,
0.3400927782,
-0.3047853708,
0.2267853767,
-0.3885222971,
0.2781976759,
0.1810555607,
0.630396843,
-0.0082096783,
-0.3585575223,
0.0792776123,
-0.0362212174,
-0.091459468,
-0.1972588003,
-0.2013964951,
-0.0789637938,
0.1084913686,
-0.3245031238,
-0.2121682763,
-0.1631360501,
-0.0280030835,
-0.14893727,
0.0738541558,
-0.086237669,
0.0371796861,
0.0263865832,
-0.0372697972,
0.1001533121,
-0.3646297753,
0.1202353016,
0.1487910002,
0.128113538,
-0.3785377145,
0.353380233,
0.123947382,
0.1833367348,
0.061748676,
-0.0448162705,
0.0917043984,
0.075462155,
0.0777844563,
0.0738049597,
-0.0071983142,
0.3873306215,
0.2677339315,
0.071726054,
-0.2746638656,
-0.2938988209,
-0.0641229004,
0.4338411987,
0.0020196771,
0.208681494,
0.3344275057,
-0.0012460215,
-0.316060245,
-0.1287142187,
0.0259850714,
-0.0291957203,
-0.2100203037,
0.1387862116,
0.0233088061,
0.336845845,
0.3451471329,
0.0074323174,
-0.1927708536,
0.172575742,
-0.1435660869,
-0.0342976265,
-0.1022073999,
-0.165438652,
0.1071850136,
0.0343046561,
-0.3031308055,
0.1160977632,
0.0175514016,
0.0346851982,
0.1440613568,
-0.2213891298,
-0.0551855601,
0.1995571703,
0.2036174685,
-0.6181794405,
-0.096079275,
-0.0322420113,
0.0491284169,
-0.3058193922,
0.3823823035,
-0.262670666,
-0.2246118784,
0.0913684964,
0.1761587411,
0.1900539249,
-0.0032818052,
0.1150834709,
0.4863202572,
-0.2339704633,
-0.4342997372,
0.1795629561,
-0.0475094318,
-0.4801170826,
-0.3479689956,
0.032632228,
0.2744628787,
-0.6401584744,
-0.0884059742,
-0.4904251993,
0.2578168511,
0.2415652722,
-0.0414679386,
-0.421245575,
0.0512775816,
0.1939626634,
0.214810282,
0.3879468441,
0.2406774014,
-0.4552801847,
0.3321771026,
-0.1109879389,
0.0511209965,
0.1218798086,
0.0672897473,
0.5852992535,
-0.3640656471,
0.176237449,
-0.0098972702,
-0.5318036675,
-0.0853492841,
-0.2202703208,
-0.0516466871,
0.3398789763,
-0.0315624438,
-0.0340849832,
0.1516623497,
0.3435986638,
-0.4623871744,
0.0688613355,
0.0710442886,
-0.0970236659,
0.0535932183,
0.5854914784,
0.0446237922,
-0.1393261403,
-0.2971012592,
-0.2534727156,
0.1182588637,
0.1055416241,
-0.3534532487,
0.2817750275,
-0.344737649,
-0.1351424158,
0.0010097956,
0.2822403014,
-0.0932579637,
0.0383084342,
-0.1354161501,
-0.1001804024,
-0.0847550109,
-0.1314861029,
-0.0863404423,
-0.0701226965,
-0.2698421776,
0.3621353805,
0.220550403,
0.0068535516,
-0.0113861095,
-0.2304554135,
0.0423479863,
0.20532763,
-0.0162834488,
-0.2285887897,
0.221137315,
0.1654392481,
-0.1939373463,
0.0875818357,
0.4406787455,
0.2429720908,
-0.0085685533,
0.0347018801,
0.3684096038,
0.1853279918,
-0.1275826097,
-0.2718522847,
0.2854013145,
-0.0000250504,
0.1827350557,
-0.0067371889,
0.079347536,
0.196776256,
-0.054790277,
-0.2289996147,
-0.0925006568,
0.0031696903,
0.3329575062,
-0.082957752,
0.3037770092,
-0.182939887,
0.1714221686,
0.3942765296,
-0.0329217054,
-0.0311594643,
0.2602731287,
0.262679249,
-0.0084973834,
0.268945992,
0.2897144854,
0.5145267248,
0.3207743168,
-0.2099420875,
-0.120312646,
0.2034094185,
0.0565714315,
0.2535464466,
0.1709093899,
0.1578359604,
-0.0918360502,
0.075181745,
0.2780884802,
0.013074561,
-0.2410780042,
0.189786166,
-0.1885933131,
0.0241643768,
-0.0633945614,
-0.1501569003,
-0.1820197105,
0.1206789985,
-0.0977460295,
-0.0727604032,
-0.2602565587,
0.0857534707,
-0.0105476584,
-0.3353481889,
0.1941446513,
-0.4066914618,
0.6620488167,
-0.0218164939,
-0.1180647686,
-0.1584096104,
-0.0623268634,
-0.1256647408,
-0.0036623627,
0.0254115108,
-0.0591929443,
0.4129063785,
0.5201870799,
0.3952544928,
-0.3922027647,
-0.7190428376,
-0.1860089004,
0.1413691938,
0.3410422206,
0.1056767926,
0.1096697673,
-0.1139928773,
-0.1750717461,
0.007892359,
-0.0568625852,
-0.0029212548,
-0.2036907971,
0.0618816204,
0.0115369903,
-0.2544606626,
-0.1515232921,
-0.2735767365,
-0.3845652938,
-0.1063531339,
-0.6283183098,
0.2063052952,
0.193056345,
-0.0818891153,
-0.1761064678,
-0.1484766454,
-0.058479324,
-0.1223751903,
-0.2285999209,
0.2185805589,
-0.1834227443,
-0.0817580819,
-0.2243817449,
-0.1812812239,
-0.0226113517,
0.3782036304,
-0.0370413363,
-0.2549468577,
-0.2389411181,
0.3893620074,
0.0703996345,
0.010055555,
0.5757449865,
0.0258769803,
-0.0952555388,
-0.043584872,
-0.7750329375,
-0.0391416848,
0.6759197116,
0.2116874009,
0.2700701058,
0.7928593159,
0.0600332506,
0.5650781393,
0.0370886438,
-0.1039232835,
0.3114770353,
0.2859172225,
0.2529326677,
-0.0563682355,
-0.4529520273,
0.1668881476,
0.0519063361,
-0.1882973462,
0.205563426,
-0.0087764813,
-0.3153162897,
0.1519219428,
-0.2178901732,
-0.0668112114,
-0.2298629433,
0.0126300678,
0.002782674,
0.4932941198,
-0.1299946904,
-0.0386294946,
-0.2027530968,
0.1347269118,
0.0183779281,
0.1802012026,
0.4544935226,
-0.2125132084,
-0.2000350356,
-0.1254374981,
-0.230574742,
0.2458508909,
0.3314680159,
0.1141684279,
-0.2801675797,
0.0657033771,
-0.1924522072,
0.2406941205,
0.7477208972,
-0.52922225,
-0.2145163566,
0.0259946603,
-0.3189592659,
-0.2657389045,
0.0460389145,
0.2910635769,
0.4161969721,
0.1629085392,
-0.1058057919,
-0.1951509565,
0.0228740592,
0.0612969063,
-0.1923942268,
0.0402696803,
-0.2254033536,
0.3078079224,
-0.1192773059,
0.0149316443,
0.0041038133,
0.0942034125,
0.04999917,
0.1094249189,
-0.1974456757,
0.2463386208,
-0.1589716524,
0.2211073935,
-0.1760585457,
0.0886990279,
0.4882602394,
0.1549446434,
-0.1867298484,
-0.033819668,
0.0779202133,
0.2467401326,
-0.3495524824,
-0.1697121114,
-0.1183996797,
-0.036320433,
0.5829600096,
0.2999675274,
0.2104944587,
0.3303306401,
0.0542146713,
0.0558883622,
-0.1873015463,
0.0037215841,
-0.0747922808,
-0.0111042103,
-0.279571265,
-0.479142338,
0.4231778085,
0.0915989131,
-0.1325959861,
0.4220628142,
0.3556714952,
-0.3571288884,
0.0627147406,
0.0114052435,
0.741102457,
0.2554354072,
-0.3337070942,
-0.3776116073,
-0.2032449096,
-0.0415001586,
0.3497535586,
-0.1329996288,
0.1716661751,
-0.335791111,
-0.0593266264,
-0.01112743,
0.4307461381,
0.2322163284,
-0.3475330174,
0.228230834,
0.0386469513,
0.0959669948,
0.3614650965,
0.2389322519,
-0.0510819592,
-0.1073411852,
0.3052011132,
0.1736231148,
-0.1473145038,
-0.2020280659,
0.0821554437,
-0.1811840087,
0.380076468,
-0.1312827468,
-0.2126290053,
-0.2832837701,
-0.5943075418,
0.2044813782,
0.02854155,
-0.0865871757,
0.4990255535,
-0.2086564004,
-0.2552304566,
0.1673956215,
-0.0318370014,
0.2002895921,
0.1674366593,
0.4596487284,
0.0310974438,
-0.160385102,
0.321375519,
0.1223514602,
-0.0046257661,
0.1685011089,
-0.002676015,
-0.5984879732,
-0.2744723856,
-0.1669736505,
0.3069955409,
-0.1207563058,
-0.2682993114,
0.0094312476,
-0.1549690366,
-0.066460155,
0.1151769757,
0.1382785738,
-0.0295161027,
0.5042107105,
-0.0778312758,
0.0283411164,
-0.0703683197,
-0.0633242503,
-0.2306769043,
0.0235213172,
0.0474065915,
-0.2809295952,
-0.2130712122,
-0.108746849,
0.0534041934,
0.0724463761,
0.2511065602,
0.1888828874,
-0.1940910071,
0.0799156129,
0.1827572137,
0.1497885734,
-0.0167108867,
0.1340551525,
-0.3087008893,
-0.122170195,
-0.2381773591,
-0.0234782584,
-0.1832217425,
0.2500422597,
-0.3270530701,
-0.0920480043,
-0.0151152359,
0.026177397,
-0.3392027617,
0.0019795555,
0.2592105269,
0.2608147264,
-0.0496385135,
0.3214573264,
-0.2342150807,
-0.1748261154,
0.0001850612,
0.2062969655,
-0.0504080653,
-0.1757787913,
0.026244862,
0.1163282618,
0.0057054753,
0.1684745252,
0.0318205468,
-0.1782764494,
-0.1147535369,
-0.0349688716,
0.0146524459,
-0.0086925346,
-0.1229169294,
0.0369510725,
0.1227367818,
-0.2957409322,
0.0918803364,
0.3713128865,
0.0391606428,
0.2213120013,
0.1012632325,
0.3325421214,
-0.0016208951,
-0.0416490585,
-0.0331823453,
0.1158358455,
-0.0071658511,
-0.2119295895,
0.1141415983,
0.1182101592,
0.2022184134,
0.7615479231,
0.0660026148,
-0.2055196911,
-0.3670697808,
0.2325706631,
0.2035418302,
0.2610616982,
-0.0105795125,
0.0419625789,
0.0765610486,
0.1557220668,
0.2152647227,
0.0404814258,
0.0103760036,
0.0479821004,
0.4257829487,
0.114711985,
0.1232079491,
-0.1540426761,
0.3795346022,
0.3643082082,
0.4355721474,
-0.0837876201,
0.3571828306,
0.1140478253,
-0.0359805301,
0.0290803183,
0.3456870019,
0.552698493,
0.2250950038,
0.0228013173,
0.4615370929,
-0.0738750622,
0.2255276889,
0.1969069839,
-0.1867161542,
0.2655589879,
0.3324671686,
-0.533100903,
-0.1534133852,
-0.274544239,
-0.0026206223,
-0.0788486004,
0.0122361425,
0.2135664672,
-0.1093504727,
-0.0837662071,
0.2663630843,
-0.0575927831,
0.0500068627,
-0.0792433545,
0.5186280012,
-0.0635706261,
-0.1355909258,
0.0517761558,
-0.2229354233,
-0.1209927574,
0.2934196889,
-0.1670712978,
-0.2024569213,
-0.1881453246,
-0.1823447347,
0.3540041149,
0.3836996257,
-0.0686790347,
0.2985633612,
-0.1129382327,
0.011470505,
-0.0029895641,
-0.2022402287,
0.0759300813,
0.0583098046,
-0.1873761863,
-0.0004158092,
-0.1120464727,
0.1615150869,
-0.0029322805,
0.0095904609,
-0.00558407,
0.298986882,
-0.4855259061,
0.1430779099,
0.6264703274,
0.00175396,
0.1273319423,
0.0754813179,
-0.1872234344,
-0.5071869493,
0.4477393627,
-0.2034418136,
-0.0455765352,
-0.0239120238,
0.1004607677,
-0.1788469702,
-0.1175327748,
0.0127185155,
-0.2336939424,
-0.3180121183,
-0.2447842956,
-0.2803399265,
-0.4860261679,
0.2912373841,
-0.0251888949,
0.4476601481,
0.0708586425,
0.0687674806,
0.0804629028,
0.1056572646,
-0.5820744038,
0.0299808551,
-0.1195450947,
-0.3621098101,
-0.0373122804,
0.1480469853,
-0.0119084902,
0.0574415959,
-0.0851607844,
0.1060508266,
-0.1281023026,
0.0495574288,
-0.313557893,
0.2372736186,
0.251665771,
0.4351767004,
0.0554939955,
0.007681617,
0.2239095718,
-0.0424687564,
0.2263104767,
0.1052959859,
0.0858170018,
-0.1471227705,
-0.0151811885,
-0.1062234044,
0.2756789029,
-0.2147732079,
-0.3290961683,
-0.1847343445,
-0.2036855072,
-0.1931264848,
0.0329504646,
-0.1344057471,
-0.1688385159,
-0.0009421725,
-0.103323929,
-0.1880442053,
0.1785890162,
0.0954537988,
0.1434054226,
-0.0176690388,
-0.222380653,
0.4956980944,
-0.3262889087,
-0.3003206253,
-0.2647593021,
0.2706447244,
-0.5723387003,
0.1840032786,
-0.1106371358,
-0.4702550173,
0.4095806181,
-0.2086217403,
-0.1416306496,
0.3902414441,
-0.0809069797,
0.1026256233,
-0.0697651207,
0.1437059492,
-0.0027658532,
-0.1407523453,
-0.2154289931,
-0.1316106617
] |
https://github.com/huggingface/datasets/issues/3317 | Add desc parameter to Dataset filter method | I'm personally ok with adding the `desc` parameter actually. Let's say you have different filters, it can be nice to differentiate between the different filters when they're running no ? | **Is your feature request related to a problem? Please describe.**
As I was filtering very large datasets I noticed the filter method doesn't have the desc parameter which is available in the map method. Why don't we add a desc parameter to the filter method both for consistency and it's nice to give some feedback to users during long operations on Datasets?
**Describe the solution you'd like**
Add desc parameter to Dataset filter method
**Describe alternatives you've considered**
N/A
**Additional context**
N/A
| 30 | Add desc parameter to Dataset filter method
**Is your feature request related to a problem? Please describe.**
As I was filtering very large datasets I noticed the filter method doesn't have the desc parameter which is available in the map method. Why don't we add a desc parameter to the filter method both for consistency and it's nice to give some feedback to users during long operations on Datasets?
**Describe the solution you'd like**
Add desc parameter to Dataset filter method
**Describe alternatives you've considered**
N/A
**Additional context**
N/A
I'm personally ok with adding the `desc` parameter actually. Let's say you have different filters, it can be nice to differentiate between the different filters when they're running no ? | [
-0.1440145373,
0.0003157938,
-0.1841550171,
-0.2966308594,
0.1535660923,
-0.2308935076,
0.0006400757,
0.0876240283,
0.0169918686,
0.4104134738,
0.2275137007,
0.3330960274,
-0.0531127267,
0.1219301149,
-0.1807418466,
-0.0010676922,
-0.2211546749,
-0.0066084312,
0.1080233678,
0.0953581631,
-0.1777178049,
-0.3088025153,
0.124988921,
-0.4366923273,
0.1198822856,
0.1853335798,
-0.0819590092,
-0.1352543533,
-0.163930878,
-0.5256620049,
0.3446744084,
0.5576266646,
0.0535383597,
0.2564477026,
-0.0001135859,
-0.1133130118,
0.4805072248,
-0.1292216927,
-0.033868663,
0.0383368321,
-0.5301124454,
-0.3138316572,
-0.0540589951,
-0.3535218537,
-0.0294891354,
0.598110795,
-0.2070549726,
-0.3096200526,
-0.1465797871,
0.1479200423,
0.2233923078,
-0.2182778865,
-0.4575056136,
0.0277706143,
-0.0196627118,
0.5463713408,
-0.1898923367,
0.0116094034,
0.7884312272,
0.0781365186,
0.0281096846,
0.0103451824,
0.048218973,
-0.3222739398,
0.2214971036,
-0.2680912614,
0.2582540512,
-0.2495917082,
0.283282131,
0.0482523851,
0.5296273828,
0.0470029265,
-0.360160023,
0.0762521252,
0.0632599965,
-0.2518523932,
-0.2971221209,
-0.1199803576,
-0.1185442433,
0.1259621084,
-0.2401591241,
-0.329215616,
-0.2043175846,
-0.0100089265,
-0.0675116181,
0.0373993553,
-0.0940099061,
0.0674530044,
-0.1200446561,
0.0946528539,
0.1461138427,
-0.4164753556,
0.1193611249,
0.1108800843,
0.0474691428,
-0.4299179912,
0.3520987928,
0.2106244713,
0.0937765688,
0.2312268317,
-0.2026025057,
-0.0993532166,
0.1086923778,
0.0807358623,
0.0456036963,
-0.0438662544,
0.4379767478,
0.2069619,
-0.0242262706,
-0.4684051871,
-0.2331517935,
-0.1306373924,
0.4602924883,
0.0897851735,
0.299094975,
0.2238934934,
-0.0140394643,
-0.3715575635,
0.0144300368,
-0.048730202,
0.1152924597,
-0.2191619128,
0.1632808149,
0.0582015365,
0.3037544191,
0.3774535954,
-0.0522525758,
-0.1807083488,
0.2116978019,
-0.100380078,
-0.059040904,
-0.0534902997,
-0.1435231864,
0.1489667743,
0.0707462505,
-0.3321255147,
0.0491604879,
0.0404895097,
-0.0691014752,
0.1003171504,
-0.2362867296,
-0.0857726634,
0.0344366208,
0.2041617185,
-0.5078454614,
-0.0482640751,
-0.0165925771,
0.0610650703,
-0.2752891183,
0.3921110332,
-0.3343831301,
-0.1993625909,
0.0325706676,
0.1790118068,
0.2498300225,
0.0094070416,
0.1327998191,
0.4285052717,
-0.175505206,
-0.3317282498,
0.1346618682,
-0.0096634421,
-0.5765014291,
-0.37065503,
-0.1282363534,
0.2092295587,
-0.6106874943,
-0.1611407548,
-0.5969171524,
0.1944942921,
0.3304447234,
0.0702305883,
-0.3924800754,
0.0942062661,
0.190365091,
0.2160069793,
0.5251375437,
0.2272520065,
-0.3510282338,
0.4137546718,
-0.1377093494,
0.0222618878,
0.1788310558,
0.1650666296,
0.4517053068,
-0.2743810117,
0.2302105278,
-0.0120407054,
-0.5472555757,
-0.1170944646,
-0.2304594666,
0.0403252244,
0.3741796613,
0.0466339327,
0.0430169888,
0.2504470944,
0.4532701671,
-0.3723931909,
0.096994102,
0.1125104278,
-0.142833814,
0.0336756594,
0.6735200286,
0.1041056365,
-0.1718372256,
-0.2886455953,
-0.0228832029,
0.0843617693,
0.1368341446,
-0.4441721439,
0.3426164389,
-0.3296678066,
-0.1403558105,
0.1151213944,
0.3602661788,
0.0251350533,
-0.0118335411,
-0.1385123134,
-0.0421645753,
-0.0077972063,
-0.0992517322,
-0.0272079427,
-0.1675532013,
-0.3018518388,
0.4546539485,
0.2324675769,
0.0337534212,
0.0091088591,
-0.2200982571,
-0.008985891,
0.1590995044,
0.0651149377,
-0.1995685697,
0.0769364908,
0.2070224136,
-0.3075038195,
0.1418099105,
0.3447070718,
0.1908727139,
0.0960710645,
0.0394720919,
0.2717526555,
0.2135330737,
-0.223858431,
-0.2000665963,
0.3168966174,
0.0188195352,
0.1871638596,
-0.0402045473,
0.0382504687,
0.2027846575,
-0.091487214,
-0.121208176,
0.0381807722,
0.1262207329,
0.2739628851,
-0.0678339824,
0.2380089462,
-0.3032865822,
0.0592828728,
0.3916707337,
-0.0610111244,
0.0013313863,
0.2145424932,
0.355715096,
0.0187966246,
0.3013975322,
0.1045395508,
0.6633807421,
0.3780917823,
-0.3329170942,
-0.0906171799,
0.1440408528,
0.0102087688,
0.15585953,
0.0379099026,
0.1343834847,
0.0143725844,
0.1460659951,
0.1643105149,
-0.024506256,
-0.261996001,
0.1512045413,
-0.152573511,
-0.0248551778,
-0.1179585755,
-0.0319395848,
-0.2548584938,
0.0828656331,
0.0382399037,
-0.0475034863,
-0.2251360863,
0.1118846908,
-0.0113220662,
-0.1743755043,
0.1434075683,
-0.5808547735,
0.7539008856,
-0.0037874267,
-0.0727356374,
-0.1565187722,
-0.0483389497,
-0.0444693677,
-0.0035385718,
0.0026924696,
-0.1408230215,
0.4450821579,
0.5670287013,
0.4446264505,
-0.3200171888,
-0.6354638338,
-0.2402632982,
0.1970529705,
0.3251100481,
-0.0395514369,
0.0858699083,
-0.0315665789,
-0.2223169059,
-0.0151802478,
0.1184143201,
0.0156180728,
-0.2286011577,
0.156126529,
-0.0547606312,
-0.2341267765,
-0.0453408398,
-0.3063183427,
-0.2547656298,
-0.07344345,
-0.5645943284,
0.1724328101,
0.1385496557,
-0.1242658794,
-0.2633371949,
-0.1780648232,
-0.0698620602,
-0.134207949,
-0.2411992401,
0.1913296431,
-0.2084333152,
-0.1073038056,
-0.1783064902,
-0.0993311405,
-0.0374904871,
0.2209032923,
-0.137020275,
-0.2050614208,
-0.2075354159,
0.3136277795,
0.0403079391,
-0.0852278173,
0.4583538473,
-0.1145318598,
-0.0107411118,
-0.0075518577,
-0.6940286756,
0.0204145219,
0.5754425526,
0.3214512467,
0.2012033761,
0.770693481,
0.0037768069,
0.5633330345,
-0.0860630497,
-0.0484082438,
0.324965775,
0.2396712005,
0.2387044728,
-0.0028287929,
-0.5533900857,
0.2658074498,
0.1160795987,
-0.2417924553,
0.1266340166,
0.0312784314,
-0.3416204154,
0.1498994678,
-0.3129273057,
0.0421204939,
-0.1396993697,
-0.0541448183,
0.0182789657,
0.4185749292,
-0.2076976597,
-0.0548560396,
-0.1852289736,
0.1697445661,
-0.01472132,
0.2590861619,
0.3578290343,
-0.2242805809,
-0.2489860654,
-0.1024069712,
-0.188153401,
0.1302921772,
0.2465630025,
0.1167277247,
-0.2758958042,
0.2056456357,
-0.149271816,
0.2434996516,
0.6622828841,
-0.4819225073,
-0.1955074668,
-0.0017662782,
-0.3046924472,
-0.2840260565,
0.0577979684,
0.318245858,
0.3154758513,
0.1627221853,
-0.2107483745,
-0.1817200631,
0.0852601826,
0.0595985353,
-0.211915195,
-0.085772343,
-0.3107109964,
0.3488435745,
-0.0887175053,
0.041671373,
0.0242285486,
0.0058338162,
0.170053184,
0.197694242,
-0.1333577484,
0.0857830495,
-0.1235962287,
0.2537927032,
-0.2877511382,
-0.1033159494,
0.3831244409,
0.1725616455,
-0.461551249,
0.1848730147,
-0.1027844697,
0.1673026383,
-0.2469273508,
-0.1669940948,
-0.038078513,
-0.0272210892,
0.6521240473,
0.2245443761,
0.1790134758,
0.5352819562,
-0.0751798227,
0.0779466033,
-0.1217432544,
0.0043268111,
-0.0872501209,
-0.0475238115,
-0.3374848962,
-0.3350776434,
0.3306462765,
-0.0151065402,
-0.0782359168,
0.3758034706,
0.2898540199,
-0.32661286,
0.0344630033,
-0.1363660395,
0.722648561,
0.2722493112,
-0.3496514261,
-0.4125066698,
-0.1996011436,
-0.0852092654,
0.3742429912,
-0.1491785645,
0.140542686,
-0.279204309,
-0.0269708354,
-0.0124735013,
0.4287956357,
0.2239040285,
-0.2040766627,
0.238585338,
-0.0628137514,
-0.0779285207,
0.2989547849,
0.3804626167,
0.024964964,
-0.0505065136,
0.3415360153,
0.1667784005,
-0.1208796725,
-0.1669295579,
0.1141616553,
-0.0715768933,
0.3761055171,
-0.0906384438,
-0.2229423374,
-0.2056190073,
-0.5178725123,
0.2002349794,
-0.0038646222,
-0.0260934699,
0.4956528842,
-0.2666839957,
-0.2921866179,
0.2234986573,
-0.0554544255,
0.2565873563,
0.0920306295,
0.4039792717,
0.0099129509,
-0.1086758375,
0.2080047727,
0.0478110686,
-0.0162077993,
0.26374349,
-0.0055341846,
-0.6359975338,
-0.3446313143,
-0.129589811,
0.262629807,
-0.1654107869,
-0.3657902777,
0.016287379,
-0.0157184005,
-0.009089035,
0.1209095269,
0.1740185469,
-0.0056664892,
0.5276472569,
-0.049948249,
0.0505638085,
-0.1306522638,
-0.062096633,
-0.142828539,
-0.0149986651,
0.0002445591,
-0.3704751134,
-0.2402049899,
-0.041999422,
0.0128121916,
0.0156497806,
0.2253739983,
0.0613827482,
-0.1306575388,
0.214491114,
0.1308835596,
0.0350301936,
-0.049687665,
0.2059446275,
-0.3033424616,
-0.0964910313,
-0.1212293357,
-0.1160334647,
-0.1698407531,
0.161641404,
-0.3428654075,
-0.03578436,
-0.137364924,
0.108865574,
-0.3114485741,
-0.1409906745,
0.3263044953,
0.2208289355,
-0.0626882538,
0.3527595997,
-0.2193501145,
-0.1936778724,
0.0813051015,
0.1084939763,
0.0914124176,
-0.1637751311,
0.076899223,
0.118564412,
0.0716065094,
0.3172790408,
-0.0000919524,
-0.2430571616,
-0.0884742588,
0.129932493,
-0.0745690465,
0.0793146715,
-0.1791337281,
-0.0877405852,
-0.0474682227,
-0.3672601283,
0.0202883221,
0.4224133492,
0.0901066437,
0.2437435687,
0.055464834,
0.3183376193,
0.043912597,
-0.0174186584,
0.027119847,
0.0545210615,
-0.0768177211,
-0.1881606877,
0.1550999582,
0.1366292536,
0.2682478726,
0.6486820579,
-0.010374343,
-0.2726184726,
-0.3714873195,
0.2911131978,
0.1740074158,
0.2599224448,
-0.0206289776,
0.0552192219,
0.0663428828,
0.14508304,
0.1363656819,
0.112122342,
-0.0830631033,
0.1754499823,
0.4104858637,
0.0404529199,
0.0417669527,
-0.0542826727,
0.1832971871,
0.3988536894,
0.4566521645,
-0.0370550081,
0.4138461947,
0.1529592872,
-0.1069606841,
0.0519869886,
0.3100071847,
0.5486305356,
0.0812594071,
-0.0534059331,
0.3338416219,
0.0026811333,
0.2101965994,
0.0755219236,
-0.30268085,
0.2804388404,
0.2271802425,
-0.6631467938,
-0.0540095419,
-0.2999446988,
0.0281994008,
0.0532863438,
0.0017547483,
0.1883640885,
-0.1206240132,
0.0070439447,
0.2516857684,
0.014538032,
0.1147569939,
-0.0199927855,
0.3447187245,
-0.0634330064,
-0.1552470922,
0.163778618,
-0.1662313193,
-0.0034259686,
0.3076841235,
-0.1251728833,
-0.2392341495,
-0.319399178,
-0.1515730917,
0.3614566624,
0.2809164226,
-0.1406048089,
0.2987117171,
0.1593149751,
-0.0653880015,
0.0852743983,
-0.1988334805,
0.1092904881,
0.0635107979,
-0.1424201578,
0.1439920962,
-0.070947051,
0.1673957556,
-0.0026325646,
0.0963753611,
-0.0035640181,
0.2056857347,
-0.6024553776,
0.2360689938,
0.554736197,
0.0167660303,
0.0334445648,
0.2027185857,
-0.1303570718,
-0.4353339672,
0.4465720057,
-0.1899175793,
-0.071334973,
-0.075641267,
0.0911174938,
-0.2378615588,
-0.2158131599,
-0.0013972834,
-0.1685079932,
-0.2964971066,
-0.1970273256,
-0.1878118068,
-0.4666915238,
0.221822992,
-0.0773917511,
0.3563058078,
0.0941067338,
0.0018727394,
0.0793373808,
0.0294582676,
-0.5522208214,
0.0481839217,
-0.1326051354,
-0.3822383285,
-0.0703578964,
0.202017501,
-0.0432301834,
0.0616697036,
-0.0860286579,
0.1807695329,
-0.1041638926,
0.0481657572,
-0.3057938218,
0.2932295799,
0.2132925391,
0.3334720135,
-0.0179650541,
-0.1227501482,
0.2824059427,
0.0057334946,
0.3121400177,
0.2292236984,
0.0194574781,
-0.1263726056,
-0.0795002729,
-0.0444794409,
0.2988438606,
-0.129609108,
-0.339232862,
-0.1141235232,
-0.0203290135,
-0.1789478362,
-0.0723821744,
0.0462571047,
-0.1433252245,
0.0014029208,
-0.0269238707,
-0.182096377,
0.0484460071,
0.0308373161,
0.2413413972,
0.0461013727,
-0.0846820101,
0.4177028835,
-0.2610942423,
-0.2140738368,
-0.2387384176,
0.3140763342,
-0.4705476761,
0.2077988088,
-0.0742526427,
-0.5415742397,
0.4401693642,
-0.1865823269,
-0.0390147045,
0.4335455894,
-0.1151584089,
0.1320946515,
-0.0046098353,
0.026153082,
-0.0891869888,
-0.1215062439,
-0.169331193,
-0.0873914212
] |
https://github.com/huggingface/datasets/issues/3317 | Add desc parameter to Dataset filter method | @mariosasko the use case is filtering of a dataset prior to tokenization and subsequent training. As the dataset is huge it's just a matter of giving a user (model trainer) some feedback on what's going on. Otherwise, feedback is given for all steps in training preparation and not for filtering and the filtering in my use case lasts about 4-5 minutes. And yes, if there are more filtering stages, as @lhoestq pointed out, it would be nice to give some feedback. I thought desc is there already and got confused when I got the script error. | **Is your feature request related to a problem? Please describe.**
As I was filtering very large datasets I noticed the filter method doesn't have the desc parameter which is available in the map method. Why don't we add a desc parameter to the filter method both for consistency and it's nice to give some feedback to users during long operations on Datasets?
**Describe the solution you'd like**
Add desc parameter to Dataset filter method
**Describe alternatives you've considered**
N/A
**Additional context**
N/A
| 96 | Add desc parameter to Dataset filter method
**Is your feature request related to a problem? Please describe.**
As I was filtering very large datasets I noticed the filter method doesn't have the desc parameter which is available in the map method. Why don't we add a desc parameter to the filter method both for consistency and it's nice to give some feedback to users during long operations on Datasets?
**Describe the solution you'd like**
Add desc parameter to Dataset filter method
**Describe alternatives you've considered**
N/A
**Additional context**
N/A
@mariosasko the use case is filtering of a dataset prior to tokenization and subsequent training. As the dataset is huge it's just a matter of giving a user (model trainer) some feedback on what's going on. Otherwise, feedback is given for all steps in training preparation and not for filtering and the filtering in my use case lasts about 4-5 minutes. And yes, if there are more filtering stages, as @lhoestq pointed out, it would be nice to give some feedback. I thought desc is there already and got confused when I got the script error. | [
-0.2420123369,
0.0004968568,
-0.1222747043,
-0.3864940405,
0.2071845084,
-0.2034219503,
-0.028897021,
0.1976792365,
0.0098760705,
0.3720795214,
0.3573766947,
0.2891174555,
-0.1399621069,
0.1705904007,
-0.0199872553,
0.0162452497,
-0.2642205358,
0.004869265,
0.014310305,
0.1486532688,
-0.1362440586,
-0.2062540501,
0.0092582675,
-0.3489800394,
0.0622921214,
0.1651374996,
-0.0439625196,
-0.0239800885,
-0.119674027,
-0.5836008787,
0.3514052927,
0.5766952038,
0.1018213406,
0.2914175391,
-0.0001198708,
-0.1571932137,
0.498985827,
-0.1870966554,
-0.0468227863,
0.0236523673,
-0.4558932781,
-0.2083767802,
-0.0585701987,
-0.3739924133,
-0.0212255884,
0.6213818192,
-0.1498724222,
-0.305501461,
-0.0062551969,
0.2434306294,
0.1409455836,
-0.1353399903,
-0.5018041134,
0.0519165099,
-0.05261131,
0.6134558916,
-0.1427365541,
0.0325454138,
0.7971282005,
-0.0579327755,
0.0324476622,
-0.0002970409,
-0.0686488673,
-0.4227455854,
0.2892583609,
-0.2626782656,
0.2746374309,
-0.3409282565,
0.3099019527,
0.0693507493,
0.5661198497,
-0.0376664586,
-0.3603061736,
0.0954780653,
0.0971266404,
-0.2942422926,
-0.3372423053,
-0.1513126493,
-0.1434044689,
0.1939776093,
-0.2696771622,
-0.2105951905,
-0.2682641447,
-0.0324255899,
0.0440827385,
-0.0202316288,
-0.1039408371,
0.1336428225,
-0.1592253149,
0.1362432539,
0.0626426861,
-0.3900074959,
0.1310457587,
0.1810851395,
0.0087202694,
-0.5507830977,
0.3258583546,
0.0824375972,
0.0720919073,
0.3139818311,
-0.2043122202,
-0.017840866,
0.1431346089,
0.1173312366,
-0.0132163092,
0.0894117057,
0.4081218839,
0.2967510521,
-0.088429682,
-0.3316461444,
-0.185545072,
-0.0306415614,
0.3833803833,
0.01025056,
0.3587351441,
0.3320619166,
-0.0413411446,
-0.3051054776,
-0.1636176556,
0.1120169684,
0.1587358266,
-0.2233763337,
0.2115518153,
0.1973486245,
0.2576710582,
0.4000867009,
0.1040600389,
-0.1860815287,
0.1649336964,
-0.1613523066,
-0.0093721189,
0.191371724,
-0.2131443173,
0.1475474983,
0.1263390332,
-0.1666786969,
0.052801609,
-0.1037911251,
-0.1233562157,
0.0726654232,
-0.2992701828,
-0.0037595534,
0.1207430214,
0.1719537824,
-0.4932343364,
-0.0825231448,
0.0265253596,
0.1109931618,
-0.2606086135,
0.3477647007,
-0.4349477887,
-0.2078420073,
0.0489473827,
0.1090521365,
0.284961164,
0.0247259233,
0.1266302317,
0.3713031411,
-0.0588566586,
-0.3190896511,
0.0843040198,
-0.0597834662,
-0.6989248395,
-0.3195604086,
-0.04867566,
0.3536749482,
-0.7523905039,
-0.1145465374,
-0.525328815,
0.3034010231,
0.4447640777,
0.0952513739,
-0.3769988716,
0.275167793,
0.2065182477,
0.233265847,
0.4827212393,
0.2081330866,
-0.3300937712,
0.4203998148,
-0.1983514726,
-0.0132853352,
0.2281376272,
0.0834664404,
0.5409326553,
-0.321328342,
0.2080146968,
0.0009161123,
-0.5523920059,
-0.1744151115,
-0.208243385,
0.0981031209,
0.3438120186,
0.140139997,
0.124516964,
0.2264795601,
0.3571223915,
-0.2922934592,
0.2500059307,
0.1408610493,
-0.0602676906,
0.0784244835,
0.6632398963,
0.1293106079,
-0.139195323,
-0.3048908114,
0.0600495748,
0.0262013879,
0.121912308,
-0.4864581823,
0.2007392496,
-0.342509836,
-0.2682598233,
0.2421749979,
0.3915093541,
0.0483303666,
-0.1138273925,
-0.1194839627,
0.0183083788,
-0.1013279185,
-0.2390212417,
-0.0124080097,
-0.2309171855,
-0.318718344,
0.3748571575,
0.181403473,
-0.0095374119,
-0.0777593628,
-0.1931391954,
0.0677428842,
0.1777582467,
-0.0258128829,
-0.175672248,
0.2462607026,
0.2229364365,
-0.4540283382,
0.1023229584,
0.2566984296,
0.0634361506,
0.0822382718,
0.0136123868,
0.3562376201,
0.2961884439,
-0.1604466587,
-0.0775708929,
0.3772707283,
0.0227790754,
0.1195529997,
-0.0320316404,
0.0330357291,
0.180560261,
-0.145173341,
-0.1174878627,
-0.0177127253,
0.1689461023,
0.1712412983,
-0.0860370919,
0.0580610186,
-0.3098419309,
0.0050976318,
0.4644983411,
-0.1317229718,
0.0281202681,
0.2651714087,
0.5062021017,
0.0504108518,
0.1506553143,
0.0703966841,
0.6057808995,
0.3058965802,
-0.4642210901,
-0.0409534685,
0.2396883368,
0.0552404113,
0.1616655737,
-0.0304431301,
0.043412555,
0.0561434068,
-0.0368284881,
0.1772812754,
0.0505993888,
-0.3213225305,
0.1427282244,
-0.0681272447,
-0.1381570697,
-0.0866254792,
-0.1173526123,
-0.1699411869,
0.0510728583,
0.1590315253,
0.1510153711,
-0.165011555,
0.1150200143,
-0.0059909751,
-0.1689780354,
0.1722238809,
-0.571886301,
0.6737946868,
0.098885566,
0.0091910735,
-0.2236598879,
-0.0665236339,
-0.0300451722,
-0.0851193815,
0.0935325921,
-0.1399430633,
0.3583241403,
0.5395306349,
0.3503639996,
-0.2984088361,
-0.5560113788,
-0.2276883423,
0.0866542906,
0.2709229887,
0.0714808032,
0.0811100155,
-0.0314871147,
-0.2182538807,
-0.1013773605,
-0.0140005779,
0.0362976938,
-0.0769228563,
0.1538297385,
-0.2761364579,
-0.2718935609,
0.009660501,
-0.3414783776,
-0.1698224545,
-0.2052968591,
-0.5865628719,
0.2484859079,
0.2069512457,
-0.1093135029,
-0.2307500988,
-0.2866675258,
-0.0776780546,
-0.0514914133,
-0.2827339172,
0.3075460792,
-0.1952321678,
-0.1879345477,
-0.0965185538,
-0.1506591588,
-0.0616559535,
0.1783113778,
-0.1150456667,
-0.1471610814,
-0.2253267467,
0.1891013384,
-0.0696755648,
-0.0831851214,
0.5324710011,
-0.1783230603,
0.0384389907,
-0.0606239475,
-0.6594768763,
-0.0075974097,
0.4371421933,
0.3039065003,
0.1501721591,
0.8784484863,
0.0133587429,
0.6142079234,
-0.0949327424,
-0.1168788522,
0.2561685741,
0.1760588735,
0.2101197839,
0.0647155643,
-0.5172018409,
0.2118287086,
0.1320742965,
-0.254517138,
0.1357434839,
-0.1032246873,
-0.2580366433,
0.1335894614,
-0.220554024,
-0.0120959068,
-0.1865832955,
-0.0734356269,
-0.0273651537,
0.4205163419,
-0.175432995,
0.0977469385,
-0.1577588469,
0.1307404786,
0.0452489182,
0.2985256016,
0.3691955209,
-0.2622390687,
-0.2517957985,
-0.1645062715,
-0.2099294364,
0.2190133184,
0.1914277077,
0.1748195291,
-0.254604876,
0.2076786011,
-0.112477906,
0.1945661753,
0.7678429484,
-0.5542520285,
-0.04347004,
-0.0683936998,
-0.2869269252,
-0.3331109583,
0.0346234255,
0.291459471,
0.3311134279,
0.0645413995,
-0.2575524747,
-0.2032195032,
0.038588997,
0.1870506555,
-0.3144134879,
-0.0847278908,
-0.3484624028,
0.2901310027,
-0.1175860316,
-0.027449701,
0.0459465533,
0.0147134513,
0.1238031834,
0.1962999254,
-0.1548530608,
0.1534227282,
-0.0989679694,
0.2471911162,
-0.2977093458,
-0.1215296611,
0.4208332598,
0.1890583783,
-0.5762963891,
0.1611452401,
-0.1036449522,
0.1220882237,
-0.1324110627,
-0.1897698045,
0.0088122515,
0.0211794879,
0.7454153895,
0.3114635646,
0.0582423024,
0.5071272254,
0.0124875205,
0.1155447438,
-0.0465178899,
0.074909851,
-0.079714857,
-0.032701984,
-0.3391386867,
-0.3834362626,
0.1227099001,
-0.0633094385,
0.042912852,
0.2775493562,
0.2025003433,
-0.2845678627,
0.0664653555,
-0.1628798693,
0.8248214126,
0.218881771,
-0.2901673615,
-0.3649187386,
-0.161937207,
-0.1726665497,
0.3191767931,
-0.0880345404,
0.0434142873,
-0.1732404977,
-0.1078131348,
0.0349614248,
0.3735795021,
0.190329507,
-0.259983927,
0.2707431316,
-0.0430659801,
-0.0910923108,
0.2190103084,
0.3959067166,
0.065838173,
-0.0646901503,
0.329236269,
0.0812815726,
-0.1526447833,
-0.15736413,
0.1015455276,
-0.0941983834,
0.4099063277,
-0.1479934454,
-0.2683018446,
-0.1017407328,
-0.5599928498,
0.0915359035,
0.0771278888,
-0.0453765579,
0.611458838,
-0.2301147431,
-0.346554935,
0.3698150814,
-0.0318850949,
0.2894951999,
-0.0347567759,
0.4139878154,
-0.001498346,
-0.1696752459,
0.3262839019,
0.0961071551,
-0.0136918044,
0.2436864972,
0.0603717305,
-0.6249885559,
-0.2551001608,
-0.1698285341,
0.4036006629,
-0.2116553783,
-0.470503211,
-0.0024920884,
-0.134849146,
-0.0232925788,
0.0534030348,
0.1296759993,
-0.1150685847,
0.4930157363,
-0.0932366624,
-0.0106398379,
0.0075038997,
-0.1088585109,
-0.2112241834,
0.050224673,
0.1089204326,
-0.2530714869,
-0.2201325148,
-0.0436822847,
-0.0776143298,
0.1722152382,
0.1526207924,
0.0619091354,
-0.0798334181,
0.2667716444,
0.2359781116,
0.0622071698,
-0.1160731167,
0.2255188227,
-0.2891027927,
-0.1802238077,
-0.1944144219,
-0.1686268151,
-0.1228249893,
0.1188236177,
-0.2465937138,
0.1166746691,
-0.1468167156,
0.0444105044,
-0.2584421635,
-0.2021532059,
0.2952959836,
0.2662290335,
-0.0049700253,
0.3137483299,
-0.2241769284,
-0.1912644058,
0.0172819477,
0.2077845484,
0.0326541625,
-0.0875057131,
0.1263148934,
0.1706253588,
0.0977670401,
0.304663986,
0.0898652971,
-0.2218456715,
-0.167947188,
0.0700814649,
-0.1045850813,
0.1103326306,
-0.1785098016,
0.0225989725,
-0.0207302235,
-0.3152800798,
0.0017852567,
0.2988087833,
0.0034914168,
0.2883735299,
0.0784206763,
0.3407734632,
0.0820478722,
-0.030942278,
-0.0401264206,
0.1027409136,
0.1186571494,
-0.0981954858,
0.2343209386,
0.0152905639,
0.1961320788,
0.5705643892,
0.0960316285,
-0.2703201175,
-0.3971258104,
0.2333159745,
0.2261372209,
0.1661506593,
-0.0113283424,
0.1573187858,
0.0374123976,
0.21864447,
0.1146233901,
0.1438706815,
-0.1963327229,
0.106328845,
0.4625174403,
0.0913078561,
0.0558526888,
-0.0735791326,
0.1681902558,
0.3842321336,
0.4502862096,
-0.0499634631,
0.4088745713,
0.1288210154,
-0.1383746564,
0.0247271881,
0.2888059914,
0.6389505863,
0.0533198416,
0.0123605262,
0.1687992513,
-0.0171322525,
0.1894451529,
0.0776177123,
-0.288852483,
0.2964714468,
0.1654870212,
-0.6193907857,
0.0779840127,
-0.1734315008,
0.0810616463,
0.1029511318,
0.024887925,
0.2184435874,
-0.2378067076,
0.0768117979,
0.2310528904,
-0.0368712768,
0.1695110947,
0.0349856839,
0.2680370808,
0.072544679,
-0.2000015676,
0.2319231033,
-0.1257226914,
-0.0893165842,
0.3451029956,
-0.2226090729,
-0.2182012796,
-0.3133515418,
-0.0936719924,
0.3672384024,
0.1877459437,
0.0155797079,
0.373524487,
0.073064521,
-0.0698835999,
0.0705652013,
-0.1580155939,
0.2463323176,
0.2129766941,
-0.1093285307,
0.1726880372,
-0.1016848981,
0.0938232467,
0.0596912801,
0.0354954042,
0.146941334,
0.2912648618,
-0.5233696699,
0.1581358165,
0.6152460575,
-0.0181522183,
-0.1405866146,
0.3351652026,
-0.272266686,
-0.4026592076,
0.4148385227,
-0.1204217151,
-0.0598196127,
-0.1424098015,
0.0526685268,
-0.2951748669,
-0.1312319338,
0.0234183948,
-0.2140696943,
-0.3213302791,
-0.1421472728,
-0.1380672455,
-0.4077441692,
0.2813633084,
-0.1921632141,
0.3110916018,
0.1073735878,
0.021627726,
0.0374575779,
0.0690678656,
-0.5874249339,
-0.0385479629,
-0.014876253,
-0.2851536274,
-0.0242942125,
0.1028786898,
0.0386057086,
0.030308919,
-0.1137860119,
0.078734614,
-0.2035964429,
-0.0356578417,
-0.2708059549,
0.1809934229,
0.1614742875,
0.3865813017,
-0.0372832566,
-0.185240835,
0.3930554986,
-0.0638063326,
0.3360133767,
0.1248336136,
0.0483020991,
-0.1771878749,
0.0337002389,
0.0304382388,
0.3028484583,
-0.0996935964,
-0.3396045268,
-0.1894862354,
-0.0492923707,
-0.2581039965,
-0.231667608,
0.0902167037,
-0.1586959064,
-0.0233738776,
0.0497506484,
-0.224294737,
0.0343462341,
0.0645156428,
0.2757310271,
0.0196605567,
-0.0870015398,
0.4778799415,
-0.240536496,
-0.3059542775,
-0.2689356804,
0.3973055482,
-0.6262532473,
0.1750807464,
-0.0604410022,
-0.4723133147,
0.2723688781,
-0.1029543877,
-0.0271075051,
0.5069528222,
-0.2161488533,
0.1769352406,
0.0667389855,
0.0420614257,
-0.0360724665,
-0.0939166397,
-0.255205214,
-0.2274690866
] |
https://github.com/huggingface/datasets/issues/3317 | Add desc parameter to Dataset filter method | I don't have a strong opinion on that, so having `desc` as a parameter is also OK. | **Is your feature request related to a problem? Please describe.**
As I was filtering very large datasets I noticed the filter method doesn't have the desc parameter which is available in the map method. Why don't we add a desc parameter to the filter method both for consistency and it's nice to give some feedback to users during long operations on Datasets?
**Describe the solution you'd like**
Add desc parameter to Dataset filter method
**Describe alternatives you've considered**
N/A
**Additional context**
N/A
| 17 | Add desc parameter to Dataset filter method
**Is your feature request related to a problem? Please describe.**
As I was filtering very large datasets I noticed the filter method doesn't have the desc parameter which is available in the map method. Why don't we add a desc parameter to the filter method both for consistency and it's nice to give some feedback to users during long operations on Datasets?
**Describe the solution you'd like**
Add desc parameter to Dataset filter method
**Describe alternatives you've considered**
N/A
**Additional context**
N/A
I don't have a strong opinion on that, so having `desc` as a parameter is also OK. | [
-0.1287522465,
-0.0055353492,
-0.1885538846,
-0.3054766655,
0.1359180063,
-0.272687912,
0.0132565005,
0.1285357624,
0.0402684659,
0.364382267,
0.2256278396,
0.322019726,
-0.0392239057,
0.1355443448,
-0.1702383906,
0.0217238124,
-0.1972773373,
0.0151643213,
0.0741908476,
0.0693152323,
-0.2096752971,
-0.3124371469,
0.0733716786,
-0.4518632293,
0.0692621917,
0.1593555361,
-0.0564046204,
-0.0860452279,
-0.1909404248,
-0.4803179502,
0.3382697403,
0.5113639832,
0.0274060648,
0.2691564858,
-0.0001110195,
-0.1314857006,
0.4167278111,
-0.1514622122,
-0.0184798315,
0.030814698,
-0.5436116457,
-0.3175924122,
-0.074753888,
-0.3342753649,
-0.0418777466,
0.5702067018,
-0.2019379586,
-0.2746688724,
-0.0828935131,
0.1676568389,
0.2455275357,
-0.2117783576,
-0.4498571754,
0.0243601985,
-0.0119329933,
0.525130868,
-0.1594765782,
0.0165404771,
0.8244943023,
0.0532146804,
0.0179518331,
0.0283068325,
0.0402734093,
-0.321777463,
0.2456882894,
-0.3030416369,
0.2266334444,
-0.2962316573,
0.2843641043,
0.0427701771,
0.5393818617,
0.0807200074,
-0.3334541917,
0.0757232383,
0.0411836207,
-0.2079882473,
-0.2928174734,
-0.1330282539,
-0.1520843804,
0.1316226572,
-0.2559987903,
-0.3349281847,
-0.1926720887,
-0.0056800111,
-0.1067241728,
0.0528879389,
-0.0819459632,
0.0411779359,
-0.1178824008,
0.0662274957,
0.0997801498,
-0.3683359623,
0.1188318655,
0.1366900951,
0.034490943,
-0.4208342433,
0.3402900696,
0.212646842,
0.126308322,
0.2201441228,
-0.189556852,
-0.0591912344,
0.1077512056,
0.1045070216,
0.054410208,
-0.0729837418,
0.4107040167,
0.156204477,
0.0119658839,
-0.4749981463,
-0.2605373561,
-0.1007079706,
0.436211288,
0.0824322253,
0.2419472039,
0.1800659448,
0.0199137405,
-0.3728677928,
-0.0129737891,
-0.032227248,
0.1131751463,
-0.1897703856,
0.1466772407,
0.0682643205,
0.2862047553,
0.3820788264,
-0.042790547,
-0.1686584949,
0.2208830863,
-0.1069815084,
-0.0753963664,
-0.0509276353,
-0.1237651855,
0.1133804843,
0.0847005695,
-0.2822652459,
0.0671132803,
0.0357478559,
-0.1018686965,
0.0763448477,
-0.2094503641,
-0.0998826101,
0.0755469278,
0.2059878707,
-0.5056269169,
-0.0645286962,
-0.0070198602,
0.0384669527,
-0.2391227186,
0.4176940918,
-0.3596380055,
-0.2161434442,
0.0148796532,
0.1997656673,
0.239050895,
-0.0177935641,
0.1691496819,
0.4102726579,
-0.172138229,
-0.3328126371,
0.1070847437,
0.0338704921,
-0.5663175583,
-0.3552456796,
-0.1128412113,
0.1622377783,
-0.6031172872,
-0.0929779336,
-0.5676332712,
0.2308328748,
0.3311686218,
0.1112224162,
-0.383942008,
0.0913689137,
0.1703580022,
0.2217052132,
0.489065975,
0.245869264,
-0.3940970004,
0.4266368449,
-0.1562194228,
-0.0137704937,
0.1715189666,
0.1499585658,
0.452552855,
-0.3060208261,
0.2749732137,
0.0151882861,
-0.5393586159,
-0.1103124321,
-0.2583934069,
0.0375957042,
0.3604870439,
0.0510363281,
0.0446577817,
0.2472177297,
0.4602893293,
-0.3706736565,
0.0908036456,
0.0866464823,
-0.144229427,
0.0682017505,
0.666021347,
0.0532022305,
-0.1853626966,
-0.3084342182,
-0.0676255897,
0.0791674331,
0.1055145264,
-0.4428327978,
0.3144757748,
-0.3552502394,
-0.1836415678,
0.1070219949,
0.3641653061,
0.0407599732,
0.0208311919,
-0.1476227343,
-0.059823513,
-0.0227541178,
-0.0907496735,
-0.0726234466,
-0.1437044293,
-0.3230601847,
0.4114653468,
0.2403999269,
0.0316666029,
0.0136049148,
-0.174265489,
0.0117329797,
0.1625006795,
0.0937466994,
-0.1911056042,
0.0832302719,
0.1922658831,
-0.2899169624,
0.1528963596,
0.3417754173,
0.1883063167,
0.0872466415,
0.0184586532,
0.2720625401,
0.2273684591,
-0.2164484411,
-0.2581890821,
0.2833387852,
0.0210179556,
0.173879236,
-0.0127353547,
0.0805027634,
0.2221190035,
-0.1084846854,
-0.1003872901,
0.0037166423,
0.0939633101,
0.290142417,
-0.0659791753,
0.2828139663,
-0.3060236573,
0.0784819275,
0.396909982,
-0.0691006705,
0.0519241355,
0.2445846498,
0.3198197782,
-0.0073959446,
0.3463861346,
0.1448623836,
0.6124712229,
0.3837258518,
-0.3019723594,
-0.1306228638,
0.1720861942,
0.0014060632,
0.1737764329,
0.0292197634,
0.1452763379,
0.0231334325,
0.1675801873,
0.1570334435,
-0.0564167574,
-0.2233838439,
0.1651682854,
-0.1175366491,
-0.0096402708,
-0.1279947311,
-0.0719111785,
-0.214882642,
0.1146360114,
0.0361819789,
-0.0700055882,
-0.2321897894,
0.144282639,
0.0344559178,
-0.2381452471,
0.1514209062,
-0.5485166907,
0.7579568028,
-0.0205985941,
-0.0584275797,
-0.1803293377,
-0.0607663766,
-0.0373243317,
0.0309452284,
-0.0025639895,
-0.1050068215,
0.4712757468,
0.5372366309,
0.4344279468,
-0.3387265205,
-0.6350774765,
-0.2494317293,
0.1550839096,
0.3155663013,
-0.0093122702,
0.1266282201,
-0.0676353872,
-0.203459397,
-0.0156240258,
0.1211184487,
0.0107368175,
-0.2057731003,
0.1300530285,
-0.0159116257,
-0.2365408093,
-0.0454697423,
-0.3073337376,
-0.2994709909,
-0.0487222597,
-0.5578936934,
0.1778642088,
0.148036465,
-0.1125917137,
-0.2583471537,
-0.1448790729,
-0.0974746644,
-0.1533336043,
-0.2219058722,
0.2215547711,
-0.1939791739,
-0.1097608954,
-0.1562925428,
-0.1061304137,
-0.0577554107,
0.2361230403,
-0.1239203885,
-0.2410774976,
-0.2176621258,
0.3387378156,
0.0356147736,
-0.0940500498,
0.4774368405,
-0.1137406677,
-0.0546233952,
-0.0364582837,
-0.670138061,
0.0191904325,
0.5955818892,
0.3161897957,
0.205878377,
0.7391366363,
0.0796403736,
0.5320224762,
-0.0961744785,
-0.0275442973,
0.3238458335,
0.2484633625,
0.211528495,
-0.0154695734,
-0.5373231173,
0.2622417212,
0.1052494943,
-0.2433634102,
0.1405808181,
0.0445214063,
-0.34609285,
0.1635227948,
-0.3104652762,
0.0354249105,
-0.1438584775,
-0.0263141058,
-0.0067045991,
0.4232582748,
-0.1560488641,
-0.0440737568,
-0.197151348,
0.1346460134,
-0.044575654,
0.1889288574,
0.3949708045,
-0.2554600239,
-0.24293679,
-0.0851307511,
-0.2298288345,
0.1610827893,
0.2690076828,
0.1478746235,
-0.2810569406,
0.1882292032,
-0.145379588,
0.2609975636,
0.6999643445,
-0.5084098577,
-0.1814579517,
-0.0188479908,
-0.2704747915,
-0.2903293073,
0.1213873997,
0.323181808,
0.3511448503,
0.171951279,
-0.2077528834,
-0.1873225123,
0.0544013306,
0.0357411392,
-0.201858446,
-0.0570472926,
-0.2651169002,
0.3846345246,
-0.1155796126,
-0.0365697742,
0.0422538072,
0.0639062747,
0.119388856,
0.2069406807,
-0.1751790643,
0.090585269,
-0.1262165159,
0.251555711,
-0.2970574498,
-0.0612177216,
0.3931531906,
0.1694175452,
-0.4510503709,
0.1812034398,
-0.0746025741,
0.1945003122,
-0.2579910457,
-0.1407448053,
-0.0199760851,
-0.0473061837,
0.6656708121,
0.2813866436,
0.1826989055,
0.5184591413,
-0.0558559224,
0.0870588869,
-0.1393049061,
0.0027309183,
-0.0960416421,
-0.0746002272,
-0.3110170364,
-0.3230661452,
0.2872397006,
-0.0314236321,
-0.0936317071,
0.3507243097,
0.268773526,
-0.3300784528,
0.0742349327,
-0.0998028219,
0.7772376537,
0.2567515671,
-0.3310768306,
-0.3947512209,
-0.1685590744,
-0.0792463347,
0.3569997847,
-0.1491892785,
0.1539615244,
-0.2922806442,
-0.0230158102,
-0.0060736611,
0.3782939613,
0.2523185909,
-0.2058185488,
0.2330402136,
-0.0365264527,
-0.0540779009,
0.3208874762,
0.3828228414,
0.025275467,
-0.0803895667,
0.3032515645,
0.1998393685,
-0.1306955367,
-0.178477481,
0.09941037,
-0.0958777815,
0.3741106391,
-0.1175924763,
-0.2150173336,
-0.2083772123,
-0.5326105356,
0.2000167966,
-0.0123482281,
-0.0644173026,
0.4500932992,
-0.2246937603,
-0.3287840486,
0.243865326,
-0.0709022656,
0.2882955074,
0.0870965049,
0.4348107278,
0.0259793773,
-0.0974319354,
0.2264516354,
0.019940516,
-0.0298536029,
0.2366074026,
-0.0324212536,
-0.6857355237,
-0.3422747552,
-0.1249643862,
0.2237432003,
-0.158116594,
-0.3872212172,
-0.0138995703,
-0.0624194629,
-0.0333751142,
0.153713122,
0.1769464612,
-0.0009617612,
0.5136743784,
-0.032831613,
0.0411506556,
-0.1205206066,
0.0019871646,
-0.146060884,
-0.0073807873,
0.0352744497,
-0.3363233507,
-0.2352654934,
-0.1133184135,
0.0153457876,
0.0190318115,
0.2077779919,
0.1015647501,
-0.1566449702,
0.1712798923,
0.1239119023,
0.073732011,
-0.0252638217,
0.1445263326,
-0.3045603335,
-0.1118372381,
-0.1437584162,
-0.0928045511,
-0.1564028114,
0.1493568122,
-0.3729199767,
-0.0567076169,
-0.1213063449,
0.1115822122,
-0.3508632183,
-0.0983032361,
0.2877097726,
0.2579544187,
-0.0605659224,
0.3187398314,
-0.1990568936,
-0.2143735588,
0.10400635,
0.1231560484,
0.0615702197,
-0.2096111178,
0.0830253735,
0.1105785817,
0.0659611076,
0.2769224942,
0.0143251717,
-0.2350816429,
-0.1227099523,
0.1316030473,
-0.0694025531,
0.0646687895,
-0.1759500802,
-0.0917273462,
-0.0322877169,
-0.3403210938,
0.0680142641,
0.3636091053,
0.0819405168,
0.2530642152,
0.0268984921,
0.3097402751,
0.0671751648,
-0.0142852403,
0.0353213362,
0.0415145494,
-0.0603471845,
-0.1874289811,
0.1965015233,
0.1155171618,
0.2328256518,
0.6476918459,
-0.002126439,
-0.2745273113,
-0.3998779655,
0.2909991741,
0.18380633,
0.2965827286,
-0.0226970334,
0.0300407205,
0.1092961058,
0.1221237928,
0.1493040174,
0.1052563787,
-0.0205225796,
0.1291668415,
0.422577709,
0.0660888106,
0.0233390685,
-0.0909707323,
0.1813035458,
0.3828810453,
0.426497817,
-0.0627560914,
0.3811622262,
0.1463189572,
-0.077535294,
0.1024229974,
0.3174202144,
0.5222004652,
0.0687226281,
-0.0355294533,
0.334736675,
-0.0243845917,
0.2400385886,
0.0699492246,
-0.3088003099,
0.2986291349,
0.232722342,
-0.6038925052,
-0.0527223349,
-0.2912172973,
0.0081433691,
0.0552189648,
-0.0053687934,
0.1993136704,
-0.1369764805,
-0.001237458,
0.242012918,
-0.0231545381,
0.0914974958,
-0.0428854786,
0.3678758442,
-0.0456008427,
-0.1248862892,
0.1358200312,
-0.1461448669,
-0.0431448556,
0.2911496162,
-0.1424155682,
-0.1838571131,
-0.323815614,
-0.1426512301,
0.3656648397,
0.2627400458,
-0.1165711135,
0.3107927144,
0.0910261422,
-0.0341497138,
0.0499432757,
-0.2372111827,
0.0656305552,
0.1024228632,
-0.1695692092,
0.1339276582,
-0.0517481267,
0.1957402974,
-0.0381737128,
0.0826633871,
-0.0004939347,
0.1799295396,
-0.5479955077,
0.2356332541,
0.5925397873,
-0.024201531,
0.0160599947,
0.1717109531,
-0.1114105731,
-0.4475089312,
0.4057147205,
-0.2122229636,
-0.0306706838,
-0.0600587055,
0.1111385971,
-0.2377393246,
-0.1685297489,
-0.0229454171,
-0.1589687765,
-0.2932932973,
-0.2138994634,
-0.2134676427,
-0.4504973292,
0.2100140899,
-0.0582062192,
0.3723426163,
0.0881078243,
0.0199262276,
0.0817428976,
-0.0079837376,
-0.5535168648,
0.035687279,
-0.0987974256,
-0.3882814944,
-0.0454111695,
0.2153708637,
-0.0215399675,
0.0425206423,
-0.1180632934,
0.1938329786,
-0.0986752287,
0.0782544613,
-0.3084457219,
0.288536489,
0.1778066307,
0.3134004772,
0.035800986,
-0.0715027153,
0.2707872391,
-0.0259763654,
0.3121153712,
0.2061410844,
0.0092570027,
-0.1597451568,
-0.0756377876,
-0.0341617092,
0.3195741177,
-0.1176567525,
-0.3300203085,
-0.1014276445,
-0.0127043147,
-0.1738208979,
-0.0548681766,
0.0266677476,
-0.1336733401,
0.0003270545,
0.0093377223,
-0.1951432228,
0.0412613563,
0.0262726955,
0.2082391977,
0.0255767331,
-0.1300167143,
0.4420168102,
-0.2422897369,
-0.2763527632,
-0.2135735005,
0.3381817043,
-0.4494326115,
0.190659672,
-0.024127407,
-0.5434308052,
0.4224690497,
-0.1769412756,
-0.0648671165,
0.424731344,
-0.1168837547,
0.1248434857,
-0.0057419795,
0.062412411,
-0.0699073374,
-0.1420671493,
-0.1694505662,
-0.1128678247
] |
https://github.com/huggingface/datasets/issues/3313 | TriviaQA License Mismatch | Hi ! You're completely right, this must be mentioned in the dataset card.
If you're interesting in contributing, feel free to open a pull request to mention this in the `trivia_qa` dataset card in the "Licensing Information" section at https://github.com/huggingface/datasets/blob/master/datasets/trivia_qa/README.md | ## Describe the bug
TriviaQA Webpage at http://nlp.cs.washington.edu/triviaqa/ says they do not own the copyright to the data. However, Huggingface datasets at https://huggingface.co/datasets/trivia_qa mentions that the dataset is released under Apache License
Is the License Information on HuggingFace correct? | 40 | TriviaQA License Mismatch
## Describe the bug
TriviaQA Webpage at http://nlp.cs.washington.edu/triviaqa/ says they do not own the copyright to the data. However, Huggingface datasets at https://huggingface.co/datasets/trivia_qa mentions that the dataset is released under Apache License
Is the License Information on HuggingFace correct?
Hi ! You're completely right, this must be mentioned in the dataset card.
If you're interesting in contributing, feel free to open a pull request to mention this in the `trivia_qa` dataset card in the "Licensing Information" section at https://github.com/huggingface/datasets/blob/master/datasets/trivia_qa/README.md | [
0.098267749,
-0.066150479,
-0.0082703521,
0.3446457088,
-0.202952683,
0.1115984097,
0.0691819564,
0.2062563002,
-0.201384902,
-0.2456243336,
0.0544378459,
0.1735272706,
0.2805500329,
0.0263393838,
0.0973243192,
-0.1761307567,
0.1311206073,
-0.252302587,
-0.1003351584,
-0.0584071614,
-0.1580770314,
0.6378138065,
-0.3034307063,
0.1950035244,
-0.0054563913,
-0.2435032725,
0.0956021026,
0.2089475095,
0.1095796824,
-0.300407052,
0.1129486188,
0.0791692883,
0.2103005946,
0.2633868754,
-0.0001164213,
-0.2355643511,
0.0323726386,
-0.1809698939,
0.0065180375,
0.1887628287,
-0.2239294201,
0.2284473479,
-0.2378152907,
0.037239518,
-0.1909452081,
-0.0149706379,
0.0405409671,
-0.3948630989,
0.3168411553,
-0.0213825442,
0.1625247747,
0.4073355198,
0.1648591161,
-0.2726813555,
-0.0559967607,
-0.0839520916,
0.0543358177,
0.3252701461,
0.0765433311,
0.0059293238,
-0.0621767752,
0.6628662348,
0.2018467337,
0.0564207286,
0.3287847936,
-0.040924415,
-0.0790307894,
-0.0520541668,
0.3920582831,
0.2581493855,
0.3475062549,
-0.3202480674,
-0.2843129933,
-0.0153518654,
0.2668381333,
0.173136428,
0.2527678013,
0.4681391716,
-0.0594095588,
0.1995480806,
0.0915275961,
-0.2464184761,
-0.1186861619,
-0.1801556051,
-0.1933633536,
-0.3333241642,
-0.1785850525,
0.1079200357,
-0.1340966672,
-0.2351815253,
-0.0325924158,
-0.0480556898,
-0.3627616763,
0.1113527119,
-0.1278084069,
-0.0623126999,
-0.3473716974,
0.2034246922,
0.3467225432,
0.2513724566,
0.0211532395,
-0.2071269304,
-0.2882445753,
-0.0219239257,
0.2336894274,
0.0340706296,
0.0312908813,
-0.150007084,
0.1825240105,
0.1349681169,
0.1546158642,
-0.0497616343,
0.0570402928,
0.0637902692,
-0.513733685,
-0.1749684513,
0.2890419662,
-0.3127984405,
-0.43153584,
0.1230657324,
-0.4250369072,
-0.118884638,
-0.0729731694,
0.2571022511,
-0.0263893697,
-0.108714819,
0.0482301749,
0.1638775468,
-0.0114664063,
-0.3528981507,
-0.216283083,
-0.0085971542,
0.2353982031,
0.1712165773,
-0.022426378,
-0.1113158986,
0.2167389989,
0.0653847903,
0.2641145885,
0.00819482,
0.0068486859,
0.0588388667,
0.0297920592,
0.1998724192,
-0.1602962315,
0.1519756764,
0.127695322,
0.127574563,
-0.1997876614,
0.2368303537,
-0.1535190195,
-0.1020950004,
-0.1100891009,
0.1193015426,
-0.1113856584,
0.0008595836,
0.3842643797,
0.0959590375,
0.1184831262,
-0.2811121047,
0.1789159626,
0.2497958988,
-0.0940195695,
-0.2125768363,
0.0404395834,
0.5094493032,
-0.2031286806,
-0.1393208355,
0.1703475565,
0.1144617721,
-0.1324551105,
0.3983498514,
-0.0499403439,
-0.0762249008,
-0.2951641083,
0.1034934521,
0.0718353018,
-0.5371122956,
-0.3362709284,
-0.1298371553,
0.0526042506,
-0.2414612919,
0.1215049624,
0.0380789042,
-0.0224720258,
-0.0101283304,
-0.0922157988,
0.1798492372,
0.0700127557,
-0.047816284,
-0.1351597756,
-0.4078398049,
-0.056958057,
-0.0921729952,
-0.2201633006,
0.2361743003,
-0.0584166683,
0.2819457352,
0.27912274,
0.2093568146,
-0.2146570086,
0.3127368689,
0.3320906758,
0.2268918306,
-0.1486966014,
-0.0433585569,
-0.2211146504,
-0.0628567562,
-0.4411793649,
0.21572797,
0.1194769442,
-0.3030932546,
-0.3414128125,
0.1544653773,
0.1291080713,
-0.446390003,
0.1253959984,
0.1195596978,
0.2391418666,
0.1584254205,
-0.0925612897,
0.1919387281,
0.2253409773,
0.1947156489,
-0.5948231816,
-0.335588634,
-0.3503430784,
0.2558816671,
0.2043539584,
0.2738720179,
0.1982197315,
0.0667234063,
0.1623606831,
0.2713439763,
-0.1226902828,
0.296231091,
0.2821557224,
0.1007654965,
0.3997852802,
-0.1936400384,
0.3042713702,
0.1142855361,
0.0453288592,
0.1157383546,
-0.3623534739,
0.2523507774,
-0.1091454104,
-0.0218238868,
-0.1075313911,
0.2421569526,
0.0663754791,
0.2437752038,
-0.0452539138,
-0.2596337199,
-0.0599177144,
0.4937544763,
0.0730095208,
0.1215104163,
-0.0979143828,
0.2074552029,
0.3340539038,
-0.0673611611,
-0.0132224541,
-0.2521710694,
-0.4714123309,
0.0534114204,
0.5081459284,
0.2275180221,
0.3568387926,
0.1614772975,
0.0365095846,
-0.2254737169,
0.1256319284,
-0.2738890648,
0.1143298,
-0.0202107765,
-0.3390917778,
-0.2217126936,
-0.0544085503,
-0.1218221635,
-0.0832764581,
0.0963117927,
-0.1113496274,
0.0204610005,
-0.2970563471,
0.0926959291,
-0.0834460407,
-0.4383685291,
-0.4319063723,
-0.1564169377,
-0.6080542803,
-0.2894662321,
0.1919780374,
0.2717407048,
-0.0539794154,
0.1983704418,
-0.1836493015,
0.1835735887,
-0.300727427,
-0.0828083456,
-0.0654496849,
-0.0405447111,
-0.2884941995,
0.089102678,
0.0273142774,
-0.1439327449,
0.1594155878,
-0.2892865241,
0.0530896261,
-0.3835474849,
-0.330199182,
0.1109888554,
-0.1406346709,
0.1410845667,
0.1348465532,
0.3785057664,
-0.120455727,
0.1281549633,
0.1143554822,
0.0578620695,
-0.1405491978,
-0.1837767512,
0.0905355513,
0.2597704232,
-0.0311794486,
-0.2863782346,
0.1019081175,
-0.2073942423,
0.4722592235,
0.0210576244,
0.0202004034,
0.49132815,
-0.2894734144,
-0.1025676876,
-0.3753218353,
0.1960308254,
-0.403891176,
-0.2164242864,
0.1279278398,
-0.1228212789,
-0.3673181236,
0.1141565219,
0.2792818248,
0.3836862147,
-0.2321308255,
-0.1021645069,
-0.2337141186,
-0.1720328629,
0.4539611638,
-0.1314741224,
0.0874482095,
0.2207813859,
-0.0437010862,
-0.0453989096,
-0.1504902244,
-0.0785346106,
0.087741971,
0.0845300257,
0.1660190672,
0.3420415521,
-0.0526620932,
-0.1555115283,
0.7847997546,
0.5099938512,
0.2360463291,
0.2462860346,
-0.130014658,
0.3044471741,
0.3006362021,
0.0033245583,
-0.0676849559,
0.270647496,
0.2437812686,
0.2163340896,
0.1435237676,
0.9297799468,
0.0317382403,
0.3236418962,
-0.4220313132,
-0.183260411,
-0.0855004042,
-0.1753630042,
0.1113764048,
0.1449578404,
0.3741216362,
0.0896057039,
-0.0948403329,
0.3792724609,
0.2949745655,
0.0562274121,
0.1279168278,
0.0796923265,
0.1806080788,
-0.4136060476,
0.2699289322,
-0.3084620833,
0.3515796959,
-0.4181351662,
-0.447239995,
0.2540465891,
0.2269374281,
0.5077682137,
0.3427832127,
-0.0742767304,
-0.2899527848,
0.0156941079,
-0.1794154495,
-0.0276884586,
-0.0351044424,
-0.1431279629,
-0.0012668215,
-0.0703871772,
-0.3571615219,
-0.0764930695,
0.2069927603,
-0.1741419733,
-0.1371338218,
-0.0846489221,
-0.4440939724,
-0.2553971112,
-0.2938181758,
-0.1955046952,
0.24090074,
0.2092545927,
0.0388257876,
0.2893083096,
0.0167257152,
-0.1419683546,
0.2242378294,
0.3275778294,
0.3295955062,
-0.1306481212,
-0.1459399313,
0.2354640663,
-0.0123278173,
0.1204107553,
0.218367517,
0.2255718112,
-0.3241786659,
-0.1505617499,
0.0666563064,
0.0689960197,
0.2838307917,
-0.117893368,
0.3125829995,
0.3069928288,
-0.2956084907,
-0.3592714667,
-0.3810203969,
0.0792821124,
-0.1139762849,
0.2194054276,
-0.2003041506,
0.4095491767,
0.3376649916,
-0.2577117085,
0.1553116292,
0.2506980002,
-0.0612686537,
-0.0943629071,
0.078700535,
1.143543601,
-0.1671953946,
0.121574074,
0.0029292873,
-0.2854775488,
0.857638061,
-0.1079735383,
0.1285797507,
-0.4733756185,
0.0388361253,
-0.2213753164,
-0.0087048076,
0.0934911221,
-0.4134358466,
-0.1576664597,
0.3193106949,
-0.1119304523,
0.440523535,
-0.0819994211,
-0.0285731964,
-0.5859723687,
-0.0258005876,
-0.2417474985,
0.093185842,
-0.1785732508,
0.7432106137,
-0.2721164227,
-0.2484530807,
-0.3822129667,
-0.0093677938,
-0.4061176181,
0.0406682342,
-0.250400871,
0.0078611588,
-0.0847357586,
-0.286324352,
-0.0358150974,
0.303502351,
0.400226295,
-0.1628341526,
-0.4663959742,
0.1741461903,
-0.0252961218,
-0.1820011437,
-0.0529648103,
0.2078427821,
-0.0014812712,
-0.0986448377,
0.0203931797,
0.2658988833,
0.0598504357,
0.1954800338,
-0.6819450855,
0.1960802525,
0.0365441255,
-0.0241847504,
0.0627909154,
-0.0548068322,
0.1078050807,
-0.0758375674,
0.0914040729,
0.2146834582,
-0.0307353642,
-0.3064028621,
0.1438615471,
-0.2276232541,
-0.0343129896,
0.365364939,
0.0956972092,
0.2570617497,
0.2499970943,
0.0923364684,
-0.0067173317,
-0.1148419455,
-0.1186706573,
-0.2896596491,
-0.8202397227,
-0.124546133,
0.22655572,
-0.0651544183,
-0.2991752923,
0.372417748,
0.2136574239,
-0.0630719289,
-0.1149109602,
-0.3020271659,
-0.2239118665,
0.2961730063,
-0.6134842634,
0.0087255538,
0.2392472923,
-0.014177626,
0.1055880859,
-0.0770952702,
-0.2424684465,
-0.1878977418,
0.0906214938,
-0.2345184088,
-0.0251181424,
0.1064675078,
0.0780660957,
-0.0097908564,
-0.0503588319,
0.0390710235,
-0.2140940726,
-0.0813126042,
0.121754773,
0.1497500092,
0.0285796132,
-0.0603754148,
-0.4867233038,
0.0921585262,
0.0385305472,
0.1078171954,
0.195531711,
0.1424142569,
0.247416541,
0.202065438,
-0.1406477094,
0.1882819682,
-0.3752547503,
0.195243448,
0.1563336104,
0.0415471345,
0.0777859837,
0.0267980825,
-0.2206768543,
-0.1130474731,
-0.1812507808,
0.3507945538,
0.0535149798,
-0.0284409691,
-0.1417283565,
0.0771422088,
-0.1051563844,
0.3031049669,
-0.0500179194,
0.2196063846,
-0.0505795553,
-0.151880607,
-0.0551455244,
0.1328584552,
-0.2306862921,
0.1938182563,
-0.436383009,
-0.0854914561,
-0.1996866316,
0.1970740706,
0.1484757364,
0.2645291686,
-0.1733230501,
0.0592091791,
0.3239274919,
-0.0282828528,
0.3576306701,
0.319391489,
-0.0008194498,
0.3412640989,
0.2637656033,
0.1055667177,
0.1281550229,
-0.1163743958,
-0.1683654934,
0.1932849735,
0.1702838987,
-0.1330838352,
0.4832733274,
-0.1455082446,
-0.066998668,
0.23288697,
0.3724455237,
0.0880387872,
0.0291008204,
0.3830452859,
-0.2597023547,
-0.2046493739,
-0.4626852572,
-0.1588909179,
-0.2632244527,
-0.1730279922,
-0.1427809298,
-0.0230711475,
0.2255286723,
0.0168396626,
0.0077935914,
-0.2453291267,
0.4182121456,
-0.1195548996,
-0.1576752812,
-0.560090661,
-0.2316306978,
0.3324700594,
0.0406161509,
0.0084878821,
0.2584230006,
-0.0463584773,
-0.0827400386,
0.5763524175,
0.4012613893,
0.4585731626,
-0.1623431295,
0.3352665007,
-0.0080857975,
-0.2097419798,
0.1080199778,
0.2652853429,
0.3865732253,
0.0401642248,
0.0557600819,
0.3132922649,
0.1208077744,
0.0161967203,
-0.3393578529,
0.0251956414,
0.1424181163,
-0.2820552886,
0.1499942243,
-0.7456974387,
-0.1138450205,
-0.0015764291,
0.1615375131,
-0.1091140732,
0.1645312607,
-0.1188130528,
-0.0121312011,
-0.1226390526,
-0.0978226438,
0.0420561209,
0.2433594316,
0.3261140287,
0.4896480739,
0.0292125642,
-0.2371531874,
-0.0831823945,
-0.4918306768,
0.2201015353,
0.2196802795,
0.1317402124,
-0.3230977356,
-0.0049699019,
0.2318203151,
0.0823162794,
0.0701730102,
0.0342074744,
0.1394873261,
0.0517696775,
-0.205641076,
-0.1890891045,
0.0454800427,
-0.2561310232,
0.1113563552,
0.1206173524,
0.286408484,
0.0931636542,
-0.1360224336,
-0.1416720152,
0.0217874274,
0.0920384377,
-0.0083488431,
0.0991099179,
0.2041217685,
0.0065388945,
0.1307082176,
-0.1458200216,
-0.011253424,
0.0783542991,
-0.1167397946,
0.1969971955,
-0.2241563946,
-0.1069486365,
0.0473951325,
-0.2711373866,
-0.1422887146,
0.9615893364,
0.1219687983,
0.0757853091,
-0.4511280954,
-0.0783824846,
-0.1225175783,
-0.2204247266,
0.3355655372,
-0.0038509779,
0.064453423,
0.2253744006,
-0.1530854255,
-0.472143054,
0.6222936511,
-0.3715931177,
0.2050430775,
0.2726900876,
0.2514034212,
0.0469665863,
-0.3353720605,
-0.9059182405,
0.2444480807,
0.2408860624,
0.0276244711,
0.0364217386,
-0.0763795674,
-0.4120143056,
-0.1861317456,
-0.0305166747,
0.6717929244,
-0.0558903962,
-0.3063523471,
0.3636106253,
0.0996194482
] |
https://github.com/huggingface/datasets/issues/3310 | Fatal error condition occurred in aws-c-io | Hi ! Are you having this issue only with this specific dataset, or it also happens with other ones like `squad` ? | ## Describe the bug
Fatal error when using the library
## Steps to reproduce the bug
```python
from datasets import load_dataset
dataset = load_dataset('wikiann', 'en')
```
## Expected results
No fatal errors
## Actual results
```
Fatal error condition occurred in D:\bld\aws-c-io_1633633258269\work\source\event_loop.c:74: aws_thread_launch(&cleanup_thread, s_event_loop_destroy_async_thread_fn, el_group, &thread_options) == AWS_OP_SUCCESS
Exiting Application
```
## Environment info
- `datasets` version: 1.15.2.dev0
- Platform: Windows-10-10.0.22504-SP0
- Python version: 3.8.12
- PyArrow version: 6.0.0
| 22 | Fatal error condition occurred in aws-c-io
## Describe the bug
Fatal error when using the library
## Steps to reproduce the bug
```python
from datasets import load_dataset
dataset = load_dataset('wikiann', 'en')
```
## Expected results
No fatal errors
## Actual results
```
Fatal error condition occurred in D:\bld\aws-c-io_1633633258269\work\source\event_loop.c:74: aws_thread_launch(&cleanup_thread, s_event_loop_destroy_async_thread_fn, el_group, &thread_options) == AWS_OP_SUCCESS
Exiting Application
```
## Environment info
- `datasets` version: 1.15.2.dev0
- Platform: Windows-10-10.0.22504-SP0
- Python version: 3.8.12
- PyArrow version: 6.0.0
Hi ! Are you having this issue only with this specific dataset, or it also happens with other ones like `squad` ? | [
-0.4823270142,
-0.0941876471,
-0.1207199469,
0.0980168432,
0.0666415095,
-0.0746589378,
0.2302931845,
0.080716446,
0.0498347208,
0.2464572787,
0.0314400084,
0.6151476502,
0.0799872056,
0.0899449214,
-0.2150688022,
0.0799752995,
0.1774080247,
0.2226745933,
-0.383779645,
0.1506047398,
-0.3002249002,
0.3312657177,
-0.3285821378,
0.1297633201,
-0.1777175516,
-0.2442936748,
-0.0252513234,
0.1826006025,
0.0460977182,
-0.3293401003,
0.3206728995,
-0.2650409639,
0.2438400984,
0.4518453479,
-0.0001093318,
-0.1118510142,
0.3101603985,
0.094552204,
-0.3214780092,
-0.0317827463,
-0.1824334562,
-0.0217733271,
0.1722513735,
-0.3631688058,
0.3220714331,
0.2951671183,
0.0071724853,
-0.2874424458,
0.1973882318,
0.4085330963,
0.2418861836,
0.7135306597,
0.1465577781,
0.0556876212,
0.1848491877,
-0.1402462423,
-0.3562592864,
0.1377409697,
0.3027016819,
-0.3610855043,
0.2152114213,
0.1781432778,
-0.1646542549,
0.1518884599,
0.0844426826,
-0.0406348445,
0.0620385781,
-0.3105756044,
0.2238105685,
-0.0043022865,
0.372600764,
-0.4975507557,
-0.2278131992,
0.1983139664,
0.1189708188,
-0.2930723131,
0.2673714161,
0.2600485981,
-0.1133085936,
0.154076457,
0.1476511806,
0.3345821202,
-0.2547405064,
0.196302861,
-0.1133233607,
0.2745121121,
-0.1227361709,
0.0944329575,
-0.0969923288,
0.0161616653,
0.0290693194,
-0.1192914471,
-0.1253110915,
0.1685810238,
-0.7996680737,
-0.0870910436,
-0.0505597442,
0.2139267921,
0.1183021739,
-0.0086709606,
0.0792438388,
-0.1322977096,
0.3381571174,
0.2955600917,
0.0983082205,
-0.1588631272,
0.0681324378,
0.1116921902,
0.3717537522,
-0.0034811997,
-0.1405860037,
-0.1129023433,
0.0967277065,
-0.2409908921,
0.2786041498,
0.0161672682,
0.4272918403,
-0.1937425137,
-0.4776917696,
0.5653189421,
-0.3984056413,
0.1799083948,
-0.0649993718,
0.4042619169,
0.0797655657,
-0.1638060808,
0.1143709719,
0.1963438541,
-0.3679198027,
0.1306263208,
-0.1418008804,
0.0005098595,
-0.1412114799,
0.019531982,
0.1512916535,
-0.2332045734,
0.1894150078,
0.2659634352,
0.2191421241,
-0.4016889334,
0.1106707677,
-0.0974878371,
-0.3781300187,
0.2504130304,
0.3266516626,
0.1434190124,
-0.0666371658,
-0.0205635875,
0.14840734,
0.2709490359,
-0.1687717438,
-0.1889024079,
-0.3929618299,
0.2797447443,
-0.1146848798,
0.0338509679,
-0.1040296257,
-0.2441021055,
0.2317205071,
-0.1020840704,
0.1924035549,
-0.2675976753,
0.1456106901,
-0.1156610921,
0.0236120466,
0.158811152,
-0.1695828289,
0.1416717321,
-0.173403576,
-0.1573117375,
0.1927894503,
0.2721312344,
-0.1239450052,
-0.0391006358,
-0.3496799469,
0.0942631587,
0.1699191332,
-0.1043844894,
-0.3306797445,
0.3258506656,
-0.0885311142,
-0.1447171718,
-0.1056173816,
-0.0206370242,
0.0421574451,
-0.0850139409,
-0.1802262068,
-0.2151266485,
-0.0075934161,
0.154202193,
-0.3081530631,
-0.3051502407,
0.0597068034,
0.1991613805,
0.2608787119,
-0.0395017788,
0.3754090071,
-0.0356417745,
0.3499757349,
-0.1175405011,
-0.092247121,
0.1783539802,
0.3556669354,
-0.2298668772,
0.0529749617,
-0.1591698676,
-0.6702604294,
0.1807159185,
0.165657863,
0.2113173753,
-0.0744267032,
-0.1161602288,
-0.0688249096,
0.3155629337,
-0.0522594228,
-0.0038407084,
0.1758319736,
-0.1146855652,
-0.0599477328,
-0.1472003758,
-0.2478776425,
0.2320475578,
-0.7155190706,
0.1314234436,
-0.1407736689,
0.300583601,
-0.1876199394,
-0.3593219221,
0.1207011193,
-0.1952483952,
0.2406071126,
0.0593785904,
-0.3034168184,
0.2202456146,
-0.1401109248,
0.5234094262,
-0.121492058,
0.2303860933,
-0.0527444631,
-0.3421445787,
0.0352784507,
0.056942869,
0.1885977834,
-0.001998665,
0.1705239862,
0.1777389348,
-0.1596398354,
0.2327788174,
-0.1285793334,
-0.0722866282,
0.0722217262,
-0.1394798756,
-0.0093200915,
0.1415272504,
0.3039070666,
0.1842695773,
0.3013442755,
-0.1546598673,
-0.4457636178,
-0.156949237,
0.2590025067,
0.0071461871,
0.2256676555,
0.089961417,
-0.0806360766,
0.0596686378,
0.3690811992,
-0.0267703664,
0.7966686487,
0.1177375764,
-0.0753351375,
0.1351559162,
-0.0905157328,
-0.2169248909,
0.4426446855,
0.2501824796,
0.1745979041,
0.436105907,
0.2811738253,
0.0342522524,
-0.4044068456,
-0.3952736259,
-0.0197327044,
0.2163796127,
-0.2601399124,
0.2554371357,
-0.0373548977,
0.1822556704,
-0.0639194772,
0.2400015146,
0.0171623677,
-0.0705009475,
-0.0469140075,
0.3004805744,
-0.0830545202,
0.2009399235,
-0.1433956325,
-0.0361894406,
0.0629049242,
0.0652647316,
-0.3282935917,
-0.1639317274,
-0.15581429,
0.0677444413,
0.2645579278,
-0.1575244665,
0.2829577327,
0.0665978789,
-0.1457823366,
-0.3569099903,
-0.0929066315,
0.0534350537,
0.0123090371,
0.3559879959,
0.1835329533,
0.2865858972,
-0.2607325912,
-0.4826546609,
0.0965461433,
-0.333728075,
0.0578401908,
-0.0025466757,
-0.2966888249,
-0.0408780426,
-0.2729905248,
-0.3428076208,
-0.1935272217,
-0.3901370466,
-0.0561678261,
-0.1907967329,
0.0778793618,
-0.1475289017,
0.2897517085,
0.0984354615,
0.3401774764,
-0.2686770856,
-0.2965059578,
-0.3120579422,
0.1830344349,
-0.1028922424,
-0.2111269832,
0.2261357158,
0.2418117076,
0.519775629,
0.0329782628,
-0.4396686554,
0.2005501986,
-0.0733782649,
0.3120964766,
-0.266420126,
0.1489852518,
0.1087665707,
-0.1928347647,
-0.0266906396,
-0.1430123895,
-0.0080377487,
-0.22552526,
0.0174364634,
0.3101728261,
-0.2037787437,
0.4758346975,
0.130440414,
0.6477095485,
0.1487701386,
-0.3631490469,
0.3281258941,
-0.0603638887,
-0.0706750005,
-0.1189918965,
-0.157239899,
0.1850177348,
-0.1347286105,
-0.3503600061,
0.112419486,
-0.1817427576,
-0.5196110606,
-0.0818971172,
0.0596943125,
-0.2758610845,
-0.2807139456,
-0.041853223,
0.3249352574,
0.2445975989,
-0.0426768102,
0.0609365739,
0.0761926547,
-0.0790033191,
0.0417178571,
0.3897144496,
-0.1952049583,
-0.1014041752,
-0.1177418977,
-0.2626718581,
-0.4432503879,
0.3169189394,
-0.1522964388,
0.3419372737,
0.0483033806,
0.1092955992,
0.1590949893,
-0.3131527007,
0.3677819967,
-0.0694473311,
0.1870154142,
0.0563020185,
0.3413411677,
-0.1624379605,
-0.1976421177,
-0.3250183463,
0.2547639608,
0.3388160169,
-0.0294157844,
-0.0952245668,
0.0383482575,
0.0723560974,
-0.1258237809,
0.1321980506,
-0.3811079264,
-0.2074203044,
-0.2426095456,
-0.4008001089,
0.4213261306,
-0.0282994602,
-0.0009477566,
-0.2422816902,
-0.4049986899,
-0.0321923904,
-0.0440528579,
0.1019300669,
0.1815075278,
-0.1903237253,
-0.1376048476,
0.3349035084,
-0.2704981863,
-0.337320447,
0.4276288152,
0.2421147972,
0.2080145478,
-0.0277191885,
0.3016574979,
0.010322419,
0.2919365764,
0.2397259325,
-0.1841232032,
0.1279132217,
0.0843145847,
0.2248754054,
0.028563058,
0.0971084759,
0.2395234406,
0.1641035378,
-0.0305603649,
0.2286696732,
0.3767009377,
-0.0723015368,
-0.0120125078,
0.5393149853,
-0.1151661873,
-0.1694132537,
0.3050014675,
0.0548523255,
0.6787362099,
0.2121764719,
-0.0562132969,
0.2949628234,
-0.3407179415,
0.3377649188,
-0.1975848377,
0.0573589988,
-0.3953698575,
0.1236198321,
0.1169001535,
-0.0813095719,
0.3585179448,
0.167766884,
0.0605344139,
0.0381093733,
0.0312572829,
0.2740856111,
-0.1324957162,
0.1294449121,
-0.5348523855,
-0.330845505,
-0.5394377708,
0.1992409676,
-0.1501922607,
0.1693485528,
-0.3229884803,
0.1403185278,
0.2016043216,
-0.3171850145,
-0.349205941,
0.1786102206,
-0.3829373717,
0.133516252,
-0.2225364894,
-0.4115643501,
0.2467336953,
0.190703854,
-0.0321029983,
0.2275134623,
0.0142660309,
0.4036365151,
0.101735577,
0.0905299857,
-0.0206051935,
-0.1149621457,
-0.1674408466,
-0.047279235,
-0.2051325142,
0.189245522,
-0.0917256549,
-0.09605553,
0.242989853,
0.1076780632,
-0.1081046686,
-0.0234655198,
-0.1044986621,
-0.0505838878,
-0.2246499211,
-0.2319654375,
0.231883347,
0.0224138945,
-0.1298245043,
0.4898677766,
-0.3267782927,
-0.0501192622,
-0.152670756,
0.475153923,
-0.1236503497,
-0.043558374,
0.2253583819,
0.4243198633,
-0.0821520314,
-0.3228991032,
0.1791907102,
-0.3497647941,
-0.3311195672,
0.0231102929,
0.0777491108,
0.0916724727,
0.2563844323,
0.2507622242,
0.0441245623,
0.0584612563,
0.0811956599,
-0.3233764768,
-0.2859399021,
0.0250118729,
-0.020928584,
0.3900223672,
0.3278732002,
0.0764866844,
-0.3376361728,
-0.0954976529,
-0.3223224878,
0.0503235087,
-0.2337908149,
0.1277036965,
0.0431019738,
0.0238359198,
0.2714158595,
-0.0961994827,
0.1416791379,
0.3956419528,
-0.1080251634,
-0.2500187755,
-0.1581801474,
0.118604593,
0.1520783901,
0.0813960508,
0.0305076651,
-0.1806692183,
-0.0440969467,
-0.0020194876,
0.4647043049,
0.0109938225,
-0.2168277353,
-0.0389939807,
-0.0622527115,
-0.0128775192,
-0.2668932974,
-0.076442495,
0.0637060627,
0.2091441154,
-0.0352348499,
0.1508771777,
0.0709739923,
-0.0007211477,
0.0113968635,
-0.0849786699,
-0.2358634323,
0.3494103253,
0.2537575066,
-0.2679549456,
-0.2649644315,
-0.1382410675,
0.1559226364,
0.2251118273,
-0.1749918312,
-0.1164731979,
0.0061866925,
0.2975080609,
-0.0800601318,
-0.167002365,
0.1288491786,
0.0077384994,
-0.0605456345,
0.0508793741,
-0.0374923646,
-0.2817239463,
0.0228593759,
0.0785793662,
0.424805373,
-0.4623888135,
0.0237456113,
0.0840030611,
-0.0769676864,
0.2048175484,
0.0626700073,
-0.1870019287,
0.2572797537,
0.4761090875,
-0.1621000916,
0.0644978732,
0.4054137766,
0.2349548042,
0.1128254533,
-0.2486469001,
-0.4075113535,
-0.0588303879,
-0.1437634528,
0.2844051421,
0.1975388825,
-0.0109807355,
0.0198368151,
0.0183124822,
-0.3024231493,
-0.0107106464,
-0.3223543763,
0.0439435914,
-0.3808037937,
-0.034379594,
0.2491384149,
0.0280437116,
-0.0458018705,
0.1105596647,
0.3311463594,
0.240572378,
0.0643306375,
-0.2667905986,
-0.0308040865,
0.419095546,
0.0662688985,
-0.1871491224,
0.0508400686,
0.181637615,
-0.0717646107,
-0.4726986289,
0.0790032148,
0.657946825,
0.0169477388,
0.0719454661,
0.1260677576,
0.1795230955,
0.0594407469,
0.0745904669,
0.1132365987,
0.120754011,
0.2666736543,
0.1490109712,
0.1702396274,
-0.1650426686,
-0.0043400358,
0.3387466669,
-0.0210197866,
-0.2424344271,
-0.2416342497,
-0.1954248399,
-0.1013672948,
-0.2265819013,
0.2639812529,
-0.3123524785,
0.1984807253,
0.3663846254,
0.0082949335,
0.0393579416,
-0.1345555037,
0.1093983278,
-0.1921638101,
0.390622437,
0.1131596044,
0.3263911605,
-0.4209771156,
-0.1554104537,
-0.2961937487,
0.2131378949,
0.0012416904,
0.3448340297,
-0.0549187027,
0.1059662327,
-0.1824579388,
0.0348602012,
0.4162335992,
-0.1679182798,
0.1294634491,
0.7829440832,
-0.3156927228,
-0.1217252985,
-0.209884584,
-0.3824699521,
0.0533129498,
-0.3740432262,
-0.0177232102,
-0.1871325821,
-0.0126328701,
-0.30629462,
-0.1858231127,
0.1075885817,
-0.1373317093,
0.7154784799,
-0.0445718803,
0.3198085427,
-0.2935835719,
0.0216121022,
-0.1158510968,
-0.3517834842,
0.1380848289,
0.0112455701,
-0.0852551982,
0.4363044798,
-0.0501286611,
-0.0191021152,
-0.0268879887,
-0.0999023989,
-0.1023883969,
-0.2486719936,
-0.1281944066,
0.0825117826,
-0.2334287167,
0.154325366,
-0.2159131765,
0.4415630996,
0.1837109476,
0.181995526,
-0.4950414896,
-0.3122365773,
0.350772649,
-0.289465189,
-0.2336854786,
-0.1207783222,
0.3673833311,
0.2532334328,
-0.0299609154,
-0.4289544225,
-0.0207980368,
0.2065768838,
-0.1468729675,
-0.2748397887,
0.0632209182,
0.2394016534,
-0.0107385824,
0.0019081387,
0.130232811,
0.1695719957,
-0.0869403556,
0.3067710102,
-0.4197969735
] |
https://github.com/huggingface/datasets/issues/3310 | Fatal error condition occurred in aws-c-io | @lhoestq It happens also on `squad`. It successfully downloads the whole dataset and then crashes on:
```
Fatal error condition occurred in D:\bld\aws-c-io_1633633258269\work\source\event_loop.c:74: aws_thread_launch(&cleanup_thread, s_event_loop_destroy_async_thread_fn, el_group, &thread_options) == AWS_OP_SUCCESS
Exiting Application
```
I tested it on Ubuntu and its working OK. Didn't test on non-preview version of Windows 11, `Windows-10-10.0.22504-SP0` is a preview version, not sure if this is causing it. | ## Describe the bug
Fatal error when using the library
## Steps to reproduce the bug
```python
from datasets import load_dataset
dataset = load_dataset('wikiann', 'en')
```
## Expected results
No fatal errors
## Actual results
```
Fatal error condition occurred in D:\bld\aws-c-io_1633633258269\work\source\event_loop.c:74: aws_thread_launch(&cleanup_thread, s_event_loop_destroy_async_thread_fn, el_group, &thread_options) == AWS_OP_SUCCESS
Exiting Application
```
## Environment info
- `datasets` version: 1.15.2.dev0
- Platform: Windows-10-10.0.22504-SP0
- Python version: 3.8.12
- PyArrow version: 6.0.0
| 61 | Fatal error condition occurred in aws-c-io
## Describe the bug
Fatal error when using the library
## Steps to reproduce the bug
```python
from datasets import load_dataset
dataset = load_dataset('wikiann', 'en')
```
## Expected results
No fatal errors
## Actual results
```
Fatal error condition occurred in D:\bld\aws-c-io_1633633258269\work\source\event_loop.c:74: aws_thread_launch(&cleanup_thread, s_event_loop_destroy_async_thread_fn, el_group, &thread_options) == AWS_OP_SUCCESS
Exiting Application
```
## Environment info
- `datasets` version: 1.15.2.dev0
- Platform: Windows-10-10.0.22504-SP0
- Python version: 3.8.12
- PyArrow version: 6.0.0
@lhoestq It happens also on `squad`. It successfully downloads the whole dataset and then crashes on:
```
Fatal error condition occurred in D:\bld\aws-c-io_1633633258269\work\source\event_loop.c:74: aws_thread_launch(&cleanup_thread, s_event_loop_destroy_async_thread_fn, el_group, &thread_options) == AWS_OP_SUCCESS
Exiting Application
```
I tested it on Ubuntu and its working OK. Didn't test on non-preview version of Windows 11, `Windows-10-10.0.22504-SP0` is a preview version, not sure if this is causing it. | [
-0.5945265889,
-0.0300624389,
-0.0512790903,
0.2207445651,
0.0420040414,
0.0443693697,
0.0953230858,
0.1442599148,
0.1222059354,
0.1434797347,
-0.0616347119,
0.5850592256,
0.0375699773,
0.1205552444,
-0.3080869317,
0.0348106101,
0.1885121018,
0.2404175103,
-0.4595812559,
0.1869170517,
-0.3032239377,
0.3453543782,
-0.2602758408,
0.1346335858,
0.0421350151,
-0.1968778968,
-0.1488535106,
0.2010757029,
-0.0742304921,
-0.2864917219,
0.2991323769,
-0.2308009267,
0.368249625,
0.4272992611,
-0.0001174554,
-0.1002697721,
0.3582291901,
0.0790439621,
-0.2358692884,
-0.0487060398,
-0.1797530055,
0.0243323352,
0.0793854669,
-0.2948921621,
0.4447724223,
0.2634952962,
-0.0024436826,
-0.2447905838,
0.1696438789,
0.4753594398,
0.1513209492,
0.8094779849,
0.2087617517,
0.063018322,
0.1563263386,
-0.200208053,
-0.3551682234,
0.1035014242,
0.3712543845,
-0.3439843059,
0.2109998018,
0.00411135,
-0.1643913835,
0.1269932538,
0.0712593347,
-0.0660402551,
-0.0026299353,
-0.3985140622,
0.2711316645,
0.0063400613,
0.4763680995,
-0.4716658592,
-0.2296433598,
0.1929732114,
0.0260524936,
-0.2832107544,
0.3270208836,
0.3015539944,
-0.2553267777,
0.112238571,
0.062577337,
0.2855647802,
-0.2144770026,
0.2550937831,
-0.1403025985,
0.2488749921,
-0.1546899527,
0.1599146128,
-0.0110516082,
0.1406493783,
0.0688198209,
-0.2619257867,
-0.1848988235,
0.0704166442,
-0.7445173264,
-0.1308862418,
-0.0579877347,
0.2496538758,
0.1386790723,
0.0210604072,
0.115343459,
-0.1648573726,
0.3813506365,
0.1840267926,
0.2412229478,
-0.1555271298,
0.0887539908,
0.1090281084,
0.2435628325,
0.0839461535,
0.0585121252,
-0.0771201327,
0.0470914096,
-0.1523842067,
0.2002092004,
0.0527235754,
0.2757399082,
-0.2119404227,
-0.4556527138,
0.4925704002,
-0.3128277659,
0.2312116176,
-0.096110329,
0.4694093764,
0.1410814077,
-0.1782955974,
0.0448044948,
0.2365275323,
-0.2475743592,
0.2036448419,
-0.019591786,
-0.0583376959,
-0.1165701151,
0.0656608939,
0.1904301196,
-0.2062090188,
0.2658505142,
0.1359633952,
0.0142727504,
-0.4328809083,
0.1512791812,
-0.0185973682,
-0.3559509218,
0.226853475,
0.4095697999,
0.286867857,
-0.1254331768,
0.1299216151,
0.0493027978,
0.423583895,
-0.0599137954,
-0.1321622282,
-0.399577111,
0.1966773421,
-0.2177073807,
0.0192752369,
-0.2026811838,
-0.1510062665,
0.1584400237,
0.0267944783,
0.2286272794,
-0.2071663439,
0.1135945991,
-0.0607533418,
0.0583752878,
0.2731277943,
-0.1933155507,
0.0719538331,
-0.1898609847,
-0.2285410464,
0.152667135,
0.2196999937,
-0.110921964,
-0.0582661815,
-0.3346825838,
0.0827380568,
0.2192900032,
-0.0943564922,
-0.3747966886,
0.5333963037,
-0.1259794384,
-0.1146125719,
-0.1206337884,
-0.0062321988,
0.1685021371,
-0.0786607265,
-0.3336589336,
-0.1456879973,
0.007175717,
0.0394508094,
-0.2569046319,
-0.3434803486,
0.0629989579,
0.1968298852,
0.2350416481,
-0.0126357283,
0.2946358621,
0.0543181673,
0.3523744941,
-0.0594732277,
-0.0684327111,
0.3224883974,
0.2951691449,
-0.3205549121,
-0.0116478214,
-0.1934605837,
-0.7862312794,
0.2362460047,
0.1455783397,
0.121576421,
0.0162233133,
-0.0900613517,
-0.1477847695,
0.2923689485,
-0.0572043695,
-0.0689449012,
0.073920466,
-0.0988010988,
0.0688332617,
-0.1523927897,
-0.239761278,
0.2122466117,
-0.787874639,
0.1639366299,
-0.0983183533,
0.2302183658,
-0.2041424364,
-0.316259414,
0.0834144652,
-0.2877324224,
0.1473356634,
0.0455146357,
-0.2425877154,
0.2752538025,
-0.2163640261,
0.5208961964,
-0.2470377833,
0.2431076467,
0.0214641932,
-0.3336754441,
0.0774446726,
0.0464486554,
0.2368066162,
-0.0321273319,
0.0632020757,
0.1591188908,
-0.1559458226,
0.2335454673,
-0.038763281,
-0.0590154044,
-0.0346167609,
-0.1613659114,
-0.0630353242,
0.1615185291,
0.3088962734,
0.1701350957,
0.0492655672,
-0.1968121231,
-0.2860597968,
-0.1553858668,
0.275983423,
-0.127915144,
0.227507323,
0.0704156831,
-0.0415071473,
0.1180110723,
0.4343193769,
-0.0808835626,
0.9347211123,
0.0018426492,
0.0353127196,
0.2009413242,
-0.0580961369,
-0.1939641088,
0.4690675437,
0.3363730013,
0.0795792937,
0.4199272394,
0.1105651781,
0.114820309,
-0.4306527674,
-0.3719192743,
0.0825792998,
0.1898144037,
-0.2700969279,
0.1599574089,
0.0176515244,
0.2466035038,
-0.1401053071,
0.2512789965,
0.1002485603,
-0.0306328852,
-0.0855208933,
0.3962350786,
-0.1278313398,
0.1714202613,
-0.2369765341,
-0.0856292844,
0.0760537982,
0.0443347655,
-0.2041535527,
-0.0555026233,
-0.2001538575,
0.001197692,
0.3533699214,
-0.0825897306,
0.2602199614,
0.1714713722,
-0.1662052721,
-0.3480177522,
-0.1021389216,
0.0529838502,
-0.00164828,
0.3050313592,
0.0911475867,
0.3521175086,
-0.2378349155,
-0.4682133794,
0.0269449018,
-0.2420989424,
0.0018657747,
-0.0206022616,
-0.1888467818,
-0.1621980816,
-0.2402482629,
-0.3338271081,
-0.0726365149,
-0.4041884243,
-0.0565469041,
-0.2005322278,
0.0834289193,
-0.3380368948,
0.3115384579,
0.0962423608,
0.3443050086,
-0.248973161,
-0.1792116016,
-0.1861671358,
0.1535691321,
-0.0508963019,
-0.2393210232,
0.2430554479,
0.3084747791,
0.4400071502,
0.1545724273,
-0.5992290378,
0.1837328672,
-0.150649175,
0.1672733426,
-0.195725143,
0.1524518728,
0.0500745922,
-0.1618418396,
0.1141157448,
-0.0103035932,
-0.0273137819,
-0.2719118595,
-0.0725420564,
0.3267697692,
-0.0703835115,
0.5273268819,
0.2026776373,
0.723359108,
0.3773346841,
-0.2953709662,
0.3126842678,
0.0719994232,
0.0956476703,
-0.1472787261,
-0.1434148252,
0.2773806751,
-0.1821620613,
-0.1853200644,
0.0702297464,
-0.2321491539,
-0.5769819021,
-0.0990289077,
0.1574501991,
-0.2186321169,
-0.2639428079,
0.074867636,
0.2448432446,
0.2539407015,
-0.0733197406,
0.1209895834,
0.2655363679,
-0.0991027877,
0.1331713796,
0.4379664958,
-0.2614843547,
-0.0384697467,
-0.1116078123,
-0.172404632,
-0.5118253827,
0.2406246066,
-0.1886292696,
0.5073842406,
0.097994566,
0.1049618348,
0.0869249478,
-0.3579382598,
0.3812223971,
-0.0550461262,
0.2018284202,
-0.0163458623,
0.2828392982,
-0.1791750938,
-0.2083454579,
-0.3531242013,
0.2340702564,
0.2537631392,
0.0050592488,
-0.065417096,
0.0361537449,
0.047615476,
-0.1950803399,
0.1537523419,
-0.3294378519,
-0.1655430347,
-0.3021996319,
-0.43603459,
0.3359627128,
-0.0081325881,
-0.0437041558,
-0.2305707335,
-0.4514518678,
-0.0066833026,
-0.0631090254,
0.0632215291,
0.1166617647,
-0.2852269411,
-0.1145218983,
0.4135974646,
-0.3531017303,
-0.3471184075,
0.2988021672,
0.3625477254,
0.1299886853,
-0.1045848355,
0.3831590712,
-0.033169318,
0.1699850857,
0.3341363668,
-0.1411636323,
-0.0320507288,
0.0516833439,
0.0687604919,
-0.1328261495,
0.1318202764,
0.3128350973,
0.1458269507,
-0.057439398,
0.3416563869,
0.425216198,
-0.0428810231,
-0.0342332274,
0.6525977254,
-0.1020414755,
-0.1602929235,
0.3260679841,
0.020007804,
0.6784617305,
0.1621540189,
-0.0609979294,
0.1173903197,
-0.4070155025,
0.3931460083,
-0.0751367509,
0.1191712618,
-0.2827619016,
0.0084784199,
0.0364901796,
-0.0289383605,
0.3885406554,
0.1470670551,
0.0406048037,
0.0707360953,
0.1024739519,
0.4265255034,
0.0028300225,
0.1302879304,
-0.6085476279,
-0.3524171412,
-0.4235704839,
0.1457188427,
-0.0403761715,
0.2298244387,
-0.3128098845,
0.1943392456,
0.233191669,
-0.2996075451,
-0.6230086684,
0.1697416902,
-0.4782597423,
0.0762458518,
-0.3338229656,
-0.3413332999,
0.2836834788,
0.209254548,
-0.0368352197,
0.2516844273,
-0.0109357256,
0.4111859202,
0.0488494709,
0.0287460908,
0.0737638548,
-0.115553081,
-0.2076582313,
-0.044364769,
-0.0675797388,
0.2769902349,
-0.0577368774,
-0.0576796234,
0.2004082501,
0.0722137615,
0.0401255526,
-0.019669544,
-0.1822921038,
-0.0679147467,
-0.214237839,
-0.1997290999,
0.1328413188,
-0.0263288729,
-0.1179969609,
0.4299728572,
-0.3922124207,
-0.006176475,
-0.1551785618,
0.5715031028,
-0.2143812031,
-0.2144821882,
0.1664054841,
0.3999162614,
-0.0226512123,
-0.2823860943,
0.1876357943,
-0.2433884293,
-0.3244304657,
-0.0396128595,
-0.0026301753,
0.0178907625,
0.2225672156,
0.2324030548,
0.1625096202,
0.0470108427,
0.0202545524,
-0.3584121168,
-0.1823165119,
0.0298636258,
-0.006172176,
0.4070484638,
0.0904695317,
-0.0006924879,
-0.2453876287,
-0.0623938479,
-0.2192386091,
0.0884702057,
-0.1749339849,
0.1047568843,
0.2353363335,
0.0958799422,
0.2981978357,
-0.0459634773,
0.0089578349,
0.448451072,
-0.0699661449,
-0.1483484954,
-0.0925107747,
0.1618647426,
0.28472206,
0.0389569774,
0.0090930099,
-0.3021151125,
-0.1004519686,
0.0410585143,
0.5126981735,
-0.0007212282,
-0.2654445171,
-0.0549469925,
-0.0515648685,
0.0797211006,
-0.3798291087,
-0.0251882225,
-0.0147454813,
0.3985373676,
0.0121558663,
0.2206330895,
0.1868208051,
0.0004660437,
-0.0657556206,
-0.0321189277,
-0.200491935,
0.3470482528,
0.2438324988,
-0.2628346682,
-0.1885360181,
-0.1161472127,
0.1353141367,
0.5015127659,
-0.2084894031,
-0.1406572461,
0.0169496164,
0.1924513131,
0.0708339959,
-0.1463118941,
0.0320697092,
0.0180354342,
-0.1015957594,
0.0643146262,
-0.1109844223,
-0.438604027,
0.0762816146,
0.0391955897,
0.4953440428,
-0.3610793948,
0.0550586246,
0.192486465,
-0.0844763741,
0.2255742252,
-0.0777699649,
-0.1581431776,
0.3030310273,
0.427283138,
-0.1432223171,
0.1047329754,
0.3196305931,
0.2709394395,
0.0879244655,
-0.3692186773,
-0.4591331184,
-0.0749712139,
-0.0327205919,
0.4876669049,
0.2349456251,
-0.0213120058,
-0.0899745524,
-0.1113712415,
-0.3564125597,
-0.1241109744,
-0.2779701948,
0.0079514226,
-0.3692465723,
-0.0271821227,
0.1514748931,
0.2016352266,
-0.0676029027,
-0.0800026655,
0.3866184652,
0.1281506866,
-0.0828471705,
-0.2630200088,
-0.0988990664,
0.368253231,
-0.1341264993,
-0.2118138671,
0.1624809206,
0.1477592736,
-0.0172718782,
-0.4945043027,
-0.0203003008,
0.5871213675,
0.0873366147,
0.0176757649,
0.202169314,
0.2980763614,
0.0525111705,
0.0830038339,
0.2261931747,
0.1220550016,
0.2426116765,
0.2064509243,
0.0788632408,
-0.0863376781,
0.0209844057,
0.4052416682,
-0.0687142164,
-0.2241511196,
-0.1767599732,
-0.2439138889,
0.0398090407,
-0.1336181313,
0.2067461908,
-0.3149637282,
0.0367994085,
0.2709009945,
-0.1248276234,
-0.0045045349,
-0.0629224628,
0.0522667505,
-0.2461694926,
0.3415251076,
0.2168300897,
0.2571910322,
-0.4328170419,
-0.1297678798,
-0.2592497468,
0.2108002007,
0.1108193696,
0.3747046292,
-0.0043408806,
0.0904390588,
-0.2460390627,
0.1084312424,
0.326903373,
-0.0202267822,
0.1218474582,
0.7604519129,
-0.3103656769,
-0.207502231,
-0.201133579,
-0.3277758956,
0.0071020219,
-0.4412897825,
0.0310629271,
-0.2277204394,
-0.1403623074,
-0.3331094086,
-0.3041557968,
0.0203610286,
-0.2023557425,
0.6579099894,
-0.0170967598,
0.3220217228,
-0.2165225595,
-0.0754067302,
-0.219499588,
-0.2107925266,
0.1322598159,
0.0122289686,
0.0074423747,
0.31691733,
-0.1602109522,
0.1062884852,
-0.0901957452,
-0.1612550169,
-0.0282868166,
-0.1654983014,
-0.1335004121,
0.0047107693,
-0.3299820423,
0.1479508132,
-0.0516794063,
0.4668426812,
0.1600505263,
0.2423472553,
-0.5066174865,
-0.2766636908,
0.2805413306,
-0.2836249769,
-0.1941786408,
-0.0448576324,
0.2992550731,
0.2431400567,
0.0290373899,
-0.5353298187,
-0.0006401189,
0.1387707591,
-0.2683946788,
-0.288533479,
-0.0028228289,
0.1455621272,
-0.0265475567,
0.0572278723,
0.2294559628,
0.1681772619,
-0.1840462089,
0.3629613221,
-0.4666096866
] |
https://github.com/huggingface/datasets/issues/3310 | Fatal error condition occurred in aws-c-io | I see the same error in Windows-10.0.19042 as of a few days ago:
`Fatal error condition occurred in D:\bld\aws-c-io_1633633258269\work\source\event_loop.c:74: aws_thread_launch(&cleanup_thread, s_event_loop_destroy_async_thread_fn, el_group, &thread_options) == AWS_OP_SUCCESS`
python 3.8.12 h7840368_2_cpython conda-forge
boto3 1.20.11 pyhd8ed1ab_0 conda-forge
botocore 1.23.11 pyhd8ed1ab_0 conda-forge
...but I am not using `datasets` (although I might take a look now that I know about it!)
The error has occurred a few times over the last two days, but not consistently enough for me to get it with DEBUG. If there is any interest I can report back here, but it seems not unique to `datasets`. | ## Describe the bug
Fatal error when using the library
## Steps to reproduce the bug
```python
from datasets import load_dataset
dataset = load_dataset('wikiann', 'en')
```
## Expected results
No fatal errors
## Actual results
```
Fatal error condition occurred in D:\bld\aws-c-io_1633633258269\work\source\event_loop.c:74: aws_thread_launch(&cleanup_thread, s_event_loop_destroy_async_thread_fn, el_group, &thread_options) == AWS_OP_SUCCESS
Exiting Application
```
## Environment info
- `datasets` version: 1.15.2.dev0
- Platform: Windows-10-10.0.22504-SP0
- Python version: 3.8.12
- PyArrow version: 6.0.0
| 95 | Fatal error condition occurred in aws-c-io
## Describe the bug
Fatal error when using the library
## Steps to reproduce the bug
```python
from datasets import load_dataset
dataset = load_dataset('wikiann', 'en')
```
## Expected results
No fatal errors
## Actual results
```
Fatal error condition occurred in D:\bld\aws-c-io_1633633258269\work\source\event_loop.c:74: aws_thread_launch(&cleanup_thread, s_event_loop_destroy_async_thread_fn, el_group, &thread_options) == AWS_OP_SUCCESS
Exiting Application
```
## Environment info
- `datasets` version: 1.15.2.dev0
- Platform: Windows-10-10.0.22504-SP0
- Python version: 3.8.12
- PyArrow version: 6.0.0
I see the same error in Windows-10.0.19042 as of a few days ago:
`Fatal error condition occurred in D:\bld\aws-c-io_1633633258269\work\source\event_loop.c:74: aws_thread_launch(&cleanup_thread, s_event_loop_destroy_async_thread_fn, el_group, &thread_options) == AWS_OP_SUCCESS`
python 3.8.12 h7840368_2_cpython conda-forge
boto3 1.20.11 pyhd8ed1ab_0 conda-forge
botocore 1.23.11 pyhd8ed1ab_0 conda-forge
...but I am not using `datasets` (although I might take a look now that I know about it!)
The error has occurred a few times over the last two days, but not consistently enough for me to get it with DEBUG. If there is any interest I can report back here, but it seems not unique to `datasets`. | [
-0.5499545336,
-0.0519863255,
-0.09508048,
0.0924665034,
0.0359084643,
-0.0551969595,
0.2764567733,
0.1207169741,
0.0653902963,
0.1175083295,
-0.0487395078,
0.6524448991,
0.0359029174,
0.133851558,
-0.2451501042,
0.0767988414,
0.2522391081,
0.2151824683,
-0.4482079744,
0.2373424619,
-0.2854835987,
0.3709986508,
-0.2946824133,
0.1192940772,
-0.10029082,
-0.2287340611,
-0.1983655393,
0.20685938,
0.1315041482,
-0.3093939424,
0.3265756965,
-0.2388521284,
0.2607099116,
0.3707391322,
-0.0001157608,
-0.0917859226,
0.4071692228,
0.148690328,
-0.3117604256,
0.0608843379,
-0.3279655874,
0.098650448,
0.0363713615,
-0.2565175295,
0.4048959315,
0.2050232142,
-0.02499892,
-0.2850674391,
0.1051979512,
0.5059041381,
0.164606005,
0.7699397206,
0.194399491,
-0.0498257689,
-0.0817567781,
0.0031185325,
-0.2729866207,
0.3502184451,
0.2688422203,
-0.369284302,
0.1845426261,
0.1368415207,
-0.1802812219,
0.0859850422,
-0.0347465947,
-0.0931606814,
0.0909111872,
-0.2314381152,
0.2387264073,
-0.012606916,
0.3991872668,
-0.4874468744,
-0.2710637152,
0.143396616,
0.0923841149,
-0.2043913007,
0.3033299446,
0.239580825,
-0.151204586,
0.206798315,
0.179019928,
0.3022569418,
-0.2204628736,
0.1466666609,
-0.0315939188,
0.1247438788,
-0.1796293706,
0.11602474,
-0.0641093627,
0.0285728723,
0.0609194413,
-0.2030085623,
-0.220576033,
0.0241066385,
-0.7777591348,
0.0045287339,
-0.0353004746,
0.3059520423,
-0.0020859179,
-0.0201334674,
0.0530151539,
-0.2604513764,
0.3260267377,
0.158352986,
0.0854597986,
-0.1748960316,
0.064942196,
0.0954029262,
0.2698767781,
0.0368408747,
0.0433922112,
-0.0771568716,
-0.1067200527,
-0.4406808913,
0.2347750664,
0.0963893831,
0.4120787978,
-0.1730632931,
-0.589011848,
0.4901894927,
-0.4142445028,
0.2129436731,
-0.0865226164,
0.3402367234,
0.0241554454,
-0.0961450189,
0.1311387271,
0.2550384402,
-0.3748913705,
0.2042336613,
-0.0502571575,
0.0906015635,
-0.147999227,
0.0254562013,
0.2121169865,
-0.3565873504,
0.1356443912,
0.2735171616,
0.1095334291,
-0.3662677407,
0.0266194604,
0.0036829363,
-0.3870201707,
0.309395045,
0.1323302835,
0.2463442683,
-0.0133627625,
0.21171242,
0.100587979,
0.3257828653,
-0.0256928205,
-0.29298383,
-0.4018706381,
0.2093170881,
-0.0628749877,
0.096986331,
-0.0543978401,
-0.2722680867,
0.2890057564,
-0.048612535,
0.2352814972,
-0.2277193516,
0.0832826346,
-0.1051632464,
0.0331251696,
0.262488246,
-0.1651194245,
0.130304575,
-0.2411627769,
-0.1495911181,
0.113512069,
0.160461247,
-0.1007714719,
0.008978989,
-0.4193942249,
-0.0071926336,
0.0395270176,
-0.0793138742,
-0.2452778667,
0.3874913454,
-0.035561163,
-0.0186599065,
-0.0620496646,
-0.162650913,
-0.0758561492,
-0.1104480028,
-0.0178956892,
-0.4756784737,
0.0559364483,
-0.0080141099,
-0.2914662063,
-0.3126811385,
0.1069754884,
0.1609327197,
0.2130124122,
-0.0402936302,
0.2886611223,
-0.0392492935,
0.3231604993,
-0.0513693914,
-0.0660371706,
0.2187791169,
0.3184036314,
-0.3267131746,
0.0563049279,
-0.1440399736,
-0.5493640304,
0.2409832031,
0.2527565956,
0.196308732,
-0.0165660661,
-0.0629064068,
-0.0942294002,
0.3367316723,
0.0385844707,
-0.1820251644,
0.0945252627,
-0.104287304,
-0.0103585022,
-0.1380602419,
-0.2619068325,
0.441339612,
-0.6677668691,
0.1126742437,
-0.1301283538,
0.1367957443,
-0.2374381721,
-0.3212200701,
0.0351992287,
-0.1402150095,
0.1950991899,
0.1580635905,
-0.2582459152,
0.1766112596,
-0.157815516,
0.4828456044,
-0.1985139847,
0.3389184177,
0.0324965082,
-0.3154920042,
-0.0294281039,
0.1426784396,
0.1578568667,
0.0499505326,
0.2831945717,
0.217572242,
-0.2182431519,
0.2862237692,
-0.1284542084,
-0.0120513346,
0.0301051792,
-0.0502829477,
-0.0200289283,
0.114865154,
0.4177231193,
0.1449841261,
0.2610105872,
-0.1689376384,
-0.4338129759,
-0.1010694429,
0.1344827712,
-0.0662300438,
0.1614041328,
0.0377268605,
-0.0388795622,
0.0679810792,
0.4430505633,
-0.1025339887,
0.8532714248,
-0.0847849399,
-0.0818995908,
0.2397217304,
-0.1352394968,
-0.2134366035,
0.5190566182,
0.2231744379,
0.085431464,
0.5037112832,
0.1369891316,
0.1201836988,
-0.2697923779,
-0.5076431036,
0.0977119729,
0.2017126381,
-0.3069104552,
0.2155215293,
-0.0066148965,
0.160861209,
-0.1376802176,
0.196337685,
0.0677707568,
-0.0010171686,
-0.0749841109,
0.3435778618,
-0.1497750282,
0.2012770772,
-0.2218021303,
0.0472305864,
-0.0674042329,
0.2412843555,
-0.3252990246,
-0.0944623724,
-0.2167848349,
0.0150364507,
0.1082332209,
-0.1634306014,
0.2965618968,
0.0087111276,
-0.0587374046,
-0.2329645157,
-0.0927875936,
0.0088473624,
0.1232946068,
0.3535719812,
0.2354680151,
0.2022422105,
-0.1104895622,
-0.5874229074,
0.0417115539,
-0.227130264,
-0.0078616077,
-0.0638491288,
-0.2713924646,
0.0055239927,
-0.2999744415,
-0.2054312378,
-0.0234903246,
-0.4739429951,
0.0252040084,
-0.4458578825,
0.0390362032,
-0.0838098153,
0.1785552651,
0.1490821987,
0.3993598521,
-0.1303741485,
-0.2798659205,
-0.2293708771,
0.0465253331,
-0.0348297432,
-0.1626738012,
0.1588021666,
0.2172313929,
0.4926838279,
0.0797185004,
-0.3393376172,
0.2580156624,
-0.1195008904,
0.1867920607,
-0.1811490059,
0.0491641276,
0.1079761535,
-0.0956413671,
0.0338959172,
-0.1273284703,
0.029783994,
-0.1947278082,
-0.0628016144,
0.2559401393,
-0.0705880299,
0.4808875024,
0.148395732,
0.4612824321,
0.3384512067,
-0.3334412873,
0.2188147008,
0.0769833177,
0.1375111043,
-0.0855766237,
-0.2624497116,
0.190439865,
-0.1460715532,
-0.3771359622,
0.0331763886,
-0.2544745803,
-0.2917659283,
-0.1037987694,
-0.0660813376,
-0.2650919259,
-0.3019341826,
0.04224585,
-0.0241747238,
0.2734473348,
-0.1112278998,
0.0801885799,
0.1956406683,
0.0892508402,
0.1346595436,
0.5528957844,
-0.1441766322,
-0.166793108,
-0.0200296137,
-0.2627156675,
-0.5973225236,
0.2886921763,
-0.1197477877,
0.5577741861,
-0.0004005888,
0.1118673012,
0.0582773015,
-0.4026932418,
0.436816901,
-0.1289615184,
0.1737023592,
0.101000607,
0.2476247698,
-0.1589979678,
-0.30695346,
-0.2576058805,
0.2303998321,
0.2549822628,
0.0941582546,
-0.0622218959,
-0.0119139412,
0.0096121877,
-0.1725257188,
0.1112363264,
-0.3681079149,
-0.1105175912,
-0.2272206694,
-0.3403026462,
0.373666048,
0.0066285022,
0.065056555,
-0.2921548486,
-0.2281584144,
-0.0991380215,
-0.0498950258,
0.0947179794,
0.030086983,
-0.2944427431,
-0.2033981085,
0.4737986028,
-0.2385879457,
-0.2888427377,
0.4684759974,
0.223367855,
0.1635232866,
-0.1380645037,
0.2582837641,
0.1014533639,
0.1912663132,
0.2531491518,
-0.1921500266,
0.0302219,
0.1169774756,
0.1452491879,
-0.2197419703,
0.1431375593,
0.2654211223,
0.1652568728,
-0.2215102911,
0.2164495438,
0.2566339672,
-0.0451054126,
-0.1023433208,
0.8201965094,
-0.2270542234,
-0.2019480616,
0.265920043,
-0.0122385472,
0.6963158846,
0.3141005337,
-0.0248486809,
0.274929136,
-0.4792165458,
0.3341405988,
-0.0688576624,
0.129610166,
-0.3208342195,
0.0899108872,
0.1203150153,
-0.0521401726,
0.4120511711,
0.0919160321,
0.0993123204,
-0.0517617427,
0.0975841284,
0.2743799388,
0.0017150389,
0.0072825775,
-0.5819390416,
-0.2476270199,
-0.3246133626,
0.1295788288,
-0.0624702014,
0.2480040044,
-0.3686098754,
0.21144633,
0.2427602261,
-0.3461924791,
-0.6382433772,
0.2329689264,
-0.3344281912,
0.2247100174,
-0.2326604724,
-0.3397753537,
0.1636851132,
0.0713154078,
0.1018951684,
0.2266633958,
0.0481980331,
0.3509864211,
0.1040817648,
0.0801929832,
-0.0092800343,
-0.2638886869,
-0.1302826554,
0.0441278927,
-0.1927155256,
0.1134966835,
-0.2044619471,
-0.0738520324,
0.1577668488,
0.0927200243,
-0.2376950383,
-0.0096581951,
-0.115735881,
-0.0112250857,
-0.1404126585,
-0.1756891906,
0.1563717127,
0.0520336628,
-0.0456961244,
0.4244812429,
-0.6460196376,
-0.052669879,
-0.1436980516,
0.4721560776,
-0.2237553149,
-0.0857692733,
0.1416811198,
0.3041332364,
-0.0502898954,
-0.2521158457,
0.0370285213,
-0.2387576401,
-0.2549446821,
0.0046277489,
0.0102889594,
0.089747116,
0.3478771448,
0.2112496495,
0.1005906761,
0.1137598976,
0.0910904035,
-0.4110886455,
-0.1661392748,
0.1254959852,
-0.0769337863,
0.4191846848,
0.1967000216,
0.1555691063,
-0.3591775,
-0.1609001905,
-0.233676821,
0.0473489985,
-0.0570357107,
0.0765087381,
-0.0546453446,
0.0574045964,
0.3659692109,
-0.0982892364,
0.0410151966,
0.3851538301,
-0.0095801149,
-0.1332189739,
-0.2089734674,
0.1386453956,
0.2057302147,
-0.0426664054,
0.1810144782,
-0.2095532268,
0.0834737048,
0.0069384463,
0.479123354,
0.1554045379,
-0.2164479941,
-0.0308680944,
-0.0317221694,
0.1524513364,
-0.2828722894,
0.0276442077,
0.0183535665,
0.3728740811,
0.0086347973,
0.239740774,
0.0047084936,
0.0421349481,
-0.0294802636,
-0.0703511834,
-0.3500629365,
0.2288783789,
0.1485865861,
-0.1922791451,
-0.2613731921,
-0.215791598,
0.2955484092,
0.3148609698,
-0.1533827037,
-0.1099674851,
0.0052013253,
0.2159427553,
0.0265641809,
-0.0515265837,
-0.0216334965,
0.0039561116,
-0.1643411666,
0.0222217496,
-0.0733533949,
-0.4028475583,
0.041326046,
0.0126999896,
0.3487910926,
-0.4518182278,
0.1537632197,
0.258487612,
0.0390486456,
0.2855170071,
0.0884466544,
-0.2318108827,
0.4138804674,
0.4094995558,
-0.1369054466,
0.0638938174,
0.5381727219,
0.277317822,
0.210910067,
-0.391274333,
-0.3996813893,
-0.1356006265,
-0.1926837265,
0.301833719,
0.1556144506,
-0.1508709341,
-0.1929193884,
0.0422244221,
-0.3284336627,
-0.0168587994,
-0.3345433772,
-0.0747022703,
-0.2128583044,
-0.0442560576,
0.3052865267,
0.0777452737,
0.0429359004,
0.0882412568,
0.4079174995,
0.120925419,
-0.0558679104,
-0.3429783285,
-0.101876758,
0.4507036209,
0.023357708,
-0.1191108823,
-0.0252946075,
0.3041795492,
-0.166045174,
-0.4921851754,
0.233558476,
0.7798621058,
0.0803893358,
-0.0106593678,
0.0813806877,
0.2162917852,
0.1851859838,
0.0678924322,
0.2161912471,
0.1104382575,
0.220026359,
0.1615923941,
0.1090178117,
-0.0931855515,
0.1871133447,
0.4082008004,
0.0103716692,
-0.2020870298,
-0.1521662474,
-0.2506228983,
0.0082727624,
-0.0351508409,
0.4417702258,
-0.2970511913,
0.0994005874,
0.4669774175,
-0.0676693991,
-0.0527262241,
-0.0250654388,
0.0701194406,
-0.1502191573,
0.3508065343,
0.2500783503,
0.3387396932,
-0.4030467868,
-0.1500457525,
-0.1515474021,
0.2248388231,
0.0716779903,
0.4849932194,
-0.1579151452,
-0.006191629,
-0.3128000498,
-0.1133336425,
0.2733083665,
-0.0833278,
0.1285687685,
0.7740316987,
-0.2859772742,
-0.1048945636,
-0.1140393093,
-0.4571277499,
0.0812765583,
-0.4259439111,
0.0277484432,
-0.1606450677,
-0.0801025406,
-0.2916432619,
-0.2057498395,
0.2516867518,
-0.1721052974,
0.6512352228,
0.0499089733,
0.257869482,
-0.1843812764,
-0.1171949953,
-0.3142887354,
-0.3332763016,
0.2324328572,
0.156780228,
-0.0438576676,
0.2950524986,
-0.1348507255,
-0.0035529747,
-0.0330772474,
-0.1401259303,
-0.1456563324,
-0.2464125305,
-0.1210480183,
0.0934056267,
-0.3021015227,
0.0179671813,
-0.1446860433,
0.5091731548,
0.1575970948,
0.2798229456,
-0.4417782128,
-0.3822163045,
0.1696914285,
-0.4895388782,
-0.208908394,
-0.1688125134,
0.3892956674,
0.1236237586,
0.0392404012,
-0.5031632185,
-0.064564608,
0.2206791192,
-0.1403032392,
-0.2223508358,
-0.0022706576,
0.290345192,
-0.0209974628,
0.0555661283,
0.3383873701,
0.1337960958,
-0.144930169,
0.3568653762,
-0.3620723784
] |
https://github.com/huggingface/datasets/issues/3310 | Fatal error condition occurred in aws-c-io | I'm not sure what `datasets` has to do with a crash that seems related to `aws-c-io`, could it be an issue with your environment ? | ## Describe the bug
Fatal error when using the library
## Steps to reproduce the bug
```python
from datasets import load_dataset
dataset = load_dataset('wikiann', 'en')
```
## Expected results
No fatal errors
## Actual results
```
Fatal error condition occurred in D:\bld\aws-c-io_1633633258269\work\source\event_loop.c:74: aws_thread_launch(&cleanup_thread, s_event_loop_destroy_async_thread_fn, el_group, &thread_options) == AWS_OP_SUCCESS
Exiting Application
```
## Environment info
- `datasets` version: 1.15.2.dev0
- Platform: Windows-10-10.0.22504-SP0
- Python version: 3.8.12
- PyArrow version: 6.0.0
| 25 | Fatal error condition occurred in aws-c-io
## Describe the bug
Fatal error when using the library
## Steps to reproduce the bug
```python
from datasets import load_dataset
dataset = load_dataset('wikiann', 'en')
```
## Expected results
No fatal errors
## Actual results
```
Fatal error condition occurred in D:\bld\aws-c-io_1633633258269\work\source\event_loop.c:74: aws_thread_launch(&cleanup_thread, s_event_loop_destroy_async_thread_fn, el_group, &thread_options) == AWS_OP_SUCCESS
Exiting Application
```
## Environment info
- `datasets` version: 1.15.2.dev0
- Platform: Windows-10-10.0.22504-SP0
- Python version: 3.8.12
- PyArrow version: 6.0.0
I'm not sure what `datasets` has to do with a crash that seems related to `aws-c-io`, could it be an issue with your environment ? | [
-0.5580906868,
-0.0866051167,
-0.1800108254,
0.2331554592,
0.1390397102,
-0.0578074157,
0.1020180956,
0.1604058444,
0.1959947348,
0.2191379368,
0.0472115204,
0.5035427213,
-0.08148662,
0.1524396539,
-0.0512856543,
-0.0705785975,
0.2270471007,
0.1326992959,
-0.3635615408,
0.2618990839,
-0.2235796601,
0.2627207637,
-0.2026830614,
0.1686507165,
-0.2237054259,
-0.193131268,
-0.1214236319,
0.2672082484,
-0.1306809038,
-0.301142633,
0.3730953336,
-0.2657854259,
0.2278277725,
0.4516444206,
-0.0001039624,
-0.0457097813,
0.2753758132,
0.1424205154,
-0.3168177009,
-0.0783033371,
-0.3594658673,
-0.0492862761,
0.0719810054,
-0.3418895304,
0.3768464923,
0.1369369179,
-0.0497515798,
-0.2243693024,
0.1877655983,
0.4523926079,
0.285361141,
0.6975252032,
0.2334341705,
0.0338979512,
0.240661338,
-0.1576884389,
-0.2585336268,
0.2231758535,
0.2173845917,
-0.3406148553,
0.2064779997,
0.0588246174,
-0.2616662979,
0.0580961481,
0.11309167,
-0.0689569861,
0.0112825437,
-0.187652275,
0.0907400101,
-0.0828917474,
0.3635475338,
-0.4973252714,
-0.1244627014,
0.2313821763,
0.0128852194,
-0.3166197538,
0.159145996,
0.113545917,
-0.102604039,
0.1333548129,
0.0853154734,
0.1846500039,
-0.2870875001,
0.2660007477,
-0.1935052127,
0.3399457335,
-0.1535816789,
0.0781579986,
-0.0916253105,
0.0350059234,
0.0082823839,
-0.0728223249,
-0.2277335525,
0.1047400013,
-0.6485292912,
-0.0661292523,
0.0728501827,
0.246037364,
0.0991362631,
0.0072348905,
0.0361944139,
-0.0946310833,
0.1987976432,
0.2689356506,
0.075152792,
0.0318720005,
-0.0267763585,
0.0699837059,
0.3378071785,
0.1059997529,
-0.0680554137,
-0.1602004915,
0.0794102475,
-0.2515025735,
0.2491407692,
0.0540213771,
0.4665202498,
-0.2341666967,
-0.4691082835,
0.4084594846,
-0.3015960455,
0.1269180477,
-0.0450676717,
0.4228083491,
0.0739519671,
-0.1321831495,
0.1611854285,
0.104721792,
-0.2570319772,
0.1472050697,
-0.1638287902,
0.039782729,
-0.2234098911,
0.038236551,
0.121963717,
-0.2239408642,
0.1807435155,
0.1838333309,
0.1145098284,
-0.3768921494,
0.1691162735,
0.0192326121,
-0.3441358209,
0.3384669423,
0.1876031011,
0.1574774086,
0.0718116388,
-0.0348827392,
0.1204971001,
0.2261818796,
-0.2306180447,
-0.3109402657,
-0.309009105,
0.3398903906,
-0.0365159214,
0.0697592273,
-0.1349174231,
-0.2245215923,
0.1453901976,
-0.1713080406,
0.1508697122,
-0.2407561839,
0.2069620788,
-0.1823585629,
0.1344611496,
0.250184536,
-0.3147758842,
0.1470015794,
-0.3205109835,
-0.1503468901,
0.091367729,
0.2561937273,
-0.1589739919,
0.0352724828,
-0.3089305162,
0.0305993855,
0.1551472396,
0.0464306921,
-0.3182403743,
0.3583160639,
-0.0958067998,
-0.1559324116,
-0.094256185,
0.0234848876,
-0.0946476609,
-0.0589137264,
-0.0174797401,
-0.2600271702,
-0.0592314787,
0.1145751253,
-0.2355815023,
-0.284261167,
0.0446613133,
0.194451943,
0.2549017966,
-0.071017772,
0.3657620847,
-0.1082937196,
0.3347532451,
-0.1403300613,
-0.1671600938,
0.3004723489,
0.426100105,
-0.1566614509,
0.0489575453,
-0.3304820359,
-0.4977251291,
0.2141334713,
0.2226579189,
0.21730268,
-0.1248249412,
-0.1662076563,
-0.175357312,
0.3738298416,
0.0586370863,
-0.0506442413,
0.2119263411,
-0.049781546,
-0.0168524776,
-0.0617945604,
-0.2481015176,
0.2332935631,
-0.5981215239,
0.0709534883,
-0.2811796069,
0.2732843459,
-0.1892387718,
-0.317320466,
0.016003035,
-0.2112745196,
0.1684762686,
0.034031596,
-0.218044892,
0.265750587,
-0.2044208497,
0.4686378241,
-0.2001600862,
0.2894155085,
-0.0485168472,
-0.343021512,
0.1722515672,
0.0255457964,
0.1771011502,
-0.0134097142,
0.3564876914,
0.2049088329,
-0.2383442819,
0.2057050914,
-0.0585470311,
-0.0367575847,
-0.0100895902,
-0.1041613519,
0.07929755,
0.0572305769,
0.3227184415,
0.0277435519,
0.1451967061,
-0.2174709439,
-0.3156679571,
-0.1250320226,
0.2692943215,
-0.0032225878,
0.2474182397,
-0.0181317236,
-0.1586837173,
0.0984704047,
0.4700220525,
0.1214291528,
0.7873455882,
0.1902833134,
-0.1476651728,
0.1761025637,
-0.1848950833,
-0.1504384726,
0.4116473794,
0.193753615,
0.1181440204,
0.2728655338,
0.1356786937,
0.0356615745,
-0.4417085052,
-0.4641525149,
-0.1209664643,
0.2546760142,
-0.2979377508,
0.2971013784,
-0.0888512358,
0.0958382934,
-0.0707037598,
0.1168237701,
0.0200048927,
-0.1598556638,
-0.0914935246,
0.3216969073,
-0.1792330891,
0.0909570754,
-0.1593286991,
-0.0921290144,
0.0093544349,
0.0950327069,
-0.3576502502,
-0.1598637551,
-0.1707616597,
0.1308874786,
0.3484070599,
0.0027621703,
0.4173463583,
0.0619248375,
-0.1146876514,
-0.2451520413,
-0.1573430598,
-0.0206214413,
-0.1067989469,
0.3480916321,
0.201488331,
0.2467450351,
-0.245227918,
-0.4284566939,
0.0656441823,
-0.2069746107,
0.0409328379,
0.0008341019,
-0.1801216453,
-0.144722864,
-0.2529622018,
-0.3234043121,
-0.2212116122,
-0.403432101,
-0.0665814877,
-0.1826649457,
0.1247238591,
-0.1730832309,
0.2974701226,
0.1841197759,
0.3028047085,
-0.2465658933,
-0.1778050363,
-0.2766483724,
0.0815852582,
-0.0800495222,
-0.1049397439,
0.1979305297,
0.2295287997,
0.4112248421,
0.104614988,
-0.4618681669,
0.261021167,
-0.1656033397,
0.2572937012,
-0.1780201942,
0.1114291176,
0.1481207311,
-0.0206373557,
-0.0547721907,
-0.0662049577,
0.048046723,
-0.3267090023,
-0.0158720985,
0.288349539,
-0.1356640011,
0.5551947951,
0.0178563222,
0.6567829847,
0.1280539334,
-0.2948001623,
0.3476784229,
-0.0864528939,
0.0429035276,
-0.1535404176,
-0.198763743,
0.0465231799,
-0.0679714084,
-0.4468880594,
-0.0218195729,
-0.1974403709,
-0.3519890308,
-0.1563673913,
0.0304114148,
-0.2174781114,
-0.2082405239,
0.0185193624,
0.199867636,
0.2868546247,
-0.1216541156,
-0.0054874704,
0.0851351544,
-0.0030652862,
0.0676682591,
0.4041518867,
-0.2816104889,
-0.1678608805,
0.0073599634,
-0.205863148,
-0.5083901882,
0.2978719771,
-0.1528180242,
0.2315282375,
-0.0478007719,
0.1166428551,
0.0240504052,
-0.3297837079,
0.3545981944,
-0.1884183288,
0.0774114653,
0.1278833598,
0.2961114049,
-0.2285758853,
-0.1195123196,
-0.39419505,
0.2651305795,
0.2077030838,
0.0433521792,
-0.0434822924,
0.0147802532,
0.1462554485,
-0.0018209382,
0.0320286974,
-0.2892379463,
-0.1521969438,
-0.2384079993,
-0.2683716714,
0.227599889,
-0.0112857195,
-0.0801383629,
-0.2370703965,
-0.3360462189,
-0.0956183448,
0.0140747856,
0.1676747799,
0.1587537378,
-0.1463735104,
-0.2279443294,
0.2665718198,
-0.3570807278,
-0.2605814636,
0.4193133414,
0.3196933568,
0.1631897986,
-0.0633685142,
0.1843382269,
0.1552063525,
0.250218302,
0.1732443869,
-0.1887727827,
0.0893893614,
0.1634072512,
0.2277205288,
-0.0841829181,
0.107685186,
0.2585031092,
0.3000777066,
-0.1861465573,
0.147777766,
0.4156912565,
-0.0625969619,
-0.0312879235,
0.5311103463,
-0.0423997492,
-0.2936862707,
0.4011607468,
-0.0153296245,
0.629110992,
0.2332619876,
-0.0415668637,
0.3172386885,
-0.1596605033,
0.3324857652,
-0.1839747876,
0.040180169,
-0.3378224373,
0.0240878947,
0.0355181992,
-0.0865921527,
0.3674762845,
0.035060972,
-0.0478481837,
0.0812982097,
0.0274761859,
0.1571154147,
-0.1843261421,
0.0483391769,
-0.5356550813,
-0.1773063093,
-0.4494068921,
0.2904345989,
-0.1282727867,
0.1330974102,
-0.2986161411,
0.1988687962,
0.1727520227,
-0.2185153961,
-0.4346652031,
0.0916936174,
-0.2952578664,
0.2024278641,
-0.349839896,
-0.2793514431,
0.1895634681,
0.168641597,
0.0584162958,
0.2312836051,
-0.0551977046,
0.3662200868,
-0.0500894114,
-0.0501227863,
0.0393306799,
-0.1577363312,
-0.0867457986,
-0.0031640993,
-0.2936913967,
0.2833209336,
-0.1038802564,
-0.0545593463,
0.1974833757,
0.0432163514,
-0.087964192,
-0.0935268104,
-0.195131883,
-0.0211845152,
-0.17162624,
-0.1867473423,
0.2720815241,
-0.002456354,
-0.0300045963,
0.371106565,
-0.3489473164,
-0.0109045012,
-0.1315765083,
0.4350380599,
-0.0899923369,
-0.0426406227,
0.174024567,
0.3948284686,
-0.0536661372,
-0.340950489,
0.147066772,
-0.2369923145,
-0.2714913785,
0.0056850263,
0.0830113143,
0.1800326109,
0.2450961173,
0.1936038584,
0.1923660487,
0.0573338047,
-0.0590691194,
-0.252279073,
-0.3350843787,
0.1717640162,
0.1261824369,
0.4865533113,
0.2048872709,
-0.1615014523,
-0.3416012526,
-0.0770022571,
-0.3782078326,
0.036504887,
-0.1317994744,
0.0000394789,
0.0987524092,
0.1031697765,
0.2870587111,
-0.1436671019,
0.2116178274,
0.3779251575,
-0.0326131284,
-0.3035918176,
-0.0865578428,
0.0724710077,
0.1420319378,
0.0462565944,
0.1016369164,
-0.2391681969,
0.0346549824,
0.0630455539,
0.582172513,
0.0790341794,
-0.2099264264,
-0.0527974255,
-0.0181050058,
0.0058813421,
-0.279543519,
0.0830724016,
-0.0578820705,
0.215982765,
0.0266851764,
0.1286705136,
0.0881684273,
-0.0597053207,
0.0375236347,
-0.0487393141,
-0.2664936185,
0.3595657349,
0.3037901521,
-0.1936329752,
-0.2794946432,
-0.2129613608,
0.2041948289,
0.2199022174,
-0.1954599768,
-0.0756972805,
0.1035302356,
0.3542762697,
-0.0149998842,
-0.094419919,
-0.017012516,
0.0231145266,
-0.0534125715,
-0.0000374965,
-0.1101293191,
-0.3007382452,
0.0407497399,
0.1465880275,
0.3212403357,
-0.2797970772,
0.1066181287,
0.1117787063,
-0.045167774,
0.1365650743,
0.0065509095,
-0.1333215833,
0.3448506892,
0.4964200854,
-0.1746409237,
0.1804476231,
0.2726297081,
0.2587821782,
0.0568825975,
-0.2849077582,
-0.2352345437,
-0.1550303698,
-0.2374969572,
0.3246304989,
0.2310211807,
0.0100605395,
-0.0830596611,
0.0741833821,
-0.3367151916,
0.0128544997,
-0.2879087031,
0.1189590469,
-0.2816357315,
-0.0563020669,
0.2164167017,
0.0887622461,
-0.0269381143,
0.015498139,
0.2619755566,
0.2115812898,
-0.038574446,
-0.3402863145,
0.031404186,
0.3942582607,
0.0578412339,
-0.1006177664,
0.0656846911,
0.2548575401,
-0.1100495607,
-0.5073841214,
0.1399368644,
0.6200224757,
0.0525675416,
0.1367287934,
0.2394931316,
0.2292445749,
-0.01985039,
0.0822134987,
-0.0315396152,
0.0924934894,
0.3412432671,
0.1436094642,
0.2769788802,
-0.2479271442,
-0.0225345772,
0.2196147591,
0.0629021525,
-0.1933303326,
-0.2581029534,
-0.1533581018,
-0.1304941922,
-0.1438370645,
0.1664337367,
-0.5015864968,
0.0359907746,
0.4835572839,
-0.0236172434,
0.061700359,
-0.1306698024,
0.1275069565,
-0.1901892722,
0.334831059,
0.2485761791,
0.3589084744,
-0.3767673373,
-0.2370231003,
-0.2269173563,
0.1791288108,
-0.0109134857,
0.2871227562,
-0.0887073427,
-0.1171567887,
-0.1014375836,
-0.0477503128,
0.3598382771,
-0.0027883018,
0.0449483059,
0.6793603897,
-0.3237033188,
-0.1270293146,
-0.1954575926,
-0.4187269807,
-0.002754455,
-0.3169215322,
-0.0090122167,
-0.1949494034,
0.0522359721,
-0.3706084192,
-0.0353815481,
0.0838596895,
-0.1571118534,
0.8148203492,
-0.0380984135,
0.2887339294,
-0.3294123411,
-0.0067246365,
-0.1642251909,
-0.3030404747,
0.1844398975,
0.1101152971,
-0.0420306474,
0.4261196256,
-0.1150892228,
-0.0889137611,
-0.0921773016,
-0.045552291,
-0.0349981971,
-0.210597679,
-0.0782981589,
0.0475822799,
-0.2176689953,
0.0300922468,
-0.0681064203,
0.392768383,
0.2255887091,
0.1990047395,
-0.3079808354,
-0.2167676836,
0.277980119,
-0.1385700107,
-0.1392562538,
0.034742713,
0.2517085671,
0.1265808344,
-0.0456948355,
-0.4866902828,
-0.0201896504,
0.2172819823,
-0.1498814672,
-0.1899716258,
0.1460516155,
0.2467836589,
0.0543506481,
0.015165302,
0.235740006,
0.0702370182,
-0.1674107015,
0.3157313764,
-0.3643979728
] |
https://github.com/huggingface/datasets/issues/3310 | Fatal error condition occurred in aws-c-io | > I'm not sure what `datasets` has to do with a crash that seems related to `aws-c-io`, could it be an issue with your environment ?
Agreed, this issue is not likely a bug in datasets, since I get the identical error without datasets installed. | ## Describe the bug
Fatal error when using the library
## Steps to reproduce the bug
```python
from datasets import load_dataset
dataset = load_dataset('wikiann', 'en')
```
## Expected results
No fatal errors
## Actual results
```
Fatal error condition occurred in D:\bld\aws-c-io_1633633258269\work\source\event_loop.c:74: aws_thread_launch(&cleanup_thread, s_event_loop_destroy_async_thread_fn, el_group, &thread_options) == AWS_OP_SUCCESS
Exiting Application
```
## Environment info
- `datasets` version: 1.15.2.dev0
- Platform: Windows-10-10.0.22504-SP0
- Python version: 3.8.12
- PyArrow version: 6.0.0
| 45 | Fatal error condition occurred in aws-c-io
## Describe the bug
Fatal error when using the library
## Steps to reproduce the bug
```python
from datasets import load_dataset
dataset = load_dataset('wikiann', 'en')
```
## Expected results
No fatal errors
## Actual results
```
Fatal error condition occurred in D:\bld\aws-c-io_1633633258269\work\source\event_loop.c:74: aws_thread_launch(&cleanup_thread, s_event_loop_destroy_async_thread_fn, el_group, &thread_options) == AWS_OP_SUCCESS
Exiting Application
```
## Environment info
- `datasets` version: 1.15.2.dev0
- Platform: Windows-10-10.0.22504-SP0
- Python version: 3.8.12
- PyArrow version: 6.0.0
> I'm not sure what `datasets` has to do with a crash that seems related to `aws-c-io`, could it be an issue with your environment ?
Agreed, this issue is not likely a bug in datasets, since I get the identical error without datasets installed. | [
-0.5877727866,
-0.098560214,
-0.1441142559,
0.2184793502,
0.0923991203,
-0.0479464978,
0.1061487943,
0.1226170287,
0.2112212479,
0.1895913482,
0.0708782971,
0.5784412622,
-0.0558514819,
0.142910853,
-0.1018204689,
-0.060227938,
0.2509334981,
0.148444593,
-0.3987596035,
0.2907882035,
-0.2431583852,
0.2944350541,
-0.2579341233,
0.1939392835,
-0.2135606706,
-0.1925463825,
-0.1446971297,
0.2619643509,
-0.0919342116,
-0.3031490147,
0.3964146972,
-0.2560612857,
0.2435162812,
0.4746381044,
-0.0001061082,
-0.0802018568,
0.29478091,
0.1537579447,
-0.296140492,
-0.0700705647,
-0.3931902349,
-0.0043014311,
0.0910913125,
-0.3130132556,
0.4095441699,
0.1187762395,
-0.0355343632,
-0.25431934,
0.1728731096,
0.4458434284,
0.2461790293,
0.6981564164,
0.2192255855,
0.0276313052,
0.1673299223,
-0.1371042877,
-0.279489845,
0.2411755919,
0.2327432185,
-0.3658466339,
0.2037451118,
0.0629403293,
-0.272555232,
0.091716893,
0.1506552249,
-0.0715619773,
0.0003566897,
-0.2031453699,
0.1082319245,
-0.0729650706,
0.3915722966,
-0.5057066679,
-0.1164458245,
0.2129102051,
0.0425735861,
-0.3092789352,
0.1988962591,
0.1277352422,
-0.1396557689,
0.1549291015,
0.0949405655,
0.1978701055,
-0.3011853993,
0.27303496,
-0.1823951006,
0.2753692865,
-0.1561725736,
0.086613737,
-0.0651198924,
0.0592301227,
0.0309846774,
-0.1313209236,
-0.2017469704,
0.0839840621,
-0.6823881269,
-0.0654327422,
0.0735922009,
0.2899927199,
0.0798467919,
-0.0321774557,
0.0161204636,
-0.1202557385,
0.2045455724,
0.259676069,
0.0885534286,
-0.0285940804,
0.0108803231,
0.0731569678,
0.3260383308,
0.0965155885,
-0.0180211589,
-0.1428625137,
0.0893202573,
-0.2459666878,
0.2204300165,
0.0406364687,
0.4716634452,
-0.22805655,
-0.4993338287,
0.4374732673,
-0.3630464971,
0.1760658622,
-0.0628786162,
0.4015409648,
0.055238761,
-0.1487730592,
0.1606696695,
0.1476565748,
-0.2831786275,
0.1800119132,
-0.1238824651,
0.0437337197,
-0.2326860279,
0.0404606797,
0.1293590516,
-0.2264019549,
0.1680917889,
0.2273064703,
0.105102919,
-0.4078164101,
0.183770746,
0.039287962,
-0.3672150373,
0.3187617362,
0.1861785799,
0.1617942154,
0.061412476,
0.02857548,
0.1389397085,
0.2625073791,
-0.1644234061,
-0.3175091147,
-0.2961938679,
0.3135827184,
-0.0716398209,
0.0767011866,
-0.1445118636,
-0.2378246337,
0.1425107569,
-0.1406113952,
0.1529326737,
-0.2565338612,
0.1812168956,
-0.1505509466,
0.0858528391,
0.2588171661,
-0.2899450958,
0.1360149235,
-0.3475253284,
-0.1644182205,
0.076315552,
0.2417822778,
-0.1393267065,
0.0218467563,
-0.3356441259,
0.030200921,
0.1445575058,
0.0923066884,
-0.3059607744,
0.3889743984,
-0.0927611291,
-0.1098951176,
-0.1311430186,
0.0132039608,
-0.1080993414,
-0.0750204027,
-0.0288725831,
-0.3261514604,
-0.0640230924,
0.0589595363,
-0.2137886882,
-0.3036153018,
0.0653343871,
0.212797612,
0.2309682816,
-0.0334367491,
0.3607059121,
-0.0831278265,
0.3458634913,
-0.121403791,
-0.1659339666,
0.292809397,
0.4134375751,
-0.1757055074,
0.035088513,
-0.3258332908,
-0.5155245662,
0.2304552943,
0.2795443237,
0.2226513922,
-0.1216918975,
-0.1652117372,
-0.1621969044,
0.3786703944,
0.049451299,
-0.051093068,
0.177117914,
-0.0630856305,
-0.0590636767,
-0.0888911262,
-0.2687593102,
0.284109503,
-0.6477699876,
0.0853072032,
-0.2740429342,
0.2091199905,
-0.1813040674,
-0.3070006371,
0.0368244201,
-0.2117382586,
0.1424225271,
0.0616410449,
-0.2239399552,
0.2642253339,
-0.187546283,
0.4725884199,
-0.2061440945,
0.3058316112,
-0.0477042608,
-0.3777439594,
0.1214580908,
0.0293556061,
0.1648999751,
-0.0026105135,
0.3278172612,
0.1968505234,
-0.2226945907,
0.2401115447,
-0.0987496302,
-0.0053680572,
-0.034628246,
-0.0988169909,
0.0412727408,
0.084610194,
0.3563314676,
0.0248864852,
0.1307501793,
-0.2181728482,
-0.3548566997,
-0.1304550916,
0.2157488763,
0.0052129915,
0.2641456425,
-0.0064033358,
-0.1238357499,
0.1349171251,
0.4550621808,
0.0737373084,
0.8468426466,
0.1617289782,
-0.128949672,
0.2258804888,
-0.1658565253,
-0.1615799516,
0.4344459474,
0.1932590902,
0.1356623173,
0.272046715,
0.1133167222,
0.0397037417,
-0.4209650755,
-0.4879210293,
-0.0897919312,
0.2629651427,
-0.3018695712,
0.285569787,
-0.0599564537,
0.088558048,
-0.0724586397,
0.162951991,
0.0512416437,
-0.1267938763,
-0.0727090314,
0.3433228433,
-0.17853567,
0.113227576,
-0.1645230353,
-0.0806010216,
-0.0116327675,
0.1421691626,
-0.3507026136,
-0.1870559901,
-0.1730583161,
0.1033713371,
0.3211433291,
0.001908401,
0.4160148203,
0.0493781529,
-0.1268949807,
-0.2298737466,
-0.1113518104,
-0.0115339803,
-0.0860463455,
0.3279513717,
0.2397268862,
0.280023098,
-0.2422127277,
-0.3903713822,
0.0365052596,
-0.2309512049,
0.0416377001,
-0.0069018113,
-0.1970527768,
-0.1180887893,
-0.2494739145,
-0.3486536145,
-0.1644389927,
-0.4070201814,
-0.0493025035,
-0.244229272,
0.0923832804,
-0.1876922995,
0.2940327525,
0.1812494397,
0.319442898,
-0.2857074142,
-0.1931089908,
-0.258154273,
0.068186909,
-0.0474566072,
-0.106008172,
0.2231672406,
0.2655583024,
0.4115249813,
0.1044440418,
-0.4842066169,
0.2805035114,
-0.1529534012,
0.2557045519,
-0.1771908402,
0.1008091345,
0.1254774183,
-0.0445098951,
-0.0258189235,
-0.0750813931,
0.0647048056,
-0.2931644022,
-0.0349034034,
0.3022508025,
-0.116287142,
0.5645008087,
0.0615684167,
0.6580146551,
0.1730606705,
-0.285551548,
0.2953936458,
-0.0488661751,
0.0511870272,
-0.1462791562,
-0.2019897252,
0.0491038449,
-0.0766162872,
-0.431817472,
-0.0307377279,
-0.1982970983,
-0.3751920462,
-0.165032059,
0.0532247014,
-0.1936532706,
-0.2127109468,
-0.0164296515,
0.161103636,
0.3118450344,
-0.0987754092,
-0.0081059327,
0.13882263,
-0.0002074977,
0.0903852358,
0.4277154505,
-0.2527189553,
-0.1415842324,
-0.0061313398,
-0.2123953998,
-0.5335054994,
0.3040244281,
-0.1477408707,
0.2798677683,
-0.0722312257,
0.1450409889,
0.01941799,
-0.2960500419,
0.3518759906,
-0.1921930909,
0.083607398,
0.0940929204,
0.3269784749,
-0.235762164,
-0.1142164841,
-0.3964976966,
0.2922960818,
0.2148124874,
0.0179223139,
-0.0508577414,
0.0252614655,
0.1060138643,
-0.0269795302,
0.0763463452,
-0.3670830727,
-0.1592974961,
-0.2227609456,
-0.2621335089,
0.2768200636,
-0.0098872203,
-0.0764514804,
-0.2282310873,
-0.3526791036,
-0.0620616116,
0.0138117503,
0.1508833617,
0.1341553777,
-0.1877207011,
-0.2491467297,
0.2911714315,
-0.3398665786,
-0.3121227622,
0.4644320607,
0.2932397723,
0.183488667,
-0.0624331348,
0.2119359076,
0.1285064518,
0.2351511866,
0.1885219812,
-0.1996483654,
0.0902304724,
0.1984795034,
0.2127441615,
-0.1068151072,
0.1090631932,
0.2760262191,
0.286911875,
-0.1655616611,
0.157826215,
0.4090358913,
-0.0577574819,
-0.0517835394,
0.5761572123,
-0.0606906675,
-0.2606713176,
0.3539756238,
-0.012572174,
0.6446405649,
0.2618288696,
-0.0804760307,
0.3265303969,
-0.2221927047,
0.3644377291,
-0.157949537,
0.0667079464,
-0.3130831122,
0.0250644367,
0.0393106975,
-0.1090053096,
0.4168555737,
0.0506153703,
-0.0284527708,
0.0692724437,
0.0529512055,
0.144808501,
-0.1391046941,
0.0429326892,
-0.5745126009,
-0.1789743751,
-0.4493946433,
0.2573566735,
-0.12023139,
0.1495253593,
-0.3286215663,
0.2176515907,
0.1780650169,
-0.202510342,
-0.4687134624,
0.1203510761,
-0.2872034311,
0.2002820522,
-0.3471600413,
-0.2701260149,
0.2164055705,
0.1818542629,
0.0430736728,
0.2235281318,
-0.0665783584,
0.3683986366,
-0.0410802029,
-0.0099004516,
0.079411149,
-0.1864738017,
-0.1069784164,
0.0018493125,
-0.2770469487,
0.2729234397,
-0.136761412,
-0.0587948039,
0.229499504,
0.0309246574,
-0.0978097469,
-0.0597214922,
-0.2161882222,
-0.0530825406,
-0.1520682126,
-0.1824541241,
0.2448806465,
0.0116897998,
-0.0338581391,
0.3932693005,
-0.4257585406,
-0.0284025352,
-0.132863611,
0.4363248348,
-0.1182910576,
-0.0635260418,
0.1485374272,
0.4547611773,
-0.0548899844,
-0.3194854558,
0.1416909993,
-0.2296029627,
-0.2951293588,
-0.0060580755,
0.0821402594,
0.186515525,
0.2783510089,
0.1861223578,
0.1607145071,
0.0486081317,
-0.0228378326,
-0.2735723555,
-0.3049526215,
0.1429341882,
0.0860025808,
0.4669291973,
0.2051888108,
-0.1307760477,
-0.348388344,
-0.1300012618,
-0.341186434,
0.0380199775,
-0.0970260277,
0.0104622124,
0.0931753665,
0.1298187226,
0.294621557,
-0.146298185,
0.1624423563,
0.380366683,
-0.0622671917,
-0.2602926195,
-0.0829271004,
0.0890478343,
0.1655270308,
0.0422263518,
0.1007214636,
-0.2739262879,
0.0319654606,
0.0567312017,
0.5843464732,
0.0928846747,
-0.2535739839,
-0.1031346023,
-0.0464757569,
0.0156377498,
-0.2979592681,
0.0546661057,
-0.0501851812,
0.2156728655,
0.0022053181,
0.1140281558,
0.0928978398,
-0.0547714978,
0.0504880622,
-0.0330816619,
-0.2740882337,
0.3323741555,
0.2851106226,
-0.2236780524,
-0.2272243947,
-0.2018562853,
0.2487337738,
0.2420290112,
-0.1947976649,
-0.0934496447,
0.0702319071,
0.323300302,
0.0111145414,
-0.0509794243,
0.0175162777,
0.0367762856,
-0.0967479497,
0.0084992591,
-0.1319792122,
-0.3017049432,
0.0384580679,
0.1524217725,
0.3105238974,
-0.3362291455,
0.1305828691,
0.0984924436,
-0.0580319241,
0.1908246726,
0.0055286335,
-0.1392738074,
0.3531437814,
0.5201244354,
-0.1432794333,
0.1186958179,
0.3514404595,
0.28060776,
0.0515814424,
-0.3107586801,
-0.2750592828,
-0.1557125896,
-0.2479810566,
0.3123764694,
0.224933356,
-0.039125286,
-0.1274674237,
0.0826401711,
-0.3162580431,
-0.0309116412,
-0.3047650158,
0.1268811077,
-0.2448503077,
-0.0552899018,
0.2345934808,
0.0906447694,
-0.0230063926,
0.0364521109,
0.2739742398,
0.1911399961,
-0.038309034,
-0.3741284907,
0.0152639383,
0.404874146,
0.0293273181,
-0.1100550964,
0.0096764714,
0.2077846229,
-0.1329037994,
-0.5147720575,
0.1572996825,
0.6183252335,
0.0377056636,
0.1170557067,
0.236172989,
0.2545502186,
0.0167079158,
0.1087096184,
-0.0160047971,
0.0923485234,
0.35478127,
0.1523864567,
0.2325763404,
-0.2144242525,
0.0067564892,
0.2578388453,
0.1124519855,
-0.2155690044,
-0.2507314086,
-0.2071984559,
-0.0739067569,
-0.1059141308,
0.2391247004,
-0.4704256654,
0.0687514991,
0.507363081,
-0.0228638574,
0.0109576834,
-0.1396449357,
0.111194104,
-0.2067412287,
0.350213021,
0.2522877753,
0.3504842818,
-0.3920117319,
-0.2178424895,
-0.2204116732,
0.1789241582,
-0.0147125525,
0.3271959722,
-0.0709383264,
-0.1341926455,
-0.1389521658,
-0.0266810674,
0.3320887387,
-0.0005849599,
0.0621742681,
0.7321696281,
-0.2915217876,
-0.1618058383,
-0.1999339759,
-0.4271437824,
-0.0064474642,
-0.3201338947,
-0.0083664889,
-0.2253454626,
0.006902976,
-0.3423821628,
-0.0645588562,
0.1135380492,
-0.1563320905,
0.7495413423,
-0.0210592002,
0.282040298,
-0.274133563,
-0.026187161,
-0.159144327,
-0.3168539703,
0.1940860003,
0.1393232495,
-0.0458444506,
0.4355510771,
-0.1475430578,
-0.0769480094,
-0.0816116482,
-0.0803510919,
-0.0518455394,
-0.2298627198,
-0.1016415358,
0.0417920351,
-0.2780906856,
0.0794595256,
-0.0703053847,
0.4106260538,
0.2392021716,
0.218250975,
-0.333856225,
-0.2227075249,
0.2599413693,
-0.1702157855,
-0.1534058899,
0.0145681845,
0.2589745522,
0.1594025642,
-0.0711617768,
-0.5073263645,
-0.0463313311,
0.2009384483,
-0.14893879,
-0.210664615,
0.1045602337,
0.2295934558,
0.040528778,
0.0454818271,
0.2611165643,
0.0974286944,
-0.150696367,
0.3761036694,
-0.3497108519
] |
https://github.com/huggingface/datasets/issues/3310 | Fatal error condition occurred in aws-c-io | Will close this issue. Bug in `aws-c-io` shouldn't be in `datasets` repo. Nevertheless, it can be useful to know that it happens. Thanks @leehaust @lhoestq | ## Describe the bug
Fatal error when using the library
## Steps to reproduce the bug
```python
from datasets import load_dataset
dataset = load_dataset('wikiann', 'en')
```
## Expected results
No fatal errors
## Actual results
```
Fatal error condition occurred in D:\bld\aws-c-io_1633633258269\work\source\event_loop.c:74: aws_thread_launch(&cleanup_thread, s_event_loop_destroy_async_thread_fn, el_group, &thread_options) == AWS_OP_SUCCESS
Exiting Application
```
## Environment info
- `datasets` version: 1.15.2.dev0
- Platform: Windows-10-10.0.22504-SP0
- Python version: 3.8.12
- PyArrow version: 6.0.0
| 25 | Fatal error condition occurred in aws-c-io
## Describe the bug
Fatal error when using the library
## Steps to reproduce the bug
```python
from datasets import load_dataset
dataset = load_dataset('wikiann', 'en')
```
## Expected results
No fatal errors
## Actual results
```
Fatal error condition occurred in D:\bld\aws-c-io_1633633258269\work\source\event_loop.c:74: aws_thread_launch(&cleanup_thread, s_event_loop_destroy_async_thread_fn, el_group, &thread_options) == AWS_OP_SUCCESS
Exiting Application
```
## Environment info
- `datasets` version: 1.15.2.dev0
- Platform: Windows-10-10.0.22504-SP0
- Python version: 3.8.12
- PyArrow version: 6.0.0
Will close this issue. Bug in `aws-c-io` shouldn't be in `datasets` repo. Nevertheless, it can be useful to know that it happens. Thanks @leehaust @lhoestq | [
-0.4938253164,
-0.0435249135,
-0.1619390398,
0.1124572083,
0.0005887501,
0.0266229678,
0.1630836129,
0.1379013211,
0.1356272846,
0.1860264689,
0.0934361219,
0.5520917177,
0.0804899633,
0.135408476,
-0.1256678998,
0.0155789685,
0.2077867985,
0.2217728347,
-0.3824179471,
0.1959048659,
-0.3294412792,
0.3910720348,
-0.3236297071,
0.060481146,
-0.0910127908,
-0.2014019042,
-0.0965272784,
0.1838518381,
-0.0741330385,
-0.3202905357,
0.377315104,
-0.1569009125,
0.222290501,
0.5065467954,
-0.0001077082,
-0.1024590433,
0.3470099866,
0.1148459166,
-0.2696466446,
-0.0053395033,
-0.3656913042,
-0.0178388767,
0.0270231385,
-0.3889615536,
0.3263211846,
0.1310640424,
-0.0941239074,
-0.3168964684,
0.1611334831,
0.4751704633,
0.2513316274,
0.6279176474,
0.3082019985,
0.0525332354,
0.218140468,
-0.1322099715,
-0.2642518282,
0.2433603704,
0.2514427006,
-0.2611132264,
0.2589482367,
0.1845951825,
-0.2209502906,
0.0992274284,
0.0549070165,
-0.1115630493,
0.0417679809,
-0.1954502612,
0.16021128,
-0.0200486332,
0.4093446434,
-0.5027351379,
-0.234983474,
0.2365395725,
0.0497231521,
-0.3314446509,
0.3023519814,
0.2035972327,
-0.0532017834,
0.2081319392,
-0.0009449731,
0.1420983821,
-0.2929332852,
0.2008297741,
-0.0847635642,
0.2213109434,
-0.1767133176,
0.084863849,
-0.1494703889,
-0.0002355085,
0.0274472106,
-0.2316009998,
-0.1954453737,
0.0880153403,
-0.6789467931,
-0.1212133244,
-0.0078141699,
0.2558232248,
0.1618278623,
-0.0224847533,
0.0145144481,
-0.2122654617,
0.1799257994,
0.2325112969,
0.0674925596,
-0.0186838079,
-0.0584381409,
0.1307701468,
0.335932672,
0.0758777782,
0.0490402691,
-0.0789107233,
0.1646819264,
-0.2007022053,
0.2658082843,
0.0205474589,
0.4408126175,
-0.2335440069,
-0.4307367504,
0.5249713659,
-0.4426818788,
0.1415309012,
-0.0989474282,
0.3270317912,
-0.0173879862,
-0.1396422237,
0.1788656712,
0.1276936233,
-0.3309928477,
0.123875834,
-0.1707814783,
0.0518678352,
-0.1427778453,
-0.0294059236,
0.1041289344,
-0.2951839566,
0.229235068,
0.2629483342,
0.1628497094,
-0.3638058007,
0.1000300124,
0.0190727469,
-0.335719496,
0.3734185398,
0.1914822757,
0.0903211311,
-0.0365626328,
0.021134913,
0.110691227,
0.2860184908,
-0.1968238503,
-0.2691620588,
-0.325710237,
0.2981790304,
-0.1363750398,
0.0681535006,
-0.2090364248,
-0.2264496088,
0.2376222908,
-0.1421608031,
0.2182313502,
-0.2470263988,
0.1478289068,
-0.1377931684,
0.0856881291,
0.1977148056,
-0.1549031585,
0.1666708142,
-0.3304830194,
-0.1561736763,
0.1892358512,
0.2127918005,
-0.130445838,
0.0089818444,
-0.4230163395,
0.0815039575,
0.1046521217,
-0.042430602,
-0.3824839592,
0.3694661856,
-0.0766364783,
-0.0727532357,
-0.1210818887,
-0.0883678719,
-0.0585526787,
-0.1133994684,
-0.111820139,
-0.2724828124,
-0.0316611379,
0.066052936,
-0.3175022602,
-0.3639380634,
0.0590524264,
0.1204151735,
0.2259986848,
0.0808174238,
0.3385001719,
-0.1502054781,
0.3867523968,
-0.0823845938,
-0.1107932404,
0.2015221566,
0.3458758593,
-0.2184848338,
0.0472207516,
-0.2388706058,
-0.6032539606,
0.2194214314,
0.271004498,
0.1674415767,
-0.1090651155,
-0.1075146198,
-0.1884635836,
0.3663167059,
0.0353925191,
-0.0938055217,
0.1792329103,
-0.0502971411,
0.0115664629,
-0.127780661,
-0.2971426845,
0.2983751297,
-0.7227091193,
0.0257620942,
-0.2277014405,
0.3009405434,
-0.1479515284,
-0.2396881133,
0.1140724421,
-0.1982641816,
0.2001527101,
0.0411118604,
-0.3241812885,
0.2923832834,
-0.1977661401,
0.5281193256,
-0.1335335225,
0.347802043,
-0.0390668958,
-0.3990999758,
0.0533820353,
0.0955142751,
0.2503382862,
0.0910323784,
0.222462371,
0.2361990809,
-0.1671310961,
0.2491817623,
-0.0965070575,
-0.0404752791,
0.0812541321,
-0.0926230997,
0.0184072126,
0.0763010532,
0.3620201945,
0.1425499767,
0.2210334092,
-0.164331466,
-0.4189109206,
-0.1286877543,
0.2353352457,
-0.0309202727,
0.1900150627,
0.0499889664,
-0.050965175,
0.0210836455,
0.4130220413,
0.1356999576,
0.7778631449,
0.1471096426,
-0.1436001509,
0.1595270038,
-0.0578466319,
-0.1984000653,
0.4705079794,
0.209297657,
0.1599984169,
0.351390481,
0.1568639725,
0.0371735319,
-0.3285266161,
-0.4677329659,
0.0151765961,
0.2333848476,
-0.308665812,
0.2389539033,
-0.047729902,
0.1631411612,
-0.0459965207,
0.185631603,
0.051902689,
-0.0745175183,
-0.0687120631,
0.3248960972,
-0.1796483994,
0.1773210913,
-0.1618949175,
-0.0057050679,
0.0095721418,
0.0550313778,
-0.4102715254,
-0.1205579191,
-0.2000647336,
0.0986905247,
0.2081054896,
-0.0912707299,
0.3833190501,
-0.0051386487,
-0.1021881774,
-0.3912465274,
-0.125702858,
0.0166487452,
-0.0228277687,
0.3393887281,
0.2033682317,
0.190670833,
-0.1743161976,
-0.3276197612,
0.0412238166,
-0.308948487,
-0.0082035046,
-0.0366349407,
-0.247145921,
0.0003952436,
-0.2048998177,
-0.3667666614,
-0.0957962945,
-0.4197381735,
-0.0333350524,
-0.2450866699,
0.1248051152,
-0.1543488801,
0.2570145726,
0.177912131,
0.3634040058,
-0.2404255867,
-0.287776798,
-0.4224727452,
0.1080911383,
-0.0763235986,
-0.1932915449,
0.225029543,
0.211616084,
0.4474442601,
0.1264897734,
-0.5192944407,
0.2814048529,
-0.1671663225,
0.3048313558,
-0.2372134775,
0.1033014357,
0.1035762653,
-0.1309885532,
-0.0295810699,
-0.1645242125,
0.0027164819,
-0.2064719796,
-0.0086900564,
0.2442625165,
-0.0370962955,
0.5199653506,
0.0563282818,
0.6024197936,
0.2463897467,
-0.2644404471,
0.2786137462,
-0.0005401665,
0.0662428662,
-0.1156438068,
-0.1701711863,
0.1072805449,
-0.0140087996,
-0.3806941807,
0.1193315908,
-0.1754963994,
-0.4002347589,
-0.0838606507,
0.0109526841,
-0.2222188562,
-0.2204208821,
-0.0765430778,
0.1240881085,
0.3603118062,
-0.0196938906,
-0.046665404,
0.1237518564,
-0.0252055433,
0.0348680429,
0.3974428475,
-0.1646729261,
-0.1125824526,
-0.0252039786,
-0.2495472729,
-0.5391439795,
0.3058199286,
-0.1153970882,
0.3603816926,
-0.0262666512,
0.1717374921,
0.0976709351,
-0.3513452411,
0.3439369798,
-0.2000699043,
0.1985865384,
0.1232413277,
0.3016057014,
-0.0835864022,
-0.1260976493,
-0.323970139,
0.3431369364,
0.2300681472,
0.017107958,
-0.1126901209,
-0.0178060327,
0.1578189433,
-0.0910313725,
0.095007658,
-0.4341489971,
-0.171446085,
-0.2656352222,
-0.3754628301,
0.3200285435,
0.0245382376,
-0.0138267064,
-0.266459614,
-0.3430681229,
-0.089029558,
0.006620321,
0.0361999907,
0.0615504421,
-0.1845513582,
-0.1737155914,
0.3499945104,
-0.3073293567,
-0.3835155666,
0.5117772818,
0.2605524361,
0.2175974101,
-0.0351628996,
0.1965966374,
0.0921587572,
0.2051423341,
0.1244155318,
-0.2413434684,
0.0302944779,
0.2208454013,
0.2084414065,
-0.096361056,
0.1103572175,
0.2135502398,
0.2369338274,
-0.1696151942,
0.0702573955,
0.4531493485,
-0.052792605,
-0.0559250228,
0.5308976769,
-0.0300584957,
-0.2158599496,
0.2831304073,
-0.0260389466,
0.690015316,
0.2633360624,
-0.1623259038,
0.2882259786,
-0.3519699574,
0.365907371,
-0.1960674375,
0.0197135396,
-0.2932257354,
0.1334455311,
0.0736226439,
-0.0702387094,
0.3788086772,
0.0348506644,
-0.0103878556,
0.0646095201,
0.0607536249,
0.2245575637,
-0.0465022437,
0.0621898249,
-0.4789436162,
-0.195496738,
-0.4705085158,
0.2409898937,
-0.1042948291,
0.1331517994,
-0.2881865501,
0.1384278834,
0.1718184948,
-0.2543370426,
-0.4298968017,
0.194049567,
-0.2709249258,
0.1828778833,
-0.3240277469,
-0.3384000063,
0.2215100378,
0.1326417327,
-0.0233830307,
0.2830997109,
-0.0486372821,
0.3247666359,
0.0995771661,
0.0113196364,
0.0408686772,
-0.1175153777,
-0.1436051726,
-0.0914088264,
-0.2064720541,
0.1635828614,
-0.1934673786,
-0.1067461818,
0.2967288792,
0.0093542179,
0.0599094033,
-0.0167711917,
-0.0794335604,
0.0277615115,
-0.161384955,
-0.2419340611,
0.2396513373,
0.0962948725,
-0.1376480609,
0.385843128,
-0.3689873517,
-0.0826586336,
-0.1525519192,
0.3873706162,
-0.0368631221,
-0.0926424339,
0.1663613617,
0.3787693679,
-0.0498319082,
-0.3401619792,
0.128489852,
-0.2713205516,
-0.3731130362,
0.1379760802,
0.0481522456,
0.1930230111,
0.198407501,
0.2652949989,
0.1142395064,
0.0721298978,
0.1071217358,
-0.3564757705,
-0.2840363681,
0.0220416784,
-0.0674396306,
0.3970969915,
0.2609088719,
-0.0623896532,
-0.3939990103,
-0.1417409927,
-0.3558458686,
0.0099878656,
-0.2339576781,
0.0450408682,
0.1323415339,
0.1434394419,
0.2904753089,
-0.0508039929,
0.1531605124,
0.3273243308,
-0.1376041025,
-0.2678337991,
-0.0952086672,
0.1091023237,
0.1525140256,
-0.0058823163,
0.1330836117,
-0.2165651768,
-0.0729261264,
0.0478754342,
0.4800642133,
0.0204374436,
-0.1856676638,
-0.0615463033,
-0.0088131623,
-0.0451696701,
-0.3847220242,
0.0074963928,
0.0511801541,
0.1971352994,
-0.0943350196,
0.2063513398,
0.0533925071,
-0.0629394129,
0.0828251094,
-0.0917256027,
-0.2398792356,
0.3396101892,
0.2963388562,
-0.2343833297,
-0.1872140914,
-0.0677255988,
0.253516674,
0.1342678219,
-0.1971160918,
-0.126437366,
0.0476974249,
0.3135504425,
-0.0963570476,
-0.0618641749,
0.0737005472,
0.0619956218,
-0.0536436774,
-0.0085989339,
-0.0744921416,
-0.192505911,
0.0093243672,
0.1376973093,
0.3421489894,
-0.3943097293,
0.1346029192,
0.1180887595,
-0.0473896079,
0.2589941323,
0.0705981553,
-0.0877956674,
0.3109539747,
0.5004758239,
-0.1261427253,
0.1602704674,
0.5143030286,
0.2918739319,
0.0785216168,
-0.335435003,
-0.2110608369,
-0.0552299172,
-0.1982943416,
0.2914004028,
0.2190916091,
-0.0873300433,
-0.0363172665,
0.0728622153,
-0.3074155748,
0.0139759947,
-0.3167142868,
0.0692971274,
-0.231844753,
-0.0346020311,
0.1959743798,
0.0417751558,
-0.0189076234,
0.0932030454,
0.3702001572,
0.1838546395,
-0.0065185293,
-0.4397543073,
-0.0111093614,
0.4318005443,
0.0513918586,
-0.1916252375,
0.0046523944,
0.186558798,
-0.1779847443,
-0.505358994,
0.2673543096,
0.6739769578,
0.0062386002,
0.2000031173,
0.1501192898,
0.2316386551,
0.0287967492,
0.1042123586,
0.1397376359,
0.0852057487,
0.3008619547,
0.1081578806,
0.1943757385,
-0.180483371,
0.0828501061,
0.3442704082,
0.099700518,
-0.2889536917,
-0.1840631366,
-0.2121309787,
-0.0885519236,
-0.1849807948,
0.3252624273,
-0.3353925049,
0.1141279414,
0.4523005486,
-0.0578445829,
-0.017407231,
-0.1354141384,
0.1180010289,
-0.2124153227,
0.3783062994,
0.1931148767,
0.3464110196,
-0.3805872202,
-0.2291619629,
-0.2495294511,
0.1904991418,
0.0580655672,
0.3497966528,
-0.0998174697,
0.0076614749,
-0.1881281883,
0.0366141126,
0.3333268464,
-0.0709696338,
0.1044165939,
0.7122975588,
-0.2329669446,
-0.1572956145,
-0.1262034625,
-0.4012383223,
0.0452662706,
-0.327962786,
-0.0271895099,
-0.1842367202,
-0.0101440856,
-0.3112579286,
-0.1087910086,
0.2254897803,
-0.1959361434,
0.7443268895,
0.0837327391,
0.2341904193,
-0.3082321584,
-0.0279197209,
-0.174410671,
-0.3456432223,
0.1468856037,
0.0500433594,
-0.0996717662,
0.4120552838,
-0.1713715345,
-0.0347583257,
-0.0542384461,
-0.1305982023,
-0.1392541081,
-0.3047567308,
-0.1175227612,
0.0917537957,
-0.2881337106,
0.0800517648,
-0.1363860667,
0.3570806682,
0.2249627113,
0.2058819085,
-0.4442859292,
-0.3117396533,
0.2971375287,
-0.2701057196,
-0.1601508856,
-0.0742598698,
0.3998969197,
0.235016495,
-0.16968894,
-0.4783015251,
0.0071300901,
0.2522349358,
-0.0855993479,
-0.2348606139,
0.1617293209,
0.2126666754,
0.0456787571,
0.0492779873,
0.3330917954,
0.0927515402,
-0.1896274537,
0.3651854694,
-0.4051701427
] |