html_url
stringlengths
51
51
title
stringlengths
6
280
comments
stringlengths
67
24.7k
body
stringlengths
51
36.2k
__index_level_0__
int64
1
1.17k
comment_length
int64
16
1.45k
text
stringlengths
190
38.3k
embeddings
sequence
https://github.com/huggingface/datasets/issues/5229
Type error when calling `map` over dataset containing 0-d tensors
Hi! We could address this by calling `.item()` on such tensors to extract the value, but this would lose us the type, which could lead to storing the generated dataset in a suboptimal format. Considering this, I think the only proper fix would be implementing support for 0-D tensors on Apache Arrow's side (Arrow is the underlying format we use to store datasets on disk/in memory). WDYT @lhoestq?
### Describe the bug 0-dimensional tensors in a dataset lead to `TypeError: iteration over a 0-d array` when calling `map`. It is easy to generate such tensors by using `.with_format("...")` on the whole dataset. ### Steps to reproduce the bug ``` ds = datasets.Dataset.from_list([{"a": 1}, {"a": 1}]).with_format("torch") ds.map(None) ``` ### Expected behavior Getting back `ds` without errors. ### Environment info Python 3.10.8 datasets 2.6. torch 1.13.0
426
68
Type error when calling `map` over dataset containing 0-d tensors ### Describe the bug 0-dimensional tensors in a dataset lead to `TypeError: iteration over a 0-d array` when calling `map`. It is easy to generate such tensors by using `.with_format("...")` on the whole dataset. ### Steps to reproduce the bug ``` ds = datasets.Dataset.from_list([{"a": 1}, {"a": 1}]).with_format("torch") ds.map(None) ``` ### Expected behavior Getting back `ds` without errors. ### Environment info Python 3.10.8 datasets 2.6. torch 1.13.0 Hi! We could address this by calling `.item()` on such tensors to extract the value, but this would lose us the type, which could lead to storing the generated dataset in a suboptimal format. Considering this, I think the only proper fix would be implementing support for 0-D tensors on Apache Arrow's side (Arrow is the underlying format we use to store datasets on disk/in memory). WDYT @lhoestq?
[ -1.181314468383789, -0.8945591449737549, -0.7441688179969788, 1.4151462316513062, -0.21924591064453125, -1.2917810678482056, 0.18332567811012268, -1.1354318857192993, 1.8034685850143433, -0.8145748376846313, 0.3132588267326355, -1.6399246454238892, 0.02455911785364151, -0.6059790849685669, -0.8035942316055298, -0.8094513416290283, -0.4477245807647705, -0.6035844683647156, 1.01888108253479, 2.5962960720062256, 1.124022364616394, -1.3054838180541992, 2.663485527038574, 0.6839632987976074, -0.1970311403274536, -0.9318042993545532, 0.5370886921882629, 0.041635431349277496, -1.3665482997894287, -0.4058723747730255, -0.9208166599273682, -0.09364283829927444, -0.4968571960926056, -0.6618649363517761, 0.025861557573080063, 0.3357559144496918, -0.33235985040664673, -0.466765433549881, -0.4622393846511841, -0.8823273777961731, 0.4367237687110901, -0.4571538269519806, 1.0140037536621094, -0.4272928535938263, 1.8568953275680542, -0.6065070033073425, 0.5253955125808716, 0.6870629787445068, 1.2820203304290771, 0.19949716329574585, -0.06114146485924721, 0.4036672115325928, 0.5356017351150513, 0.023030351847410202, 0.5153518319129944, 1.0559204816818237, 0.5840743184089661, 0.4947679042816162, 0.7574361562728882, -2.247194528579712, 1.246955394744873, -1.0128729343414307, 0.24083223938941956, 1.3147521018981934, -0.956339418888092, 0.34141111373901367, -1.7187520265579224, -0.07837001234292984, 0.5798535943031311, -2.2622082233428955, 0.2548252046108246, -1.419878602027893, -0.5440983176231384, 1.0395692586898804, 0.37232154607772827, -1.196471095085144, 0.12953871488571167, -0.38758063316345215, 0.9029276371002197, 0.47423648834228516, 1.1160855293273926, -1.7275855541229248, -0.03501617908477783, -0.3369176387786865, 0.047393281012773514, -1.2647356986999512, -1.4557446241378784, 0.5819315314292908, 0.6344910264015198, 0.556275486946106, -0.06131492182612419, 0.9690614938735962, -0.952496349811554, 0.7615664601325989, -1.0132412910461426, -1.8358725309371948, -1.4786134958267212, -2.252789258956909, -2.2828962802886963, 0.7677419781684875, -0.4334307312965393, -0.4788142740726471, 2.033163070678711, -1.0669398307800293, -1.7759225368499756, 1.1682851314544678, 0.27818039059638977, -0.15076586604118347, 2.3236618041992188, 0.23145711421966553, -0.6573490500450134, 0.4514884054660797, -0.7652230858802795, 0.6116037964820862, -0.46952223777770996, 1.265920639038086, 0.42416924238204956, -1.0653868913650513, 1.584572672843933, -0.42596831917762756, 0.6066449284553528, -0.7136233448982239, -0.43566349148750305, -0.7299332618713379, 0.36380091309547424, 1.9231886863708496, -0.3602469265460968, 1.525946855545044, -0.2932151257991791, -1.513458013534546, -1.573127269744873, 0.8136906623840332, 0.48946094512939453, -0.668164849281311, 0.13136053085327148, -0.3265579044818878, 0.11097083985805511, -0.11194154620170593, 1.1644948720932007, 1.1781082153320312, 0.7579861879348755, -0.21381860971450806, -0.8378309607505798, 0.27599477767944336, 0.021887943148612976, -0.8117102980613708, -1.7312654256820679, -0.40275490283966064, 0.11209484934806824, 0.6258057951927185, -1.2133220434188843, 1.7514424324035645, 0.8226251006126404, 1.9146634340286255, 1.036302089691162, -0.2370092272758484, 1.4838734865188599, 0.11449509114027023, 1.8812932968139648, -0.4304960370063782, 0.6990880966186523, -0.3708958029747009, -1.1220085620880127, 0.8273065090179443, -0.3340199291706085, -2.0650947093963623, -0.6985353827476501, -0.977340579032898, -0.13847345113754272, -0.7703143954277039, 1.0107790231704712, -0.23627400398254395, -1.3077073097229004, 0.23397403955459595, -0.7290321588516235, 0.0613074004650116, -1.2384812831878662, 0.34118708968162537, 0.7517341375350952, -0.5567725896835327, 0.09900622069835663, -0.2426919937133789, -1.3515492677688599, -0.38188305497169495, 0.24327495694160461, 1.880779504776001, -0.9207217693328857, 0.9501517415046692, 0.9912420511245728, -0.6929900646209717, -0.09037111699581146, 0.3728066086769104, -0.3635255694389343, 0.8534917831420898, -1.0204769372940063, -0.3016499876976013, 1.247765064239502, -0.21624994277954102, -0.600000262260437, 1.4475364685058594, 0.6962912678718567, -0.9957138299942017, -0.15856558084487915, -0.13020053505897522, -0.8240228891372681, 0.031158406287431717, -1.6715915203094482, -0.11073975265026093, 0.32391029596328735, -1.5697044134140015, -0.551991879940033, -0.18312588334083557, 1.2837464809417725, -0.05421237647533417, 1.4485355615615845, -0.35182034969329834, -0.26605233550071716, -0.4512363374233246, -0.27940601110458374, 0.07462604343891144, -0.2033044695854187, -0.662739098072052, 0.26028671860694885, -0.6961944699287415, 0.3540840744972229, 1.4226102828979492, 0.3152506649494171, 0.08833129703998566, 0.6568995714187622, 1.0131101608276367, 0.32816281914711, -0.08836805820465088, -0.8785528540611267, -1.6792447566986084, 2.1158812046051025, -1.435245394706726, 1.996321439743042, 0.6734838485717773, -0.05528289079666138, -1.7835443019866943, -2.0056958198547363, 1.3925113677978516, 1.1163737773895264, 2.2225425243377686, 0.5219382643699646, 0.4041655361652374, -0.7308664321899414, -0.6185376048088074, 0.2866158187389374, -1.030678629875183, -0.7243813872337341, 0.1279296576976776, 2.3652212619781494, 1.6993529796600342, -0.4430830478668213, -0.23466327786445618, -1.1357066631317139, 1.4437487125396729, -0.1577412188053131, 0.20048469305038452, 1.9295574426651, -0.3429878354072571, -1.0427578687667847, 1.2276418209075928, -2.307206153869629, 0.10837236791849136, 1.95867121219635, 0.1930498480796814, 0.08184847980737686, -1.3366302251815796, -0.6870693564414978, -0.28994616866111755, -0.39334797859191895, -1.199924349784851, 0.5591854453086853, -0.20482385158538818, -0.8002609610557556, -1.4261474609375, 0.17325592041015625, -1.0768860578536987, -1.6801167726516724, 0.1341497004032135, 1.8771623373031616, 1.9202286005020142, -0.7729201316833496, 1.4928818941116333, -0.2706851661205292, 0.21235671639442444, 1.3345266580581665, 1.202492117881775, 3.1759355068206787, 1.9959945678710938, -1.2897279262542725, 0.7342988848686218, -0.016368906944990158, -0.45217669010162354, 1.169346809387207, -1.217681884765625, 1.3180582523345947, -0.13913244009017944, -1.13227379322052, -1.1949023008346558, 0.8367699384689331, 0.4841074049472809, 0.0927315354347229, -0.43932121992111206, 1.1838585138320923, 0.04133788123726845, 1.3381673097610474, 0.5852190852165222, -0.3727494478225708, 0.748937726020813, -0.38560718297958374, -0.4466058313846588, 1.4879112243652344, 0.2785346210002899, -1.3981353044509888, -2.398038148880005, -0.13564461469650269, -0.8939456939697266, 0.006311105564236641, -0.5783427953720093, -0.97024005651474, 1.6799160242080688, 0.43061235547065735, -1.176548957824707, -0.22233331203460693, -0.31377092003822327, -0.6082996726036072, 2.80722713470459, -1.4911298751831055, -0.2807035446166992, -1.0517643690109253, -0.6423988342285156, 1.6870555877685547, -1.1607764959335327, -0.15636232495307922, -1.02654230594635, -0.5128556489944458, -1.3080135583877563, -0.5887572169303894, -0.01215587742626667, -0.9518314003944397, 0.898664116859436, 0.11152421683073044, -1.2258892059326172, -0.34847596287727356, -0.9483453035354614, 0.8134302496910095, -0.06918519735336304, 0.2403605878353119, 1.9601072072982788, 0.4583151638507843, -0.3874370753765106, 0.6839044690132141, 1.175166368484497, 0.6660415530204773, -0.678044319152832, 0.37784305214881897, -0.7012450098991394, 0.31416159868240356, -1.2838106155395508, 0.2918154299259186, -2.7050580978393555, 0.555155873298645, -0.10407114773988724, -0.07572543621063232, 0.03225438669323921, -1.3481581211090088, 1.0722973346710205, 2.616135835647583, -1.123450517654419, 0.4873732626438141, 0.20924460887908936, 1.178714394569397, -1.5155562162399292, 0.3595125675201416, -0.4385717213153839, 2.1072824001312256, 0.20698893070220947, 1.1378339529037476, -0.40044307708740234, -2.181735038757324, 0.7048363089561462, -1.329209804534912, -1.3233375549316406, 0.8080121278762817, -0.8378795981407166, -0.008781800977885723, -1.3789036273956299, -0.12095131725072861, -0.777433454990387, -1.240765929222107, 0.7214690446853638, 0.07644852250814438, 0.5249107480049133, -0.5951856970787048, 0.3543154299259186, -2.190812587738037, -1.312676191329956, -0.29475486278533936, -0.898288369178772, 0.44816508889198303, -0.242434561252594, 0.7601984143257141, -0.2704788148403168, 0.006034856662154198, 0.35226210951805115, 1.4014415740966797, 3.458017349243164, 0.15492013096809387, 0.33972039818763733, -0.18706095218658447, -0.9506701827049255, 1.4009710550308228, 0.9578801989555359, -0.22495180368423462, -0.56742262840271, -1.0209007263183594, 1.2279719114303589, 1.938633680343628, 0.9860098361968994, 0.04311668500304222, -0.7962360382080078, -0.7278732061386108, -0.0039265756495296955, 0.10756871849298477, 0.44009941816329956, 0.8862287998199463, 0.1514878273010254, 0.060157179832458496, 1.420899510383606, 1.1740995645523071, -0.4240047037601471, 0.3426397144794464, -0.7929166555404663, -0.4429806172847748, 0.5967572331428528, 0.38062626123428345, 0.020176056772470474, 0.3155628442764282, -0.9597326517105103, -0.2718936800956726, -0.39457085728645325, -0.9346131682395935, -0.7427697777748108, -0.43912073969841003, -0.3802761137485504, 1.6580699682235718, 0.07184156775474548, -0.4548734724521637, -0.0972059965133667, -0.7991549968719482, -0.027420543134212494, -0.9345861077308655, 0.29142671823501587, -0.13336113095283508, -0.12633728981018066, -0.08058156818151474, 1.7108794450759888, -0.9322947263717651, -1.980945348739624, 0.3139950931072235, 0.16883039474487305, -0.30491283535957336, 0.22076502442359924, 1.5694769620895386, 0.5945205092430115, 1.5189493894577026, 1.357904314994812, 0.8536504507064819, -0.649829089641571, -1.3326897621154785, 0.6245704293251038, 0.9887536764144897, -1.4489428997039795, 0.7324801087379456, 0.14819028973579407, -0.5687769651412964, 0.5966746807098389, 1.158292531967163, 0.43318378925323486, -1.9053280353546143, 0.7235190868377686, -0.8528753519058228, 0.7642277479171753, 0.7242264151573181, 0.7826524972915649, 0.22315043210983276, 0.7809382677078247, -1.2461304664611816, -1.157165288925171, -0.764247477054596, -0.5938028693199158, 1.9569120407104492, -0.256679892539978, 0.5631580352783203, -0.17534449696540833, -1.339996099472046, -0.11310940235853195, 0.6222718358039856, 0.3226301968097687, -0.4504961371421814, 0.777350664138794, -0.6527409553527832, -1.0970064401626587, -1.4108850955963135, -0.48431098461151123, -1.0708129405975342, -0.9293927550315857, 1.0868180990219116, 0.8739002346992493, 0.30316850543022156, 1.8592514991760254, 0.6093453764915466, 0.2149869203567505, -2.694852828979492, 0.9294489026069641, 0.2511405050754547, -0.11263760179281235, 0.8177868127822876, 0.23738062381744385, 0.9646651744842529, -0.11858176440000534, 0.5638797283172607, -2.4306929111480713, 2.2819015979766846, -0.20586726069450378, 0.6788858771324158, -0.008439192548394203, -0.08645901829004288, 1.0242506265640259, 0.5734788775444031, 0.5555861592292786, -1.0342965126037598, 0.6566528677940369, -0.6217048764228821, 1.3366416692733765, 0.9087603092193604, -0.8227289915084839, -0.06441622227430344, 1.3802248239517212, 0.5352950692176819, -0.48688191175460815, -0.9124318361282349, -1.0071468353271484, 0.9453524947166443, 1.730090856552124, -0.06864497065544128, -0.05435898154973984, 0.8672228455543518, 0.5943381190299988, -1.2881999015808105, 0.05300319194793701, -0.8004776239395142, -0.6966221332550049, 1.6633514165878296, 2.1548357009887695, -0.0803869292140007, -0.2248799204826355, -0.826252281665802, -1.1596345901489258, 0.8047016263008118, 0.07398340106010437, 0.08826643228530884, 0.7394196391105652, -0.5912092924118042, 1.1557419300079346, 0.9419123530387878, 0.9240492582321167, 0.26686984300613403, 0.2682112455368042, 0.28388360142707825, -0.31300225853919983, -1.21224844455719, -0.267022967338562, -1.0111991167068481, -2.552558422088623, 0.5324065685272217, -0.3133927881717682, -1.4526593685150146, 0.03146112337708473, -1.1180027723312378, 0.9255638122558594, -0.5322851538658142, -1.040197730064392, -1.5060534477233887, 0.1305672824382782, -0.04351038858294487, 0.8796627521514893, -1.59093177318573, -0.05435706675052643, 1.3128560781478882, 0.9306225776672363, -0.7057574987411499, 0.9408472776412964, 0.24923834204673767, 1.043005108833313, 0.8961565494537354, -0.3206193745136261, 0.5439346432685852, 0.011605974286794662, -1.4286177158355713, 0.5219259262084961, 1.1584060192108154, 0.22935158014297485, 1.4553302526474, -0.6237747669219971, 0.06230694800615311, 0.43386033177375793, -0.42186439037323, -0.4436412453651428, -0.6080557107925415, 0.7435040473937988, 0.14785084128379822, -0.8445860743522644, -0.007578792050480843, -0.04936649650335312, -0.17639154195785522, 0.138991117477417, -1.4890861511230469, -0.11158684641122818, -0.23803088068962097, -0.7427552342414856, -1.210484266281128, -0.12705419957637787, 1.3226251602172852, -0.8764182329177856, -0.09260580688714981, 0.5566624999046326, 0.307672381401062, 0.5346924662590027, 0.6462478637695312, -0.6243346333503723, -0.3876836895942688, -0.24912181496620178, -0.2912912964820862, 0.3261134922504425, 1.4587899446487427, -0.11900003999471664, -1.013870120048523, 0.7390891313552856, -0.3823155164718628, 0.030437622219324112, 1.8615797758102417, 0.07126905024051666, -0.8066321015357971, 0.2594551146030426, -0.623460054397583, 1.981009602546692, 1.661513328552246, 1.285762071609497, -0.06772473454475403, -1.01649808883667, 0.5927542448043823, -0.3215515911579132, -0.34818416833877563, 0.9112119674682617, 0.436357319355011, -0.16940397024154663, -1.3568850755691528, 0.678432285785675, 1.2830231189727783, -0.9178411960601807, -0.8823589086532593, 0.09153851121664047, -0.7951114773750305, 1.025743842124939, 0.7416495084762573, 0.3404020071029663, 0.2688177525997162, 1.5836249589920044, 0.8272578716278076, -0.48678144812583923, 0.4788537621498108, 0.5313864946365356, -0.07112794369459152, -2.1117584705352783, -1.022438883781433, 0.45950621366500854, -0.4435800313949585, -1.6255683898925781, 1.388403296470642, -1.1519159078598022, -0.9085553288459778, 0.5898744463920593, 0.14434275031089783, 1.5262466669082642, 0.350877583026886, 1.53593909740448, 2.0410921573638916, 0.9460309147834778, 0.3757317066192627, 1.3716602325439453, -0.22971612215042114, -0.45168137550354004, 1.682814121246338, -0.4031940996646881, 0.5177581310272217, 1.0373460054397583, -0.3848930895328522, -0.9969838857650757, -0.7685632705688477, -1.3057336807250977, -0.6868433952331543, 1.184368371963501, 0.08039627224206924, -1.1655211448669434, 0.2084285020828247, 1.5432771444320679, 0.023345738649368286, -0.30911388993263245, 0.5855468511581421, 0.36347806453704834, -0.7908404469490051, -0.09970026463270187, -0.9465024471282959, 0.5924434661865234, -0.11097605526447296, -0.36312198638916016, 0.3853566348552704, 0.4099526107311249, 1.3730378150939941, -0.07509084790945053, 0.19111868739128113, 1.1697399616241455, -1.359917402267456, 1.5272599458694458, -0.7635193467140198, 0.21616017818450928, -2.3526930809020996, 1.428127408027649, -0.8546774387359619, 1.893677830696106, -2.6956098079681396, 0.396647572517395, -0.5562469959259033, -0.41167256236076355, 0.2671990692615509, -0.3189707398414612, 0.14340358972549438, -0.20968523621559143, -1.198447346687317, -0.0864519402384758, -0.760042130947113, 0.6391591429710388, 1.027090072631836, 1.309870719909668, -1.1834625005722046, -0.29426315426826477, -1.793807864189148, -0.14845061302185059, -0.6763294339179993, 0.3822759985923767, -1.9742945432662964, -0.04946364834904671, -1.8739551305770874, -2.461568593978882, -1.354143738746643, -0.7734282612800598, 1.0927551984786987, 0.0018844353035092354, -0.8679160475730896, 1.1475062370300293, -0.3769192397594452, -1.9118417501449585, 1.1237517595291138, -2.2339417934417725 ]
https://github.com/huggingface/datasets/issues/5229
Type error when calling `map` over dataset containing 0-d tensors
I think we can just convert the item to a numpy typed scalar using `.numpy()` ? For example this works: ```python import numpy as np import pyarrow as pa assert pa.array([np.float64(1.0)]).type == pa.float64() assert pa.array([np.float32(1.0)]).type == pa.float32() assert pa.array([np.int32(1)]).type == pa.int32() assert pa.array([np.int64(1)]).type == pa.int64() ``` And therefore it would work the same as for PyTorch N-D Tensors: convert to Numpy Array to keep the type in `_cast_to_python_objects`, then convert to Arrow
### Describe the bug 0-dimensional tensors in a dataset lead to `TypeError: iteration over a 0-d array` when calling `map`. It is easy to generate such tensors by using `.with_format("...")` on the whole dataset. ### Steps to reproduce the bug ``` ds = datasets.Dataset.from_list([{"a": 1}, {"a": 1}]).with_format("torch") ds.map(None) ``` ### Expected behavior Getting back `ds` without errors. ### Environment info Python 3.10.8 datasets 2.6. torch 1.13.0
426
72
Type error when calling `map` over dataset containing 0-d tensors ### Describe the bug 0-dimensional tensors in a dataset lead to `TypeError: iteration over a 0-d array` when calling `map`. It is easy to generate such tensors by using `.with_format("...")` on the whole dataset. ### Steps to reproduce the bug ``` ds = datasets.Dataset.from_list([{"a": 1}, {"a": 1}]).with_format("torch") ds.map(None) ``` ### Expected behavior Getting back `ds` without errors. ### Environment info Python 3.10.8 datasets 2.6. torch 1.13.0 I think we can just convert the item to a numpy typed scalar using `.numpy()` ? For example this works: ```python import numpy as np import pyarrow as pa assert pa.array([np.float64(1.0)]).type == pa.float64() assert pa.array([np.float32(1.0)]).type == pa.float32() assert pa.array([np.int32(1)]).type == pa.int32() assert pa.array([np.int64(1)]).type == pa.int64() ``` And therefore it would work the same as for PyTorch N-D Tensors: convert to Numpy Array to keep the type in `_cast_to_python_objects`, then convert to Arrow
[ -1.2763721942901611, -0.8571905493736267, -0.6723377108573914, 1.5056922435760498, -0.14017623662948608, -1.215745449066162, 0.18773041665554047, -1.0328963994979858, 1.8163405656814575, -0.8256814479827881, 0.3336203396320343, -1.6222895383834839, 0.12736748158931732, -0.5088975429534912, -0.7988576292991638, -0.782721757888794, -0.5613328814506531, -0.6276170015335083, 1.0353167057037354, 2.5175023078918457, 1.1547294855117798, -1.3489596843719482, 2.588470697402954, 0.7439485192298889, -0.17980730533599854, -0.9511786103248596, 0.47221100330352783, 0.05470554903149605, -1.4046982526779175, -0.3460219204425812, -0.9426481127738953, -0.12812279164791107, -0.5145485401153564, -0.7075645327568054, 0.04666583612561226, 0.3144530951976776, -0.2798525393009186, -0.538284420967102, -0.43539729714393616, -0.7982330918312073, 0.4099833071231842, -0.4216456711292267, 0.8965825438499451, -0.36521995067596436, 1.8233346939086914, -0.6745279431343079, 0.6108785271644592, 0.6538708209991455, 1.3868800401687622, 0.22669059038162231, -0.08875466883182526, 0.5360651612281799, 0.4980350136756897, 0.035616111010313034, 0.5886397957801819, 1.2034486532211304, 0.7005614042282104, 0.43555471301078796, 0.7985108494758606, -2.247898578643799, 1.2935800552368164, -1.0566837787628174, 0.33545634150505066, 1.264936923980713, -0.956108808517456, 0.31191080808639526, -1.665459156036377, -0.08429349958896637, 0.5812621116638184, -2.2840733528137207, 0.2660103440284729, -1.4465018510818481, -0.4945066273212433, 1.1108016967773438, 0.462595134973526, -1.2323824167251587, -0.00797327607870102, -0.4303833246231079, 0.8950937390327454, 0.3585784435272217, 1.1288073062896729, -1.6512901782989502, -0.07937094569206238, -0.38276877999305725, 0.11449210345745087, -1.2125588655471802, -1.4398099184036255, 0.5196983814239502, 0.762076199054718, 0.5254552960395813, -0.07013458013534546, 0.9683706164360046, -1.051743507385254, 0.8177291750907898, -1.003200650215149, -1.8766461610794067, -1.4585235118865967, -2.1927103996276855, -2.2598330974578857, 0.7130932807922363, -0.4027981758117676, -0.509144127368927, 2.077615737915039, -1.024568796157837, -1.790542483329773, 1.164622187614441, 0.24224193394184113, -0.15148156881332397, 2.398892402648926, 0.1428271383047104, -0.6699627041816711, 0.42270714044570923, -0.777907133102417, 0.6961029171943665, -0.4634597897529602, 1.292346715927124, 0.443706214427948, -1.0776976346969604, 1.5704787969589233, -0.28416386246681213, 0.5856339931488037, -0.6844344735145569, -0.39695224165916443, -0.6416410803794861, 0.37927407026290894, 2.008397102355957, -0.3703070878982544, 1.5028088092803955, -0.30028587579727173, -1.5351916551589966, -1.6204780340194702, 0.8165929317474365, 0.5261683464050293, -0.6479752063751221, 0.1736612617969513, -0.3526844084262848, 0.07925944030284882, 0.00112054031342268, 1.1853307485580444, 1.297256350517273, 0.7483236789703369, -0.22363786399364471, -0.8600925803184509, 0.20918720960617065, 0.01991676539182663, -0.7585997581481934, -1.6886204481124878, -0.4512523412704468, 0.12048719078302383, 0.5839232802391052, -1.2013911008834839, 1.7234388589859009, 0.8278618454933167, 1.8666515350341797, 1.0989713668823242, -0.22775138914585114, 1.5863516330718994, 0.09115306288003922, 1.823081612586975, -0.4283788800239563, 0.7618370652198792, -0.34787964820861816, -1.169836401939392, 0.784390926361084, -0.3794122636318207, -2.096634864807129, -0.7360352277755737, -0.8035722970962524, -0.07678857445716858, -0.7981125712394714, 0.9172290563583374, -0.27232179045677185, -1.4195572137832642, 0.27195483446121216, -0.8357366919517517, 0.004973970353603363, -1.2000858783721924, 0.3648368716239929, 0.7395594120025635, -0.6585797667503357, 0.14228984713554382, -0.2611163556575775, -1.3230351209640503, -0.39338430762290955, 0.2649979293346405, 1.887511968612671, -0.910593569278717, 0.9002626538276672, 1.0600286722183228, -0.7499271631240845, -0.04839874804019928, 0.3577769994735718, -0.3027023673057556, 0.9190945625305176, -1.0137170553207397, -0.33100026845932007, 1.1757075786590576, -0.08086488395929337, -0.5961489081382751, 1.475521206855774, 0.6637135744094849, -0.9771063923835754, -0.19138416647911072, -0.09925618767738342, -0.8013387322425842, 0.10938641428947449, -1.6653627157211304, -0.11577419191598892, 0.40932801365852356, -1.5513901710510254, -0.5573498010635376, -0.16840128600597382, 1.3271124362945557, -0.13155756890773773, 1.4779412746429443, -0.3553760349750519, -0.16676561534404755, -0.39960476756095886, -0.2259708195924759, 0.10938012599945068, -0.13785868883132935, -0.6301265358924866, 0.25591254234313965, -0.7019755840301514, 0.4299411475658417, 1.4013175964355469, 0.3721407353878021, 0.11705141514539719, 0.5852046608924866, 1.078792691230774, 0.3870276212692261, -0.14080552756786346, -0.8743817806243896, -1.6747711896896362, 2.1015095710754395, -1.3486440181732178, 2.051335096359253, 0.6767128705978394, -0.0900208130478859, -1.7276946306228638, -1.9409971237182617, 1.3633583784103394, 1.1511720418930054, 2.3598368167877197, 0.5802997350692749, 0.42913639545440674, -0.8159424662590027, -0.6536164879798889, 0.34025782346725464, -1.0425053834915161, -0.8237902522087097, 0.10346515476703644, 2.3737146854400635, 1.6852041482925415, -0.3567678928375244, -0.22029149532318115, -1.1000779867172241, 1.4779915809631348, -0.209585502743721, 0.17764079570770264, 1.935784935951233, -0.21480964124202728, -1.0508394241333008, 1.29106867313385, -2.297866106033325, 0.08894792199134827, 1.9631963968276978, 0.2070135474205017, 0.04401598125696182, -1.3978033065795898, -0.6400746703147888, -0.29463014006614685, -0.4164099097251892, -1.224081039428711, 0.5217897891998291, -0.17674246430397034, -0.8113992810249329, -1.4200407266616821, 0.16719524562358856, -1.117769718170166, -1.6796640157699585, 0.10307810455560684, 1.8467086553573608, 1.8595354557037354, -0.7125735282897949, 1.510377049446106, -0.35291171073913574, 0.20731405913829803, 1.2817835807800293, 1.1704752445220947, 3.153359889984131, 2.0170958042144775, -1.2028502225875854, 0.7160406112670898, -0.14381594955921173, -0.4554007649421692, 1.1133484840393066, -1.2859441041946411, 1.3308286666870117, -0.057024985551834106, -1.213197946548462, -1.1894280910491943, 0.9770325422286987, 0.4530107080936432, 0.05797499790787697, -0.46788451075553894, 1.2095361948013306, 0.07760745286941528, 1.3759123086929321, 0.5185185074806213, -0.22345151007175446, 0.7320368885993958, -0.4091174900531769, -0.44954463839530945, 1.5086288452148438, 0.2753770649433136, -1.33224356174469, -2.291266679763794, -0.13041932880878448, -0.9060406684875488, 0.029835592955350876, -0.6013785004615784, -0.9334595799446106, 1.7201027870178223, 0.38552871346473694, -1.244433045387268, -0.19392627477645874, -0.34366166591644287, -0.6066539883613586, 2.8134140968322754, -1.3996026515960693, -0.22903914749622345, -1.0590451955795288, -0.6653346419334412, 1.661078691482544, -1.16728937625885, -0.16559629142284393, -1.033385992050171, -0.5047762393951416, -1.1864207983016968, -0.6656612753868103, -0.08386442810297012, -0.9676452279090881, 0.7988584637641907, 0.09303326159715652, -1.2516802549362183, -0.43050453066825867, -0.9019759893417358, 0.81033855676651, -0.033859945833683014, 0.1488904505968094, 1.9649436473846436, 0.43574726581573486, -0.32248085737228394, 0.7794576287269592, 1.1193950176239014, 0.61832195520401, -0.5301188826560974, 0.4105337858200073, -0.6066461205482483, 0.33437860012054443, -1.2792160511016846, 0.2594203054904938, -2.7273478507995605, 0.6258454918861389, -0.07195056229829788, 0.02038179710507393, -0.04046125337481499, -1.2630088329315186, 1.116909384727478, 2.6813344955444336, -1.1047210693359375, 0.5028417110443115, 0.2220940887928009, 1.1059287786483765, -1.4776201248168945, 0.2720462679862976, -0.44694605469703674, 2.186255931854248, 0.2633776068687439, 1.1857115030288696, -0.4175850749015808, -2.2494966983795166, 0.7393876910209656, -1.3066520690917969, -1.263136625289917, 0.7326797842979431, -0.8171712160110474, 0.008872631005942822, -1.319037914276123, -0.20604591071605682, -0.7130846977233887, -1.1002780199050903, 0.6015678644180298, 0.11912255734205246, 0.5302853584289551, -0.5679466724395752, 0.41090866923332214, -2.255964756011963, -1.3144959211349487, -0.2927607595920563, -0.9733765125274658, 0.45770904421806335, -0.1943604201078415, 0.6602659225463867, -0.23899562656879425, 0.006201103329658508, 0.35986509919166565, 1.3703603744506836, 3.3206591606140137, 0.1845775991678238, 0.3039364814758301, -0.1780499964952469, -0.9814538955688477, 1.342034101486206, 0.9053252935409546, -0.2712183892726898, -0.5876243114471436, -1.030594825744629, 1.243742823600769, 1.8764138221740723, 0.992163896560669, -0.00018298998475074768, -0.7576029896736145, -0.8407403230667114, -0.04723381623625755, 0.07003208994865417, 0.3945758640766144, 0.906775712966919, 0.19042758643627167, 0.12015574425458908, 1.4393702745437622, 1.2307980060577393, -0.47478994727134705, 0.36184385418891907, -0.7748858332633972, -0.5087522268295288, 0.5751169919967651, 0.3276558220386505, 0.008437964133918285, 0.276607483625412, -1.0340458154678345, -0.21392229199409485, -0.3653155565261841, -0.9300216436386108, -0.8156912922859192, -0.34344691038131714, -0.36454907059669495, 1.7128962278366089, 0.12230473011732101, -0.4825715720653534, -0.14748923480510712, -0.9119714498519897, -0.01955590769648552, -0.8899939060211182, 0.38198956847190857, -0.0906439870595932, -0.14187219738960266, -0.07263853400945663, 1.8474632501602173, -0.9544858932495117, -1.9939758777618408, 0.3362233638763428, 0.04054399952292442, -0.3268068730831146, 0.27395617961883545, 1.6186423301696777, 0.7172728776931763, 1.4795688390731812, 1.3703854084014893, 0.9007206559181213, -0.588838517665863, -1.3349335193634033, 0.6421823501586914, 0.9798290133476257, -1.3992446660995483, 0.6524772047996521, 0.14415092766284943, -0.48310309648513794, 0.5770480632781982, 1.239591121673584, 0.5132301449775696, -2.0179905891418457, 0.7203305959701538, -0.9136669635772705, 0.6904793977737427, 0.683545708656311, 0.6602757573127747, 0.17512835562229156, 0.7591533064842224, -1.215157151222229, -1.1564854383468628, -0.7156516909599304, -0.6951091885566711, 1.9587888717651367, -0.3154074251651764, 0.5357732176780701, -0.18584060668945312, -1.4957666397094727, -0.12196199595928192, 0.6384449601173401, 0.36084282398223877, -0.5430501103401184, 0.8390292525291443, -0.5703829526901245, -1.171385645866394, -1.4230430126190186, -0.5097267031669617, -0.993870198726654, -0.9354330897331238, 0.9747263193130493, 0.8297193050384521, 0.26219063997268677, 1.8721354007720947, 0.5594800114631653, 0.21148833632469177, -2.7317748069763184, 0.8868690133094788, 0.22033008933067322, -0.10337479412555695, 0.8163017630577087, 0.2658950090408325, 0.8421486616134644, -0.14893795549869537, 0.5347214937210083, -2.4100685119628906, 2.310335636138916, -0.13875728845596313, 0.7231941223144531, 0.04158341512084007, -0.05868270993232727, 1.026578426361084, 0.6028821468353271, 0.6708744168281555, -1.0167981386184692, 0.5641589164733887, -0.6766595244407654, 1.4266313314437866, 0.8462743163108826, -0.7726748585700989, -0.14846263825893402, 1.3438785076141357, 0.3924572467803955, -0.4579618275165558, -0.8703652024269104, -1.1303564310073853, 0.990817129611969, 1.802058458328247, -0.05331200733780861, 0.022802632302045822, 0.8004308342933655, 0.626101016998291, -1.3289216756820679, -0.0710420235991478, -0.8308138251304626, -0.6886693239212036, 1.6393797397613525, 2.2045669555664062, -0.15334613621234894, -0.3085070252418518, -0.7128295302391052, -1.2655431032180786, 0.7761407494544983, 0.059813786298036575, 0.11856425553560257, 0.7304809093475342, -0.5292959213256836, 1.1220545768737793, 1.000036358833313, 0.9901735782623291, 0.22414721548557281, 0.26907679438591003, 0.1875554621219635, -0.3379146456718445, -1.346647024154663, -0.2940838634967804, -0.9612100720405579, -2.526426076889038, 0.41359835863113403, -0.22862404584884644, -1.4245706796646118, 0.036775339394807816, -1.1330655813217163, 0.8141762018203735, -0.5112038850784302, -1.0464640855789185, -1.450719952583313, 0.11254265904426575, 0.004896879196166992, 0.8875681757926941, -1.5742524862289429, -0.052829559892416, 1.2539933919906616, 1.0081130266189575, -0.6938338279724121, 0.9216641783714294, 0.2845785915851593, 1.1038674116134644, 0.9435144662857056, -0.3646606504917145, 0.5444023013114929, 0.015741005539894104, -1.367933750152588, 0.466152548789978, 1.1551119089126587, 0.15342311561107635, 1.5171263217926025, -0.6534109711647034, -0.043612390756607056, 0.41230443120002747, -0.5631259679794312, -0.3941103219985962, -0.6362221240997314, 0.7370845079421997, 0.008648938499391079, -0.9226896166801453, -0.038465000689029694, 0.03622233122587204, -0.12413041293621063, 0.18192730844020844, -1.533246397972107, 0.007799259386956692, -0.2125575989484787, -0.7611904144287109, -1.1931160688400269, -0.13850119709968567, 1.338515043258667, -0.9526916742324829, -0.12456728518009186, 0.39672359824180603, 0.2877415418624878, 0.5643693208694458, 0.6615731716156006, -0.6029791831970215, -0.4487988352775574, -0.175560861825943, -0.374789834022522, 0.35319483280181885, 1.4354710578918457, -0.12951265275478363, -0.9866830706596375, 0.7671860456466675, -0.4103507101535797, 0.046730075031518936, 1.7998660802841187, 0.05727260932326317, -0.7814351916313171, 0.2346203476190567, -0.6611585021018982, 1.9587994813919067, 1.6529520750045776, 1.2622148990631104, -0.09153934568166733, -1.0183217525482178, 0.6223366260528564, -0.3653489351272583, -0.3254954516887665, 0.8063622117042542, 0.4267098009586334, -0.18169686198234558, -1.3257523775100708, 0.6647316217422485, 1.2623326778411865, -0.928260087966919, -0.8715590834617615, 0.10066093504428864, -0.8443496823310852, 1.0493825674057007, 0.8126497864723206, 0.3798791170120239, 0.18554125726222992, 1.6869046688079834, 0.7967765927314758, -0.44165143370628357, 0.49108630418777466, 0.5607973337173462, -0.1426316499710083, -2.1508092880249023, -1.0256245136260986, 0.3128637671470642, -0.5429505705833435, -1.7075401544570923, 1.2983195781707764, -1.1916438341140747, -0.8798059821128845, 0.5028707981109619, 0.12433233112096786, 1.4981108903884888, 0.2713067829608917, 1.5434373617172241, 1.963214635848999, 0.9267886877059937, 0.3440465033054352, 1.2690260410308838, -0.14753837883472443, -0.4441484808921814, 1.65848970413208, -0.429789274930954, 0.517814040184021, 1.0467941761016846, -0.31982842087745667, -1.0171407461166382, -0.7743761539459229, -1.322275161743164, -0.8146862983703613, 1.1806519031524658, 0.14827083051204681, -1.1833155155181885, 0.17331261932849884, 1.5206373929977417, 0.07048733532428741, -0.23335999250411987, 0.5254168510437012, 0.350941002368927, -0.7990825176239014, -0.08825477957725525, -0.8935784101486206, 0.47578147053718567, -0.14572547376155853, -0.3795539438724518, 0.3167738616466522, 0.3302242159843445, 1.3939933776855469, -0.055213820189237595, 0.13467927277088165, 1.1885778903961182, -1.3591750860214233, 1.5515985488891602, -0.6956439018249512, 0.301178514957428, -2.301062822341919, 1.4292562007904053, -0.8697232604026794, 1.8566687107086182, -2.7241549491882324, 0.4313092529773712, -0.5220720171928406, -0.4310764670372009, 0.26004689931869507, -0.35094037652015686, 0.10874396562576294, -0.1652052253484726, -1.223440170288086, -0.10933618247509003, -0.6979078650474548, 0.5789191722869873, 1.0074787139892578, 1.3465533256530762, -1.1657015085220337, -0.3098565638065338, -1.7589634656906128, -0.1398058980703354, -0.7012419700622559, 0.42494240403175354, -1.9944571256637573, -0.11885832995176315, -1.8803870677947998, -2.374851942062378, -1.2155036926269531, -0.758938193321228, 1.0683714151382446, 0.001677018590271473, -0.704300045967102, 1.1461889743804932, -0.4095909297466278, -1.9698913097381592, 1.1188642978668213, -2.2082505226135254 ]
https://github.com/huggingface/datasets/issues/5228
Loading a dataset from the hub fails if you happen to have a folder of the same name
`load_dataset` first checks for a local directory before checking for the Hub. To make it explicit that it has to fetch the Hub, we could support the `hffs` syntax: ```python load_dataset("hf://datasets/glue") ``` would that work for you ? Also cc @mariosasko who's leading the `hffs` project
### Describe the bug I'm not 100% sure this should be considered a bug, but it was certainly annoying to figure out the cause of. And perhaps I am just missing a specific argument needed to avoid this conflict. Basically I had a situation where multiple workers were downloading different parts of the glue dataset and then training on them. Additionally, they were writing their checkpoints to a folder called `glue`. This meant that once one worker had created the `glue` folder to write checkpoints to, the next worker to try to load a glue dataset would fail as shown in the minimal repro below. I'm not sure what the solution would be since I'm not super familiar with the `datasets` code, but I would expect `load_dataset` to not crash just because i have a local folder with the same name as a dataset from the hub. ### Steps to reproduce the bug ``` In [1]: import datasets In [2]: rte = datasets.load_dataset('glue', 'rte') Downloading and preparing dataset glue/rte to /Users/danielking/.cache/huggingface/datasets/glue/rte/1.0.0/dacbe3125aa31d7f70367a07a8a9e72a5a0bfeb5fc42e75c9db75b96da6053ad... Downloading data: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 697k/697k [00:00<00:00, 6.08MB/s] Dataset glue downloaded and prepared to /Users/danielking/.cache/huggingface/datasets/glue/rte/1.0.0/dacbe3125aa31d7f70367a07a8a9e72a5a0bfeb5fc42e75c9db75b96da6053ad. Subsequent calls will reuse this data. 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3/3 [00:00<00:00, 773.81it/s] In [3]: import os In [4]: os.mkdir('glue') In [5]: rte = datasets.load_dataset('glue', 'rte') --------------------------------------------------------------------------- EmptyDatasetError Traceback (most recent call last) <ipython-input-5-0d6b9ad8bbd0> in <cell line: 1>() ----> 1 rte = datasets.load_dataset('glue', 'rte') ~/miniconda3/envs/composer/lib/python3.9/site-packages/datasets/load.py in load_dataset(path, name, data_dir, data_files, split, cache_dir, features, download_config, download_mode, ignore_verifications, keep_in_memory, save_infos, revision, use_auth_token, task, streaming, **config_kwargs) 1717 1718 # Create a dataset builder -> 1719 builder_instance = load_dataset_builder( 1720 path=path, 1721 name=name, ~/miniconda3/envs/composer/lib/python3.9/site-packages/datasets/load.py in load_dataset_builder(path, name, data_dir, data_files, cache_dir, features, download_config, download_mode, revision, use_auth_token, **config_kwargs) 1495 download_config = download_config.copy() if download_config else DownloadConfig() 1496 download_config.use_auth_token = use_auth_token -> 1497 dataset_module = dataset_module_factory( 1498 path, 1499 revision=revision, ~/miniconda3/envs/composer/lib/python3.9/site-packages/datasets/load.py in dataset_module_factory(path, revision, download_config, download_mode, dynamic_modules_path, data_dir, data_files, **download_kwargs) 1152 ).get_module() 1153 elif os.path.isdir(path): -> 1154 return LocalDatasetModuleFactoryWithoutScript( 1155 path, data_dir=data_dir, data_files=data_files, download_mode=download_mode 1156 ).get_module() ~/miniconda3/envs/composer/lib/python3.9/site-packages/datasets/load.py in get_module(self) 624 base_path = os.path.join(self.path, self.data_dir) if self.data_dir else self.path 625 patterns = ( --> 626 sanitize_patterns(self.data_files) if self.data_files is not None else get_data_patterns_locally(base_path) 627 ) 628 data_files = DataFilesDict.from_local_or_remote( ~/miniconda3/envs/composer/lib/python3.9/site-packages/datasets/data_files.py in get_data_patterns_locally(base_path) 458 return _get_data_files_patterns(resolver) 459 except FileNotFoundError: --> 460 raise EmptyDatasetError(f"The directory at {base_path} doesn't contain any data files") from None 461 462 EmptyDatasetError: The directory at glue doesn't contain any data files ``` ### Expected behavior Dataset is still able to be loaded from the hub even if I have a local folder with the same name. ### Environment info datasets version: 2.6.1
427
46
Loading a dataset from the hub fails if you happen to have a folder of the same name ### Describe the bug I'm not 100% sure this should be considered a bug, but it was certainly annoying to figure out the cause of. And perhaps I am just missing a specific argument needed to avoid this conflict. Basically I had a situation where multiple workers were downloading different parts of the glue dataset and then training on them. Additionally, they were writing their checkpoints to a folder called `glue`. This meant that once one worker had created the `glue` folder to write checkpoints to, the next worker to try to load a glue dataset would fail as shown in the minimal repro below. I'm not sure what the solution would be since I'm not super familiar with the `datasets` code, but I would expect `load_dataset` to not crash just because i have a local folder with the same name as a dataset from the hub. ### Steps to reproduce the bug ``` In [1]: import datasets In [2]: rte = datasets.load_dataset('glue', 'rte') Downloading and preparing dataset glue/rte to /Users/danielking/.cache/huggingface/datasets/glue/rte/1.0.0/dacbe3125aa31d7f70367a07a8a9e72a5a0bfeb5fc42e75c9db75b96da6053ad... Downloading data: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 697k/697k [00:00<00:00, 6.08MB/s] Dataset glue downloaded and prepared to /Users/danielking/.cache/huggingface/datasets/glue/rte/1.0.0/dacbe3125aa31d7f70367a07a8a9e72a5a0bfeb5fc42e75c9db75b96da6053ad. Subsequent calls will reuse this data. 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3/3 [00:00<00:00, 773.81it/s] In [3]: import os In [4]: os.mkdir('glue') In [5]: rte = datasets.load_dataset('glue', 'rte') --------------------------------------------------------------------------- EmptyDatasetError Traceback (most recent call last) <ipython-input-5-0d6b9ad8bbd0> in <cell line: 1>() ----> 1 rte = datasets.load_dataset('glue', 'rte') ~/miniconda3/envs/composer/lib/python3.9/site-packages/datasets/load.py in load_dataset(path, name, data_dir, data_files, split, cache_dir, features, download_config, download_mode, ignore_verifications, keep_in_memory, save_infos, revision, use_auth_token, task, streaming, **config_kwargs) 1717 1718 # Create a dataset builder -> 1719 builder_instance = load_dataset_builder( 1720 path=path, 1721 name=name, ~/miniconda3/envs/composer/lib/python3.9/site-packages/datasets/load.py in load_dataset_builder(path, name, data_dir, data_files, cache_dir, features, download_config, download_mode, revision, use_auth_token, **config_kwargs) 1495 download_config = download_config.copy() if download_config else DownloadConfig() 1496 download_config.use_auth_token = use_auth_token -> 1497 dataset_module = dataset_module_factory( 1498 path, 1499 revision=revision, ~/miniconda3/envs/composer/lib/python3.9/site-packages/datasets/load.py in dataset_module_factory(path, revision, download_config, download_mode, dynamic_modules_path, data_dir, data_files, **download_kwargs) 1152 ).get_module() 1153 elif os.path.isdir(path): -> 1154 return LocalDatasetModuleFactoryWithoutScript( 1155 path, data_dir=data_dir, data_files=data_files, download_mode=download_mode 1156 ).get_module() ~/miniconda3/envs/composer/lib/python3.9/site-packages/datasets/load.py in get_module(self) 624 base_path = os.path.join(self.path, self.data_dir) if self.data_dir else self.path 625 patterns = ( --> 626 sanitize_patterns(self.data_files) if self.data_files is not None else get_data_patterns_locally(base_path) 627 ) 628 data_files = DataFilesDict.from_local_or_remote( ~/miniconda3/envs/composer/lib/python3.9/site-packages/datasets/data_files.py in get_data_patterns_locally(base_path) 458 return _get_data_files_patterns(resolver) 459 except FileNotFoundError: --> 460 raise EmptyDatasetError(f"The directory at {base_path} doesn't contain any data files") from None 461 462 EmptyDatasetError: The directory at glue doesn't contain any data files ``` ### Expected behavior Dataset is still able to be loaded from the hub even if I have a local folder with the same name. ### Environment info datasets version: 2.6.1 `load_dataset` first checks for a local directory before checking for the Hub. To make it explicit that it has to fetch the Hub, we could support the `hffs` syntax: ```python load_dataset("hf://datasets/glue") ``` would that work for you ? Also cc @mariosasko who's leading the `hffs` project
[ -1.2131543159484863, -0.9564005136489868, -0.8099877238273621, 1.3657832145690918, -0.13374356925487518, -1.2053414583206177, 0.07706921547651291, -1.1170157194137573, 1.7217015027999878, -0.7816483974456787, 0.17890967428684235, -1.696474313735962, 0.027815470471978188, -0.5958007574081421, -0.7802811861038208, -0.8928460478782654, -0.37964463233947754, -0.7801126837730408, 0.9639599919319153, 2.5694403648376465, 1.0924615859985352, -1.4331532716751099, 2.8071563243865967, 0.6881861090660095, -0.15599730610847473, -0.9906968474388123, 0.5288132429122925, 0.027754483744502068, -1.2739530801773071, -0.40502670407295227, -0.9182989597320557, 0.032313913106918335, -0.5587345957756042, -0.5285069346427917, 0.10916852951049805, 0.3653695583343506, -0.33734115958213806, -0.4003702998161316, -0.5385255217552185, -0.7060883641242981, 0.4407091736793518, -0.3699881136417389, 0.9628760814666748, -0.35276949405670166, 1.7776740789413452, -0.5187954306602478, 0.325233519077301, 0.6975334882736206, 1.4175218343734741, 0.21561679244041443, 0.06375327706336975, 0.36026570200920105, 0.33989930152893066, -0.02922527864575386, 0.3930877447128296, 1.16804838180542, 0.5658486485481262, 0.4766666889190674, 0.7189942002296448, -2.2227749824523926, 1.3355671167373657, -0.8946899175643921, 0.3259508013725281, 1.3285855054855347, -0.8124657273292542, 0.37244459986686707, -1.8499573469161987, -0.0495511069893837, 0.5827456116676331, -2.2390224933624268, 0.24262815713882446, -1.3368746042251587, -0.48391422629356384, 0.9350795745849609, 0.2581019997596741, -1.1817606687545776, 0.3063816726207733, -0.4589294493198395, 1.0635124444961548, 0.4809603989124298, 1.214213490486145, -1.7344326972961426, 0.04333369433879852, -0.24517913162708282, 0.10366825759410858, -1.2563998699188232, -1.5795120000839233, 0.4847591519355774, 0.6196723580360413, 0.6605019569396973, -0.04700002074241638, 0.9317816495895386, -0.9575029611587524, 0.746595025062561, -0.9341337084770203, -1.6810634136199951, -1.3357751369476318, -2.2631146907806396, -2.33497953414917, 0.777742862701416, -0.4665314555168152, -0.48926475644111633, 2.016603946685791, -0.9845731258392334, -1.8336118459701538, 1.1526169776916504, 0.3242465853691101, -0.017219936475157738, 2.3998353481292725, 0.1870507001876831, -0.713716983795166, 0.4857644736766815, -0.6883172988891602, 0.8329390287399292, -0.34251633286476135, 1.4171483516693115, 0.49198079109191895, -0.9217196106910706, 1.6049342155456543, -0.43676358461380005, 0.5730918645858765, -0.7325308918952942, -0.5132783055305481, -0.8394752740859985, 0.4367506802082062, 1.847699761390686, -0.3698772192001343, 1.6032804250717163, -0.410092294216156, -1.5990103483200073, -1.593237042427063, 0.8929473757743835, 0.5556783080101013, -0.7670290470123291, 0.023539060726761818, -0.4120951294898987, 0.06890544295310974, -0.0162939615547657, 1.1043133735656738, 1.2166804075241089, 0.7066119313240051, -0.2804654538631439, -0.9199469089508057, 0.2053857147693634, -0.1248595342040062, -0.6865695714950562, -1.8362420797348022, -0.24700786173343658, 0.21797412633895874, 0.6250201463699341, -1.2743535041809082, 1.6413687467575073, 0.8815248012542725, 1.983863353729248, 1.0199164152145386, -0.33978548645973206, 1.51712965965271, 0.11007436364889145, 1.906550407409668, -0.47963884472846985, 0.537876546382904, -0.28712716698646545, -1.1115015745162964, 0.838640570640564, -0.35673388838768005, -2.060054302215576, -0.7919554710388184, -0.8086788654327393, -0.21200433373451233, -0.7575519680976868, 0.9001872539520264, -0.29440802335739136, -1.424917459487915, 0.2717626392841339, -0.6124676465988159, 0.11425012350082397, -1.1912486553192139, 0.20607125759124756, 0.7404053807258606, -0.6274763941764832, 0.06819768249988556, -0.2546118199825287, -1.3868632316589355, -0.461185485124588, 0.3192427158355713, 1.912268042564392, -0.6878206133842468, 0.8542131185531616, 1.0944970846176147, -0.6941770911216736, 0.08205020427703857, 0.3793926537036896, -0.2937796413898468, 0.8349248766899109, -1.1528652906417847, -0.3324154019355774, 1.10533607006073, -0.14935922622680664, -0.5492544174194336, 1.4549518823623657, 0.7786230444908142, -1.0237611532211304, -0.12333302944898605, -0.12041793018579483, -0.8505557775497437, -0.08019863069057465, -1.6220451593399048, -0.15341196954250336, 0.27510005235671997, -1.4721519947052002, -0.4595077931880951, -0.30192744731903076, 1.1796249151229858, -0.17099611461162567, 1.4541442394256592, -0.35520637035369873, -0.1741785705089569, -0.36086446046829224, -0.43417686223983765, 0.12128302454948425, -0.24554817378520966, -0.6591632962226868, 0.21974749863147736, -0.7750972509384155, 0.35268911719322205, 1.4558380842208862, 0.40904727578163147, 0.011688778176903725, 0.5001165270805359, 1.1367791891098022, 0.32963815331459045, -0.0701940581202507, -0.8584850430488586, -1.5928748846054077, 1.9920321702957153, -1.470245599746704, 1.9081758260726929, 0.7607772946357727, 0.027957292273640633, -1.7935020923614502, -1.8447800874710083, 1.4224259853363037, 1.0913991928100586, 2.456230401992798, 0.5171665549278259, 0.42672422528266907, -0.8199149370193481, -0.7247009873390198, 0.31624966859817505, -0.9461191892623901, -0.7336462140083313, 0.1267549842596054, 2.3250811100006104, 1.7628835439682007, -0.5221162438392639, -0.20434220135211945, -1.0014079809188843, 1.3004142045974731, -0.1457212269306183, 0.14301364123821259, 1.9920176267623901, -0.23710790276527405, -1.083860158920288, 1.3514564037322998, -2.3088698387145996, 0.10394110530614853, 2.0133702754974365, 0.21960702538490295, 0.06232856959104538, -1.4278926849365234, -0.6812792420387268, -0.33441317081451416, -0.4060012102127075, -1.368322730064392, 0.5289145708084106, -0.3277361989021301, -0.8426268696784973, -1.5432326793670654, 0.16098764538764954, -1.1832473278045654, -1.5748223066329956, 0.24367186427116394, 1.8904423713684082, 2.0586843490600586, -0.7349296808242798, 1.5173333883285522, -0.2933337986469269, 0.16998155415058136, 1.2111340761184692, 1.1831912994384766, 3.1646809577941895, 1.837448000907898, -1.2878841161727905, 0.7151526808738708, -0.15497750043869019, -0.4720470607280731, 1.1223868131637573, -1.098174810409546, 1.2031649351119995, -0.22739247977733612, -1.189158320426941, -1.2463386058807373, 0.9711914658546448, 0.5058698654174805, 0.07053995132446289, -0.4822447896003723, 1.2391597032546997, 0.041718557476997375, 1.2625153064727783, 0.5483624339103699, -0.3639829754829407, 0.6252976655960083, -0.35732951760292053, -0.584026575088501, 1.5887657403945923, 0.17590907216072083, -1.428161859512329, -2.371518850326538, -0.28659799695014954, -0.842269778251648, -0.011636171489953995, -0.639126718044281, -1.0594260692596436, 1.6615846157073975, 0.4048316478729248, -1.2785264253616333, -0.3239685595035553, -0.3435766100883484, -0.6363274455070496, 2.624966621398926, -1.3855007886886597, -0.16907909512519836, -0.9288422465324402, -0.5129795670509338, 1.5851763486862183, -1.0916210412979126, -0.14843255281448364, -1.0224013328552246, -0.6407095789909363, -1.3527520895004272, -0.5503996014595032, -0.047058358788490295, -0.9087177515029907, 0.790041983127594, 0.2010422945022583, -1.1300724744796753, -0.23503980040550232, -0.9134992957115173, 0.9217239618301392, -0.057107582688331604, 0.23990494012832642, 1.8736830949783325, 0.4730192720890045, -0.4203164577484131, 0.7229582667350769, 1.1448050737380981, 0.6189255714416504, -0.6676800847053528, 0.1279762238264084, -0.7329960465431213, 0.2415761947631836, -1.4156889915466309, 0.27011314034461975, -2.8544869422912598, 0.7100893259048462, -0.09256448596715927, -0.09222457557916641, 0.00739528052508831, -1.206408143043518, 1.093705415725708, 2.6669914722442627, -1.2044085264205933, 0.4730381369590759, 0.32930484414100647, 1.2631555795669556, -1.567175030708313, 0.32647261023521423, -0.40167608857154846, 2.092334508895874, 0.11083222180604935, 1.1106164455413818, -0.5627629160881042, -2.286482810974121, 0.5942909717559814, -1.2716829776763916, -1.143701434135437, 0.8250771760940552, -0.8069140911102295, 0.09242355078458786, -1.4422589540481567, -0.24695824086666107, -0.9366777539253235, -1.2187753915786743, 0.7673506140708923, 0.10884568095207214, 0.42059847712516785, -0.5991870164871216, 0.34380361437797546, -2.1807687282562256, -1.3202027082443237, -0.22978778183460236, -0.9632015228271484, 0.5018953680992126, -0.28925320506095886, 0.701324999332428, -0.1462181657552719, 0.00838499516248703, 0.29107630252838135, 1.3396905660629272, 3.3950250148773193, 0.22632041573524475, 0.3965485692024231, -0.12378403544425964, -0.9173001050949097, 1.3660377264022827, 1.005137324333191, -0.1346127688884735, -0.6167927980422974, -1.0482007265090942, 1.2513467073440552, 2.005589485168457, 0.987412691116333, 0.06736652553081512, -0.8267658948898315, -0.6899852156639099, 0.06074132025241852, 0.19065876305103302, 0.5108506679534912, 0.930535078048706, 0.004089390859007835, 0.061044417321681976, 1.5065375566482544, 1.215111255645752, -0.41927531361579895, 0.38011404871940613, -0.83426833152771, -0.4947134554386139, 0.4915730953216553, 0.2912079989910126, 0.03450985252857208, 0.38626357913017273, -1.0617847442626953, -0.2133978009223938, -0.4027870297431946, -0.9810261130332947, -0.6850911378860474, -0.40800419449806213, -0.32248157262802124, 1.6255840063095093, 0.15389341115951538, -0.44032344222068787, -0.001262781210243702, -0.7127264738082886, -0.14683941006660461, -1.0965304374694824, 0.3581259846687317, -0.14313596487045288, -0.0795956626534462, -0.09453689306974411, 1.7613677978515625, -0.9934456944465637, -2.1230857372283936, 0.15379442274570465, 0.20470592379570007, -0.4068910777568817, 0.2312467396259308, 1.6601459980010986, 0.5794008374214172, 1.4448188543319702, 1.3490068912506104, 0.9336904883384705, -0.6198389530181885, -1.297320008277893, 0.626679539680481, 0.9824135899543762, -1.343712329864502, 0.8119831681251526, -0.04969748854637146, -0.5967758893966675, 0.7744405269622803, 1.366419792175293, 0.34252890944480896, -2.108299493789673, 0.7954733967781067, -0.8488076329231262, 0.6538755297660828, 0.6521704196929932, 0.7265692353248596, 0.2304999977350235, 0.8594523072242737, -1.2313069105148315, -1.1792018413543701, -0.780593752861023, -0.6552674770355225, 1.921244740486145, -0.18122147023677826, 0.5546832084655762, -0.15687574446201324, -1.3233686685562134, -0.06922195851802826, 0.6884776949882507, 0.41254308819770813, -0.4339618980884552, 0.8481271862983704, -0.6575324535369873, -1.1280885934829712, -1.3740770816802979, -0.4885236918926239, -1.005361557006836, -0.8756285905838013, 0.9666101336479187, 0.7821241021156311, 0.2612464129924774, 1.884685754776001, 0.6565936803817749, 0.27672135829925537, -2.6516239643096924, 0.8401220440864563, 0.2868594825267792, 0.010977104306221008, 0.9510504603385925, 0.34314486384391785, 1.0510679483413696, 0.05471532791852951, 0.571945071220398, -2.293839454650879, 2.188669443130493, -0.24887636303901672, 0.7879719138145447, -0.08390795439481735, -0.20505766570568085, 1.0698930025100708, 0.5438540577888489, 0.5726972818374634, -1.1119970083236694, 0.7235469222068787, -0.6758543848991394, 1.1626644134521484, 0.9460197687149048, -0.8071392774581909, 0.03648563474416733, 1.3041574954986572, 0.4354252219200134, -0.4517279863357544, -0.9657183289527893, -0.9566508531570435, 0.9616689085960388, 1.7249524593353271, -0.09520330280065536, 0.05609077215194702, 0.8443496227264404, 0.6121705174446106, -1.34092116355896, 0.08262060582637787, -0.7168980836868286, -0.7379292845726013, 1.6785403490066528, 2.0300381183624268, -0.10607285797595978, -0.19876065850257874, -0.734600305557251, -1.2279863357543945, 0.7394090294837952, -0.04687907546758652, 0.22338545322418213, 0.6246070265769958, -0.7032831907272339, 1.205474853515625, 0.7741436958312988, 0.925794780254364, 0.04869093745946884, 0.4393579065799713, 0.4361984431743622, -0.2945646047592163, -1.1441266536712646, -0.30865028500556946, -1.1174240112304688, -2.345104694366455, 0.5107324719429016, -0.15488320589065552, -1.5158687829971313, 0.052299290895462036, -0.9984188675880432, 0.9497238397598267, -0.5096226930618286, -1.138824701309204, -1.5048388242721558, 0.28261828422546387, -0.09484653174877167, 0.9350152611732483, -1.574236273765564, -0.08098173141479492, 1.1863166093826294, 0.9523678421974182, -0.5943489670753479, 1.0366697311401367, 0.29884007573127747, 1.0323082208633423, 0.8885979652404785, -0.4142359793186188, 0.44596731662750244, 0.11666040122509003, -1.2985447645187378, 0.4185459017753601, 1.1197441816329956, 0.215088352560997, 1.3771638870239258, -0.5473501086235046, -0.0006275847554206848, 0.359631210565567, -0.5160099864006042, -0.4069894850254059, -0.5625532865524292, 0.6848472356796265, 0.07353904098272324, -0.8553698062896729, 0.013901259750127792, -0.1023290827870369, -0.22508370876312256, 0.2820592522621155, -1.5369175672531128, -0.280549019575119, -0.44403275847435, -0.5244295597076416, -1.2835222482681274, 0.09195908904075623, 1.3764052391052246, -0.7700545191764832, -0.23563458025455475, 0.5092789530754089, 0.4920664429664612, 0.5111609697341919, 0.6096071004867554, -0.6119673252105713, -0.3692099452018738, -0.36305758357048035, -0.37787964940071106, 0.18134111166000366, 1.2803585529327393, -0.14302608370780945, -1.005686640739441, 0.7596756815910339, -0.5304312109947205, 0.0026386473327875137, 1.8992843627929688, 0.015072755515575409, -0.7773664593696594, 0.32811596989631653, -0.6963106989860535, 1.9110773801803589, 1.7643898725509644, 1.3739393949508667, -0.14987947046756744, -0.9131626486778259, 0.625871479511261, -0.23317711055278778, -0.34942692518234253, 1.0105713605880737, 0.5374861359596252, -0.1524018794298172, -1.464640498161316, 0.5083402991294861, 1.2753186225891113, -0.8909239768981934, -0.7428153157234192, 0.05690868943929672, -0.8334367275238037, 1.0693025588989258, 0.762290894985199, 0.3921605944633484, 0.15250518918037415, 1.6644856929779053, 0.6872095465660095, -0.5589478611946106, 0.5568127632141113, 0.5092639923095703, -0.16527265310287476, -2.1534759998321533, -1.0672938823699951, 0.2569178640842438, -0.2743751108646393, -1.6049892902374268, 1.327408790588379, -1.0952987670898438, -0.9242061376571655, 0.5320425033569336, 0.03702365607023239, 1.3803712129592896, 0.3180425465106964, 1.6265474557876587, 2.1514647006988525, 0.9011508226394653, 0.3072272539138794, 1.3229055404663086, -0.08723869919776917, -0.441696435213089, 1.8930963277816772, -0.47608187794685364, 0.552993655204773, 1.0467647314071655, -0.4070722758769989, -1.053086519241333, -0.7504327893257141, -1.1377911567687988, -0.6619042158126831, 1.1602414846420288, 0.13095228374004364, -1.19313383102417, 0.28760918974876404, 1.6217997074127197, 0.053163155913352966, -0.3142746090888977, 0.6413196325302124, 0.5228017568588257, -0.7708320021629333, -0.10545458644628525, -0.9129113554954529, 0.5162692666053772, -0.15019166469573975, -0.2730116844177246, 0.2563728094100952, 0.4642944633960724, 1.336983323097229, -0.033852145075798035, 0.13615921139717102, 1.2715630531311035, -1.4096462726593018, 1.420576810836792, -0.5900564789772034, 0.3195051848888397, -2.4496922492980957, 1.3840186595916748, -0.7453445792198181, 1.8525935411453247, -2.6061999797821045, 0.44332313537597656, -0.6960283517837524, -0.4144291877746582, 0.3438243567943573, -0.3265434801578522, 0.11525719612836838, -0.1572413444519043, -1.068949580192566, -0.09360780566930771, -0.7100547552108765, 0.5554919838905334, 1.1657743453979492, 1.2867532968521118, -1.023167371749878, -0.25121599435806274, -1.7161002159118652, -0.21771463751792908, -0.7042033672332764, 0.28044673800468445, -2.0286526679992676, -0.1893504112958908, -1.9661517143249512, -2.3966221809387207, -1.4514894485473633, -0.8419768810272217, 1.0579041242599487, 0.19426894187927246, -1.0140634775161743, 1.2171545028686523, -0.39788028597831726, -1.7684861421585083, 1.1349775791168213, -2.129639148712158 ]
https://github.com/huggingface/datasets/issues/5228
Loading a dataset from the hub fails if you happen to have a folder of the same name
This still has no proper solution in 2.11 perhaps have a `download_config="force_remote"` or just backtrack once you reach `EmptyDatasetError` locally and then try to load it from the hub (or a local cache, as that only gets checked if there is no local folder...?)
### Describe the bug I'm not 100% sure this should be considered a bug, but it was certainly annoying to figure out the cause of. And perhaps I am just missing a specific argument needed to avoid this conflict. Basically I had a situation where multiple workers were downloading different parts of the glue dataset and then training on them. Additionally, they were writing their checkpoints to a folder called `glue`. This meant that once one worker had created the `glue` folder to write checkpoints to, the next worker to try to load a glue dataset would fail as shown in the minimal repro below. I'm not sure what the solution would be since I'm not super familiar with the `datasets` code, but I would expect `load_dataset` to not crash just because i have a local folder with the same name as a dataset from the hub. ### Steps to reproduce the bug ``` In [1]: import datasets In [2]: rte = datasets.load_dataset('glue', 'rte') Downloading and preparing dataset glue/rte to /Users/danielking/.cache/huggingface/datasets/glue/rte/1.0.0/dacbe3125aa31d7f70367a07a8a9e72a5a0bfeb5fc42e75c9db75b96da6053ad... Downloading data: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 697k/697k [00:00<00:00, 6.08MB/s] Dataset glue downloaded and prepared to /Users/danielking/.cache/huggingface/datasets/glue/rte/1.0.0/dacbe3125aa31d7f70367a07a8a9e72a5a0bfeb5fc42e75c9db75b96da6053ad. Subsequent calls will reuse this data. 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3/3 [00:00<00:00, 773.81it/s] In [3]: import os In [4]: os.mkdir('glue') In [5]: rte = datasets.load_dataset('glue', 'rte') --------------------------------------------------------------------------- EmptyDatasetError Traceback (most recent call last) <ipython-input-5-0d6b9ad8bbd0> in <cell line: 1>() ----> 1 rte = datasets.load_dataset('glue', 'rte') ~/miniconda3/envs/composer/lib/python3.9/site-packages/datasets/load.py in load_dataset(path, name, data_dir, data_files, split, cache_dir, features, download_config, download_mode, ignore_verifications, keep_in_memory, save_infos, revision, use_auth_token, task, streaming, **config_kwargs) 1717 1718 # Create a dataset builder -> 1719 builder_instance = load_dataset_builder( 1720 path=path, 1721 name=name, ~/miniconda3/envs/composer/lib/python3.9/site-packages/datasets/load.py in load_dataset_builder(path, name, data_dir, data_files, cache_dir, features, download_config, download_mode, revision, use_auth_token, **config_kwargs) 1495 download_config = download_config.copy() if download_config else DownloadConfig() 1496 download_config.use_auth_token = use_auth_token -> 1497 dataset_module = dataset_module_factory( 1498 path, 1499 revision=revision, ~/miniconda3/envs/composer/lib/python3.9/site-packages/datasets/load.py in dataset_module_factory(path, revision, download_config, download_mode, dynamic_modules_path, data_dir, data_files, **download_kwargs) 1152 ).get_module() 1153 elif os.path.isdir(path): -> 1154 return LocalDatasetModuleFactoryWithoutScript( 1155 path, data_dir=data_dir, data_files=data_files, download_mode=download_mode 1156 ).get_module() ~/miniconda3/envs/composer/lib/python3.9/site-packages/datasets/load.py in get_module(self) 624 base_path = os.path.join(self.path, self.data_dir) if self.data_dir else self.path 625 patterns = ( --> 626 sanitize_patterns(self.data_files) if self.data_files is not None else get_data_patterns_locally(base_path) 627 ) 628 data_files = DataFilesDict.from_local_or_remote( ~/miniconda3/envs/composer/lib/python3.9/site-packages/datasets/data_files.py in get_data_patterns_locally(base_path) 458 return _get_data_files_patterns(resolver) 459 except FileNotFoundError: --> 460 raise EmptyDatasetError(f"The directory at {base_path} doesn't contain any data files") from None 461 462 EmptyDatasetError: The directory at glue doesn't contain any data files ``` ### Expected behavior Dataset is still able to be loaded from the hub even if I have a local folder with the same name. ### Environment info datasets version: 2.6.1
427
44
Loading a dataset from the hub fails if you happen to have a folder of the same name ### Describe the bug I'm not 100% sure this should be considered a bug, but it was certainly annoying to figure out the cause of. And perhaps I am just missing a specific argument needed to avoid this conflict. Basically I had a situation where multiple workers were downloading different parts of the glue dataset and then training on them. Additionally, they were writing their checkpoints to a folder called `glue`. This meant that once one worker had created the `glue` folder to write checkpoints to, the next worker to try to load a glue dataset would fail as shown in the minimal repro below. I'm not sure what the solution would be since I'm not super familiar with the `datasets` code, but I would expect `load_dataset` to not crash just because i have a local folder with the same name as a dataset from the hub. ### Steps to reproduce the bug ``` In [1]: import datasets In [2]: rte = datasets.load_dataset('glue', 'rte') Downloading and preparing dataset glue/rte to /Users/danielking/.cache/huggingface/datasets/glue/rte/1.0.0/dacbe3125aa31d7f70367a07a8a9e72a5a0bfeb5fc42e75c9db75b96da6053ad... Downloading data: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 697k/697k [00:00<00:00, 6.08MB/s] Dataset glue downloaded and prepared to /Users/danielking/.cache/huggingface/datasets/glue/rte/1.0.0/dacbe3125aa31d7f70367a07a8a9e72a5a0bfeb5fc42e75c9db75b96da6053ad. Subsequent calls will reuse this data. 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3/3 [00:00<00:00, 773.81it/s] In [3]: import os In [4]: os.mkdir('glue') In [5]: rte = datasets.load_dataset('glue', 'rte') --------------------------------------------------------------------------- EmptyDatasetError Traceback (most recent call last) <ipython-input-5-0d6b9ad8bbd0> in <cell line: 1>() ----> 1 rte = datasets.load_dataset('glue', 'rte') ~/miniconda3/envs/composer/lib/python3.9/site-packages/datasets/load.py in load_dataset(path, name, data_dir, data_files, split, cache_dir, features, download_config, download_mode, ignore_verifications, keep_in_memory, save_infos, revision, use_auth_token, task, streaming, **config_kwargs) 1717 1718 # Create a dataset builder -> 1719 builder_instance = load_dataset_builder( 1720 path=path, 1721 name=name, ~/miniconda3/envs/composer/lib/python3.9/site-packages/datasets/load.py in load_dataset_builder(path, name, data_dir, data_files, cache_dir, features, download_config, download_mode, revision, use_auth_token, **config_kwargs) 1495 download_config = download_config.copy() if download_config else DownloadConfig() 1496 download_config.use_auth_token = use_auth_token -> 1497 dataset_module = dataset_module_factory( 1498 path, 1499 revision=revision, ~/miniconda3/envs/composer/lib/python3.9/site-packages/datasets/load.py in dataset_module_factory(path, revision, download_config, download_mode, dynamic_modules_path, data_dir, data_files, **download_kwargs) 1152 ).get_module() 1153 elif os.path.isdir(path): -> 1154 return LocalDatasetModuleFactoryWithoutScript( 1155 path, data_dir=data_dir, data_files=data_files, download_mode=download_mode 1156 ).get_module() ~/miniconda3/envs/composer/lib/python3.9/site-packages/datasets/load.py in get_module(self) 624 base_path = os.path.join(self.path, self.data_dir) if self.data_dir else self.path 625 patterns = ( --> 626 sanitize_patterns(self.data_files) if self.data_files is not None else get_data_patterns_locally(base_path) 627 ) 628 data_files = DataFilesDict.from_local_or_remote( ~/miniconda3/envs/composer/lib/python3.9/site-packages/datasets/data_files.py in get_data_patterns_locally(base_path) 458 return _get_data_files_patterns(resolver) 459 except FileNotFoundError: --> 460 raise EmptyDatasetError(f"The directory at {base_path} doesn't contain any data files") from None 461 462 EmptyDatasetError: The directory at glue doesn't contain any data files ``` ### Expected behavior Dataset is still able to be loaded from the hub even if I have a local folder with the same name. ### Environment info datasets version: 2.6.1 This still has no proper solution in 2.11 perhaps have a `download_config="force_remote"` or just backtrack once you reach `EmptyDatasetError` locally and then try to load it from the hub (or a local cache, as that only gets checked if there is no local folder...?)
[ -1.2131543159484863, -0.9564005136489868, -0.8099877238273621, 1.3657832145690918, -0.13374356925487518, -1.2053414583206177, 0.07706921547651291, -1.1170157194137573, 1.7217015027999878, -0.7816483974456787, 0.17890967428684235, -1.696474313735962, 0.027815470471978188, -0.5958007574081421, -0.7802811861038208, -0.8928460478782654, -0.37964463233947754, -0.7801126837730408, 0.9639599919319153, 2.5694403648376465, 1.0924615859985352, -1.4331532716751099, 2.8071563243865967, 0.6881861090660095, -0.15599730610847473, -0.9906968474388123, 0.5288132429122925, 0.027754483744502068, -1.2739530801773071, -0.40502670407295227, -0.9182989597320557, 0.032313913106918335, -0.5587345957756042, -0.5285069346427917, 0.10916852951049805, 0.3653695583343506, -0.33734115958213806, -0.4003702998161316, -0.5385255217552185, -0.7060883641242981, 0.4407091736793518, -0.3699881136417389, 0.9628760814666748, -0.35276949405670166, 1.7776740789413452, -0.5187954306602478, 0.325233519077301, 0.6975334882736206, 1.4175218343734741, 0.21561679244041443, 0.06375327706336975, 0.36026570200920105, 0.33989930152893066, -0.02922527864575386, 0.3930877447128296, 1.16804838180542, 0.5658486485481262, 0.4766666889190674, 0.7189942002296448, -2.2227749824523926, 1.3355671167373657, -0.8946899175643921, 0.3259508013725281, 1.3285855054855347, -0.8124657273292542, 0.37244459986686707, -1.8499573469161987, -0.0495511069893837, 0.5827456116676331, -2.2390224933624268, 0.24262815713882446, -1.3368746042251587, -0.48391422629356384, 0.9350795745849609, 0.2581019997596741, -1.1817606687545776, 0.3063816726207733, -0.4589294493198395, 1.0635124444961548, 0.4809603989124298, 1.214213490486145, -1.7344326972961426, 0.04333369433879852, -0.24517913162708282, 0.10366825759410858, -1.2563998699188232, -1.5795120000839233, 0.4847591519355774, 0.6196723580360413, 0.6605019569396973, -0.04700002074241638, 0.9317816495895386, -0.9575029611587524, 0.746595025062561, -0.9341337084770203, -1.6810634136199951, -1.3357751369476318, -2.2631146907806396, -2.33497953414917, 0.777742862701416, -0.4665314555168152, -0.48926475644111633, 2.016603946685791, -0.9845731258392334, -1.8336118459701538, 1.1526169776916504, 0.3242465853691101, -0.017219936475157738, 2.3998353481292725, 0.1870507001876831, -0.713716983795166, 0.4857644736766815, -0.6883172988891602, 0.8329390287399292, -0.34251633286476135, 1.4171483516693115, 0.49198079109191895, -0.9217196106910706, 1.6049342155456543, -0.43676358461380005, 0.5730918645858765, -0.7325308918952942, -0.5132783055305481, -0.8394752740859985, 0.4367506802082062, 1.847699761390686, -0.3698772192001343, 1.6032804250717163, -0.410092294216156, -1.5990103483200073, -1.593237042427063, 0.8929473757743835, 0.5556783080101013, -0.7670290470123291, 0.023539060726761818, -0.4120951294898987, 0.06890544295310974, -0.0162939615547657, 1.1043133735656738, 1.2166804075241089, 0.7066119313240051, -0.2804654538631439, -0.9199469089508057, 0.2053857147693634, -0.1248595342040062, -0.6865695714950562, -1.8362420797348022, -0.24700786173343658, 0.21797412633895874, 0.6250201463699341, -1.2743535041809082, 1.6413687467575073, 0.8815248012542725, 1.983863353729248, 1.0199164152145386, -0.33978548645973206, 1.51712965965271, 0.11007436364889145, 1.906550407409668, -0.47963884472846985, 0.537876546382904, -0.28712716698646545, -1.1115015745162964, 0.838640570640564, -0.35673388838768005, -2.060054302215576, -0.7919554710388184, -0.8086788654327393, -0.21200433373451233, -0.7575519680976868, 0.9001872539520264, -0.29440802335739136, -1.424917459487915, 0.2717626392841339, -0.6124676465988159, 0.11425012350082397, -1.1912486553192139, 0.20607125759124756, 0.7404053807258606, -0.6274763941764832, 0.06819768249988556, -0.2546118199825287, -1.3868632316589355, -0.461185485124588, 0.3192427158355713, 1.912268042564392, -0.6878206133842468, 0.8542131185531616, 1.0944970846176147, -0.6941770911216736, 0.08205020427703857, 0.3793926537036896, -0.2937796413898468, 0.8349248766899109, -1.1528652906417847, -0.3324154019355774, 1.10533607006073, -0.14935922622680664, -0.5492544174194336, 1.4549518823623657, 0.7786230444908142, -1.0237611532211304, -0.12333302944898605, -0.12041793018579483, -0.8505557775497437, -0.08019863069057465, -1.6220451593399048, -0.15341196954250336, 0.27510005235671997, -1.4721519947052002, -0.4595077931880951, -0.30192744731903076, 1.1796249151229858, -0.17099611461162567, 1.4541442394256592, -0.35520637035369873, -0.1741785705089569, -0.36086446046829224, -0.43417686223983765, 0.12128302454948425, -0.24554817378520966, -0.6591632962226868, 0.21974749863147736, -0.7750972509384155, 0.35268911719322205, 1.4558380842208862, 0.40904727578163147, 0.011688778176903725, 0.5001165270805359, 1.1367791891098022, 0.32963815331459045, -0.0701940581202507, -0.8584850430488586, -1.5928748846054077, 1.9920321702957153, -1.470245599746704, 1.9081758260726929, 0.7607772946357727, 0.027957292273640633, -1.7935020923614502, -1.8447800874710083, 1.4224259853363037, 1.0913991928100586, 2.456230401992798, 0.5171665549278259, 0.42672422528266907, -0.8199149370193481, -0.7247009873390198, 0.31624966859817505, -0.9461191892623901, -0.7336462140083313, 0.1267549842596054, 2.3250811100006104, 1.7628835439682007, -0.5221162438392639, -0.20434220135211945, -1.0014079809188843, 1.3004142045974731, -0.1457212269306183, 0.14301364123821259, 1.9920176267623901, -0.23710790276527405, -1.083860158920288, 1.3514564037322998, -2.3088698387145996, 0.10394110530614853, 2.0133702754974365, 0.21960702538490295, 0.06232856959104538, -1.4278926849365234, -0.6812792420387268, -0.33441317081451416, -0.4060012102127075, -1.368322730064392, 0.5289145708084106, -0.3277361989021301, -0.8426268696784973, -1.5432326793670654, 0.16098764538764954, -1.1832473278045654, -1.5748223066329956, 0.24367186427116394, 1.8904423713684082, 2.0586843490600586, -0.7349296808242798, 1.5173333883285522, -0.2933337986469269, 0.16998155415058136, 1.2111340761184692, 1.1831912994384766, 3.1646809577941895, 1.837448000907898, -1.2878841161727905, 0.7151526808738708, -0.15497750043869019, -0.4720470607280731, 1.1223868131637573, -1.098174810409546, 1.2031649351119995, -0.22739247977733612, -1.189158320426941, -1.2463386058807373, 0.9711914658546448, 0.5058698654174805, 0.07053995132446289, -0.4822447896003723, 1.2391597032546997, 0.041718557476997375, 1.2625153064727783, 0.5483624339103699, -0.3639829754829407, 0.6252976655960083, -0.35732951760292053, -0.584026575088501, 1.5887657403945923, 0.17590907216072083, -1.428161859512329, -2.371518850326538, -0.28659799695014954, -0.842269778251648, -0.011636171489953995, -0.639126718044281, -1.0594260692596436, 1.6615846157073975, 0.4048316478729248, -1.2785264253616333, -0.3239685595035553, -0.3435766100883484, -0.6363274455070496, 2.624966621398926, -1.3855007886886597, -0.16907909512519836, -0.9288422465324402, -0.5129795670509338, 1.5851763486862183, -1.0916210412979126, -0.14843255281448364, -1.0224013328552246, -0.6407095789909363, -1.3527520895004272, -0.5503996014595032, -0.047058358788490295, -0.9087177515029907, 0.790041983127594, 0.2010422945022583, -1.1300724744796753, -0.23503980040550232, -0.9134992957115173, 0.9217239618301392, -0.057107582688331604, 0.23990494012832642, 1.8736830949783325, 0.4730192720890045, -0.4203164577484131, 0.7229582667350769, 1.1448050737380981, 0.6189255714416504, -0.6676800847053528, 0.1279762238264084, -0.7329960465431213, 0.2415761947631836, -1.4156889915466309, 0.27011314034461975, -2.8544869422912598, 0.7100893259048462, -0.09256448596715927, -0.09222457557916641, 0.00739528052508831, -1.206408143043518, 1.093705415725708, 2.6669914722442627, -1.2044085264205933, 0.4730381369590759, 0.32930484414100647, 1.2631555795669556, -1.567175030708313, 0.32647261023521423, -0.40167608857154846, 2.092334508895874, 0.11083222180604935, 1.1106164455413818, -0.5627629160881042, -2.286482810974121, 0.5942909717559814, -1.2716829776763916, -1.143701434135437, 0.8250771760940552, -0.8069140911102295, 0.09242355078458786, -1.4422589540481567, -0.24695824086666107, -0.9366777539253235, -1.2187753915786743, 0.7673506140708923, 0.10884568095207214, 0.42059847712516785, -0.5991870164871216, 0.34380361437797546, -2.1807687282562256, -1.3202027082443237, -0.22978778183460236, -0.9632015228271484, 0.5018953680992126, -0.28925320506095886, 0.701324999332428, -0.1462181657552719, 0.00838499516248703, 0.29107630252838135, 1.3396905660629272, 3.3950250148773193, 0.22632041573524475, 0.3965485692024231, -0.12378403544425964, -0.9173001050949097, 1.3660377264022827, 1.005137324333191, -0.1346127688884735, -0.6167927980422974, -1.0482007265090942, 1.2513467073440552, 2.005589485168457, 0.987412691116333, 0.06736652553081512, -0.8267658948898315, -0.6899852156639099, 0.06074132025241852, 0.19065876305103302, 0.5108506679534912, 0.930535078048706, 0.004089390859007835, 0.061044417321681976, 1.5065375566482544, 1.215111255645752, -0.41927531361579895, 0.38011404871940613, -0.83426833152771, -0.4947134554386139, 0.4915730953216553, 0.2912079989910126, 0.03450985252857208, 0.38626357913017273, -1.0617847442626953, -0.2133978009223938, -0.4027870297431946, -0.9810261130332947, -0.6850911378860474, -0.40800419449806213, -0.32248157262802124, 1.6255840063095093, 0.15389341115951538, -0.44032344222068787, -0.001262781210243702, -0.7127264738082886, -0.14683941006660461, -1.0965304374694824, 0.3581259846687317, -0.14313596487045288, -0.0795956626534462, -0.09453689306974411, 1.7613677978515625, -0.9934456944465637, -2.1230857372283936, 0.15379442274570465, 0.20470592379570007, -0.4068910777568817, 0.2312467396259308, 1.6601459980010986, 0.5794008374214172, 1.4448188543319702, 1.3490068912506104, 0.9336904883384705, -0.6198389530181885, -1.297320008277893, 0.626679539680481, 0.9824135899543762, -1.343712329864502, 0.8119831681251526, -0.04969748854637146, -0.5967758893966675, 0.7744405269622803, 1.366419792175293, 0.34252890944480896, -2.108299493789673, 0.7954733967781067, -0.8488076329231262, 0.6538755297660828, 0.6521704196929932, 0.7265692353248596, 0.2304999977350235, 0.8594523072242737, -1.2313069105148315, -1.1792018413543701, -0.780593752861023, -0.6552674770355225, 1.921244740486145, -0.18122147023677826, 0.5546832084655762, -0.15687574446201324, -1.3233686685562134, -0.06922195851802826, 0.6884776949882507, 0.41254308819770813, -0.4339618980884552, 0.8481271862983704, -0.6575324535369873, -1.1280885934829712, -1.3740770816802979, -0.4885236918926239, -1.005361557006836, -0.8756285905838013, 0.9666101336479187, 0.7821241021156311, 0.2612464129924774, 1.884685754776001, 0.6565936803817749, 0.27672135829925537, -2.6516239643096924, 0.8401220440864563, 0.2868594825267792, 0.010977104306221008, 0.9510504603385925, 0.34314486384391785, 1.0510679483413696, 0.05471532791852951, 0.571945071220398, -2.293839454650879, 2.188669443130493, -0.24887636303901672, 0.7879719138145447, -0.08390795439481735, -0.20505766570568085, 1.0698930025100708, 0.5438540577888489, 0.5726972818374634, -1.1119970083236694, 0.7235469222068787, -0.6758543848991394, 1.1626644134521484, 0.9460197687149048, -0.8071392774581909, 0.03648563474416733, 1.3041574954986572, 0.4354252219200134, -0.4517279863357544, -0.9657183289527893, -0.9566508531570435, 0.9616689085960388, 1.7249524593353271, -0.09520330280065536, 0.05609077215194702, 0.8443496227264404, 0.6121705174446106, -1.34092116355896, 0.08262060582637787, -0.7168980836868286, -0.7379292845726013, 1.6785403490066528, 2.0300381183624268, -0.10607285797595978, -0.19876065850257874, -0.734600305557251, -1.2279863357543945, 0.7394090294837952, -0.04687907546758652, 0.22338545322418213, 0.6246070265769958, -0.7032831907272339, 1.205474853515625, 0.7741436958312988, 0.925794780254364, 0.04869093745946884, 0.4393579065799713, 0.4361984431743622, -0.2945646047592163, -1.1441266536712646, -0.30865028500556946, -1.1174240112304688, -2.345104694366455, 0.5107324719429016, -0.15488320589065552, -1.5158687829971313, 0.052299290895462036, -0.9984188675880432, 0.9497238397598267, -0.5096226930618286, -1.138824701309204, -1.5048388242721558, 0.28261828422546387, -0.09484653174877167, 0.9350152611732483, -1.574236273765564, -0.08098173141479492, 1.1863166093826294, 0.9523678421974182, -0.5943489670753479, 1.0366697311401367, 0.29884007573127747, 1.0323082208633423, 0.8885979652404785, -0.4142359793186188, 0.44596731662750244, 0.11666040122509003, -1.2985447645187378, 0.4185459017753601, 1.1197441816329956, 0.215088352560997, 1.3771638870239258, -0.5473501086235046, -0.0006275847554206848, 0.359631210565567, -0.5160099864006042, -0.4069894850254059, -0.5625532865524292, 0.6848472356796265, 0.07353904098272324, -0.8553698062896729, 0.013901259750127792, -0.1023290827870369, -0.22508370876312256, 0.2820592522621155, -1.5369175672531128, -0.280549019575119, -0.44403275847435, -0.5244295597076416, -1.2835222482681274, 0.09195908904075623, 1.3764052391052246, -0.7700545191764832, -0.23563458025455475, 0.5092789530754089, 0.4920664429664612, 0.5111609697341919, 0.6096071004867554, -0.6119673252105713, -0.3692099452018738, -0.36305758357048035, -0.37787964940071106, 0.18134111166000366, 1.2803585529327393, -0.14302608370780945, -1.005686640739441, 0.7596756815910339, -0.5304312109947205, 0.0026386473327875137, 1.8992843627929688, 0.015072755515575409, -0.7773664593696594, 0.32811596989631653, -0.6963106989860535, 1.9110773801803589, 1.7643898725509644, 1.3739393949508667, -0.14987947046756744, -0.9131626486778259, 0.625871479511261, -0.23317711055278778, -0.34942692518234253, 1.0105713605880737, 0.5374861359596252, -0.1524018794298172, -1.464640498161316, 0.5083402991294861, 1.2753186225891113, -0.8909239768981934, -0.7428153157234192, 0.05690868943929672, -0.8334367275238037, 1.0693025588989258, 0.762290894985199, 0.3921605944633484, 0.15250518918037415, 1.6644856929779053, 0.6872095465660095, -0.5589478611946106, 0.5568127632141113, 0.5092639923095703, -0.16527265310287476, -2.1534759998321533, -1.0672938823699951, 0.2569178640842438, -0.2743751108646393, -1.6049892902374268, 1.327408790588379, -1.0952987670898438, -0.9242061376571655, 0.5320425033569336, 0.03702365607023239, 1.3803712129592896, 0.3180425465106964, 1.6265474557876587, 2.1514647006988525, 0.9011508226394653, 0.3072272539138794, 1.3229055404663086, -0.08723869919776917, -0.441696435213089, 1.8930963277816772, -0.47608187794685364, 0.552993655204773, 1.0467647314071655, -0.4070722758769989, -1.053086519241333, -0.7504327893257141, -1.1377911567687988, -0.6619042158126831, 1.1602414846420288, 0.13095228374004364, -1.19313383102417, 0.28760918974876404, 1.6217997074127197, 0.053163155913352966, -0.3142746090888977, 0.6413196325302124, 0.5228017568588257, -0.7708320021629333, -0.10545458644628525, -0.9129113554954529, 0.5162692666053772, -0.15019166469573975, -0.2730116844177246, 0.2563728094100952, 0.4642944633960724, 1.336983323097229, -0.033852145075798035, 0.13615921139717102, 1.2715630531311035, -1.4096462726593018, 1.420576810836792, -0.5900564789772034, 0.3195051848888397, -2.4496922492980957, 1.3840186595916748, -0.7453445792198181, 1.8525935411453247, -2.6061999797821045, 0.44332313537597656, -0.6960283517837524, -0.4144291877746582, 0.3438243567943573, -0.3265434801578522, 0.11525719612836838, -0.1572413444519043, -1.068949580192566, -0.09360780566930771, -0.7100547552108765, 0.5554919838905334, 1.1657743453979492, 1.2867532968521118, -1.023167371749878, -0.25121599435806274, -1.7161002159118652, -0.21771463751792908, -0.7042033672332764, 0.28044673800468445, -2.0286526679992676, -0.1893504112958908, -1.9661517143249512, -2.3966221809387207, -1.4514894485473633, -0.8419768810272217, 1.0579041242599487, 0.19426894187927246, -1.0140634775161743, 1.2171545028686523, -0.39788028597831726, -1.7684861421585083, 1.1349775791168213, -2.129639148712158 ]
https://github.com/huggingface/datasets/issues/5226
Q: Memory release when removing the column?
Hi ! Datasets are memory mapped from your disk, i.e. they're not loaded in RAM. This is possible thanks to the Arrow data format. Therefore the column you remove is not in RAM, so removing it doesn't cause the RAM to decrease.
### Describe the bug How do I release memory when I use methods like `.remove_columns()` or `clear()` in notebooks? ```python from datasets import load_dataset common_voice = load_dataset("mozilla-foundation/common_voice_11_0", "ja", use_auth_token=True) # check memory -> RAM Used (GB): 0.704 / Total (GB) 33.670 common_voice = common_voice.remove_columns(column_names=common_voice.column_names['train']) common_voice.clear() # check memory -> RAM Used (GB): 0.705 / Total (GB) 33.670 ``` I tried `gc.collect()` but did not help ### Steps to reproduce the bug 1. load dataset 2. remove all the columns 3. check memory is reduced or not [link to reproduce](https://www.kaggle.com/code/bayartsogtya/huggingface-dataset-memory-issue/notebook?scriptVersionId=110630567) ### Expected behavior Memory released when I remove the column ### Environment info - `datasets` version: 2.1.0 - Platform: Linux-5.15.65+-x86_64-with-debian-bullseye-sid - Python version: 3.7.12 - PyArrow version: 8.0.0 - Pandas version: 1.3.5
429
42
Q: Memory release when removing the column? ### Describe the bug How do I release memory when I use methods like `.remove_columns()` or `clear()` in notebooks? ```python from datasets import load_dataset common_voice = load_dataset("mozilla-foundation/common_voice_11_0", "ja", use_auth_token=True) # check memory -> RAM Used (GB): 0.704 / Total (GB) 33.670 common_voice = common_voice.remove_columns(column_names=common_voice.column_names['train']) common_voice.clear() # check memory -> RAM Used (GB): 0.705 / Total (GB) 33.670 ``` I tried `gc.collect()` but did not help ### Steps to reproduce the bug 1. load dataset 2. remove all the columns 3. check memory is reduced or not [link to reproduce](https://www.kaggle.com/code/bayartsogtya/huggingface-dataset-memory-issue/notebook?scriptVersionId=110630567) ### Expected behavior Memory released when I remove the column ### Environment info - `datasets` version: 2.1.0 - Platform: Linux-5.15.65+-x86_64-with-debian-bullseye-sid - Python version: 3.7.12 - PyArrow version: 8.0.0 - Pandas version: 1.3.5 Hi ! Datasets are memory mapped from your disk, i.e. they're not loaded in RAM. This is possible thanks to the Arrow data format. Therefore the column you remove is not in RAM, so removing it doesn't cause the RAM to decrease.
[ -1.1906449794769287, -0.9165562391281128, -0.6410274505615234, 1.5131562948226929, -0.1438470035791397, -1.1657845973968506, 0.16934902966022491, -0.9862246513366699, 1.617893934249878, -0.7596152424812317, 0.2861641049385071, -1.6524263620376587, 0.03372906148433685, -0.515241265296936, -0.7084801197052002, -0.8537551760673523, -0.4564589560031891, -0.7239900827407837, 1.0532524585723877, 2.510727882385254, 1.2972606420516968, -1.3193062543869019, 2.7568371295928955, 0.6173325181007385, -0.18361006677150726, -1.0604690313339233, 0.46058687567710876, -0.046996891498565674, -1.4088172912597656, -0.34838515520095825, -0.9674425721168518, -0.07129621505737305, -0.5509207248687744, -0.533203125, 0.025957386940717697, 0.40145617723464966, -0.2885681986808777, -0.41675660014152527, -0.5160444378852844, -0.8265751004219055, 0.5470048785209656, -0.3702318072319031, 0.9092103838920593, -0.34041571617126465, 1.7732924222946167, -0.6551114320755005, 0.568424642086029, 0.7180607914924622, 1.3159912824630737, 0.16736038029193878, -0.058406706899404526, 0.46822553873062134, 0.4084222912788391, -0.01989271491765976, 0.5928722620010376, 1.1009762287139893, 0.6199176907539368, 0.41406306624412537, 0.6536458730697632, -2.2016093730926514, 1.3110909461975098, -0.9170045256614685, 0.23879577219486237, 1.3506678342819214, -1.0321370363235474, 0.33262166380882263, -1.734039545059204, -0.08380750566720963, 0.5586209297180176, -2.2643535137176514, 0.17782659828662872, -1.3582780361175537, -0.5275799036026001, 1.0880796909332275, 0.416849285364151, -1.2800644636154175, 0.018087182193994522, -0.4642300009727478, 0.977757453918457, 0.427053838968277, 1.1484507322311401, -1.671642541885376, -0.11562472581863403, -0.27412086725234985, 0.14455457031726837, -1.2312597036361694, -1.6169743537902832, 0.5591916441917419, 0.7001534700393677, 0.5096234083175659, -0.12544770538806915, 0.9583268165588379, -1.0176079273223877, 0.7899686098098755, -0.975848913192749, -1.7665646076202393, -1.4594138860702515, -2.4513862133026123, -2.3118724822998047, 0.7661027908325195, -0.4475221037864685, -0.42990371584892273, 2.077568769454956, -1.087507963180542, -1.7984185218811035, 1.1200225353240967, 0.19206224381923676, -0.05605345964431763, 2.3115146160125732, 0.20019197463989258, -0.731103241443634, 0.4403279423713684, -0.7995123863220215, 0.7289440631866455, -0.38097965717315674, 1.332586407661438, 0.44977954030036926, -1.0692585706710815, 1.5880305767059326, -0.35606545209884644, 0.5036977529525757, -0.6082793474197388, -0.4068303406238556, -0.7064116597175598, 0.21901200711727142, 1.951271414756775, -0.30011504888534546, 1.5459572076797485, -0.28226253390312195, -1.5016183853149414, -1.561894178390503, 0.7880555987358093, 0.4840404987335205, -0.7827144265174866, 0.11929216980934143, -0.4273505210876465, 0.09480620175600052, 0.055710986256599426, 1.0954344272613525, 1.3152244091033936, 0.7121703624725342, -0.2942162752151489, -0.8593499064445496, 0.188302144408226, -0.04442491754889488, -0.6728924512863159, -1.7257287502288818, -0.329683393239975, 0.17860794067382812, 0.6366931200027466, -1.185492753982544, 1.7935446500778198, 0.8735736012458801, 1.9339046478271484, 1.0488697290420532, -0.36038538813591003, 1.4818084239959717, 0.1526831090450287, 1.8172677755355835, -0.500027060508728, 0.6684429049491882, -0.4159696400165558, -1.2106401920318604, 0.7606139183044434, -0.3537198305130005, -2.043198347091675, -0.7202264666557312, -0.8008665442466736, -0.09199743717908859, -0.743351399898529, 0.9722669124603271, -0.2418455183506012, -1.3361661434173584, 0.22218413650989532, -0.8206399083137512, 0.16426287591457367, -1.2316641807556152, 0.27577805519104004, 0.7480838298797607, -0.6327390670776367, 0.06983955949544907, -0.31694042682647705, -1.2892717123031616, -0.4446742832660675, 0.37132564187049866, 1.8232835531234741, -0.6838289499282837, 1.0311686992645264, 1.0200504064559937, -0.6518058180809021, 0.016491249203681946, 0.31462782621383667, -0.270654559135437, 0.9400550127029419, -1.0040615797042847, -0.4024370610713959, 1.198180913925171, -0.2668701112270355, -0.6349359154701233, 1.4630322456359863, 0.7437095642089844, -0.9982609748840332, -0.25208398699760437, -0.14128386974334717, -0.88701331615448, 0.09648718684911728, -1.6736254692077637, -0.0803542211651802, 0.373596727848053, -1.5645701885223389, -0.49395251274108887, -0.12721596658229828, 1.3867484331130981, -0.05911421403288841, 1.4717175960540771, -0.33234506845474243, -0.13124333322048187, -0.4425053894519806, -0.42381349205970764, 0.1433783322572708, -0.22115761041641235, -0.6031810641288757, 0.2767031490802765, -0.7598111033439636, 0.3413807451725006, 1.4040634632110596, 0.2626398503780365, 0.06579723209142685, 0.5465174913406372, 1.1267162561416626, 0.3489636182785034, -0.20675969123840332, -0.8502986431121826, -1.7023032903671265, 2.067732810974121, -1.3451387882232666, 1.9767441749572754, 0.8020491003990173, -0.09789500385522842, -1.786901593208313, -1.8957159519195557, 1.3270751237869263, 1.1113780736923218, 2.3325843811035156, 0.5182987451553345, 0.48589062690734863, -0.8470160365104675, -0.7197787165641785, 0.3516376316547394, -0.9617700576782227, -0.7805430889129639, 0.09606239199638367, 2.384345531463623, 1.756699562072754, -0.4316795766353607, -0.1942245364189148, -1.0362684726715088, 1.4206503629684448, -0.2270354926586151, 0.19226954877376556, 1.9613838195800781, -0.16899283230304718, -1.06816565990448, 1.2914952039718628, -2.2856616973876953, 0.2135654240846634, 1.9964288473129272, 0.27028194069862366, 0.05869961529970169, -1.4114676713943481, -0.7104183435440063, -0.30834344029426575, -0.3723887503147125, -1.282325029373169, 0.512910008430481, -0.23156583309173584, -0.842695951461792, -1.3854162693023682, 0.10662124305963516, -1.1152108907699585, -1.6895745992660522, 0.28044092655181885, 1.808648943901062, 2.0342628955841064, -0.7739524245262146, 1.5279408693313599, -0.3136979341506958, 0.15557299554347992, 1.2487214803695679, 1.2135628461837769, 3.1102449893951416, 2.022575616836548, -1.3054454326629639, 0.7143391966819763, -0.12289601564407349, -0.43157970905303955, 1.2588938474655151, -1.184747338294983, 1.2945212125778198, -0.20806215703487396, -1.2809172868728638, -1.1770211458206177, 0.9954858422279358, 0.4577132761478424, 0.0005947612226009369, -0.44274571537971497, 1.216485619544983, 0.1006360873579979, 1.360755205154419, 0.5782772302627563, -0.291553258895874, 0.6762638688087463, -0.43648388981819153, -0.4860984683036804, 1.558787226676941, 0.2181650847196579, -1.447475552558899, -2.280015230178833, -0.26045289635658264, -0.8540581464767456, 0.022854093462228775, -0.6798076033592224, -0.9894198775291443, 1.5477912425994873, 0.44901323318481445, -1.1799870729446411, -0.28220227360725403, -0.35136592388153076, -0.5252809524536133, 2.6919257640838623, -1.3648533821105957, -0.20346097648143768, -1.0997806787490845, -0.5980631113052368, 1.6096869707107544, -1.1894892454147339, -0.18140257894992828, -1.0355608463287354, -0.5651495456695557, -1.22852623462677, -0.5695702433586121, -0.03162587061524391, -0.8824846744537354, 0.7438040971755981, 0.09601093083620071, -1.1876940727233887, -0.2729523479938507, -0.8901875019073486, 0.8769101500511169, -0.1590944081544876, 0.13926033675670624, 1.7832828760147095, 0.30915477871894836, -0.4049169719219208, 0.7527633905410767, 1.1427992582321167, 0.6401390433311462, -0.5499410629272461, 0.2523193061351776, -0.6875611543655396, 0.30232158303260803, -1.2658663988113403, 0.24607127904891968, -2.8849146366119385, 0.6648297309875488, -0.006127581000328064, -0.03545672073960304, -0.10572222620248795, -1.3564579486846924, 1.0888187885284424, 2.4802772998809814, -1.1691408157348633, 0.5106510519981384, 0.3172891139984131, 1.1530545949935913, -1.6254507303237915, 0.31483423709869385, -0.48532402515411377, 2.1320273876190186, 0.19147445261478424, 1.2136956453323364, -0.3923759460449219, -2.2486305236816406, 0.6565267443656921, -1.2422641515731812, -1.0989598035812378, 0.7839196920394897, -0.7886038422584534, 0.10342243313789368, -1.3132920265197754, -0.2283918261528015, -0.7679418325424194, -1.2028656005859375, 0.6263173818588257, 0.08167901635169983, 0.48988959193229675, -0.5518215298652649, 0.3110501766204834, -2.2317633628845215, -1.2806448936462402, -0.18825775384902954, -1.028607964515686, 0.45531439781188965, -0.34907227754592896, 0.6607589721679688, -0.16768929362297058, 0.06757324188947678, 0.3395753800868988, 1.4138250350952148, 3.4330544471740723, 0.0951138436794281, 0.2631877660751343, -0.11956673860549927, -0.9766837954521179, 1.4690648317337036, 0.9473038911819458, -0.2121148705482483, -0.581440806388855, -1.0218713283538818, 1.2758524417877197, 1.9522411823272705, 1.0165518522262573, 0.10281424224376678, -0.8981423377990723, -0.8062565922737122, -0.012270106002688408, 0.1749868094921112, 0.5339125990867615, 0.982487678527832, 0.09716589748859406, 0.05086543783545494, 1.425504207611084, 1.2578359842300415, -0.34332358837127686, 0.37077006697654724, -0.8806791305541992, -0.4238063395023346, 0.4893135726451874, 0.33599644899368286, -0.017409883439540863, 0.3446652889251709, -1.0139306783676147, -0.1841372698545456, -0.3569457530975342, -0.8532236814498901, -0.8161226511001587, -0.42228302359580994, -0.37609294056892395, 1.68678617477417, 0.093941330909729, -0.5283835530281067, -0.040851861238479614, -0.7572773098945618, -0.11621758341789246, -1.030466914176941, 0.3166936933994293, -0.09554434567689896, -0.04143676906824112, -0.13126663863658905, 1.6854746341705322, -1.0003960132598877, -2.133720636367798, 0.2421371340751648, 0.21890586614608765, -0.3260646164417267, 0.11348053812980652, 1.664801001548767, 0.5807057619094849, 1.3817696571350098, 1.3875306844711304, 0.982966959476471, -0.6203864812850952, -1.3221392631530762, 0.6863987445831299, 0.9389637112617493, -1.4151992797851562, 0.7638012766838074, -0.042607877403497696, -0.5091033577919006, 0.6115869283676147, 1.2602274417877197, 0.5020239353179932, -1.9268383979797363, 0.9056049585342407, -0.9245524406433105, 0.8187033534049988, 0.6958886981010437, 0.7345893979072571, 0.16182543337345123, 0.795647144317627, -1.2756606340408325, -1.0796868801116943, -0.6457905173301697, -0.7092928886413574, 1.9227290153503418, -0.36371544003486633, 0.4660530686378479, -0.2387181520462036, -1.3501076698303223, -0.13902753591537476, 0.7648937702178955, 0.33069777488708496, -0.5045270919799805, 0.814983069896698, -0.6330522894859314, -1.0812673568725586, -1.3362425565719604, -0.4992383122444153, -1.007333755493164, -0.9987938404083252, 1.0312992334365845, 0.7221963405609131, 0.4021938741207123, 1.8997671604156494, 0.6270118951797485, 0.24694812297821045, -2.632366895675659, 0.8768231868743896, 0.29327306151390076, -0.004165709018707275, 0.9044409990310669, 0.26635870337486267, 1.0376255512237549, -0.1331378072500229, 0.5816254019737244, -2.38506817817688, 2.3409924507141113, -0.18770228326320648, 0.7041374444961548, 0.03230562433600426, -0.10471988469362259, 1.0840246677398682, 0.5417000651359558, 0.6064529418945312, -1.119705319404602, 0.790777325630188, -0.5918618440628052, 1.2053521871566772, 0.7695846557617188, -0.9151456356048584, -0.06545461714267731, 1.3007217645645142, 0.44334298372268677, -0.4645959734916687, -0.9555144309997559, -1.017020583152771, 0.926821768283844, 1.782528042793274, -0.017186002805829048, 0.037415068596601486, 0.8515609502792358, 0.6617200970649719, -1.3008843660354614, 0.031035173684358597, -0.7266126275062561, -0.6579059362411499, 1.6815069913864136, 2.0987043380737305, -0.11902452260255814, -0.2955327332019806, -0.7165226936340332, -1.311922550201416, 0.7815673351287842, 0.05292821675539017, 0.056493960320949554, 0.6990156173706055, -0.5977953672409058, 1.1359184980392456, 0.8261426687240601, 0.9445183277130127, 0.22986488044261932, 0.22204619646072388, 0.3165442645549774, -0.2783142626285553, -1.2225334644317627, -0.307079941034317, -0.9975572228431702, -2.5933990478515625, 0.4489830434322357, -0.24310214817523956, -1.4537519216537476, 0.06741657108068466, -1.0508676767349243, 0.8350398540496826, -0.5544192790985107, -1.1002118587493896, -1.5316569805145264, 0.15571385622024536, -0.15930314362049103, 0.9071767926216125, -1.5629982948303223, -0.12495551258325577, 1.262495756149292, 0.897803544998169, -0.6095224618911743, 0.9819949269294739, 0.2661535441875458, 0.9742226004600525, 0.8483288884162903, -0.3290167450904846, 0.5412554144859314, 0.12114681303501129, -1.362769603729248, 0.44746118783950806, 1.2318215370178223, 0.16032883524894714, 1.5185219049453735, -0.5433008074760437, 0.03372790664434433, 0.44434064626693726, -0.513549268245697, -0.4827529191970825, -0.5506635904312134, 0.6780397891998291, 0.021855279803276062, -1.0002001523971558, 0.015036321245133877, -0.11158474534749985, -0.21444782614707947, 0.15005633234977722, -1.508836030960083, -0.07851111888885498, -0.35174766182899475, -0.6927178502082825, -1.2436093091964722, -0.08586575090885162, 1.3936063051223755, -0.895050585269928, -0.14376018941402435, 0.5052136778831482, 0.30825403332710266, 0.5919122695922852, 0.6358789801597595, -0.6678576469421387, -0.2853820323944092, -0.2410062998533249, -0.34567350149154663, 0.3343564569950104, 1.3140294551849365, -0.07170457392930984, -1.0099924802780151, 0.6891104578971863, -0.3759458661079407, 0.17116039991378784, 1.991266131401062, 0.08860912919044495, -0.8527804017066956, 0.31324681639671326, -0.6996844410896301, 1.9584529399871826, 1.6696184873580933, 1.359925389289856, -0.1228584349155426, -0.9893415570259094, 0.5987259745597839, -0.3210258483886719, -0.30515697598457336, 0.8855072259902954, 0.41850996017456055, -0.26049089431762695, -1.323461651802063, 0.7175934910774231, 1.2832773923873901, -0.8756129741668701, -0.7621157765388489, 0.08786888420581818, -0.8575884103775024, 1.1473079919815063, 0.6958253383636475, 0.3648965358734131, 0.23983462154865265, 1.5904816389083862, 0.7415401339530945, -0.45295920968055725, 0.5454756021499634, 0.4957781732082367, -0.21058087050914764, -2.0787923336029053, -1.0937000513076782, 0.45517316460609436, -0.600513756275177, -1.6207091808319092, 1.3290834426879883, -1.1853606700897217, -0.9757180213928223, 0.5018383264541626, 0.07875251770019531, 1.4243812561035156, 0.23884987831115723, 1.6561269760131836, 2.0088720321655273, 0.9466245770454407, 0.3694946765899658, 1.2835935354232788, -0.10915414988994598, -0.392066091299057, 1.7139034271240234, -0.40638819336891174, 0.5314936637878418, 1.1287057399749756, -0.3873787224292755, -1.1221563816070557, -0.7748011946678162, -1.1468851566314697, -0.7061764597892761, 1.1725869178771973, 0.09005793184041977, -1.0518666505813599, 0.27265089750289917, 1.527484655380249, 0.17313197255134583, -0.23324592411518097, 0.6706356406211853, 0.31020647287368774, -0.7349193096160889, -0.0507488027215004, -0.9665823578834534, 0.527881383895874, -0.2316763997077942, -0.4170270562171936, 0.2755827009677887, 0.3504083454608917, 1.28414785861969, -0.04069948568940163, 0.10978198051452637, 1.2768908739089966, -1.3795596361160278, 1.4672088623046875, -0.6721779704093933, 0.27453187108039856, -2.334629774093628, 1.3784444332122803, -0.8010861277580261, 1.87448251247406, -2.681373119354248, 0.41250962018966675, -0.5822350978851318, -0.39926955103874207, 0.269021213054657, -0.27762702107429504, 0.14373253285884857, -0.15791110694408417, -1.170032262802124, -0.17597319185733795, -0.7916013598442078, 0.5619291663169861, 1.1385939121246338, 1.3927274942398071, -1.0855329036712646, -0.13782426714897156, -1.723291039466858, -0.13694407045841217, -0.766467809677124, 0.37045860290527344, -1.922594428062439, -0.14535363018512726, -1.9363868236541748, -2.4035890102386475, -1.2217687368392944, -0.7749255895614624, 1.1105164289474487, 0.1403750628232956, -0.8379303216934204, 1.164335012435913, -0.3775480091571808, -1.836291790008545, 1.129311442375183, -2.2521469593048096 ]
https://github.com/huggingface/datasets/issues/5226
Q: Memory release when removing the column?
Thanks for the explanation! @lhoestq I wonder since it is memory mapped, can we reduce or remove this memory map?
### Describe the bug How do I release memory when I use methods like `.remove_columns()` or `clear()` in notebooks? ```python from datasets import load_dataset common_voice = load_dataset("mozilla-foundation/common_voice_11_0", "ja", use_auth_token=True) # check memory -> RAM Used (GB): 0.704 / Total (GB) 33.670 common_voice = common_voice.remove_columns(column_names=common_voice.column_names['train']) common_voice.clear() # check memory -> RAM Used (GB): 0.705 / Total (GB) 33.670 ``` I tried `gc.collect()` but did not help ### Steps to reproduce the bug 1. load dataset 2. remove all the columns 3. check memory is reduced or not [link to reproduce](https://www.kaggle.com/code/bayartsogtya/huggingface-dataset-memory-issue/notebook?scriptVersionId=110630567) ### Expected behavior Memory released when I remove the column ### Environment info - `datasets` version: 2.1.0 - Platform: Linux-5.15.65+-x86_64-with-debian-bullseye-sid - Python version: 3.7.12 - PyArrow version: 8.0.0 - Pandas version: 1.3.5
429
20
Q: Memory release when removing the column? ### Describe the bug How do I release memory when I use methods like `.remove_columns()` or `clear()` in notebooks? ```python from datasets import load_dataset common_voice = load_dataset("mozilla-foundation/common_voice_11_0", "ja", use_auth_token=True) # check memory -> RAM Used (GB): 0.704 / Total (GB) 33.670 common_voice = common_voice.remove_columns(column_names=common_voice.column_names['train']) common_voice.clear() # check memory -> RAM Used (GB): 0.705 / Total (GB) 33.670 ``` I tried `gc.collect()` but did not help ### Steps to reproduce the bug 1. load dataset 2. remove all the columns 3. check memory is reduced or not [link to reproduce](https://www.kaggle.com/code/bayartsogtya/huggingface-dataset-memory-issue/notebook?scriptVersionId=110630567) ### Expected behavior Memory released when I remove the column ### Environment info - `datasets` version: 2.1.0 - Platform: Linux-5.15.65+-x86_64-with-debian-bullseye-sid - Python version: 3.7.12 - PyArrow version: 8.0.0 - Pandas version: 1.3.5 Thanks for the explanation! @lhoestq I wonder since it is memory mapped, can we reduce or remove this memory map?
[ -1.2016704082489014, -0.9061854481697083, -0.6098951697349548, 1.5320788621902466, -0.1000046655535698, -1.176424264907837, 0.17336294054985046, -0.9801585674285889, 1.6063413619995117, -0.7470572590827942, 0.29756492376327515, -1.6521891355514526, 0.014948606491088867, -0.5254845023155212, -0.7180193066596985, -0.8535193204879761, -0.4618561863899231, -0.7185172438621521, 1.0594494342803955, 2.520646572113037, 1.2811857461929321, -1.3179372549057007, 2.76145601272583, 0.6103125214576721, -0.19014504551887512, -1.0573300123214722, 0.4716576635837555, -0.05870232358574867, -1.4258514642715454, -0.3592739403247833, -0.9755822420120239, -0.11218611150979996, -0.5626845359802246, -0.5144487023353577, 0.029550179839134216, 0.4050057828426361, -0.26179060339927673, -0.40472739934921265, -0.5344605445861816, -0.8418465852737427, 0.554374098777771, -0.35208699107170105, 0.8881630301475525, -0.31917116045951843, 1.7513364553451538, -0.7017521262168884, 0.5997567176818848, 0.7104988694190979, 1.3113632202148438, 0.16856947541236877, -0.06027267873287201, 0.47756946086883545, 0.391573429107666, -0.03235933929681778, 0.6217262744903564, 1.0928404331207275, 0.6251828670501709, 0.406649649143219, 0.6572465896606445, -2.2134084701538086, 1.2765096426010132, -0.9408690333366394, 0.24816608428955078, 1.3677000999450684, -1.0119630098342896, 0.305843710899353, -1.753156304359436, -0.07171846181154251, 0.5514612793922424, -2.2362987995147705, 0.16139882802963257, -1.3418493270874023, -0.5212434530258179, 1.0603307485580444, 0.4260215163230896, -1.2974616289138794, -0.019403783604502678, -0.4528448283672333, 0.9841705560684204, 0.40821510553359985, 1.1317847967147827, -1.6863670349121094, -0.1271078884601593, -0.2691936492919922, 0.14496475458145142, -1.2267011404037476, -1.606316328048706, 0.5445607304573059, 0.6837031245231628, 0.4915419816970825, -0.1136908307671547, 0.9575116038322449, -0.9880788326263428, 0.8032746315002441, -1.0016146898269653, -1.7517231702804565, -1.4812164306640625, -2.448878765106201, -2.2933969497680664, 0.7697044610977173, -0.4547615945339203, -0.44937077164649963, 2.054980516433716, -1.1031283140182495, -1.7872484922409058, 1.1291009187698364, 0.1778605580329895, -0.07047120481729507, 2.2922403812408447, 0.20968660712242126, -0.7325994372367859, 0.4804982841014862, -0.8218117356300354, 0.7079293131828308, -0.37662190198898315, 1.3160375356674194, 0.4363934099674225, -1.08165442943573, 1.5614930391311646, -0.3404068350791931, 0.5188362002372742, -0.6098049283027649, -0.4192309081554413, -0.7093275189399719, 0.22830834984779358, 1.967496633529663, -0.2611122727394104, 1.5403658151626587, -0.25316953659057617, -1.47329580783844, -1.5226842164993286, 0.7909226417541504, 0.4765876531600952, -0.7829462289810181, 0.15255051851272583, -0.4332936108112335, 0.08887152373790741, 0.0606347918510437, 1.0863652229309082, 1.2921322584152222, 0.7035062909126282, -0.2927933931350708, -0.8271905183792114, 0.1987299919128418, -0.03552989661693573, -0.6931484341621399, -1.7197433710098267, -0.3237450420856476, 0.16999804973602295, 0.6415818333625793, -1.2140748500823975, 1.825361967086792, 0.8549591302871704, 1.9272327423095703, 1.0514991283416748, -0.361728698015213, 1.4872419834136963, 0.12481427937746048, 1.814199447631836, -0.49354204535484314, 0.6522138714790344, -0.4252033531665802, -1.2071658372879028, 0.7765055298805237, -0.36121904850006104, -2.0584523677825928, -0.7275835275650024, -0.8060808777809143, -0.07514139264822006, -0.7556679248809814, 0.9567931890487671, -0.2643493115901947, -1.3507221937179565, 0.2098427414894104, -0.8264841437339783, 0.19096791744232178, -1.243432641029358, 0.28028205037117004, 0.7515724301338196, -0.627539873123169, 0.07749263942241669, -0.2930261194705963, -1.2957594394683838, -0.4524010121822357, 0.3598528504371643, 1.8176558017730713, -0.6893255114555359, 1.0322877168655396, 1.024726152420044, -0.6385866403579712, 0.006113089621067047, 0.34526845812797546, -0.2787950038909912, 0.9581301212310791, -0.9704386591911316, -0.4196130335330963, 1.2220630645751953, -0.26360854506492615, -0.6347771286964417, 1.4913854598999023, 0.7762516736984253, -1.0053236484527588, -0.2568601965904236, -0.15246820449829102, -0.9002712368965149, 0.10096219182014465, -1.6976555585861206, -0.0581432580947876, 0.38329407572746277, -1.5783839225769043, -0.48179155588150024, -0.07882452011108398, 1.3887935876846313, -0.054499126970767975, 1.4700249433517456, -0.34691113233566284, -0.10932706296443939, -0.45084619522094727, -0.4260048270225525, 0.13823860883712769, -0.24301224946975708, -0.6108149886131287, 0.2903498709201813, -0.7196145057678223, 0.35653695464134216, 1.4079546928405762, 0.251939982175827, 0.07187848538160324, 0.5491937398910522, 1.1414138078689575, 0.3136000633239746, -0.21219485998153687, -0.8509918451309204, -1.7023404836654663, 2.0750105381011963, -1.3464163541793823, 1.966901421546936, 0.8019315600395203, -0.116044782102108, -1.7739745378494263, -1.8772187232971191, 1.3243992328643799, 1.142175555229187, 2.3228631019592285, 0.5133677124977112, 0.5076571702957153, -0.8646341562271118, -0.714482843875885, 0.32370027899742126, -0.9630832672119141, -0.7790815830230713, 0.10037367045879364, 2.405726909637451, 1.7583431005477905, -0.40678927302360535, -0.1851782202720642, -1.0472469329833984, 1.412564754486084, -0.23182198405265808, 0.19214579463005066, 1.961120367050171, -0.1748397946357727, -1.0761055946350098, 1.3055347204208374, -2.2843873500823975, 0.19434863328933716, 1.9992783069610596, 0.29238417744636536, 0.06289936602115631, -1.421101689338684, -0.6998748183250427, -0.3457796275615692, -0.3403886556625366, -1.2662994861602783, 0.5294401049613953, -0.21373319625854492, -0.8213127255439758, -1.3470492362976074, 0.09166093170642853, -1.1196590662002563, -1.70901358127594, 0.28359314799308777, 1.7889572381973267, 2.029517412185669, -0.7694298028945923, 1.515648365020752, -0.3274407982826233, 0.185111403465271, 1.2645248174667358, 1.2231495380401611, 3.1333107948303223, 2.026339054107666, -1.306408405303955, 0.7255745530128479, -0.15734174847602844, -0.44250136613845825, 1.2684603929519653, -1.2138391733169556, 1.278181791305542, -0.18369406461715698, -1.2642971277236938, -1.1788055896759033, 1.005803108215332, 0.4393961429595947, 0.00971413217484951, -0.4768041968345642, 1.2032443284988403, 0.10997235029935837, 1.3585872650146484, 0.5555277466773987, -0.27049440145492554, 0.6398365497589111, -0.4326325058937073, -0.4865475296974182, 1.568360686302185, 0.21944263577461243, -1.4632720947265625, -2.311197280883789, -0.23034048080444336, -0.8702479600906372, 0.01607782021164894, -0.7056721448898315, -0.9991074204444885, 1.5663608312606812, 0.4542243778705597, -1.203128457069397, -0.2621695101261139, -0.3332933187484741, -0.5204600095748901, 2.7251007556915283, -1.3859522342681885, -0.20944002270698547, -1.098645567893982, -0.6124151945114136, 1.6318522691726685, -1.199664831161499, -0.19990381598472595, -1.0431814193725586, -0.5769755244255066, -1.186583161354065, -0.5467104315757751, -0.04593523219227791, -0.9137247800827026, 0.7498127818107605, 0.07856284826993942, -1.1963385343551636, -0.28389009833335876, -0.8757936358451843, 0.8976988196372986, -0.16087523102760315, 0.14396357536315918, 1.7663723230361938, 0.34045377373695374, -0.38728925585746765, 0.7558731436729431, 1.1857441663742065, 0.6537970304489136, -0.5598471760749817, 0.210363507270813, -0.6805728673934937, 0.31727343797683716, -1.256596326828003, 0.25864580273628235, -2.879615068435669, 0.645659327507019, -0.011420205235481262, -0.037732966244220734, -0.13232630491256714, -1.3485171794891357, 1.0938189029693604, 2.4633054733276367, -1.153818964958191, 0.5091643333435059, 0.33002325892448425, 1.1417292356491089, -1.6190776824951172, 0.2940714955329895, -0.5088504552841187, 2.139784336090088, 0.18293267488479614, 1.1802839040756226, -0.40612736344337463, -2.2517330646514893, 0.6419931650161743, -1.276749849319458, -1.0923441648483276, 0.7965691089630127, -0.7785159945487976, 0.11342433094978333, -1.2934268712997437, -0.22562739253044128, -0.7657385468482971, -1.1852368116378784, 0.6291385293006897, 0.0845235213637352, 0.4857045114040375, -0.5347198247909546, 0.30911946296691895, -2.2455568313598633, -1.3117064237594604, -0.1966996192932129, -1.0052770376205444, 0.43978971242904663, -0.37248122692108154, 0.6591465473175049, -0.146986186504364, 0.06316719949245453, 0.34559309482574463, 1.4442682266235352, 3.4308860301971436, 0.09927927702665329, 0.29575350880622864, -0.16384956240653992, -0.9683164358139038, 1.4802541732788086, 0.926137387752533, -0.22838786244392395, -0.5998241305351257, -0.9859882593154907, 1.2962980270385742, 1.9221913814544678, 1.0374696254730225, 0.0842188149690628, -0.8911473751068115, -0.8103635311126709, -0.02979274094104767, 0.18186691403388977, 0.5114964842796326, 0.9645032286643982, 0.0850442424416542, 0.05362214893102646, 1.4096064567565918, 1.23845374584198, -0.3432857096195221, 0.37344151735305786, -0.8579645752906799, -0.40781450271606445, 0.4991105794906616, 0.3452821671962738, -0.017929088324308395, 0.3580842912197113, -0.9701274633407593, -0.20734825730323792, -0.33651235699653625, -0.8420778512954712, -0.8300912976264954, -0.43957945704460144, -0.3756539821624756, 1.6876885890960693, 0.07630909979343414, -0.5332160592079163, -0.03728393092751503, -0.7673641443252563, -0.13477760553359985, -1.0534220933914185, 0.2974003255367279, -0.101918525993824, -0.032155510038137436, -0.13902926445007324, 1.6919299364089966, -1.0123412609100342, -2.130556344985962, 0.260621577501297, 0.24338790774345398, -0.3174050748348236, 0.10871889442205429, 1.6689695119857788, 0.5668708086013794, 1.3572057485580444, 1.3909763097763062, 0.9822277426719666, -0.6145522594451904, -1.311950922012329, 0.6941169500350952, 0.9664232134819031, -1.4281471967697144, 0.7835211753845215, -0.05072760954499245, -0.48397839069366455, 0.5907480716705322, 1.2545708417892456, 0.5043853521347046, -1.891230583190918, 0.894324779510498, -0.9486595392227173, 0.8359670042991638, 0.7063615322113037, 0.7488151788711548, 0.17467400431632996, 0.7922519445419312, -1.2744778394699097, -1.0784908533096313, -0.6673712134361267, -0.7007850408554077, 1.9287545680999756, -0.36257192492485046, 0.44887667894363403, -0.22795453667640686, -1.3383487462997437, -0.1303737461566925, 0.781595766544342, 0.3105623126029968, -0.5017701983451843, 0.8007190227508545, -0.6275399327278137, -1.0770673751831055, -1.3010319471359253, -0.4905989468097687, -0.9870043992996216, -1.0115585327148438, 1.039290189743042, 0.7133903503417969, 0.4247966706752777, 1.8931258916854858, 0.6396306157112122, 0.26918238401412964, -2.6220295429229736, 0.8778788447380066, 0.2656393349170685, 0.002571137621998787, 0.8812963366508484, 0.2756229639053345, 1.0382496118545532, -0.12620526552200317, 0.5839117765426636, -2.3840696811676025, 2.3440628051757812, -0.1851651966571808, 0.6797683238983154, 0.01974376104772091, -0.06846565753221512, 1.0924108028411865, 0.5426223874092102, 0.5731412172317505, -1.1088753938674927, 0.7716897130012512, -0.5902189612388611, 1.2068170309066772, 0.7489858269691467, -0.9337387681007385, -0.04183986037969589, 1.311599850654602, 0.43217334151268005, -0.4685044288635254, -0.983314573764801, -1.0080231428146362, 0.9745765924453735, 1.7379388809204102, -0.008508173748850822, 0.01940241828560829, 0.8447567224502563, 0.6794533133506775, -1.270556926727295, 0.035534098744392395, -0.7131299376487732, -0.6708892583847046, 1.700126051902771, 2.132189989089966, -0.13101309537887573, -0.25994908809661865, -0.7202719449996948, -1.3070173263549805, 0.7735398411750793, 0.038979895412921906, 0.044883474707603455, 0.6623675227165222, -0.5903528928756714, 1.122088074684143, 0.8696750402450562, 0.950444221496582, 0.2642070949077606, 0.20331448316574097, 0.30242466926574707, -0.2394040822982788, -1.2202880382537842, -0.31874677538871765, -1.0299458503723145, -2.6350417137145996, 0.4231823682785034, -0.2535945177078247, -1.4191776514053345, 0.08604064583778381, -1.0570907592773438, 0.8270758390426636, -0.5749343633651733, -1.093910813331604, -1.5186043977737427, 0.1345457136631012, -0.1454308032989502, 0.8846272826194763, -1.5552445650100708, -0.12212782353162766, 1.2272168397903442, 0.868097186088562, -0.5906595587730408, 0.954681396484375, 0.2691180408000946, 0.9611616730690002, 0.870018720626831, -0.32851937413215637, 0.5809618830680847, 0.13951647281646729, -1.3653382062911987, 0.46297702193260193, 1.2541346549987793, 0.1707736849784851, 1.5371829271316528, -0.5544888973236084, 0.030793018639087677, 0.42312121391296387, -0.4997580349445343, -0.4821540415287018, -0.6145391464233398, 0.6719890236854553, 0.05547438561916351, -1.0277903079986572, 0.007083415985107422, -0.11035924404859543, -0.20663240551948547, 0.1612703800201416, -1.5261300802230835, -0.05275269225239754, -0.3438830077648163, -0.6790590882301331, -1.2663055658340454, -0.11157093942165375, 1.408124566078186, -0.9328199625015259, -0.11788437515497208, 0.4950050711631775, 0.3072132170200348, 0.596234917640686, 0.6572580337524414, -0.6550362706184387, -0.28532278537750244, -0.2401392161846161, -0.3446196913719177, 0.3517651855945587, 1.3035616874694824, -0.05640412122011185, -0.9873505234718323, 0.6860230565071106, -0.40115785598754883, 0.1910119354724884, 1.997405767440796, 0.10003292560577393, -0.8500232696533203, 0.31194019317626953, -0.6941380500793457, 1.9556859731674194, 1.6520700454711914, 1.323070764541626, -0.12165533751249313, -0.9855837821960449, 0.6211610436439514, -0.30914297699928284, -0.3028413653373718, 0.8620660305023193, 0.416612446308136, -0.29751095175743103, -1.3347994089126587, 0.7235623002052307, 1.293073058128357, -0.8386632204055786, -0.767275869846344, 0.08169537782669067, -0.8549961447715759, 1.1456646919250488, 0.6962057948112488, 0.35132792592048645, 0.24547389149665833, 1.5995173454284668, 0.7508317828178406, -0.4758516550064087, 0.524961531162262, 0.5127831101417542, -0.2018280327320099, -2.0717759132385254, -1.09516441822052, 0.48599281907081604, -0.5893666744232178, -1.6052242517471313, 1.3157209157943726, -1.182126522064209, -0.962720513343811, 0.539029598236084, 0.0775933787226677, 1.437094807624817, 0.23597285151481628, 1.6392767429351807, 1.9992420673370361, 0.937691867351532, 0.3821880519390106, 1.2687537670135498, -0.12049279361963272, -0.3720957636833191, 1.7141014337539673, -0.4046703577041626, 0.5358033180236816, 1.1237684488296509, -0.39714765548706055, -1.1355007886886597, -0.7765712141990662, -1.1648283004760742, -0.7327136993408203, 1.1891332864761353, 0.09645997732877731, -1.0690068006515503, 0.26697561144828796, 1.5318750143051147, 0.163763165473938, -0.19363415241241455, 0.6508752107620239, 0.2936398684978485, -0.7483564615249634, -0.04910635948181152, -0.9841159582138062, 0.5292463302612305, -0.21465229988098145, -0.41108039021492004, 0.2668597996234894, 0.36259955167770386, 1.250051736831665, -0.02286437526345253, 0.1065804734826088, 1.257476806640625, -1.394213318824768, 1.4464445114135742, -0.6981686949729919, 0.28918522596359253, -2.3363757133483887, 1.3955912590026855, -0.8000816702842712, 1.8657379150390625, -2.687812328338623, 0.40561190247535706, -0.5812212228775024, -0.427985817193985, 0.2582186460494995, -0.3052223026752472, 0.1508740782737732, -0.1487618386745453, -1.1759229898452759, -0.15808188915252686, -0.7999945878982544, 0.572323203086853, 1.1359968185424805, 1.4105830192565918, -1.0732057094573975, -0.1600542664527893, -1.6945736408233643, -0.12456955015659332, -0.7431793212890625, 0.3392004072666168, -1.914695382118225, -0.10274840146303177, -1.9402176141738892, -2.384267807006836, -1.227533221244812, -0.7626103758811951, 1.1113163232803345, 0.15971705317497253, -0.8351005911827087, 1.1491076946258545, -0.41790297627449036, -1.8191032409667969, 1.1250981092453003, -2.272716522216797 ]
https://github.com/huggingface/datasets/issues/5225
Add video feature
@NielsRogge @rwightman may have additional requirements regarding this feature. When adding a new (decodable) type, the hardest part is choosing the right decoding library. What I mean by "right" here is that it has all the features we need and is easy to install (with GPU support?). Some candidates/options: * [`decord`](https://github.com/dmlc/decord): no longer [maintained](https://github.com/dmlc/decord/issues/214), not trivial to install with GPU support * [`pyAV`](https://github.com/PyAV-Org/PyAV): used for CPU decoding in `torchvision`, GPU decoding not supported if I'm not mistaken, otherwise the best candidate probably * [`video_reader`](https://github.com/pytorch/vision/blob/de350bc01ad2193ea2888f0ce8a6a346d3cba5a9/torchvision/csrc/io/video_reader/video_reader.cpp): used for GPU decoding in `torchvision`, depends on `torch' * OpenCV: uses `ffmpeg` for video decoding under the hood * ... And the last resort is building our own library, which is the most flexible solution but also requires the most work. PS: I'm adding a link to an article that compares various video decoding libraries: https://towardsdatascience.com/lightning-fast-video-reading-in-python-c1438771c4e6
### Feature request Add a `Video` feature to the library so folks can include videos in their datasets. ### Motivation Being able to load Video data would be quite helpful. However, there are some challenges when it comes to videos: 1. Videos, unlike images, can end up being extremely large files 2. Often times when training video models, you need to do some very specific sampling. Videos might end up needing to be broken down into X number of clips used for training/inference 3. Videos have an additional audio stream, which must be accounted for 4. The feature needs to be able to encode/decode videos (with right video settings) from bytes. ### Your contribution I did work on this a while back in [this (now closed) PR](https://github.com/huggingface/datasets/pull/4532). It used a library I made called [encoded_video](https://github.com/nateraw/encoded-video), which is basically the utils from [pytorchvideo](https://github.com/facebookresearch/pytorchvideo), but without the `torch` dep. It included the ability to read/write from bytes, as we need to do here. We don't want to be using a sketchy library that I made as a dependency in this repo, though. Would love to use this issue as a place to: - brainstorm ideas on how to do this right - list ways/examples to work around it for now CC @sayakpaul @mariosasko @fcakyon
430
141
Add video feature ### Feature request Add a `Video` feature to the library so folks can include videos in their datasets. ### Motivation Being able to load Video data would be quite helpful. However, there are some challenges when it comes to videos: 1. Videos, unlike images, can end up being extremely large files 2. Often times when training video models, you need to do some very specific sampling. Videos might end up needing to be broken down into X number of clips used for training/inference 3. Videos have an additional audio stream, which must be accounted for 4. The feature needs to be able to encode/decode videos (with right video settings) from bytes. ### Your contribution I did work on this a while back in [this (now closed) PR](https://github.com/huggingface/datasets/pull/4532). It used a library I made called [encoded_video](https://github.com/nateraw/encoded-video), which is basically the utils from [pytorchvideo](https://github.com/facebookresearch/pytorchvideo), but without the `torch` dep. It included the ability to read/write from bytes, as we need to do here. We don't want to be using a sketchy library that I made as a dependency in this repo, though. Would love to use this issue as a place to: - brainstorm ideas on how to do this right - list ways/examples to work around it for now CC @sayakpaul @mariosasko @fcakyon @NielsRogge @rwightman may have additional requirements regarding this feature. When adding a new (decodable) type, the hardest part is choosing the right decoding library. What I mean by "right" here is that it has all the features we need and is easy to install (with GPU support?). Some candidates/options: * [`decord`](https://github.com/dmlc/decord): no longer [maintained](https://github.com/dmlc/decord/issues/214), not trivial to install with GPU support * [`pyAV`](https://github.com/PyAV-Org/PyAV): used for CPU decoding in `torchvision`, GPU decoding not supported if I'm not mistaken, otherwise the best candidate probably * [`video_reader`](https://github.com/pytorch/vision/blob/de350bc01ad2193ea2888f0ce8a6a346d3cba5a9/torchvision/csrc/io/video_reader/video_reader.cpp): used for GPU decoding in `torchvision`, depends on `torch' * OpenCV: uses `ffmpeg` for video decoding under the hood * ... And the last resort is building our own library, which is the most flexible solution but also requires the most work. PS: I'm adding a link to an article that compares various video decoding libraries: https://towardsdatascience.com/lightning-fast-video-reading-in-python-c1438771c4e6
[ -1.253359079360962, -0.9200264811515808, -0.8337728977203369, 1.4843002557754517, -0.1328882873058319, -1.2242681980133057, 0.13065771758556366, -1.0813215970993042, 1.5977531671524048, -0.7313802242279053, 0.36990153789520264, -1.6389939785003662, 0.05539274588227272, -0.5776135325431824, -0.8312882781028748, -0.7912849187850952, -0.3855263292789459, -0.7610602974891663, 0.9756811261177063, 2.5249733924865723, 1.258260726928711, -1.4396508932113647, 2.699986219406128, 0.7717544436454773, -0.21377232670783997, -1.0487338304519653, 0.48648738861083984, 0.04275744408369064, -1.259684443473816, -0.5103079080581665, -0.9378982186317444, -0.05620679259300232, -0.5522493124008179, -0.49104106426239014, 0.029893983155488968, 0.4104456603527069, -0.21976043283939362, -0.32344692945480347, -0.6322633624076843, -0.6973769664764404, 0.4933634400367737, -0.3683636486530304, 0.9686163663864136, -0.261688232421875, 1.739700436592102, -0.5942533612251282, 0.42771977186203003, 0.6782621741294861, 1.430373191833496, 0.22430060803890228, -0.03856021910905838, 0.27409642934799194, 0.44256457686424255, -0.06295183300971985, 0.4950394630432129, 1.2346153259277344, 0.7197030782699585, 0.5205646753311157, 0.7394976019859314, -2.2104544639587402, 1.2751127481460571, -1.01112699508667, 0.3245668411254883, 1.3028810024261475, -0.918954610824585, 0.3633230924606323, -1.8162254095077515, -0.051521629095077515, 0.5645243525505066, -2.282883882522583, 0.1951422095298767, -1.2799304723739624, -0.4963032007217407, 0.9688690900802612, 0.2706807255744934, -1.3235834836959839, 0.2274196892976761, -0.4496691823005676, 0.9788318872451782, 0.4408280849456787, 1.218367576599121, -1.6420434713363647, 0.02267635613679886, -0.20966748893260956, 0.13908354938030243, -1.1724344491958618, -1.5290634632110596, 0.5248053669929504, 0.5988189578056335, 0.545525312423706, -0.10529981553554535, 0.9609766006469727, -1.0100678205490112, 0.858278214931488, -0.9453018307685852, -1.632085919380188, -1.407586693763733, -2.2508273124694824, -2.279686689376831, 0.7834622859954834, -0.5083595514297485, -0.46850109100341797, 2.0276877880096436, -1.0473917722702026, -1.8191792964935303, 1.1013544797897339, 0.32962721586227417, 0.08370578289031982, 2.374985694885254, 0.14833174645900726, -0.7292019128799438, 0.5114031434059143, -0.6978709697723389, 0.8527531623840332, -0.500135600566864, 1.3619478940963745, 0.4196534752845764, -0.9573501944541931, 1.6571452617645264, -0.42259591817855835, 0.5446637272834778, -0.7378532290458679, -0.4621918797492981, -0.749762773513794, 0.387380450963974, 1.8944065570831299, -0.35389938950538635, 1.566130518913269, -0.36883416771888733, -1.5830121040344238, -1.5656694173812866, 0.8518162965774536, 0.5219088792800903, -0.7948659062385559, 0.0841790959239006, -0.428801029920578, 0.13384677469730377, -0.03868529945611954, 1.088382363319397, 1.282137155532837, 0.6979609727859497, -0.31681424379348755, -0.9348504543304443, 0.20950458943843842, -0.08688816428184509, -0.7037885189056396, -1.8157953023910522, -0.36042076349258423, 0.2270577847957611, 0.6752643585205078, -1.2513235807418823, 1.7415889501571655, 0.8749556541442871, 1.960863709449768, 0.9909651875495911, -0.4061529040336609, 1.5280787944793701, 0.025271721184253693, 1.8565605878829956, -0.5227667689323425, 0.6353440284729004, -0.3980371952056885, -1.1545127630233765, 0.8408246636390686, -0.3830234110355377, -2.0141985416412354, -0.6809787154197693, -0.7890049815177917, -0.19847045838832855, -0.7556538581848145, 0.9068412780761719, -0.23380595445632935, -1.3215839862823486, 0.23441077768802643, -0.7022773027420044, 0.15782223641872406, -1.2420157194137573, 0.2785528302192688, 0.774867594242096, -0.6741450428962708, 0.026062048971652985, -0.29810428619384766, -1.3243082761764526, -0.49476876854896545, 0.29158902168273926, 1.8998134136199951, -0.7329391241073608, 0.900087296962738, 0.9994422197341919, -0.6744569540023804, 0.04611991345882416, 0.3870946168899536, -0.3787538409233093, 0.8409369587898254, -1.1000003814697266, -0.44279390573501587, 1.1687101125717163, -0.14486591517925262, -0.5566549897193909, 1.4005123376846313, 0.7991079092025757, -0.9695553779602051, -0.252672016620636, -0.11577113717794418, -0.8205004930496216, 0.039889637380838394, -1.5955883264541626, -0.16596874594688416, 0.3286382853984833, -1.5204757452011108, -0.4774684011936188, -0.24147719144821167, 1.2325739860534668, -0.19791825115680695, 1.4552217721939087, -0.31568434834480286, -0.192545086145401, -0.3473984897136688, -0.41322654485702515, 0.08855442702770233, -0.23799310624599457, -0.6281200647354126, 0.2776809334754944, -0.8103401064872742, 0.37989529967308044, 1.4494506120681763, 0.3613342344760895, 0.011847571469843388, 0.4805307984352112, 1.0714246034622192, 0.4279899597167969, -0.02787914127111435, -0.8631141781806946, -1.5294666290283203, 2.028510093688965, -1.476872444152832, 1.9762743711471558, 0.8674247860908508, -0.014922479167580605, -1.7967860698699951, -1.8572556972503662, 1.3394253253936768, 1.1599769592285156, 2.4327616691589355, 0.5760669112205505, 0.3619641661643982, -0.7622590661048889, -0.5962458848953247, 0.35588130354881287, -1.0654217004776, -0.828393280506134, 0.0670139342546463, 2.4235663414001465, 1.8206326961517334, -0.5229576230049133, -0.2667413651943207, -0.9962818622589111, 1.3687442541122437, -0.20797723531723022, 0.18629910051822662, 2.0131659507751465, -0.19654417037963867, -1.0345747470855713, 1.3128565549850464, -2.385701894760132, 0.17880167067050934, 2.0098154544830322, 0.3001960515975952, 0.08742983639240265, -1.4122956991195679, -0.6071224808692932, -0.26256969571113586, -0.4245366156101227, -1.2126688957214355, 0.6000280976295471, -0.23740163445472717, -0.8200218677520752, -1.4645006656646729, 0.08745911717414856, -1.1739777326583862, -1.6647053956985474, 0.32017287611961365, 1.841294288635254, 2.029618978500366, -0.7810108065605164, 1.5159783363342285, -0.26014578342437744, 0.05586368218064308, 1.2896859645843506, 1.2397682666778564, 3.167464256286621, 1.9085053205490112, -1.2734735012054443, 0.6563531160354614, -0.2222900539636612, -0.5090364217758179, 1.1458152532577515, -1.1370279788970947, 1.1564695835113525, -0.18668979406356812, -1.2326164245605469, -1.1924474239349365, 0.9892786741256714, 0.4500897526741028, 0.10440109670162201, -0.5541774034500122, 1.1404420137405396, 0.1495199203491211, 1.2648036479949951, 0.5906327962875366, -0.34000363945961, 0.6211993098258972, -0.3796674609184265, -0.4688712954521179, 1.5497199296951294, 0.14213794469833374, -1.487105369567871, -2.315114974975586, -0.12688249349594116, -0.8591592907905579, -0.03715347871184349, -0.6346740126609802, -1.0270429849624634, 1.592739224433899, 0.45319557189941406, -1.3140109777450562, -0.2907640337944031, -0.32166051864624023, -0.6110840439796448, 2.6185648441314697, -1.48318350315094, -0.30766063928604126, -1.0294157266616821, -0.5303633213043213, 1.6378974914550781, -1.1641969680786133, -0.2063785046339035, -1.0059176683425903, -0.5914393663406372, -1.2965435981750488, -0.5757603049278259, 0.023786790668964386, -0.8260209560394287, 0.6908434629440308, 0.12283787131309509, -1.1663721799850464, -0.32881873846054077, -0.8353998064994812, 0.846565842628479, -0.09327950328588486, 0.24561025202274323, 1.9702562093734741, 0.41215112805366516, -0.4124588966369629, 0.7150892019271851, 1.223494529724121, 0.5700441598892212, -0.616310179233551, 0.21232612431049347, -0.6703749299049377, 0.36748427152633667, -1.4288195371627808, 0.29459235072135925, -2.815178871154785, 0.714191198348999, -0.03986882045865059, -0.1526959240436554, 0.020764891058206558, -1.3006826639175415, 1.158067226409912, 2.6619529724121094, -1.1535273790359497, 0.4267621338367462, 0.3497982919216156, 1.2026139497756958, -1.5693649053573608, 0.31982365250587463, -0.4009934961795807, 2.1133835315704346, 0.18766441941261292, 1.1805428266525269, -0.501861572265625, -2.2678470611572266, 0.5947873592376709, -1.2239211797714233, -1.1356390714645386, 0.8105999231338501, -0.8254286646842957, 0.044866349548101425, -1.4920679330825806, -0.13868939876556396, -0.8964841365814209, -1.1986584663391113, 0.7463864088058472, 0.09273166209459305, 0.38380342721939087, -0.6501033306121826, 0.31515422463417053, -2.140244483947754, -1.3547619581222534, -0.19616830348968506, -0.9508426785469055, 0.4584077000617981, -0.33768677711486816, 0.6894139051437378, -0.14484597742557526, -0.000054758042097091675, 0.30322790145874023, 1.3984209299087524, 3.366600275039673, 0.2226618230342865, 0.4217526316642761, -0.2276143580675125, -0.9309585094451904, 1.4178062677383423, 0.9408822655677795, -0.091671884059906, -0.6029142141342163, -0.9398494362831116, 1.271741509437561, 1.95290207862854, 1.0354998111724854, 0.11889968812465668, -0.867470920085907, -0.761498749256134, -0.039217714220285416, 0.17631009221076965, 0.42743128538131714, 1.0624489784240723, -0.0166510958224535, 0.060223180800676346, 1.398317813873291, 1.2461822032928467, -0.404715895652771, 0.3920142352581024, -0.8373412489891052, -0.3889022171497345, 0.4166584312915802, 0.3670693039894104, 0.025272127240896225, 0.41433411836624146, -0.990293562412262, -0.29149505496025085, -0.3776116669178009, -0.967187762260437, -0.7595176100730896, -0.40819162130355835, -0.2937440574169159, 1.6395331621170044, 0.14020097255706787, -0.4604355990886688, 0.035632308572530746, -0.8356764912605286, -0.08086461573839188, -1.0377980470657349, 0.21927855908870697, -0.09284382313489914, -0.09318914264440536, -0.03865291178226471, 1.7581884860992432, -0.9305952787399292, -2.098184108734131, 0.30137506127357483, 0.2507176101207733, -0.39686837792396545, 0.19058386981487274, 1.6530587673187256, 0.5601423978805542, 1.4041084051132202, 1.3035715818405151, 0.9907494783401489, -0.64095538854599, -1.2403303384780884, 0.7483817934989929, 0.966556191444397, -1.4062278270721436, 0.833250880241394, -0.011938581243157387, -0.4741482436656952, 0.6560243964195251, 1.2524937391281128, 0.3651485741138458, -2.0046262741088867, 0.7786942720413208, -0.8400371074676514, 0.7473872900009155, 0.6376226544380188, 0.6784269213676453, 0.27130427956581116, 0.7741146087646484, -1.2288459539413452, -1.152882695198059, -0.7838050127029419, -0.6471200585365295, 1.9940733909606934, -0.21197651326656342, 0.626244306564331, -0.1374819129705429, -1.3652501106262207, -0.15393993258476257, 0.7210749387741089, 0.2819173336029053, -0.510341227054596, 0.8776209950447083, -0.6526001691818237, -1.0745490789413452, -1.3567582368850708, -0.4778936505317688, -0.9276750087738037, -0.902594268321991, 1.0606003999710083, 0.8576401472091675, 0.29667267203330994, 1.9471544027328491, 0.5693152546882629, 0.22208929061889648, -2.6795761585235596, 0.8959031105041504, 0.36656856536865234, -0.07798294723033905, 0.9257846474647522, 0.31407108902931213, 1.0470768213272095, -0.0327489972114563, 0.5444074869155884, -2.432494878768921, 2.3163366317749023, -0.18380342423915863, 0.7298054695129395, -0.013191001489758492, -0.20728974044322968, 1.1430686712265015, 0.5859220623970032, 0.5787740349769592, -1.1138253211975098, 0.6143103837966919, -0.574399471282959, 1.2052572965621948, 0.8609042167663574, -0.8299528360366821, 0.018288668245077133, 1.3512096405029297, 0.45801234245300293, -0.46886003017425537, -0.9190658330917358, -0.8449432253837585, 0.9940645694732666, 1.7947157621383667, 0.029562462121248245, 0.02043760195374489, 0.8535358309745789, 0.6767767071723938, -1.317060947418213, 0.02981352061033249, -0.7842130064964294, -0.7985635995864868, 1.654632806777954, 1.9933013916015625, -0.08861237019300461, -0.25528499484062195, -0.7211207151412964, -1.3076962232589722, 0.7403282523155212, -0.019083241000771523, 0.1790236234664917, 0.7147154211997986, -0.6760490536689758, 1.1711328029632568, 0.8017526268959045, 0.9303991794586182, 0.07790233194828033, 0.29633423686027527, 0.34913504123687744, -0.4178994596004486, -1.119940996170044, -0.29668354988098145, -1.1996618509292603, -2.4821221828460693, 0.4653334319591522, -0.19821716845035553, -1.427965760231018, 0.026670925319194794, -1.045807957649231, 0.8537153601646423, -0.6089186668395996, -1.0923569202423096, -1.5384594202041626, 0.2761857807636261, -0.17247334122657776, 0.9299225211143494, -1.5888639688491821, -0.09562947601079941, 1.140259861946106, 0.9004665613174438, -0.5675048232078552, 0.9578591585159302, 0.24087001383304596, 1.0249489545822144, 0.8653209209442139, -0.38846513628959656, 0.43347588181495667, 0.08333026617765427, -1.3155394792556763, 0.3884187638759613, 1.1584665775299072, 0.20475296676158905, 1.3945730924606323, -0.5450757145881653, 0.07636070996522903, 0.43494412302970886, -0.5905601978302002, -0.4583577811717987, -0.5133575201034546, 0.7195712327957153, 0.0679260641336441, -0.981688916683197, -0.024954937398433685, -0.13627755641937256, -0.26314306259155273, 0.160252183675766, -1.523729920387268, -0.1591695100069046, -0.34703153371810913, -0.5452406406402588, -1.2714965343475342, 0.0011273808777332306, 1.3470426797866821, -0.8537742495536804, -0.17241044342517853, 0.47775328159332275, 0.3479043245315552, 0.5213426947593689, 0.5995737910270691, -0.639062762260437, -0.42308419942855835, -0.17610007524490356, -0.38723239302635193, 0.29278475046157837, 1.299729585647583, -0.08692342787981033, -0.9938743710517883, 0.7264577746391296, -0.43677520751953125, 0.10172410309314728, 1.9473198652267456, 0.036040812730789185, -0.7857685685157776, 0.37055525183677673, -0.6429897546768188, 1.8187236785888672, 1.7177046537399292, 1.257212519645691, -0.1322459578514099, -0.8444323539733887, 0.6832742691040039, -0.31040406227111816, -0.3505958616733551, 0.865570068359375, 0.35490626096725464, -0.21647879481315613, -1.5072214603424072, 0.50634765625, 1.285975694656372, -0.8967293500900269, -0.7793474197387695, 0.02854207530617714, -0.9000276923179626, 1.1404569149017334, 0.6959081292152405, 0.3379310071468353, 0.22211530804634094, 1.5913795232772827, 0.7669044733047485, -0.4863157868385315, 0.5330032110214233, 0.5291990637779236, -0.12424921989440918, -2.161862850189209, -1.082499384880066, 0.26077359914779663, -0.34721577167510986, -1.5580685138702393, 1.2886862754821777, -1.2195777893066406, -0.9500370025634766, 0.536803126335144, 0.1265828162431717, 1.408972144126892, 0.318261057138443, 1.5819683074951172, 2.1310951709747314, 0.8428847193717957, 0.3421248495578766, 1.2693016529083252, -0.06339965015649796, -0.43863338232040405, 1.8237555027008057, -0.4311664402484894, 0.5485889315605164, 1.042953610420227, -0.3623141646385193, -1.0645228624343872, -0.79915452003479, -1.2035961151123047, -0.7385901808738708, 1.2968882322311401, 0.10154330730438232, -1.0901776552200317, 0.2622474730014801, 1.635205864906311, 0.08113707602024078, -0.3358677327632904, 0.5826214551925659, 0.4501097500324249, -0.7417629957199097, -0.04386281222105026, -0.8368732333183289, 0.5384002923965454, -0.13383565843105316, -0.306152880191803, 0.3517938554286957, 0.4513469636440277, 1.2580136060714722, -0.014075817540287971, 0.02594073861837387, 1.1287108659744263, -1.4838693141937256, 1.5786772966384888, -0.6206058263778687, 0.2989565432071686, -2.399073362350464, 1.4625449180603027, -0.7753818035125732, 1.9353642463684082, -2.6151323318481445, 0.36698538064956665, -0.615705132484436, -0.5288888812065125, 0.3094742000102997, -0.358874648809433, 0.1556115597486496, -0.18002454936504364, -1.0353325605392456, -0.11699759215116501, -0.6924722194671631, 0.5657845735549927, 1.1674160957336426, 1.2836365699768066, -1.1375946998596191, -0.312475323677063, -1.7622406482696533, -0.12275762856006622, -0.6754779815673828, 0.28954094648361206, -2.0010218620300293, -0.1761915236711502, -1.965736985206604, -2.25138521194458, -1.3788481950759888, -0.8399897813796997, 1.0400171279907227, 0.1703454852104187, -0.8723031282424927, 1.1750129461288452, -0.3878621459007263, -1.8512541055679321, 1.0572766065597534, -2.203094959259033 ]
https://github.com/huggingface/datasets/issues/5225
Add video feature
@mariosasko is GPU decoding a hard requirement here? Do we really need it? (I don't know) Something to consider with `decord` is that it doesn't (AFAIK) support writing videos, so you'd still need something else for that. also I've noticed [issues](https://github.com/dmlc/decord/issues/242) with decord's ability to decode stereo audio streams along side the video (which you don't run into with PyAV). --- I think PyAV should be able to do the job just fine to start. If we write the video io utilities as their own functions, we can hot swap them later if we find/write a different solution that's faster/better.
### Feature request Add a `Video` feature to the library so folks can include videos in their datasets. ### Motivation Being able to load Video data would be quite helpful. However, there are some challenges when it comes to videos: 1. Videos, unlike images, can end up being extremely large files 2. Often times when training video models, you need to do some very specific sampling. Videos might end up needing to be broken down into X number of clips used for training/inference 3. Videos have an additional audio stream, which must be accounted for 4. The feature needs to be able to encode/decode videos (with right video settings) from bytes. ### Your contribution I did work on this a while back in [this (now closed) PR](https://github.com/huggingface/datasets/pull/4532). It used a library I made called [encoded_video](https://github.com/nateraw/encoded-video), which is basically the utils from [pytorchvideo](https://github.com/facebookresearch/pytorchvideo), but without the `torch` dep. It included the ability to read/write from bytes, as we need to do here. We don't want to be using a sketchy library that I made as a dependency in this repo, though. Would love to use this issue as a place to: - brainstorm ideas on how to do this right - list ways/examples to work around it for now CC @sayakpaul @mariosasko @fcakyon
430
100
Add video feature ### Feature request Add a `Video` feature to the library so folks can include videos in their datasets. ### Motivation Being able to load Video data would be quite helpful. However, there are some challenges when it comes to videos: 1. Videos, unlike images, can end up being extremely large files 2. Often times when training video models, you need to do some very specific sampling. Videos might end up needing to be broken down into X number of clips used for training/inference 3. Videos have an additional audio stream, which must be accounted for 4. The feature needs to be able to encode/decode videos (with right video settings) from bytes. ### Your contribution I did work on this a while back in [this (now closed) PR](https://github.com/huggingface/datasets/pull/4532). It used a library I made called [encoded_video](https://github.com/nateraw/encoded-video), which is basically the utils from [pytorchvideo](https://github.com/facebookresearch/pytorchvideo), but without the `torch` dep. It included the ability to read/write from bytes, as we need to do here. We don't want to be using a sketchy library that I made as a dependency in this repo, though. Would love to use this issue as a place to: - brainstorm ideas on how to do this right - list ways/examples to work around it for now CC @sayakpaul @mariosasko @fcakyon @mariosasko is GPU decoding a hard requirement here? Do we really need it? (I don't know) Something to consider with `decord` is that it doesn't (AFAIK) support writing videos, so you'd still need something else for that. also I've noticed [issues](https://github.com/dmlc/decord/issues/242) with decord's ability to decode stereo audio streams along side the video (which you don't run into with PyAV). --- I think PyAV should be able to do the job just fine to start. If we write the video io utilities as their own functions, we can hot swap them later if we find/write a different solution that's faster/better.
[ -1.273463487625122, -0.9415316581726074, -0.8314502239227295, 1.457404375076294, -0.14580002427101135, -1.204658031463623, 0.09731809794902802, -1.0928714275360107, 1.5644663572311401, -0.7788373827934265, 0.3630716800689697, -1.6294053792953491, 0.07271193712949753, -0.5807929039001465, -0.7986447215080261, -0.7906510233879089, -0.3606463074684143, -0.7664188146591187, 0.990309476852417, 2.5561256408691406, 1.183813214302063, -1.4594215154647827, 2.721035957336426, 0.7673525214195251, -0.19431033730506897, -1.0383392572402954, 0.4822058379650116, 0.08071676641702652, -1.2711553573608398, -0.4988301992416382, -0.959069013595581, -0.01902238093316555, -0.5449522137641907, -0.49100035429000854, 0.03296525031328201, 0.4006544053554535, -0.19554297626018524, -0.3573058843612671, -0.6254677176475525, -0.6794477701187134, 0.49364906549453735, -0.39990416169166565, 0.9680070877075195, -0.26809993386268616, 1.7896894216537476, -0.5780893564224243, 0.4262268543243408, 0.6544987559318542, 1.4447609186172485, 0.24009278416633606, -0.027158256620168686, 0.26574525237083435, 0.4340307414531708, -0.07361598312854767, 0.47405266761779785, 1.1727988719940186, 0.7007627487182617, 0.5096280574798584, 0.7146546840667725, -2.2045466899871826, 1.269689679145813, -1.017166256904602, 0.3303471803665161, 1.3216112852096558, -0.9386120438575745, 0.3995932340621948, -1.8099584579467773, -0.057262420654296875, 0.5580858588218689, -2.2792012691497803, 0.1927887499332428, -1.264163851737976, -0.46627500653266907, 0.9609584212303162, 0.28491416573524475, -1.3374745845794678, 0.23925819993019104, -0.46071967482566833, 1.002081036567688, 0.418312132358551, 1.182355523109436, -1.6044230461120605, 0.04678149148821831, -0.22554649412631989, 0.1410459727048874, -1.195725440979004, -1.5483982563018799, 0.49287205934524536, 0.6241413354873657, 0.5336493253707886, -0.07692883163690567, 0.9554086327552795, -1.0436506271362305, 0.8312610983848572, -0.9339258670806885, -1.6374289989471436, -1.414453387260437, -2.2396676540374756, -2.2841691970825195, 0.8044245839118958, -0.503322422504425, -0.4940570294857025, 2.0174312591552734, -1.0593804121017456, -1.821202278137207, 1.137419581413269, 0.32376012206077576, 0.06407617032527924, 2.389364004135132, 0.13811206817626953, -0.7201051712036133, 0.5108528137207031, -0.7163514494895935, 0.8784568309783936, -0.5338875651359558, 1.34479558467865, 0.41361844539642334, -0.9144822955131531, 1.6525514125823975, -0.40481576323509216, 0.5548052191734314, -0.7317826151847839, -0.47859758138656616, -0.8000951409339905, 0.3782986104488373, 1.9321613311767578, -0.31698644161224365, 1.5896873474121094, -0.41066569089889526, -1.606126308441162, -1.5587975978851318, 0.8426598906517029, 0.5185468792915344, -0.8348763585090637, 0.12185199558734894, -0.41348376870155334, 0.13838699460029602, -0.032963406294584274, 1.0783867835998535, 1.3079062700271606, 0.704261839389801, -0.2759137749671936, -0.9504761695861816, 0.2127794474363327, -0.11151695996522903, -0.6649644374847412, -1.8378608226776123, -0.35604456067085266, 0.1957644671201706, 0.6861515641212463, -1.2324538230895996, 1.7471481561660767, 0.8905929327011108, 1.951192855834961, 1.021463394165039, -0.38365936279296875, 1.5318971872329712, 0.04980405420064926, 1.83853018283844, -0.5191066861152649, 0.6698388457298279, -0.40176621079444885, -1.1613298654556274, 0.8081525564193726, -0.3866484761238098, -2.010443687438965, -0.6376692056655884, -0.7770713567733765, -0.21979087591171265, -0.7450913190841675, 0.8956653475761414, -0.24282203614711761, -1.3639483451843262, 0.23982268571853638, -0.6533707976341248, 0.182962104678154, -1.2099816799163818, 0.31618553400039673, 0.7627668380737305, -0.6760340929031372, 0.05507552996277809, -0.31562191247940063, -1.330316185951233, -0.4606325030326843, 0.32665133476257324, 1.876058578491211, -0.7613952159881592, 0.8674815893173218, 0.9793381690979004, -0.6368824243545532, 0.01927269622683525, 0.4086577892303467, -0.3714771270751953, 0.8424761891365051, -1.1036663055419922, -0.42889639735221863, 1.2052184343338013, -0.2080531120300293, -0.5307917594909668, 1.3682864904403687, 0.7942854166030884, -0.961975634098053, -0.2509087324142456, -0.1329805552959442, -0.8633707761764526, 0.0007100505754351616, -1.641622543334961, -0.18326540291309357, 0.30802032351493835, -1.5431793928146362, -0.484456330537796, -0.2301291972398758, 1.2005447149276733, -0.19653165340423584, 1.4550658464431763, -0.34590718150138855, -0.17899884283542633, -0.32808157801628113, -0.45131659507751465, 0.14930874109268188, -0.2670760154724121, -0.618087887763977, 0.26634663343429565, -0.8227828145027161, 0.39667561650276184, 1.4359103441238403, 0.37200525403022766, 0.013661208562552929, 0.4828847646713257, 1.0578961372375488, 0.4331042468547821, -0.028355978429317474, -0.8677232265472412, -1.5437657833099365, 2.031517505645752, -1.5016756057739258, 1.996598720550537, 0.8602710962295532, -0.02505515143275261, -1.8077276945114136, -1.8274884223937988, 1.3324084281921387, 1.163879632949829, 2.411424160003662, 0.5584505200386047, 0.3596551716327667, -0.7707111835479736, -0.602788507938385, 0.36622002720832825, -1.043111801147461, -0.8471274375915527, 0.054591793566942215, 2.4007184505462646, 1.777647614479065, -0.5196846127510071, -0.2472115457057953, -0.9854923486709595, 1.3810824155807495, -0.19364474713802338, 0.1956738978624344, 2.0162460803985596, -0.20387890934944153, -1.0322787761688232, 1.3211389780044556, -2.3974170684814453, 0.18742352724075317, 1.9874227046966553, 0.2720211446285248, 0.0940578505396843, -1.3865569829940796, -0.6138389706611633, -0.23335906863212585, -0.359275221824646, -1.226578950881958, 0.5829584002494812, -0.23887062072753906, -0.7966083288192749, -1.4861453771591187, 0.05648960545659065, -1.1924296617507935, -1.6450040340423584, 0.33213600516319275, 1.8777170181274414, 2.032135248184204, -0.7807848453521729, 1.4893889427185059, -0.23446714878082275, 0.0877297967672348, 1.297375202178955, 1.2036445140838623, 3.1705849170684814, 1.9119468927383423, -1.2690846920013428, 0.6236338019371033, -0.21934868395328522, -0.514190673828125, 1.1526919603347778, -1.093682885169983, 1.1720497608184814, -0.13997037708759308, -1.1950387954711914, -1.1870907545089722, 0.9675251841545105, 0.4427683651447296, 0.08601788431406021, -0.5158304572105408, 1.145795226097107, 0.14311908185482025, 1.2567585706710815, 0.5851576328277588, -0.36271390318870544, 0.6134418249130249, -0.4127691090106964, -0.5022324323654175, 1.557888388633728, 0.12499852478504181, -1.4957404136657715, -2.287747621536255, -0.14134275913238525, -0.827576756477356, -0.028935261070728302, -0.6505931615829468, -1.0150296688079834, 1.5735843181610107, 0.4591835141181946, -1.2857047319412231, -0.2821650803089142, -0.30170026421546936, -0.6127698421478271, 2.613459825515747, -1.4819289445877075, -0.3248315453529358, -1.0115009546279907, -0.5470664501190186, 1.599094271659851, -1.2018752098083496, -0.2151680290699005, -1.0117183923721313, -0.5815195441246033, -1.2858325242996216, -0.5441753268241882, -0.001210973598062992, -0.8487502336502075, 0.6865473389625549, 0.14394915103912354, -1.174745798110962, -0.3324653208255768, -0.8478673100471497, 0.8039014339447021, -0.08365192264318466, 0.254585862159729, 1.9713878631591797, 0.3735789358615875, -0.4273599088191986, 0.7514432072639465, 1.2272469997406006, 0.5489677786827087, -0.6255813241004944, 0.20275098085403442, -0.6669765114784241, 0.3747466802597046, -1.4015214443206787, 0.30983972549438477, -2.833181381225586, 0.7132490277290344, -0.02704799175262451, -0.17469170689582825, 0.03717474639415741, -1.3168553113937378, 1.1319897174835205, 2.6566193103790283, -1.1392121315002441, 0.4557574391365051, 0.3282911777496338, 1.2385025024414062, -1.5820932388305664, 0.3524366617202759, -0.3787330090999603, 2.1094233989715576, 0.2180207073688507, 1.1404930353164673, -0.5105900764465332, -2.319314479827881, 0.5570995807647705, -1.2111804485321045, -1.1376923322677612, 0.7930150628089905, -0.8505815267562866, 0.0000667572021484375, -1.5025742053985596, -0.14860083162784576, -0.9001107215881348, -1.1919207572937012, 0.7282699346542358, 0.10052698105573654, 0.4151707589626312, -0.6457464694976807, 0.2947734296321869, -2.1581661701202393, -1.3446342945098877, -0.20042505860328674, -0.9455061554908752, 0.4352264702320099, -0.3400205671787262, 0.6660797595977783, -0.15079502761363983, 0.011194194667041302, 0.2814485430717468, 1.404262661933899, 3.3643763065338135, 0.2327442765235901, 0.44991037249565125, -0.23148396611213684, -0.916215717792511, 1.4315738677978516, 0.9299497008323669, -0.09766539186239243, -0.6180773973464966, -0.9481303691864014, 1.2867810726165771, 1.9259017705917358, 0.9930233955383301, 0.11477866768836975, -0.8132395148277283, -0.7408477663993835, -0.06756484508514404, 0.12860141694545746, 0.436506450176239, 1.074299931526184, -0.007823368534445763, 0.09025097638368607, 1.4074667692184448, 1.2561639547348022, -0.42307448387145996, 0.3591528534889221, -0.8340062499046326, -0.3718562424182892, 0.4052126705646515, 0.38476425409317017, -0.003269741777330637, 0.37317413091659546, -0.955398440361023, -0.2553361654281616, -0.37655431032180786, -0.954444408416748, -0.7470993399620056, -0.3973105549812317, -0.28948691487312317, 1.6523418426513672, 0.1660400927066803, -0.4677582085132599, -0.028606627136468887, -0.8584260940551758, -0.08837777376174927, -1.0087071657180786, 0.20496058464050293, -0.05375690758228302, -0.10849501937627792, -0.021198619157075882, 1.752143383026123, -0.9164910912513733, -2.1288161277770996, 0.2916923761367798, 0.20269335806369781, -0.35723739862442017, 0.1654757857322693, 1.6800825595855713, 0.5151697397232056, 1.4063355922698975, 1.344622015953064, 0.9869043827056885, -0.6439266204833984, -1.242506742477417, 0.75361168384552, 0.9186344742774963, -1.4096662998199463, 0.8418509364128113, 0.007906808517873287, -0.4772053360939026, 0.6711240410804749, 1.2410715818405151, 0.3963391184806824, -1.9870368242263794, 0.7975516319274902, -0.8920807838439941, 0.7375503778457642, 0.6911888122558594, 0.6806418299674988, 0.2582819163799286, 0.8237944841384888, -1.202186942100525, -1.1493922472000122, -0.7717178463935852, -0.6436428427696228, 2.0215466022491455, -0.24811504781246185, 0.6009578704833984, -0.13712213933467865, -1.3548986911773682, -0.13729821145534515, 0.7242395877838135, 0.26576897501945496, -0.5026140213012695, 0.8641211986541748, -0.6668253540992737, -1.1025112867355347, -1.3844318389892578, -0.4814838469028473, -0.9482747316360474, -0.8812800645828247, 1.0567867755889893, 0.8439672589302063, 0.2855970561504364, 1.945778250694275, 0.5849491357803345, 0.23355966806411743, -2.7052431106567383, 0.9056316018104553, 0.34120282530784607, -0.08415394276380539, 0.9172292351722717, 0.29322919249534607, 1.0634390115737915, -0.03996851667761803, 0.53846275806427, -2.4209485054016113, 2.322448492050171, -0.2308187484741211, 0.7696759700775146, -0.04927316680550575, -0.16733622550964355, 1.1385990381240845, 0.5781295299530029, 0.5979831218719482, -1.11696457862854, 0.641164243221283, -0.5609516501426697, 1.2133111953735352, 0.921646237373352, -0.8254688382148743, 0.003860148601233959, 1.3543076515197754, 0.3992013931274414, -0.5233484506607056, -0.9314597845077515, -0.8570179343223572, 0.9613910913467407, 1.8000460863113403, 0.027206629514694214, -0.007435148116201162, 0.8529912829399109, 0.6647553443908691, -1.3339104652404785, 0.047422587871551514, -0.7538557648658752, -0.800542950630188, 1.6552900075912476, 1.9883850812911987, -0.06402254849672318, -0.26036012172698975, -0.6771553158760071, -1.3326207399368286, 0.7027512788772583, 0.028256583958864212, 0.17699624598026276, 0.6793010234832764, -0.6772072315216064, 1.1547393798828125, 0.8508957624435425, 0.9365826845169067, 0.08275939524173737, 0.26547539234161377, 0.3749378025531769, -0.4107896387577057, -1.1214476823806763, -0.2938939034938812, -1.1799874305725098, -2.4466376304626465, 0.4371466636657715, -0.18072845041751862, -1.4637423753738403, 0.07077863812446594, -1.0116454362869263, 0.8746572732925415, -0.6117377877235413, -1.1047775745391846, -1.5654422044754028, 0.24468204379081726, -0.17879310250282288, 0.8831864595413208, -1.6027836799621582, -0.07935792207717896, 1.133272647857666, 0.9104212522506714, -0.5543834567070007, 0.9891479015350342, 0.264151930809021, 1.032200813293457, 0.8681131601333618, -0.4160116910934448, 0.43115121126174927, 0.10579971969127655, -1.3105401992797852, 0.40549102425575256, 1.1553202867507935, 0.19432315230369568, 1.3967434167861938, -0.5485684275627136, 0.0411345474421978, 0.43367505073547363, -0.586830735206604, -0.4546966552734375, -0.5070405602455139, 0.7375758290290833, 0.0603671558201313, -0.9216352105140686, -0.029273640364408493, -0.12440203130245209, -0.25400620698928833, 0.17410045862197876, -1.5503042936325073, -0.1594933271408081, -0.34953951835632324, -0.552717387676239, -1.2806572914123535, 0.00022436678409576416, 1.3855348825454712, -0.8405860662460327, -0.1812869906425476, 0.49576324224472046, 0.372400164604187, 0.5201157927513123, 0.5992704629898071, -0.6402475237846375, -0.38510802388191223, -0.16654309630393982, -0.3802264332771301, 0.28876692056655884, 1.300990104675293, -0.10363726317882538, -0.970550537109375, 0.6855036616325378, -0.4205661714076996, 0.07895240187644958, 1.9107111692428589, 0.03420303761959076, -0.7947283387184143, 0.37403956055641174, -0.6747510433197021, 1.8676327466964722, 1.7266407012939453, 1.2850918769836426, -0.12558716535568237, -0.8649440407752991, 0.6990312337875366, -0.2964930534362793, -0.3513842821121216, 0.8629870414733887, 0.3815600872039795, -0.2207120805978775, -1.4859358072280884, 0.5501099228858948, 1.2416905164718628, -0.8801736235618591, -0.7502972483634949, 0.027431346476078033, -0.8844977617263794, 1.1384974718093872, 0.6909499764442444, 0.34805887937545776, 0.20693784952163696, 1.631165862083435, 0.7707473635673523, -0.49611082673072815, 0.5694158673286438, 0.5551169514656067, -0.13558755815029144, -2.153001070022583, -1.124873161315918, 0.2597249448299408, -0.33723872900009155, -1.5625109672546387, 1.33094322681427, -1.2209420204162598, -0.942245602607727, 0.5225566029548645, 0.1079830601811409, 1.406053066253662, 0.3275938332080841, 1.5587328672409058, 2.135904550552368, 0.861927330493927, 0.3659651577472687, 1.2560938596725464, -0.09759988635778427, -0.4235861897468567, 1.8081438541412354, -0.4283392131328583, 0.549072802066803, 1.052391767501831, -0.3657994866371155, -1.046698808670044, -0.7869892120361328, -1.1904537677764893, -0.7287301421165466, 1.2688649892807007, 0.10066995024681091, -1.101444959640503, 0.2539912164211273, 1.650368332862854, 0.06715937703847885, -0.3324574828147888, 0.5833942890167236, 0.4806635081768036, -0.7345810532569885, -0.050950173288583755, -0.8569982647895813, 0.5394672155380249, -0.16381485760211945, -0.31539303064346313, 0.3674111068248749, 0.43982207775115967, 1.2622517347335815, 0.028255298733711243, 0.02576896920800209, 1.151275873184204, -1.4946715831756592, 1.53232741355896, -0.6484925150871277, 0.2970070242881775, -2.3823676109313965, 1.4898496866226196, -0.7880339622497559, 1.9570410251617432, -2.6002485752105713, 0.3766876757144928, -0.6472833752632141, -0.5464891791343689, 0.3180922567844391, -0.3679075837135315, 0.12617842853069305, -0.15899445116519928, -1.0347095727920532, -0.10810662060976028, -0.6676695346832275, 0.568377673625946, 1.1542086601257324, 1.2470630407333374, -1.1286988258361816, -0.28874605894088745, -1.7435277700424194, -0.11403924226760864, -0.6605761647224426, 0.26512637734413147, -2.0345098972320557, -0.18687234818935394, -1.9733669757843018, -2.258948802947998, -1.3502590656280518, -0.8264232873916626, 1.0577889680862427, 0.15658363699913025, -0.848400890827179, 1.2018998861312866, -0.3349621593952179, -1.875503659248352, 1.0948262214660645, -2.1582555770874023 ]
https://github.com/huggingface/datasets/issues/5225
Add video feature
Video is still a bit of a mess, but I'd say pyAV is likely the best approach (or supporting all three via pytorchvideo, but that adds a middle man dependency). Being able to decode on the GPU, into memory that could be passed off to a Tensor in whatever framework is being used would be the dream, I don't think there is any interop of that nature working right now. Number of decoder instances per GPU is limited so it's not clear if balancing load btw GPU decoders and CPUs would be needed in say large scale video training. Any of these solutions is less than ideal due to the nature of video, having a simple Python interface video / start -> end results in lots of extra memory (you need to decode whole range of the clips into a buffer before using anything). Any scalable video system would be streaming on the fly (issuing frames via callbacks as soon as the stream is far enough along to have re-ordered the frames and synced audio+video+other metadata (sensors, CC, etc).
### Feature request Add a `Video` feature to the library so folks can include videos in their datasets. ### Motivation Being able to load Video data would be quite helpful. However, there are some challenges when it comes to videos: 1. Videos, unlike images, can end up being extremely large files 2. Often times when training video models, you need to do some very specific sampling. Videos might end up needing to be broken down into X number of clips used for training/inference 3. Videos have an additional audio stream, which must be accounted for 4. The feature needs to be able to encode/decode videos (with right video settings) from bytes. ### Your contribution I did work on this a while back in [this (now closed) PR](https://github.com/huggingface/datasets/pull/4532). It used a library I made called [encoded_video](https://github.com/nateraw/encoded-video), which is basically the utils from [pytorchvideo](https://github.com/facebookresearch/pytorchvideo), but without the `torch` dep. It included the ability to read/write from bytes, as we need to do here. We don't want to be using a sketchy library that I made as a dependency in this repo, though. Would love to use this issue as a place to: - brainstorm ideas on how to do this right - list ways/examples to work around it for now CC @sayakpaul @mariosasko @fcakyon
430
179
Add video feature ### Feature request Add a `Video` feature to the library so folks can include videos in their datasets. ### Motivation Being able to load Video data would be quite helpful. However, there are some challenges when it comes to videos: 1. Videos, unlike images, can end up being extremely large files 2. Often times when training video models, you need to do some very specific sampling. Videos might end up needing to be broken down into X number of clips used for training/inference 3. Videos have an additional audio stream, which must be accounted for 4. The feature needs to be able to encode/decode videos (with right video settings) from bytes. ### Your contribution I did work on this a while back in [this (now closed) PR](https://github.com/huggingface/datasets/pull/4532). It used a library I made called [encoded_video](https://github.com/nateraw/encoded-video), which is basically the utils from [pytorchvideo](https://github.com/facebookresearch/pytorchvideo), but without the `torch` dep. It included the ability to read/write from bytes, as we need to do here. We don't want to be using a sketchy library that I made as a dependency in this repo, though. Would love to use this issue as a place to: - brainstorm ideas on how to do this right - list ways/examples to work around it for now CC @sayakpaul @mariosasko @fcakyon Video is still a bit of a mess, but I'd say pyAV is likely the best approach (or supporting all three via pytorchvideo, but that adds a middle man dependency). Being able to decode on the GPU, into memory that could be passed off to a Tensor in whatever framework is being used would be the dream, I don't think there is any interop of that nature working right now. Number of decoder instances per GPU is limited so it's not clear if balancing load btw GPU decoders and CPUs would be needed in say large scale video training. Any of these solutions is less than ideal due to the nature of video, having a simple Python interface video / start -> end results in lots of extra memory (you need to decode whole range of the clips into a buffer before using anything). Any scalable video system would be streaming on the fly (issuing frames via callbacks as soon as the stream is far enough along to have re-ordered the frames and synced audio+video+other metadata (sensors, CC, etc).
[ -1.237155795097351, -0.9500148892402649, -0.789792001247406, 1.419312834739685, -0.1634485274553299, -1.1952697038650513, 0.13046646118164062, -1.0675410032272339, 1.616344690322876, -0.8428171277046204, 0.369454026222229, -1.6406822204589844, 0.054005712270736694, -0.6069270968437195, -0.7582025527954102, -0.8099931478500366, -0.37174221873283386, -0.7924826145172119, 0.9936155676841736, 2.5670204162597656, 1.174376368522644, -1.4867520332336426, 2.6665210723876953, 0.7606688737869263, -0.1971709430217743, -1.0387396812438965, 0.4717155396938324, 0.060174956917762756, -1.274587631225586, -0.5188913941383362, -0.9657999873161316, -0.017478132620453835, -0.5559906959533691, -0.49047723412513733, 0.01155557669699192, 0.39340099692344666, -0.2172899693250656, -0.3490482270717621, -0.6157492399215698, -0.6990744471549988, 0.46720513701438904, -0.392864465713501, 1.0171895027160645, -0.2660297453403473, 1.7784595489501953, -0.5317674279212952, 0.4334316849708557, 0.6992896199226379, 1.4257339239120483, 0.24281024932861328, -0.03309407830238342, 0.19602148234844208, 0.4349389374256134, -0.12844613194465637, 0.50437331199646, 1.188774585723877, 0.714149534702301, 0.5116124153137207, 0.7397052645683289, -2.175356149673462, 1.3616201877593994, -1.0249333381652832, 0.36028212308883667, 1.327964186668396, -0.9200609922409058, 0.394558846950531, -1.7918896675109863, -0.08014409989118576, 0.5752490758895874, -2.239520788192749, 0.2071242481470108, -1.2500332593917847, -0.4746415615081787, 0.9584856033325195, 0.2637951374053955, -1.2849148511886597, 0.23831012845039368, -0.4365535378456116, 0.9691351056098938, 0.37998276948928833, 1.1915020942687988, -1.6359806060791016, 0.03392833471298218, -0.21883930265903473, 0.16911005973815918, -1.206140398979187, -1.5630520582199097, 0.510195791721344, 0.6101132035255432, 0.5011494159698486, -0.10949382930994034, 0.9830106496810913, -1.05767822265625, 0.8176097869873047, -0.9416749477386475, -1.5980262756347656, -1.3607972860336304, -2.2588329315185547, -2.3160300254821777, 0.8020984530448914, -0.5061312317848206, -0.5290600657463074, 2.0592572689056396, -1.0596650838851929, -1.787143588066101, 1.14626145362854, 0.3305111527442932, 0.06942247599363327, 2.411264419555664, 0.15390953421592712, -0.7111766934394836, 0.49278050661087036, -0.6910450458526611, 0.8905670046806335, -0.5471802353858948, 1.369715690612793, 0.42794039845466614, -0.9525378942489624, 1.6123133897781372, -0.4145338237285614, 0.5286509990692139, -0.7137021422386169, -0.5150788426399231, -0.7714787721633911, 0.4053434431552887, 1.8659741878509521, -0.3314945697784424, 1.5443364381790161, -0.3932112753391266, -1.6127445697784424, -1.602453589439392, 0.8735648393630981, 0.5026842355728149, -0.8068574070930481, 0.09185189008712769, -0.4145585596561432, 0.15257075428962708, -0.03400980681180954, 1.0815330743789673, 1.3432379961013794, 0.686101496219635, -0.2820671796798706, -0.9306432604789734, 0.1692752093076706, -0.17830035090446472, -0.6728963851928711, -1.8393008708953857, -0.35404717922210693, 0.19591863453388214, 0.6832977533340454, -1.1972359418869019, 1.7722891569137573, 0.9504871964454651, 1.9183470010757446, 0.9860054850578308, -0.3819236159324646, 1.5093584060668945, 0.03941194713115692, 1.793387770652771, -0.5396662354469299, 0.6787056922912598, -0.4163244068622589, -1.136027455329895, 0.876143753528595, -0.3853723406791687, -1.9726731777191162, -0.658073365688324, -0.773213267326355, -0.23833715915679932, -0.7244526147842407, 0.9029704332351685, -0.21337680518627167, -1.323513388633728, 0.25443992018699646, -0.6508009433746338, 0.18707820773124695, -1.1834076642990112, 0.3379368185997009, 0.7581692337989807, -0.6860307455062866, 0.04926472157239914, -0.2858582139015198, -1.335526704788208, -0.4965762495994568, 0.3022264540195465, 1.8657513856887817, -0.7840641140937805, 0.8365156650543213, 1.0009738206863403, -0.6438636183738708, 0.0358891487121582, 0.37761828303337097, -0.35309574007987976, 0.8041071891784668, -1.1002870798110962, -0.4247708320617676, 1.1658287048339844, -0.1730627715587616, -0.5204904079437256, 1.3718370199203491, 0.7476197481155396, -0.9783504009246826, -0.18153157830238342, -0.14032253623008728, -0.8686450719833374, 0.024925576522946358, -1.6271487474441528, -0.17677322030067444, 0.29636818170547485, -1.5060895681381226, -0.4566952586174011, -0.23307040333747864, 1.1982487440109253, -0.20847788453102112, 1.449386715888977, -0.35183385014533997, -0.2163829505443573, -0.3274136781692505, -0.3928166925907135, 0.1203220933675766, -0.25643208622932434, -0.5963097810745239, 0.2693062722682953, -0.8176871538162231, 0.36718475818634033, 1.4649068117141724, 0.36048391461372375, -0.011362832970917225, 0.44812703132629395, 1.0708009004592896, 0.4361855685710907, 0.017013277858495712, -0.8715394139289856, -1.4717422723770142, 1.9989482164382935, -1.497179627418518, 1.9981621503829956, 0.9055498838424683, 0.026891661807894707, -1.7937147617340088, -1.8230695724487305, 1.336917519569397, 1.1747262477874756, 2.4175429344177246, 0.5758483409881592, 0.3298470675945282, -0.777482271194458, -0.6095946431159973, 0.4167078137397766, -1.0688552856445312, -0.8022344708442688, 0.0493815541267395, 2.3974196910858154, 1.821619987487793, -0.5190568566322327, -0.2434058040380478, -0.9745871424674988, 1.4105151891708374, -0.16555313766002655, 0.14701296389102936, 2.0441489219665527, -0.2324562817811966, -1.0597809553146362, 1.3327620029449463, -2.421671152114868, 0.14050039649009705, 1.976820945739746, 0.2736171782016754, 0.08001615852117538, -1.3945428133010864, -0.6449618935585022, -0.2392250895500183, -0.3801997900009155, -1.1894826889038086, 0.6435109376907349, -0.25444361567497253, -0.7892496585845947, -1.5256654024124146, 0.10948914289474487, -1.2269799709320068, -1.6509093046188354, 0.2810555398464203, 1.8377044200897217, 2.0671677589416504, -0.7773450613021851, 1.529259443283081, -0.23343424499034882, 0.06307245045900345, 1.2890434265136719, 1.2266632318496704, 3.1677470207214355, 1.9005571603775024, -1.2773455381393433, 0.5517387390136719, -0.1897551417350769, -0.5298883318901062, 1.1234484910964966, -1.1014293432235718, 1.1876287460327148, -0.13165386021137238, -1.1798264980316162, -1.1937440633773804, 0.9808474779129028, 0.4300764501094818, 0.13044174015522003, -0.4930160939693451, 1.158483862876892, 0.1822497546672821, 1.2859896421432495, 0.5849486589431763, -0.3406960964202881, 0.6109580397605896, -0.4344269633293152, -0.5198739171028137, 1.5875985622406006, 0.19921070337295532, -1.4913369417190552, -2.235581398010254, -0.16569313406944275, -0.8286582827568054, -0.019014772027730942, -0.6139434576034546, -1.007827639579773, 1.59691321849823, 0.41666844487190247, -1.3311580419540405, -0.30536121129989624, -0.310907781124115, -0.6290881633758545, 2.58428955078125, -1.4925830364227295, -0.3180881440639496, -1.0151995420455933, -0.5328797101974487, 1.5881043672561646, -1.195626974105835, -0.1678588092327118, -1.042221188545227, -0.5691466927528381, -1.2813384532928467, -0.5287692546844482, -0.03624517470598221, -0.8416271805763245, 0.7119238376617432, 0.17487603425979614, -1.1882038116455078, -0.35663744807243347, -0.8469822406768799, 0.7762488722801208, -0.0883956328034401, 0.30875009298324585, 1.9194639921188354, 0.4129382073879242, -0.4528781771659851, 0.7120055556297302, 1.2295948266983032, 0.5678074359893799, -0.5947205424308777, 0.18969927728176117, -0.6781431436538696, 0.35787728428840637, -1.3647902011871338, 0.3201408088207245, -2.8457179069519043, 0.7069849371910095, -0.04205147922039032, -0.1741315722465515, 0.023788994178175926, -1.341054081916809, 1.1388986110687256, 2.631889581680298, -1.1207877397537231, 0.4402027428150177, 0.3275303244590759, 1.2268006801605225, -1.5738670825958252, 0.37135693430900574, -0.35171398520469666, 2.0947768688201904, 0.18751318752765656, 1.1472091674804688, -0.5398198962211609, -2.343513011932373, 0.5304784178733826, -1.2578065395355225, -1.0938825607299805, 0.8070877194404602, -0.8065932989120483, -0.0045098597183823586, -1.4947044849395752, -0.15966935455799103, -0.854379415512085, -1.2107175588607788, 0.7637145519256592, 0.09030336141586304, 0.4098844528198242, -0.6325485706329346, 0.29289543628692627, -2.1536002159118652, -1.3752995729446411, -0.2320287525653839, -0.9223734736442566, 0.4721701145172119, -0.36468154191970825, 0.701400637626648, -0.1847480833530426, 0.011213256046175957, 0.2793007791042328, 1.386047601699829, 3.3659937381744385, 0.22504876554012299, 0.5009777545928955, -0.24667727947235107, -0.9058500528335571, 1.3993020057678223, 0.9323566555976868, -0.07162294536828995, -0.6244785189628601, -0.9782660603523254, 1.2700228691101074, 1.940259575843811, 0.99478679895401, 0.06960054486989975, -0.8118793964385986, -0.7196668386459351, -0.07640672475099564, 0.13222019374370575, 0.4231247305870056, 1.0572389364242554, 0.006655034609138966, 0.08296968787908554, 1.4247841835021973, 1.2644094228744507, -0.4662705063819885, 0.3495059907436371, -0.789517879486084, -0.40231049060821533, 0.3899337649345398, 0.3548857569694519, 0.021601948887109756, 0.3927758038043976, -0.93487948179245, -0.2983933091163635, -0.3905330002307892, -0.9600632190704346, -0.7371535897254944, -0.4491807222366333, -0.2980895936489105, 1.6771750450134277, 0.20055599510669708, -0.5163822174072266, 0.014334362000226974, -0.8340564966201782, -0.0949966087937355, -1.041815996170044, 0.20689243078231812, -0.04026474803686142, -0.12866435945034027, -0.04461260885000229, 1.799643635749817, -0.9000699520111084, -2.089927911758423, 0.2844669222831726, 0.20089715719223022, -0.3335031270980835, 0.1708422750234604, 1.6403303146362305, 0.5258655548095703, 1.4501408338546753, 1.306419849395752, 0.9977402091026306, -0.6845208406448364, -1.2703046798706055, 0.7725855112075806, 0.9385117292404175, -1.4654470682144165, 0.8533300757408142, -0.019667956978082657, -0.4529028534889221, 0.6733704209327698, 1.2478604316711426, 0.3967497646808624, -2.0036354064941406, 0.7829765677452087, -0.9263362288475037, 0.782052218914032, 0.6757704615592957, 0.6494571566581726, 0.24858364462852478, 0.763232409954071, -1.1911958456039429, -1.1699637174606323, -0.7841448783874512, -0.675044596195221, 2.0327842235565186, -0.28989076614379883, 0.626223087310791, -0.11942467838525772, -1.4090656042099, -0.16437947750091553, 0.7439172863960266, 0.29600954055786133, -0.506898045539856, 0.8209178447723389, -0.6581882834434509, -1.1147067546844482, -1.401192307472229, -0.4716418981552124, -0.9879919290542603, -0.9125768542289734, 1.069082260131836, 0.884466290473938, 0.25641727447509766, 1.924462914466858, 0.6099189519882202, 0.24066276848316193, -2.664713144302368, 0.8955169320106506, 0.33939898014068604, -0.09205111861228943, 0.947904109954834, 0.31239083409309387, 1.0463520288467407, -0.03880344331264496, 0.5694133639335632, -2.4897689819335938, 2.3360531330108643, -0.20655477046966553, 0.783935010433197, -0.04186709225177765, -0.19981656968593597, 1.1599111557006836, 0.5594833493232727, 0.6029134392738342, -1.113373875617981, 0.6178988814353943, -0.5191711187362671, 1.234889030456543, 0.9178787469863892, -0.8098612427711487, 0.03054048679769039, 1.3505672216415405, 0.39990299940109253, -0.5222434997558594, -0.8878347277641296, -0.9020420908927917, 0.9300746917724609, 1.8008464574813843, -0.02426019124686718, 0.020974397659301758, 0.8057428598403931, 0.6680958867073059, -1.3132364749908447, 0.05376078933477402, -0.7811272144317627, -0.835423469543457, 1.5895253419876099, 1.973440170288086, -0.0908946841955185, -0.23162741959095, -0.6931010484695435, -1.323578953742981, 0.7166589498519897, 0.043396420776844025, 0.18637728691101074, 0.6711847186088562, -0.6621320843696594, 1.1317534446716309, 0.8590837121009827, 0.9245933890342712, 0.11936064064502716, 0.2941166162490845, 0.3906014561653137, -0.40955883264541626, -1.0885061025619507, -0.25922709703445435, -1.1970494985580444, -2.4836878776550293, 0.44492122530937195, -0.21510370075702667, -1.4829615354537964, -0.022101374343037605, -0.9987926483154297, 0.8432989120483398, -0.5807379484176636, -1.093686580657959, -1.6005276441574097, 0.24337857961654663, -0.14631585776805878, 0.9299463629722595, -1.588599681854248, -0.08594747632741928, 1.121269702911377, 0.9098820090293884, -0.590522289276123, 1.0000548362731934, 0.2399921715259552, 0.9985796809196472, 0.8737287521362305, -0.3788195252418518, 0.46727490425109863, 0.06355027109384537, -1.3101873397827148, 0.386122465133667, 1.159485936164856, 0.17465858161449432, 1.3331973552703857, -0.5589250326156616, 0.06763824075460434, 0.43457818031311035, -0.5695851445198059, -0.43672412633895874, -0.469148725271225, 0.7533405423164368, 0.06653038412332535, -0.8960193395614624, -0.012325135059654713, -0.13165856897830963, -0.2740347981452942, 0.16079460084438324, -1.5412544012069702, -0.1700393259525299, -0.40447404980659485, -0.5126728415489197, -1.2733649015426636, -0.025231972336769104, 1.3992043733596802, -0.7876614332199097, -0.19070132076740265, 0.5112181305885315, 0.4264943599700928, 0.5123693943023682, 0.6029161810874939, -0.608138918876648, -0.4215538203716278, -0.13215582072734833, -0.3713366389274597, 0.34922105073928833, 1.342552900314331, -0.07351954281330109, -0.9599481225013733, 0.7536887526512146, -0.4056587219238281, 0.08066483587026596, 1.9487383365631104, 0.034492455422878265, -0.7974953055381775, 0.38975903391838074, -0.6824532151222229, 1.85069739818573, 1.7880951166152954, 1.2715383768081665, -0.08149366825819016, -0.907750129699707, 0.7117180824279785, -0.2962861955165863, -0.3257869780063629, 0.9086673855781555, 0.36916521191596985, -0.2357676774263382, -1.497057318687439, 0.5333845019340515, 1.2378156185150146, -0.84102863073349, -0.770509660243988, 0.02407013066112995, -0.8942289352416992, 1.119482159614563, 0.692177951335907, 0.39831796288490295, 0.17438334226608276, 1.6526063680648804, 0.7806280255317688, -0.5189493894577026, 0.5332489013671875, 0.5406975746154785, -0.12890242040157318, -2.1604490280151367, -1.1278127431869507, 0.21371734142303467, -0.3747420012950897, -1.5490988492965698, 1.298494577407837, -1.2243926525115967, -0.9720851182937622, 0.549441933631897, 0.03916165977716446, 1.3989877700805664, 0.34071800112724304, 1.5277851819992065, 2.14782452583313, 0.8491855263710022, 0.3391457498073578, 1.2646042108535767, -0.1443759948015213, -0.421865314245224, 1.8652690649032593, -0.43481937050819397, 0.5041999816894531, 1.0815008878707886, -0.344272643327713, -1.06625497341156, -0.7635749578475952, -1.1474781036376953, -0.6912709474563599, 1.2932695150375366, 0.06597306579351425, -1.1025491952896118, 0.2906216084957123, 1.6375824213027954, 0.05880872905254364, -0.33691221475601196, 0.5672396421432495, 0.5107397437095642, -0.7877113223075867, -0.03304658085107803, -0.8658326864242554, 0.5431888103485107, -0.17578642070293427, -0.32988542318344116, 0.4120694696903229, 0.4739401936531067, 1.2490280866622925, -0.01657705008983612, 0.05357395112514496, 1.1024153232574463, -1.5172146558761597, 1.5460271835327148, -0.5951100587844849, 0.25134390592575073, -2.363548755645752, 1.4799385070800781, -0.7442943453788757, 1.9681401252746582, -2.629589796066284, 0.3912976086139679, -0.6686151623725891, -0.5459725260734558, 0.3224521577358246, -0.3472532033920288, 0.14896252751350403, -0.16858619451522827, -1.037043809890747, -0.10975190252065659, -0.6194731593132019, 0.5647304058074951, 1.1476191282272339, 1.2690825462341309, -1.1298445463180542, -0.30309322476387024, -1.7128466367721558, -0.1302325278520584, -0.7335623502731323, 0.2263326644897461, -1.9867337942123413, -0.18455666303634644, -1.9721472263336182, -2.2323262691497803, -1.3902642726898193, -0.833283543586731, 1.0568031072616577, 0.16761337220668793, -0.8895277976989746, 1.1958845853805542, -0.3589177429676056, -1.8729509115219116, 1.0881905555725098, -2.1052722930908203 ]
https://github.com/huggingface/datasets/issues/5225
Add video feature
For standalone usage, decoding on GPU could be ideal but isn't async processing of inputs on CPUs while letting the accelerator busy for training the de-facto? Of course, I am aware of other advanced mechanisms such as CPU offloading, but I think my point is conveyed.
### Feature request Add a `Video` feature to the library so folks can include videos in their datasets. ### Motivation Being able to load Video data would be quite helpful. However, there are some challenges when it comes to videos: 1. Videos, unlike images, can end up being extremely large files 2. Often times when training video models, you need to do some very specific sampling. Videos might end up needing to be broken down into X number of clips used for training/inference 3. Videos have an additional audio stream, which must be accounted for 4. The feature needs to be able to encode/decode videos (with right video settings) from bytes. ### Your contribution I did work on this a while back in [this (now closed) PR](https://github.com/huggingface/datasets/pull/4532). It used a library I made called [encoded_video](https://github.com/nateraw/encoded-video), which is basically the utils from [pytorchvideo](https://github.com/facebookresearch/pytorchvideo), but without the `torch` dep. It included the ability to read/write from bytes, as we need to do here. We don't want to be using a sketchy library that I made as a dependency in this repo, though. Would love to use this issue as a place to: - brainstorm ideas on how to do this right - list ways/examples to work around it for now CC @sayakpaul @mariosasko @fcakyon
430
46
Add video feature ### Feature request Add a `Video` feature to the library so folks can include videos in their datasets. ### Motivation Being able to load Video data would be quite helpful. However, there are some challenges when it comes to videos: 1. Videos, unlike images, can end up being extremely large files 2. Often times when training video models, you need to do some very specific sampling. Videos might end up needing to be broken down into X number of clips used for training/inference 3. Videos have an additional audio stream, which must be accounted for 4. The feature needs to be able to encode/decode videos (with right video settings) from bytes. ### Your contribution I did work on this a while back in [this (now closed) PR](https://github.com/huggingface/datasets/pull/4532). It used a library I made called [encoded_video](https://github.com/nateraw/encoded-video), which is basically the utils from [pytorchvideo](https://github.com/facebookresearch/pytorchvideo), but without the `torch` dep. It included the ability to read/write from bytes, as we need to do here. We don't want to be using a sketchy library that I made as a dependency in this repo, though. Would love to use this issue as a place to: - brainstorm ideas on how to do this right - list ways/examples to work around it for now CC @sayakpaul @mariosasko @fcakyon For standalone usage, decoding on GPU could be ideal but isn't async processing of inputs on CPUs while letting the accelerator busy for training the de-facto? Of course, I am aware of other advanced mechanisms such as CPU offloading, but I think my point is conveyed.
[ -1.2693657875061035, -0.958405077457428, -0.8209702372550964, 1.479623794555664, -0.12833884358406067, -1.2108359336853027, 0.09967778623104095, -1.0662508010864258, 1.5818854570388794, -0.7950277924537659, 0.3791281580924988, -1.6316474676132202, 0.07509969174861908, -0.5933211445808411, -0.7680141925811768, -0.833732008934021, -0.3825908899307251, -0.7633211612701416, 1.0157470703125, 2.5815658569335938, 1.1702572107315063, -1.4649425745010376, 2.6792051792144775, 0.7487204074859619, -0.21057625114917755, -1.032726764678955, 0.46666061878204346, 0.08672299981117249, -1.2453334331512451, -0.5041743516921997, -0.9273229837417603, -0.020425621420145035, -0.5696437954902649, -0.46797454357147217, 0.012012234888970852, 0.3937215507030487, -0.2230859100818634, -0.30613160133361816, -0.5703662633895874, -0.7237241268157959, 0.4928133487701416, -0.3758455514907837, 0.9777061939239502, -0.2705064117908478, 1.73992121219635, -0.5496695637702942, 0.44481295347213745, 0.6950763463973999, 1.384951114654541, 0.24203111231327057, -0.01705976203083992, 0.22280101478099823, 0.4565439820289612, -0.11777874827384949, 0.47040098905563354, 1.1713212728500366, 0.6948519945144653, 0.5407698154449463, 0.7144503593444824, -2.1902852058410645, 1.3204599618911743, -1.0426428318023682, 0.3501218855381012, 1.3716834783554077, -0.909976065158844, 0.3906285762786865, -1.790451169013977, -0.10972379148006439, 0.530988335609436, -2.259077787399292, 0.2017027735710144, -1.245481014251709, -0.48432841897010803, 0.9664943218231201, 0.2763547897338867, -1.2987122535705566, 0.21681122481822968, -0.4400882124900818, 0.9801897406578064, 0.4245217740535736, 1.1864380836486816, -1.6326028108596802, 0.041971269994974136, -0.20671486854553223, 0.14399121701717377, -1.2133795022964478, -1.5274465084075928, 0.4903567135334015, 0.5720748901367188, 0.5240757465362549, -0.07653423398733139, 0.935076117515564, -1.0347952842712402, 0.8465985655784607, -0.9523689150810242, -1.6064714193344116, -1.3755803108215332, -2.278801679611206, -2.3661789894104004, 0.8402844667434692, -0.49235859513282776, -0.49979814887046814, 2.052940845489502, -1.0605477094650269, -1.7819852828979492, 1.1758371591567993, 0.3397749364376068, 0.021263424307107925, 2.422966241836548, 0.16308626532554626, -0.7232927680015564, 0.5260024070739746, -0.7142941951751709, 0.885512113571167, -0.5486582517623901, 1.3680487871170044, 0.4783654510974884, -0.9639236927032471, 1.6224393844604492, -0.39835938811302185, 0.5099602341651917, -0.7055290341377258, -0.496690034866333, -0.7879750728607178, 0.42407938838005066, 1.8426032066345215, -0.29486942291259766, 1.5626333951950073, -0.38612884283065796, -1.5786640644073486, -1.5688399076461792, 0.8644452691078186, 0.5198006629943848, -0.8099741339683533, 0.12291185557842255, -0.3766327500343323, 0.12300345301628113, -0.003916759043931961, 1.0647634267807007, 1.3050360679626465, 0.6766484379768372, -0.3015105724334717, -0.9538314342498779, 0.21954429149627686, -0.1422003209590912, -0.6618778109550476, -1.8084062337875366, -0.3483907878398895, 0.18741002678871155, 0.6875758767127991, -1.2418277263641357, 1.7443679571151733, 0.9209240078926086, 1.930446982383728, 0.9703488945960999, -0.392111599445343, 1.5019869804382324, 0.03330281004309654, 1.8293023109436035, -0.5328210592269897, 0.6696199774742126, -0.4040818214416504, -1.1473816633224487, 0.8419193029403687, -0.37457969784736633, -1.966792106628418, -0.667388916015625, -0.8057795166969299, -0.20789854228496552, -0.7635779976844788, 0.9283278584480286, -0.21916575729846954, -1.3211555480957031, 0.2585497498512268, -0.6676408648490906, 0.1744978278875351, -1.249861478805542, 0.3267993927001953, 0.7514225840568542, -0.6783678531646729, 0.03543839976191521, -0.2927374839782715, -1.331004023551941, -0.5032086968421936, 0.31216737627983093, 1.865930438041687, -0.7374386191368103, 0.8940808773040771, 0.9865700006484985, -0.6829138398170471, 0.030020762234926224, 0.4185515344142914, -0.379594087600708, 0.8367107510566711, -1.0960972309112549, -0.4593518078327179, 1.185081958770752, -0.21601974964141846, -0.5269768238067627, 1.3998568058013916, 0.7778452634811401, -0.9750041365623474, -0.21475645899772644, -0.1462681144475937, -0.8356987237930298, 0.015879221260547638, -1.6014410257339478, -0.18923546373844147, 0.322689414024353, -1.5223238468170166, -0.46938133239746094, -0.24023379385471344, 1.2298280000686646, -0.25742894411087036, 1.4863606691360474, -0.3232903778553009, -0.230643630027771, -0.37170588970184326, -0.4101549983024597, 0.12856720387935638, -0.21718090772628784, -0.6149741411209106, 0.29560065269470215, -0.8232442140579224, 0.3946670591831207, 1.4420527219772339, 0.34894368052482605, 0.0027070874348282814, 0.4521189332008362, 1.0711416006088257, 0.4070169925689697, -0.016143660992383957, -0.913474440574646, -1.485663652420044, 2.021592378616333, -1.512584924697876, 1.994327425956726, 0.8723595142364502, 0.0019732946529984474, -1.7795042991638184, -1.7999181747436523, 1.3498647212982178, 1.2074990272521973, 2.414393424987793, 0.5585878491401672, 0.3504190444946289, -0.7810949087142944, -0.6081154346466064, 0.3776561915874481, -1.1006593704223633, -0.8230174779891968, 0.05613066256046295, 2.3813955783843994, 1.7933905124664307, -0.5046708583831787, -0.23857218027114868, -1.0189902782440186, 1.4127295017242432, -0.16581998765468597, 0.12864257395267487, 2.0524423122406006, -0.24061428010463715, -1.043129801750183, 1.2995823621749878, -2.3896234035491943, 0.16270336508750916, 2.002168655395508, 0.30601686239242554, 0.054698146879673004, -1.388074517250061, -0.6445657014846802, -0.23897698521614075, -0.3747324049472809, -1.1940290927886963, 0.6169811487197876, -0.2409205138683319, -0.8050068020820618, -1.489905834197998, 0.07708991318941116, -1.1855963468551636, -1.6579302549362183, 0.298046350479126, 1.8064725399017334, 2.0627570152282715, -0.7783539891242981, 1.5316200256347656, -0.19809065759181976, 0.0794420838356018, 1.2829762697219849, 1.2095756530761719, 3.1559765338897705, 1.9116119146347046, -1.257361650466919, 0.6042271852493286, -0.1737203150987625, -0.5151945352554321, 1.1537541151046753, -1.0784863233566284, 1.1854857206344604, -0.15665137767791748, -1.1882562637329102, -1.2130190134048462, 0.9637933373451233, 0.3905010223388672, 0.10382866114377975, -0.5349382162094116, 1.145295262336731, 0.17772305011749268, 1.2794208526611328, 0.5715435147285461, -0.31415513157844543, 0.6266540288925171, -0.4472479522228241, -0.49691662192344666, 1.590869426727295, 0.16477353870868683, -1.541098713874817, -2.2697582244873047, -0.17516140639781952, -0.7981783747673035, -0.02667950838804245, -0.6334871649742126, -1.0269391536712646, 1.5630431175231934, 0.4808991253376007, -1.3126440048217773, -0.28536999225616455, -0.34241175651550293, -0.6625165939331055, 2.6171875, -1.4795653820037842, -0.2922135293483734, -1.0049309730529785, -0.5383375287055969, 1.579073190689087, -1.202221393585205, -0.1585700809955597, -1.0266668796539307, -0.6133517622947693, -1.30001962184906, -0.5380159020423889, -0.008170364424586296, -0.8782819509506226, 0.6619113087654114, 0.11022427678108215, -1.1749589443206787, -0.34049397706985474, -0.8346182703971863, 0.7416366338729858, -0.0825609415769577, 0.3058183491230011, 1.924957036972046, 0.39285650849342346, -0.44034165143966675, 0.7054919004440308, 1.223831295967102, 0.5634661912918091, -0.6078600883483887, 0.22902396321296692, -0.6918892860412598, 0.3456569015979767, -1.3360838890075684, 0.3215159773826599, -2.8263978958129883, 0.7219919562339783, -0.04937658831477165, -0.1790159046649933, -0.00956893153488636, -1.2972837686538696, 1.176254391670227, 2.6214873790740967, -1.1781208515167236, 0.4785207509994507, 0.3192739188671112, 1.1921489238739014, -1.5907371044158936, 0.3425539433956146, -0.3326682150363922, 2.1044766902923584, 0.20909246802330017, 1.1531667709350586, -0.5548436045646667, -2.3055551052093506, 0.5553575158119202, -1.2314043045043945, -1.1234328746795654, 0.7979234457015991, -0.8419018387794495, 0.030434053391218185, -1.4555708169937134, -0.14185307919979095, -0.8628548383712769, -1.2295467853546143, 0.7334601879119873, 0.05546730011701584, 0.4534027874469757, -0.6242846846580505, 0.30603790283203125, -2.1845507621765137, -1.358712911605835, -0.2433190792798996, -0.9511609673500061, 0.4403125047683716, -0.32659822702407837, 0.6967617273330688, -0.16559229791164398, 0.008582537062466145, 0.2923971116542816, 1.415059208869934, 3.405667304992676, 0.23254117369651794, 0.48121586441993713, -0.20649781823158264, -0.9238940477371216, 1.414096713066101, 0.9844704866409302, -0.07597838342189789, -0.5986948609352112, -0.9788479804992676, 1.2953448295593262, 1.9387922286987305, 1.0166146755218506, 0.10263542085886002, -0.8039188981056213, -0.7188826203346252, -0.04997377097606659, 0.1382346749305725, 0.4130498468875885, 1.0388411283493042, 0.022470079362392426, 0.09906385838985443, 1.4283881187438965, 1.2482883930206299, -0.4504706859588623, 0.34372949600219727, -0.8210182785987854, -0.3816474378108978, 0.40123462677001953, 0.36789292097091675, -0.002642597071826458, 0.41679584980010986, -0.921433687210083, -0.2956262230873108, -0.3594076931476593, -0.9745807647705078, -0.7567147016525269, -0.43296995759010315, -0.33080896735191345, 1.6815528869628906, 0.1752212941646576, -0.4885930120944977, 0.015802990645170212, -0.8586013317108154, -0.1194879412651062, -1.038804531097412, 0.20295946300029755, -0.058678701519966125, -0.1018262580037117, -0.061001479625701904, 1.8328042030334473, -0.9226511716842651, -2.130297899246216, 0.28496024012565613, 0.21699684858322144, -0.35079455375671387, 0.19030681252479553, 1.6581755876541138, 0.5101723670959473, 1.437170147895813, 1.3004072904586792, 1.0041648149490356, -0.6863664984703064, -1.2548131942749023, 0.7735616564750671, 0.9464700818061829, -1.4272412061691284, 0.8431124687194824, -0.006040981970727444, -0.41891250014305115, 0.6599056720733643, 1.2481318712234497, 0.37358325719833374, -1.9741698503494263, 0.7784734964370728, -0.8904724717140198, 0.7711820006370544, 0.6453969478607178, 0.6896748542785645, 0.22242403030395508, 0.7668872475624084, -1.2435939311981201, -1.1270556449890137, -0.7584837675094604, -0.6331223249435425, 1.9976295232772827, -0.22903794050216675, 0.6160845160484314, -0.1464601457118988, -1.3607220649719238, -0.1269625723361969, 0.7274672985076904, 0.2790505588054657, -0.47636204957962036, 0.8427577018737793, -0.6418136358261108, -1.0824973583221436, -1.4091389179229736, -0.43647950887680054, -0.966578483581543, -0.9142284989356995, 1.076920509338379, 0.8436093926429749, 0.24169784784317017, 1.9414989948272705, 0.5963954925537109, 0.2467176765203476, -2.674034357070923, 0.9078394174575806, 0.33234307169914246, -0.08009354025125504, 0.943419337272644, 0.3088732063770294, 1.0726619958877563, -0.04631800204515457, 0.5543596744537354, -2.448153257369995, 2.3437795639038086, -0.18701566755771637, 0.771174430847168, 0.010162496007978916, -0.15826670825481415, 1.173770785331726, 0.5802968144416809, 0.5704359412193298, -1.1473186016082764, 0.6282936930656433, -0.5360812544822693, 1.243894338607788, 0.9401084780693054, -0.8285430073738098, 0.0031131235882639885, 1.3369125127792358, 0.4228422939777374, -0.4749545753002167, -0.9108604192733765, -0.8763542175292969, 0.9560533761978149, 1.7840670347213745, -0.04926459863781929, -0.0011401386000216007, 0.8282689452171326, 0.6777498126029968, -1.3177424669265747, 0.03289582207798958, -0.7847399711608887, -0.834097146987915, 1.6399245262145996, 1.9827284812927246, -0.061637215316295624, -0.25855106115341187, -0.7160086035728455, -1.3144283294677734, 0.7322267889976501, 0.029061343520879745, 0.18607862293720245, 0.6882613897323608, -0.6729189157485962, 1.162086009979248, 0.8727181553840637, 0.8781538605690002, 0.14110399782657623, 0.24986572563648224, 0.33904969692230225, -0.3742635250091553, -1.0907660722732544, -0.27162307500839233, -1.204655647277832, -2.504610776901245, 0.44848233461380005, -0.21479642391204834, -1.424694299697876, 0.007067377679049969, -1.0450434684753418, 0.8390485644340515, -0.6099534034729004, -1.1252800226211548, -1.5936989784240723, 0.2187412828207016, -0.18974176049232483, 0.9370987415313721, -1.580330729484558, -0.09303904324769974, 1.128666877746582, 0.8816844820976257, -0.5970820784568787, 1.0032501220703125, 0.22578370571136475, 1.0143375396728516, 0.8309175372123718, -0.4203503131866455, 0.4765036702156067, 0.09569737315177917, -1.3392443656921387, 0.39672067761421204, 1.168044924736023, 0.21181420981884003, 1.3494921922683716, -0.5585647225379944, 0.09438466280698776, 0.4426068067550659, -0.5664539933204651, -0.480300635099411, -0.5030564069747925, 0.7285680770874023, 0.06739025563001633, -0.9250844120979309, 0.005363177508115768, -0.13613258302211761, -0.2449001669883728, 0.1980908066034317, -1.552083134651184, -0.19473794102668762, -0.3789803385734558, -0.549675703048706, -1.2961593866348267, -0.024710718542337418, 1.3724600076675415, -0.8415235877037048, -0.1475505381822586, 0.49481719732284546, 0.39430147409439087, 0.5256355404853821, 0.5899812579154968, -0.5943724513053894, -0.41288650035858154, -0.18888241052627563, -0.3720094859600067, 0.30415019392967224, 1.2991564273834229, -0.10511788725852966, -0.9918749928474426, 0.7435017228126526, -0.4057844877243042, 0.09279315173625946, 1.935784935951233, 0.039355065673589706, -0.8353968858718872, 0.3725746273994446, -0.6200616955757141, 1.8751609325408936, 1.7546132802963257, 1.2641156911849976, -0.13642702996730804, -0.9067570567131042, 0.6802641749382019, -0.2705756425857544, -0.3291277289390564, 0.8894178867340088, 0.34843429923057556, -0.23452222347259521, -1.4881008863449097, 0.5402784943580627, 1.267207384109497, -0.8512261509895325, -0.7952989935874939, 0.05115954577922821, -0.9216105341911316, 1.0779253244400024, 0.6905679106712341, 0.39668580889701843, 0.19874124228954315, 1.6643885374069214, 0.7829865217208862, -0.5187126994132996, 0.5242618322372437, 0.5493626594543457, -0.1539875715970993, -2.1344945430755615, -1.1326664686203003, 0.23231437802314758, -0.3927018642425537, -1.5455241203308105, 1.32752525806427, -1.1969082355499268, -0.9459315538406372, 0.5711919069290161, 0.06959450244903564, 1.4164830446243286, 0.2922099828720093, 1.5604304075241089, 2.1157617568969727, 0.8506360650062561, 0.3509950339794159, 1.2715142965316772, -0.13377320766448975, -0.43319171667099, 1.8403557538986206, -0.43169867992401123, 0.5220413208007812, 1.099407434463501, -0.36586061120033264, -1.0448639392852783, -0.7623964548110962, -1.1436046361923218, -0.7064673900604248, 1.2742563486099243, 0.11250071227550507, -1.0962886810302734, 0.25511494278907776, 1.6465356349945068, 0.08843067288398743, -0.31987500190734863, 0.5793443322181702, 0.5009580254554749, -0.7653094530105591, -0.007919958792626858, -0.8766562342643738, 0.5528582334518433, -0.17342138290405273, -0.3147919178009033, 0.36563560366630554, 0.4603617489337921, 1.2435581684112549, -0.02852718159556389, 0.05919492989778519, 1.112195611000061, -1.476440668106079, 1.5152287483215332, -0.625210165977478, 0.2798076272010803, -2.3225865364074707, 1.4327058792114258, -0.7672792077064514, 1.9105801582336426, -2.6377763748168945, 0.37271106243133545, -0.6774057745933533, -0.5564062595367432, 0.3198133111000061, -0.382060706615448, 0.1624300479888916, -0.17996491491794586, -1.015994906425476, -0.12792326509952545, -0.6894217133522034, 0.5563907027244568, 1.1687489748001099, 1.273202896118164, -1.0956370830535889, -0.3190070390701294, -1.7206802368164062, -0.09828264266252518, -0.6778441667556763, 0.27873924374580383, -2.002626419067383, -0.1869547963142395, -1.9537594318389893, -2.230884075164795, -1.3844298124313354, -0.839474081993103, 1.0597628355026245, 0.13151845335960388, -0.8621752858161926, 1.1881107091903687, -0.3763684630393982, -1.8480607271194458, 1.1063194274902344, -2.16513991355896 ]
https://github.com/huggingface/datasets/issues/5225
Add video feature
Here's a minimal implementation of the helper functions we'd need from PyAV, a lot of which I borrowed from `pytorchvideo`, stripping out the `torch` specific stuff: [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/gist/nateraw/c327cb6ff6b074e6ddc8068d19c0367d/pyav-io.ipynb) It's not too much code...@mariosasko we could probably just maintain these helper fns within the `datasets` library, right?
### Feature request Add a `Video` feature to the library so folks can include videos in their datasets. ### Motivation Being able to load Video data would be quite helpful. However, there are some challenges when it comes to videos: 1. Videos, unlike images, can end up being extremely large files 2. Often times when training video models, you need to do some very specific sampling. Videos might end up needing to be broken down into X number of clips used for training/inference 3. Videos have an additional audio stream, which must be accounted for 4. The feature needs to be able to encode/decode videos (with right video settings) from bytes. ### Your contribution I did work on this a while back in [this (now closed) PR](https://github.com/huggingface/datasets/pull/4532). It used a library I made called [encoded_video](https://github.com/nateraw/encoded-video), which is basically the utils from [pytorchvideo](https://github.com/facebookresearch/pytorchvideo), but without the `torch` dep. It included the ability to read/write from bytes, as we need to do here. We don't want to be using a sketchy library that I made as a dependency in this repo, though. Would love to use this issue as a place to: - brainstorm ideas on how to do this right - list ways/examples to work around it for now CC @sayakpaul @mariosasko @fcakyon
430
47
Add video feature ### Feature request Add a `Video` feature to the library so folks can include videos in their datasets. ### Motivation Being able to load Video data would be quite helpful. However, there are some challenges when it comes to videos: 1. Videos, unlike images, can end up being extremely large files 2. Often times when training video models, you need to do some very specific sampling. Videos might end up needing to be broken down into X number of clips used for training/inference 3. Videos have an additional audio stream, which must be accounted for 4. The feature needs to be able to encode/decode videos (with right video settings) from bytes. ### Your contribution I did work on this a while back in [this (now closed) PR](https://github.com/huggingface/datasets/pull/4532). It used a library I made called [encoded_video](https://github.com/nateraw/encoded-video), which is basically the utils from [pytorchvideo](https://github.com/facebookresearch/pytorchvideo), but without the `torch` dep. It included the ability to read/write from bytes, as we need to do here. We don't want to be using a sketchy library that I made as a dependency in this repo, though. Would love to use this issue as a place to: - brainstorm ideas on how to do this right - list ways/examples to work around it for now CC @sayakpaul @mariosasko @fcakyon Here's a minimal implementation of the helper functions we'd need from PyAV, a lot of which I borrowed from `pytorchvideo`, stripping out the `torch` specific stuff: [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/gist/nateraw/c327cb6ff6b074e6ddc8068d19c0367d/pyav-io.ipynb) It's not too much code...@mariosasko we could probably just maintain these helper fns within the `datasets` library, right?
[ -1.2417361736297607, -0.9003021717071533, -0.8292959928512573, 1.4341795444488525, -0.1294361650943756, -1.2092078924179077, 0.11698733270168304, -1.084381341934204, 1.620904803276062, -0.7869300842285156, 0.31305912137031555, -1.6541966199874878, 0.0761498436331749, -0.5763533711433411, -0.7663329839706421, -0.7905789613723755, -0.3567197918891907, -0.7563313245773315, 1.0070757865905762, 2.559534788131714, 1.18161940574646, -1.4592115879058838, 2.6854898929595947, 0.7640330195426941, -0.20440828800201416, -1.0843522548675537, 0.4643046259880066, 0.049928367137908936, -1.3222644329071045, -0.48263850808143616, -0.9696221947669983, -0.02589290216565132, -0.5682188868522644, -0.49300417304039, 0.04233747720718384, 0.3924328684806824, -0.21383756399154663, -0.3448209762573242, -0.5994106531143188, -0.6860391497612, 0.4857209324836731, -0.37139883637428284, 0.9801461696624756, -0.2186996191740036, 1.7305877208709717, -0.5704591870307922, 0.4265552759170532, 0.6836376786231995, 1.4218015670776367, 0.20409588515758514, -0.03392728790640831, 0.22179417312145233, 0.4359782338142395, -0.05795595422387123, 0.44137346744537354, 1.1810243129730225, 0.7190700769424438, 0.49445202946662903, 0.704671323299408, -2.216400146484375, 1.287466287612915, -0.9655523300170898, 0.31100866198539734, 1.325499176979065, -0.9511973261833191, 0.35190001130104065, -1.7998064756393433, -0.056517817080020905, 0.5679569244384766, -2.2395362854003906, 0.22718417644500732, -1.2882612943649292, -0.47902706265449524, 0.9755963683128357, 0.30613183975219727, -1.2632800340652466, 0.21235968172550201, -0.463367760181427, 0.9831779599189758, 0.4353025257587433, 1.1842536926269531, -1.6740096807479858, 0.0035187378525733948, -0.21740587055683136, 0.16607140004634857, -1.2128407955169678, -1.5513447523117065, 0.5080491304397583, 0.6488917469978333, 0.530017614364624, -0.08737014979124069, 0.9562020301818848, -1.0494972467422485, 0.8076493144035339, -0.95017009973526, -1.698286771774292, -1.3641505241394043, -2.2513458728790283, -2.317918539047241, 0.7736543416976929, -0.45558640360832214, -0.473544180393219, 2.014211654663086, -1.0477181673049927, -1.8401743173599243, 1.088378667831421, 0.30568960309028625, 0.042915817350149155, 2.3874588012695312, 0.17151841521263123, -0.7526035904884338, 0.4808506965637207, -0.7072249054908752, 0.8685019016265869, -0.5090935230255127, 1.3626291751861572, 0.443807452917099, -0.928619384765625, 1.6191942691802979, -0.40336206555366516, 0.5461262464523315, -0.7755220532417297, -0.42109090089797974, -0.7526436448097229, 0.3784571886062622, 1.908908486366272, -0.33678632974624634, 1.5459246635437012, -0.3490464389324188, -1.596482753753662, -1.5310125350952148, 0.8200333714485168, 0.5336570739746094, -0.7911339402198792, 0.09936273097991943, -0.4204265773296356, 0.13390083611011505, -0.03393782302737236, 1.098151445388794, 1.3129303455352783, 0.7235626578330994, -0.30289703607559204, -0.958745002746582, 0.20522572100162506, -0.16648361086845398, -0.7021113038063049, -1.852851390838623, -0.3296995162963867, 0.2168612778186798, 0.7324925661087036, -1.24858558177948, 1.7392131090164185, 0.8947551250457764, 1.9566599130630493, 0.9889570474624634, -0.4265647530555725, 1.5591598749160767, 0.05479521304368973, 1.8742872476577759, -0.5193795561790466, 0.6898121237754822, -0.40438607335090637, -1.1471998691558838, 0.8531368374824524, -0.34930747747421265, -1.9690173864364624, -0.656392514705658, -0.7831403613090515, -0.21004411578178406, -0.7441293597221375, 0.908594012260437, -0.24733930826187134, -1.380514144897461, 0.2299773395061493, -0.6952758431434631, 0.1830558329820633, -1.215255856513977, 0.280206561088562, 0.7673760056495667, -0.6753975749015808, 0.028459403663873672, -0.31831851601600647, -1.3871870040893555, -0.5005069971084595, 0.2969096601009369, 1.8322473764419556, -0.7231500148773193, 0.8750885128974915, 1.0074665546417236, -0.6489142775535583, 0.07553329318761826, 0.40524739027023315, -0.3527891933917999, 0.8134024143218994, -1.147142767906189, -0.3862992823123932, 1.169671893119812, -0.1774175763130188, -0.5571023225784302, 1.40277898311615, 0.8049500584602356, -0.9823883771896362, -0.23817817866802216, -0.12272243946790695, -0.8560009598731995, 0.01800147444009781, -1.632883071899414, -0.19304989278316498, 0.3325515389442444, -1.5262796878814697, -0.4510885179042816, -0.24789918959140778, 1.253135085105896, -0.20470283925533295, 1.478914499282837, -0.3051820397377014, -0.20793966948986053, -0.3518121540546417, -0.38370150327682495, 0.12531384825706482, -0.2700882852077484, -0.6135255098342896, 0.29028937220573425, -0.8435430526733398, 0.3800814747810364, 1.485366702079773, 0.3279675245285034, 0.04011893272399902, 0.4612773656845093, 1.0848381519317627, 0.40134990215301514, -0.035596732050180435, -0.8940902948379517, -1.5506638288497925, 2.038858413696289, -1.4998087882995605, 1.9745920896530151, 0.8672377467155457, -0.014435958117246628, -1.783976435661316, -1.8437252044677734, 1.3337451219558716, 1.1506215333938599, 2.439826488494873, 0.552007794380188, 0.3821895122528076, -0.7590557932853699, -0.6246654391288757, 0.3906242251396179, -1.0235029458999634, -0.8186309337615967, 0.1161460354924202, 2.4129786491394043, 1.7840725183486938, -0.5062631368637085, -0.24382321536540985, -0.9948357343673706, 1.3759384155273438, -0.2015063613653183, 0.16483329236507416, 2.0596892833709717, -0.19058558344841003, -1.04777193069458, 1.3159997463226318, -2.3946633338928223, 0.1943066418170929, 2.017882823944092, 0.2733999788761139, 0.10366947948932648, -1.4054408073425293, -0.666205883026123, -0.24058005213737488, -0.38038119673728943, -1.2113590240478516, 0.5939978957176208, -0.24673062562942505, -0.8563500642776489, -1.5351985692977905, 0.09209705889225006, -1.1809591054916382, -1.6774094104766846, 0.282730370759964, 1.847277045249939, 2.0164642333984375, -0.7595405578613281, 1.496950387954712, -0.23895816504955292, 0.05410083383321762, 1.2626525163650513, 1.1937520503997803, 3.1496810913085938, 1.9242534637451172, -1.2665038108825684, 0.6911337375640869, -0.19622036814689636, -0.5219106078147888, 1.1022714376449585, -1.1172858476638794, 1.157278060913086, -0.18712511658668518, -1.200556755065918, -1.2138772010803223, 0.9819095730781555, 0.42751529812812805, 0.10879592597484589, -0.533291757106781, 1.1760023832321167, 0.17309288680553436, 1.2722856998443604, 0.5979170203208923, -0.3268060088157654, 0.6286906599998474, -0.42975205183029175, -0.4814966022968292, 1.5680702924728394, 0.1508387327194214, -1.4888479709625244, -2.301121711730957, -0.19391098618507385, -0.8583078980445862, -0.043532438576221466, -0.6202311515808105, -1.0025187730789185, 1.6089816093444824, 0.45570647716522217, -1.3249382972717285, -0.2947166860103607, -0.31719714403152466, -0.6114515662193298, 2.6204886436462402, -1.4374390840530396, -0.30182313919067383, -1.0097323656082153, -0.539449155330658, 1.5867199897766113, -1.182267665863037, -0.19352871179580688, -1.045868992805481, -0.5765002369880676, -1.2710925340652466, -0.5510371327400208, 0.017286986112594604, -0.8411345481872559, 0.6842136383056641, 0.14603368937969208, -1.187531590461731, -0.3560834228992462, -0.8509531617164612, 0.8281535506248474, -0.06109403818845749, 0.24415932595729828, 1.9438667297363281, 0.39323240518569946, -0.4373239576816559, 0.7168601751327515, 1.201891541481018, 0.5653709769248962, -0.5988907217979431, 0.1972898244857788, -0.6729320287704468, 0.3140930235385895, -1.3744144439697266, 0.32614579796791077, -2.8155109882354736, 0.7181293964385986, -0.026405975222587585, -0.15081802010536194, 0.016134098172187805, -1.3063499927520752, 1.1582961082458496, 2.6675798892974854, -1.1689891815185547, 0.4727928638458252, 0.33730268478393555, 1.2257788181304932, -1.524266004562378, 0.31479161977767944, -0.3735649287700653, 2.11360502243042, 0.22468729317188263, 1.1796073913574219, -0.5246034264564514, -2.3215677738189697, 0.5827929377555847, -1.2415461540222168, -1.1189253330230713, 0.8341276049613953, -0.8140165209770203, 0.012634112499654293, -1.4679181575775146, -0.12040494382381439, -0.8764176964759827, -1.2251967191696167, 0.7149426341056824, 0.07175478339195251, 0.44388753175735474, -0.6656500697135925, 0.30731627345085144, -2.133554458618164, -1.35415518283844, -0.18588630855083466, -0.9426583647727966, 0.4493352770805359, -0.3459259867668152, 0.6811164617538452, -0.16269001364707947, 0.011082020588219166, 0.2857622802257538, 1.4106659889221191, 3.3749098777770996, 0.23549778759479523, 0.4326014518737793, -0.21265646815299988, -0.9267979264259338, 1.4015834331512451, 0.9695910215377808, -0.0916045755147934, -0.6024017333984375, -0.9300598502159119, 1.2552770376205444, 1.9411444664001465, 1.0061161518096924, 0.07525717467069626, -0.8185056447982788, -0.7530368566513062, -0.0406910702586174, 0.16538584232330322, 0.42515671253204346, 1.0515387058258057, 0.005944044329226017, 0.07807426154613495, 1.4103302955627441, 1.2318694591522217, -0.4377575218677521, 0.37520402669906616, -0.863822877407074, -0.39112135767936707, 0.4180103838443756, 0.3661062717437744, 0.0391865000128746, 0.3955303430557251, -0.9981716275215149, -0.27755457162857056, -0.34954652190208435, -0.9669317603111267, -0.7571921348571777, -0.42652690410614014, -0.29432037472724915, 1.6467646360397339, 0.15661178529262543, -0.4492572247982025, -0.007148004602640867, -0.8153993487358093, -0.05765368789434433, -1.0340286493301392, 0.2292100489139557, -0.08990821987390518, -0.08264683932065964, -0.03682417795062065, 1.7900289297103882, -0.9118549823760986, -2.064558506011963, 0.282654732465744, 0.1917707473039627, -0.3766348361968994, 0.18863987922668457, 1.690484881401062, 0.5664916038513184, 1.407997727394104, 1.3071650266647339, 1.005025863647461, -0.6222890019416809, -1.2652907371520996, 0.7547441124916077, 0.9349935054779053, -1.4131733179092407, 0.8448091149330139, -0.022027570754289627, -0.4901585876941681, 0.691406786441803, 1.26663076877594, 0.36450710892677307, -2.0155742168426514, 0.7473554611206055, -0.8811854720115662, 0.7124054431915283, 0.6796602010726929, 0.6991538405418396, 0.21590635180473328, 0.7811785340309143, -1.222822666168213, -1.1371203660964966, -0.7517406344413757, -0.6598101854324341, 1.9934160709381104, -0.24803152680397034, 0.5825811624526978, -0.13159243762493134, -1.3688546419143677, -0.14477401971817017, 0.7340415120124817, 0.2840985953807831, -0.4806912839412689, 0.8528568148612976, -0.6839405298233032, -1.09205961227417, -1.334902286529541, -0.5325735211372375, -0.9389634728431702, -0.9168750047683716, 1.0502179861068726, 0.8485587239265442, 0.31591543555259705, 1.9552843570709229, 0.6121490597724915, 0.2152847796678543, -2.668731212615967, 0.8776971101760864, 0.3719674050807953, -0.061124276369810104, 0.9493614435195923, 0.29822614789009094, 1.0662883520126343, -0.04669743776321411, 0.571171760559082, -2.421396017074585, 2.3155405521392822, -0.21804942190647125, 0.7479676604270935, -0.034030161798000336, -0.16186591982841492, 1.1299028396606445, 0.5981879234313965, 0.5901649594306946, -1.1320388317108154, 0.6585577130317688, -0.5854097604751587, 1.2066797018051147, 0.8639448881149292, -0.8298116326332092, 0.022211816161870956, 1.3075740337371826, 0.40594878792762756, -0.5181835889816284, -0.8753892183303833, -0.9321387410163879, 0.9470595717430115, 1.8071359395980835, 0.0018915468826889992, 0.07324936240911484, 0.8438557982444763, 0.650118350982666, -1.3128341436386108, 0.0001437067985534668, -0.7756320834159851, -0.7795642018318176, 1.6606565713882446, 1.9976146221160889, -0.08560376614332199, -0.22024062275886536, -0.7071590423583984, -1.3048255443572998, 0.7202492952346802, 0.018372584134340286, 0.1644716113805771, 0.702528715133667, -0.6391542553901672, 1.1355934143066406, 0.8316391706466675, 0.9540706276893616, 0.08903778344392776, 0.2877902388572693, 0.33262208104133606, -0.3870386481285095, -1.1311169862747192, -0.2875797152519226, -1.17982017993927, -2.4659366607666016, 0.4742356538772583, -0.17019981145858765, -1.5032176971435547, 0.044421885162591934, -1.037277102470398, 0.835418701171875, -0.6191175580024719, -1.1111444234848022, -1.5106621980667114, 0.2736492156982422, -0.1922338455915451, 0.9097062945365906, -1.5841360092163086, -0.046809032559394836, 1.148260235786438, 0.9208838939666748, -0.5615916848182678, 0.9802433252334595, 0.25232312083244324, 1.0654813051223755, 0.8756030797958374, -0.3776315152645111, 0.44676223397254944, 0.1268922984600067, -1.2865866422653198, 0.377311110496521, 1.148149847984314, 0.22085285186767578, 1.3441911935806274, -0.5353636145591736, 0.058876171708106995, 0.4394150972366333, -0.5697205662727356, -0.47371339797973633, -0.5171611905097961, 0.7215981483459473, 0.10807672888040543, -0.9211366772651672, -0.03332643210887909, -0.14381103217601776, -0.23459817469120026, 0.19089390337467194, -1.5159838199615479, -0.19353234767913818, -0.3601643741130829, -0.5335801839828491, -1.2718864679336548, 0.006990077905356884, 1.3651551008224487, -0.8190120458602905, -0.184174582362175, 0.49200716614723206, 0.3819006681442261, 0.5434841513633728, 0.6115999221801758, -0.6210637092590332, -0.44596269726753235, -0.1608305126428604, -0.3887496888637543, 0.3087376058101654, 1.3251428604125977, -0.07709281891584396, -0.9861286878585815, 0.7304748892784119, -0.4454440176486969, 0.10494574159383774, 1.9095786809921265, 0.034710079431533813, -0.8222640752792358, 0.3342766761779785, -0.6344562768936157, 1.8649139404296875, 1.7503440380096436, 1.2678793668746948, -0.14554737508296967, -0.8721300959587097, 0.665826678276062, -0.2970891296863556, -0.3774254620075226, 0.8844037055969238, 0.3603361248970032, -0.23115916550159454, -1.455753207206726, 0.537987232208252, 1.2751134634017944, -0.8635954856872559, -0.7829199433326721, 0.024396579712629318, -0.8951355814933777, 1.1270182132720947, 0.7221212983131409, 0.34501224756240845, 0.20596393942832947, 1.6231639385223389, 0.7824928164482117, -0.5127974152565002, 0.5515192747116089, 0.5190566778182983, -0.12608148157596588, -2.159790515899658, -1.103752851486206, 0.20705291628837585, -0.33176296949386597, -1.5691297054290771, 1.30106782913208, -1.2260724306106567, -0.9587755799293518, 0.5192154049873352, 0.1038803830742836, 1.3982527256011963, 0.3431790769100189, 1.5542064905166626, 2.145402669906616, 0.8808399438858032, 0.3598426580429077, 1.2600469589233398, -0.1149805560708046, -0.4760504961013794, 1.8371583223342896, -0.42797303199768066, 0.5605440139770508, 1.0535120964050293, -0.38572534918785095, -1.0387109518051147, -0.7826051712036133, -1.1752408742904663, -0.6892225742340088, 1.2608684301376343, 0.09071293473243713, -1.1597801446914673, 0.2635955810546875, 1.625129222869873, 0.09996345639228821, -0.29198840260505676, 0.641952633857727, 0.4846000373363495, -0.7643558979034424, -0.04112843796610832, -0.866210401058197, 0.5385687351226807, -0.17856208980083466, -0.30329301953315735, 0.377682089805603, 0.46923649311065674, 1.2406429052352905, 0.030168592929840088, 0.018538113683462143, 1.1317460536956787, -1.489889144897461, 1.5418399572372437, -0.6274433732032776, 0.3069552779197693, -2.3924131393432617, 1.4451210498809814, -0.7940929532051086, 1.9377409219741821, -2.6175429821014404, 0.34735798835754395, -0.6029189825057983, -0.5975783467292786, 0.2729980945587158, -0.37429681420326233, 0.1370401382446289, -0.1642914116382599, -1.0388226509094238, -0.12539243698120117, -0.6987197399139404, 0.5563462376594543, 1.1507772207260132, 1.2980084419250488, -1.102311611175537, -0.2569652795791626, -1.7506779432296753, -0.14577138423919678, -0.6993684768676758, 0.29843372106552124, -1.9714168310165405, -0.1855156123638153, -1.9858524799346924, -2.2380759716033936, -1.3819470405578613, -0.8641711473464966, 1.0390509366989136, 0.16175702214241028, -0.854093074798584, 1.152121901512146, -0.3385908007621765, -1.852643609046936, 1.0405535697937012, -2.186880111694336 ]
https://github.com/huggingface/datasets/issues/5225
Add video feature
Also wanted to note I added a PR for video classification in `transformers` here, which uses `decord`. It's still open...should we make a decision now to align the libraries we are using between `datasets` and `transformers`? (CC @Narsil ) https://github.com/huggingface/transformers/pull/20151
### Feature request Add a `Video` feature to the library so folks can include videos in their datasets. ### Motivation Being able to load Video data would be quite helpful. However, there are some challenges when it comes to videos: 1. Videos, unlike images, can end up being extremely large files 2. Often times when training video models, you need to do some very specific sampling. Videos might end up needing to be broken down into X number of clips used for training/inference 3. Videos have an additional audio stream, which must be accounted for 4. The feature needs to be able to encode/decode videos (with right video settings) from bytes. ### Your contribution I did work on this a while back in [this (now closed) PR](https://github.com/huggingface/datasets/pull/4532). It used a library I made called [encoded_video](https://github.com/nateraw/encoded-video), which is basically the utils from [pytorchvideo](https://github.com/facebookresearch/pytorchvideo), but without the `torch` dep. It included the ability to read/write from bytes, as we need to do here. We don't want to be using a sketchy library that I made as a dependency in this repo, though. Would love to use this issue as a place to: - brainstorm ideas on how to do this right - list ways/examples to work around it for now CC @sayakpaul @mariosasko @fcakyon
430
40
Add video feature ### Feature request Add a `Video` feature to the library so folks can include videos in their datasets. ### Motivation Being able to load Video data would be quite helpful. However, there are some challenges when it comes to videos: 1. Videos, unlike images, can end up being extremely large files 2. Often times when training video models, you need to do some very specific sampling. Videos might end up needing to be broken down into X number of clips used for training/inference 3. Videos have an additional audio stream, which must be accounted for 4. The feature needs to be able to encode/decode videos (with right video settings) from bytes. ### Your contribution I did work on this a while back in [this (now closed) PR](https://github.com/huggingface/datasets/pull/4532). It used a library I made called [encoded_video](https://github.com/nateraw/encoded-video), which is basically the utils from [pytorchvideo](https://github.com/facebookresearch/pytorchvideo), but without the `torch` dep. It included the ability to read/write from bytes, as we need to do here. We don't want to be using a sketchy library that I made as a dependency in this repo, though. Would love to use this issue as a place to: - brainstorm ideas on how to do this right - list ways/examples to work around it for now CC @sayakpaul @mariosasko @fcakyon Also wanted to note I added a PR for video classification in `transformers` here, which uses `decord`. It's still open...should we make a decision now to align the libraries we are using between `datasets` and `transformers`? (CC @Narsil ) https://github.com/huggingface/transformers/pull/20151
[ -1.2164283990859985, -0.9488006234169006, -0.8363174200057983, 1.4827109575271606, -0.10483892261981964, -1.2311762571334839, 0.11534338444471359, -1.0742864608764648, 1.6302716732025146, -0.7801726460456848, 0.3693317174911499, -1.6465158462524414, 0.06659001857042313, -0.6112323999404907, -0.7936856746673584, -0.8099918365478516, -0.38308167457580566, -0.7351099848747253, 0.9768102765083313, 2.5439345836639404, 1.2065304517745972, -1.4478000402450562, 2.643900156021118, 0.7606106996536255, -0.22611543536186218, -1.0272165536880493, 0.45367416739463806, 0.07136813551187515, -1.2588709592819214, -0.5033272504806519, -0.9176376461982727, -0.0382208414375782, -0.5613905191421509, -0.5243373513221741, 0.007217154838144779, 0.41850921511650085, -0.2545551061630249, -0.34919556975364685, -0.6076741218566895, -0.7355043292045593, 0.4780050218105316, -0.3674565255641937, 0.9704223275184631, -0.26515355706214905, 1.761620283126831, -0.5733422040939331, 0.4660402536392212, 0.6741342544555664, 1.4014523029327393, 0.20633143186569214, -0.013088524341583252, 0.24518457055091858, 0.43603187799453735, -0.0820089653134346, 0.4671119451522827, 1.1717077493667603, 0.6985254883766174, 0.5294385552406311, 0.7124664187431335, -2.2211875915527344, 1.2893575429916382, -1.0041745901107788, 0.3297387957572937, 1.3229416608810425, -0.8993902206420898, 0.35661816596984863, -1.791933298110962, -0.08800718188285828, 0.5642103552818298, -2.246694326400757, 0.2091369926929474, -1.2846940755844116, -0.46916839480400085, 1.0034862756729126, 0.3004564642906189, -1.2914128303527832, 0.2093067467212677, -0.4190274477005005, 0.9928816556930542, 0.4292081594467163, 1.1940733194351196, -1.6405036449432373, -0.005252552218735218, -0.21964401006698608, 0.12350604683160782, -1.178519368171692, -1.52997624874115, 0.4845450818538666, 0.5996297001838684, 0.5399847626686096, -0.07886788249015808, 0.9233785271644592, -0.9982569217681885, 0.8185703754425049, -0.953122615814209, -1.6715478897094727, -1.3716974258422852, -2.2438805103302, -2.350184202194214, 0.8004736304283142, -0.4709106981754303, -0.4824911952018738, 2.0136702060699463, -1.0430550575256348, -1.8329533338546753, 1.1048022508621216, 0.3451519310474396, 0.04525493457913399, 2.3859169483184814, 0.15723377466201782, -0.7083529233932495, 0.4973967671394348, -0.7191120386123657, 0.8444947600364685, -0.5103802680969238, 1.3573859930038452, 0.46243059635162354, -0.9860184788703918, 1.6370829343795776, -0.4000912606716156, 0.5522299408912659, -0.764186680316925, -0.45599180459976196, -0.7843623161315918, 0.38529255986213684, 1.8681681156158447, -0.31794923543930054, 1.5587482452392578, -0.38960063457489014, -1.5937649011611938, -1.5538872480392456, 0.8478279113769531, 0.517002522945404, -0.7863031029701233, 0.09056961536407471, -0.3717949390411377, 0.12822341918945312, -0.036432042717933655, 1.114449381828308, 1.3270390033721924, 0.6963688731193542, -0.312624990940094, -0.9276016354560852, 0.2151026427745819, -0.14115867018699646, -0.7033997178077698, -1.8056268692016602, -0.35115355253219604, 0.23362648487091064, 0.6716124415397644, -1.2176285982131958, 1.7504923343658447, 0.9054086804389954, 1.9512250423431396, 0.9773074984550476, -0.4153168201446533, 1.502872347831726, 0.027373116463422775, 1.8941751718521118, -0.5102015733718872, 0.6856228113174438, -0.4029427766799927, -1.1398612260818481, 0.8557736873626709, -0.3661947548389435, -1.996957778930664, -0.6675293445587158, -0.7976119518280029, -0.19204014539718628, -0.7287304401397705, 0.9030157923698425, -0.20780527591705322, -1.3366502523422241, 0.24925416707992554, -0.6896860003471375, 0.16607362031936646, -1.2272992134094238, 0.29716160893440247, 0.7743532061576843, -0.6767648458480835, 0.033005427569150925, -0.299517959356308, -1.3388800621032715, -0.5134766697883606, 0.3389689028263092, 1.8634028434753418, -0.7344303131103516, 0.8820054531097412, 0.9969004392623901, -0.7102377414703369, 0.036271147429943085, 0.40633654594421387, -0.35423600673675537, 0.8395677804946899, -1.109521508216858, -0.42369478940963745, 1.20384681224823, -0.19180363416671753, -0.5820927619934082, 1.4177227020263672, 0.8030349612236023, -0.9559552073478699, -0.20403873920440674, -0.14299124479293823, -0.7941251397132874, 0.043128013610839844, -1.6058883666992188, -0.15664342045783997, 0.3208121061325073, -1.5123497247695923, -0.4927231967449188, -0.2641303539276123, 1.2269762754440308, -0.2198827862739563, 1.4571051597595215, -0.28340181708335876, -0.2412060797214508, -0.3758597671985626, -0.41501012444496155, 0.08862511068582535, -0.24045181274414062, -0.594140350818634, 0.2856723964214325, -0.7955052852630615, 0.4129388630390167, 1.432701826095581, 0.33602410554885864, 0.03302212804555893, 0.4591398239135742, 1.068581461906433, 0.4251953065395355, -0.03501707315444946, -0.8635690212249756, -1.5021203756332397, 2.013258934020996, -1.4844112396240234, 1.9858814477920532, 0.8272808790206909, -0.010831177234649658, -1.778437852859497, -1.8523695468902588, 1.3638954162597656, 1.1553248167037964, 2.4420831203460693, 0.5843471884727478, 0.36166125535964966, -0.7714975476264954, -0.6107798218727112, 0.37177562713623047, -1.0582261085510254, -0.8413466811180115, 0.06815622001886368, 2.399170398712158, 1.7852033376693726, -0.5168523788452148, -0.26243308186531067, -1.0359736680984497, 1.3935256004333496, -0.1516415774822235, 0.14801910519599915, 2.0426578521728516, -0.2169179916381836, -1.0400334596633911, 1.3214857578277588, -2.3837740421295166, 0.15337970852851868, 1.9873462915420532, 0.2690749764442444, 0.07755368947982788, -1.4061115980148315, -0.6240572929382324, -0.2475355863571167, -0.3818846344947815, -1.1975451707839966, 0.6063326001167297, -0.19557887315750122, -0.8170468211174011, -1.5004228353500366, 0.10272196680307388, -1.1655128002166748, -1.6855942010879517, 0.28619852662086487, 1.8473567962646484, 2.0095558166503906, -0.7806305289268494, 1.5113285779953003, -0.1853882074356079, 0.08364418894052505, 1.3261454105377197, 1.214599847793579, 3.1747236251831055, 1.9500138759613037, -1.3005541563034058, 0.6676350831985474, -0.1948353350162506, -0.5213848948478699, 1.1560896635055542, -1.1269253492355347, 1.1974388360977173, -0.1915242075920105, -1.2049325704574585, -1.2495832443237305, 0.9752916097640991, 0.45207372307777405, 0.12133390456438065, -0.5270869731903076, 1.1535332202911377, 0.1739126741886139, 1.2680106163024902, 0.5707759261131287, -0.34288325905799866, 0.6538030505180359, -0.42783308029174805, -0.488398015499115, 1.5982322692871094, 0.17743146419525146, -1.4896446466445923, -2.290787696838379, -0.18028461933135986, -0.8801698684692383, -0.06621856987476349, -0.6276416182518005, -0.9947932362556458, 1.5934504270553589, 0.5064502954483032, -1.318855881690979, -0.30152836441993713, -0.3021150231361389, -0.6398243308067322, 2.6359689235687256, -1.4501405954360962, -0.2827695608139038, -1.0453206300735474, -0.5656481385231018, 1.5989928245544434, -1.180538296699524, -0.20378395915031433, -1.0086932182312012, -0.6118745803833008, -1.2930659055709839, -0.5300963521003723, -0.006275421939790249, -0.8392757773399353, 0.6823411583900452, 0.10948708653450012, -1.1901646852493286, -0.33359915018081665, -0.8504757285118103, 0.8023436665534973, -0.07863035798072815, 0.28737032413482666, 1.9283418655395508, 0.4288564622402191, -0.39945656061172485, 0.6942691206932068, 1.203627347946167, 0.5275941491127014, -0.6104888319969177, 0.24521797895431519, -0.6784780621528625, 0.3243255615234375, -1.3663809299468994, 0.3391478359699249, -2.8010408878326416, 0.6995485424995422, -0.06946119666099548, -0.1594301462173462, 0.007928149774670601, -1.2991935014724731, 1.1573491096496582, 2.6732192039489746, -1.1742653846740723, 0.4623182415962219, 0.33346861600875854, 1.1868047714233398, -1.5552650690078735, 0.35261446237564087, -0.36194440722465515, 2.130300521850586, 0.20442834496498108, 1.1517157554626465, -0.521929144859314, -2.2669787406921387, 0.5478745698928833, -1.206686019897461, -1.1388229131698608, 0.8186839818954468, -0.8334712982177734, -0.01192384585738182, -1.4520890712738037, -0.1279500126838684, -0.8452324867248535, -1.2423933744430542, 0.7312714457511902, 0.06267853826284409, 0.4464387595653534, -0.6437765955924988, 0.3356401324272156, -2.1706089973449707, -1.364770770072937, -0.2498779296875, -0.9377288222312927, 0.42930394411087036, -0.2941664457321167, 0.696046769618988, -0.13645625114440918, 0.001082337461411953, 0.29606252908706665, 1.3821933269500732, 3.387148857116699, 0.24646273255348206, 0.45446205139160156, -0.1954321265220642, -0.9393750429153442, 1.4049553871154785, 0.9748252630233765, -0.08575505018234253, -0.5865616202354431, -0.9599305987358093, 1.2482162714004517, 1.9499428272247314, 1.0482361316680908, 0.11347471922636032, -0.8347411751747131, -0.7677690386772156, -0.034027695655822754, 0.1378357708454132, 0.3945007920265198, 1.0292662382125854, 0.05370781198143959, 0.09585592150688171, 1.3937352895736694, 1.2499595880508423, -0.4117136001586914, 0.3741261959075928, -0.8313947916030884, -0.3983055055141449, 0.41079652309417725, 0.3799227178096771, 0.03478438779711723, 0.3768497705459595, -0.9721364974975586, -0.2896668612957001, -0.36716940999031067, -0.9596835374832153, -0.7731499075889587, -0.435471773147583, -0.2955535650253296, 1.6568477153778076, 0.12722137570381165, -0.4736790657043457, 0.02499346062541008, -0.8454005718231201, -0.06836602091789246, -1.0252209901809692, 0.24363064765930176, -0.07047023624181747, -0.09492304921150208, -0.020174849778413773, 1.7865980863571167, -0.9553205370903015, -2.113770008087158, 0.3189093768596649, 0.20991173386573792, -0.42478999495506287, 0.2189052402973175, 1.6625896692276, 0.5308647155761719, 1.416357398033142, 1.2971597909927368, 1.0409979820251465, -0.690139889717102, -1.251376986503601, 0.7785707712173462, 0.9370702505111694, -1.4272874593734741, 0.8023580312728882, 0.020933493971824646, -0.4332799017429352, 0.6625998616218567, 1.2054600715637207, 0.36119142174720764, -1.9931763410568237, 0.727497935295105, -0.8608435988426208, 0.765257716178894, 0.6443974375724792, 0.6800268888473511, 0.233510822057724, 0.7571199536323547, -1.2456666231155396, -1.123409628868103, -0.7479282021522522, -0.6532506942749023, 1.9731745719909668, -0.22664034366607666, 0.6122857928276062, -0.12197782844305038, -1.3666059970855713, -0.13516202569007874, 0.74198979139328, 0.2950191795825958, -0.5334398150444031, 0.8180741667747498, -0.6217469573020935, -1.0649749040603638, -1.3563058376312256, -0.48389577865600586, -1.0115258693695068, -0.8903021812438965, 1.0361013412475586, 0.8572767972946167, 0.28049200773239136, 1.9428097009658813, 0.5799643993377686, 0.2638629674911499, -2.6953818798065186, 0.9157149195671082, 0.3499657213687897, -0.07954530417919159, 0.9323158264160156, 0.3270963132381439, 1.0517125129699707, -0.07991276681423187, 0.5622349977493286, -2.4155220985412598, 2.3452253341674805, -0.19229060411453247, 0.6980605721473694, -0.009330760687589645, -0.17742908000946045, 1.1459320783615112, 0.5655573606491089, 0.5740668177604675, -1.141964077949524, 0.6409037709236145, -0.5470046997070312, 1.2207839488983154, 0.8613839149475098, -0.8486694097518921, -0.02301761507987976, 1.3372058868408203, 0.4288691282272339, -0.4710237383842468, -0.8965079188346863, -0.9100003838539124, 0.9749037623405457, 1.7576769590377808, -0.05365142971277237, -0.0005296715535223484, 0.870322585105896, 0.6508055329322815, -1.3336279392242432, 0.03347719460725784, -0.7806918025016785, -0.7783661484718323, 1.6375428438186646, 1.9582427740097046, -0.04488636925816536, -0.2551502585411072, -0.7571331858634949, -1.2888354063034058, 0.7347978353500366, 0.03462780639529228, 0.15192392468452454, 0.7008951306343079, -0.6745739579200745, 1.1637108325958252, 0.8778737187385559, 0.9233148694038391, 0.08338027447462082, 0.27044323086738586, 0.3545396029949188, -0.4137614667415619, -1.132159948348999, -0.27533194422721863, -1.1869350671768188, -2.4595437049865723, 0.47655367851257324, -0.18651211261749268, -1.4527587890625, 0.030353259295225143, -1.0549254417419434, 0.8578149080276489, -0.6044010519981384, -1.122288465499878, -1.5718210935592651, 0.24744156002998352, -0.19906139373779297, 0.9335834383964539, -1.5721968412399292, -0.04153716191649437, 1.1365965604782104, 0.884087085723877, -0.6187182068824768, 0.9968761205673218, 0.21875980496406555, 1.011085033416748, 0.8800494074821472, -0.37912890315055847, 0.4604215621948242, 0.11619845777750015, -1.3181946277618408, 0.3719198405742645, 1.1437618732452393, 0.22469472885131836, 1.3639764785766602, -0.5971276760101318, 0.07865767180919647, 0.4244455397129059, -0.5384861826896667, -0.4945530891418457, -0.5275968909263611, 0.7233948111534119, 0.08077032119035721, -0.9454256296157837, 0.021426020190119743, -0.11890903115272522, -0.24286004900932312, 0.17438724637031555, -1.5416953563690186, -0.17703887820243835, -0.33897048234939575, -0.5609872341156006, -1.2606347799301147, -0.014031289145350456, 1.3585647344589233, -0.8379554152488708, -0.13977551460266113, 0.5178278684616089, 0.36722439527511597, 0.5140672922134399, 0.5833688974380493, -0.5946727395057678, -0.4105750322341919, -0.18701449036598206, -0.3799731731414795, 0.3501012325286865, 1.3136005401611328, -0.07746060937643051, -0.9961825609207153, 0.7667598724365234, -0.45197415351867676, 0.10716035962104797, 1.9221144914627075, 0.038223206996917725, -0.8043169379234314, 0.35145777463912964, -0.6393350958824158, 1.8763988018035889, 1.780961275100708, 1.2705907821655273, -0.10750699788331985, -0.9216635227203369, 0.6676476001739502, -0.2996556758880615, -0.3479245603084564, 0.9300349354743958, 0.32345467805862427, -0.23129555583000183, -1.4613946676254272, 0.517719030380249, 1.3107762336730957, -0.888810396194458, -0.8134627938270569, 0.0576530396938324, -0.9046174883842468, 1.1132639646530151, 0.7262999415397644, 0.37015077471733093, 0.20127177238464355, 1.6070505380630493, 0.7835949659347534, -0.4829525649547577, 0.520808756351471, 0.5317574739456177, -0.13323158025741577, -2.136430263519287, -1.1346560716629028, 0.23302048444747925, -0.3834046721458435, -1.5651744604110718, 1.3032602071762085, -1.232742190361023, -0.9518796801567078, 0.550361156463623, 0.08633579313755035, 1.4520617723464966, 0.31067442893981934, 1.5405904054641724, 2.140695333480835, 0.8396304845809937, 0.33239665627479553, 1.260247826576233, -0.12458329647779465, -0.4451546370983124, 1.819568395614624, -0.44407692551612854, 0.5372058153152466, 1.0733532905578613, -0.36103934049606323, -1.0622910261154175, -0.7994034886360168, -1.170755386352539, -0.7312458753585815, 1.3156216144561768, 0.1100519448518753, -1.098480463027954, 0.2843831479549408, 1.6581268310546875, 0.08406008780002594, -0.3344699740409851, 0.5789232850074768, 0.4867093563079834, -0.7902978658676147, -0.0053853560239076614, -0.8616761565208435, 0.5482215285301208, -0.15182369947433472, -0.3070842921733856, 0.3706270754337311, 0.46022453904151917, 1.2272584438323975, -0.008663186803460121, 0.04984711855649948, 1.1190608739852905, -1.4565966129302979, 1.575713872909546, -0.6218260526657104, 0.29448118805885315, -2.3379387855529785, 1.4545692205429077, -0.7734988331794739, 1.8921151161193848, -2.640070676803589, 0.35918501019477844, -0.6232531070709229, -0.5656688809394836, 0.29970720410346985, -0.39139294624328613, 0.14465025067329407, -0.21167075634002686, -1.0571383237838745, -0.16944250464439392, -0.6764439344406128, 0.5485349893569946, 1.1632269620895386, 1.3054530620574951, -1.1231155395507812, -0.3042733371257782, -1.7659484148025513, -0.10575486719608307, -0.6361775398254395, 0.29722508788108826, -1.995890736579895, -0.13529270887374878, -1.9491075277328491, -2.274505853652954, -1.3744487762451172, -0.8166463375091553, 1.0572209358215332, 0.1390075385570526, -0.8372814059257507, 1.1468477249145508, -0.3634953200817108, -1.8791887760162354, 1.0697951316833496, -2.1846675872802734 ]
https://github.com/huggingface/datasets/issues/5225
Add video feature
Fully agree on at least trying to unite things. Making clear function boundaries to help us change dependency if needed seems like a good idea since there doesn't seem to be a clear winner. I also happen to like directly calling ffmpeg. For some reason it was a lot faster than pyav.
### Feature request Add a `Video` feature to the library so folks can include videos in their datasets. ### Motivation Being able to load Video data would be quite helpful. However, there are some challenges when it comes to videos: 1. Videos, unlike images, can end up being extremely large files 2. Often times when training video models, you need to do some very specific sampling. Videos might end up needing to be broken down into X number of clips used for training/inference 3. Videos have an additional audio stream, which must be accounted for 4. The feature needs to be able to encode/decode videos (with right video settings) from bytes. ### Your contribution I did work on this a while back in [this (now closed) PR](https://github.com/huggingface/datasets/pull/4532). It used a library I made called [encoded_video](https://github.com/nateraw/encoded-video), which is basically the utils from [pytorchvideo](https://github.com/facebookresearch/pytorchvideo), but without the `torch` dep. It included the ability to read/write from bytes, as we need to do here. We don't want to be using a sketchy library that I made as a dependency in this repo, though. Would love to use this issue as a place to: - brainstorm ideas on how to do this right - list ways/examples to work around it for now CC @sayakpaul @mariosasko @fcakyon
430
52
Add video feature ### Feature request Add a `Video` feature to the library so folks can include videos in their datasets. ### Motivation Being able to load Video data would be quite helpful. However, there are some challenges when it comes to videos: 1. Videos, unlike images, can end up being extremely large files 2. Often times when training video models, you need to do some very specific sampling. Videos might end up needing to be broken down into X number of clips used for training/inference 3. Videos have an additional audio stream, which must be accounted for 4. The feature needs to be able to encode/decode videos (with right video settings) from bytes. ### Your contribution I did work on this a while back in [this (now closed) PR](https://github.com/huggingface/datasets/pull/4532). It used a library I made called [encoded_video](https://github.com/nateraw/encoded-video), which is basically the utils from [pytorchvideo](https://github.com/facebookresearch/pytorchvideo), but without the `torch` dep. It included the ability to read/write from bytes, as we need to do here. We don't want to be using a sketchy library that I made as a dependency in this repo, though. Would love to use this issue as a place to: - brainstorm ideas on how to do this right - list ways/examples to work around it for now CC @sayakpaul @mariosasko @fcakyon Fully agree on at least trying to unite things. Making clear function boundaries to help us change dependency if needed seems like a good idea since there doesn't seem to be a clear winner. I also happen to like directly calling ffmpeg. For some reason it was a lot faster than pyav.
[ -1.2376718521118164, -0.9653905630111694, -0.8213478922843933, 1.4740958213806152, -0.12996472418308258, -1.1923750638961792, 0.08681153506040573, -1.0805485248565674, 1.63386869430542, -0.7684857845306396, 0.4000479578971863, -1.621155023574829, 0.09476523846387863, -0.5747378468513489, -0.7521423697471619, -0.8173628449440002, -0.38569849729537964, -0.7538166642189026, 1.0046420097351074, 2.556253433227539, 1.1437042951583862, -1.4883943796157837, 2.6639652252197266, 0.7552827596664429, -0.194499209523201, -1.030798316001892, 0.4486636221408844, 0.09259124100208282, -1.268416166305542, -0.4881531596183777, -0.9020068645477295, -0.02798762544989586, -0.5715528130531311, -0.4933837354183197, 0.02359875664114952, 0.38385045528411865, -0.23392702639102936, -0.33123043179512024, -0.6272479891777039, -0.7028913497924805, 0.4798164963722229, -0.38333210349082947, 0.9857060313224792, -0.2529851198196411, 1.7668851613998413, -0.5707018375396729, 0.4620487689971924, 0.6810317635536194, 1.3914343118667603, 0.22136163711547852, -0.004367415327578783, 0.25074175000190735, 0.45217183232307434, -0.09337537735700607, 0.47652626037597656, 1.1429457664489746, 0.705649733543396, 0.537459671497345, 0.6710095405578613, -2.178612232208252, 1.336416244506836, -1.0507982969284058, 0.32044681906700134, 1.3177053928375244, -0.9132614731788635, 0.41199594736099243, -1.7592295408248901, -0.102037712931633, 0.5976131558418274, -2.2501978874206543, 0.2022581249475479, -1.251147747039795, -0.48168206214904785, 1.0041342973709106, 0.29495298862457275, -1.2899978160858154, 0.20905455946922302, -0.4575154781341553, 0.9691370725631714, 0.40797922015190125, 1.1935213804244995, -1.6333863735198975, 0.06096651405096054, -0.22293975949287415, 0.13162578642368317, -1.221975326538086, -1.527428150177002, 0.5130481719970703, 0.5905755162239075, 0.5439178943634033, -0.057844456285238266, 0.9225549697875977, -1.0321500301361084, 0.8096926212310791, -0.9494941830635071, -1.642470359802246, -1.3622359037399292, -2.290444850921631, -2.366344690322876, 0.8169283270835876, -0.46019446849823, -0.5070229172706604, 2.0309510231018066, -1.062099575996399, -1.8136829137802124, 1.1541459560394287, 0.32158127427101135, 0.022915583103895187, 2.4086532592773438, 0.13314701616764069, -0.7078637480735779, 0.5068936944007874, -0.7360435128211975, 0.9081872701644897, -0.5446543097496033, 1.3350547552108765, 0.47313523292541504, -0.9576359391212463, 1.6111676692962646, -0.41356924176216125, 0.5259706974029541, -0.7175687551498413, -0.4907057583332062, -0.7911960482597351, 0.41475799679756165, 1.8950879573822021, -0.30195486545562744, 1.5789777040481567, -0.38498151302337646, -1.5757651329040527, -1.5533576011657715, 0.8545114398002625, 0.499538391828537, -0.8264575004577637, 0.09455017000436783, -0.3737824261188507, 0.12796977162361145, -0.01114300824701786, 1.0980538129806519, 1.2748099565505981, 0.6842519044876099, -0.32173413038253784, -0.969623327255249, 0.20292934775352478, -0.15125638246536255, -0.6841545104980469, -1.8376818895339966, -0.3534870743751526, 0.190032958984375, 0.6740120053291321, -1.2537049055099487, 1.744968056678772, 0.9184158444404602, 1.9421958923339844, 0.9840219020843506, -0.4012759327888489, 1.5046608448028564, 0.034554582089185715, 1.8473061323165894, -0.5101492404937744, 0.6984803080558777, -0.38964688777923584, -1.1579958200454712, 0.8244100213050842, -0.4089299142360687, -1.9993176460266113, -0.6724637150764465, -0.7757715582847595, -0.21363742649555206, -0.7204160094261169, 0.909277081489563, -0.22416050732135773, -1.3408160209655762, 0.2558612525463104, -0.6804205179214478, 0.16230803728103638, -1.2269443273544312, 0.29561227560043335, 0.7547699213027954, -0.673106849193573, 0.04739303141832352, -0.3052644431591034, -1.335841178894043, -0.47716525197029114, 0.29557231068611145, 1.8548080921173096, -0.7399488687515259, 0.8777454495429993, 0.9804225564002991, -0.667948305606842, 0.030576925724744797, 0.40615326166152954, -0.36223551630973816, 0.8528637886047363, -1.0889105796813965, -0.44222912192344666, 1.1955560445785522, -0.2028379589319229, -0.5452337861061096, 1.4017324447631836, 0.7591269612312317, -0.9766044616699219, -0.22882094979286194, -0.14088822901248932, -0.8516843318939209, 0.049828894436359406, -1.6217777729034424, -0.1801249235868454, 0.3136758506298065, -1.5163986682891846, -0.4434830844402313, -0.2659550607204437, 1.184386968612671, -0.24404433369636536, 1.4488255977630615, -0.31431078910827637, -0.2195596843957901, -0.38070201873779297, -0.43173420429229736, 0.12588036060333252, -0.20681563019752502, -0.6014699339866638, 0.2673299312591553, -0.816278874874115, 0.40253138542175293, 1.4344581365585327, 0.3254162073135376, 0.037706706672906876, 0.4506981670856476, 1.0389198064804077, 0.40195485949516296, -0.041911859065294266, -0.8658506870269775, -1.5095409154891968, 2.0255980491638184, -1.4813270568847656, 2.0047872066497803, 0.9087366461753845, -0.017232898622751236, -1.780392050743103, -1.8378173112869263, 1.329184651374817, 1.1766934394836426, 2.4163503646850586, 0.5678210854530334, 0.3616119623184204, -0.7926715016365051, -0.6208748817443848, 0.35043540596961975, -1.0566316843032837, -0.8519545793533325, 0.06473805755376816, 2.398914337158203, 1.767914056777954, -0.49891871213912964, -0.24307285249233246, -1.012969732284546, 1.418613076210022, -0.1597033143043518, 0.16147902607917786, 2.043915271759033, -0.22064149379730225, -1.0547540187835693, 1.3076590299606323, -2.4140238761901855, 0.14244291186332703, 1.9721094369888306, 0.295900821685791, 0.0842178612947464, -1.412811040878296, -0.6422128081321716, -0.26032739877700806, -0.34754475951194763, -1.1839556694030762, 0.6187079548835754, -0.22994975745677948, -0.8181647062301636, -1.5240697860717773, 0.0998922809958458, -1.197649359703064, -1.665399193763733, 0.26875168085098267, 1.8165653944015503, 2.040510892868042, -0.8022577166557312, 1.4985523223876953, -0.20322713255882263, 0.03853482007980347, 1.2915475368499756, 1.1911544799804688, 3.1606075763702393, 1.906868577003479, -1.277694582939148, 0.6287000179290771, -0.18399299681186676, -0.5283137559890747, 1.1567881107330322, -1.1226942539215088, 1.2076728343963623, -0.16069157421588898, -1.1869715452194214, -1.248909592628479, 0.9661468267440796, 0.4503662586212158, 0.10987824946641922, -0.5103346705436707, 1.1607869863510132, 0.17765015363693237, 1.2835116386413574, 0.5364459156990051, -0.3169786334037781, 0.6193031668663025, -0.42501965165138245, -0.5040127038955688, 1.5780291557312012, 0.17078128457069397, -1.5112769603729248, -2.2721173763275146, -0.17856457829475403, -0.8440881967544556, -0.057179611176252365, -0.619434654712677, -1.0120803117752075, 1.5638577938079834, 0.4519767463207245, -1.3402371406555176, -0.3039982318878174, -0.3093312084674835, -0.6662780046463013, 2.629453420639038, -1.4697089195251465, -0.3084031045436859, -1.0186614990234375, -0.5316101908683777, 1.5827057361602783, -1.1885796785354614, -0.17466767132282257, -1.0211583375930786, -0.582955539226532, -1.300602912902832, -0.5216231346130371, 0.006296747364103794, -0.8710591793060303, 0.673143208026886, 0.11556009203195572, -1.167238473892212, -0.3475281894207001, -0.825842559337616, 0.7603612542152405, -0.06655009835958481, 0.3212028443813324, 1.9111981391906738, 0.3982902765274048, -0.40584033727645874, 0.7179371118545532, 1.2252119779586792, 0.5627716779708862, -0.6394663453102112, 0.2184448391199112, -0.6899125576019287, 0.3309464752674103, -1.3576037883758545, 0.33861207962036133, -2.8356714248657227, 0.6963039636611938, -0.030873313546180725, -0.17126041650772095, 0.029814675450325012, -1.295446515083313, 1.149900197982788, 2.665173053741455, -1.1605504751205444, 0.4625434875488281, 0.3184587061405182, 1.1663880348205566, -1.5693624019622803, 0.3586561977863312, -0.3414568305015564, 2.107948064804077, 0.24503615498542786, 1.1359676122665405, -0.5437567830085754, -2.2922205924987793, 0.5639045238494873, -1.23048996925354, -1.1414728164672852, 0.8338626027107239, -0.837647557258606, 0.00521751306951046, -1.4590486288070679, -0.13670720160007477, -0.8455387949943542, -1.2445000410079956, 0.7098796963691711, 0.07613182812929153, 0.432891845703125, -0.6213681101799011, 0.33809319138526917, -2.221179962158203, -1.3871086835861206, -0.21940018236637115, -0.9768638014793396, 0.4548832178115845, -0.3375856578350067, 0.6768591403961182, -0.16248515248298645, 0.018620606511831284, 0.3042007386684418, 1.3756872415542603, 3.4281136989593506, 0.24913248419761658, 0.47253936529159546, -0.19046297669410706, -0.9318723082542419, 1.4074636697769165, 0.9586590528488159, -0.08811406046152115, -0.6021607518196106, -0.9687585234642029, 1.2921992540359497, 1.9532390832901, 1.0073233842849731, 0.08099956065416336, -0.7978516817092896, -0.7316750884056091, -0.05341426655650139, 0.15435628592967987, 0.38848045468330383, 1.0410668849945068, 0.02521844208240509, 0.10668037086725235, 1.4224501848220825, 1.289281964302063, -0.4369460940361023, 0.36171576380729675, -0.800987184047699, -0.388265997171402, 0.42264702916145325, 0.36755937337875366, 0.029171977192163467, 0.38905665278434753, -0.9566476941108704, -0.29942405223846436, -0.39571207761764526, -0.9756816625595093, -0.7807345986366272, -0.39564433693885803, -0.3277728259563446, 1.672187089920044, 0.16260503232479095, -0.4612586200237274, 0.030073512345552444, -0.8500475883483887, -0.07801403105258942, -1.0277751684188843, 0.2308434098958969, -0.04371601715683937, -0.12513914704322815, -0.04081257805228233, 1.8264975547790527, -0.9393495917320251, -2.0960464477539062, 0.2998991906642914, 0.20469097793102264, -0.37353116273880005, 0.19992919266223907, 1.6703871488571167, 0.5024421215057373, 1.4374241828918457, 1.2862929105758667, 1.0178968906402588, -0.6946966648101807, -1.2687098979949951, 0.7535786628723145, 0.9376620650291443, -1.4390137195587158, 0.815022349357605, 0.017056185752153397, -0.4623526632785797, 0.6760392785072327, 1.222567081451416, 0.37871766090393066, -1.9691922664642334, 0.7473670840263367, -0.8922247886657715, 0.7742044925689697, 0.6635980606079102, 0.6719390749931335, 0.2175500988960266, 0.7429105043411255, -1.2257256507873535, -1.1134250164031982, -0.7806132435798645, -0.6332594752311707, 1.9953356981277466, -0.25407078862190247, 0.6232515573501587, -0.13829712569713593, -1.3680976629257202, -0.1335681974887848, 0.7250102758407593, 0.3112802505493164, -0.5170230269432068, 0.8732287883758545, -0.6529266834259033, -1.1156222820281982, -1.3863823413848877, -0.46079355478286743, -0.9742981195449829, -0.8899316191673279, 1.0461876392364502, 0.8416268825531006, 0.2686183452606201, 1.942539095878601, 0.5896545052528381, 0.25762417912483215, -2.707822322845459, 0.9326173067092896, 0.31031298637390137, -0.0685640200972557, 0.931113064289093, 0.3120822310447693, 1.0419034957885742, -0.055963702499866486, 0.5517098903656006, -2.4096648693084717, 2.349210262298584, -0.19211702048778534, 0.7410038709640503, -0.005525575019419193, -0.1845511943101883, 1.1320010423660278, 0.601496696472168, 0.5829465389251709, -1.1383588314056396, 0.6241542100906372, -0.514886200428009, 1.2592805624008179, 0.8960546255111694, -0.8128984570503235, -0.01769658923149109, 1.2982250452041626, 0.4251438081264496, -0.4699876308441162, -0.9019282460212708, -0.893578290939331, 0.9629587531089783, 1.775383710861206, -0.04522381350398064, -0.009491682052612305, 0.8353790640830994, 0.6391914486885071, -1.3108495473861694, 0.041114792227745056, -0.7965621948242188, -0.810939610004425, 1.6426371335983276, 1.9754220247268677, -0.03928455710411072, -0.27909716963768005, -0.6955751180648804, -1.2984888553619385, 0.729560136795044, 0.05415064096450806, 0.19777867197990417, 0.6835458874702454, -0.6505538821220398, 1.1497712135314941, 0.8706952333450317, 0.9207084774971008, 0.08802315592765808, 0.2290622442960739, 0.3414936065673828, -0.38861027359962463, -1.1230852603912354, -0.28310051560401917, -1.1883364915847778, -2.486647129058838, 0.4593130648136139, -0.197255477309227, -1.4748117923736572, 0.020818959921598434, -1.045027732849121, 0.8625981211662292, -0.579498291015625, -1.0899477005004883, -1.5955897569656372, 0.26112765073776245, -0.1903429925441742, 0.9522634148597717, -1.5764362812042236, -0.05586513131856918, 1.124632477760315, 0.8996917009353638, -0.6060653924942017, 1.0193156003952026, 0.21231766045093536, 1.0153976678848267, 0.8493515849113464, -0.3644099831581116, 0.4748642146587372, 0.13264597952365875, -1.321341872215271, 0.3753712773323059, 1.134377360343933, 0.2202291637659073, 1.338367223739624, -0.581922173500061, 0.09492216259241104, 0.42738789319992065, -0.5502156019210815, -0.4396629333496094, -0.48584988713264465, 0.7377851009368896, 0.07324399799108505, -0.9143991470336914, 0.0019840067252516747, -0.1476820707321167, -0.234752357006073, 0.16392719745635986, -1.5283485651016235, -0.19304974377155304, -0.3781696557998657, -0.5579757690429688, -1.265173316001892, -0.0073230694979429245, 1.3977323770523071, -0.8301233649253845, -0.15218612551689148, 0.5033349394798279, 0.44031772017478943, 0.5310398936271667, 0.6124643683433533, -0.5877655148506165, -0.42909833788871765, -0.16229425370693207, -0.33242303133010864, 0.3279697000980377, 1.323607325553894, -0.08151088654994965, -1.0022860765457153, 0.7587296962738037, -0.4582974910736084, 0.12659965455532074, 1.9181184768676758, 0.04546073451638222, -0.8336864113807678, 0.37406855821609497, -0.645082414150238, 1.8658572435379028, 1.7522417306900024, 1.2609530687332153, -0.10030146688222885, -0.8929347991943359, 0.7073450088500977, -0.2843940854072571, -0.3207673728466034, 0.8932405710220337, 0.33946311473846436, -0.22026024758815765, -1.4663504362106323, 0.5353555679321289, 1.269641399383545, -0.853539228439331, -0.8138201236724854, 0.058027297258377075, -0.8987060785293579, 1.1079373359680176, 0.7210744023323059, 0.40372776985168457, 0.16505898535251617, 1.6465144157409668, 0.7754363417625427, -0.5154231190681458, 0.5501670837402344, 0.5272544026374817, -0.17360256612300873, -2.156306266784668, -1.0953950881958008, 0.23642347753047943, -0.4011231064796448, -1.5456842184066772, 1.3125419616699219, -1.2310653924942017, -0.9189194440841675, 0.5681064128875732, 0.05234616994857788, 1.4285744428634644, 0.29976537823677063, 1.5338122844696045, 2.153238296508789, 0.8626983165740967, 0.31293803453445435, 1.2743226289749146, -0.11596646904945374, -0.4425792694091797, 1.8208513259887695, -0.45449012517929077, 0.5566688776016235, 1.0557466745376587, -0.3793308138847351, -1.019904375076294, -0.777242124080658, -1.132616400718689, -0.7372018694877625, 1.3072823286056519, 0.11737397313117981, -1.0930235385894775, 0.2539869248867035, 1.6668131351470947, 0.07948687672615051, -0.31130528450012207, 0.5794352889060974, 0.48484933376312256, -0.781319260597229, -0.025865301489830017, -0.8599384427070618, 0.5420334339141846, -0.1813896894454956, -0.30281591415405273, 0.3777678906917572, 0.45204612612724304, 1.2258312702178955, 0.012693009339272976, 0.061987072229385376, 1.1296861171722412, -1.4798986911773682, 1.555222749710083, -0.5624188780784607, 0.2873550057411194, -2.3586301803588867, 1.451955795288086, -0.7538905739784241, 1.9234700202941895, -2.630528211593628, 0.37088415026664734, -0.649742066860199, -0.5537855625152588, 0.29571419954299927, -0.38636767864227295, 0.17145514488220215, -0.21388378739356995, -1.0314346551895142, -0.1404220461845398, -0.6741146445274353, 0.5526162385940552, 1.1503876447677612, 1.2693322896957397, -1.1175644397735596, -0.2968659996986389, -1.73121976852417, -0.09853094816207886, -0.6885724067687988, 0.27510833740234375, -1.9923096895217896, -0.1937950700521469, -1.9539728164672852, -2.242892265319824, -1.371509075164795, -0.8056027889251709, 1.06646728515625, 0.1456836313009262, -0.8478151559829712, 1.1741212606430054, -0.3749770224094391, -1.8739603757858276, 1.1041351556777954, -2.1630938053131104 ]
https://github.com/huggingface/datasets/issues/5224
Seems to freeze when loading audio dataset with wav files from local folder
I just tried to do the same but changing the `.wav` files to `.mp3` files and that doesn't fix it.
### Describe the bug I'm following the instructions in [https://huggingface.co/docs/datasets/audio_load#audiofolder-with-metadata](url) to be able to load a dataset from a local folder. I have everything into a folder, into a train folder and then the audios and csv. When I try to load the dataset and run from terminal, seems to work but then freezes with no apparent reason. The metadata.csv file contains a few columns but the important ones, `file_name` with the filename and `transcription` with the transcription are okay. The audios are `.wav` files, I don't know if that might be the problem (I will proceed to try to change them all to `.mp3` and try again). ### Steps to reproduce the bug The code I'm using: ```python from datasets import load_dataset dataset = load_dataset("audiofolder", data_dir="../archive/Dataset") dataset[0]["audio"] ``` The output I obtain: ``` Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 311135.43it/s] Using custom data configuration default-38d4546ffd010f3e Downloading and preparing dataset audiofolder/default to /Users/mine/.cache/huggingface/datasets/audiofolder/default-38d4546ffd010f3e/0.0.0/6cbdd16f8688354c63b4e2a36e1585d05de285023ee6443ffd71c4182055c0fc... Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 166467.72it/s] Using custom data configuration default-38d4546ffd010f3e Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 187772.74it/s] Using custom data configuration default-38d4546ffd010f3e Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 59623.71it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 138090.55it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 106065.64it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 56036.38it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 74004.24it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 162343.45it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 101881.23it/s] Using custom data configuration default-38d4546ffd010f3e Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 60145.67it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 80890.02it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 54036.67it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 95851.09it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 155897.00it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 137656.96it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 131230.81it/s] Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e ``` And then here it just freezes and nothing more happens. ### Expected behavior Load the dataset. ### Environment info Datasets version: datasets 2.6.1 pypi_0 pypi
431
20
Seems to freeze when loading audio dataset with wav files from local folder ### Describe the bug I'm following the instructions in [https://huggingface.co/docs/datasets/audio_load#audiofolder-with-metadata](url) to be able to load a dataset from a local folder. I have everything into a folder, into a train folder and then the audios and csv. When I try to load the dataset and run from terminal, seems to work but then freezes with no apparent reason. The metadata.csv file contains a few columns but the important ones, `file_name` with the filename and `transcription` with the transcription are okay. The audios are `.wav` files, I don't know if that might be the problem (I will proceed to try to change them all to `.mp3` and try again). ### Steps to reproduce the bug The code I'm using: ```python from datasets import load_dataset dataset = load_dataset("audiofolder", data_dir="../archive/Dataset") dataset[0]["audio"] ``` The output I obtain: ``` Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 311135.43it/s] Using custom data configuration default-38d4546ffd010f3e Downloading and preparing dataset audiofolder/default to /Users/mine/.cache/huggingface/datasets/audiofolder/default-38d4546ffd010f3e/0.0.0/6cbdd16f8688354c63b4e2a36e1585d05de285023ee6443ffd71c4182055c0fc... Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 166467.72it/s] Using custom data configuration default-38d4546ffd010f3e Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 187772.74it/s] Using custom data configuration default-38d4546ffd010f3e Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 59623.71it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 138090.55it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 106065.64it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 56036.38it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 74004.24it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 162343.45it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 101881.23it/s] Using custom data configuration default-38d4546ffd010f3e Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 60145.67it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 80890.02it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 54036.67it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 95851.09it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 155897.00it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 137656.96it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 131230.81it/s] Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e ``` And then here it just freezes and nothing more happens. ### Expected behavior Load the dataset. ### Environment info Datasets version: datasets 2.6.1 pypi_0 pypi I just tried to do the same but changing the `.wav` files to `.mp3` files and that doesn't fix it.
[ -1.177045226097107, -0.8611588478088379, -0.809963047504425, 1.3688044548034668, -0.10902983695268631, -1.2759076356887817, 0.11001427471637726, -1.1854735612869263, 1.6254072189331055, -0.7464590668678284, 0.29121655225753784, -1.6808435916900635, 0.027181081473827362, -0.498515248298645, -0.8016663789749146, -0.8814895749092102, -0.4189562499523163, -0.7975467443466187, 0.9734137058258057, 2.576556444168091, 1.1819307804107666, -1.3740915060043335, 2.703252077102661, 0.7239051461219788, -0.1859632134437561, -0.9891704320907593, 0.5566399097442627, 0.04392192140221596, -1.4045166969299316, -0.4226067364215851, -0.9514261484146118, -0.06710577011108398, -0.563116192817688, -0.49857187271118164, 0.04890153929591179, 0.4124694764614105, -0.2684883773326874, -0.43418604135513306, -0.6030599474906921, -0.7632831931114197, 0.4584762752056122, -0.3980419933795929, 0.9903907179832458, -0.29153522849082947, 1.8255106210708618, -0.5477443933486938, 0.4383834898471832, 0.6837046146392822, 1.3526325225830078, 0.18383237719535828, 0.03636850044131279, 0.30702289938926697, 0.4111441671848297, -0.022102106362581253, 0.4487132132053375, 1.1873217821121216, 0.5861096382141113, 0.4318959414958954, 0.7796026468276978, -2.183908700942993, 1.2691999673843384, -0.92335045337677, 0.3109503984451294, 1.3577396869659424, -0.875851035118103, 0.2918130159378052, -1.858930230140686, -0.07699919492006302, 0.5583109855651855, -2.2018327713012695, 0.25284409523010254, -1.298535943031311, -0.48681312799453735, 0.9694587588310242, 0.2680845558643341, -1.2009949684143066, 0.24145746231079102, -0.454656183719635, 1.0463298559188843, 0.46114376187324524, 1.2401801347732544, -1.638676404953003, -0.018473468720912933, -0.31776657700538635, 0.11452723294496536, -1.2939664125442505, -1.5257821083068848, 0.5625008940696716, 0.6303656697273254, 0.6082437038421631, -0.1187739223241806, 1.0496294498443604, -1.0009714365005493, 0.8240001797676086, -0.9319517612457275, -1.7446019649505615, -1.349585771560669, -2.2401580810546875, -2.3362653255462646, 0.8055827617645264, -0.5424256324768066, -0.5162351131439209, 2.021582841873169, -1.0748976469039917, -1.7341970205307007, 1.1392731666564941, 0.26195093989372253, 0.04361569136381149, 2.3581039905548096, 0.2541356682777405, -0.7004566192626953, 0.4971880316734314, -0.6584510207176208, 0.8265178203582764, -0.34116482734680176, 1.3626257181167603, 0.39146143198013306, -0.9876833558082581, 1.6273157596588135, -0.41870617866516113, 0.5464661717414856, -0.701486349105835, -0.5352745056152344, -0.8144261837005615, 0.3283708989620209, 1.9565765857696533, -0.38774439692497253, 1.6817026138305664, -0.32467690110206604, -1.5976893901824951, -1.5105242729187012, 0.8821020722389221, 0.5033664107322693, -0.8383167386054993, 0.040436845272779465, -0.37342599034309387, 0.07527071237564087, -0.03104180097579956, 1.0774834156036377, 1.254411220550537, 0.7123990058898926, -0.30872979760169983, -0.9226701259613037, 0.21465861797332764, -0.08851765096187592, -0.7895652055740356, -1.7368626594543457, -0.2800601124763489, 0.13531431555747986, 0.6503796577453613, -1.2593035697937012, 1.742278814315796, 0.8446279168128967, 1.9866788387298584, 1.0190378427505493, -0.3776298463344574, 1.4673101902008057, 0.1120031550526619, 1.9244210720062256, -0.4926134943962097, 0.6330540180206299, -0.39754828810691833, -1.1159189939498901, 0.8326040506362915, -0.4021669030189514, -2.0363028049468994, -0.7508416175842285, -0.7648869156837463, -0.1812194585800171, -0.7284308075904846, 0.9352673888206482, -0.27501192688941956, -1.468174695968628, 0.2622196674346924, -0.633589506149292, 0.11382907629013062, -1.2499043941497803, 0.26855066418647766, 0.7676485776901245, -0.6567649245262146, 0.009858338162302971, -0.21990260481834412, -1.3281152248382568, -0.44430509209632874, 0.24793130159378052, 1.931482195854187, -0.718754231929779, 0.9295110106468201, 1.0586740970611572, -0.699178159236908, 0.05267930030822754, 0.3247361481189728, -0.38034069538116455, 0.7810860872268677, -1.110992670059204, -0.3830617368221283, 1.1270835399627686, -0.11119364947080612, -0.5107691287994385, 1.415974736213684, 0.7021037340164185, -1.0676454305648804, -0.1933719515800476, -0.15824630856513977, -0.8399246335029602, 0.001848316751420498, -1.5893491506576538, -0.08896313607692719, 0.3286394476890564, -1.5206501483917236, -0.4658382534980774, -0.2284843921661377, 1.1499098539352417, -0.1773463487625122, 1.4294729232788086, -0.35541850328445435, -0.1635727882385254, -0.3556526303291321, -0.4506728947162628, 0.1415404975414276, -0.2302030324935913, -0.6733143329620361, 0.256900817155838, -0.7493028044700623, 0.3446309566497803, 1.4326558113098145, 0.31539809703826904, 0.052949488162994385, 0.4622274935245514, 1.0731852054595947, 0.343759149312973, -0.0274664293974638, -0.7915140986442566, -1.6111760139465332, 2.026930093765259, -1.4853533506393433, 1.9363166093826294, 0.7615849375724792, 0.014589307829737663, -1.8572090864181519, -1.8804179430007935, 1.3816325664520264, 1.1167662143707275, 2.380068778991699, 0.6077806949615479, 0.4139186441898346, -0.7424968481063843, -0.6960543394088745, 0.36031225323677063, -0.8938062787055969, -0.7437651753425598, 0.16037127375602722, 2.370553970336914, 1.7133814096450806, -0.5195774435997009, -0.227789044380188, -0.9292681217193604, 1.3177158832550049, -0.1390528380870819, 0.16058960556983948, 1.9626742601394653, -0.30487918853759766, -1.1091194152832031, 1.2970194816589355, -2.334277629852295, 0.14883357286453247, 2.0353140830993652, 0.23998728394508362, 0.027051925659179688, -1.388466477394104, -0.6595567464828491, -0.27944430708885193, -0.4664936661720276, -1.1971379518508911, 0.5519652962684631, -0.33020657300949097, -0.8477961421012878, -1.482170820236206, 0.07899540662765503, -1.203815221786499, -1.6466306447982788, 0.33875641226768494, 1.8854819536209106, 2.015721321105957, -0.730334997177124, 1.5351228713989258, -0.289363831281662, 0.1344490349292755, 1.1802603006362915, 1.2624555826187134, 3.138875961303711, 1.827347755432129, -1.2500698566436768, 0.6991807818412781, -0.18567430973052979, -0.47686129808425903, 1.165993571281433, -1.086262583732605, 1.2377902269363403, -0.1727743148803711, -1.2409600019454956, -1.2358273267745972, 0.976182222366333, 0.4760851263999939, 0.10522753745317459, -0.5052093863487244, 1.2437653541564941, 0.07453610002994537, 1.229683518409729, 0.5884259343147278, -0.3827056288719177, 0.5507679581642151, -0.358415812253952, -0.5457502603530884, 1.5797603130340576, 0.19285085797309875, -1.354553461074829, -2.4195828437805176, -0.2836788296699524, -0.8610252737998962, 0.02527007833123207, -0.6315411329269409, -1.0324188470840454, 1.6562857627868652, 0.4077802896499634, -1.2881591320037842, -0.28864914178848267, -0.3433673679828644, -0.611627995967865, 2.6285388469696045, -1.4361827373504639, -0.18315809965133667, -0.9376745223999023, -0.5767473578453064, 1.6455023288726807, -1.1558659076690674, -0.23248296976089478, -1.0989640951156616, -0.5565245747566223, -1.3027995824813843, -0.5724326968193054, 0.07232625037431717, -0.9332013130187988, 0.8852264881134033, 0.20113134384155273, -1.1316463947296143, -0.29020416736602783, -0.9665595889091492, 0.9253933429718018, -0.047409042716026306, 0.22905665636062622, 1.8709790706634521, 0.4710407555103302, -0.4556061029434204, 0.683032214641571, 1.2283180952072144, 0.611449658870697, -0.7319052815437317, 0.13512590527534485, -0.765618622303009, 0.2700996398925781, -1.4375399351119995, 0.2829831540584564, -2.8242948055267334, 0.6826815009117126, -0.07488460838794708, -0.07057543098926544, 0.03061816096305847, -1.3091201782226562, 1.0763407945632935, 2.6058552265167236, -1.1702269315719604, 0.49564605951309204, 0.3317403197288513, 1.2305256128311157, -1.5625617504119873, 0.2524462938308716, -0.41135257482528687, 2.027275800704956, 0.12037820369005203, 1.209728717803955, -0.5043249726295471, -2.2223799228668213, 0.6317911148071289, -1.2662651538848877, -1.156360387802124, 0.7918312549591064, -0.8304548859596252, 0.108178049325943, -1.4640419483184814, -0.23190158605575562, -0.9711726307868958, -1.1929011344909668, 0.6910825371742249, 0.1497274935245514, 0.46425318717956543, -0.5563284158706665, 0.30624908208847046, -2.2434518337249756, -1.3905340433120728, -0.1588973104953766, -1.0022101402282715, 0.41920673847198486, -0.3054157495498657, 0.6697402000427246, -0.15955734252929688, 0.04076866805553436, 0.3516070246696472, 1.4231925010681152, 3.4279415607452393, 0.18362995982170105, 0.2956988215446472, -0.1767401397228241, -0.9701099395751953, 1.4370235204696655, 0.8870733380317688, -0.08760349452495575, -0.595485508441925, -1.0425925254821777, 1.174485206604004, 2.0235321521759033, 1.0783324241638184, 0.018247952684760094, -0.772982120513916, -0.6861045956611633, 0.01574110984802246, 0.20903286337852478, 0.4880272448062897, 0.9526862502098083, 0.04596356675028801, 0.06248382478952408, 1.4447602033615112, 1.1550441980361938, -0.41811704635620117, 0.40832605957984924, -0.8227015733718872, -0.4871406853199005, 0.4558883607387543, 0.2971380949020386, 0.04516466334462166, 0.37174782156944275, -1.039376974105835, -0.2948809266090393, -0.42388322949409485, -0.9235021471977234, -0.6542003750801086, -0.43922311067581177, -0.34456387162208557, 1.5765020847320557, 0.10586496442556381, -0.5127415657043457, -0.014520689845085144, -0.718422532081604, -0.0931129977107048, -1.108964443206787, 0.23380446434020996, -0.21747943758964539, -0.052573978900909424, -0.06857572495937347, 1.7697715759277344, -0.9630581140518188, -2.0621883869171143, 0.2213665246963501, 0.2163097858428955, -0.3932340443134308, 0.2367071509361267, 1.6198920011520386, 0.5543076395988464, 1.3867419958114624, 1.3966326713562012, 0.9151023030281067, -0.7038053274154663, -1.3096578121185303, 0.642474353313446, 1.006812572479248, -1.3245726823806763, 0.793375551700592, 0.00548994354903698, -0.5462919473648071, 0.6799790859222412, 1.3920878171920776, 0.3820948302745819, -2.019927978515625, 0.831506609916687, -0.8449352979660034, 0.7078782320022583, 0.6964355111122131, 0.7496566772460938, 0.2377793788909912, 0.8331480026245117, -1.2018908262252808, -1.1543587446212769, -0.7735903263092041, -0.663986325263977, 1.8968284130096436, -0.20658209919929504, 0.5684143304824829, -0.12865370512008667, -1.2043994665145874, -0.07296169549226761, 0.7189001441001892, 0.37391504645347595, -0.4677261710166931, 0.8088794350624084, -0.5964112281799316, -1.142390251159668, -1.3403685092926025, -0.47172823548316956, -1.00417160987854, -0.8353327512741089, 1.0274723768234253, 0.8100610971450806, 0.32342255115509033, 1.9147967100143433, 0.6680358648300171, 0.24837356805801392, -2.698245048522949, 0.8766034245491028, 0.2587394714355469, -0.017878010869026184, 0.909256100654602, 0.3031493127346039, 1.1112550497055054, -0.01979753188788891, 0.5647207498550415, -2.314199209213257, 2.235041618347168, -0.2838687598705292, 0.66267991065979, -0.11605554819107056, -0.1923203468322754, 1.1439744234085083, 0.5520919561386108, 0.5616620779037476, -1.0754539966583252, 0.6887755990028381, -0.6413965821266174, 1.1589767932891846, 0.9345277547836304, -0.880267858505249, 0.013019183650612831, 1.3962963819503784, 0.4614531099796295, -0.45998644828796387, -0.960774838924408, -0.8250517845153809, 0.9563124775886536, 1.7165484428405762, -0.026910215616226196, 0.04554238170385361, 0.9058986306190491, 0.6933000683784485, -1.347892165184021, 0.05896015465259552, -0.7132324576377869, -0.7783219814300537, 1.6964259147644043, 2.0482704639434814, -0.04292907193303108, -0.14976149797439575, -0.7784760594367981, -1.2544708251953125, 0.8019235134124756, -0.08031601458787918, 0.1762838363647461, 0.6112508773803711, -0.7097834944725037, 1.1363753080368042, 0.775414764881134, 0.9799906611442566, 0.13226589560508728, 0.3685321807861328, 0.42502719163894653, -0.3283305764198303, -1.1140917539596558, -0.26952803134918213, -1.1106059551239014, -2.446949005126953, 0.5573897957801819, -0.2635153532028198, -1.5026389360427856, 0.06633615493774414, -0.9746317267417908, 0.9515697956085205, -0.5861446857452393, -1.0831655263900757, -1.472977638244629, 0.31024983525276184, -0.057986848056316376, 0.9762657880783081, -1.6117697954177856, -0.10639739781618118, 1.166332721710205, 0.9515277147293091, -0.6197370290756226, 0.9971116781234741, 0.2627807557582855, 1.0072917938232422, 0.8262597918510437, -0.411201536655426, 0.4348970949649811, 0.05172053724527359, -1.312997817993164, 0.4134186804294586, 1.2028230428695679, 0.19395482540130615, 1.400834083557129, -0.5699542760848999, 0.035912446677684784, 0.4032372236251831, -0.41837242245674133, -0.3798809349536896, -0.5470868945121765, 0.6227719783782959, 0.12889647483825684, -0.913962721824646, -0.09480136632919312, -0.08642558008432388, -0.2607055604457855, 0.19296595454216003, -1.4804891347885132, -0.1984327733516693, -0.4123927056789398, -0.5056923627853394, -1.231001615524292, 0.01599419303238392, 1.3577749729156494, -0.7556585669517517, -0.19675031304359436, 0.44457992911338806, 0.3946242928504944, 0.5218251347541809, 0.6209444999694824, -0.6719030737876892, -0.3112528622150421, -0.3161429166793823, -0.36160439252853394, 0.17523431777954102, 1.3165236711502075, -0.11138859391212463, -0.9844589829444885, 0.7048812508583069, -0.38281431794166565, 0.055963434278964996, 1.9708608388900757, 0.10282006859779358, -0.7545056939125061, 0.3151713013648987, -0.702364981174469, 1.892063021659851, 1.8065481185913086, 1.368569254875183, -0.09252772480249405, -0.9055118560791016, 0.6013420224189758, -0.3207935392856598, -0.3043896555900574, 0.9344643950462341, 0.4374535381793976, -0.11392035335302353, -1.3969749212265015, 0.5722218155860901, 1.2951722145080566, -0.9294453263282776, -0.7376842498779297, 0.08742287755012512, -0.8000909090042114, 1.0963689088821411, 0.7214288115501404, 0.3965560793876648, 0.28156551718711853, 1.6131246089935303, 0.7622761130332947, -0.4887363016605377, 0.5996245741844177, 0.5283762812614441, -0.18764042854309082, -2.081199884414673, -1.087990641593933, 0.30639949440956116, -0.33147311210632324, -1.6400423049926758, 1.3577364683151245, -1.1462068557739258, -0.8769893050193787, 0.5186706781387329, 0.03765149042010307, 1.3788390159606934, 0.4279692769050598, 1.6669836044311523, 2.1602416038513184, 0.8623015284538269, 0.3368256390094757, 1.2806544303894043, -0.06814135611057281, -0.4270018935203552, 1.8475010395050049, -0.4874597489833832, 0.5152776837348938, 1.0568552017211914, -0.3135044276714325, -0.9972320795059204, -0.8624488115310669, -1.2681514024734497, -0.695915937423706, 1.1005752086639404, 0.06144620478153229, -1.143193006515503, 0.2605235278606415, 1.6672980785369873, 0.041153982281684875, -0.3726869523525238, 0.7329645156860352, 0.432547926902771, -0.8374496102333069, -0.1500765085220337, -0.9323380589485168, 0.5096015334129333, -0.14838048815727234, -0.35250499844551086, 0.2970975637435913, 0.48300421237945557, 1.3367880582809448, -0.03222239762544632, 0.04670420661568642, 1.2505613565444946, -1.4453448057174683, 1.4394365549087524, -0.6703428626060486, 0.2644713521003723, -2.3947417736053467, 1.4023076295852661, -0.7698463797569275, 1.8652557134628296, -2.6172542572021484, 0.4191308915615082, -0.5917977094650269, -0.49258896708488464, 0.2789534330368042, -0.39686664938926697, 0.15072116255760193, -0.12465441226959229, -1.0388449430465698, -0.07768252491950989, -0.7062051892280579, 0.5778265595436096, 1.172428846359253, 1.3073042631149292, -1.039700984954834, -0.32478728890419006, -1.7630643844604492, -0.15871214866638184, -0.580815315246582, 0.33151358366012573, -1.9878718852996826, -0.20510560274124146, -1.997524619102478, -2.4221396446228027, -1.4201016426086426, -0.8579733371734619, 1.052305817604065, 0.15816572308540344, -0.9752810597419739, 1.1457405090332031, -0.42664432525634766, -1.823190450668335, 1.097705364227295, -2.1953012943267822 ]
https://github.com/huggingface/datasets/issues/5224
Seems to freeze when loading audio dataset with wav files from local folder
I don't know if anyone will ever read this but I've tried to upload the same dataset with google colab and the output seems more clarifying. I didn't specify the train/test split so the dataset wasn't fully uploaded (or that is what I understood, might be wrong!!). Now, including the `drop_metadata` flag I can load the dataset normally (at least with colab notebook): ```python from datasets import load_dataset dataset = load_dataset("audiofolder", data_dir="../archive/Dataset", , drop_metadata=True) ``` I'll close the issue.
### Describe the bug I'm following the instructions in [https://huggingface.co/docs/datasets/audio_load#audiofolder-with-metadata](url) to be able to load a dataset from a local folder. I have everything into a folder, into a train folder and then the audios and csv. When I try to load the dataset and run from terminal, seems to work but then freezes with no apparent reason. The metadata.csv file contains a few columns but the important ones, `file_name` with the filename and `transcription` with the transcription are okay. The audios are `.wav` files, I don't know if that might be the problem (I will proceed to try to change them all to `.mp3` and try again). ### Steps to reproduce the bug The code I'm using: ```python from datasets import load_dataset dataset = load_dataset("audiofolder", data_dir="../archive/Dataset") dataset[0]["audio"] ``` The output I obtain: ``` Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 311135.43it/s] Using custom data configuration default-38d4546ffd010f3e Downloading and preparing dataset audiofolder/default to /Users/mine/.cache/huggingface/datasets/audiofolder/default-38d4546ffd010f3e/0.0.0/6cbdd16f8688354c63b4e2a36e1585d05de285023ee6443ffd71c4182055c0fc... Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 166467.72it/s] Using custom data configuration default-38d4546ffd010f3e Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 187772.74it/s] Using custom data configuration default-38d4546ffd010f3e Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 59623.71it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 138090.55it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 106065.64it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 56036.38it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 74004.24it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 162343.45it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 101881.23it/s] Using custom data configuration default-38d4546ffd010f3e Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 60145.67it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 80890.02it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 54036.67it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 95851.09it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 155897.00it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 137656.96it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 131230.81it/s] Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e ``` And then here it just freezes and nothing more happens. ### Expected behavior Load the dataset. ### Environment info Datasets version: datasets 2.6.1 pypi_0 pypi
431
79
Seems to freeze when loading audio dataset with wav files from local folder ### Describe the bug I'm following the instructions in [https://huggingface.co/docs/datasets/audio_load#audiofolder-with-metadata](url) to be able to load a dataset from a local folder. I have everything into a folder, into a train folder and then the audios and csv. When I try to load the dataset and run from terminal, seems to work but then freezes with no apparent reason. The metadata.csv file contains a few columns but the important ones, `file_name` with the filename and `transcription` with the transcription are okay. The audios are `.wav` files, I don't know if that might be the problem (I will proceed to try to change them all to `.mp3` and try again). ### Steps to reproduce the bug The code I'm using: ```python from datasets import load_dataset dataset = load_dataset("audiofolder", data_dir="../archive/Dataset") dataset[0]["audio"] ``` The output I obtain: ``` Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 311135.43it/s] Using custom data configuration default-38d4546ffd010f3e Downloading and preparing dataset audiofolder/default to /Users/mine/.cache/huggingface/datasets/audiofolder/default-38d4546ffd010f3e/0.0.0/6cbdd16f8688354c63b4e2a36e1585d05de285023ee6443ffd71c4182055c0fc... Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 166467.72it/s] Using custom data configuration default-38d4546ffd010f3e Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 187772.74it/s] Using custom data configuration default-38d4546ffd010f3e Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 59623.71it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 138090.55it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 106065.64it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 56036.38it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 74004.24it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 162343.45it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 101881.23it/s] Using custom data configuration default-38d4546ffd010f3e Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 60145.67it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 80890.02it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 54036.67it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 95851.09it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 155897.00it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 137656.96it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 131230.81it/s] Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e ``` And then here it just freezes and nothing more happens. ### Expected behavior Load the dataset. ### Environment info Datasets version: datasets 2.6.1 pypi_0 pypi I don't know if anyone will ever read this but I've tried to upload the same dataset with google colab and the output seems more clarifying. I didn't specify the train/test split so the dataset wasn't fully uploaded (or that is what I understood, might be wrong!!). Now, including the `drop_metadata` flag I can load the dataset normally (at least with colab notebook): ```python from datasets import load_dataset dataset = load_dataset("audiofolder", data_dir="../archive/Dataset", , drop_metadata=True) ``` I'll close the issue.
[ -1.177045226097107, -0.8611588478088379, -0.809963047504425, 1.3688044548034668, -0.10902983695268631, -1.2759076356887817, 0.11001427471637726, -1.1854735612869263, 1.6254072189331055, -0.7464590668678284, 0.29121655225753784, -1.6808435916900635, 0.027181081473827362, -0.498515248298645, -0.8016663789749146, -0.8814895749092102, -0.4189562499523163, -0.7975467443466187, 0.9734137058258057, 2.576556444168091, 1.1819307804107666, -1.3740915060043335, 2.703252077102661, 0.7239051461219788, -0.1859632134437561, -0.9891704320907593, 0.5566399097442627, 0.04392192140221596, -1.4045166969299316, -0.4226067364215851, -0.9514261484146118, -0.06710577011108398, -0.563116192817688, -0.49857187271118164, 0.04890153929591179, 0.4124694764614105, -0.2684883773326874, -0.43418604135513306, -0.6030599474906921, -0.7632831931114197, 0.4584762752056122, -0.3980419933795929, 0.9903907179832458, -0.29153522849082947, 1.8255106210708618, -0.5477443933486938, 0.4383834898471832, 0.6837046146392822, 1.3526325225830078, 0.18383237719535828, 0.03636850044131279, 0.30702289938926697, 0.4111441671848297, -0.022102106362581253, 0.4487132132053375, 1.1873217821121216, 0.5861096382141113, 0.4318959414958954, 0.7796026468276978, -2.183908700942993, 1.2691999673843384, -0.92335045337677, 0.3109503984451294, 1.3577396869659424, -0.875851035118103, 0.2918130159378052, -1.858930230140686, -0.07699919492006302, 0.5583109855651855, -2.2018327713012695, 0.25284409523010254, -1.298535943031311, -0.48681312799453735, 0.9694587588310242, 0.2680845558643341, -1.2009949684143066, 0.24145746231079102, -0.454656183719635, 1.0463298559188843, 0.46114376187324524, 1.2401801347732544, -1.638676404953003, -0.018473468720912933, -0.31776657700538635, 0.11452723294496536, -1.2939664125442505, -1.5257821083068848, 0.5625008940696716, 0.6303656697273254, 0.6082437038421631, -0.1187739223241806, 1.0496294498443604, -1.0009714365005493, 0.8240001797676086, -0.9319517612457275, -1.7446019649505615, -1.349585771560669, -2.2401580810546875, -2.3362653255462646, 0.8055827617645264, -0.5424256324768066, -0.5162351131439209, 2.021582841873169, -1.0748976469039917, -1.7341970205307007, 1.1392731666564941, 0.26195093989372253, 0.04361569136381149, 2.3581039905548096, 0.2541356682777405, -0.7004566192626953, 0.4971880316734314, -0.6584510207176208, 0.8265178203582764, -0.34116482734680176, 1.3626257181167603, 0.39146143198013306, -0.9876833558082581, 1.6273157596588135, -0.41870617866516113, 0.5464661717414856, -0.701486349105835, -0.5352745056152344, -0.8144261837005615, 0.3283708989620209, 1.9565765857696533, -0.38774439692497253, 1.6817026138305664, -0.32467690110206604, -1.5976893901824951, -1.5105242729187012, 0.8821020722389221, 0.5033664107322693, -0.8383167386054993, 0.040436845272779465, -0.37342599034309387, 0.07527071237564087, -0.03104180097579956, 1.0774834156036377, 1.254411220550537, 0.7123990058898926, -0.30872979760169983, -0.9226701259613037, 0.21465861797332764, -0.08851765096187592, -0.7895652055740356, -1.7368626594543457, -0.2800601124763489, 0.13531431555747986, 0.6503796577453613, -1.2593035697937012, 1.742278814315796, 0.8446279168128967, 1.9866788387298584, 1.0190378427505493, -0.3776298463344574, 1.4673101902008057, 0.1120031550526619, 1.9244210720062256, -0.4926134943962097, 0.6330540180206299, -0.39754828810691833, -1.1159189939498901, 0.8326040506362915, -0.4021669030189514, -2.0363028049468994, -0.7508416175842285, -0.7648869156837463, -0.1812194585800171, -0.7284308075904846, 0.9352673888206482, -0.27501192688941956, -1.468174695968628, 0.2622196674346924, -0.633589506149292, 0.11382907629013062, -1.2499043941497803, 0.26855066418647766, 0.7676485776901245, -0.6567649245262146, 0.009858338162302971, -0.21990260481834412, -1.3281152248382568, -0.44430509209632874, 0.24793130159378052, 1.931482195854187, -0.718754231929779, 0.9295110106468201, 1.0586740970611572, -0.699178159236908, 0.05267930030822754, 0.3247361481189728, -0.38034069538116455, 0.7810860872268677, -1.110992670059204, -0.3830617368221283, 1.1270835399627686, -0.11119364947080612, -0.5107691287994385, 1.415974736213684, 0.7021037340164185, -1.0676454305648804, -0.1933719515800476, -0.15824630856513977, -0.8399246335029602, 0.001848316751420498, -1.5893491506576538, -0.08896313607692719, 0.3286394476890564, -1.5206501483917236, -0.4658382534980774, -0.2284843921661377, 1.1499098539352417, -0.1773463487625122, 1.4294729232788086, -0.35541850328445435, -0.1635727882385254, -0.3556526303291321, -0.4506728947162628, 0.1415404975414276, -0.2302030324935913, -0.6733143329620361, 0.256900817155838, -0.7493028044700623, 0.3446309566497803, 1.4326558113098145, 0.31539809703826904, 0.052949488162994385, 0.4622274935245514, 1.0731852054595947, 0.343759149312973, -0.0274664293974638, -0.7915140986442566, -1.6111760139465332, 2.026930093765259, -1.4853533506393433, 1.9363166093826294, 0.7615849375724792, 0.014589307829737663, -1.8572090864181519, -1.8804179430007935, 1.3816325664520264, 1.1167662143707275, 2.380068778991699, 0.6077806949615479, 0.4139186441898346, -0.7424968481063843, -0.6960543394088745, 0.36031225323677063, -0.8938062787055969, -0.7437651753425598, 0.16037127375602722, 2.370553970336914, 1.7133814096450806, -0.5195774435997009, -0.227789044380188, -0.9292681217193604, 1.3177158832550049, -0.1390528380870819, 0.16058960556983948, 1.9626742601394653, -0.30487918853759766, -1.1091194152832031, 1.2970194816589355, -2.334277629852295, 0.14883357286453247, 2.0353140830993652, 0.23998728394508362, 0.027051925659179688, -1.388466477394104, -0.6595567464828491, -0.27944430708885193, -0.4664936661720276, -1.1971379518508911, 0.5519652962684631, -0.33020657300949097, -0.8477961421012878, -1.482170820236206, 0.07899540662765503, -1.203815221786499, -1.6466306447982788, 0.33875641226768494, 1.8854819536209106, 2.015721321105957, -0.730334997177124, 1.5351228713989258, -0.289363831281662, 0.1344490349292755, 1.1802603006362915, 1.2624555826187134, 3.138875961303711, 1.827347755432129, -1.2500698566436768, 0.6991807818412781, -0.18567430973052979, -0.47686129808425903, 1.165993571281433, -1.086262583732605, 1.2377902269363403, -0.1727743148803711, -1.2409600019454956, -1.2358273267745972, 0.976182222366333, 0.4760851263999939, 0.10522753745317459, -0.5052093863487244, 1.2437653541564941, 0.07453610002994537, 1.229683518409729, 0.5884259343147278, -0.3827056288719177, 0.5507679581642151, -0.358415812253952, -0.5457502603530884, 1.5797603130340576, 0.19285085797309875, -1.354553461074829, -2.4195828437805176, -0.2836788296699524, -0.8610252737998962, 0.02527007833123207, -0.6315411329269409, -1.0324188470840454, 1.6562857627868652, 0.4077802896499634, -1.2881591320037842, -0.28864914178848267, -0.3433673679828644, -0.611627995967865, 2.6285388469696045, -1.4361827373504639, -0.18315809965133667, -0.9376745223999023, -0.5767473578453064, 1.6455023288726807, -1.1558659076690674, -0.23248296976089478, -1.0989640951156616, -0.5565245747566223, -1.3027995824813843, -0.5724326968193054, 0.07232625037431717, -0.9332013130187988, 0.8852264881134033, 0.20113134384155273, -1.1316463947296143, -0.29020416736602783, -0.9665595889091492, 0.9253933429718018, -0.047409042716026306, 0.22905665636062622, 1.8709790706634521, 0.4710407555103302, -0.4556061029434204, 0.683032214641571, 1.2283180952072144, 0.611449658870697, -0.7319052815437317, 0.13512590527534485, -0.765618622303009, 0.2700996398925781, -1.4375399351119995, 0.2829831540584564, -2.8242948055267334, 0.6826815009117126, -0.07488460838794708, -0.07057543098926544, 0.03061816096305847, -1.3091201782226562, 1.0763407945632935, 2.6058552265167236, -1.1702269315719604, 0.49564605951309204, 0.3317403197288513, 1.2305256128311157, -1.5625617504119873, 0.2524462938308716, -0.41135257482528687, 2.027275800704956, 0.12037820369005203, 1.209728717803955, -0.5043249726295471, -2.2223799228668213, 0.6317911148071289, -1.2662651538848877, -1.156360387802124, 0.7918312549591064, -0.8304548859596252, 0.108178049325943, -1.4640419483184814, -0.23190158605575562, -0.9711726307868958, -1.1929011344909668, 0.6910825371742249, 0.1497274935245514, 0.46425318717956543, -0.5563284158706665, 0.30624908208847046, -2.2434518337249756, -1.3905340433120728, -0.1588973104953766, -1.0022101402282715, 0.41920673847198486, -0.3054157495498657, 0.6697402000427246, -0.15955734252929688, 0.04076866805553436, 0.3516070246696472, 1.4231925010681152, 3.4279415607452393, 0.18362995982170105, 0.2956988215446472, -0.1767401397228241, -0.9701099395751953, 1.4370235204696655, 0.8870733380317688, -0.08760349452495575, -0.595485508441925, -1.0425925254821777, 1.174485206604004, 2.0235321521759033, 1.0783324241638184, 0.018247952684760094, -0.772982120513916, -0.6861045956611633, 0.01574110984802246, 0.20903286337852478, 0.4880272448062897, 0.9526862502098083, 0.04596356675028801, 0.06248382478952408, 1.4447602033615112, 1.1550441980361938, -0.41811704635620117, 0.40832605957984924, -0.8227015733718872, -0.4871406853199005, 0.4558883607387543, 0.2971380949020386, 0.04516466334462166, 0.37174782156944275, -1.039376974105835, -0.2948809266090393, -0.42388322949409485, -0.9235021471977234, -0.6542003750801086, -0.43922311067581177, -0.34456387162208557, 1.5765020847320557, 0.10586496442556381, -0.5127415657043457, -0.014520689845085144, -0.718422532081604, -0.0931129977107048, -1.108964443206787, 0.23380446434020996, -0.21747943758964539, -0.052573978900909424, -0.06857572495937347, 1.7697715759277344, -0.9630581140518188, -2.0621883869171143, 0.2213665246963501, 0.2163097858428955, -0.3932340443134308, 0.2367071509361267, 1.6198920011520386, 0.5543076395988464, 1.3867419958114624, 1.3966326713562012, 0.9151023030281067, -0.7038053274154663, -1.3096578121185303, 0.642474353313446, 1.006812572479248, -1.3245726823806763, 0.793375551700592, 0.00548994354903698, -0.5462919473648071, 0.6799790859222412, 1.3920878171920776, 0.3820948302745819, -2.019927978515625, 0.831506609916687, -0.8449352979660034, 0.7078782320022583, 0.6964355111122131, 0.7496566772460938, 0.2377793788909912, 0.8331480026245117, -1.2018908262252808, -1.1543587446212769, -0.7735903263092041, -0.663986325263977, 1.8968284130096436, -0.20658209919929504, 0.5684143304824829, -0.12865370512008667, -1.2043994665145874, -0.07296169549226761, 0.7189001441001892, 0.37391504645347595, -0.4677261710166931, 0.8088794350624084, -0.5964112281799316, -1.142390251159668, -1.3403685092926025, -0.47172823548316956, -1.00417160987854, -0.8353327512741089, 1.0274723768234253, 0.8100610971450806, 0.32342255115509033, 1.9147967100143433, 0.6680358648300171, 0.24837356805801392, -2.698245048522949, 0.8766034245491028, 0.2587394714355469, -0.017878010869026184, 0.909256100654602, 0.3031493127346039, 1.1112550497055054, -0.01979753188788891, 0.5647207498550415, -2.314199209213257, 2.235041618347168, -0.2838687598705292, 0.66267991065979, -0.11605554819107056, -0.1923203468322754, 1.1439744234085083, 0.5520919561386108, 0.5616620779037476, -1.0754539966583252, 0.6887755990028381, -0.6413965821266174, 1.1589767932891846, 0.9345277547836304, -0.880267858505249, 0.013019183650612831, 1.3962963819503784, 0.4614531099796295, -0.45998644828796387, -0.960774838924408, -0.8250517845153809, 0.9563124775886536, 1.7165484428405762, -0.026910215616226196, 0.04554238170385361, 0.9058986306190491, 0.6933000683784485, -1.347892165184021, 0.05896015465259552, -0.7132324576377869, -0.7783219814300537, 1.6964259147644043, 2.0482704639434814, -0.04292907193303108, -0.14976149797439575, -0.7784760594367981, -1.2544708251953125, 0.8019235134124756, -0.08031601458787918, 0.1762838363647461, 0.6112508773803711, -0.7097834944725037, 1.1363753080368042, 0.775414764881134, 0.9799906611442566, 0.13226589560508728, 0.3685321807861328, 0.42502719163894653, -0.3283305764198303, -1.1140917539596558, -0.26952803134918213, -1.1106059551239014, -2.446949005126953, 0.5573897957801819, -0.2635153532028198, -1.5026389360427856, 0.06633615493774414, -0.9746317267417908, 0.9515697956085205, -0.5861446857452393, -1.0831655263900757, -1.472977638244629, 0.31024983525276184, -0.057986848056316376, 0.9762657880783081, -1.6117697954177856, -0.10639739781618118, 1.166332721710205, 0.9515277147293091, -0.6197370290756226, 0.9971116781234741, 0.2627807557582855, 1.0072917938232422, 0.8262597918510437, -0.411201536655426, 0.4348970949649811, 0.05172053724527359, -1.312997817993164, 0.4134186804294586, 1.2028230428695679, 0.19395482540130615, 1.400834083557129, -0.5699542760848999, 0.035912446677684784, 0.4032372236251831, -0.41837242245674133, -0.3798809349536896, -0.5470868945121765, 0.6227719783782959, 0.12889647483825684, -0.913962721824646, -0.09480136632919312, -0.08642558008432388, -0.2607055604457855, 0.19296595454216003, -1.4804891347885132, -0.1984327733516693, -0.4123927056789398, -0.5056923627853394, -1.231001615524292, 0.01599419303238392, 1.3577749729156494, -0.7556585669517517, -0.19675031304359436, 0.44457992911338806, 0.3946242928504944, 0.5218251347541809, 0.6209444999694824, -0.6719030737876892, -0.3112528622150421, -0.3161429166793823, -0.36160439252853394, 0.17523431777954102, 1.3165236711502075, -0.11138859391212463, -0.9844589829444885, 0.7048812508583069, -0.38281431794166565, 0.055963434278964996, 1.9708608388900757, 0.10282006859779358, -0.7545056939125061, 0.3151713013648987, -0.702364981174469, 1.892063021659851, 1.8065481185913086, 1.368569254875183, -0.09252772480249405, -0.9055118560791016, 0.6013420224189758, -0.3207935392856598, -0.3043896555900574, 0.9344643950462341, 0.4374535381793976, -0.11392035335302353, -1.3969749212265015, 0.5722218155860901, 1.2951722145080566, -0.9294453263282776, -0.7376842498779297, 0.08742287755012512, -0.8000909090042114, 1.0963689088821411, 0.7214288115501404, 0.3965560793876648, 0.28156551718711853, 1.6131246089935303, 0.7622761130332947, -0.4887363016605377, 0.5996245741844177, 0.5283762812614441, -0.18764042854309082, -2.081199884414673, -1.087990641593933, 0.30639949440956116, -0.33147311210632324, -1.6400423049926758, 1.3577364683151245, -1.1462068557739258, -0.8769893050193787, 0.5186706781387329, 0.03765149042010307, 1.3788390159606934, 0.4279692769050598, 1.6669836044311523, 2.1602416038513184, 0.8623015284538269, 0.3368256390094757, 1.2806544303894043, -0.06814135611057281, -0.4270018935203552, 1.8475010395050049, -0.4874597489833832, 0.5152776837348938, 1.0568552017211914, -0.3135044276714325, -0.9972320795059204, -0.8624488115310669, -1.2681514024734497, -0.695915937423706, 1.1005752086639404, 0.06144620478153229, -1.143193006515503, 0.2605235278606415, 1.6672980785369873, 0.041153982281684875, -0.3726869523525238, 0.7329645156860352, 0.432547926902771, -0.8374496102333069, -0.1500765085220337, -0.9323380589485168, 0.5096015334129333, -0.14838048815727234, -0.35250499844551086, 0.2970975637435913, 0.48300421237945557, 1.3367880582809448, -0.03222239762544632, 0.04670420661568642, 1.2505613565444946, -1.4453448057174683, 1.4394365549087524, -0.6703428626060486, 0.2644713521003723, -2.3947417736053467, 1.4023076295852661, -0.7698463797569275, 1.8652557134628296, -2.6172542572021484, 0.4191308915615082, -0.5917977094650269, -0.49258896708488464, 0.2789534330368042, -0.39686664938926697, 0.15072116255760193, -0.12465441226959229, -1.0388449430465698, -0.07768252491950989, -0.7062051892280579, 0.5778265595436096, 1.172428846359253, 1.3073042631149292, -1.039700984954834, -0.32478728890419006, -1.7630643844604492, -0.15871214866638184, -0.580815315246582, 0.33151358366012573, -1.9878718852996826, -0.20510560274124146, -1.997524619102478, -2.4221396446228027, -1.4201016426086426, -0.8579733371734619, 1.052305817604065, 0.15816572308540344, -0.9752810597419739, 1.1457405090332031, -0.42664432525634766, -1.823190450668335, 1.097705364227295, -2.1953012943267822 ]
https://github.com/huggingface/datasets/issues/5224
Seems to freeze when loading audio dataset with wav files from local folder
Yes but it didn't matter. I don't remember which of them I ended up working with.
### Describe the bug I'm following the instructions in [https://huggingface.co/docs/datasets/audio_load#audiofolder-with-metadata](url) to be able to load a dataset from a local folder. I have everything into a folder, into a train folder and then the audios and csv. When I try to load the dataset and run from terminal, seems to work but then freezes with no apparent reason. The metadata.csv file contains a few columns but the important ones, `file_name` with the filename and `transcription` with the transcription are okay. The audios are `.wav` files, I don't know if that might be the problem (I will proceed to try to change them all to `.mp3` and try again). ### Steps to reproduce the bug The code I'm using: ```python from datasets import load_dataset dataset = load_dataset("audiofolder", data_dir="../archive/Dataset") dataset[0]["audio"] ``` The output I obtain: ``` Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 311135.43it/s] Using custom data configuration default-38d4546ffd010f3e Downloading and preparing dataset audiofolder/default to /Users/mine/.cache/huggingface/datasets/audiofolder/default-38d4546ffd010f3e/0.0.0/6cbdd16f8688354c63b4e2a36e1585d05de285023ee6443ffd71c4182055c0fc... Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 166467.72it/s] Using custom data configuration default-38d4546ffd010f3e Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 187772.74it/s] Using custom data configuration default-38d4546ffd010f3e Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 59623.71it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 138090.55it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 106065.64it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 56036.38it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 74004.24it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 162343.45it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 101881.23it/s] Using custom data configuration default-38d4546ffd010f3e Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 60145.67it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 80890.02it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 54036.67it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 95851.09it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 155897.00it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 137656.96it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 131230.81it/s] Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e ``` And then here it just freezes and nothing more happens. ### Expected behavior Load the dataset. ### Environment info Datasets version: datasets 2.6.1 pypi_0 pypi
431
16
Seems to freeze when loading audio dataset with wav files from local folder ### Describe the bug I'm following the instructions in [https://huggingface.co/docs/datasets/audio_load#audiofolder-with-metadata](url) to be able to load a dataset from a local folder. I have everything into a folder, into a train folder and then the audios and csv. When I try to load the dataset and run from terminal, seems to work but then freezes with no apparent reason. The metadata.csv file contains a few columns but the important ones, `file_name` with the filename and `transcription` with the transcription are okay. The audios are `.wav` files, I don't know if that might be the problem (I will proceed to try to change them all to `.mp3` and try again). ### Steps to reproduce the bug The code I'm using: ```python from datasets import load_dataset dataset = load_dataset("audiofolder", data_dir="../archive/Dataset") dataset[0]["audio"] ``` The output I obtain: ``` Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 311135.43it/s] Using custom data configuration default-38d4546ffd010f3e Downloading and preparing dataset audiofolder/default to /Users/mine/.cache/huggingface/datasets/audiofolder/default-38d4546ffd010f3e/0.0.0/6cbdd16f8688354c63b4e2a36e1585d05de285023ee6443ffd71c4182055c0fc... Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 166467.72it/s] Using custom data configuration default-38d4546ffd010f3e Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 187772.74it/s] Using custom data configuration default-38d4546ffd010f3e Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 59623.71it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 138090.55it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 106065.64it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 56036.38it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 74004.24it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 162343.45it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 101881.23it/s] Using custom data configuration default-38d4546ffd010f3e Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 60145.67it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 80890.02it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 54036.67it/s] Resolving data files: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 95851.09it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 155897.00it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 137656.96it/s] Resolving data files: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 439/439 [00:00<00:00, 131230.81it/s] Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e Using custom data configuration default-38d4546ffd010f3e ``` And then here it just freezes and nothing more happens. ### Expected behavior Load the dataset. ### Environment info Datasets version: datasets 2.6.1 pypi_0 pypi Yes but it didn't matter. I don't remember which of them I ended up working with.
[ -1.177045226097107, -0.8611588478088379, -0.809963047504425, 1.3688044548034668, -0.10902983695268631, -1.2759076356887817, 0.11001427471637726, -1.1854735612869263, 1.6254072189331055, -0.7464590668678284, 0.29121655225753784, -1.6808435916900635, 0.027181081473827362, -0.498515248298645, -0.8016663789749146, -0.8814895749092102, -0.4189562499523163, -0.7975467443466187, 0.9734137058258057, 2.576556444168091, 1.1819307804107666, -1.3740915060043335, 2.703252077102661, 0.7239051461219788, -0.1859632134437561, -0.9891704320907593, 0.5566399097442627, 0.04392192140221596, -1.4045166969299316, -0.4226067364215851, -0.9514261484146118, -0.06710577011108398, -0.563116192817688, -0.49857187271118164, 0.04890153929591179, 0.4124694764614105, -0.2684883773326874, -0.43418604135513306, -0.6030599474906921, -0.7632831931114197, 0.4584762752056122, -0.3980419933795929, 0.9903907179832458, -0.29153522849082947, 1.8255106210708618, -0.5477443933486938, 0.4383834898471832, 0.6837046146392822, 1.3526325225830078, 0.18383237719535828, 0.03636850044131279, 0.30702289938926697, 0.4111441671848297, -0.022102106362581253, 0.4487132132053375, 1.1873217821121216, 0.5861096382141113, 0.4318959414958954, 0.7796026468276978, -2.183908700942993, 1.2691999673843384, -0.92335045337677, 0.3109503984451294, 1.3577396869659424, -0.875851035118103, 0.2918130159378052, -1.858930230140686, -0.07699919492006302, 0.5583109855651855, -2.2018327713012695, 0.25284409523010254, -1.298535943031311, -0.48681312799453735, 0.9694587588310242, 0.2680845558643341, -1.2009949684143066, 0.24145746231079102, -0.454656183719635, 1.0463298559188843, 0.46114376187324524, 1.2401801347732544, -1.638676404953003, -0.018473468720912933, -0.31776657700538635, 0.11452723294496536, -1.2939664125442505, -1.5257821083068848, 0.5625008940696716, 0.6303656697273254, 0.6082437038421631, -0.1187739223241806, 1.0496294498443604, -1.0009714365005493, 0.8240001797676086, -0.9319517612457275, -1.7446019649505615, -1.349585771560669, -2.2401580810546875, -2.3362653255462646, 0.8055827617645264, -0.5424256324768066, -0.5162351131439209, 2.021582841873169, -1.0748976469039917, -1.7341970205307007, 1.1392731666564941, 0.26195093989372253, 0.04361569136381149, 2.3581039905548096, 0.2541356682777405, -0.7004566192626953, 0.4971880316734314, -0.6584510207176208, 0.8265178203582764, -0.34116482734680176, 1.3626257181167603, 0.39146143198013306, -0.9876833558082581, 1.6273157596588135, -0.41870617866516113, 0.5464661717414856, -0.701486349105835, -0.5352745056152344, -0.8144261837005615, 0.3283708989620209, 1.9565765857696533, -0.38774439692497253, 1.6817026138305664, -0.32467690110206604, -1.5976893901824951, -1.5105242729187012, 0.8821020722389221, 0.5033664107322693, -0.8383167386054993, 0.040436845272779465, -0.37342599034309387, 0.07527071237564087, -0.03104180097579956, 1.0774834156036377, 1.254411220550537, 0.7123990058898926, -0.30872979760169983, -0.9226701259613037, 0.21465861797332764, -0.08851765096187592, -0.7895652055740356, -1.7368626594543457, -0.2800601124763489, 0.13531431555747986, 0.6503796577453613, -1.2593035697937012, 1.742278814315796, 0.8446279168128967, 1.9866788387298584, 1.0190378427505493, -0.3776298463344574, 1.4673101902008057, 0.1120031550526619, 1.9244210720062256, -0.4926134943962097, 0.6330540180206299, -0.39754828810691833, -1.1159189939498901, 0.8326040506362915, -0.4021669030189514, -2.0363028049468994, -0.7508416175842285, -0.7648869156837463, -0.1812194585800171, -0.7284308075904846, 0.9352673888206482, -0.27501192688941956, -1.468174695968628, 0.2622196674346924, -0.633589506149292, 0.11382907629013062, -1.2499043941497803, 0.26855066418647766, 0.7676485776901245, -0.6567649245262146, 0.009858338162302971, -0.21990260481834412, -1.3281152248382568, -0.44430509209632874, 0.24793130159378052, 1.931482195854187, -0.718754231929779, 0.9295110106468201, 1.0586740970611572, -0.699178159236908, 0.05267930030822754, 0.3247361481189728, -0.38034069538116455, 0.7810860872268677, -1.110992670059204, -0.3830617368221283, 1.1270835399627686, -0.11119364947080612, -0.5107691287994385, 1.415974736213684, 0.7021037340164185, -1.0676454305648804, -0.1933719515800476, -0.15824630856513977, -0.8399246335029602, 0.001848316751420498, -1.5893491506576538, -0.08896313607692719, 0.3286394476890564, -1.5206501483917236, -0.4658382534980774, -0.2284843921661377, 1.1499098539352417, -0.1773463487625122, 1.4294729232788086, -0.35541850328445435, -0.1635727882385254, -0.3556526303291321, -0.4506728947162628, 0.1415404975414276, -0.2302030324935913, -0.6733143329620361, 0.256900817155838, -0.7493028044700623, 0.3446309566497803, 1.4326558113098145, 0.31539809703826904, 0.052949488162994385, 0.4622274935245514, 1.0731852054595947, 0.343759149312973, -0.0274664293974638, -0.7915140986442566, -1.6111760139465332, 2.026930093765259, -1.4853533506393433, 1.9363166093826294, 0.7615849375724792, 0.014589307829737663, -1.8572090864181519, -1.8804179430007935, 1.3816325664520264, 1.1167662143707275, 2.380068778991699, 0.6077806949615479, 0.4139186441898346, -0.7424968481063843, -0.6960543394088745, 0.36031225323677063, -0.8938062787055969, -0.7437651753425598, 0.16037127375602722, 2.370553970336914, 1.7133814096450806, -0.5195774435997009, -0.227789044380188, -0.9292681217193604, 1.3177158832550049, -0.1390528380870819, 0.16058960556983948, 1.9626742601394653, -0.30487918853759766, -1.1091194152832031, 1.2970194816589355, -2.334277629852295, 0.14883357286453247, 2.0353140830993652, 0.23998728394508362, 0.027051925659179688, -1.388466477394104, -0.6595567464828491, -0.27944430708885193, -0.4664936661720276, -1.1971379518508911, 0.5519652962684631, -0.33020657300949097, -0.8477961421012878, -1.482170820236206, 0.07899540662765503, -1.203815221786499, -1.6466306447982788, 0.33875641226768494, 1.8854819536209106, 2.015721321105957, -0.730334997177124, 1.5351228713989258, -0.289363831281662, 0.1344490349292755, 1.1802603006362915, 1.2624555826187134, 3.138875961303711, 1.827347755432129, -1.2500698566436768, 0.6991807818412781, -0.18567430973052979, -0.47686129808425903, 1.165993571281433, -1.086262583732605, 1.2377902269363403, -0.1727743148803711, -1.2409600019454956, -1.2358273267745972, 0.976182222366333, 0.4760851263999939, 0.10522753745317459, -0.5052093863487244, 1.2437653541564941, 0.07453610002994537, 1.229683518409729, 0.5884259343147278, -0.3827056288719177, 0.5507679581642151, -0.358415812253952, -0.5457502603530884, 1.5797603130340576, 0.19285085797309875, -1.354553461074829, -2.4195828437805176, -0.2836788296699524, -0.8610252737998962, 0.02527007833123207, -0.6315411329269409, -1.0324188470840454, 1.6562857627868652, 0.4077802896499634, -1.2881591320037842, -0.28864914178848267, -0.3433673679828644, -0.611627995967865, 2.6285388469696045, -1.4361827373504639, -0.18315809965133667, -0.9376745223999023, -0.5767473578453064, 1.6455023288726807, -1.1558659076690674, -0.23248296976089478, -1.0989640951156616, -0.5565245747566223, -1.3027995824813843, -0.5724326968193054, 0.07232625037431717, -0.9332013130187988, 0.8852264881134033, 0.20113134384155273, -1.1316463947296143, -0.29020416736602783, -0.9665595889091492, 0.9253933429718018, -0.047409042716026306, 0.22905665636062622, 1.8709790706634521, 0.4710407555103302, -0.4556061029434204, 0.683032214641571, 1.2283180952072144, 0.611449658870697, -0.7319052815437317, 0.13512590527534485, -0.765618622303009, 0.2700996398925781, -1.4375399351119995, 0.2829831540584564, -2.8242948055267334, 0.6826815009117126, -0.07488460838794708, -0.07057543098926544, 0.03061816096305847, -1.3091201782226562, 1.0763407945632935, 2.6058552265167236, -1.1702269315719604, 0.49564605951309204, 0.3317403197288513, 1.2305256128311157, -1.5625617504119873, 0.2524462938308716, -0.41135257482528687, 2.027275800704956, 0.12037820369005203, 1.209728717803955, -0.5043249726295471, -2.2223799228668213, 0.6317911148071289, -1.2662651538848877, -1.156360387802124, 0.7918312549591064, -0.8304548859596252, 0.108178049325943, -1.4640419483184814, -0.23190158605575562, -0.9711726307868958, -1.1929011344909668, 0.6910825371742249, 0.1497274935245514, 0.46425318717956543, -0.5563284158706665, 0.30624908208847046, -2.2434518337249756, -1.3905340433120728, -0.1588973104953766, -1.0022101402282715, 0.41920673847198486, -0.3054157495498657, 0.6697402000427246, -0.15955734252929688, 0.04076866805553436, 0.3516070246696472, 1.4231925010681152, 3.4279415607452393, 0.18362995982170105, 0.2956988215446472, -0.1767401397228241, -0.9701099395751953, 1.4370235204696655, 0.8870733380317688, -0.08760349452495575, -0.595485508441925, -1.0425925254821777, 1.174485206604004, 2.0235321521759033, 1.0783324241638184, 0.018247952684760094, -0.772982120513916, -0.6861045956611633, 0.01574110984802246, 0.20903286337852478, 0.4880272448062897, 0.9526862502098083, 0.04596356675028801, 0.06248382478952408, 1.4447602033615112, 1.1550441980361938, -0.41811704635620117, 0.40832605957984924, -0.8227015733718872, -0.4871406853199005, 0.4558883607387543, 0.2971380949020386, 0.04516466334462166, 0.37174782156944275, -1.039376974105835, -0.2948809266090393, -0.42388322949409485, -0.9235021471977234, -0.6542003750801086, -0.43922311067581177, -0.34456387162208557, 1.5765020847320557, 0.10586496442556381, -0.5127415657043457, -0.014520689845085144, -0.718422532081604, -0.0931129977107048, -1.108964443206787, 0.23380446434020996, -0.21747943758964539, -0.052573978900909424, -0.06857572495937347, 1.7697715759277344, -0.9630581140518188, -2.0621883869171143, 0.2213665246963501, 0.2163097858428955, -0.3932340443134308, 0.2367071509361267, 1.6198920011520386, 0.5543076395988464, 1.3867419958114624, 1.3966326713562012, 0.9151023030281067, -0.7038053274154663, -1.3096578121185303, 0.642474353313446, 1.006812572479248, -1.3245726823806763, 0.793375551700592, 0.00548994354903698, -0.5462919473648071, 0.6799790859222412, 1.3920878171920776, 0.3820948302745819, -2.019927978515625, 0.831506609916687, -0.8449352979660034, 0.7078782320022583, 0.6964355111122131, 0.7496566772460938, 0.2377793788909912, 0.8331480026245117, -1.2018908262252808, -1.1543587446212769, -0.7735903263092041, -0.663986325263977, 1.8968284130096436, -0.20658209919929504, 0.5684143304824829, -0.12865370512008667, -1.2043994665145874, -0.07296169549226761, 0.7189001441001892, 0.37391504645347595, -0.4677261710166931, 0.8088794350624084, -0.5964112281799316, -1.142390251159668, -1.3403685092926025, -0.47172823548316956, -1.00417160987854, -0.8353327512741089, 1.0274723768234253, 0.8100610971450806, 0.32342255115509033, 1.9147967100143433, 0.6680358648300171, 0.24837356805801392, -2.698245048522949, 0.8766034245491028, 0.2587394714355469, -0.017878010869026184, 0.909256100654602, 0.3031493127346039, 1.1112550497055054, -0.01979753188788891, 0.5647207498550415, -2.314199209213257, 2.235041618347168, -0.2838687598705292, 0.66267991065979, -0.11605554819107056, -0.1923203468322754, 1.1439744234085083, 0.5520919561386108, 0.5616620779037476, -1.0754539966583252, 0.6887755990028381, -0.6413965821266174, 1.1589767932891846, 0.9345277547836304, -0.880267858505249, 0.013019183650612831, 1.3962963819503784, 0.4614531099796295, -0.45998644828796387, -0.960774838924408, -0.8250517845153809, 0.9563124775886536, 1.7165484428405762, -0.026910215616226196, 0.04554238170385361, 0.9058986306190491, 0.6933000683784485, -1.347892165184021, 0.05896015465259552, -0.7132324576377869, -0.7783219814300537, 1.6964259147644043, 2.0482704639434814, -0.04292907193303108, -0.14976149797439575, -0.7784760594367981, -1.2544708251953125, 0.8019235134124756, -0.08031601458787918, 0.1762838363647461, 0.6112508773803711, -0.7097834944725037, 1.1363753080368042, 0.775414764881134, 0.9799906611442566, 0.13226589560508728, 0.3685321807861328, 0.42502719163894653, -0.3283305764198303, -1.1140917539596558, -0.26952803134918213, -1.1106059551239014, -2.446949005126953, 0.5573897957801819, -0.2635153532028198, -1.5026389360427856, 0.06633615493774414, -0.9746317267417908, 0.9515697956085205, -0.5861446857452393, -1.0831655263900757, -1.472977638244629, 0.31024983525276184, -0.057986848056316376, 0.9762657880783081, -1.6117697954177856, -0.10639739781618118, 1.166332721710205, 0.9515277147293091, -0.6197370290756226, 0.9971116781234741, 0.2627807557582855, 1.0072917938232422, 0.8262597918510437, -0.411201536655426, 0.4348970949649811, 0.05172053724527359, -1.312997817993164, 0.4134186804294586, 1.2028230428695679, 0.19395482540130615, 1.400834083557129, -0.5699542760848999, 0.035912446677684784, 0.4032372236251831, -0.41837242245674133, -0.3798809349536896, -0.5470868945121765, 0.6227719783782959, 0.12889647483825684, -0.913962721824646, -0.09480136632919312, -0.08642558008432388, -0.2607055604457855, 0.19296595454216003, -1.4804891347885132, -0.1984327733516693, -0.4123927056789398, -0.5056923627853394, -1.231001615524292, 0.01599419303238392, 1.3577749729156494, -0.7556585669517517, -0.19675031304359436, 0.44457992911338806, 0.3946242928504944, 0.5218251347541809, 0.6209444999694824, -0.6719030737876892, -0.3112528622150421, -0.3161429166793823, -0.36160439252853394, 0.17523431777954102, 1.3165236711502075, -0.11138859391212463, -0.9844589829444885, 0.7048812508583069, -0.38281431794166565, 0.055963434278964996, 1.9708608388900757, 0.10282006859779358, -0.7545056939125061, 0.3151713013648987, -0.702364981174469, 1.892063021659851, 1.8065481185913086, 1.368569254875183, -0.09252772480249405, -0.9055118560791016, 0.6013420224189758, -0.3207935392856598, -0.3043896555900574, 0.9344643950462341, 0.4374535381793976, -0.11392035335302353, -1.3969749212265015, 0.5722218155860901, 1.2951722145080566, -0.9294453263282776, -0.7376842498779297, 0.08742287755012512, -0.8000909090042114, 1.0963689088821411, 0.7214288115501404, 0.3965560793876648, 0.28156551718711853, 1.6131246089935303, 0.7622761130332947, -0.4887363016605377, 0.5996245741844177, 0.5283762812614441, -0.18764042854309082, -2.081199884414673, -1.087990641593933, 0.30639949440956116, -0.33147311210632324, -1.6400423049926758, 1.3577364683151245, -1.1462068557739258, -0.8769893050193787, 0.5186706781387329, 0.03765149042010307, 1.3788390159606934, 0.4279692769050598, 1.6669836044311523, 2.1602416038513184, 0.8623015284538269, 0.3368256390094757, 1.2806544303894043, -0.06814135611057281, -0.4270018935203552, 1.8475010395050049, -0.4874597489833832, 0.5152776837348938, 1.0568552017211914, -0.3135044276714325, -0.9972320795059204, -0.8624488115310669, -1.2681514024734497, -0.695915937423706, 1.1005752086639404, 0.06144620478153229, -1.143193006515503, 0.2605235278606415, 1.6672980785369873, 0.041153982281684875, -0.3726869523525238, 0.7329645156860352, 0.432547926902771, -0.8374496102333069, -0.1500765085220337, -0.9323380589485168, 0.5096015334129333, -0.14838048815727234, -0.35250499844551086, 0.2970975637435913, 0.48300421237945557, 1.3367880582809448, -0.03222239762544632, 0.04670420661568642, 1.2505613565444946, -1.4453448057174683, 1.4394365549087524, -0.6703428626060486, 0.2644713521003723, -2.3947417736053467, 1.4023076295852661, -0.7698463797569275, 1.8652557134628296, -2.6172542572021484, 0.4191308915615082, -0.5917977094650269, -0.49258896708488464, 0.2789534330368042, -0.39686664938926697, 0.15072116255760193, -0.12465441226959229, -1.0388449430465698, -0.07768252491950989, -0.7062051892280579, 0.5778265595436096, 1.172428846359253, 1.3073042631149292, -1.039700984954834, -0.32478728890419006, -1.7630643844604492, -0.15871214866638184, -0.580815315246582, 0.33151358366012573, -1.9878718852996826, -0.20510560274124146, -1.997524619102478, -2.4221396446228027, -1.4201016426086426, -0.8579733371734619, 1.052305817604065, 0.15816572308540344, -0.9752810597419739, 1.1457405090332031, -0.42664432525634766, -1.823190450668335, 1.097705364227295, -2.1953012943267822 ]
https://github.com/huggingface/datasets/issues/5222
HuggingFace website is incorrectly reporting that my datasets are pickled
Yes I think I know what is happening. We check in zips for pickles, and the UI must display the pickle jar when a scan has an associated list of imports, even when empty. ~I'll fix ASAP !~
### Describe the bug HuggingFace is incorrectly reporting that my datasets are pickled. They are not picked, they are simple ZIP files containing PNG images. Hopefully this is the right location to report this bug. ### Steps to reproduce the bug Inspect my dataset respository here: https://huggingface.co/datasets/ProGamerGov/StableDiffusion-v1-5-Regularization-Images ### Expected behavior They should not be reported as being pickled. ### Environment info N/A
432
38
HuggingFace website is incorrectly reporting that my datasets are pickled ### Describe the bug HuggingFace is incorrectly reporting that my datasets are pickled. They are not picked, they are simple ZIP files containing PNG images. Hopefully this is the right location to report this bug. ### Steps to reproduce the bug Inspect my dataset respository here: https://huggingface.co/datasets/ProGamerGov/StableDiffusion-v1-5-Regularization-Images ### Expected behavior They should not be reported as being pickled. ### Environment info N/A Yes I think I know what is happening. We check in zips for pickles, and the UI must display the pickle jar when a scan has an associated list of imports, even when empty. ~I'll fix ASAP !~
[ -1.0278323888778687, -0.9593296647071838, -0.7739267945289612, 1.3790059089660645, -0.12511217594146729, -1.3747193813323975, 0.05607408285140991, -1.0936943292617798, 1.6110087633132935, -0.8396238684654236, 0.3010099232196808, -1.7182331085205078, 0.04131099209189415, -0.5545557141304016, -0.612694263458252, -0.9594866037368774, -0.3506695032119751, -0.7578669190406799, 1.047896146774292, 2.6285362243652344, 1.1382020711898804, -1.3800146579742432, 2.7192800045013428, 0.6913490891456604, -0.33504948019981384, -1.0103156566619873, 0.7228329181671143, 0.07038144767284393, -1.2819316387176514, -0.413315087556839, -1.0116078853607178, -0.02152227982878685, -0.4933643937110901, -0.5402513742446899, 0.014089120551943779, 0.2934272587299347, -0.09932973235845566, -0.31779906153678894, -0.5197194218635559, -0.6989938616752625, 0.4947032630443573, -0.46459662914276123, 1.023563027381897, -0.46221986413002014, 1.9297019243240356, -0.49664217233657837, 0.37224042415618896, 0.6789639592170715, 1.4382370710372925, 0.17671850323677063, -0.07854127883911133, 0.2773788869380951, 0.39879611134529114, -0.01593026891350746, 0.3660816252231598, 1.036277413368225, 0.6100683212280273, 0.47944703698158264, 0.704213559627533, -2.1083335876464844, 1.2668640613555908, -0.8995466828346252, 0.2596728503704071, 1.3527299165725708, -0.9974154233932495, 0.4312345087528229, -1.72746741771698, -0.1116260439157486, 0.48634180426597595, -2.299039125442505, 0.11352936178445816, -1.140647053718567, -0.5144085884094238, 0.9924070239067078, 0.2956145703792572, -1.3706893920898438, -0.008550077676773071, -0.5074554681777954, 1.0029356479644775, 0.5188784003257751, 1.1627227067947388, -1.6504729986190796, -0.06357957422733307, -0.3679842948913574, -0.0992637649178505, -1.4373884201049805, -1.4464085102081299, 0.567035436630249, 0.7644467949867249, 0.6654430031776428, 0.0435183010995388, 0.8695235848426819, -1.0101842880249023, 0.758102536201477, -0.776004433631897, -1.7683899402618408, -1.3330297470092773, -2.442439079284668, -2.343254566192627, 0.9001209735870361, -0.5163052678108215, -0.5905340313911438, 2.0699784755706787, -1.1239010095596313, -1.7709965705871582, 1.2330896854400635, 0.15875795483589172, 0.02194959670305252, 2.499253511428833, 0.29648613929748535, -0.690620481967926, 0.3881450295448303, -0.6775460243225098, 0.8349224925041199, -0.5585048198699951, 1.4087116718292236, 0.43870678544044495, -1.0139437913894653, 1.6867427825927734, -0.5044617652893066, 0.5156785249710083, -0.7558374404907227, -0.5153714418411255, -0.8964999318122864, 0.4555406868457794, 1.835113763809204, -0.40533575415611267, 1.648558259010315, -0.36617311835289, -1.546916127204895, -1.6316566467285156, 0.7825345993041992, 0.4881959855556488, -0.8033170104026794, 0.14193350076675415, -0.30827316641807556, -0.07436739653348923, 0.06749877333641052, 1.0478484630584717, 1.1662847995758057, 0.5510314702987671, -0.29780831933021545, -0.97874915599823, 0.34735241532325745, -0.11645720154047012, -0.6946907043457031, -1.8994698524475098, -0.4063495397567749, 0.028988827019929886, 0.6317623853683472, -1.2996052503585815, 1.6536096334457397, 0.9137060642242432, 1.9449208974838257, 1.0283039808273315, -0.3393626809120178, 1.450171709060669, 0.05329976975917816, 1.8499969244003296, -0.44042158126831055, 0.7743385434150696, -0.33838871121406555, -1.192098617553711, 0.6912097930908203, -0.38634008169174194, -1.9503540992736816, -0.8007529377937317, -0.9754056930541992, -0.1687282919883728, -0.7602161169052124, 1.039573073387146, -0.36694952845573425, -1.2582471370697021, 0.2952323853969574, -0.60267174243927, 0.12999019026756287, -1.3612312078475952, 0.30778875946998596, 0.7594652771949768, -0.6965204477310181, 0.06173066049814224, -0.3575770854949951, -1.3176586627960205, -0.43022748827934265, 0.2387271225452423, 1.8964921236038208, -0.8276342153549194, 0.9164054989814758, 0.9575097560882568, -0.5973730087280273, 0.03697386011481285, 0.3286849856376648, -0.33569592237472534, 0.8100127577781677, -1.0807182788848877, -0.3798241913318634, 1.183154582977295, -0.20673781633377075, -0.6228110194206238, 1.384049415588379, 0.8054063320159912, -1.0008721351623535, -0.12986494600772858, -0.30679184198379517, -0.8392162919044495, -0.019113298505544662, -1.7352797985076904, -0.12100697308778763, 0.2175542712211609, -1.470569133758545, -0.4924848675727844, -0.21340394020080566, 1.3076424598693848, 0.003670903854072094, 1.3164056539535522, -0.35446134209632874, -0.33717215061187744, -0.395291805267334, -0.46411681175231934, 0.28434738516807556, -0.2173767387866974, -0.6216160655021667, 0.34780579805374146, -0.7876861691474915, 0.21693730354309082, 1.396864652633667, 0.373463898897171, 0.13082826137542725, 0.6372235417366028, 0.9380580186843872, 0.38858458399772644, -0.20701497793197632, -0.9482475519180298, -1.5339621305465698, 2.145765781402588, -1.4963454008102417, 1.9041720628738403, 0.858849823474884, -0.14107531309127808, -1.8306807279586792, -1.92793869972229, 1.3677434921264648, 1.3139756917953491, 2.275969982147217, 0.5389857292175293, 0.41917678713798523, -0.7504743933677673, -0.6644014120101929, 0.38572177290916443, -0.9832175970077515, -0.8079797029495239, 0.017375916242599487, 2.3478736877441406, 1.8080137968063354, -0.46085360646247864, -0.1348336935043335, -1.0302493572235107, 1.2484055757522583, -0.10919291526079178, 0.2626257836818695, 2.040816307067871, -0.4789813160896301, -1.1253421306610107, 1.1789331436157227, -2.3470826148986816, 0.08901162445545197, 1.9895201921463013, 0.2047128677368164, 0.076418936252594, -1.5002833604812622, -0.7146146297454834, -0.26768630743026733, -0.39720311760902405, -1.2047804594039917, 0.549370288848877, -0.3080880045890808, -0.9162185192108154, -1.558862566947937, 0.1685435175895691, -1.2133264541625977, -1.6959948539733887, 0.36750316619873047, 1.887101650238037, 2.067843437194824, -0.8292086720466614, 1.5111457109451294, -0.11798028647899628, 0.1973562240600586, 1.16965913772583, 1.1250485181808472, 3.096465587615967, 2.0608103275299072, -1.209835171699524, 0.6969383358955383, -0.025814536958932877, -0.5308929681777954, 1.0458167791366577, -0.9963897466659546, 1.294393539428711, -0.17156603932380676, -1.218529462814331, -1.2915942668914795, 0.8365535140037537, 0.47892266511917114, 0.016827048733830452, -0.4649156332015991, 1.4100252389907837, 0.07131263613700867, 1.2552820444107056, 0.5193073153495789, -0.3686661124229431, 0.5395488142967224, -0.48102113604545593, -0.508338451385498, 1.518315315246582, 0.33094748854637146, -1.5496083498001099, -2.229487180709839, -0.3090206980705261, -0.7888842821121216, -0.1428840458393097, -0.6612715125083923, -0.9851649403572083, 1.5589288473129272, 0.4845011234283447, -1.090985655784607, -0.43684157729148865, -0.35551944375038147, -0.6271164417266846, 2.661064624786377, -1.5088578462600708, -0.15007370710372925, -0.927569568157196, -0.45342791080474854, 1.5990324020385742, -1.3094040155410767, -0.08604929596185684, -1.0983842611312866, -0.6362971663475037, -1.316559910774231, -0.5219671130180359, -0.10364044457674026, -0.9337028861045837, 0.7532798051834106, 0.21823877096176147, -1.0411921739578247, -0.22209084033966064, -0.9389898777008057, 0.7991440296173096, -0.03469286113977432, 0.337092787027359, 1.803800106048584, 0.5003243684768677, -0.44188711047172546, 0.6838560700416565, 1.2495746612548828, 0.6285133361816406, -0.7283269166946411, 0.1979530155658722, -0.705001175403595, 0.31685876846313477, -1.2468841075897217, 0.2687758803367615, -2.884040117263794, 0.6349350214004517, -0.16042926907539368, -0.11949558556079865, 0.029482092708349228, -1.3054697513580322, 1.1073542833328247, 2.5023326873779297, -1.201096534729004, 0.5162959694862366, 0.30093076825141907, 1.2844901084899902, -1.513521671295166, 0.3665529489517212, -0.4283052086830139, 2.071291446685791, 0.09874026477336884, 1.2156494855880737, -0.5445103645324707, -2.173233985900879, 0.6912786364555359, -1.2360289096832275, -1.117518424987793, 0.7515860795974731, -0.7996659874916077, 0.06329707056283951, -1.488879919052124, -0.028487829491496086, -0.8016872406005859, -1.3716583251953125, 0.6784372329711914, 0.15844306349754333, 0.5484446287155151, -0.5077388286590576, 0.2827688455581665, -2.124398946762085, -1.396593689918518, -0.2122848927974701, -0.9681891798973083, 0.3452702760696411, -0.3140917718410492, 0.7374584078788757, -0.20317044854164124, 0.11179239302873611, 0.3524715006351471, 1.3514076471328735, 3.435696840286255, 0.16963231563568115, 0.48666873574256897, -0.054902296513319016, -1.0468188524246216, 1.4405765533447266, 0.9610522389411926, -0.10369554907083511, -0.6054372787475586, -0.9481902718544006, 1.3376845121383667, 1.995932936668396, 1.0966235399246216, 0.10488487780094147, -0.7614290714263916, -0.5829303860664368, -0.020365657284855843, 0.333310067653656, 0.5841854214668274, 0.9780151844024658, -0.05698764696717262, 0.08959583193063736, 1.515053391456604, 1.2415608167648315, -0.537863552570343, 0.4573870301246643, -0.8482797741889954, -0.44071778655052185, 0.46431851387023926, 0.36504244804382324, 0.08227362483739853, 0.3545469343662262, -0.9667659401893616, -0.31560254096984863, -0.29247865080833435, -0.8800120949745178, -0.7166431546211243, -0.29685553908348083, -0.41740038990974426, 1.6312952041625977, 0.03434271365404129, -0.5038031935691833, 0.020019251853227615, -0.7283222675323486, -0.11413309723138809, -0.9835671782493591, 0.2502197027206421, -0.08378122746944427, -0.10264921933412552, 0.009286666288971901, 1.7925082445144653, -0.9990300536155701, -2.2216176986694336, 0.2934158742427826, 0.2562929689884186, -0.26595425605773926, 0.18217456340789795, 1.6153795719146729, 0.5239041447639465, 1.363952875137329, 1.3387988805770874, 1.02705717086792, -0.7468335032463074, -1.357375144958496, 0.7001991271972656, 1.0475876331329346, -1.4192075729370117, 0.8039655685424805, -0.12282399088144302, -0.5294406414031982, 0.6920841932296753, 1.2914458513259888, 0.45436981320381165, -1.8201310634613037, 0.8856527209281921, -0.8728352785110474, 0.7773315906524658, 0.7276871800422668, 0.8207691311836243, 0.3005697429180145, 0.8023715615272522, -1.2572739124298096, -1.1559562683105469, -0.8791094422340393, -0.6221132874488831, 1.914059042930603, -0.2102002203464508, 0.47179070115089417, -0.15384411811828613, -1.275909423828125, -0.07290206104516983, 0.6017231941223145, 0.24696865677833557, -0.31893646717071533, 0.8177978992462158, -0.6740150451660156, -1.165885090827942, -1.5916298627853394, -0.36392831802368164, -0.99169921875, -0.8793154358863831, 1.1288518905639648, 0.8491107225418091, 0.23578932881355286, 1.9157532453536987, 0.5827794075012207, 0.2247709333896637, -2.6419990062713623, 0.9711206555366516, 0.3132130801677704, -0.02923455461859703, 0.8763864636421204, 0.26225554943084717, 1.0697396993637085, -0.021774359047412872, 0.4971918761730194, -2.2998123168945312, 2.3404440879821777, -0.3291519284248352, 0.6815873980522156, 0.04216108098626137, -0.10013952851295471, 1.0611305236816406, 0.5239667296409607, 0.698299765586853, -1.0026533603668213, 0.7516764998435974, -0.5974768400192261, 1.1676185131072998, 1.077666163444519, -0.8701549768447876, 0.07216447591781616, 1.2726799249649048, 0.635943591594696, -0.5160274505615234, -0.8650749325752258, -0.8581994771957397, 0.8257472515106201, 1.7529903650283813, -0.07751171290874481, -0.013965504243969917, 0.8009055852890015, 0.5009617209434509, -1.3156002759933472, 0.047601375728845596, -0.711656928062439, -0.6701968908309937, 1.6233149766921997, 2.028881788253784, -0.08709727227687836, -0.18006497621536255, -0.7432718276977539, -1.1920034885406494, 0.7932162880897522, -0.0785578265786171, 0.15649950504302979, 0.7880722284317017, -0.69730544090271, 1.1678099632263184, 0.8110541701316833, 0.8320530652999878, 0.14617189764976501, 0.24071455001831055, 0.30392736196517944, -0.1793290078639984, -1.1009958982467651, -0.27059900760650635, -1.1398799419403076, -2.496802568435669, 0.38902536034584045, -0.38758572936058044, -1.4045912027359009, 0.015387220308184624, -1.0587785243988037, 0.9527261257171631, -0.5292876958847046, -0.9507831931114197, -1.53114652633667, 0.16638830304145813, -0.20115569233894348, 0.8558485507965088, -1.6839067935943604, -0.12204257398843765, 1.3360213041305542, 0.9145503044128418, -0.6190298199653625, 1.0403255224227905, 0.2873212993144989, 1.074414849281311, 0.8151963949203491, -0.31009984016418457, 0.4035990238189697, 0.13669613003730774, -1.320467233657837, 0.5463994145393372, 1.0521436929702759, 0.10251572728157043, 1.3103301525115967, -0.6037327647209167, 0.09685845673084259, 0.4909493029117584, -0.36938607692718506, -0.42367982864379883, -0.5345205068588257, 0.7861644625663757, 0.10656264424324036, -0.8938719034194946, 0.07299982011318207, -0.2582308053970337, -0.27458497881889343, 0.22309339046478271, -1.533820390701294, -0.3594991862773895, -0.3610422909259796, -0.5319299697875977, -1.2844977378845215, -0.007037740666419268, 1.4117236137390137, -0.7642194032669067, -0.2640087902545929, 0.5508642196655273, 0.4413107633590698, 0.5549401044845581, 0.7284722924232483, -0.649314284324646, -0.2757152318954468, -0.3148161768913269, -0.3000621795654297, 0.29200151562690735, 1.3433958292007446, -0.2121318280696869, -1.0335434675216675, 0.8147058486938477, -0.3398888111114502, 0.13544011116027832, 2.0404052734375, 0.13388893008232117, -0.9628219604492188, 0.2595539391040802, -0.7150500416755676, 1.9275485277175903, 1.5664385557174683, 1.2904123067855835, -0.0836109146475792, -0.883374810218811, 0.6218323707580566, -0.08359233289957047, -0.24181988835334778, 0.9132940173149109, 0.5153461694717407, -0.20138242840766907, -1.3944088220596313, 0.5605509281158447, 1.1707088947296143, -0.872832179069519, -0.7677536606788635, 0.09563590586185455, -0.822316586971283, 1.1395784616470337, 0.8017231225967407, 0.46610358357429504, 0.18546763062477112, 1.6289242506027222, 0.7145689129829407, -0.5670801997184753, 0.41487523913383484, 0.44761767983436584, -0.18008294701576233, -1.9388285875320435, -0.9142236709594727, 0.29271188378334045, -0.42128363251686096, -1.6041123867034912, 1.3398211002349854, -1.2670199871063232, -0.8172994256019592, 0.4700618088245392, 0.0619305819272995, 1.49457848072052, 0.35486844182014465, 1.6365455389022827, 2.0120065212249756, 0.9851760864257812, 0.3061341643333435, 1.340122103691101, -0.14645642042160034, -0.3139430284500122, 1.7395440340042114, -0.3436301648616791, 0.3336535096168518, 1.123435616493225, -0.48560982942581177, -0.9218990206718445, -0.7385391592979431, -1.090610146522522, -0.4849950075149536, 1.1554157733917236, 0.16173440217971802, -1.1509757041931152, 0.15609583258628845, 1.4335054159164429, 0.049735598266124725, -0.3003232181072235, 0.4563334286212921, 0.5049386024475098, -0.7321931719779968, -0.09329081326723099, -0.9398962259292603, 0.5522298812866211, -0.25487980246543884, -0.33394330739974976, 0.37351152300834656, 0.5297689437866211, 1.2668644189834595, -0.08684936910867691, 0.36071911454200745, 1.3114960193634033, -1.3940303325653076, 1.3650736808776855, -0.6380500197410583, 0.1042497530579567, -2.2293829917907715, 1.4674304723739624, -0.6923400163650513, 1.9191726446151733, -2.6744959354400635, 0.42118537425994873, -0.6469401717185974, -0.45243439078330994, 0.2895967364311218, -0.36157187819480896, 0.09903780370950699, -0.28052210807800293, -1.0393582582473755, -0.06812256574630737, -0.6459687352180481, 0.528623104095459, 1.1735519170761108, 1.1806690692901611, -0.9548776149749756, -0.299972265958786, -1.7126619815826416, -0.18353042006492615, -0.6722769737243652, 0.34250685572624207, -2.076127052307129, -0.1696123480796814, -1.9378082752227783, -2.376516819000244, -1.4241595268249512, -0.8603697419166565, 1.1313717365264893, 0.1346377432346344, -0.9030706286430359, 1.1949645280838013, -0.28659388422966003, -1.7846399545669556, 1.0373340845108032, -2.211056709289551 ]
https://github.com/huggingface/datasets/issues/5222
HuggingFace website is incorrectly reporting that my datasets are pickled
> I'll fix ASAP ! Actually I'd rather leave it like that for now, as it indicates that we checked for pickles and nothing dangerous appeared :)
### Describe the bug HuggingFace is incorrectly reporting that my datasets are pickled. They are not picked, they are simple ZIP files containing PNG images. Hopefully this is the right location to report this bug. ### Steps to reproduce the bug Inspect my dataset respository here: https://huggingface.co/datasets/ProGamerGov/StableDiffusion-v1-5-Regularization-Images ### Expected behavior They should not be reported as being pickled. ### Environment info N/A
432
27
HuggingFace website is incorrectly reporting that my datasets are pickled ### Describe the bug HuggingFace is incorrectly reporting that my datasets are pickled. They are not picked, they are simple ZIP files containing PNG images. Hopefully this is the right location to report this bug. ### Steps to reproduce the bug Inspect my dataset respository here: https://huggingface.co/datasets/ProGamerGov/StableDiffusion-v1-5-Regularization-Images ### Expected behavior They should not be reported as being pickled. ### Environment info N/A > I'll fix ASAP ! Actually I'd rather leave it like that for now, as it indicates that we checked for pickles and nothing dangerous appeared :)
[ -1.0379571914672852, -0.9646618962287903, -0.7808497548103333, 1.4214839935302734, -0.11619673669338226, -1.3187267780303955, 0.03565313667058945, -1.0618788003921509, 1.6334782838821411, -0.7935335636138916, 0.2877371609210968, -1.7413878440856934, 0.005852104164659977, -0.5518096685409546, -0.620468258857727, -0.9430760741233826, -0.34033119678497314, -0.7701818943023682, 1.0053012371063232, 2.602677345275879, 1.1447889804840088, -1.3778626918792725, 2.688534736633301, 0.708404541015625, -0.3223833441734314, -1.0867743492126465, 0.6988371014595032, 0.056120261549949646, -1.2577060461044312, -0.4259168207645416, -1.044947624206543, -0.030962586402893066, -0.5224902033805847, -0.5129045844078064, 0.039412811398506165, 0.3715469241142273, -0.09292743355035782, -0.3442622125148773, -0.5914698839187622, -0.6664941906929016, 0.5024888515472412, -0.48439279198646545, 1.0118935108184814, -0.5008866786956787, 1.9096028804779053, -0.5280849933624268, 0.3553132116794586, 0.6608589291572571, 1.4338045120239258, 0.17112749814987183, -0.08612646907567978, 0.19953382015228271, 0.40621474385261536, -0.04103139787912369, 0.3890109658241272, 1.0503590106964111, 0.6031927466392517, 0.5087641477584839, 0.6674535274505615, -2.1367478370666504, 1.2390947341918945, -0.8910328149795532, 0.2621534466743469, 1.361135721206665, -1.0536047220230103, 0.4168094992637634, -1.7169585227966309, -0.11730573326349258, 0.5120212435722351, -2.247122287750244, 0.10376732051372528, -1.1035538911819458, -0.4841524660587311, 1.0026353597640991, 0.2893359661102295, -1.358498454093933, -0.025695284828543663, -0.44050535559654236, 1.0234801769256592, 0.5035139918327332, 1.1525155305862427, -1.666467547416687, -0.013641438446938992, -0.3628406524658203, -0.11778979748487473, -1.4048426151275635, -1.4096521139144897, 0.5498933792114258, 0.7607235312461853, 0.6951221227645874, 0.039520084857940674, 0.9060803055763245, -1.0301073789596558, 0.7578061819076538, -0.8153156638145447, -1.7512602806091309, -1.2859951257705688, -2.4555561542510986, -2.3256804943084717, 0.8598262071609497, -0.4979540705680847, -0.5900828838348389, 2.080636501312256, -1.105224609375, -1.8247220516204834, 1.2438098192214966, 0.18466076254844666, 0.0368172749876976, 2.514988660812378, 0.29406869411468506, -0.6892651319503784, 0.43224284052848816, -0.677736759185791, 0.8468625545501709, -0.5630504488945007, 1.3925561904907227, 0.42806851863861084, -1.00281822681427, 1.7010120153427124, -0.523377537727356, 0.5599738359451294, -0.7099045515060425, -0.5253801941871643, -0.8935111165046692, 0.4406205117702484, 1.8571908473968506, -0.3505544364452362, 1.6628928184509277, -0.28651925921440125, -1.5617823600769043, -1.6092545986175537, 0.7855143547058105, 0.46040862798690796, -0.7970592379570007, 0.1547698974609375, -0.3332901895046234, -0.021190084517002106, 0.031482771039009094, 1.0806573629379272, 1.1783626079559326, 0.6271926760673523, -0.2624354064464569, -1.0029184818267822, 0.35901081562042236, -0.08418522775173187, -0.695722758769989, -1.8087196350097656, -0.4350237250328064, 0.04059816896915436, 0.6103527545928955, -1.2725223302841187, 1.6783617734909058, 0.9482440948486328, 1.925681471824646, 1.0253369808197021, -0.3162830173969269, 1.4479559659957886, 0.013871327042579651, 1.8131159543991089, -0.4312596917152405, 0.7654009461402893, -0.3818358778953552, -1.2225351333618164, 0.6874282360076904, -0.41117188334465027, -1.9072753190994263, -0.8109837174415588, -0.9691470265388489, -0.12217796593904495, -0.7512115240097046, 1.0365551710128784, -0.3243809938430786, -1.2612429857254028, 0.3204765021800995, -0.6234579682350159, 0.1921849548816681, -1.2983882427215576, 0.36472368240356445, 0.7977504730224609, -0.6882797479629517, 0.0347474068403244, -0.2904506027698517, -1.3227959871292114, -0.4106890559196472, 0.2465030550956726, 1.9264384508132935, -0.8126255869865417, 0.8932106494903564, 0.917961835861206, -0.6438392400741577, 0.02189132384955883, 0.29500898718833923, -0.3035162091255188, 0.8229467868804932, -1.0952870845794678, -0.4140703082084656, 1.2026286125183105, -0.21358716487884521, -0.6556001901626587, 1.4136836528778076, 0.7796115875244141, -0.9875891208648682, -0.1445198357105255, -0.3455904722213745, -0.7519756555557251, -0.04299081116914749, -1.7225277423858643, -0.07440979778766632, 0.2973814308643341, -1.4053224325180054, -0.5212691426277161, -0.16028185188770294, 1.3228152990341187, 0.018759800121188164, 1.3261003494262695, -0.33004677295684814, -0.30985090136528015, -0.37789204716682434, -0.5222468376159668, 0.25381919741630554, -0.2359728068113327, -0.5937038064002991, 0.27395811676979065, -0.7781825661659241, 0.2367984652519226, 1.4241576194763184, 0.36180830001831055, 0.09960010647773743, 0.6350480318069458, 0.960080623626709, 0.4021739363670349, -0.19788898527622223, -0.9593770503997803, -1.4897072315216064, 2.087599515914917, -1.469799518585205, 1.961955189704895, 0.8359257578849792, -0.19219274818897247, -1.7643579244613647, -1.9567502737045288, 1.423267126083374, 1.309362769126892, 2.2675650119781494, 0.6009207963943481, 0.4162277281284332, -0.8310137391090393, -0.6885932087898254, 0.3563570976257324, -1.0102534294128418, -0.7823378443717957, -0.011332783848047256, 2.349496841430664, 1.8334048986434937, -0.5017722845077515, -0.16191770136356354, -1.0074763298034668, 1.1993707418441772, -0.15212272107601166, 0.2143232822418213, 2.0674805641174316, -0.44684141874313354, -1.16184663772583, 1.2203322649002075, -2.3676934242248535, 0.0659269317984581, 2.0423583984375, 0.21505551040172577, 0.12844762206077576, -1.4989728927612305, -0.6527955532073975, -0.28049755096435547, -0.30744844675064087, -1.243972659111023, 0.6294010281562805, -0.2992888391017914, -0.8873001337051392, -1.5267692804336548, 0.19592054188251495, -1.1919339895248413, -1.7067322731018066, 0.35589858889579773, 1.8325515985488892, 2.0564377307891846, -0.8596245050430298, 1.478005051612854, -0.0744505301117897, 0.2097650170326233, 1.2183679342269897, 1.111438274383545, 3.0918264389038086, 2.0914433002471924, -1.2344282865524292, 0.6689869165420532, -0.10804262012243271, -0.5902786254882812, 1.1284278631210327, -1.0034308433532715, 1.277005910873413, -0.23440895974636078, -1.2932850122451782, -1.3451268672943115, 0.887794017791748, 0.4928331971168518, -0.00851012859493494, -0.4787357747554779, 1.4309971332550049, 0.06614162772893906, 1.2381644248962402, 0.46637433767318726, -0.371681809425354, 0.5793552994728088, -0.5316168069839478, -0.4301984906196594, 1.5347658395767212, 0.32106858491897583, -1.5782302618026733, -2.1995327472686768, -0.2819518744945526, -0.8181900978088379, -0.1512121707201004, -0.6730016469955444, -1.03432035446167, 1.5603004693984985, 0.46590983867645264, -1.1576892137527466, -0.43600744009017944, -0.333956778049469, -0.6791400909423828, 2.664245128631592, -1.4974207878112793, -0.16086019575595856, -0.9540024995803833, -0.5078367590904236, 1.6085366010665894, -1.282577395439148, -0.09035924077033997, -1.0708584785461426, -0.614441454410553, -1.3555405139923096, -0.5441688895225525, -0.10095138102769852, -0.906183123588562, 0.731837272644043, 0.2721419334411621, -1.0891284942626953, -0.20416873693466187, -0.9148375391960144, 0.7800503969192505, -0.0477844774723053, 0.2943260371685028, 1.7859208583831787, 0.4414050281047821, -0.38934454321861267, 0.7100392580032349, 1.2865511178970337, 0.6514026522636414, -0.7138951420783997, 0.210506409406662, -0.699039101600647, 0.35797715187072754, -1.301672339439392, 0.22491642832756042, -2.91796875, 0.6684219241142273, -0.19326625764369965, -0.11657902598381042, 0.0561022087931633, -1.2325429916381836, 1.0881942510604858, 2.5267367362976074, -1.1880210638046265, 0.5521324276924133, 0.2856810986995697, 1.308858036994934, -1.4741690158843994, 0.3254011273384094, -0.46119368076324463, 2.103381633758545, 0.056521959602832794, 1.2445741891860962, -0.5569060444831848, -2.1999683380126953, 0.6870781779289246, -1.2648333311080933, -1.1382883787155151, 0.7080585956573486, -0.8620641231536865, 0.012839274480938911, -1.4329713582992554, -0.07655339688062668, -0.8596766591072083, -1.3703444004058838, 0.6573308110237122, 0.10831765830516815, 0.4999657869338989, -0.5137995481491089, 0.266274631023407, -2.1366727352142334, -1.433746576309204, -0.22066542506217957, -1.0222641229629517, 0.3532382845878601, -0.35838037729263306, 0.7467775344848633, -0.24252255260944366, 0.11099240183830261, 0.32805973291397095, 1.369631290435791, 3.411405563354492, 0.17497195303440094, 0.5385044813156128, -0.061256684362888336, -1.0671461820602417, 1.495495080947876, 0.9498339295387268, -0.14166854321956635, -0.6060406565666199, -0.9179261326789856, 1.3464657068252563, 1.9210549592971802, 1.1013323068618774, 0.06203506886959076, -0.723950982093811, -0.5722798109054565, -0.07265862077474594, 0.27986854314804077, 0.5836726427078247, 0.9898111820220947, -0.05280841141939163, 0.09536635130643845, 1.4707871675491333, 1.1771867275238037, -0.47912347316741943, 0.40267080068588257, -0.8387842774391174, -0.45212265849113464, 0.5063965320587158, 0.357102632522583, 0.07932036370038986, 0.35804644227027893, -0.9806705713272095, -0.3251916170120239, -0.26359546184539795, -0.8389757871627808, -0.7517855763435364, -0.31206339597702026, -0.38900673389434814, 1.6379128694534302, -0.02226901613175869, -0.5283984541893005, -0.0007561072707176208, -0.7934512495994568, -0.08872409164905548, -0.9985001087188721, 0.22735539078712463, -0.09396296739578247, -0.12506252527236938, -0.03530975058674812, 1.8106943368911743, -1.0545083284378052, -2.2157773971557617, 0.30762532353401184, 0.3058924078941345, -0.2593715488910675, 0.15005291998386383, 1.60128915309906, 0.5689327120780945, 1.366886854171753, 1.3790018558502197, 1.1139445304870605, -0.7663622498512268, -1.3483479022979736, 0.720634937286377, 1.0287590026855469, -1.446805477142334, 0.8292325735092163, -0.1276201456785202, -0.47044792771339417, 0.6212156414985657, 1.290238857269287, 0.5066091418266296, -1.76842200756073, 0.8398224711418152, -0.9114786386489868, 0.7882335186004639, 0.7486813068389893, 0.8368083238601685, 0.2829189598560333, 0.7623059153556824, -1.2639124393463135, -1.1413723230361938, -0.8403993248939514, -0.61078280210495, 1.9338512420654297, -0.22600673139095306, 0.5268903374671936, -0.19772550463676453, -1.2723653316497803, -0.09521320462226868, 0.5806251764297485, 0.24575239419937134, -0.28402450680732727, 0.8769577145576477, -0.5994092226028442, -1.1499353647232056, -1.5300008058547974, -0.3779011070728302, -1.0118565559387207, -0.8460451364517212, 1.1138880252838135, 0.8693501353263855, 0.2576398253440857, 1.8787832260131836, 0.548106849193573, 0.25609055161476135, -2.674471855163574, 0.9579696655273438, 0.2757195830345154, -0.04606557637453079, 0.8461677432060242, 0.3179856836795807, 1.1116352081298828, -0.021482503041625023, 0.5023710131645203, -2.257385730743408, 2.3564693927764893, -0.31779745221138, 0.6603955626487732, 0.06743777543306351, -0.07472140341997147, 1.019843339920044, 0.5417098999023438, 0.6788256764411926, -1.0172334909439087, 0.745339035987854, -0.6172543168067932, 1.185465931892395, 1.099823236465454, -0.864097535610199, 0.0772947445511818, 1.3007999658584595, 0.630134642124176, -0.5391634106636047, -0.9319164156913757, -0.7513244152069092, 0.8793185353279114, 1.7578914165496826, -0.04229464381933212, -0.013026932254433632, 0.8470949530601501, 0.4531570076942444, -1.3391765356063843, 0.06237935274839401, -0.6616742014884949, -0.656281054019928, 1.6464239358901978, 2.004350423812866, -0.0853211060166359, -0.24342525005340576, -0.7443451881408691, -1.2341010570526123, 0.7460032105445862, -0.0495176687836647, 0.09442300349473953, 0.8154555559158325, -0.6731885671615601, 1.125145435333252, 0.8172396421432495, 0.8498643636703491, 0.08170734345912933, 0.24362337589263916, 0.3380047678947449, -0.20714817941188812, -1.1388875246047974, -0.20318640768527985, -1.1741646528244019, -2.51888370513916, 0.36500340700149536, -0.3840506374835968, -1.3684849739074707, -0.00893143005669117, -1.0626643896102905, 0.9927104115486145, -0.5168704390525818, -0.9427869915962219, -1.5276000499725342, 0.15450824797153473, -0.20228171348571777, 0.8554323315620422, -1.6218925714492798, -0.09588435292243958, 1.2905713319778442, 0.9551680088043213, -0.7020044922828674, 1.0122593641281128, 0.2620369493961334, 1.0524874925613403, 0.8068675994873047, -0.3393402397632599, 0.4448320269584656, 0.14559033513069153, -1.3399440050125122, 0.5192474722862244, 1.107332706451416, 0.11985748261213303, 1.295890212059021, -0.5922404527664185, 0.02963111363351345, 0.462439626455307, -0.35411369800567627, -0.3532809615135193, -0.5316293239593506, 0.7678415179252625, 0.16934028267860413, -0.9393296837806702, 0.028383461758494377, -0.2573312520980835, -0.30319082736968994, 0.2636977732181549, -1.575299859046936, -0.3403271734714508, -0.3811391592025757, -0.48735564947128296, -1.28719162940979, 0.03746883571147919, 1.3888095617294312, -0.7601447105407715, -0.26365789771080017, 0.5446726083755493, 0.36414873600006104, 0.5461215376853943, 0.6695784330368042, -0.6679059267044067, -0.264763742685318, -0.34769633412361145, -0.30527812242507935, 0.3029404580593109, 1.3168118000030518, -0.18843112885951996, -1.0545092821121216, 0.7943494319915771, -0.33843791484832764, 0.158737912774086, 1.9994451999664307, 0.11485504359006882, -0.9522451162338257, 0.24476826190948486, -0.7395092844963074, 1.8946353197097778, 1.5203793048858643, 1.2830772399902344, -0.07135174423456192, -0.8286721110343933, 0.7022687792778015, -0.11598605662584305, -0.21616403758525848, 0.829960823059082, 0.5100197792053223, -0.19415394961833954, -1.4822325706481934, 0.5447573661804199, 1.1700129508972168, -0.8575245141983032, -0.7564869523048401, 0.12187132984399796, -0.8498786091804504, 1.1550302505493164, 0.7516417503356934, 0.47463008761405945, 0.2322853058576584, 1.6356900930404663, 0.7018265724182129, -0.546208381652832, 0.4348560869693756, 0.420877605676651, -0.17451392114162445, -1.9244188070297241, -0.9308205842971802, 0.30075037479400635, -0.47721216082572937, -1.637474536895752, 1.35244619846344, -1.3173435926437378, -0.7899913191795349, 0.47750553488731384, 0.07747792452573776, 1.4918497800827026, 0.34939977526664734, 1.6242188215255737, 2.0072875022888184, 0.9771255254745483, 0.3123689293861389, 1.3394352197647095, -0.12248411774635315, -0.2313174456357956, 1.7255650758743286, -0.3711804449558258, 0.3692416548728943, 1.1496092081069946, -0.4756641685962677, -0.9882426261901855, -0.7588222622871399, -1.1279470920562744, -0.5119765400886536, 1.0663233995437622, 0.18601565062999725, -1.1864396333694458, 0.15230698883533478, 1.4572938680648804, 0.019454656168818474, -0.29395949840545654, 0.43651583790779114, 0.4891442358493805, -0.7696107625961304, -0.08241628110408783, -0.8544638156890869, 0.557557225227356, -0.24661193788051605, -0.2667660117149353, 0.3977227807044983, 0.539038360118866, 1.2615118026733398, -0.016730867326259613, 0.28165724873542786, 1.3471450805664062, -1.3394593000411987, 1.3740586042404175, -0.6229342818260193, 0.08283110707998276, -2.2491962909698486, 1.4281103610992432, -0.6656956076622009, 1.9308371543884277, -2.596003293991089, 0.4653001129627228, -0.6364670991897583, -0.4560818076133728, 0.2968921363353729, -0.39927589893341064, 0.11071771383285522, -0.2735332250595093, -1.0502268075942993, -0.07241395115852356, -0.6350255012512207, 0.5182924866676331, 1.1417826414108276, 1.2673027515411377, -0.9383841156959534, -0.2956109642982483, -1.7354696989059448, -0.14987480640411377, -0.6537714600563049, 0.32121869921684265, -2.095231056213379, -0.17891736328601837, -1.9370434284210205, -2.355947732925415, -1.368853211402893, -0.8393369317054749, 1.1382765769958496, 0.13029752671718597, -0.8930673599243164, 1.1944382190704346, -0.23417116701602936, -1.7435896396636963, 1.0025315284729004, -2.237417221069336 ]
https://github.com/huggingface/datasets/issues/5221
Cannot push
Did you run `huggingface-cli lfs-enable-largefiles` before committing or before adding ? Maybe you can try before adding Anyway I'd encourage you to split your data into several TAR archives if possible, this way the dataset can loaded faster using multiprocessing (by giving each process a subset of shards to process)
### Describe the bug I am facing the issue when I try to push the tar.gz file around 11G to HUB. ``` (venv) ╭─laptop@laptop ~/PersonalProjects/data/ulaanbal_v0 ‹main●› ╰─$ du -sh * 4.0K README.md 13G data 516K test.jsonl 18M train.jsonl 4.0K ulaanbal_v0.py 11G ulaanbal_v0.tar.gz 452K validation.jsonl (venv) ╭─laptop@laptop~/PersonalProjects/data/ulaanbal_v0 ‹main●› ╰─$ git add ulaanbal_v0.tar.gz && git commit -m 'large version' (venv) ╭─laptop@laptop ~/PersonalProjects/data/ulaanbal_v0 ‹main●› ╰─$ git push EOFoading LFS objects: 0% (0/1), 0 B | 0 B/s Uploading LFS objects: 0% (0/1), 0 B | 0 B/s, done. error: failed to push some refs to 'https://huggingface.co/datasets/bayartsogt/ulaanbal_v0' ``` I have already tried pushing a small version of this and it was working fine. So my guess it is probably because of the big file. Following I run before the commit: ``` ╰─$ git lfs install ╰─$ huggingface-cli lfs-enable-largefiles . ``` ### Steps to reproduce the bug Create a private dataset on huggingface and push 12G tar.gz file ### Expected behavior To be pushed with no issue ### Environment info - `datasets` version: 2.6.1 - Platform: Darwin-21.6.0-x86_64-i386-64bit - Python version: 3.7.11 - PyArrow version: 10.0.0 - Pandas version: 1.3.5
433
50
Cannot push ### Describe the bug I am facing the issue when I try to push the tar.gz file around 11G to HUB. ``` (venv) ╭─laptop@laptop ~/PersonalProjects/data/ulaanbal_v0 ‹main●› ╰─$ du -sh * 4.0K README.md 13G data 516K test.jsonl 18M train.jsonl 4.0K ulaanbal_v0.py 11G ulaanbal_v0.tar.gz 452K validation.jsonl (venv) ╭─laptop@laptop~/PersonalProjects/data/ulaanbal_v0 ‹main●› ╰─$ git add ulaanbal_v0.tar.gz && git commit -m 'large version' (venv) ╭─laptop@laptop ~/PersonalProjects/data/ulaanbal_v0 ‹main●› ╰─$ git push EOFoading LFS objects: 0% (0/1), 0 B | 0 B/s Uploading LFS objects: 0% (0/1), 0 B | 0 B/s, done. error: failed to push some refs to 'https://huggingface.co/datasets/bayartsogt/ulaanbal_v0' ``` I have already tried pushing a small version of this and it was working fine. So my guess it is probably because of the big file. Following I run before the commit: ``` ╰─$ git lfs install ╰─$ huggingface-cli lfs-enable-largefiles . ``` ### Steps to reproduce the bug Create a private dataset on huggingface and push 12G tar.gz file ### Expected behavior To be pushed with no issue ### Environment info - `datasets` version: 2.6.1 - Platform: Darwin-21.6.0-x86_64-i386-64bit - Python version: 3.7.11 - PyArrow version: 10.0.0 - Pandas version: 1.3.5 Did you run `huggingface-cli lfs-enable-largefiles` before committing or before adding ? Maybe you can try before adding Anyway I'd encourage you to split your data into several TAR archives if possible, this way the dataset can loaded faster using multiprocessing (by giving each process a subset of shards to process)
[ -1.2156692743301392, -0.9381448030471802, -0.6891186237335205, 1.4605247974395752, -0.0629352405667305, -1.2082252502441406, 0.08148239552974701, -0.9539744853973389, 1.6793979406356812, -0.717065691947937, 0.2957465946674347, -1.6405218839645386, -0.03197583928704262, -0.5527600049972534, -0.73908531665802, -0.8629104495048523, -0.38692790269851685, -0.7575568556785583, 1.112999439239502, 2.545576810836792, 1.2073496580123901, -1.3113675117492676, 2.7565159797668457, 0.755563497543335, -0.24734826385974884, -1.0241771936416626, 0.5440871715545654, -0.02769220620393753, -1.3588083982467651, -0.4447338879108429, -0.8404896855354309, 0.007697346620261669, -0.6132413148880005, -0.5319691896438599, 0.07369080930948257, 0.35958388447761536, -0.2411889135837555, -0.4619588553905487, -0.5384389758110046, -0.792306125164032, 0.4749777317047119, -0.4349307417869568, 0.9522087574005127, -0.32030484080314636, 1.7919669151306152, -0.6429991126060486, 0.43716827034950256, 0.711552619934082, 1.328342080116272, 0.21535517275333405, 0.08210282027721405, 0.37515270709991455, 0.4147035777568817, 0.07799789309501648, 0.5021706819534302, 1.1663304567337036, 0.6858718395233154, 0.4256681501865387, 0.6815095543861389, -2.214869737625122, 1.3025972843170166, -0.9414718151092529, 0.23080512881278992, 1.302168369293213, -0.9049887657165527, 0.35993093252182007, -1.7969048023223877, -0.07419642060995102, 0.5300284028053284, -2.246081829071045, 0.2275974154472351, -1.303769588470459, -0.4087498188018799, 0.9308282136917114, 0.3296741247177124, -1.273072361946106, 0.13052302598953247, -0.4237790107727051, 1.0319616794586182, 0.38770434260368347, 1.1217495203018188, -1.6458815336227417, -0.12949460744857788, -0.3480745553970337, 0.04230131953954697, -1.2096868753433228, -1.6002525091171265, 0.44217225909233093, 0.6731576919555664, 0.6473977565765381, -0.12695981562137604, 1.0130878686904907, -0.9824617505073547, 0.8191701769828796, -0.8961843252182007, -1.7710902690887451, -1.4747706651687622, -2.327043294906616, -2.235995292663574, 0.7410604357719421, -0.4318588376045227, -0.4704740345478058, 2.0247442722320557, -1.09132981300354, -1.7677024602890015, 1.1443771123886108, 0.31504419445991516, -0.045881401747465134, 2.3687448501586914, 0.21439705789089203, -0.7668925523757935, 0.4211198389530182, -0.7638794183731079, 0.7497513890266418, -0.4433686137199402, 1.38015878200531, 0.4499453008174896, -1.0628310441970825, 1.5994077920913696, -0.399276465177536, 0.6084664463996887, -0.7326992750167847, -0.4312034845352173, -0.8398845791816711, 0.28009170293807983, 1.8952689170837402, -0.3373028635978699, 1.598130464553833, -0.31445685029029846, -1.5689131021499634, -1.5440666675567627, 0.77313232421875, 0.4997718036174774, -0.7392582893371582, 0.11839771270751953, -0.4376992881298065, 0.08990968763828278, 0.02319319173693657, 1.0571446418762207, 1.2344719171524048, 0.7461884617805481, -0.3074618875980377, -0.8857051730155945, 0.2697288691997528, 0.028435200452804565, -0.7131356000900269, -1.8509852886199951, -0.3459338843822479, 0.20415161550045013, 0.6214141249656677, -1.2108675241470337, 1.6846426725387573, 0.8523834943771362, 2.0189177989959717, 1.0536226034164429, -0.39309972524642944, 1.5186200141906738, 0.061127014458179474, 1.829318642616272, -0.4444253444671631, 0.679391622543335, -0.3741663098335266, -1.2366379499435425, 0.8025320172309875, -0.35589611530303955, -2.1129255294799805, -0.6496256589889526, -0.7907192707061768, -0.16457299888134003, -0.7667985558509827, 0.9949888586997986, -0.33409085869789124, -1.3766372203826904, 0.22277797758579254, -0.7716529369354248, 0.0851367712020874, -1.3033061027526855, 0.23758646845817566, 0.7404781579971313, -0.5871007442474365, 0.10146427154541016, -0.1933799386024475, -1.2518730163574219, -0.45115646719932556, 0.313759446144104, 1.7503589391708374, -0.748701810836792, 0.9988498091697693, 1.051139235496521, -0.6598811149597168, 0.06045517325401306, 0.4107379615306854, -0.3323538899421692, 0.8603005409240723, -0.9980349540710449, -0.393864244222641, 1.2398860454559326, -0.22383134067058563, -0.5999993681907654, 1.4154763221740723, 0.7751528024673462, -0.9816725850105286, -0.21747548878192902, -0.06937672942876816, -0.8412320017814636, 0.05090193822979927, -1.688498854637146, -0.16067324578762054, 0.3802235424518585, -1.506895899772644, -0.45616984367370605, -0.2632717192173004, 1.34047532081604, -0.13551433384418488, 1.3862372636795044, -0.2952329218387604, -0.17672450840473175, -0.37933623790740967, -0.40077289938926697, 0.22945736348628998, -0.16056357324123383, -0.6435085535049438, 0.29821789264678955, -0.750546932220459, 0.3473803400993347, 1.4610074758529663, 0.32732099294662476, 0.08358018100261688, 0.5286443829536438, 1.07807195186615, 0.3057083189487457, -0.09198298305273056, -0.9131173491477966, -1.657486081123352, 2.074754238128662, -1.4903538227081299, 1.9772560596466064, 0.8362619280815125, -0.0649326965212822, -1.7597469091415405, -1.9345638751983643, 1.3121097087860107, 1.0666861534118652, 2.3955140113830566, 0.587834894657135, 0.3576921820640564, -0.8265140652656555, -0.6597710847854614, 0.31705009937286377, -1.0696815252304077, -0.7982118725776672, 0.05063191056251526, 2.376471996307373, 1.7491053342819214, -0.40741050243377686, -0.17627853155136108, -1.0292726755142212, 1.4164161682128906, -0.1690833419561386, 0.24474990367889404, 2.0175368785858154, -0.20833392441272736, -1.0189974308013916, 1.2311729192733765, -2.2629432678222656, 0.2796730101108551, 1.9504711627960205, 0.2574024498462677, 0.08314451575279236, -1.4620038270950317, -0.6516749858856201, -0.32669752836227417, -0.47361692786216736, -1.1961668729782104, 0.5493367314338684, -0.30225062370300293, -0.8876869082450867, -1.461124300956726, 0.09674379229545593, -1.1019805669784546, -1.714052438735962, 0.3043515682220459, 1.8882348537445068, 2.036494731903076, -0.7182068824768066, 1.5097912549972534, -0.24876812100410461, 0.17560146749019623, 1.246153473854065, 1.188381314277649, 3.1662070751190186, 1.9176121950149536, -1.249650001525879, 0.6824483275413513, -0.16717173159122467, -0.5515773296356201, 1.125322937965393, -1.1849528551101685, 1.237514853477478, -0.18371425569057465, -1.1242660284042358, -1.2009631395339966, 1.0024769306182861, 0.441602885723114, 0.029035720974206924, -0.44664210081100464, 1.1589044332504272, 0.10788093507289886, 1.2755061388015747, 0.5499485731124878, -0.23475579917430878, 0.5839881896972656, -0.3404105603694916, -0.4957604706287384, 1.5224953889846802, 0.23254966735839844, -1.4618403911590576, -2.3531527519226074, -0.23955081403255463, -0.8510897159576416, -0.00597837008535862, -0.6738471984863281, -1.0062229633331299, 1.6241192817687988, 0.3859212398529053, -1.218488097190857, -0.25032368302345276, -0.326282799243927, -0.5890079736709595, 2.697004795074463, -1.4321919679641724, -0.1125042662024498, -0.9514477252960205, -0.5461905598640442, 1.539322018623352, -1.2023299932479858, -0.19537247717380524, -1.056232213973999, -0.5431986451148987, -1.2548940181732178, -0.5758770704269409, 0.016065046191215515, -0.9237697124481201, 0.7656010985374451, 0.16600222885608673, -1.1231409311294556, -0.2851262092590332, -0.9282663464546204, 0.9476524591445923, -0.07414674013853073, 0.2355191856622696, 1.8601285219192505, 0.3775363564491272, -0.32021665573120117, 0.726535975933075, 1.0926158428192139, 0.6519251465797424, -0.6418171525001526, 0.16304998099803925, -0.7136743664741516, 0.251677930355072, -1.329006314277649, 0.29110294580459595, -2.78670597076416, 0.6954522132873535, -0.05812602862715721, -0.08525320142507553, -0.09018586575984955, -1.3424859046936035, 1.1129307746887207, 2.5822653770446777, -1.1669946908950806, 0.505530595779419, 0.2534935474395752, 1.17097008228302, -1.5618690252304077, 0.25451257824897766, -0.45633190870285034, 2.176926851272583, 0.1472032368183136, 1.2600435018539429, -0.44904088973999023, -2.3124725818634033, 0.6733300685882568, -1.1923779249191284, -1.1094285249710083, 0.8167708516120911, -0.8899888396263123, 0.05579297989606857, -1.3476974964141846, -0.17099101841449738, -0.9655906558036804, -1.2089769840240479, 0.6703115701675415, 0.08766253292560577, 0.5634734630584717, -0.6416919827461243, 0.3509436845779419, -2.226574420928955, -1.3934742212295532, -0.22857601940631866, -0.9932542443275452, 0.3913656175136566, -0.32709866762161255, 0.639255940914154, -0.13151700794696808, -0.08749496191740036, 0.40167537331581116, 1.45111882686615, 3.3463573455810547, 0.13305050134658813, 0.3166970908641815, -0.11461421102285385, -1.0060962438583374, 1.348746657371521, 0.8877821564674377, -0.12653104960918427, -0.6218494176864624, -0.9991489052772522, 1.2343599796295166, 1.968375563621521, 1.0827865600585938, 0.01989664137363434, -0.8125396370887756, -0.8083826899528503, 0.0438656248152256, 0.17335958778858185, 0.49794724583625793, 0.8937300443649292, 0.04963568598031998, 0.07791777700185776, 1.4102165699005127, 1.2016503810882568, -0.4681580066680908, 0.4374554753303528, -0.803353488445282, -0.39652830362319946, 0.45420563220977783, 0.2787263095378876, 0.009516933001577854, 0.3442552089691162, -1.0968929529190063, -0.24966572225093842, -0.3904806971549988, -0.8679984211921692, -0.8041809797286987, -0.3927111327648163, -0.34559154510498047, 1.6255899667739868, 0.07852493226528168, -0.47250163555145264, -0.010873409919440746, -0.7485480904579163, -0.08210501074790955, -0.9674917459487915, 0.2259405553340912, -0.1819906085729599, -0.017304562032222748, -0.11201398819684982, 1.6873114109039307, -1.0021977424621582, -2.122415781021118, 0.2907162010669708, 0.21638453006744385, -0.37222564220428467, 0.1219787448644638, 1.6777958869934082, 0.5950336456298828, 1.3399776220321655, 1.337976098060608, 0.9396082758903503, -0.6621942520141602, -1.2585967779159546, 0.652691125869751, 0.9966080784797668, -1.3846070766448975, 0.8522942066192627, -0.07183755934238434, -0.4857681393623352, 0.6417072415351868, 1.3467075824737549, 0.3702384829521179, -2.026719093322754, 0.8459474444389343, -0.9410703182220459, 0.8161400556564331, 0.673344612121582, 0.7147942781448364, 0.17159204185009003, 0.7308326959609985, -1.2724241018295288, -1.0913410186767578, -0.7626087069511414, -0.6548736095428467, 1.8764915466308594, -0.15239033102989197, 0.5696642994880676, -0.11319135874509811, -1.3111549615859985, -0.0612151212990284, 0.6329870223999023, 0.3230299651622772, -0.44027265906333923, 0.8181132078170776, -0.6546328067779541, -1.1980692148208618, -1.3758862018585205, -0.4657374918460846, -0.9833400845527649, -0.8643893599510193, 1.0114340782165527, 0.7645266056060791, 0.3937118351459503, 1.870558738708496, 0.6250443458557129, 0.2779828608036041, -2.676971912384033, 0.9697885513305664, 0.25740906596183777, -0.01844809390604496, 0.9090836048126221, 0.2126486599445343, 1.0468515157699585, -0.08119633048772812, 0.5266120433807373, -2.3713560104370117, 2.2903356552124023, -0.24384745955467224, 0.6796239018440247, 0.018297791481018066, -0.18535499274730682, 1.0275254249572754, 0.5646358728408813, 0.5972161889076233, -1.0857526063919067, 0.7741381525993347, -0.6153483390808105, 1.2452150583267212, 0.8634519577026367, -0.818273663520813, -0.014252716675400734, 1.342483401298523, 0.42046698927879333, -0.4464326798915863, -0.9141403436660767, -0.9466344714164734, 0.9003652334213257, 1.7850635051727295, -0.03169141709804535, 0.03505444899201393, 0.876612663269043, 0.7049289345741272, -1.326295256614685, 0.1357782781124115, -0.7300078272819519, -0.6962680816650391, 1.6348198652267456, 2.076875925064087, -0.14091643691062927, -0.2191600203514099, -0.8044623136520386, -1.183025598526001, 0.7112025618553162, 0.016708511859178543, 0.09812736511230469, 0.6419486403465271, -0.6509163975715637, 1.16388738155365, 0.8622896671295166, 0.950274646282196, 0.16373422741889954, 0.21589305996894836, 0.3384278118610382, -0.3466935455799103, -1.1728429794311523, -0.3694468140602112, -1.0456984043121338, -2.5889482498168945, 0.47782713174819946, -0.18682217597961426, -1.5084437131881714, 0.05268094688653946, -1.0297608375549316, 0.8448426723480225, -0.5583378672599792, -0.9989317655563354, -1.4816489219665527, 0.2524699866771698, -0.1458883136510849, 0.8842654228210449, -1.6424371004104614, -0.13249805569648743, 1.2658568620681763, 0.937635064125061, -0.58382648229599, 0.9779002666473389, 0.2504219710826874, 1.0214236974716187, 0.9627209305763245, -0.4132428765296936, 0.43258848786354065, 0.16202136874198914, -1.286976933479309, 0.44074010848999023, 1.2571702003479004, 0.18824386596679688, 1.4693397283554077, -0.6612136363983154, 0.022685762494802475, 0.3833019733428955, -0.5684549808502197, -0.4817988872528076, -0.5793523192405701, 0.7835683822631836, 0.08144368976354599, -0.9600486159324646, 0.0866672471165657, -0.12882398068904877, -0.12374266237020493, 0.20570991933345795, -1.6026238203048706, -0.19128479063510895, -0.2843705117702484, -0.6303648352622986, -1.2836413383483887, -0.05973521247506142, 1.378669261932373, -0.8301402926445007, -0.19254568219184875, 0.5001965165138245, 0.2530999481678009, 0.6230579018592834, 0.6689784526824951, -0.682432234287262, -0.3372449278831482, -0.27435189485549927, -0.38573697209358215, 0.33248528838157654, 1.3270213603973389, -0.025220613926649094, -0.9081970453262329, 0.6929233074188232, -0.40496164560317993, 0.057801105082035065, 2.0110042095184326, 0.09839610755443573, -0.8531908392906189, 0.38212820887565613, -0.632800281047821, 1.9135814905166626, 1.7036606073379517, 1.3143624067306519, -0.14533433318138123, -0.9959627389907837, 0.5926326513290405, -0.2704288959503174, -0.3759220838546753, 0.9161900877952576, 0.3506213426589966, -0.3057824969291687, -1.3163022994995117, 0.6195487976074219, 1.369381070137024, -0.962187647819519, -0.7922353744506836, 0.11238023638725281, -0.9191878437995911, 1.1576749086380005, 0.7262207269668579, 0.3421007990837097, 0.25061649084091187, 1.6090892553329468, 0.7729697823524475, -0.44157537817955017, 0.5912773609161377, 0.43263354897499084, -0.19487595558166504, -2.1291258335113525, -1.012869954109192, 0.3250177800655365, -0.43020978569984436, -1.556456446647644, 1.3941216468811035, -1.1895487308502197, -0.9218722581863403, 0.6313610076904297, 0.17825515568256378, 1.4527918100357056, 0.32765719294548035, 1.6249853372573853, 2.150197744369507, 0.9429942965507507, 0.3703179955482483, 1.2506179809570312, -0.1454722285270691, -0.4632200002670288, 1.7383378744125366, -0.49113428592681885, 0.5374638438224792, 1.0680862665176392, -0.4294325113296509, -1.08295738697052, -0.8378995060920715, -1.1820738315582275, -0.6577005386352539, 1.253172516822815, 0.0867030918598175, -1.167157530784607, 0.2554110884666443, 1.6412793397903442, 0.1448678970336914, -0.30738547444343567, 0.6535193920135498, 0.46412450075149536, -0.7127630710601807, -0.06748069822788239, -1.0060930252075195, 0.5046730637550354, -0.18283605575561523, -0.33178648352622986, 0.3512727618217468, 0.47933751344680786, 1.2052392959594727, -0.032661788165569305, 0.11227717995643616, 1.2209361791610718, -1.3797098398208618, 1.4731537103652954, -0.7550144195556641, 0.17792625725269318, -2.3627634048461914, 1.4263914823532104, -0.8637986183166504, 1.902161717414856, -2.578690767288208, 0.46333643794059753, -0.5756271481513977, -0.44874486327171326, 0.24478772282600403, -0.3333006203174591, 0.08837315440177917, -0.2000522017478943, -1.0778425931930542, -0.14350058138370514, -0.7874059677124023, 0.5361754298210144, 1.1374166011810303, 1.3671729564666748, -1.0650173425674438, -0.2717480957508087, -1.7323040962219238, -0.17930032312870026, -0.6877328753471375, 0.4371988773345947, -1.887190580368042, -0.1921626627445221, -1.9667441844940186, -2.358690023422241, -1.3280837535858154, -0.8906750082969666, 1.1002616882324219, 0.17230072617530823, -0.7930432558059692, 1.106844425201416, -0.3629530966281891, -1.8449639081954956, 1.0998111963272095, -2.1754021644592285 ]
https://github.com/huggingface/datasets/issues/5221
Cannot push
@lhoestq Thanks for the help! > Maybe you can try before adding It did not help But I totally got your point about split into multiple TAR archives. It really helped!
### Describe the bug I am facing the issue when I try to push the tar.gz file around 11G to HUB. ``` (venv) ╭─laptop@laptop ~/PersonalProjects/data/ulaanbal_v0 ‹main●› ╰─$ du -sh * 4.0K README.md 13G data 516K test.jsonl 18M train.jsonl 4.0K ulaanbal_v0.py 11G ulaanbal_v0.tar.gz 452K validation.jsonl (venv) ╭─laptop@laptop~/PersonalProjects/data/ulaanbal_v0 ‹main●› ╰─$ git add ulaanbal_v0.tar.gz && git commit -m 'large version' (venv) ╭─laptop@laptop ~/PersonalProjects/data/ulaanbal_v0 ‹main●› ╰─$ git push EOFoading LFS objects: 0% (0/1), 0 B | 0 B/s Uploading LFS objects: 0% (0/1), 0 B | 0 B/s, done. error: failed to push some refs to 'https://huggingface.co/datasets/bayartsogt/ulaanbal_v0' ``` I have already tried pushing a small version of this and it was working fine. So my guess it is probably because of the big file. Following I run before the commit: ``` ╰─$ git lfs install ╰─$ huggingface-cli lfs-enable-largefiles . ``` ### Steps to reproduce the bug Create a private dataset on huggingface and push 12G tar.gz file ### Expected behavior To be pushed with no issue ### Environment info - `datasets` version: 2.6.1 - Platform: Darwin-21.6.0-x86_64-i386-64bit - Python version: 3.7.11 - PyArrow version: 10.0.0 - Pandas version: 1.3.5
433
31
Cannot push ### Describe the bug I am facing the issue when I try to push the tar.gz file around 11G to HUB. ``` (venv) ╭─laptop@laptop ~/PersonalProjects/data/ulaanbal_v0 ‹main●› ╰─$ du -sh * 4.0K README.md 13G data 516K test.jsonl 18M train.jsonl 4.0K ulaanbal_v0.py 11G ulaanbal_v0.tar.gz 452K validation.jsonl (venv) ╭─laptop@laptop~/PersonalProjects/data/ulaanbal_v0 ‹main●› ╰─$ git add ulaanbal_v0.tar.gz && git commit -m 'large version' (venv) ╭─laptop@laptop ~/PersonalProjects/data/ulaanbal_v0 ‹main●› ╰─$ git push EOFoading LFS objects: 0% (0/1), 0 B | 0 B/s Uploading LFS objects: 0% (0/1), 0 B | 0 B/s, done. error: failed to push some refs to 'https://huggingface.co/datasets/bayartsogt/ulaanbal_v0' ``` I have already tried pushing a small version of this and it was working fine. So my guess it is probably because of the big file. Following I run before the commit: ``` ╰─$ git lfs install ╰─$ huggingface-cli lfs-enable-largefiles . ``` ### Steps to reproduce the bug Create a private dataset on huggingface and push 12G tar.gz file ### Expected behavior To be pushed with no issue ### Environment info - `datasets` version: 2.6.1 - Platform: Darwin-21.6.0-x86_64-i386-64bit - Python version: 3.7.11 - PyArrow version: 10.0.0 - Pandas version: 1.3.5 @lhoestq Thanks for the help! > Maybe you can try before adding It did not help But I totally got your point about split into multiple TAR archives. It really helped!
[ -1.2214797735214233, -0.9332610964775085, -0.6824793219566345, 1.4627870321273804, -0.05783301591873169, -1.1975269317626953, 0.07594025135040283, -0.9629576206207275, 1.6685229539871216, -0.7042075395584106, 0.29317954182624817, -1.6334120035171509, -0.030098002403974533, -0.5359724164009094, -0.7480785846710205, -0.8589325547218323, -0.41277599334716797, -0.7603309154510498, 1.1257414817810059, 2.5592780113220215, 1.2171640396118164, -1.3256630897521973, 2.7586121559143066, 0.7458822131156921, -0.2489313930273056, -1.029598355293274, 0.5389277935028076, -0.04209568351507187, -1.372180461883545, -0.45648449659347534, -0.8286749124526978, 0.015816055238246918, -0.6114450097084045, -0.5325984954833984, 0.07016301155090332, 0.34707778692245483, -0.22279489040374756, -0.4489627182483673, -0.5408211946487427, -0.7780965566635132, 0.470694363117218, -0.4255521297454834, 0.9563724398612976, -0.3079091012477875, 1.7931451797485352, -0.6351425051689148, 0.4609757363796234, 0.7070782780647278, 1.3364561796188354, 0.21414236724376678, 0.06620670855045319, 0.3654576539993286, 0.433492511510849, 0.07537804543972015, 0.49465978145599365, 1.1501201391220093, 0.687203586101532, 0.4170551896095276, 0.6787636280059814, -2.204765796661377, 1.308854341506958, -0.9364198446273804, 0.23698154091835022, 1.3195021152496338, -0.8985185027122498, 0.3522908687591553, -1.772430419921875, -0.07334037125110626, 0.5295628309249878, -2.2523224353790283, 0.20449964702129364, -1.2915769815444946, -0.3909871578216553, 0.9479668736457825, 0.333182156085968, -1.2781511545181274, 0.12154391407966614, -0.4306182265281677, 1.0282217264175415, 0.3997127115726471, 1.1306641101837158, -1.6638801097869873, -0.14213444292545319, -0.34060513973236084, 0.043004605919122696, -1.2170312404632568, -1.5928395986557007, 0.433896005153656, 0.6474047899246216, 0.6595879793167114, -0.10823260247707367, 1.0130876302719116, -0.9792291522026062, 0.8187209367752075, -0.8981295824050903, -1.7490328550338745, -1.4623708724975586, -2.3185596466064453, -2.2395496368408203, 0.7475594878196716, -0.4413611590862274, -0.4766421318054199, 2.018918037414551, -1.0892012119293213, -1.7621197700500488, 1.1466429233551025, 0.3118087947368622, -0.03229513019323349, 2.38102388381958, 0.20650117099285126, -0.7489733695983887, 0.39792290329933167, -0.7583337426185608, 0.7432649731636047, -0.432696670293808, 1.3742247819900513, 0.4489476680755615, -1.0611112117767334, 1.5868772268295288, -0.39440447092056274, 0.6076356172561646, -0.7162556052207947, -0.44201985001564026, -0.8442918658256531, 0.27391552925109863, 1.89139723777771, -0.3324619233608246, 1.6016323566436768, -0.32090774178504944, -1.5695254802703857, -1.5560691356658936, 0.7826362252235413, 0.4862559735774994, -0.7410376667976379, 0.10292539745569229, -0.43439140915870667, 0.08065503090620041, 0.02723650634288788, 1.0391243696212769, 1.2295883893966675, 0.7344391942024231, -0.3170331120491028, -0.9000902771949768, 0.2702639102935791, 0.0316772498190403, -0.713192880153656, -1.8393510580062866, -0.35166147351264954, 0.16954652965068817, 0.6343904137611389, -1.218254566192627, 1.671082854270935, 0.8564121127128601, 2.0148773193359375, 1.0468920469284058, -0.40651756525039673, 1.5093010663986206, 0.05827514827251434, 1.8394800424575806, -0.45668086409568787, 0.665345311164856, -0.38369637727737427, -1.242480754852295, 0.8058377504348755, -0.3558165729045868, -2.093327522277832, -0.6689490079879761, -0.783672571182251, -0.16979482769966125, -0.7629150152206421, 0.985792875289917, -0.345168799161911, -1.3786157369613647, 0.2426072210073471, -0.7663841247558594, 0.08543003350496292, -1.3000565767288208, 0.2537178099155426, 0.7502395510673523, -0.5862463712692261, 0.11593237519264221, -0.18863268196582794, -1.256725788116455, -0.45897915959358215, 0.2945818305015564, 1.758707880973816, -0.734840989112854, 1.0013463497161865, 1.0475088357925415, -0.6528252959251404, 0.052874378859996796, 0.4026625454425812, -0.3268650472164154, 0.8689317107200623, -1.011506199836731, -0.39691582322120667, 1.2433723211288452, -0.2408643364906311, -0.6114602088928223, 1.4300254583358765, 0.7876536846160889, -0.9929561614990234, -0.2156035602092743, -0.055460572242736816, -0.8374175429344177, 0.05309826135635376, -1.685370922088623, -0.16532529890537262, 0.3784501850605011, -1.5104433298110962, -0.44690755009651184, -0.2637709677219391, 1.338087558746338, -0.13377831876277924, 1.3987634181976318, -0.29941266775131226, -0.16194367408752441, -0.38664355874061584, -0.3926708400249481, 0.2226191908121109, -0.16284500062465668, -0.6271200776100159, 0.2935267686843872, -0.7523074150085449, 0.3475598394870758, 1.4651894569396973, 0.341739684343338, 0.08556453883647919, 0.5033696889877319, 1.0675456523895264, 0.3301354944705963, -0.08002280443906784, -0.9139395952224731, -1.6470593214035034, 2.102217197418213, -1.4935355186462402, 1.9638465642929077, 0.8384069204330444, -0.09117213636636734, -1.7475968599319458, -1.9288016557693481, 1.314087986946106, 1.0833243131637573, 2.401611804962158, 0.5797556042671204, 0.3694781959056854, -0.8230627775192261, -0.6617319583892822, 0.31088876724243164, -1.0684280395507812, -0.8053986430168152, 0.061759211122989655, 2.3874661922454834, 1.745863676071167, -0.4071383476257324, -0.16689248383045197, -1.0230286121368408, 1.3989479541778564, -0.14571473002433777, 0.23801960051059723, 2.007591962814331, -0.20011667907238007, -1.0295517444610596, 1.2325407266616821, -2.2673861980438232, 0.2822413742542267, 1.9535534381866455, 0.27360278367996216, 0.09755083918571472, -1.4628525972366333, -0.6573471426963806, -0.3342198431491852, -0.4739597737789154, -1.1958072185516357, 0.5571720004081726, -0.30794480443000793, -0.8906139731407166, -1.4722180366516113, 0.10663215816020966, -1.1131459474563599, -1.726011872291565, 0.29749757051467896, 1.880028486251831, 2.0461883544921875, -0.7016982436180115, 1.5106672048568726, -0.24012652039527893, 0.1738428771495819, 1.2350869178771973, 1.1995978355407715, 3.1655595302581787, 1.9252644777297974, -1.228887677192688, 0.6703998446464539, -0.16982123255729675, -0.549513578414917, 1.09779691696167, -1.1910518407821655, 1.239912986755371, -0.17275460064411163, -1.1407554149627686, -1.208482265472412, 0.9994730353355408, 0.43773406744003296, 0.025542382150888443, -0.44498196244239807, 1.171513319015503, 0.11389480531215668, 1.2910652160644531, 0.5418623685836792, -0.2186969667673111, 0.5761876702308655, -0.34998226165771484, -0.47789958119392395, 1.526073932647705, 0.24283082783222198, -1.4662327766418457, -2.3593223094940186, -0.25064408779144287, -0.8541499376296997, -0.016572197899222374, -0.6603983640670776, -0.9960166215896606, 1.6226695775985718, 0.3856847584247589, -1.2431522607803345, -0.24665802717208862, -0.32138291001319885, -0.5887610912322998, 2.7007598876953125, -1.4364079236984253, -0.12255346775054932, -0.9427012205123901, -0.553810715675354, 1.539272665977478, -1.2104219198226929, -0.18890373408794403, -1.0403246879577637, -0.5666195750236511, -1.2592122554779053, -0.5705779194831848, 0.018206752836704254, -0.9477166533470154, 0.7556082010269165, 0.17181506752967834, -1.109573483467102, -0.2794150710105896, -0.9137077927589417, 0.9315407276153564, -0.061795201152563095, 0.2574622929096222, 1.8743027448654175, 0.39135316014289856, -0.3318413197994232, 0.7046091556549072, 1.110246181488037, 0.6493443846702576, -0.6608850955963135, 0.147382453083992, -0.7190663814544678, 0.2510988712310791, -1.305054783821106, 0.27337750792503357, -2.778965950012207, 0.7091352343559265, -0.0726027861237526, -0.08761060237884521, -0.09197455644607544, -1.323256254196167, 1.13279128074646, 2.5857813358306885, -1.1708722114562988, 0.5246135592460632, 0.269624263048172, 1.1751168966293335, -1.5670017004013062, 0.25660228729248047, -0.44413483142852783, 2.188973903656006, 0.17702710628509521, 1.2653512954711914, -0.4428001344203949, -2.322697877883911, 0.6685619950294495, -1.2055208683013916, -1.1019505262374878, 0.8024395704269409, -0.8812207579612732, 0.04366888478398323, -1.3462783098220825, -0.15532545745372772, -0.9440709352493286, -1.2135528326034546, 0.6708128452301025, 0.08578047901391983, 0.5637603998184204, -0.6440863609313965, 0.3615325689315796, -2.2232372760772705, -1.3925375938415527, -0.2126627117395401, -0.9999262094497681, 0.38282716274261475, -0.3394894003868103, 0.6541261672973633, -0.14008551836013794, -0.08976873010396957, 0.40952417254447937, 1.4312547445297241, 3.363978862762451, 0.13799059391021729, 0.3064126670360565, -0.13734158873558044, -1.0091365575790405, 1.3528144359588623, 0.8963797688484192, -0.12869460880756378, -0.6101081967353821, -1.002931833267212, 1.2381737232208252, 1.9758342504501343, 1.0753284692764282, 0.031530383974313736, -0.7996143698692322, -0.8084182143211365, 0.033891309052705765, 0.17419122159481049, 0.4819565713405609, 0.8967230319976807, 0.049333442002534866, 0.0746687576174736, 1.4249532222747803, 1.211077094078064, -0.4787798523902893, 0.410793662071228, -0.8059325218200684, -0.3978593051433563, 0.46391668915748596, 0.2713909447193146, 0.003844095394015312, 0.35449281334877014, -1.0827592611312866, -0.24053874611854553, -0.39329883456230164, -0.883291482925415, -0.7966356873512268, -0.36764827370643616, -0.3378317952156067, 1.6299175024032593, 0.07121587544679642, -0.4854002892971039, 0.0027478383854031563, -0.7556968927383423, -0.09081147611141205, -0.9788362383842468, 0.2275880128145218, -0.18175943195819855, -0.010724056512117386, -0.10310453176498413, 1.691834807395935, -1.0071924924850464, -2.126096248626709, 0.2913738787174225, 0.22357840836048126, -0.37617215514183044, 0.13946284353733063, 1.6700359582901, 0.5946727991104126, 1.3501231670379639, 1.3205749988555908, 0.937527596950531, -0.6551095247268677, -1.2754228115081787, 0.6699780821800232, 0.975821852684021, -1.4000812768936157, 0.8354607224464417, -0.0676857978105545, -0.4719231426715851, 0.6375290751457214, 1.3334084749221802, 0.3716493844985962, -2.0288262367248535, 0.8578622937202454, -0.9324278235435486, 0.8375032544136047, 0.6703537702560425, 0.7062379121780396, 0.16912880539894104, 0.7291892170906067, -1.2810205221176147, -1.0971935987472534, -0.756666898727417, -0.6505216956138611, 1.8748412132263184, -0.16116781532764435, 0.5735557675361633, -0.09815628081560135, -1.2982299327850342, -0.06389118731021881, 0.6114790439605713, 0.29531413316726685, -0.45173943042755127, 0.8249580264091492, -0.6565039753913879, -1.2064626216888428, -1.393309235572815, -0.4797214865684509, -0.9837728142738342, -0.8715706467628479, 1.0161495208740234, 0.7468339204788208, 0.3915308713912964, 1.8686829805374146, 0.6070536375045776, 0.2931874096393585, -2.674509048461914, 0.9672785401344299, 0.25835156440734863, -0.01869817078113556, 0.9276869893074036, 0.21059077978134155, 1.033198356628418, -0.07070537656545639, 0.5282517671585083, -2.3657805919647217, 2.307523727416992, -0.2439502626657486, 0.6764010190963745, 0.02809881418943405, -0.18790920078754425, 1.035001277923584, 0.5953266620635986, 0.5923348069190979, -1.1092325448989868, 0.7809064984321594, -0.6155911684036255, 1.2605174779891968, 0.854869544506073, -0.8159549236297607, -0.008199606090784073, 1.3422753810882568, 0.4330546259880066, -0.4520092010498047, -0.916629433631897, -0.9526611566543579, 0.9071784019470215, 1.782419204711914, -0.04384922608733177, 0.03155536204576492, 0.8760462999343872, 0.7004125714302063, -1.3089238405227661, 0.11855509877204895, -0.7304770350456238, -0.6933103203773499, 1.61988365650177, 2.071629524230957, -0.1414652168750763, -0.23991355299949646, -0.7927241921424866, -1.1889406442642212, 0.6960803866386414, 0.0073344530537724495, 0.11627732217311859, 0.6287810206413269, -0.6649631857872009, 1.161367654800415, 0.856758713722229, 0.9454171061515808, 0.16434434056282043, 0.20869562029838562, 0.3188480734825134, -0.3605154752731323, -1.1625250577926636, -0.34727367758750916, -1.0454504489898682, -2.59714412689209, 0.461358904838562, -0.17671231925487518, -1.4922112226486206, 0.06209685653448105, -1.0493221282958984, 0.8597956895828247, -0.5511147379875183, -1.0087167024612427, -1.47386634349823, 0.23077376186847687, -0.14667969942092896, 0.8997630476951599, -1.6548703908920288, -0.1340796798467636, 1.276847004890442, 0.9431691765785217, -0.5844475030899048, 1.0003629922866821, 0.25734350085258484, 1.0207425355911255, 0.9433296918869019, -0.40965136885643005, 0.4504204988479614, 0.15987525880336761, -1.2989925146102905, 0.4490102231502533, 1.2376798391342163, 0.19624151289463043, 1.4670346975326538, -0.6684772968292236, 0.05641324073076248, 0.3905199468135834, -0.5705745220184326, -0.4801982045173645, -0.58601313829422, 0.7848541736602783, 0.06729515641927719, -0.9652913808822632, 0.0896465852856636, -0.15211515128612518, -0.12354167550802231, 0.19130609929561615, -1.6039092540740967, -0.19486814737319946, -0.3031788766384125, -0.6127710342407227, -1.2766222953796387, -0.07097320258617401, 1.3814259767532349, -0.8389245271682739, -0.19292540848255157, 0.48647406697273254, 0.2697204351425171, 0.6061752438545227, 0.685701847076416, -0.690619945526123, -0.3571712374687195, -0.27560192346572876, -0.37572282552719116, 0.3257436454296112, 1.3297362327575684, -0.033766474574804306, -0.9150447845458984, 0.7077290415763855, -0.4121365547180176, 0.05115174502134323, 2.0001299381256104, 0.09018803387880325, -0.8454869389533997, 0.37929853796958923, -0.6442593336105347, 1.9316428899765015, 1.7065223455429077, 1.3144879341125488, -0.16560257971286774, -0.9983566403388977, 0.5934767723083496, -0.27021268010139465, -0.3682281970977783, 0.9096173644065857, 0.3425310552120209, -0.3141573965549469, -1.3197481632232666, 0.6023515462875366, 1.3524137735366821, -0.9365028738975525, -0.7801520228385925, 0.11782129108905792, -0.9080902934074402, 1.1523369550704956, 0.7196994423866272, 0.3441728949546814, 0.2461593598127365, 1.6119636297225952, 0.7843369245529175, -0.45169347524642944, 0.6016730666160583, 0.4285089075565338, -0.17603416740894318, -2.126100540161133, -1.0176703929901123, 0.3200071454048157, -0.44995880126953125, -1.5526666641235352, 1.3834421634674072, -1.1768649816513062, -0.9071269035339355, 0.6305325627326965, 0.17897115647792816, 1.4502750635147095, 0.3100346028804779, 1.6244633197784424, 2.141653299331665, 0.9313148856163025, 0.3559541702270508, 1.2578614950180054, -0.13646411895751953, -0.45524075627326965, 1.7420457601547241, -0.48587119579315186, 0.5312118530273438, 1.0803300142288208, -0.43069005012512207, -1.0707659721374512, -0.8352777361869812, -1.1894878149032593, -0.6750220060348511, 1.237178921699524, 0.08066785335540771, -1.1745244264602661, 0.24870078265666962, 1.6403172016143799, 0.15402673184871674, -0.28732219338417053, 0.6326525807380676, 0.462411105632782, -0.7018908858299255, -0.0696740597486496, -1.0138880014419556, 0.5058885812759399, -0.1740243136882782, -0.34611427783966064, 0.35181593894958496, 0.45382922887802124, 1.2022372484207153, -0.03785330802202225, 0.1191798746585846, 1.2362667322158813, -1.380671739578247, 1.473199486732483, -0.7526265978813171, 0.16642695665359497, -2.3490774631500244, 1.4221863746643066, -0.8551309108734131, 1.9032303094863892, -2.5684330463409424, 0.44679248332977295, -0.5931230783462524, -0.44150876998901367, 0.26630476117134094, -0.3409308195114136, 0.1044192984700203, -0.2225268930196762, -1.067920207977295, -0.15366055071353912, -0.77569580078125, 0.5323651432991028, 1.1254198551177979, 1.3695155382156372, -1.0605214834213257, -0.27811405062675476, -1.7319562435150146, -0.18024234473705292, -0.6868044137954712, 0.44573599100112915, -1.8886295557022095, -0.196882963180542, -1.972594141960144, -2.3610680103302, -1.327826976776123, -0.8577755093574524, 1.1069453954696655, 0.1868838667869568, -0.7768799662590027, 1.1249058246612549, -0.361052930355072, -1.8343071937561035, 1.0815528631210327, -2.171753406524658 ]
https://github.com/huggingface/datasets/issues/5220
Implicit type conversion of lists in to_pandas
I think this behavior comes from PyArrow: ```python import pyarrow as pa t = pa.table({"a": [[0]]}) t.to_pandas().a.values[0] # array([0]) ``` I believe this has to do with zero-copy: you can get a pandas DataFrame without copying the buffers from arrow, and therefore end up with numpy arrays.
### Describe the bug ``` ds = Dataset.from_list([{'a':[1,2,3]}]) ds.to_pandas().a.values[0] ``` Results in `array([1, 2, 3])` -- a rather unexpected conversion of types which made downstream tools expecting lists not happy. ### Steps to reproduce the bug See snippet ### Expected behavior Keep the original type ### Environment info datasets 2.6.1 python 3.8.10
434
47
Implicit type conversion of lists in to_pandas ### Describe the bug ``` ds = Dataset.from_list([{'a':[1,2,3]}]) ds.to_pandas().a.values[0] ``` Results in `array([1, 2, 3])` -- a rather unexpected conversion of types which made downstream tools expecting lists not happy. ### Steps to reproduce the bug See snippet ### Expected behavior Keep the original type ### Environment info datasets 2.6.1 python 3.8.10 I think this behavior comes from PyArrow: ```python import pyarrow as pa t = pa.table({"a": [[0]]}) t.to_pandas().a.values[0] # array([0]) ``` I believe this has to do with zero-copy: you can get a pandas DataFrame without copying the buffers from arrow, and therefore end up with numpy arrays.
[ -1.263661503791809, -0.8906689286231995, -0.8228638768196106, 1.5893652439117432, -0.16286630928516388, -1.3324925899505615, 0.0945909321308136, -1.1061066389083862, 1.7900753021240234, -0.801214337348938, 0.35772567987442017, -1.6955809593200684, 0.1352350264787674, -0.736991286277771, -0.8385015726089478, -0.8961631655693054, -0.3476937413215637, -0.609772801399231, 1.0302666425704956, 2.5434958934783936, 1.1432907581329346, -1.368911623954773, 2.686561346054077, 0.7924637794494629, -0.21228362619876862, -0.8988685011863708, 0.5356573462486267, 0.10597878694534302, -1.326791524887085, -0.4051685333251953, -1.0075669288635254, -0.14994971454143524, -0.46365058422088623, -0.6332256197929382, -0.0184205062687397, 0.421356737613678, -0.281328022480011, -0.4360208511352539, -0.4637083411216736, -0.8695627450942993, 0.31298449635505676, -0.39563649892807007, 0.9451203942298889, -0.37368059158325195, 1.8265339136123657, -0.644978404045105, 0.4160842001438141, 0.6143660545349121, 1.385272741317749, 0.11186615377664566, -0.06322309374809265, 0.5052680373191833, 0.39173299074172974, -0.03456279635429382, 0.4649125933647156, 1.1040161848068237, 0.6588954329490662, 0.4983008801937103, 0.8337975144386292, -2.1660573482513428, 1.2917872667312622, -1.0803215503692627, 0.26138603687286377, 1.3225876092910767, -1.1255145072937012, 0.32405829429626465, -1.5838299989700317, -0.10017853230237961, 0.6329096555709839, -2.2719497680664062, 0.3070027828216553, -1.33049738407135, -0.4892166256904602, 0.9143159985542297, 0.47681376338005066, -1.2250252962112427, 0.04047761857509613, -0.4928884506225586, 0.9927728772163391, 0.3700922429561615, 1.0903593301773071, -1.6516907215118408, 0.010644089430570602, -0.37770867347717285, 0.0002604871988296509, -1.3220680952072144, -1.4339447021484375, 0.5845223069190979, 0.7423645257949829, 0.5777754783630371, -0.06821566075086594, 0.9279180765151978, -1.0160887241363525, 0.7410714030265808, -0.9404392838478088, -1.7644853591918945, -1.3870104551315308, -2.3121328353881836, -2.235851526260376, 0.7756717801094055, -0.3920941650867462, -0.6091166138648987, 2.0528602600097656, -0.9878224730491638, -1.7736644744873047, 1.1328321695327759, 0.21788007020950317, -0.11965682357549667, 2.413357734680176, 0.17380161583423615, -0.6779308915138245, 0.44028180837631226, -0.7619206309318542, 0.7639055252075195, -0.5317575931549072, 1.276854157447815, 0.38358697295188904, -1.0614707469940186, 1.6627311706542969, -0.2730546295642853, 0.5915672779083252, -0.7542768716812134, -0.38672542572021484, -0.7634401917457581, 0.32575151324272156, 1.9202221632003784, -0.2866646945476532, 1.5279812812805176, -0.2771415412425995, -1.4733548164367676, -1.6599966287612915, 0.7934145927429199, 0.44963333010673523, -0.7422745227813721, 0.18575739860534668, -0.3395989239215851, 0.12154863774776459, -0.06319557875394821, 1.2146250009536743, 1.3026772737503052, 0.6151759624481201, -0.1946328729391098, -0.8214133381843567, 0.1724577695131302, -0.053882770240306854, -0.729743480682373, -1.7407336235046387, -0.3447754383087158, 0.09480694681406021, 0.712222695350647, -1.1904981136322021, 1.8035579919815063, 0.8073721528053284, 1.8535064458847046, 1.087192416191101, -0.25302037596702576, 1.5183380842208862, 0.05858800560235977, 1.8459852933883667, -0.524642825126648, 0.7314523458480835, -0.4139760434627533, -1.1288210153579712, 0.8375281691551208, -0.46816691756248474, -2.0165657997131348, -0.6859392523765564, -0.820780873298645, -0.09249062836170197, -0.7080532908439636, 0.9732697010040283, -0.373705118894577, -1.3000134229660034, 0.3418763279914856, -0.8622310757637024, 0.07455787807703018, -1.1410166025161743, 0.30097949504852295, 0.7140653729438782, -0.5260472297668457, 0.11366963386535645, -0.2894379794597626, -1.3371975421905518, -0.3650303781032562, 0.3104228973388672, 1.9458932876586914, -0.9259283542633057, 0.9945670962333679, 0.9721118211746216, -0.6423909664154053, -0.08377288281917572, 0.39817702770233154, -0.27905675768852234, 0.9156337976455688, -1.0840214490890503, -0.3822791278362274, 1.1472811698913574, -0.1791606992483139, -0.5640486478805542, 1.517589807510376, 0.7594468593597412, -0.9436057806015015, -0.10243971645832062, -0.11736644804477692, -0.853451669216156, 0.07295412570238113, -1.7337726354599, -0.15108151733875275, 0.44310462474823, -1.535053014755249, -0.5334547758102417, -0.10898864269256592, 1.30709969997406, -0.05264908820390701, 1.3528538942337036, -0.2956378757953644, -0.24542897939682007, -0.3305055499076843, -0.3855409026145935, 0.057812370359897614, -0.18068379163742065, -0.564156174659729, 0.24612662196159363, -0.6164637804031372, 0.40678367018699646, 1.3673388957977295, 0.2705596089363098, 0.2102382332086563, 0.6647762060165405, 1.064197063446045, 0.25782477855682373, -0.05968383699655533, -0.8492823839187622, -1.674964189529419, 1.9900211095809937, -1.4168856143951416, 2.054682731628418, 0.7897859811782837, 0.0035404879599809647, -1.7099562883377075, -1.9414759874343872, 1.49531888961792, 1.2267111539840698, 2.174518585205078, 0.6364455819129944, 0.3470725417137146, -0.8515214323997498, -0.598862886428833, 0.24913060665130615, -1.0478389263153076, -0.7357994914054871, 0.09921500086784363, 2.4114508628845215, 1.7201179265975952, -0.34094613790512085, -0.23133064806461334, -1.110429048538208, 1.4378763437271118, -0.1705191433429718, 0.18674325942993164, 1.978177547454834, -0.2126494199037552, -1.0948076248168945, 1.1587458848953247, -2.3273773193359375, -0.012273658998310566, 1.9809706211090088, 0.18556062877178192, 0.06899024546146393, -1.4072219133377075, -0.7345984578132629, -0.37809908390045166, -0.3846755027770996, -1.2158199548721313, 0.5253897905349731, -0.3081423342227936, -0.7357258200645447, -1.4248197078704834, 0.16588160395622253, -1.12740159034729, -1.6423038244247437, 0.17188304662704468, 1.899113655090332, 1.9734997749328613, -0.6864134669303894, 1.6671651601791382, -0.28224819898605347, 0.19476495683193207, 1.2989368438720703, 1.2360566854476929, 3.1835570335388184, 1.9583512544631958, -1.2001224756240845, 0.6805844306945801, -0.07399606704711914, -0.37235593795776367, 1.1933016777038574, -1.2473527193069458, 1.3705135583877563, -0.04585481435060501, -1.265406847000122, -1.2295068502426147, 0.8912872076034546, 0.4353571832180023, 0.016371387988328934, -0.48003315925598145, 1.327911615371704, -0.045545630156993866, 1.279748558998108, 0.51496821641922, -0.21601402759552002, 0.5700780153274536, -0.41990160942077637, -0.4352220296859741, 1.5980722904205322, 0.2580110728740692, -1.45131254196167, -2.3621068000793457, -0.136202871799469, -0.7637116312980652, -0.013772739097476006, -0.7728694677352905, -1.0398942232131958, 1.7692972421646118, 0.3662354350090027, -1.199202060699463, -0.15254314243793488, -0.3323948085308075, -0.6441730260848999, 2.770083427429199, -1.400515079498291, -0.4011841118335724, -1.0601427555084229, -0.5183150768280029, 1.596375823020935, -1.224490761756897, -0.22926031053066254, -0.9602108597755432, -0.4417615532875061, -1.2073343992233276, -0.5540972948074341, -0.12151868641376495, -0.9667252898216248, 0.807553768157959, -0.007387612015008926, -1.215970754623413, -0.2921940088272095, -0.8846502304077148, 0.8580750226974487, -0.1328512728214264, 0.24451079964637756, 1.9622904062271118, 0.42264607548713684, -0.398208349943161, 0.7671851515769958, 1.2070162296295166, 0.7073860764503479, -0.6564429402351379, 0.32706642150878906, -0.552760899066925, 0.3027879297733307, -1.2053346633911133, 0.3191258907318115, -2.831073045730591, 0.551687479019165, -0.013559982180595398, -0.08859659731388092, 0.028771059587597847, -1.2846084833145142, 1.0928891897201538, 2.6032321453094482, -1.1224734783172607, 0.4269104301929474, 0.13938818871974945, 1.2595083713531494, -1.603389024734497, 0.33660614490509033, -0.4088344871997833, 2.1400420665740967, 0.23214691877365112, 1.1396387815475464, -0.38025152683258057, -2.302833080291748, 0.658081591129303, -1.3265637159347534, -1.1595669984817505, 0.73492431640625, -0.7772830724716187, 0.08602070808410645, -1.3472613096237183, -0.07517160475254059, -0.7276603579521179, -1.1100975275039673, 0.6477562785148621, 0.12218067049980164, 0.4419231116771698, -0.5284603834152222, 0.2776438593864441, -2.1417505741119385, -1.3319064378738403, -0.14311666786670685, -0.9520308971405029, 0.5285011529922485, -0.27899855375289917, 0.6821819543838501, -0.20320172607898712, 0.005901705473661423, 0.291451096534729, 1.4991614818572998, 3.365938425064087, 0.13647204637527466, 0.4204098582267761, -0.20007342100143433, -0.8312561511993408, 1.363694667816162, 0.9103583693504333, -0.12960952520370483, -0.6264720559120178, -0.9995352625846863, 1.319954752922058, 1.9233744144439697, 1.0048437118530273, 0.04650726169347763, -0.7979625463485718, -0.7787623405456543, -0.07381214201450348, 0.17493245005607605, 0.4277990162372589, 0.8405498266220093, 0.14602701365947723, 0.002174067310988903, 1.4873110055923462, 1.2339824438095093, -0.5110759139060974, 0.4409703016281128, -0.8866949677467346, -0.3948054611682892, 0.4974733889102936, 0.3527362644672394, 0.017749719321727753, 0.29400700330734253, -0.9719513654708862, -0.23982053995132446, -0.3539397716522217, -0.853113055229187, -0.7721288800239563, -0.34170830249786377, -0.33034563064575195, 1.7322015762329102, 0.045666612684726715, -0.5530771017074585, -0.14334681630134583, -0.7886157035827637, -0.0704343318939209, -0.9882081747055054, 0.3005318343639374, -0.1351817548274994, -0.1391061693429947, 0.0038917716592550278, 1.815399408340454, -1.0207301378250122, -2.0938808917999268, 0.2845272719860077, 0.14574913680553436, -0.3321680724620819, 0.23764055967330933, 1.5617185831069946, 0.6838295459747314, 1.4606859683990479, 1.412308931350708, 0.937539279460907, -0.7188438773155212, -1.3946053981781006, 0.6252065896987915, 0.8934808373451233, -1.4026272296905518, 0.8384902477264404, -0.0335889607667923, -0.5377060770988464, 0.5758330821990967, 1.3011362552642822, 0.5681723356246948, -2.0581514835357666, 0.6907925009727478, -0.9253333806991577, 0.8440598845481873, 0.7712568044662476, 0.6406362056732178, 0.3247346580028534, 0.7253331542015076, -1.2358323335647583, -1.190752387046814, -0.7547814249992371, -0.7126640677452087, 1.9217090606689453, -0.2906704246997833, 0.6092008352279663, -0.30834001302719116, -1.4387716054916382, -0.1280864030122757, 0.6251893639564514, 0.324160099029541, -0.4768613576889038, 0.8080686926841736, -0.7297606468200684, -1.1194909811019897, -1.3648648262023926, -0.5587589144706726, -0.963816225528717, -0.8982314467430115, 1.0809422731399536, 0.819432258605957, 0.3002926707267761, 1.945737361907959, 0.5714565515518188, 0.16382640600204468, -2.526197671890259, 0.8726484775543213, 0.2261984497308731, -0.029458018019795418, 0.7765395641326904, 0.3257540762424469, 0.9950643181800842, -0.12628398835659027, 0.4854101836681366, -2.384770154953003, 2.2980599403381348, -0.2661648094654083, 0.601435661315918, 0.006889311596751213, -0.01965675875544548, 1.091747522354126, 0.5397486686706543, 0.5410749912261963, -0.9519822597503662, 0.538440465927124, -0.6154009103775024, 1.381805181503296, 0.8642271757125854, -0.8067649602890015, -0.07960717380046844, 1.2910590171813965, 0.5303273797035217, -0.5753676891326904, -0.9228317737579346, -1.0404362678527832, 0.8823605179786682, 1.7221670150756836, -0.004031859338283539, 0.011457301676273346, 0.8121311068534851, 0.5736699104309082, -1.244362711906433, 0.06975109130144119, -0.7638617753982544, -0.7608137130737305, 1.6739073991775513, 2.1154892444610596, -0.24994820356369019, -0.14775139093399048, -0.7292652726173401, -1.215185523033142, 0.787319540977478, 0.011437321081757545, -0.006670226342976093, 0.6778683066368103, -0.5727889537811279, 1.0777665376663208, 0.9956188797950745, 0.9099138379096985, 0.23314590752124786, 0.2859945297241211, 0.2616148591041565, -0.2963283658027649, -1.2027071714401245, -0.30793967843055725, -0.9908260703086853, -2.5022168159484863, 0.43553611636161804, -0.31168317794799805, -1.4402449131011963, 0.01926879771053791, -1.1475849151611328, 0.8945645689964294, -0.5162874460220337, -1.0133850574493408, -1.5152969360351562, 0.17712777853012085, -0.0936526209115982, 0.9342077970504761, -1.5928714275360107, -0.007967567071318626, 1.290586233139038, 0.8502812385559082, -0.7599803805351257, 1.0275400876998901, 0.24494683742523193, 1.1414518356323242, 0.933778703212738, -0.42141810059547424, 0.4576191306114197, 0.046793289482593536, -1.2817798852920532, 0.5466846823692322, 1.1304943561553955, 0.06932567805051804, 1.570396900177002, -0.5753459930419922, -0.06540358066558838, 0.3835567831993103, -0.45473721623420715, -0.4720138907432556, -0.7041614651679993, 0.778975248336792, 0.10445360839366913, -0.8105734586715698, -0.006437286734580994, 0.006566228345036507, -0.3362139165401459, 0.1417466253042221, -1.5240265130996704, -0.05810720473527908, -0.2932800352573395, -0.6855307817459106, -1.213482141494751, -0.03544941544532776, 1.3119903802871704, -0.7196348905563354, -0.17696239054203033, 0.43344971537590027, 0.3461025357246399, 0.47111764550209045, 0.7225373983383179, -0.55604088306427, -0.4451761543750763, -0.19685149192810059, -0.37144649028778076, 0.39321449398994446, 1.3056704998016357, -0.23120425641536713, -0.9814589619636536, 0.7076584696769714, -0.35592392086982727, 0.03640846908092499, 1.8957512378692627, 0.010561499744653702, -0.8406484723091125, 0.23759610950946808, -0.6703450679779053, 2.0452630519866943, 1.6742781400680542, 1.241939663887024, -0.13442616164684296, -1.0195298194885254, 0.7085056900978088, -0.22336533665657043, -0.40816831588745117, 0.7858278155326843, 0.388557493686676, -0.24598203599452972, -1.3892693519592285, 0.655525803565979, 1.236909031867981, -0.9104508757591248, -0.8690856099128723, 0.09278936684131622, -0.7957016825675964, 1.0066187381744385, 0.7712253332138062, 0.42902618646621704, 0.3359488546848297, 1.630336046218872, 0.6941370368003845, -0.5581392049789429, 0.5001771450042725, 0.4706380069255829, -0.052207306027412415, -2.1349525451660156, -1.0852147340774536, 0.32891905307769775, -0.4924018383026123, -1.712047815322876, 1.2945382595062256, -1.1792231798171997, -0.7771264910697937, 0.5411356091499329, 0.13243448734283447, 1.4396535158157349, 0.1948237419128418, 1.50571608543396, 1.9793308973312378, 0.8101773858070374, 0.3281238079071045, 1.2433148622512817, -0.1781655251979828, -0.49364644289016724, 1.6976778507232666, -0.4297015964984894, 0.5430427193641663, 1.0387232303619385, -0.25490936636924744, -1.0980027914047241, -0.6876692771911621, -1.213671088218689, -0.7213385105133057, 1.1487542390823364, 0.14700299501419067, -1.2360870838165283, 0.17365941405296326, 1.4248305559158325, 0.07139219343662262, -0.35607925057411194, 0.48420682549476624, 0.4060148596763611, -0.8761138319969177, -0.12229268997907639, -0.9015942215919495, 0.5862004160881042, -0.14669181406497955, -0.33218538761138916, 0.4584300220012665, 0.4257309138774872, 1.3239952325820923, 0.01500309444963932, 0.1957087367773056, 1.2014228105545044, -1.4820259809494019, 1.50876784324646, -0.676083505153656, 0.32952880859375, -2.3001506328582764, 1.459736943244934, -0.7584903836250305, 1.914668321609497, -2.785512685775757, 0.4246009290218353, -0.5710482001304626, -0.44044455885887146, 0.34435367584228516, -0.1917269378900528, 0.17627780139446259, -0.21001297235488892, -1.1800925731658936, -0.004917442332953215, -0.7567126750946045, 0.526751697063446, 1.1142133474349976, 1.2840386629104614, -1.1146527528762817, -0.2118406742811203, -1.732028841972351, -0.1457618921995163, -0.7398239970207214, 0.31223031878471375, -2.0837721824645996, -0.14763964712619781, -1.8391698598861694, -2.4461960792541504, -1.32197105884552, -0.7274075150489807, 1.1722294092178345, 0.09405148774385452, -0.8453440070152283, 1.172663688659668, -0.34127750992774963, -1.8005801439285278, 1.0693168640136719, -2.1334762573242188 ]
https://github.com/huggingface/datasets/issues/5219
Delta Tables usage using Datasets Library
Hi ! Interesting :) Can you provide concrete examples of cases where it can be useful ?
### Feature request Adding compatibility of Datasets library with Delta Format. Elevating the utilities of Datasets library from Machine Learning Scope to Data Engineering Scope as well. ### Motivation We know datasets library can absorb csv, json, parquet, etc. file formats but it would be great if Datasets library could work with Delta Tables (with delta format) as it has different features such as time travelling, layout optimization, query performance, aids in Data Engineering. This will help and enhance Datasets library from Machine Learning utility to Data Engineering utilities and expand horizons thereafter. I am totally using Datasets library in all my usecases and as my role expands so does the work, compatibility with Datasets library is something I don't want to lose. ### Your contribution Would love to work on this feature, even if this has to picked up from scratch, including design paradigms and patterns. I have basic idea about Delta Live Tables, would brush it easily for this feature.
435
17
Delta Tables usage using Datasets Library ### Feature request Adding compatibility of Datasets library with Delta Format. Elevating the utilities of Datasets library from Machine Learning Scope to Data Engineering Scope as well. ### Motivation We know datasets library can absorb csv, json, parquet, etc. file formats but it would be great if Datasets library could work with Delta Tables (with delta format) as it has different features such as time travelling, layout optimization, query performance, aids in Data Engineering. This will help and enhance Datasets library from Machine Learning utility to Data Engineering utilities and expand horizons thereafter. I am totally using Datasets library in all my usecases and as my role expands so does the work, compatibility with Datasets library is something I don't want to lose. ### Your contribution Would love to work on this feature, even if this has to picked up from scratch, including design paradigms and patterns. I have basic idea about Delta Live Tables, would brush it easily for this feature. Hi ! Interesting :) Can you provide concrete examples of cases where it can be useful ?
[ -1.2036807537078857, -1.0125750303268433, -0.8679957985877991, 1.4628970623016357, -0.17718744277954102, -1.2667477130889893, 0.11683699488639832, -1.079410195350647, 1.5974159240722656, -0.8598438501358032, 0.2711060345172882, -1.6651438474655151, 0.06676749885082245, -0.6459336280822754, -0.7150779366493225, -0.925434947013855, -0.3680048882961273, -0.7727875113487244, 1.0144476890563965, 2.612398386001587, 1.1121169328689575, -1.268623948097229, 2.74082612991333, 0.718732476234436, -0.2530771493911743, -0.9740912914276123, 0.5608735084533691, 0.1560693085193634, -1.2253338098526, -0.4456321597099304, -0.9465990662574768, -0.0018529137596488, -0.4259052872657776, -0.48434317111968994, -0.02034522220492363, 0.3302633464336395, -0.19479332864284515, -0.38632044196128845, -0.511524498462677, -0.7316937446594238, 0.397419273853302, -0.3327174186706543, 1.0559966564178467, -0.35901114344596863, 1.9126893281936646, -0.42135459184646606, 0.27912116050720215, 0.7571916580200195, 1.2543613910675049, 0.2654612362384796, -0.047418057918548584, 0.17532265186309814, 0.43852734565734863, -0.05820034071803093, 0.4541745185852051, 1.0580363273620605, 0.6204968094825745, 0.6026038527488708, 0.7538883686065674, -2.1623997688293457, 1.4206146001815796, -1.1619337797164917, 0.42683887481689453, 1.4247188568115234, -0.9811342358589172, 0.45916470885276794, -1.6779457330703735, -0.19331812858581543, 0.5304539203643799, -2.2685651779174805, 0.23446504771709442, -1.2091785669326782, -0.5730584263801575, 0.9559748768806458, 0.36581069231033325, -1.19962739944458, 0.17513957619667053, -0.44075360894203186, 1.0006734132766724, 0.5233343243598938, 1.2021015882492065, -1.7640317678451538, 0.15129752457141876, -0.2528090178966522, 0.003641575574874878, -1.4033730030059814, -1.4345530271530151, 0.5227259397506714, 0.586997926235199, 0.649927020072937, -0.056928664445877075, 0.9175536632537842, -1.0433170795440674, 0.7929571866989136, -0.884001612663269, -1.5117857456207275, -1.3579528331756592, -2.3259754180908203, -2.4883687496185303, 0.787736177444458, -0.3821566700935364, -0.5467625856399536, 2.093672275543213, -1.020079255104065, -1.7545151710510254, 1.3598721027374268, 0.20835264027118683, -0.09076054394245148, 2.4089832305908203, 0.33595260977745056, -0.6402448415756226, 0.4315418303012848, -0.6979993581771851, 0.8969435691833496, -0.48570385575294495, 1.375134825706482, 0.4908575713634491, -1.045069932937622, 1.582463264465332, -0.5665916204452515, 0.5014423131942749, -0.5546361804008484, -0.5587515234947205, -0.8985840082168579, 0.44048941135406494, 1.8064987659454346, -0.2013433873653412, 1.5808428525924683, -0.36868345737457275, -1.5963996648788452, -1.6578178405761719, 0.8264299035072327, 0.4295150339603424, -0.6999245285987854, 0.020871661603450775, -0.40179455280303955, 0.09704340994358063, 0.05847084894776344, 1.0998938083648682, 1.1987931728363037, 0.6877565383911133, -0.38476094603538513, -0.9265267848968506, 0.2679598033428192, -0.011164365336298943, -0.6885356903076172, -1.8688000440597534, -0.2573589086532593, 0.03961649909615517, 0.6449329853057861, -1.1646099090576172, 1.6117345094680786, 0.9307501912117004, 1.875564694404602, 0.963167130947113, -0.26082131266593933, 1.4562733173370361, 0.049914877861738205, 1.7934763431549072, -0.4791926443576813, 0.7339932918548584, -0.3809516727924347, -1.0716975927352905, 0.8110417723655701, -0.4109833836555481, -1.994597315788269, -0.801720380783081, -0.9015835523605347, -0.25069940090179443, -0.8216508030891418, 1.0402411222457886, -0.25269031524658203, -1.373091220855713, 0.3270875811576843, -0.6583651304244995, 0.12785495817661285, -1.1524769067764282, 0.35093003511428833, 0.7249140739440918, -0.6694892048835754, 0.03235839307308197, -0.19448544085025787, -1.3517813682556152, -0.39406588673591614, 0.2761975824832916, 1.9167660474777222, -0.7811747193336487, 0.9527024626731873, 0.9877517819404602, -0.7009393572807312, -0.043808259069919586, 0.34332963824272156, -0.34518104791641235, 0.7369738221168518, -1.0185439586639404, -0.3715640604496002, 1.1685971021652222, -0.19489531219005585, -0.4847639501094818, 1.5202052593231201, 0.7368806004524231, -1.045166254043579, -0.10620969533920288, -0.22435390949249268, -0.7561519742012024, -0.11747564375400543, -1.6574902534484863, -0.15333908796310425, 0.29191601276397705, -1.4524613618850708, -0.5519804954528809, -0.26247256994247437, 1.2884697914123535, -0.09938368201255798, 1.3832404613494873, -0.4198043644428253, -0.28819218277931213, -0.3374730944633484, -0.47496622800827026, 0.30604806542396545, -0.13016684353351593, -0.5477452874183655, 0.2946467995643616, -0.8350428342819214, 0.261222243309021, 1.5343430042266846, 0.3341516852378845, 0.03812970593571663, 0.48556435108184814, 0.9896060228347778, 0.4278661608695984, -0.10121305286884308, -0.8616292476654053, -1.5608556270599365, 2.0102829933166504, -1.5268055200576782, 1.9315226078033447, 0.7674322724342346, -0.004314610734581947, -1.8605961799621582, -1.8810102939605713, 1.3142993450164795, 1.2470576763153076, 2.2619166374206543, 0.5481830835342407, 0.21104136109352112, -0.7841538190841675, -0.6403402090072632, 0.38002291321754456, -1.156313419342041, -0.6782877445220947, 0.09880207479000092, 2.2658421993255615, 1.759193778038025, -0.451537162065506, -0.1465800553560257, -1.0140823125839233, 1.3279006481170654, -0.1541837602853775, 0.08944311738014221, 2.091029405593872, -0.4533703029155731, -1.105437159538269, 1.315476894378662, -2.3428876399993896, 0.11468300223350525, 1.8433191776275635, 0.35776451230049133, 0.04696851596236229, -1.4379942417144775, -0.6655591726303101, -0.2847241461277008, -0.3783116340637207, -1.1955376863479614, 0.7152630686759949, -0.29118287563323975, -0.7797624468803406, -1.4121428728103638, 0.14990639686584473, -1.1514071226119995, -1.6538281440734863, 0.4316578209400177, 1.830406904220581, 2.16921067237854, -0.8001372218132019, 1.5652939081192017, -0.24908044934272766, 0.15391278266906738, 1.2915936708450317, 1.1153810024261475, 3.1762948036193848, 1.8536540269851685, -1.287197232246399, 0.6152008771896362, 0.008526405319571495, -0.5338258147239685, 1.1346635818481445, -1.0232329368591309, 1.3403990268707275, -0.15287712216377258, -1.146170735359192, -1.2353664636611938, 0.9078486561775208, 0.3958204388618469, 0.1021895706653595, -0.5221216082572937, 1.2157810926437378, -0.05191534757614136, 1.2710665464401245, 0.5824586749076843, -0.37289154529571533, 0.6527876257896423, -0.47627487778663635, -0.4883634150028229, 1.5323785543441772, 0.23783954977989197, -1.5260965824127197, -2.2541186809539795, -0.17194657027721405, -0.651030421257019, -0.019349871203303337, -0.5812784433364868, -0.999692440032959, 1.608107566833496, 0.4142396152019501, -1.1856707334518433, -0.28177839517593384, -0.3824503421783447, -0.6258904933929443, 2.6046478748321533, -1.5127060413360596, -0.28703925013542175, -0.9605189561843872, -0.6102299690246582, 1.567590355873108, -1.183861255645752, -0.23123079538345337, -0.9963501691818237, -0.6081448793411255, -1.405484914779663, -0.6458993554115295, 0.0495356023311615, -1.0107454061508179, 0.8305342793464661, 0.02566816285252571, -1.1097861528396606, -0.20471154153347015, -0.9053611755371094, 0.8014869689941406, -0.11790801584720612, 0.41071584820747375, 1.8698111772537231, 0.3986269533634186, -0.4506472051143646, 0.6912966966629028, 1.2746741771697998, 0.7424495220184326, -0.777807891368866, 0.19213855266571045, -0.8992262482643127, 0.30778414011001587, -1.2163282632827759, 0.3088476061820984, -2.877593755722046, 0.6370876431465149, -0.06595916301012039, -0.152472123503685, 0.022282198071479797, -1.281467080116272, 1.0969319343566895, 2.546508312225342, -1.1498534679412842, 0.4735957980155945, 0.2512238621711731, 1.3357787132263184, -1.5130181312561035, 0.42199790477752686, -0.30022957921028137, 2.052581787109375, 0.3028426468372345, 1.2337430715560913, -0.513205349445343, -2.179564952850342, 0.730928361415863, -1.3445123434066772, -1.160332441329956, 0.7560634613037109, -0.8783354759216309, -0.06555398553609848, -1.4398528337478638, -0.09800314903259277, -0.7820430397987366, -1.2865064144134521, 0.6866455078125, 0.23655493557453156, 0.4530583918094635, -0.4854311943054199, 0.30786606669425964, -2.189511775970459, -1.36509370803833, -0.17832668125629425, -0.9916210174560547, 0.465035080909729, -0.3160761594772339, 0.6797978281974792, -0.27768421173095703, -0.022879334166646004, 0.43265196681022644, 1.412705898284912, 3.3968863487243652, 0.18294022977352142, 0.4379364848136902, -0.14089815318584442, -1.0153262615203857, 1.5072672367095947, 0.9928891658782959, -0.08327242732048035, -0.5606274008750916, -1.1437879800796509, 1.2016401290893555, 1.9154914617538452, 1.0672086477279663, 0.002402777783572674, -0.7405385375022888, -0.5969329476356506, 0.031215626746416092, 0.2489553987979889, 0.46604660153388977, 0.9651473760604858, 0.018673479557037354, 0.06230464205145836, 1.5034171342849731, 1.2451342344284058, -0.4979252219200134, 0.3917958736419678, -0.7934145331382751, -0.3253673315048218, 0.5379067063331604, 0.3307877480983734, -0.08445832133293152, 0.33294105529785156, -0.8915097117424011, -0.32781124114990234, -0.4021911919116974, -0.9244732856750488, -0.7242688536643982, -0.44233158230781555, -0.4451792538166046, 1.587659478187561, 0.1935444474220276, -0.5267213582992554, -0.11461681127548218, -0.8158384561538696, -0.07480652630329132, -1.0431946516036987, 0.26190128922462463, -0.1444343477487564, -0.17096589505672455, -0.11973074078559875, 1.9406121969223022, -0.9722415804862976, -2.063706398010254, 0.31433409452438354, 0.25809675455093384, -0.21951106190681458, 0.19021491706371307, 1.4781770706176758, 0.49154141545295715, 1.3751944303512573, 1.2776713371276855, 0.928738534450531, -0.6733319163322449, -1.3841952085494995, 0.7432460188865662, 0.9962269067764282, -1.4599696397781372, 0.7872767448425293, 0.0019800765439867973, -0.5471006631851196, 0.7199825048446655, 1.247066855430603, 0.3253874182701111, -1.8378087282180786, 0.7534526586532593, -0.9053782224655151, 0.7204495668411255, 0.7291023135185242, 0.7237817049026489, 0.18400156497955322, 0.6870068907737732, -1.3451801538467407, -1.0913794040679932, -0.7654526233673096, -0.6000955104827881, 1.9886281490325928, -0.127142995595932, 0.6748135685920715, -0.21935808658599854, -1.341113805770874, -0.006039048545062542, 0.59501051902771, 0.1758819967508316, -0.3766222894191742, 0.7998608946800232, -0.7204844355583191, -1.0753185749053955, -1.4905403852462769, -0.3566710948944092, -1.0214340686798096, -0.8359560370445251, 1.1284594535827637, 0.7525954842567444, 0.17487597465515137, 1.8345199823379517, 0.5407558679580688, 0.3647383153438568, -2.5924928188323975, 0.887039065361023, 0.2393646091222763, -0.06508354097604752, 0.8582171201705933, 0.2595597207546234, 1.1107250452041626, 0.052910130470991135, 0.41590139269828796, -2.4442460536956787, 2.2993998527526855, -0.2938295602798462, 0.7571621537208557, 0.11081516742706299, -0.13663001358509064, 1.2193512916564941, 0.668599009513855, 0.5787198543548584, -1.0552141666412354, 0.6734148859977722, -0.5745943188667297, 1.2876667976379395, 1.109311580657959, -0.8293207287788391, -0.07063698768615723, 1.3928453922271729, 0.5497085452079773, -0.3335241675376892, -0.8581015467643738, -0.985822319984436, 0.9570757746696472, 1.7141766548156738, -0.10651272535324097, -0.037656329572200775, 0.7359390258789062, 0.6093220114707947, -1.2455543279647827, -0.03276333212852478, -0.7923346161842346, -0.7447034120559692, 1.5948225259780884, 2.0412890911102295, -0.05953894183039665, -0.19119501113891602, -0.792897641658783, -1.1858458518981934, 0.7994551658630371, -0.041607774794101715, 0.24147766828536987, 0.6312246322631836, -0.6516209244728088, 1.11943781375885, 1.0081584453582764, 0.7229353189468384, 0.23174715042114258, 0.3074086308479309, 0.37695762515068054, -0.23738647997379303, -1.1433988809585571, -0.30366581678390503, -1.1447842121124268, -2.552623748779297, 0.4633076786994934, -0.413534939289093, -1.4626593589782715, 0.046308595687150955, -1.0539476871490479, 1.0072060823440552, -0.5924378633499146, -0.9882895350456238, -1.748206377029419, 0.2795458436012268, -0.1656227558851242, 1.042107105255127, -1.571918249130249, -0.18487027287483215, 1.2477192878723145, 0.8676090240478516, -0.6010841131210327, 1.0822381973266602, 0.2067420482635498, 1.0095365047454834, 0.7935075163841248, -0.41982603073120117, 0.4511890411376953, 0.1569201648235321, -1.3962887525558472, 0.42641007900238037, 1.2093408107757568, 0.16854192316532135, 1.3962898254394531, -0.5284498929977417, 0.04076196625828743, 0.41951653361320496, -0.548773467540741, -0.4503622055053711, -0.4643894135951996, 0.8173758387565613, 0.04985210299491882, -0.829225480556488, 0.024449694901704788, -0.13097010552883148, -0.39608994126319885, 0.212832510471344, -1.617919683456421, -0.3107309341430664, -0.46677228808403015, -0.5473982691764832, -1.33295738697052, -0.11142334342002869, 1.3483386039733887, -0.8544999957084656, -0.18075931072235107, 0.4384254813194275, 0.49627527594566345, 0.5384401679039001, 0.6012401580810547, -0.6471891403198242, -0.3233794569969177, -0.31534242630004883, -0.2581004798412323, 0.20890866219997406, 1.4215445518493652, -0.1731802374124527, -0.9662050008773804, 0.7367901802062988, -0.3335541784763336, 0.09550543129444122, 1.979318618774414, 0.1253795474767685, -0.8708280920982361, 0.3421367108821869, -0.715169370174408, 1.9507455825805664, 1.6654940843582153, 1.2902166843414307, -0.019389376044273376, -0.912581205368042, 0.49717119336128235, -0.20792162418365479, -0.2597508132457733, 0.852221667766571, 0.4675214886665344, -0.1977856606245041, -1.5292861461639404, 0.7107658386230469, 1.270660161972046, -0.8914982676506042, -0.834567666053772, 0.046710304915905, -0.7781463861465454, 0.9283892512321472, 0.6198599338531494, 0.5024014711380005, 0.2575382590293884, 1.6095952987670898, 0.7087658643722534, -0.6279588341712952, 0.4569074511528015, 0.50241619348526, -0.07121764123439789, -2.125546455383301, -1.043555736541748, 0.26939865946769714, -0.42648881673812866, -1.4511075019836426, 1.4060627222061157, -1.1108506917953491, -0.8070544004440308, 0.5695774555206299, 0.15360386669635773, 1.477231740951538, 0.4143792390823364, 1.5166789293289185, 2.1111154556274414, 0.835715651512146, 0.27817827463150024, 1.4138191938400269, -0.22018219530582428, -0.39542895555496216, 1.8466707468032837, -0.37281709909439087, 0.4665987193584442, 1.151373028755188, -0.34962645173072815, -0.8831592202186584, -0.6957156658172607, -1.1395564079284668, -0.6802123188972473, 1.0352586507797241, 0.1252092868089676, -1.1312081813812256, 0.1307457685470581, 1.5516643524169922, 0.09337864816188812, -0.3184053599834442, 0.5475696921348572, 0.44826680421829224, -0.7348998188972473, -0.13264703750610352, -1.0329115390777588, 0.4515080451965332, -0.25254693627357483, -0.3638051152229309, 0.37170398235321045, 0.43197187781333923, 1.2184693813323975, -0.018253855407238007, 0.1289491206407547, 1.0807467699050903, -1.3787764310836792, 1.453930139541626, -0.6621751189231873, 0.18906374275684357, -2.3730859756469727, 1.4438364505767822, -0.7477864027023315, 1.9347198009490967, -2.7006611824035645, 0.4063177704811096, -0.6535346508026123, -0.472126305103302, 0.26374590396881104, -0.29557090997695923, 0.21109551191329956, -0.19549913704395294, -1.0176568031311035, -0.06713402271270752, -0.7148705720901489, 0.5624396800994873, 1.2272894382476807, 1.2942688465118408, -1.2093279361724854, -0.36472949385643005, -1.649532437324524, -0.266470730304718, -0.778771162033081, 0.3246935307979584, -1.9931612014770508, -0.19997462630271912, -1.764843463897705, -2.3425354957580566, -1.410391092300415, -0.848652720451355, 1.278567910194397, 0.1051710844039917, -0.9783650040626526, 1.2340967655181885, -0.4053880572319031, -1.8468273878097534, 1.085680603981018, -2.161059856414795 ]
https://github.com/huggingface/datasets/issues/5219
Delta Tables usage using Datasets Library
Few example blogs and posts that might help on this - 1. https://hevodata.com/learn/databricks-delta-tables/ 2. https://docs.databricks.com/delta/index.html Basically, we are looking at utility of Datasets library with Delta Lake Tables.
### Feature request Adding compatibility of Datasets library with Delta Format. Elevating the utilities of Datasets library from Machine Learning Scope to Data Engineering Scope as well. ### Motivation We know datasets library can absorb csv, json, parquet, etc. file formats but it would be great if Datasets library could work with Delta Tables (with delta format) as it has different features such as time travelling, layout optimization, query performance, aids in Data Engineering. This will help and enhance Datasets library from Machine Learning utility to Data Engineering utilities and expand horizons thereafter. I am totally using Datasets library in all my usecases and as my role expands so does the work, compatibility with Datasets library is something I don't want to lose. ### Your contribution Would love to work on this feature, even if this has to picked up from scratch, including design paradigms and patterns. I have basic idea about Delta Live Tables, would brush it easily for this feature.
435
28
Delta Tables usage using Datasets Library ### Feature request Adding compatibility of Datasets library with Delta Format. Elevating the utilities of Datasets library from Machine Learning Scope to Data Engineering Scope as well. ### Motivation We know datasets library can absorb csv, json, parquet, etc. file formats but it would be great if Datasets library could work with Delta Tables (with delta format) as it has different features such as time travelling, layout optimization, query performance, aids in Data Engineering. This will help and enhance Datasets library from Machine Learning utility to Data Engineering utilities and expand horizons thereafter. I am totally using Datasets library in all my usecases and as my role expands so does the work, compatibility with Datasets library is something I don't want to lose. ### Your contribution Would love to work on this feature, even if this has to picked up from scratch, including design paradigms and patterns. I have basic idea about Delta Live Tables, would brush it easily for this feature. Few example blogs and posts that might help on this - 1. https://hevodata.com/learn/databricks-delta-tables/ 2. https://docs.databricks.com/delta/index.html Basically, we are looking at utility of Datasets library with Delta Lake Tables.
[ -1.2208447456359863, -1.0149539709091187, -0.8781011700630188, 1.4250775575637817, -0.15946336090564728, -1.267756700515747, 0.12476511299610138, -1.05329430103302, 1.6016497611999512, -0.8228683471679688, 0.2315940409898758, -1.6294360160827637, -0.019480187445878983, -0.6116613745689392, -0.7144932150840759, -0.9528771042823792, -0.39151620864868164, -0.7690053582191467, 0.9956238865852356, 2.587548017501831, 1.1299059391021729, -1.2820690870285034, 2.7639126777648926, 0.7274543642997742, -0.21447758376598358, -0.9789077043533325, 0.5652581453323364, 0.1430583894252777, -1.2510161399841309, -0.4385336637496948, -0.9058946967124939, 0.02495645359158516, -0.46489769220352173, -0.42852163314819336, 0.04709327220916748, 0.32005321979522705, -0.18196459114551544, -0.3701474666595459, -0.5290297865867615, -0.7782464623451233, 0.417161762714386, -0.36028367280960083, 0.9853508472442627, -0.37997716665267944, 1.8972606658935547, -0.44640249013900757, 0.3177117705345154, 0.7699639797210693, 1.244397521018982, 0.24243579804897308, 0.002573857083916664, 0.1835603564977646, 0.43381398916244507, -0.007222761400043964, 0.48724114894866943, 1.1293928623199463, 0.6015652418136597, 0.5737638473510742, 0.6918402910232544, -2.1626296043395996, 1.3759392499923706, -1.083985686302185, 0.3995794653892517, 1.4393335580825806, -0.927033543586731, 0.44221729040145874, -1.7043193578720093, -0.1851460486650467, 0.5365968346595764, -2.3449697494506836, 0.20301125943660736, -1.2036083936691284, -0.5366613268852234, 0.9584015607833862, 0.3372232913970947, -1.1562434434890747, 0.25333160161972046, -0.4791199564933777, 1.0323866605758667, 0.551374614238739, 1.2221505641937256, -1.7235339879989624, 0.07359898090362549, -0.17456071078777313, 0.001598617061972618, -1.3547080755233765, -1.4770570993423462, 0.4800183176994324, 0.6293061971664429, 0.6457215547561646, -0.0794447585940361, 0.8927724957466125, -1.051652431488037, 0.8135154247283936, -0.887498140335083, -1.5402159690856934, -1.3925889730453491, -2.3233447074890137, -2.4879183769226074, 0.8367471098899841, -0.3525964617729187, -0.47462552785873413, 2.0618481636047363, -0.9595198631286621, -1.7997395992279053, 1.2874318361282349, 0.29314321279525757, -0.007263071835041046, 2.3920867443084717, 0.34731924533843994, -0.6672647595405579, 0.44108718633651733, -0.7130976915359497, 0.8151745796203613, -0.5029527544975281, 1.3528574705123901, 0.5172935724258423, -0.9798961877822876, 1.562522292137146, -0.6225207448005676, 0.5200386643409729, -0.6042237281799316, -0.5098591446876526, -0.8615188002586365, 0.3938845992088318, 1.8266541957855225, -0.2166910171508789, 1.611733078956604, -0.3805444836616516, -1.6030141115188599, -1.6182808876037598, 0.7902021408081055, 0.43007612228393555, -0.7133076786994934, -0.052709415555000305, -0.413637638092041, 0.11732697486877441, 0.02254556305706501, 1.0490156412124634, 1.1417874097824097, 0.7410758137702942, -0.3764647841453552, -0.9134327173233032, 0.2992650270462036, 0.010220145806670189, -0.6989836096763611, -1.8629136085510254, -0.2796829342842102, 0.11318003386259079, 0.5977800488471985, -1.215617299079895, 1.6120957136154175, 0.9276459813117981, 1.9310965538024902, 0.9100619554519653, -0.32543015480041504, 1.5011757612228394, 0.05795451998710632, 1.8451515436172485, -0.4513559341430664, 0.7372061014175415, -0.37534868717193604, -1.0824886560440063, 0.7844117879867554, -0.4029656648635864, -2.027852773666382, -0.7617141604423523, -0.8775872588157654, -0.1910332292318344, -0.8031737804412842, 1.0150965452194214, -0.1903371810913086, -1.392657995223999, 0.2161020189523697, -0.67078697681427, 0.12308394908905029, -1.17084801197052, 0.3049406409263611, 0.7652508616447449, -0.6519225239753723, 0.014436298981308937, -0.1995617002248764, -1.3606030941009521, -0.3612995743751526, 0.304563045501709, 1.9164073467254639, -0.7638580799102783, 0.9536221623420715, 0.9426619410514832, -0.7530285716056824, 0.06046424061059952, 0.32360154390335083, -0.40912991762161255, 0.7522470951080322, -0.9731675982475281, -0.35047447681427, 1.1983429193496704, -0.2081921100616455, -0.5121622085571289, 1.4824732542037964, 0.7932533025741577, -1.0197581052780151, -0.13743619620800018, -0.2058761566877365, -0.7454553842544556, -0.1279507279396057, -1.6261236667633057, -0.15825380384922028, 0.27391839027404785, -1.4022061824798584, -0.5461655259132385, -0.2959928512573242, 1.3015772104263306, -0.10831291228532791, 1.4055659770965576, -0.3709242343902588, -0.2261417955160141, -0.39041733741760254, -0.5090568661689758, 0.2672428488731384, -0.15922048687934875, -0.5790369510650635, 0.3057652711868286, -0.8741292953491211, 0.2367899864912033, 1.547967791557312, 0.34242677688598633, 0.043703801929950714, 0.48586344718933105, 0.988098680973053, 0.45150846242904663, -0.13549458980560303, -0.8556484580039978, -1.5901048183441162, 2.024463415145874, -1.5139122009277344, 1.9005717039108276, 0.7566741704940796, -0.01207233127206564, -1.828945279121399, -1.9096083641052246, 1.3174420595169067, 1.1656345129013062, 2.3307764530181885, 0.5055695176124573, 0.2743668556213379, -0.8104005455970764, -0.7192236185073853, 0.3630164861679077, -1.1241947412490845, -0.7162357568740845, 0.08403857797384262, 2.2684309482574463, 1.7657700777053833, -0.5026681423187256, -0.1897149533033371, -1.0128511190414429, 1.3523162603378296, -0.1786956638097763, 0.12435097992420197, 2.105062246322632, -0.4264599084854126, -1.021565318107605, 1.2975504398345947, -2.3950583934783936, 0.17587244510650635, 1.854474663734436, 0.35353904962539673, 0.04929615184664726, -1.4842065572738647, -0.6761782765388489, -0.3066225051879883, -0.36621177196502686, -1.1572630405426025, 0.6732665300369263, -0.2583010792732239, -0.8664154410362244, -1.3865330219268799, 0.09101632982492447, -1.172933578491211, -1.6938506364822388, 0.4084435701370239, 1.842814564704895, 2.1291723251342773, -0.7982481122016907, 1.4881970882415771, -0.24427492916584015, 0.06753793358802795, 1.2721292972564697, 1.1698943376541138, 3.1750283241271973, 1.8350000381469727, -1.2870898246765137, 0.6292916536331177, -0.05651494860649109, -0.5030331611633301, 1.0866942405700684, -1.0185279846191406, 1.3081589937210083, -0.18327449262142181, -1.1504762172698975, -1.2422590255737305, 0.9617930054664612, 0.44231581687927246, 0.09728066623210907, -0.5440405011177063, 1.232017993927002, -0.03526497632265091, 1.3444942235946655, 0.5785079598426819, -0.4146661162376404, 0.6267561316490173, -0.40173065662384033, -0.5128951668739319, 1.5401188135147095, 0.1970980018377304, -1.521694302558899, -2.3141307830810547, -0.14863985776901245, -0.7351276278495789, -0.05413459986448288, -0.5893611907958984, -1.0129822492599487, 1.6122145652770996, 0.49018847942352295, -1.1730490922927856, -0.27885401248931885, -0.37164241075515747, -0.6334972381591797, 2.5942845344543457, -1.4772303104400635, -0.25824087858200073, -0.9301579594612122, -0.4847453832626343, 1.544755458831787, -1.158656120300293, -0.2104017287492752, -0.945307195186615, -0.6557761430740356, -1.4538843631744385, -0.6554977893829346, 0.05233893543481827, -1.0062123537063599, 0.8124955892562866, 0.003414895385503769, -1.1469992399215698, -0.23370400071144104, -0.9231818318367004, 0.8732086420059204, -0.06961797922849655, 0.33983486890792847, 1.8452118635177612, 0.37930434942245483, -0.41622400283813477, 0.6867914199829102, 1.2817471027374268, 0.7478783130645752, -0.7814036011695862, 0.22500091791152954, -0.8932626843452454, 0.34116142988204956, -1.2963849306106567, 0.23801997303962708, -2.870227575302124, 0.6661122441291809, -0.08923713117837906, -0.169467955827713, -0.04596696048974991, -1.2668907642364502, 1.1359652280807495, 2.546217203140259, -1.1157433986663818, 0.4619423747062683, 0.3219756484031677, 1.3360607624053955, -1.4882889986038208, 0.37855541706085205, -0.33257412910461426, 2.0481491088867188, 0.29168856143951416, 1.2545692920684814, -0.5249065160751343, -2.100125551223755, 0.6790814995765686, -1.3394906520843506, -1.0669105052947998, 0.8127803802490234, -0.8895336389541626, 0.0008952328935265541, -1.4647547006607056, -0.08247917145490646, -0.8046046495437622, -1.284087061882019, 0.6365694403648376, 0.22343455255031586, 0.4800049662590027, -0.4997583031654358, 0.3496013879776001, -2.192957639694214, -1.3296208381652832, -0.18456913530826569, -1.024701714515686, 0.5050531029701233, -0.30015599727630615, 0.6948272585868835, -0.19140078127384186, -0.054907575249671936, 0.423772931098938, 1.3809304237365723, 3.3702056407928467, 0.16372910141944885, 0.3731841444969177, -0.1275431215763092, -1.0374914407730103, 1.527634859085083, 0.9733209013938904, -0.12376979738473892, -0.49144959449768066, -1.0964863300323486, 1.2329192161560059, 1.9744987487792969, 1.1513829231262207, 0.0013003014028072357, -0.8219398260116577, -0.6451696753501892, 0.05306299775838852, 0.19185172021389008, 0.4707942008972168, 0.9820159077644348, -0.0036731050349771976, 0.06676843017339706, 1.4938114881515503, 1.2820284366607666, -0.4289017915725708, 0.45113086700439453, -0.8922882080078125, -0.3353648781776428, 0.5289883017539978, 0.30597835779190063, -0.04641656577587128, 0.36358731985092163, -0.9635301232337952, -0.3113256096839905, -0.3706650733947754, -0.8614145517349243, -0.7436108589172363, -0.48460304737091064, -0.44865113496780396, 1.5867600440979004, 0.18186596035957336, -0.49996185302734375, -0.03241299092769623, -0.8043004870414734, -0.07005824148654938, -1.0065654516220093, 0.25002193450927734, -0.1290230005979538, -0.11883416026830673, -0.17920145392417908, 1.878421664237976, -0.9628913998603821, -2.058237314224243, 0.2994786500930786, 0.22438636422157288, -0.3017793893814087, 0.15678827464580536, 1.551031231880188, 0.4858946204185486, 1.3793964385986328, 1.285660743713379, 0.9496530890464783, -0.6496809124946594, -1.3744151592254639, 0.8025006651878357, 1.0076860189437866, -1.3850460052490234, 0.8063559532165527, -0.043733853846788406, -0.5649556517601013, 0.7033573985099792, 1.2435187101364136, 0.23198860883712769, -1.84888756275177, 0.7574478387832642, -0.8560035824775696, 0.7136173248291016, 0.7035095691680908, 0.7208169102668762, 0.20279358327388763, 0.6967401504516602, -1.3978450298309326, -1.1000158786773682, -0.7839736342430115, -0.5609453320503235, 1.9858248233795166, -0.12564074993133545, 0.6158137917518616, -0.1946418434381485, -1.3208320140838623, -0.04283500090241432, 0.6233753561973572, 0.1951793134212494, -0.4001949429512024, 0.8412386178970337, -0.6888628602027893, -1.0445576906204224, -1.3994371891021729, -0.35434621572494507, -1.0525181293487549, -0.8183929324150085, 1.0935180187225342, 0.8248554468154907, 0.23243989050388336, 1.8378877639770508, 0.5279902815818787, 0.4070085883140564, -2.615884780883789, 0.9238553047180176, 0.23198923468589783, -0.06429886817932129, 0.8436009287834167, 0.1765192747116089, 1.1614807844161987, 0.0206375103443861, 0.4882955551147461, -2.431143045425415, 2.254582405090332, -0.21831192076206207, 0.7133567929267883, 0.13228711485862732, -0.1311960220336914, 1.2197884321212769, 0.6601481437683105, 0.5982884764671326, -1.0819886922836304, 0.6706240177154541, -0.5935007929801941, 1.2176971435546875, 1.0881133079528809, -0.8452204465866089, -0.04642004519701004, 1.4183831214904785, 0.5481757521629333, -0.30847758054733276, -0.9051030874252319, -0.9503964781761169, 0.9736940264701843, 1.685390591621399, -0.10138111561536789, -0.04993408918380737, 0.8006261587142944, 0.6305271983146667, -1.3008612394332886, -0.01009525079280138, -0.7866553068161011, -0.6742555499076843, 1.6397054195404053, 2.0496878623962402, -0.04624247923493385, -0.1836632639169693, -0.8035638928413391, -1.2366539239883423, 0.6937653422355652, -0.04573282599449158, 0.22957369685173035, 0.6878165006637573, -0.6387553811073303, 1.1738656759262085, 0.9178019165992737, 0.7582560777664185, 0.14782994985580444, 0.26957637071609497, 0.3143916726112366, -0.30279821157455444, -1.1861169338226318, -0.36016881465911865, -1.1114881038665771, -2.5315167903900146, 0.4914093017578125, -0.35377323627471924, -1.470874309539795, 0.0978851243853569, -1.0861821174621582, 1.027750849723816, -0.6683933734893799, -0.9914342164993286, -1.6710245609283447, 0.33665114641189575, -0.19612841308116913, 0.9871936440467834, -1.5798362493515015, -0.163696750998497, 1.2572401762008667, 0.8533971905708313, -0.5373783111572266, 1.0712472200393677, 0.24558530747890472, 1.0235655307769775, 0.7608582377433777, -0.3769564628601074, 0.4632928967475891, 0.1799897998571396, -1.4123777151107788, 0.3863844871520996, 1.1837375164031982, 0.22441917657852173, 1.3684839010238647, -0.5457362532615662, 0.11118695139884949, 0.4628449082374573, -0.5789153575897217, -0.472029447555542, -0.44893741607666016, 0.7846407294273376, 0.051855701953172684, -0.9297613501548767, -0.015912819653749466, -0.14892295002937317, -0.34930169582366943, 0.20871935784816742, -1.583562970161438, -0.3307727575302124, -0.3829568028450012, -0.5273019671440125, -1.3035846948623657, -0.02194063551723957, 1.351263403892517, -0.9003297090530396, -0.2078571319580078, 0.4771358370780945, 0.4580182433128357, 0.5676601529121399, 0.6019589304924011, -0.6429194211959839, -0.3127117156982422, -0.3238219618797302, -0.20926478505134583, 0.1794004589319229, 1.3903820514678955, -0.16383978724479675, -1.0012003183364868, 0.7079988718032837, -0.41257381439208984, 0.13135787844657898, 2.012237071990967, 0.09117652475833893, -0.8747745156288147, 0.35976463556289673, -0.6935537457466125, 1.9162371158599854, 1.6638325452804565, 1.3446096181869507, 0.004908527247607708, -0.8667030930519104, 0.434154748916626, -0.2467624992132187, -0.2786189913749695, 0.8608245253562927, 0.47913217544555664, -0.15701919794082642, -1.5148264169692993, 0.6065834760665894, 1.2937501668930054, -0.9113932251930237, -0.8616311550140381, 0.07417134195566177, -0.8392984867095947, 0.9674994349479675, 0.6953705549240112, 0.4443737864494324, 0.2232017070055008, 1.5748945474624634, 0.7649757266044617, -0.6081137657165527, 0.4920817017555237, 0.49513864517211914, -0.12318570911884308, -2.1258885860443115, -0.9779819846153259, 0.2872314453125, -0.3621806502342224, -1.4477382898330688, 1.4076272249221802, -1.1139440536499023, -0.8080748915672302, 0.5318179130554199, 0.18129488825798035, 1.4388059377670288, 0.40841662883758545, 1.5546058416366577, 2.097227096557617, 0.8488345742225647, 0.2402896136045456, 1.4074459075927734, -0.21437175571918488, -0.42799240350723267, 1.8343786001205444, -0.368041455745697, 0.5136376023292542, 1.0851924419403076, -0.369992196559906, -0.8834143280982971, -0.7248073816299438, -1.1712855100631714, -0.6474685668945312, 1.116951584815979, 0.13766245543956757, -1.1133391857147217, 0.10385909676551819, 1.5915647745132446, 0.054453201591968536, -0.29989463090896606, 0.6589921116828918, 0.45064443349838257, -0.6941199898719788, -0.09150119125843048, -1.0406116247177124, 0.44205242395401, -0.1579752117395401, -0.3696742653846741, 0.3150675892829895, 0.3974573612213135, 1.2055541276931763, -0.0013055154122412205, 0.11254414916038513, 1.0718661546707153, -1.32243013381958, 1.469756841659546, -0.7044066786766052, 0.22941593825817108, -2.4322571754455566, 1.433353304862976, -0.783332347869873, 1.8932586908340454, -2.6615583896636963, 0.38927602767944336, -0.6430412530899048, -0.44480711221694946, 0.2622694969177246, -0.35917961597442627, 0.1980309635400772, -0.14267995953559875, -1.059133529663086, -0.07578538358211517, -0.7532020211219788, 0.5750022530555725, 1.2220170497894287, 1.3187347650527954, -1.247992753982544, -0.39076143503189087, -1.6929150819778442, -0.23600955307483673, -0.7792968153953552, 0.36651521921157837, -1.9578323364257812, -0.14495135843753815, -1.7881134748458862, -2.3228261470794678, -1.446002721786499, -0.8545892238616943, 1.2346434593200684, 0.07227598130702972, -0.9973639249801636, 1.2052935361862183, -0.4110000729560852, -1.8709793090820312, 1.0898905992507935, -2.2177019119262695 ]
https://github.com/huggingface/datasets/issues/5219
Delta Tables usage using Datasets Library
`datasets` can already read/write from parquet from/to a cloud storage using fsspec, if I understand correctly it's should be possible to load parquet files as delat lake tables no ? :) Or is there someting missing ?
### Feature request Adding compatibility of Datasets library with Delta Format. Elevating the utilities of Datasets library from Machine Learning Scope to Data Engineering Scope as well. ### Motivation We know datasets library can absorb csv, json, parquet, etc. file formats but it would be great if Datasets library could work with Delta Tables (with delta format) as it has different features such as time travelling, layout optimization, query performance, aids in Data Engineering. This will help and enhance Datasets library from Machine Learning utility to Data Engineering utilities and expand horizons thereafter. I am totally using Datasets library in all my usecases and as my role expands so does the work, compatibility with Datasets library is something I don't want to lose. ### Your contribution Would love to work on this feature, even if this has to picked up from scratch, including design paradigms and patterns. I have basic idea about Delta Live Tables, would brush it easily for this feature.
435
37
Delta Tables usage using Datasets Library ### Feature request Adding compatibility of Datasets library with Delta Format. Elevating the utilities of Datasets library from Machine Learning Scope to Data Engineering Scope as well. ### Motivation We know datasets library can absorb csv, json, parquet, etc. file formats but it would be great if Datasets library could work with Delta Tables (with delta format) as it has different features such as time travelling, layout optimization, query performance, aids in Data Engineering. This will help and enhance Datasets library from Machine Learning utility to Data Engineering utilities and expand horizons thereafter. I am totally using Datasets library in all my usecases and as my role expands so does the work, compatibility with Datasets library is something I don't want to lose. ### Your contribution Would love to work on this feature, even if this has to picked up from scratch, including design paradigms and patterns. I have basic idea about Delta Live Tables, would brush it easily for this feature. `datasets` can already read/write from parquet from/to a cloud storage using fsspec, if I understand correctly it's should be possible to load parquet files as delat lake tables no ? :) Or is there someting missing ?
[ -1.1959606409072876, -0.9679224491119385, -0.8535606265068054, 1.478890299797058, -0.17202338576316833, -1.2553794384002686, 0.142351433634758, -1.0673953294754028, 1.548815131187439, -0.8623663187026978, 0.3138457238674164, -1.6487563848495483, 0.03789140284061432, -0.6716776490211487, -0.7273213863372803, -0.9323418140411377, -0.39863306283950806, -0.7461735606193542, 0.9817745089530945, 2.578141689300537, 1.1304473876953125, -1.321839690208435, 2.7361764907836914, 0.7241733074188232, -0.2303951531648636, -0.9734719395637512, 0.5326377153396606, 0.1405911147594452, -1.1938432455062866, -0.4783635139465332, -0.9235591292381287, -0.014244910329580307, -0.465782105922699, -0.4672076106071472, 0.04024840146303177, 0.33997297286987305, -0.20952893793582916, -0.40909209847450256, -0.5161948204040527, -0.7586058378219604, 0.42262381315231323, -0.36197617650032043, 1.0353256464004517, -0.36794787645339966, 1.8967349529266357, -0.4317191541194916, 0.29058837890625, 0.7441660165786743, 1.2875021696090698, 0.25066548585891724, -0.032696016132831573, 0.22143344581127167, 0.40566328167915344, -0.060322731733322144, 0.48616620898246765, 1.0935295820236206, 0.6012301445007324, 0.5960884094238281, 0.7504892945289612, -2.1433091163635254, 1.4076613187789917, -1.175646424293518, 0.39597123861312866, 1.3715660572052002, -0.9319185018539429, 0.4941059350967407, -1.688170313835144, -0.19879819452762604, 0.5023642778396606, -2.297893524169922, 0.2302582561969757, -1.2080092430114746, -0.5056304335594177, 0.9767577648162842, 0.34931910037994385, -1.1714444160461426, 0.24058078229427338, -0.47249695658683777, 0.9792140126228333, 0.4921841025352478, 1.1937187910079956, -1.7304290533065796, 0.12903892993927002, -0.24110707640647888, 0.04963231086730957, -1.3860186338424683, -1.4577029943466187, 0.5195668339729309, 0.5957316160202026, 0.6242406368255615, -0.05963825434446335, 0.9604333639144897, -1.0430124998092651, 0.7819015383720398, -0.8979000449180603, -1.5021618604660034, -1.3817335367202759, -2.26776385307312, -2.4911928176879883, 0.8064410090446472, -0.40473490953445435, -0.5315775871276855, 2.0767242908477783, -1.025451898574829, -1.7756441831588745, 1.2896356582641602, 0.22648650407791138, -0.08335313946008682, 2.4039223194122314, 0.32763102650642395, -0.6483234167098999, 0.4578002989292145, -0.6724384427070618, 0.8991619348526001, -0.5268134474754333, 1.3769508600234985, 0.47197800874710083, -1.0393095016479492, 1.6019766330718994, -0.5613032579421997, 0.5357006192207336, -0.5703142285346985, -0.556309163570404, -0.857227623462677, 0.42243286967277527, 1.8591423034667969, -0.21774880588054657, 1.589800238609314, -0.39611390233039856, -1.5957974195480347, -1.6470690965652466, 0.8428469300270081, 0.41265764832496643, -0.724912166595459, 0.016164079308509827, -0.3806935250759125, 0.1153833344578743, 0.02998843602836132, 1.074684977531433, 1.17336905002594, 0.6854822039604187, -0.38900405168533325, -0.9445748925209045, 0.28305351734161377, 0.008714737370610237, -0.6780137419700623, -1.8552237749099731, -0.29664579033851624, 0.08245179057121277, 0.6103881597518921, -1.1614155769348145, 1.617734670639038, 0.9514935612678528, 1.869499921798706, 0.9779049158096313, -0.3077046275138855, 1.4956105947494507, 0.06334924697875977, 1.81747305393219, -0.4627368152141571, 0.7097822427749634, -0.406739205121994, -1.106486201286316, 0.7910090684890747, -0.3862658143043518, -2.0524675846099854, -0.7734275460243225, -0.8939213156700134, -0.23628488183021545, -0.78726726770401, 1.0516259670257568, -0.2455030381679535, -1.377173662185669, 0.27514126896858215, -0.6275296807289124, 0.17592935264110565, -1.1816184520721436, 0.36368241906166077, 0.7531471252441406, -0.6476887464523315, 0.02987024001777172, -0.2317468672990799, -1.367680549621582, -0.35169607400894165, 0.26800695061683655, 1.9081472158432007, -0.7784304618835449, 0.9454322457313538, 0.9527588486671448, -0.7163397669792175, -0.02524121105670929, 0.33920684456825256, -0.3755438029766083, 0.7419317960739136, -1.0075987577438354, -0.37201061844825745, 1.1961793899536133, -0.22590166330337524, -0.4841940701007843, 1.4698760509490967, 0.7845012545585632, -1.053227424621582, -0.13634394109249115, -0.24099469184875488, -0.7973666787147522, -0.11314534395933151, -1.596490740776062, -0.15147243440151215, 0.2768068015575409, -1.4444431066513062, -0.5460599660873413, -0.28262603282928467, 1.2287250757217407, -0.12709921598434448, 1.4181138277053833, -0.4266131520271301, -0.25637391209602356, -0.2988590598106384, -0.5254930257797241, 0.2906111478805542, -0.13692300021648407, -0.5747957229614258, 0.27850472927093506, -0.8144205212593079, 0.27000460028648376, 1.50920832157135, 0.3000335097312927, 0.04401232302188873, 0.487650990486145, 0.9557709693908691, 0.4389294981956482, -0.08420444279909134, -0.8380908966064453, -1.5355234146118164, 2.048889636993408, -1.5204999446868896, 1.9149413108825684, 0.7579664587974548, 0.03573053330183029, -1.8042899370193481, -1.8505183458328247, 1.338520884513855, 1.221286654472351, 2.26155161857605, 0.5336647629737854, 0.24999020993709564, -0.8108845353126526, -0.6652941703796387, 0.36165449023246765, -1.1346089839935303, -0.6847884058952332, 0.10845868289470673, 2.273231267929077, 1.7857639789581299, -0.48426395654678345, -0.16664232313632965, -0.9996843934059143, 1.3606499433517456, -0.2222394049167633, 0.10303971916437149, 2.0648305416107178, -0.4387989640235901, -1.0505409240722656, 1.3041819334030151, -2.401183843612671, 0.1504715383052826, 1.867324709892273, 0.3400963246822357, 0.048741236329078674, -1.4490171670913696, -0.6536740660667419, -0.2708151638507843, -0.33734703063964844, -1.2061680555343628, 0.6611853241920471, -0.2754870653152466, -0.7734395265579224, -1.413544774055481, 0.1705293357372284, -1.1881201267242432, -1.6685384511947632, 0.40803688764572144, 1.8411411046981812, 2.1316981315612793, -0.7640984058380127, 1.5610146522521973, -0.307810515165329, 0.13175588846206665, 1.2809844017028809, 1.1268856525421143, 3.1842002868652344, 1.8312550783157349, -1.278800368309021, 0.6250374913215637, -0.007024514954537153, -0.5561585426330566, 1.1388214826583862, -1.0033791065216064, 1.3318324089050293, -0.1457710713148117, -1.152130126953125, -1.2100409269332886, 0.9054585695266724, 0.40547975897789, 0.12787075340747833, -0.5249989032745361, 1.2124849557876587, -0.021256571635603905, 1.2904173135757446, 0.5827566385269165, -0.38900014758110046, 0.6363041400909424, -0.4250689148902893, -0.4915972948074341, 1.49696946144104, 0.21221096813678741, -1.4996590614318848, -2.248622179031372, -0.18771308660507202, -0.6561357975006104, 0.0017538713291287422, -0.5844299793243408, -1.000653862953186, 1.6259502172470093, 0.4056774377822876, -1.1869724988937378, -0.3094727694988251, -0.3945077657699585, -0.5907517671585083, 2.5833046436309814, -1.5184239149093628, -0.3063352406024933, -0.9497972130775452, -0.5921368598937988, 1.5546773672103882, -1.1789523363113403, -0.21508531272411346, -0.979345977306366, -0.5946353077888489, -1.4360535144805908, -0.6457110643386841, 0.03186815232038498, -1.0193315744400024, 0.8179092407226562, 0.05722331255674362, -1.1367298364639282, -0.23566344380378723, -0.9221851229667664, 0.8428158760070801, -0.10432139039039612, 0.3650256097316742, 1.8407177925109863, 0.38177821040153503, -0.46585801243782043, 0.707580029964447, 1.283839225769043, 0.715492308139801, -0.7512350082397461, 0.1640065461397171, -0.8834449052810669, 0.29877984523773193, -1.2771077156066895, 0.30580246448516846, -2.870483875274658, 0.6397219896316528, -0.08870378136634827, -0.15692032873630524, 0.002880486659705639, -1.2843979597091675, 1.0977485179901123, 2.5829532146453857, -1.1417409181594849, 0.47085922956466675, 0.2877711057662964, 1.3096287250518799, -1.5334340333938599, 0.3845949172973633, -0.29254359006881714, 2.0922279357910156, 0.28335103392601013, 1.2363934516906738, -0.5324448347091675, -2.194638967514038, 0.6652334928512573, -1.3529736995697021, -1.1667741537094116, 0.7677542567253113, -0.8732505440711975, -0.07150039076805115, -1.456531286239624, -0.0896003246307373, -0.8166232705116272, -1.2573025226593018, 0.677143394947052, 0.20759570598602295, 0.4459649622440338, -0.505599856376648, 0.30404001474380493, -2.1895129680633545, -1.3810611963272095, -0.18187668919563293, -0.986717164516449, 0.47290366888046265, -0.33824968338012695, 0.7028551697731018, -0.26416799426078796, -0.036808982491493225, 0.40787792205810547, 1.4179370403289795, 3.411585807800293, 0.188419371843338, 0.4351235628128052, -0.1647183895111084, -1.0001062154769897, 1.4785397052764893, 0.9681095480918884, -0.1110023632645607, -0.5086382627487183, -1.073492169380188, 1.2173030376434326, 1.9763067960739136, 1.0842106342315674, -0.0505402535200119, -0.7750580310821533, -0.6152827143669128, 0.010902555659413338, 0.2083328664302826, 0.47943949699401855, 0.97858726978302, 0.016569774597883224, 0.0774465799331665, 1.4388210773468018, 1.233147144317627, -0.47984039783477783, 0.40589043498039246, -0.8139421939849854, -0.3297405540943146, 0.5181412100791931, 0.3255327045917511, -0.10039028525352478, 0.3311226963996887, -0.8891564011573792, -0.3165569603443146, -0.4481317400932312, -0.8975846171379089, -0.7226130962371826, -0.4909592568874359, -0.41423141956329346, 1.6239525079727173, 0.17904320359230042, -0.5279996395111084, -0.07303322106599808, -0.7850082516670227, -0.09279368817806244, -1.0026450157165527, 0.2277713567018509, -0.13459435105323792, -0.15870796144008636, -0.10545065253973007, 1.8975282907485962, -0.974982500076294, -2.0337564945220947, 0.27676326036453247, 0.23443837463855743, -0.24430787563323975, 0.15903469920158386, 1.5404760837554932, 0.4726552665233612, 1.39718496799469, 1.3215935230255127, 0.9183763265609741, -0.6859934329986572, -1.3402279615402222, 0.763484001159668, 1.0096229314804077, -1.4519610404968262, 0.8204693794250488, 0.020752323791384697, -0.5415372848510742, 0.699018657207489, 1.2300516366958618, 0.3386923372745514, -1.868520975112915, 0.7732422947883606, -0.9093128442764282, 0.7158939242362976, 0.7317277789115906, 0.6955958008766174, 0.24128960072994232, 0.7064875364303589, -1.3053388595581055, -1.1226544380187988, -0.8241376876831055, -0.5980273485183716, 1.9544403553009033, -0.15336722135543823, 0.667685866355896, -0.1982506811618805, -1.346840262413025, -0.008718712255358696, 0.6667144298553467, 0.21483813226222992, -0.4048521816730499, 0.7893400192260742, -0.6919283866882324, -1.065995693206787, -1.4589204788208008, -0.3663521409034729, -1.0485947132110596, -0.8278128504753113, 1.100986361503601, 0.7832168936729431, 0.17106586694717407, 1.8396002054214478, 0.6054821610450745, 0.32800963521003723, -2.5952439308166504, 0.9226183295249939, 0.22595037519931793, -0.08425033837556839, 0.8767679333686829, 0.2386017143726349, 1.114503026008606, 0.06408153474330902, 0.4707719087600708, -2.442237615585327, 2.2616031169891357, -0.24808582663536072, 0.7532179355621338, 0.08747413009405136, -0.16989825665950775, 1.2121596336364746, 0.6468788981437683, 0.5757826566696167, -1.099677324295044, 0.6559343338012695, -0.5942506790161133, 1.242065191268921, 1.0646802186965942, -0.8591229915618896, -0.05297784507274628, 1.416496992111206, 0.5105710625648499, -0.34891414642333984, -0.932271420955658, -0.943496584892273, 0.9820512533187866, 1.691489338874817, -0.11035413295030594, -0.07918143272399902, 0.7986912131309509, 0.6439564824104309, -1.2810637950897217, 0.028341693803668022, -0.736513614654541, -0.7708807587623596, 1.6333458423614502, 2.0237791538238525, -0.08712797611951828, -0.1906966120004654, -0.8042739629745483, -1.2169908285140991, 0.7641474008560181, -0.039396658539772034, 0.19989842176437378, 0.6226094961166382, -0.6802390813827515, 1.1830663681030273, 0.9554316997528076, 0.7415957450866699, 0.20991890132427216, 0.28910940885543823, 0.41288596391677856, -0.28015977144241333, -1.1207847595214844, -0.31602802872657776, -1.1563624143600464, -2.5381736755371094, 0.5186963677406311, -0.3725685179233551, -1.4691072702407837, 0.07382246851921082, -1.0698387622833252, 1.0360695123672485, -0.6160033941268921, -0.9898282885551453, -1.7357959747314453, 0.29904186725616455, -0.14666032791137695, 1.031296730041504, -1.5538204908370972, -0.1391659826040268, 1.2468643188476562, 0.8773118257522583, -0.5623136758804321, 1.0786526203155518, 0.20854321122169495, 1.0274369716644287, 0.8035964965820312, -0.396237850189209, 0.4864010810852051, 0.16883188486099243, -1.3811835050582886, 0.4447513520717621, 1.2229862213134766, 0.21057924628257751, 1.3246841430664062, -0.5185383558273315, 0.05116797983646393, 0.40245139598846436, -0.5760947465896606, -0.444305956363678, -0.47252196073532104, 0.781892716884613, 0.04211098700761795, -0.8540714979171753, 0.01699686236679554, -0.14196191728115082, -0.37636488676071167, 0.16288265585899353, -1.6249384880065918, -0.2986243963241577, -0.4269445240497589, -0.5419983863830566, -1.3124843835830688, -0.08797767013311386, 1.379032015800476, -0.8499376177787781, -0.20802979171276093, 0.49923235177993774, 0.5296707153320312, 0.528206467628479, 0.58208167552948, -0.6694004535675049, -0.29519402980804443, -0.2940009832382202, -0.26965129375457764, 0.2191532999277115, 1.3939546346664429, -0.15993326902389526, -0.9565898776054382, 0.7153834104537964, -0.3649190366268158, 0.06631086766719818, 1.965580940246582, 0.12882891297340393, -0.8306608200073242, 0.3532951772212982, -0.7024497985839844, 1.9327642917633057, 1.7249321937561035, 1.2875300645828247, -0.02127496339380741, -0.9352265000343323, 0.5164583921432495, -0.25299957394599915, -0.2595774531364441, 0.873845100402832, 0.4501097500324249, -0.1810707002878189, -1.5696923732757568, 0.6816190481185913, 1.2575637102127075, -0.8700020909309387, -0.8681306838989258, 0.03078722022473812, -0.7948877811431885, 0.9350416660308838, 0.6495981216430664, 0.46441197395324707, 0.2268841415643692, 1.6401549577713013, 0.7501462697982788, -0.6190569400787354, 0.5272092223167419, 0.508077085018158, -0.12593474984169006, -2.1260581016540527, -1.0521459579467773, 0.27437153458595276, -0.383443146944046, -1.4864501953125, 1.415928840637207, -1.091984510421753, -0.8328919410705566, 0.5505807995796204, 0.14751015603542328, 1.491171956062317, 0.401420921087265, 1.5407850742340088, 2.103421926498413, 0.8664979934692383, 0.2955453395843506, 1.38998544216156, -0.23946523666381836, -0.42391255497932434, 1.8794652223587036, -0.3771997392177582, 0.49357670545578003, 1.1349925994873047, -0.35665398836135864, -0.8871111869812012, -0.7149180173873901, -1.1334505081176758, -0.697394609451294, 1.082122564315796, 0.1201104000210762, -1.1004948616027832, 0.13386976718902588, 1.6088180541992188, 0.12814460694789886, -0.3523051142692566, 0.5977376103401184, 0.46330660581588745, -0.733538031578064, -0.11069101095199585, -1.046006679534912, 0.46169450879096985, -0.23702675104141235, -0.3423570990562439, 0.3758706748485565, 0.42305025458335876, 1.2093663215637207, 0.01696527749300003, 0.1149936243891716, 1.0561949014663696, -1.420079231262207, 1.449270486831665, -0.690278172492981, 0.2202494889497757, -2.3829808235168457, 1.445712924003601, -0.7551095485687256, 1.9477447271347046, -2.6389591693878174, 0.39799800515174866, -0.6902742981910706, -0.4702187180519104, 0.3144535422325134, -0.3374989330768585, 0.22814002633094788, -0.15909841656684875, -1.0442404747009277, -0.033845238387584686, -0.6997158527374268, 0.5802183151245117, 1.1960885524749756, 1.3297206163406372, -1.1866049766540527, -0.35011494159698486, -1.6649222373962402, -0.25056520104408264, -0.769076943397522, 0.32784825563430786, -1.9527502059936523, -0.19138936698436737, -1.8138691186904907, -2.3219056129455566, -1.454417109489441, -0.802642822265625, 1.2178993225097656, 0.12888725101947784, -0.9568142890930176, 1.221566915512085, -0.42922547459602356, -1.876400351524353, 1.1264102458953857, -2.1527328491210938 ]
https://github.com/huggingface/datasets/issues/5219
Delta Tables usage using Datasets Library
@lhoestq Per my understanding, delta lake table is a bunch of paruqet files together with the meta to support ACID. For example file 1 contains v0.1 of record A while file 2 contains v0.2 of record A. I am assuming the Hugging face dataset would delegate the read/write delta table to 3rd party lib, maybe pyarrow. Correct me if I was wrong @reichenbch And I am assuming, people are asking the versioning of Hugging face datasets. But I am assuming Hugging face delegate this function to github and it is not the key requirement for Public Data set. It actually the key function of ML Ops, I am not sure whether hugging face would like expand to that area.
### Feature request Adding compatibility of Datasets library with Delta Format. Elevating the utilities of Datasets library from Machine Learning Scope to Data Engineering Scope as well. ### Motivation We know datasets library can absorb csv, json, parquet, etc. file formats but it would be great if Datasets library could work with Delta Tables (with delta format) as it has different features such as time travelling, layout optimization, query performance, aids in Data Engineering. This will help and enhance Datasets library from Machine Learning utility to Data Engineering utilities and expand horizons thereafter. I am totally using Datasets library in all my usecases and as my role expands so does the work, compatibility with Datasets library is something I don't want to lose. ### Your contribution Would love to work on this feature, even if this has to picked up from scratch, including design paradigms and patterns. I have basic idea about Delta Live Tables, would brush it easily for this feature.
435
119
Delta Tables usage using Datasets Library ### Feature request Adding compatibility of Datasets library with Delta Format. Elevating the utilities of Datasets library from Machine Learning Scope to Data Engineering Scope as well. ### Motivation We know datasets library can absorb csv, json, parquet, etc. file formats but it would be great if Datasets library could work with Delta Tables (with delta format) as it has different features such as time travelling, layout optimization, query performance, aids in Data Engineering. This will help and enhance Datasets library from Machine Learning utility to Data Engineering utilities and expand horizons thereafter. I am totally using Datasets library in all my usecases and as my role expands so does the work, compatibility with Datasets library is something I don't want to lose. ### Your contribution Would love to work on this feature, even if this has to picked up from scratch, including design paradigms and patterns. I have basic idea about Delta Live Tables, would brush it easily for this feature. @lhoestq Per my understanding, delta lake table is a bunch of paruqet files together with the meta to support ACID. For example file 1 contains v0.1 of record A while file 2 contains v0.2 of record A. I am assuming the Hugging face dataset would delegate the read/write delta table to 3rd party lib, maybe pyarrow. Correct me if I was wrong @reichenbch And I am assuming, people are asking the versioning of Hugging face datasets. But I am assuming Hugging face delegate this function to github and it is not the key requirement for Public Data set. It actually the key function of ML Ops, I am not sure whether hugging face would like expand to that area.
[ -1.2338666915893555, -1.013400912284851, -0.7742330431938171, 1.4133477210998535, -0.14629723131656647, -1.2019288539886475, 0.12571905553340912, -1.1214171648025513, 1.625464916229248, -0.8309222459793091, 0.294321209192276, -1.6209945678710938, 0.07327441871166229, -0.6209760308265686, -0.7155194282531738, -0.9831911325454712, -0.4004749059677124, -0.8084030747413635, 1.0403978824615479, 2.5860650539398193, 1.105675220489502, -1.3496350049972534, 2.7164440155029297, 0.6912153363227844, -0.23376870155334473, -0.9963177442550659, 0.5614655017852783, 0.11536979675292969, -1.210750699043274, -0.4992457330226898, -0.9088299870491028, -0.01629447191953659, -0.5096286535263062, -0.4833064675331116, -0.02174495905637741, 0.30927908420562744, -0.20758379995822906, -0.4047771692276001, -0.5501782298088074, -0.7165324091911316, 0.4367271661758423, -0.322047621011734, 0.960651159286499, -0.3185026943683624, 1.9238461256027222, -0.44233259558677673, 0.3359453082084656, 0.7485564351081848, 1.3193312883377075, 0.2204078584909439, -0.0153834018856287, 0.1897561252117157, 0.4455656409263611, -0.11248072981834412, 0.4510973393917084, 1.1143900156021118, 0.6410543322563171, 0.5538405179977417, 0.6654818058013916, -2.1778485774993896, 1.4149668216705322, -1.1207573413848877, 0.42460107803344727, 1.4189344644546509, -0.9304551482200623, 0.5152098536491394, -1.6663767099380493, -0.13071109354496002, 0.4791327118873596, -2.3018500804901123, 0.13508117198944092, -1.1909581422805786, -0.5025809407234192, 0.980817973613739, 0.29867854714393616, -1.2589436769485474, 0.24810950458049774, -0.4699125587940216, 1.0589858293533325, 0.5099766254425049, 1.203517198562622, -1.7782258987426758, 0.04672182351350784, -0.26502734422683716, 0.1072273850440979, -1.3517102003097534, -1.494553804397583, 0.4715477526187897, 0.6467127203941345, 0.5920825004577637, -0.017567090690135956, 0.9605152606964111, -1.0183087587356567, 0.8328022360801697, -0.8866457939147949, -1.5486011505126953, -1.37201988697052, -2.3208556175231934, -2.435504198074341, 0.7964767217636108, -0.44002360105514526, -0.5397026538848877, 2.0812113285064697, -1.0522029399871826, -1.7397962808609009, 1.3258346319198608, 0.2805189788341522, -0.09679524600505829, 2.4766504764556885, 0.2940921485424042, -0.6606993675231934, 0.4402119815349579, -0.7493018507957458, 0.8120846152305603, -0.5282315015792847, 1.4043982028961182, 0.4756394922733307, -1.0459697246551514, 1.497193694114685, -0.47978875041007996, 0.5033910870552063, -0.6425411105155945, -0.5093488097190857, -0.8625933527946472, 0.43819040060043335, 1.7762329578399658, -0.2658288776874542, 1.6029253005981445, -0.42157551646232605, -1.582763433456421, -1.687354326248169, 0.8704879879951477, 0.42319512367248535, -0.7142677307128906, 0.04499952495098114, -0.37122511863708496, 0.04886140674352646, 0.0667697936296463, 1.0372469425201416, 1.1712262630462646, 0.6712110042572021, -0.38910219073295593, -0.9139962196350098, 0.30190059542655945, -0.07186451554298401, -0.6628227233886719, -1.8309085369110107, -0.29328715801239014, 0.04826367646455765, 0.5965959429740906, -1.2368024587631226, 1.583909273147583, 0.9441928267478943, 1.8820990324020386, 1.0012825727462769, -0.3435385823249817, 1.5128719806671143, 0.08706097304821014, 1.7976161241531372, -0.48655757308006287, 0.7237645387649536, -0.36577942967414856, -1.1003639698028564, 0.7722955346107483, -0.3584284782409668, -1.9860496520996094, -0.7995893359184265, -0.8079658150672913, -0.22046369314193726, -0.824495792388916, 1.0063555240631104, -0.2629731595516205, -1.425360083580017, 0.3015631139278412, -0.6420457363128662, 0.1349383443593979, -1.172037124633789, 0.36273062229156494, 0.7521706819534302, -0.6747018098831177, 0.07569435238838196, -0.23046694695949554, -1.313742995262146, -0.35910192131996155, 0.29084205627441406, 1.8793528079986572, -0.7537584900856018, 0.9513967633247375, 1.0097874402999878, -0.6810758709907532, 0.0015065614134073257, 0.39532533288002014, -0.3262624442577362, 0.803412675857544, -0.9701953530311584, -0.4054134488105774, 1.1832152605056763, -0.23572395741939545, -0.4626626670360565, 1.4535882472991943, 0.7363788485527039, -1.023219347000122, -0.12179966270923615, -0.1846555471420288, -0.7980378270149231, -0.06322745233774185, -1.6203117370605469, -0.10806944966316223, 0.23095425963401794, -1.4872019290924072, -0.5053143501281738, -0.29332005977630615, 1.2656173706054688, -0.1338350921869278, 1.449336290359497, -0.3994111716747284, -0.18229517340660095, -0.37949326634407043, -0.4570678174495697, 0.2413904219865799, -0.19053775072097778, -0.576262354850769, 0.2996602952480316, -0.819330632686615, 0.3194798529148102, 1.4675296545028687, 0.38083022832870483, 0.06062280759215355, 0.45148012042045593, 0.9766799211502075, 0.4053312838077545, -0.12466898560523987, -0.8713706731796265, -1.5293688774108887, 2.0321543216705322, -1.5044550895690918, 2.011730670928955, 0.8696673512458801, -0.03253399580717087, -1.7661385536193848, -1.8431448936462402, 1.3600560426712036, 1.2313152551651, 2.3428523540496826, 0.5616584420204163, 0.28333139419555664, -0.7929438352584839, -0.6464697122573853, 0.3124774098396301, -1.1583579778671265, -0.719565212726593, 0.10155583918094635, 2.296213388442993, 1.7552560567855835, -0.5013118982315063, -0.17138417065143585, -1.0583868026733398, 1.3443033695220947, -0.15674225986003876, 0.10349094867706299, 2.077059507369995, -0.35929083824157715, -1.0949735641479492, 1.3295936584472656, -2.3454227447509766, 0.11913980543613434, 1.876549482345581, 0.329624742269516, 0.04324920475482941, -1.4616867303848267, -0.6186096668243408, -0.2685041129589081, -0.39826199412345886, -1.2653850317001343, 0.6081903576850891, -0.28969496488571167, -0.7641571164131165, -1.4889612197875977, 0.15811185538768768, -1.1382807493209839, -1.6798579692840576, 0.3770278990268707, 1.8502029180526733, 2.0743048191070557, -0.7965080738067627, 1.547352910041809, -0.21517178416252136, 0.1606702208518982, 1.1499416828155518, 1.1159579753875732, 3.136178970336914, 1.852698564529419, -1.26052725315094, 0.5460235476493835, -0.112367644906044, -0.5120822787284851, 1.104299545288086, -1.0516958236694336, 1.3302596807479858, -0.12433178722858429, -1.1927005052566528, -1.2480671405792236, 0.9701153635978699, 0.46128249168395996, 0.11668433248996735, -0.559079647064209, 1.215622067451477, 0.025158077478408813, 1.2624094486236572, 0.4972383975982666, -0.319746196269989, 0.6302604675292969, -0.4197219908237457, -0.5598588585853577, 1.5520901679992676, 0.20726223289966583, -1.4856497049331665, -2.2762439250946045, -0.19844436645507812, -0.7002450227737427, 0.004071531817317009, -0.627253532409668, -0.9901157021522522, 1.5937669277191162, 0.47542229294776917, -1.2328442335128784, -0.27352824807167053, -0.4072415232658386, -0.6525810360908508, 2.606433868408203, -1.4356330633163452, -0.2702060043811798, -0.9165666103363037, -0.567823588848114, 1.4848076105117798, -1.1998728513717651, -0.1457393318414688, -0.9931010603904724, -0.6266995072364807, -1.332594633102417, -0.5978532433509827, 0.00564645417034626, -1.0111546516418457, 0.8064744472503662, 0.14484989643096924, -1.1127601861953735, -0.2784830629825592, -0.9123646020889282, 0.8236358165740967, -0.08078230917453766, 0.3631878197193146, 1.8023654222488403, 0.398467093706131, -0.4305822551250458, 0.7292894721031189, 1.1918541193008423, 0.6883387565612793, -0.7134071588516235, 0.1381215751171112, -0.8234161734580994, 0.31067773699760437, -1.2173078060150146, 0.32440152764320374, -2.870328903198242, 0.6676258444786072, -0.04809707775712013, -0.1286938637495041, 0.0014842236414551735, -1.2204031944274902, 1.102002739906311, 2.6141178607940674, -1.0762172937393188, 0.4906309247016907, 0.2975744307041168, 1.305400013923645, -1.5582489967346191, 0.42162081599235535, -0.35153719782829285, 2.1115341186523438, 0.2630387842655182, 1.1791164875030518, -0.5559146404266357, -2.274440050125122, 0.5717021822929382, -1.356075644493103, -1.162567138671875, 0.7936751246452332, -0.8662822842597961, -0.07847246527671814, -1.3891031742095947, -0.09386046230792999, -0.7877975702285767, -1.2402654886245728, 0.6788991093635559, 0.21161843836307526, 0.4753727614879608, -0.5875704288482666, 0.33241602778434753, -2.2193679809570312, -1.3804943561553955, -0.2210818976163864, -0.9829289317131042, 0.4156089723110199, -0.33979758620262146, 0.7250290513038635, -0.2426622211933136, -0.028032764792442322, 0.38780346512794495, 1.3994228839874268, 3.388038158416748, 0.22203394770622253, 0.45468729734420776, -0.16661415994167328, -1.009087085723877, 1.4819084405899048, 0.9239299297332764, -0.16905860602855682, -0.5880598425865173, -1.0954110622406006, 1.246715784072876, 1.9664127826690674, 1.0723841190338135, 0.005571192130446434, -0.7821948528289795, -0.6825103163719177, 0.014227582141757011, 0.2816190719604492, 0.47973382472991943, 0.9613614082336426, -0.028096696361899376, 0.14302967488765717, 1.523236870765686, 1.2540580034255981, -0.5167360305786133, 0.4440227150917053, -0.8004898428916931, -0.42328518629074097, 0.5151236653327942, 0.3123215138912201, -0.04139845073223114, 0.33883553743362427, -0.886574387550354, -0.29319849610328674, -0.4318632483482361, -0.9315139651298523, -0.7306433320045471, -0.4186990261077881, -0.37713444232940674, 1.675479769706726, 0.16892215609550476, -0.4918155074119568, -0.01514894887804985, -0.7605682611465454, -0.09898333251476288, -1.0120556354522705, 0.25069567561149597, -0.09703551232814789, -0.11071133613586426, -0.08909450471401215, 1.9188554286956787, -0.9794610738754272, -2.093578815460205, 0.23620834946632385, 0.22473877668380737, -0.2239382565021515, 0.23913124203681946, 1.5453897714614868, 0.4982324242591858, 1.406829595565796, 1.3259828090667725, 0.995507001876831, -0.7292984127998352, -1.3846187591552734, 0.7782520651817322, 0.9874449968338013, -1.4212208986282349, 0.7986099123954773, 0.03938513621687889, -0.5298262238502502, 0.7298252582550049, 1.276376485824585, 0.3514529764652252, -1.929680585861206, 0.780055820941925, -0.9368755221366882, 0.7928646206855774, 0.6979667544364929, 0.6799203753471375, 0.19181419909000397, 0.7182698845863342, -1.3335871696472168, -1.1410174369812012, -0.7716506123542786, -0.5835800766944885, 1.9673405885696411, -0.16597090661525726, 0.6782211661338806, -0.2052537053823471, -1.3774007558822632, -0.0035699508152902126, 0.6548416018486023, 0.27809518575668335, -0.3735078275203705, 0.8115739226341248, -0.7126733660697937, -1.1103746891021729, -1.5006552934646606, -0.3702055513858795, -1.030051589012146, -0.8723011612892151, 1.1104964017868042, 0.7239367365837097, 0.15335234999656677, 1.8346765041351318, 0.5602207779884338, 0.3421541154384613, -2.6286680698394775, 0.9360684752464294, 0.24734796583652496, -0.10364383459091187, 0.8571986556053162, 0.2756405174732208, 1.0479332208633423, 0.08252671360969543, 0.45609748363494873, -2.413369655609131, 2.3249173164367676, -0.20769277215003967, 0.7912417054176331, 0.08544839918613434, -0.19306200742721558, 1.1745272874832153, 0.6821125149726868, 0.6296939253807068, -1.1103360652923584, 0.6492416858673096, -0.5874459743499756, 1.2581403255462646, 1.0558723211288452, -0.797597348690033, -0.08222447335720062, 1.3424620628356934, 0.5272418260574341, -0.37392520904541016, -0.9254947304725647, -1.0206483602523804, 0.9263665080070496, 1.762718677520752, -0.11977805197238922, -0.020767752081155777, 0.7278969883918762, 0.6640470027923584, -1.3017144203186035, 0.07481230795383453, -0.8035873174667358, -0.8098137378692627, 1.5656300783157349, 2.0607497692108154, -0.11701560020446777, -0.1837610900402069, -0.7170066237449646, -1.2152823209762573, 0.8036483526229858, -0.031037937849760056, 0.2683403789997101, 0.5952592492103577, -0.6058738231658936, 1.1192526817321777, 1.0041978359222412, 0.7811412811279297, 0.25258639454841614, 0.2549268901348114, 0.383910596370697, -0.3008502423763275, -1.1312960386276245, -0.22771865129470825, -1.160833477973938, -2.5052101612091064, 0.3884579837322235, -0.2929258942604065, -1.438462734222412, 0.03331621363759041, -1.0057225227355957, 0.9626619815826416, -0.5508602261543274, -1.0128800868988037, -1.6636358499526978, 0.24583981931209564, -0.18916471302509308, 0.9983212947845459, -1.5714919567108154, -0.13053536415100098, 1.2418168783187866, 0.9120455384254456, -0.584571123123169, 1.027301549911499, 0.15684570372104645, 0.993783712387085, 0.8064261078834534, -0.40792644023895264, 0.46092262864112854, 0.14837071299552917, -1.3844249248504639, 0.4199758768081665, 1.1549814939498901, 0.22014668583869934, 1.354951024055481, -0.5849407911300659, 0.03505594655871391, 0.37452971935272217, -0.5313791036605835, -0.4492519199848175, -0.509583055973053, 0.7379648685455322, 0.02248602919280529, -0.8698186874389648, 0.11606942117214203, -0.1225365549325943, -0.3305537700653076, 0.1992933750152588, -1.6099902391433716, -0.25476256012916565, -0.4490608274936676, -0.4945731461048126, -1.341270089149475, -0.08392824232578278, 1.413041353225708, -0.83745276927948, -0.22166872024536133, 0.46436062455177307, 0.5560303330421448, 0.540638267993927, 0.6068161129951477, -0.6360490918159485, -0.37695497274398804, -0.28157857060432434, -0.27507033944129944, 0.25699618458747864, 1.3700361251831055, -0.18345431983470917, -0.9283321499824524, 0.7001152038574219, -0.38029006123542786, 0.08710514008998871, 1.9624892473220825, 0.11906358599662781, -0.8178653120994568, 0.3500290513038635, -0.6651817560195923, 1.9080452919006348, 1.7054921388626099, 1.3410528898239136, -0.11633467674255371, -0.921339750289917, 0.548913300037384, -0.2641388475894928, -0.3105415105819702, 0.9390563368797302, 0.44961872696876526, -0.19831408560276031, -1.5106277465820312, 0.6180383563041687, 1.2784353494644165, -0.7915638089179993, -0.8401113152503967, 0.01036362536251545, -0.8524874448776245, 0.9725584983825684, 0.6380165219306946, 0.46655988693237305, 0.20550447702407837, 1.6863065958023071, 0.7388207316398621, -0.59810870885849, 0.5227197408676147, 0.483620285987854, -0.19128313660621643, -2.1053383350372314, -1.1130505800247192, 0.22475388646125793, -0.4493230879306793, -1.4773215055465698, 1.424538254737854, -1.136825442314148, -0.8759439587593079, 0.5659255981445312, 0.07868409156799316, 1.4186700582504272, 0.3387400507926941, 1.5319850444793701, 2.1502366065979004, 0.886661946773529, 0.3325992226600647, 1.377445936203003, -0.21685025095939636, -0.3726588785648346, 1.8209147453308105, -0.35491710901260376, 0.4284912943840027, 1.1503463983535767, -0.37304070591926575, -0.9579870700836182, -0.7709959745407104, -1.0888863801956177, -0.6908894777297974, 1.0990039110183716, 0.10862503945827484, -1.1092809438705444, 0.19336502254009247, 1.6297510862350464, 0.10334567725658417, -0.3483213484287262, 0.5537551641464233, 0.5330270528793335, -0.6908979415893555, -0.0892508327960968, -1.0208677053451538, 0.42761561274528503, -0.2726702094078064, -0.36849063634872437, 0.3354959785938263, 0.41012534499168396, 1.2260936498641968, -0.03431318700313568, 0.1583084613084793, 1.152695894241333, -1.366950511932373, 1.4032901525497437, -0.6245862245559692, 0.21434330940246582, -2.3986294269561768, 1.4596136808395386, -0.7013932466506958, 1.9095650911331177, -2.628657102584839, 0.4643421769142151, -0.6804305911064148, -0.45334479212760925, 0.359618216753006, -0.3957919478416443, 0.22617146372795105, -0.22139643132686615, -1.08034348487854, -0.12104932963848114, -0.6848165988922119, 0.5038031339645386, 1.1596711874008179, 1.2958840131759644, -1.0643539428710938, -0.3066159188747406, -1.6512607336044312, -0.2102707177400589, -0.7125021815299988, 0.3315034508705139, -1.9987837076187134, -0.2534826099872589, -1.8386962413787842, -2.342945098876953, -1.3815139532089233, -0.7660773992538452, 1.200095295906067, 0.13244250416755676, -0.9239303469657898, 1.2876297235488892, -0.4582706093788147, -1.8831602334976196, 1.1336246728897095, -2.1541388034820557 ]
https://github.com/huggingface/datasets/issues/5216
save_elasticsearch_index
Hi ! I think there exist tools to dump and reload an index in your elastic search but I'm not super familiar with it. Anyway after reloading an index in elastic search you can call `ds.load_elasticsearch_index` which will connect the index to the dataset without re-indexing
Hi, I am new to Dataset and elasticsearch. I was wondering is there any equivalent approach to save elasticsearch index as of save_faiss_index locally for later use, to remove the need to re-index a dataset?
436
46
save_elasticsearch_index Hi, I am new to Dataset and elasticsearch. I was wondering is there any equivalent approach to save elasticsearch index as of save_faiss_index locally for later use, to remove the need to re-index a dataset? Hi ! I think there exist tools to dump and reload an index in your elastic search but I'm not super familiar with it. Anyway after reloading an index in elastic search you can call `ds.load_elasticsearch_index` which will connect the index to the dataset without re-indexing
[ -1.3909711837768555, -0.9974580407142639, -0.7578473687171936, 1.416235089302063, -0.17309188842773438, -1.16696035861969, 0.13344189524650574, -1.0814085006713867, 1.5899484157562256, -0.9839093089103699, 0.3602564334869385, -1.468231439590454, 0.07060202956199646, -0.5085134506225586, -0.7729642391204834, -0.8467769622802734, -0.3914720118045807, -0.7101321816444397, 1.0960487127304077, 2.498332977294922, 1.0859812498092651, -1.5272859334945679, 2.7427713871002197, 0.6507726311683655, -0.28442245721817017, -1.0391287803649902, 0.4917314052581787, 0.2327888160943985, -1.211174488067627, -0.497284859418869, -0.9221435189247131, -0.06786199659109116, -0.8016471266746521, -0.3397253453731537, -0.0060911281034350395, 0.4033077657222748, -0.2592703104019165, -0.5745769739151001, -0.46258142590522766, -0.7482246160507202, 0.5640290379524231, -0.2886652648448944, 0.9376652240753174, -0.32828614115715027, 1.673142433166504, -0.4036863148212433, 0.4470272958278656, 0.7167550921440125, 1.4328978061676025, 0.13752777874469757, -0.09547765552997589, 0.22318941354751587, 0.45539548993110657, -0.11148840188980103, 0.29593560099601746, 1.0825691223144531, 0.377916157245636, 0.7002897262573242, 0.7991657853126526, -2.0782339572906494, 1.444454550743103, -1.1296278238296509, 0.18227753043174744, 1.384785532951355, -0.9813466668128967, 0.43598461151123047, -1.8354295492172241, -0.07178209722042084, 0.4986066520214081, -2.233304977416992, 0.24213561415672302, -1.3044166564941406, -0.5990820527076721, 0.9418399930000305, 0.44077226519584656, -1.3154387474060059, 0.10130411386489868, -0.421373188495636, 0.9750434160232544, 0.5423638224601746, 1.1649247407913208, -1.6551580429077148, 0.06782180070877075, -0.38878878951072693, 0.1401200294494629, -1.4764900207519531, -1.374483585357666, 0.5519391894340515, 0.6014682650566101, 0.4624529182910919, 0.022232504561543465, 1.0836076736450195, -1.0807679891586304, 0.8043116331100464, -1.0547256469726562, -1.3964768648147583, -1.3021398782730103, -2.4691567420959473, -2.3766987323760986, 0.7564502358436584, -0.5160074234008789, -0.5407647490501404, 2.2242696285247803, -1.0733726024627686, -1.7705892324447632, 1.3643195629119873, 0.31868040561676025, 0.12984220683574677, 2.410968542098999, 0.18209895491600037, -0.6931577920913696, 0.5126237273216248, -0.6421597599983215, 0.9195971488952637, -0.5452046394348145, 1.3634992837905884, 0.4522135555744171, -0.9346449971199036, 1.615578293800354, -0.1956891566514969, 0.5643079876899719, -0.5086061954498291, -0.5616998076438904, -0.8314136862754822, 0.5211657881736755, 1.7617148160934448, -0.233011394739151, 1.542353868484497, -0.5197067260742188, -1.5727612972259521, -1.6721645593643188, 1.0426441431045532, 0.5578809380531311, -0.8967846632003784, 0.1787673681974411, -0.3929974138736725, -0.00131703307852149, -0.08638040721416473, 1.191948413848877, 1.4471569061279297, 0.6930014491081238, -0.3100682199001312, -0.972474992275238, 0.2143847942352295, -0.12723438441753387, -0.8257148861885071, -1.735459566116333, -0.39030563831329346, 0.0005789408460259438, 0.651588499546051, -1.113925814628601, 1.6910756826400757, 1.0360219478607178, 2.0669949054718018, 0.9127342104911804, -0.32112208008766174, 1.420572280883789, 0.016525188460946083, 1.7880221605300903, -0.5605979561805725, 0.7195748090744019, -0.4786111116409302, -1.0714716911315918, 0.8333725333213806, -0.45148733258247375, -1.9344029426574707, -0.8033909201622009, -0.7964969873428345, -0.22446662187576294, -0.7971338033676147, 0.9948590993881226, -0.19386698305606842, -1.3742868900299072, 0.23557031154632568, -0.5852316617965698, 0.1415015012025833, -1.0808546543121338, 0.3730643391609192, 0.5665678381919861, -0.6442834734916687, -0.07028744369745255, -0.3402809798717499, -1.2064619064331055, -0.5678380727767944, 0.2693871855735779, 1.707862138748169, -0.6931537389755249, 0.9552690386772156, 0.9239689111709595, -0.7578541040420532, 0.06860712170600891, 0.3483384847640991, -0.22892679274082184, 0.6972408890724182, -1.1115890741348267, -0.48166197538375854, 1.2658984661102295, -0.30080777406692505, -0.5991480946540833, 1.459546685218811, 0.7169126868247986, -0.9060865640640259, -0.05229616537690163, -0.17206034064292908, -0.7459427714347839, 0.02989167347550392, -1.6331713199615479, -0.05462196469306946, 0.2415340095758438, -1.5382015705108643, -0.4388149082660675, -0.08568026125431061, 1.304132342338562, -0.1507783830165863, 1.4740104675292969, -0.3243296444416046, -0.15630047023296356, -0.3910803496837616, -0.4424183666706085, 0.15675529837608337, -0.05485495179891586, -0.43952611088752747, 0.1338275671005249, -0.8561219573020935, 0.39567798376083374, 1.407706618309021, 0.3854762315750122, 0.14613653719425201, 0.4070151746273041, 0.9826491475105286, 0.31019648909568787, -0.06079645827412605, -0.905824601650238, -1.489361047744751, 1.8375041484832764, -1.5003504753112793, 2.1059930324554443, 0.7921580672264099, -0.21424365043640137, -1.6641019582748413, -1.8263158798217773, 1.3934141397476196, 1.1020065546035767, 2.2015163898468018, 0.6077548861503601, 0.24137292802333832, -0.7436275482177734, -0.6627488136291504, 0.39228346943855286, -1.0417152643203735, -0.6622404456138611, 0.039608556777238846, 2.21115779876709, 1.608997106552124, -0.5143669843673706, -0.2223563939332962, -1.009128451347351, 1.2315857410430908, -0.15272939205169678, 0.343937486410141, 1.931698203086853, -0.5676445364952087, -1.1804611682891846, 1.199175477027893, -2.4059348106384277, 0.1070624589920044, 2.0583512783050537, 0.3473631739616394, 0.075249582529068, -1.4104365110397339, -0.5847045183181763, -0.1599348485469818, -0.3665704131126404, -1.283752679824829, 0.5950813293457031, -0.31572869420051575, -0.7643682956695557, -1.3837019205093384, 0.20505893230438232, -1.2359575033187866, -1.659968614578247, 0.46573519706726074, 1.8991822004318237, 2.0403738021850586, -0.6797224283218384, 1.5114340782165527, -0.33460691571235657, -0.06485770642757416, 1.0873218774795532, 1.2051310539245605, 3.0299742221832275, 1.8944929838180542, -1.1099447011947632, 0.5912503004074097, -0.11111031472682953, -0.6087102293968201, 1.2632946968078613, -1.168984293937683, 1.3324452638626099, -0.1751047521829605, -0.9403408169746399, -1.2163832187652588, 0.7525979280471802, 0.4277280867099762, 0.10152825713157654, -0.6202539801597595, 1.3122835159301758, 0.14090898633003235, 1.217206597328186, 0.44076651334762573, -0.4484250843524933, 0.8156940340995789, -0.5397428870201111, -0.5544463992118835, 1.6276562213897705, 0.18069131672382355, -1.444659948348999, -2.281628131866455, -0.24677425622940063, -0.7991394996643066, 0.16922463476657867, -0.6563548445701599, -0.979804515838623, 1.7335883378982544, 0.29927659034729004, -1.2054450511932373, -0.33955273032188416, -0.4440971612930298, -0.6414002180099487, 2.649406671524048, -1.2943323850631714, -0.2592807114124298, -0.8184314370155334, -0.5854821801185608, 1.6208593845367432, -1.2514574527740479, -0.07079628109931946, -1.0741846561431885, -0.4161507487297058, -1.3910551071166992, -0.4760746955871582, 0.10842229425907135, -0.9664650559425354, 0.7887281775474548, 0.20291006565093994, -1.1721160411834717, -0.4193054437637329, -0.6928350925445557, 0.8358572125434875, -0.0652945339679718, 0.3980630934238434, 1.7999294996261597, 0.3170861303806305, -0.3896504044532776, 0.8712972402572632, 1.2226628065109253, 0.6147281527519226, -0.6149770617485046, 0.23447057604789734, -0.5822747945785522, 0.41033968329429626, -1.216399908065796, 0.4504416584968567, -2.9868640899658203, 0.6412696838378906, -0.0915457010269165, -0.15057332813739777, -0.07243405282497406, -1.436418890953064, 1.1045609712600708, 2.5714409351348877, -1.108298897743225, 0.5393972396850586, 0.3735358417034149, 1.1082090139389038, -1.4954472780227661, 0.35356006026268005, -0.5147372484207153, 2.0963833332061768, 0.1828518807888031, 1.1452418565750122, -0.590149462223053, -2.3252830505371094, 0.5169782638549805, -1.2310999631881714, -1.1930872201919556, 0.6819117069244385, -0.9765275120735168, -0.008549594320356846, -1.4807428121566772, -0.23743054270744324, -0.9985798597335815, -1.1532009840011597, 0.711705207824707, 0.34741467237472534, 0.49958857893943787, -0.5898127555847168, 0.4304807782173157, -2.2977256774902344, -1.4153155088424683, -0.23869051039218903, -0.9280217885971069, 0.42010509967803955, -0.4660140573978424, 0.6380685567855835, -0.32966145873069763, 0.05173229053616524, 0.24944272637367249, 1.4972004890441895, 3.2758688926696777, 0.14848896861076355, 0.3271670341491699, -0.24445167183876038, -0.8677820563316345, 1.6538833379745483, 1.1033790111541748, 0.017280466854572296, -0.7144062519073486, -0.9844415783882141, 1.4035909175872803, 2.085088014602661, 0.8031874299049377, -0.11679276823997498, -0.7790656685829163, -0.5197560787200928, -0.09870871901512146, 0.0245802141726017, 0.411298930644989, 0.9787407517433167, 0.10866251587867737, 0.06374470889568329, 1.3633216619491577, 1.2663036584854126, -0.48100772500038147, 0.49813929200172424, -0.8586710691452026, -0.3656390309333801, 0.5108931660652161, 0.307119756937027, 0.0030149687081575394, 0.3257489800453186, -0.7592450380325317, -0.29614418745040894, -0.3462558388710022, -1.0612106323242188, -0.7518614530563354, -0.38962796330451965, -0.4133354425430298, 1.8246965408325195, 0.18208031356334686, -0.503481388092041, 0.010009756311774254, -0.7664833664894104, -0.0005935202352702618, -1.2368403673171997, 0.15872476994991302, -0.13837890326976776, 0.04178249463438988, -0.12043723464012146, 1.8233782052993774, -0.9404760003089905, -2.0063045024871826, 0.24151325225830078, 0.22924217581748962, -0.4087432324886322, 0.2263125628232956, 1.6921679973602295, 0.34737762808799744, 1.586150884628296, 1.4292908906936646, 0.9051145911216736, -0.6039749383926392, -1.2159817218780518, 0.7315583825111389, 0.8831248879432678, -1.5110512971878052, 0.9944940805435181, 0.13913439214229584, -0.6217355728149414, 0.8204358816146851, 1.1830161809921265, 0.4844467341899872, -2.095208168029785, 0.7599807381629944, -1.0053226947784424, 0.9190660715103149, 0.7197936773300171, 0.6005186438560486, 0.28450724482536316, 0.9817452430725098, -1.058070421218872, -1.1186907291412354, -0.7552018761634827, -0.7071561217308044, 2.1143975257873535, -0.3477361500263214, 0.6340866684913635, -0.11013901233673096, -1.1094810962677002, -0.16145117580890656, 0.6141546964645386, 0.37764185667037964, -0.23519659042358398, 0.7148577570915222, -0.6816197633743286, -1.203004002571106, -1.5676116943359375, -0.4632377326488495, -1.0554560422897339, -0.8933980464935303, 1.17800772190094, 0.7201201319694519, 0.24418053030967712, 1.9805201292037964, 0.5595328211784363, 0.19700591266155243, -2.6185452938079834, 0.838508665561676, 0.3265784680843353, -0.02955949306488037, 0.8490775227546692, 0.2674082815647125, 1.114435076713562, -0.015414861962199211, 0.5207995772361755, -2.411559581756592, 2.21621036529541, -0.25788381695747375, 0.6718990802764893, 0.13228395581245422, -0.04445260763168335, 1.0729634761810303, 0.5954563021659851, 0.6281401515007019, -1.190818190574646, 0.5650061368942261, -0.5828160643577576, 1.220868468284607, 0.9287998676300049, -0.7356672883033752, -0.0034014671109616756, 1.36799156665802, 0.49029073119163513, -0.5286661386489868, -0.9313757419586182, -0.7381309866905212, 0.8111639022827148, 1.5693970918655396, -0.07229341566562653, 0.12790372967720032, 0.7517991065979004, 0.6871936917304993, -1.2975702285766602, 0.11853532493114471, -0.8318207263946533, -0.7818655371665955, 1.609324336051941, 2.023916482925415, 0.017593802884221077, -0.009037598967552185, -0.6435872316360474, -1.2840250730514526, 0.8126663565635681, -0.08346383273601532, 0.17529326677322388, 0.4441641569137573, -0.6817169785499573, 1.0138921737670898, 0.6308769583702087, 0.7244755029678345, 0.07122980058193207, 0.2464064657688141, 0.6106578707695007, -0.23897455632686615, -1.1625760793685913, -0.20133750140666962, -1.0603101253509521, -2.599989652633667, 0.5796281695365906, -0.3883727788925171, -1.4144291877746582, -0.123896524310112, -1.0169390439987183, 0.8446837067604065, -0.5069843530654907, -1.0973660945892334, -1.5804946422576904, 0.07141031324863434, -0.04034077748656273, 0.9398368000984192, -1.6367446184158325, -0.11032366752624512, 1.0512326955795288, 0.7763921618461609, -0.7494635581970215, 1.042569875717163, 0.28570204973220825, 1.060086727142334, 0.7431224584579468, -0.5278396010398865, 0.5511597990989685, 0.024861101061105728, -1.28858482837677, 0.6539536118507385, 1.1956719160079956, 0.15444938838481903, 1.3504259586334229, -0.4211285412311554, 0.07208050787448883, 0.39256301522254944, -0.5878710746765137, -0.45524775981903076, -0.49473974108695984, 0.749614417552948, -0.0696968287229538, -0.7896332740783691, -0.03439948707818985, -0.18825815618038177, -0.2920393645763397, 0.19118894636631012, -1.467910885810852, -0.2882729470729828, -0.536406934261322, -0.4444599747657776, -1.4064068794250488, 0.08283188939094543, 1.365476369857788, -0.7049871683120728, -0.14505384862422943, 0.5530920028686523, 0.5949907898902893, 0.4640858769416809, 0.7167140245437622, -0.7016124129295349, -0.3076595067977905, -0.20334741473197937, -0.48251157999038696, 0.3665548264980316, 1.358421802520752, -0.2363889515399933, -0.871913492679596, 0.5868944525718689, -0.2684602737426758, -0.09739479422569275, 1.9209201335906982, 0.12702882289886475, -0.7582908868789673, 0.3544938266277313, -0.8058647513389587, 1.9192477464675903, 1.6087185144424438, 1.3231290578842163, -0.26143258810043335, -0.8966785669326782, 0.6405392289161682, -0.4073556363582611, -0.2616633474826813, 0.7829652428627014, 0.47074007987976074, -0.21655479073524475, -1.3616447448730469, 0.6883029937744141, 1.1762615442276, -0.872195303440094, -0.8958576917648315, -0.10069523751735687, -0.773796558380127, 1.0269466638565063, 0.6115019917488098, 0.5332300662994385, 0.2571491599082947, 1.719449520111084, 0.6787039637565613, -0.5860021710395813, 0.6034196615219116, 0.6328474283218384, -0.15041808784008026, -2.1039373874664307, -1.2509543895721436, 0.3369028866291046, -0.4877176880836487, -1.5647039413452148, 1.3476271629333496, -1.044494390487671, -1.081876277923584, 0.5235347747802734, -0.060740839689970016, 1.3755888938903809, 0.3291339576244354, 1.707306981086731, 2.059512138366699, 0.9896771311759949, 0.5179234743118286, 1.4879118204116821, -0.16609545052051544, -0.3945503830909729, 1.9725319147109985, -0.3446143865585327, 0.3187524676322937, 1.2971816062927246, -0.28599077463150024, -1.0124634504318237, -0.8331538438796997, -1.1847617626190186, -0.6369921565055847, 1.095563292503357, 0.17145632207393646, -1.1396989822387695, 0.27021658420562744, 1.6418085098266602, 0.15222641825675964, -0.17918157577514648, 0.5652041435241699, 0.4393836259841919, -0.7814300060272217, -0.02200040966272354, -1.018563985824585, 0.5031029582023621, -0.30124959349632263, -0.5109514594078064, 0.30484655499458313, 0.4682767987251282, 1.308512806892395, -0.18700389564037323, 0.19351384043693542, 1.1602851152420044, -1.5571726560592651, 1.2807538509368896, -0.6842747330665588, 0.3421500027179718, -2.3095853328704834, 1.3694207668304443, -0.7426031827926636, 1.9711757898330688, -2.774149179458618, 0.46375587582588196, -0.7256994247436523, -0.5940642356872559, 0.4118405878543854, -0.29687657952308655, 0.09046956896781921, -0.1928921490907669, -1.0045822858810425, 0.03539995104074478, -0.668014645576477, 0.6001133322715759, 1.130353569984436, 1.2187317609786987, -0.975918173789978, -0.2451847493648529, -1.5833910703659058, -0.22456632554531097, -0.5545508861541748, 0.43928641080856323, -2.155061960220337, -0.2058391273021698, -2.1148102283477783, -2.162668228149414, -1.4073810577392578, -0.7747349739074707, 1.1483272314071655, 0.21037493646144867, -0.8303462862968445, 1.0736560821533203, -0.2286326140165329, -1.815565586090088, 1.211532711982727, -1.9641242027282715 ]
https://github.com/huggingface/datasets/issues/5209
Implement ability to define splits in metadata section of dataset card
@merveenoyan Do you want different files to be splits or configurations? From [what you specified in `Readme.md`](https://huggingface.co/datasets/inria-soda/tabular-benchmark/commit/fb4575853772c62a20203bdd6cc0202f5db4ce4e) I hypothesize that you want to have 4 **configs** corresponding to directories: `"clf_cat", "clf_num", "reg_cat", "reg_num"`. And inside each config you require to have as many splits as there are `csv` files so if you run ```python load_dataset("inria-soda/tabular-benchmark", "clf_cat", split="compass") ``` you will generate the data only from `compass.csv` file. In this case, running `load_dataset("inria-soda/tabular-benchmark", "clf_cat"`) without split parameter will return `DatasetDict` object with `"KDDCup09_upselling", "cat_compass", "cat_covertype", ... "road_safety"` keys (which values are splits - `Dataset` objects) **or** do you want each file to be a separate config? Like: ```python load_dataset("inria-soda/tabular-benchmark", "clf_cat_compass") # returns DatasetDict with a single "train" split ``` **or** maybe smth completely different? :smile: Anyway, now I have an impression that this is probably rather a matter of automatically inferring configs from repository structure rather than providing parameters in metadata yaml.
### Feature request If you go here: https://huggingface.co/datasets/inria-soda/tabular-benchmark/tree/main you will see bunch of folders that has various CSV files. I’d like dataset viewer to show these files instead of only one dataset like it currently does. (and also people to be able to load them as splits instead of loading through `data_files`) e.g GLUE has various splits on viewer but it’s too overkill to ask people to implement loading script, so it would be better to let them define these in the README file instead. Also pinging @polinaeterna @lhoestq @adrinjalali
437
151
Implement ability to define splits in metadata section of dataset card ### Feature request If you go here: https://huggingface.co/datasets/inria-soda/tabular-benchmark/tree/main you will see bunch of folders that has various CSV files. I’d like dataset viewer to show these files instead of only one dataset like it currently does. (and also people to be able to load them as splits instead of loading through `data_files`) e.g GLUE has various splits on viewer but it’s too overkill to ask people to implement loading script, so it would be better to let them define these in the README file instead. Also pinging @polinaeterna @lhoestq @adrinjalali @merveenoyan Do you want different files to be splits or configurations? From [what you specified in `Readme.md`](https://huggingface.co/datasets/inria-soda/tabular-benchmark/commit/fb4575853772c62a20203bdd6cc0202f5db4ce4e) I hypothesize that you want to have 4 **configs** corresponding to directories: `"clf_cat", "clf_num", "reg_cat", "reg_num"`. And inside each config you require to have as many splits as there are `csv` files so if you run ```python load_dataset("inria-soda/tabular-benchmark", "clf_cat", split="compass") ``` you will generate the data only from `compass.csv` file. In this case, running `load_dataset("inria-soda/tabular-benchmark", "clf_cat"`) without split parameter will return `DatasetDict` object with `"KDDCup09_upselling", "cat_compass", "cat_covertype", ... "road_safety"` keys (which values are splits - `Dataset` objects) **or** do you want each file to be a separate config? Like: ```python load_dataset("inria-soda/tabular-benchmark", "clf_cat_compass") # returns DatasetDict with a single "train" split ``` **or** maybe smth completely different? :smile: Anyway, now I have an impression that this is probably rather a matter of automatically inferring configs from repository structure rather than providing parameters in metadata yaml.
[ -1.1274577379226685, -0.9249616265296936, -0.7130165696144104, 1.5014170408248901, -0.1326085925102234, -1.207730770111084, 0.24863514304161072, -1.0877469778060913, 1.6575603485107422, -0.7514339089393616, 0.3837408423423767, -1.681352972984314, 0.00939095951616764, -0.6765584349632263, -0.738889753818512, -0.8742715716362, -0.4688839912414551, -0.7702948451042175, 0.9681023359298706, 2.437492609024048, 1.2808287143707275, -1.3578227758407593, 2.719771385192871, 0.6336016058921814, -0.177757129073143, -0.9999057650566101, 0.45721742510795593, 0.05538029223680496, -1.184529185295105, -0.4490821361541748, -0.9381538033485413, -0.14524251222610474, -0.5757316946983337, -0.5250001549720764, 0.035912953317165375, 0.4848848283290863, -0.2823793292045593, -0.381364107131958, -0.6281696557998657, -0.719337522983551, 0.553873598575592, -0.43376079201698303, 0.9831576347351074, -0.3669593632221222, 1.810827374458313, -0.6281593441963196, 0.45106783509254456, 0.7600144147872925, 1.308605432510376, 0.2729247510433197, 0.03560277819633484, 0.27430248260498047, 0.38162922859191895, -0.057116277515888214, 0.5284510850906372, 1.2762614488601685, 0.6456046104431152, 0.5658391118049622, 0.7864667773246765, -2.2258663177490234, 1.2970476150512695, -0.9941436648368835, 0.3360750675201416, 1.291050910949707, -0.8889175653457642, 0.3301195204257965, -1.8641070127487183, -0.05397806316614151, 0.5194694995880127, -2.3059613704681396, 0.2987152934074402, -1.2694610357284546, -0.5744442939758301, 0.9880073070526123, 0.307836651802063, -1.198757529258728, 0.22466951608657837, -0.39170223474502563, 0.9223507046699524, 0.3963080048561096, 1.117798089981079, -1.740017056465149, -0.02941669337451458, -0.27657371759414673, 0.15628938376903534, -1.1539844274520874, -1.5603030920028687, 0.5179755091667175, 0.5937095284461975, 0.5204465985298157, -0.191192626953125, 1.0155665874481201, -1.0296579599380493, 0.8157596588134766, -1.0175609588623047, -1.6946638822555542, -1.3766387701034546, -2.1667392253875732, -2.348001003265381, 0.7799015045166016, -0.4811418652534485, -0.5127167105674744, 2.0257935523986816, -0.965189516544342, -1.724229097366333, 1.1573237180709839, 0.35266774892807007, 0.00016636867076158524, 2.329695224761963, 0.1846243143081665, -0.6636543273925781, 0.4721224308013916, -0.7056823968887329, 0.8291352987289429, -0.43172743916511536, 1.3403953313827515, 0.4143781065940857, -1.0721238851547241, 1.5874781608581543, -0.4038263261318207, 0.6061474084854126, -0.6576095819473267, -0.5675987005233765, -0.7079750895500183, 0.35739168524742126, 1.8627533912658691, -0.3107832074165344, 1.5215644836425781, -0.28661781549453735, -1.6476655006408691, -1.6385235786437988, 0.8885883092880249, 0.464109867811203, -0.6979277729988098, 0.03611587733030319, -0.4017096757888794, 0.19880414009094238, -0.04608266055583954, 1.1459497213363647, 1.2363760471343994, 0.7639462351799011, -0.33632978796958923, -0.8171497583389282, 0.12732532620429993, -0.05171092599630356, -0.6642246246337891, -1.769688606262207, -0.3094457685947418, 0.2641851305961609, 0.5341165661811829, -1.1848324537277222, 1.7373405694961548, 0.8842381834983826, 1.9894554615020752, 0.9952611327171326, -0.26754477620124817, 1.5863308906555176, 0.045854032039642334, 1.811482548713684, -0.4887171983718872, 0.5939316749572754, -0.3423624634742737, -1.1150825023651123, 0.8671934008598328, -0.35062673687934875, -2.0397350788116455, -0.7991750836372375, -0.800629734992981, -0.14987017214298248, -0.7261223793029785, 0.9321237802505493, -0.2394164353609085, -1.4027807712554932, 0.19258160889148712, -0.6373648643493652, 0.06316811591386795, -1.2436679601669312, 0.3010783791542053, 0.7025401592254639, -0.758338451385498, 0.05103112757205963, -0.20395351946353912, -1.2872520685195923, -0.4431772828102112, 0.2478226125240326, 1.9187554121017456, -0.7560710310935974, 0.8400253057479858, 1.095903754234314, -0.7824375033378601, 0.06252393126487732, 0.3563414514064789, -0.37030985951423645, 0.7722406387329102, -1.1012861728668213, -0.3425884246826172, 1.1189712285995483, -0.09524723142385483, -0.5924145579338074, 1.417210578918457, 0.7642533183097839, -1.0595908164978027, -0.1760246455669403, -0.18557441234588623, -0.7841210961341858, 0.04492127150297165, -1.516017198562622, -0.11404120922088623, 0.35733532905578613, -1.4688576459884644, -0.46263501048088074, -0.25935450196266174, 1.2413018941879272, -0.17247815430164337, 1.4073735475540161, -0.29269641637802124, -0.16244356334209442, -0.33803656697273254, -0.4973517656326294, 0.1562241017818451, -0.22147676348686218, -0.6678861379623413, 0.20193304121494293, -0.7576302289962769, 0.3259277641773224, 1.5274076461791992, 0.28834688663482666, 0.025957675650715828, 0.4935644865036011, 1.1262322664260864, 0.30541372299194336, -0.02989978902041912, -0.8597880601882935, -1.5140248537063599, 1.9708847999572754, -1.4818748235702515, 1.9360162019729614, 0.7811912298202515, 0.0205517765134573, -1.7535030841827393, -1.8897790908813477, 1.401145100593567, 1.200032353401184, 2.4637765884399414, 0.5172795057296753, 0.393682062625885, -0.8293286561965942, -0.6763935685157776, 0.4342377781867981, -1.0949674844741821, -0.6572298407554626, 0.17027579247951508, 2.369689702987671, 1.774990200996399, -0.5650965571403503, -0.2412348985671997, -0.993903398513794, 1.3964569568634033, -0.19083569943904877, 0.16311246156692505, 2.071160078048706, -0.2603698670864105, -1.0654264688491821, 1.3142222166061401, -2.2852797508239746, 0.11678190529346466, 1.9338867664337158, 0.23681417107582092, 0.0894845649600029, -1.318688154220581, -0.6022300124168396, -0.2815702259540558, -0.4421527683734894, -1.2676345109939575, 0.5303323864936829, -0.21421808004379272, -0.8155197501182556, -1.4401519298553467, 0.16838747262954712, -1.1545424461364746, -1.6166291236877441, 0.32295575737953186, 1.8197976350784302, 2.022120714187622, -0.8817045092582703, 1.4823960065841675, -0.3417701721191406, 0.13238732516765594, 1.2211178541183472, 1.2446321249008179, 3.153817653656006, 1.8260979652404785, -1.2470823526382446, 0.6571133136749268, -0.202352374792099, -0.5067094564437866, 1.186819076538086, -1.1646878719329834, 1.2744295597076416, -0.19930459558963776, -1.1289063692092896, -1.1873608827590942, 0.9655036926269531, 0.5023991465568542, 0.09620177000761032, -0.5107579231262207, 1.0903793573379517, 0.19970253109931946, 1.3591539859771729, 0.596794068813324, -0.36056920886039734, 0.6939457654953003, -0.4211108982563019, -0.5077189207077026, 1.5575355291366577, 0.20995645225048065, -1.4552693367004395, -2.2266721725463867, -0.13002964854240417, -0.8964965343475342, 0.0035305237397551537, -0.5275615453720093, -1.0062867403030396, 1.6452324390411377, 0.3598824143409729, -1.3016254901885986, -0.2425403892993927, -0.33436691761016846, -0.5540100336074829, 2.6657211780548096, -1.3798695802688599, -0.1932731717824936, -0.9675509929656982, -0.6513457298278809, 1.687060832977295, -1.1543304920196533, -0.24995487928390503, -1.0245401859283447, -0.47246789932250977, -1.297602891921997, -0.5841265320777893, 0.09009507298469543, -0.8870967030525208, 0.7988617420196533, 0.19475635886192322, -1.2100874185562134, -0.35431408882141113, -0.8400808572769165, 0.8763253688812256, -0.17735448479652405, 0.20219352841377258, 1.8660392761230469, 0.3941040635108948, -0.3887020945549011, 0.6907852292060852, 1.168873906135559, 0.5439848899841309, -0.5989900231361389, 0.21662701666355133, -0.7490690350532532, 0.2547907829284668, -1.3628733158111572, 0.22203949093818665, -2.812610387802124, 0.643310010433197, -0.10456467419862747, -0.10728563368320465, 0.06543180346488953, -1.3809422254562378, 1.075191855430603, 2.6209144592285156, -1.1578636169433594, 0.40172451734542847, 0.35328128933906555, 1.1816235780715942, -1.5664197206497192, 0.24425071477890015, -0.44170042872428894, 2.0311875343322754, 0.1141396313905716, 1.213765263557434, -0.5319995880126953, -2.2471821308135986, 0.633935272693634, -1.2928844690322876, -1.1981960535049438, 0.797469437122345, -0.9302676320075989, 0.06649810075759888, -1.4046865701675415, -0.2948720455169678, -0.8834622502326965, -1.198575496673584, 0.7313684821128845, 0.13991713523864746, 0.39794018864631653, -0.6173223257064819, 0.33855879306793213, -2.120121955871582, -1.422184705734253, -0.3160872459411621, -0.9155458807945251, 0.4950355887413025, -0.3090980648994446, 0.6910586953163147, -0.22607864439487457, 0.0021931827068328857, 0.38451117277145386, 1.435322642326355, 3.3287742137908936, 0.1917230784893036, 0.3288233280181885, -0.2062019407749176, -0.997586727142334, 1.4792569875717163, 0.9195125102996826, -0.08968901634216309, -0.5612737536430359, -1.0928776264190674, 1.2326111793518066, 1.980527639389038, 1.068992257118225, -0.008782867342233658, -0.8142557740211487, -0.7484262585639954, -0.007663073483854532, 0.12245362997055054, 0.41266587376594543, 0.9276261329650879, 0.006877001374959946, 0.04471993446350098, 1.387881875038147, 1.2129809856414795, -0.41321006417274475, 0.3382441997528076, -0.8685444593429565, -0.42315617203712463, 0.5562920570373535, 0.26628413796424866, 0.061028286814689636, 0.322231650352478, -1.0734411478042603, -0.2715451121330261, -0.3449229598045349, -0.9005454182624817, -0.7949917316436768, -0.48799461126327515, -0.3105058968067169, 1.6659058332443237, 0.0972023531794548, -0.4361971318721771, 0.013368386775255203, -0.7393609881401062, -0.124547578394413, -1.0884419679641724, 0.21877306699752808, -0.10192064195871353, -0.17516452074050903, -0.179570272564888, 1.7632877826690674, -0.9850447177886963, -2.070890426635742, 0.3025015890598297, 0.2337728887796402, -0.38805311918258667, 0.14047802984714508, 1.6672053337097168, 0.5151694416999817, 1.4900938272476196, 1.3098571300506592, 1.0644217729568481, -0.6441773176193237, -1.2235817909240723, 0.6691631078720093, 1.0290088653564453, -1.3328046798706055, 0.7473189830780029, -0.00017275474965572357, -0.48802638053894043, 0.6561233997344971, 1.2417241334915161, 0.4295222759246826, -1.9896959066390991, 0.781656801700592, -0.9122488498687744, 0.6925721168518066, 0.6881980299949646, 0.7705455422401428, 0.2479844093322754, 0.8178015351295471, -1.231520414352417, -1.2072234153747559, -0.7083303332328796, -0.6390607357025146, 1.9658653736114502, -0.20143024623394012, 0.5886154174804688, -0.18584217131137848, -1.346253514289856, -0.04971786588430405, 0.8272990584373474, 0.37143656611442566, -0.4606212377548218, 0.743257999420166, -0.6367261409759521, -0.9008851647377014, -1.381995439529419, -0.36589115858078003, -1.1263045072555542, -0.9482528567314148, 0.9816635847091675, 0.8349590301513672, 0.3609273135662079, 1.946997046470642, 0.7440962195396423, 0.3645765483379364, -2.6073296070098877, 0.9395049214363098, 0.3620319068431854, -0.11694838106632233, 0.8953332901000977, 0.41179388761520386, 1.0461894273757935, -0.05878625810146332, 0.5522404909133911, -2.4275927543640137, 2.2656872272491455, -0.1716829091310501, 0.7595067620277405, -0.01776544749736786, -0.2571030259132385, 1.098279595375061, 0.5366148352622986, 0.5272915363311768, -1.1397677659988403, 0.5728906393051147, -0.5765239000320435, 1.1465944051742554, 0.9041769504547119, -0.8322833776473999, 0.0471978560090065, 1.3113845586776733, 0.4535987973213196, -0.4510669708251953, -0.9519467353820801, -0.9018583297729492, 0.9461079239845276, 1.7554285526275635, -0.10737138986587524, 0.04028848558664322, 0.9060407876968384, 0.676486611366272, -1.2877519130706787, 0.006798354908823967, -0.7816950678825378, -0.8226587772369385, 1.748388409614563, 2.0481128692626953, -0.2076633870601654, -0.2318955659866333, -0.8056702613830566, -1.1773111820220947, 0.8580747842788696, 0.05907681584358215, 0.11184359341859818, 0.6754555702209473, -0.6722793579101562, 1.1736509799957275, 0.833106279373169, 0.8781769275665283, 0.20359770953655243, 0.3648708164691925, 0.48056384921073914, -0.3617335557937622, -1.0946985483169556, -0.2754906415939331, -1.1052439212799072, -2.621065139770508, 0.565223753452301, -0.1984490156173706, -1.4003021717071533, 0.010024206712841988, -0.9966497421264648, 0.8734651207923889, -0.5790883898735046, -1.1309232711791992, -1.581079363822937, 0.29319077730178833, -0.07965598255395889, 0.9717893004417419, -1.5632193088531494, -0.13186641037464142, 1.105116367340088, 0.9064496159553528, -0.6551769375801086, 0.8774791359901428, 0.19795411825180054, 0.9998398423194885, 0.8798977136611938, -0.3661024868488312, 0.526394784450531, 0.055260807275772095, -1.315882682800293, 0.37633493542671204, 1.2383054494857788, 0.17916162312030792, 1.3664755821228027, -0.479706734418869, 0.01572611555457115, 0.39681023359298706, -0.6096415519714355, -0.4672657251358032, -0.5540653467178345, 0.6190833449363708, 0.04587589204311371, -0.9962478280067444, 0.014224022626876831, -0.052279189229011536, -0.2569933235645294, 0.23926058411598206, -1.4764043092727661, -0.16615629196166992, -0.3733106255531311, -0.5386107563972473, -1.2222411632537842, -0.06618862599134445, 1.3767341375350952, -0.6885154843330383, -0.22050459682941437, 0.5298694968223572, 0.32060563564300537, 0.5186169147491455, 0.46904394030570984, -0.7743306159973145, -0.3006797730922699, -0.29566434025764465, -0.35200297832489014, 0.2769802212715149, 1.3824946880340576, -0.09299610555171967, -1.016850471496582, 0.7087636590003967, -0.4117529094219208, 0.09017886221408844, 1.9778510332107544, 0.13925662636756897, -0.8063783645629883, 0.30640140175819397, -0.7428631782531738, 1.838758945465088, 1.8490984439849854, 1.3266810178756714, -0.06361737847328186, -0.9555115103721619, 0.6317170262336731, -0.387073814868927, -0.39790430665016174, 0.9265535473823547, 0.33101874589920044, -0.19010771811008453, -1.5101945400238037, 0.6829141974449158, 1.3880549669265747, -0.8326191306114197, -0.8336589336395264, 0.0830780491232872, -0.8820852041244507, 1.1200509071350098, 0.66553795337677, 0.4090764820575714, 0.2001822590827942, 1.6180089712142944, 0.784068763256073, -0.40955859422683716, 0.5443984866142273, 0.578284502029419, -0.15682099759578705, -2.138011932373047, -1.2109514474868774, 0.33088821172714233, -0.5007785558700562, -1.5848835706710815, 1.4495060443878174, -1.1288745403289795, -1.0365046262741089, 0.4891497790813446, 0.04876764863729477, 1.4340044260025024, 0.3600916564464569, 1.5460400581359863, 2.1113765239715576, 0.8791571259498596, 0.4129379689693451, 1.3095088005065918, -0.1894691437482834, -0.4756588339805603, 1.9005440473556519, -0.5213025808334351, 0.46152588725090027, 1.0764967203140259, -0.3247230052947998, -1.078514575958252, -0.8132644295692444, -1.214011311531067, -0.7853478789329529, 1.196311593055725, 0.035200171172618866, -1.0912680625915527, 0.31727054715156555, 1.6875205039978027, 0.12448661029338837, -0.4122704565525055, 0.6911472082138062, 0.35367587208747864, -0.765477180480957, -0.05187127739191055, -0.9143511056900024, 0.5724731683731079, -0.18487028777599335, -0.3203481137752533, 0.30941641330718994, 0.5641159415245056, 1.247729778289795, -0.06248943507671356, 0.02619214914739132, 1.1170463562011719, -1.410276174545288, 1.5161083936691284, -0.7057207226753235, 0.2701498568058014, -2.4009928703308105, 1.4569441080093384, -0.7743563652038574, 1.8681668043136597, -2.5817649364471436, 0.4315851330757141, -0.503495454788208, -0.48943471908569336, 0.2869492769241333, -0.3963668942451477, 0.13537123799324036, -0.09709610790014267, -1.1629468202590942, -0.06664179265499115, -0.6683171987533569, 0.657782793045044, 1.1217396259307861, 1.436724066734314, -1.0987342596054077, -0.3630012571811676, -1.7488914728164673, -0.08585666865110397, -0.6794082522392273, 0.2867226302623749, -2.018617630004883, -0.24744141101837158, -1.8730522394180298, -2.2909598350524902, -1.3825371265411377, -0.8173149824142456, 1.1309599876403809, 0.1571652591228485, -0.9283202886581421, 1.1360927820205688, -0.4129374325275421, -1.8819825649261475, 1.1774611473083496, -2.210237979888916 ]
https://github.com/huggingface/datasets/issues/5209
Implement ability to define splits in metadata section of dataset card
@polinaeterna I want the latter where you can think of every CSV file as a config, like MNLI from GLUE.
### Feature request If you go here: https://huggingface.co/datasets/inria-soda/tabular-benchmark/tree/main you will see bunch of folders that has various CSV files. I’d like dataset viewer to show these files instead of only one dataset like it currently does. (and also people to be able to load them as splits instead of loading through `data_files`) e.g GLUE has various splits on viewer but it’s too overkill to ask people to implement loading script, so it would be better to let them define these in the README file instead. Also pinging @polinaeterna @lhoestq @adrinjalali
437
20
Implement ability to define splits in metadata section of dataset card ### Feature request If you go here: https://huggingface.co/datasets/inria-soda/tabular-benchmark/tree/main you will see bunch of folders that has various CSV files. I’d like dataset viewer to show these files instead of only one dataset like it currently does. (and also people to be able to load them as splits instead of loading through `data_files`) e.g GLUE has various splits on viewer but it’s too overkill to ask people to implement loading script, so it would be better to let them define these in the README file instead. Also pinging @polinaeterna @lhoestq @adrinjalali @polinaeterna I want the latter where you can think of every CSV file as a config, like MNLI from GLUE.
[ -1.186791181564331, -0.9638875126838684, -0.9183132648468018, 1.5415327548980713, -0.13168396055698395, -1.2302013635635376, 0.14252440631389618, -1.0041964054107666, 1.6586488485336304, -0.8472521901130676, 0.4266990125179291, -1.6545112133026123, 0.13983406126499176, -0.6501156091690063, -0.7391031384468079, -0.9806198477745056, -0.4152507483959198, -0.7246168255805969, 1.060955286026001, 2.4663197994232178, 1.1677910089492798, -1.3350762128829956, 2.788478136062622, 0.6339418292045593, -0.16346284747123718, -1.1351161003112793, 0.6009123921394348, 0.13737516105175018, -1.181808352470398, -0.4282577335834503, -0.9654108881950378, -0.07745540142059326, -0.5786911845207214, -0.4676748216152191, 0.08514730632305145, 0.3562376797199249, -0.13891375064849854, -0.33933520317077637, -0.5511593222618103, -0.7221871018409729, 0.5042998194694519, -0.38939547538757324, 0.9506027698516846, -0.3501160144805908, 1.853690505027771, -0.5583289265632629, 0.29564616084098816, 0.7322956919670105, 1.4067491292953491, 0.19235201179981232, -0.016442567110061646, 0.16958940029144287, 0.3655523359775543, -0.02805667743086815, 0.4233492314815521, 1.1662800312042236, 0.5615261197090149, 0.588839590549469, 0.6835530400276184, -2.167132616043091, 1.372541069984436, -0.9143342971801758, 0.3588820993900299, 1.2733216285705566, -1.015581727027893, 0.36675825715065, -1.7844195365905762, -0.16471537947654724, 0.4834682047367096, -2.3862688541412354, 0.16884024441242218, -1.152448296546936, -0.5557677745819092, 0.9331015944480896, 0.2996361255645752, -1.2644425630569458, 0.1584518849849701, -0.5111290216445923, 0.9612194895744324, 0.5476822853088379, 1.1264808177947998, -1.6768220663070679, 0.14528626203536987, -0.27358031272888184, 0.04315453767776489, -1.3177706003189087, -1.4837857484817505, 0.4694101810455322, 0.6715177893638611, 0.5157673358917236, -0.04391409084200859, 0.8566826581954956, -0.9783356785774231, 0.8839238882064819, -0.8701412677764893, -1.6423466205596924, -1.4030823707580566, -2.2274227142333984, -2.378408908843994, 0.7892512083053589, -0.43443015217781067, -0.6529468297958374, 1.9869493246078491, -0.9852849245071411, -1.829169750213623, 1.2544430494308472, 0.20023800432682037, -0.007784750312566757, 2.4640393257141113, 0.16288892924785614, -0.5689499974250793, 0.41323235630989075, -0.695218026638031, 0.936305582523346, -0.4394175112247467, 1.47480046749115, 0.4652508795261383, -1.0312097072601318, 1.6607595682144165, -0.44991183280944824, 0.4768197536468506, -0.647765576839447, -0.5665937066078186, -0.8507476449012756, 0.3413268029689789, 1.9025099277496338, -0.29685908555984497, 1.5737920999526978, -0.38252440094947815, -1.648848295211792, -1.6182901859283447, 0.8669646978378296, 0.49366113543510437, -0.7451049089431763, 0.09173546731472015, -0.4047725200653076, 0.15427786111831665, 0.09077032655477524, 1.1065948009490967, 1.1628774404525757, 0.6651532053947449, -0.25515466928482056, -0.7771404385566711, 0.20856544375419617, -0.06948041170835495, -0.6491818428039551, -1.8600153923034668, -0.2552601993083954, 0.17439262568950653, 0.6321452260017395, -1.2001073360443115, 1.627730369567871, 0.9362867474555969, 2.0195164680480957, 1.0309933423995972, -0.18370471894741058, 1.5724971294403076, -0.14845514297485352, 1.824357032775879, -0.4339829683303833, 0.636067271232605, -0.403964102268219, -1.1614446640014648, 0.7440612316131592, -0.41062667965888977, -2.0572750568389893, -0.8725491166114807, -0.8778913021087646, -0.11368153244256973, -0.7289385199546814, 1.0938979387283325, -0.3610319197177887, -1.3598014116287231, 0.20451994240283966, -0.6503108143806458, 0.07971349358558655, -1.283351182937622, 0.2909333407878876, 0.7434161901473999, -0.7606646418571472, 0.02596288174390793, -0.2712671160697937, -1.210439682006836, -0.4707721173763275, 0.29672420024871826, 1.9056100845336914, -0.8617600202560425, 0.8773898482322693, 0.9724819660186768, -0.7354174256324768, 0.039576299488544464, 0.33104103803634644, -0.34506914019584656, 0.7950876951217651, -1.0295706987380981, -0.32687386870384216, 1.1223807334899902, -0.1357264518737793, -0.6543885469436646, 1.415713906288147, 0.8079555630683899, -0.9897319674491882, -0.14607678353786469, -0.1740148514509201, -0.8067570924758911, -0.07563747465610504, -1.6585582494735718, -0.15708398818969727, 0.2273494452238083, -1.471859097480774, -0.3709871470928192, -0.28349724411964417, 1.192611575126648, -0.05517749488353729, 1.3866511583328247, -0.2804775536060333, -0.2106904536485672, -0.36986789107322693, -0.5168278813362122, 0.24479125440120697, -0.1558806300163269, -0.6186677813529968, 0.2903710901737213, -0.7970178127288818, 0.34248197078704834, 1.5820822715759277, 0.36829695105552673, 0.14478395879268646, 0.5786632895469666, 1.0465304851531982, 0.3156050145626068, -0.1049698144197464, -0.8452031016349792, -1.586203694343567, 2.058480739593506, -1.4928398132324219, 1.9475603103637695, 0.7942721843719482, -0.06779540330171585, -1.7586989402770996, -1.8166218996047974, 1.4519236087799072, 1.2164164781570435, 2.339367628097534, 0.5872167348861694, 0.26024311780929565, -0.8418200016021729, -0.6271077990531921, 0.295508474111557, -1.1297533512115479, -0.7753441333770752, 0.09174226224422455, 2.3325612545013428, 1.7807356119155884, -0.5513675212860107, -0.15317553281784058, -1.104519248008728, 1.2920843362808228, -0.0819021463394165, 0.17590685188770294, 2.0207457542419434, -0.27248236536979675, -1.0732969045639038, 1.2025090456008911, -2.2780447006225586, 0.10066553950309753, 1.8724584579467773, 0.2655499279499054, 0.05768711492419243, -1.4853986501693726, -0.6108511686325073, -0.25327256321907043, -0.35196366906166077, -1.2875332832336426, 0.6274881362915039, -0.24899499118328094, -0.7915084362030029, -1.4628007411956787, 0.18528537452220917, -1.1171766519546509, -1.6526316404342651, 0.37110036611557007, 1.74600350856781, 2.122081995010376, -0.8195493817329407, 1.485767126083374, -0.21865631639957428, 0.15394902229309082, 1.2849817276000977, 1.1459925174713135, 3.1479430198669434, 1.8708051443099976, -1.2467955350875854, 0.6511940956115723, -0.08477552980184555, -0.4936756491661072, 1.155788540840149, -1.0766488313674927, 1.3149912357330322, -0.19569596648216248, -1.198616623878479, -1.280935525894165, 0.9808456897735596, 0.48313266038894653, 0.09717550873756409, -0.4911671578884125, 1.2601053714752197, 0.09339334070682526, 1.3385181427001953, 0.5079493522644043, -0.3357681334018707, 0.5598134398460388, -0.4238227605819702, -0.5914627313613892, 1.6532402038574219, 0.13440430164337158, -1.6247222423553467, -2.219149351119995, -0.13813231885433197, -0.779930055141449, -0.0666777640581131, -0.5096761584281921, -1.0338085889816284, 1.586580514907837, 0.3932855725288391, -1.2802482843399048, -0.32406678795814514, -0.4340384006500244, -0.6580986976623535, 2.6469666957855225, -1.4702938795089722, -0.2601052224636078, -0.9048291444778442, -0.5557235479354858, 1.6398439407348633, -1.2067464590072632, -0.1976192742586136, -0.9779298901557922, -0.5648221969604492, -1.364039421081543, -0.587060272693634, 0.06300299614667892, -0.9674108028411865, 0.7421403527259827, 0.14742045104503632, -1.1425095796585083, -0.3214039206504822, -0.8520712852478027, 0.8539334535598755, -0.1273665726184845, 0.40698888897895813, 1.833099603652954, 0.40863358974456787, -0.47541576623916626, 0.737995445728302, 1.1502219438552856, 0.6070407629013062, -0.6318131685256958, 0.23738449811935425, -0.6788761615753174, 0.25526487827301025, -1.2994290590286255, 0.2915952205657959, -2.8655991554260254, 0.6570647358894348, -0.13580334186553955, -0.23564524948596954, 0.06589090079069138, -1.3364061117172241, 1.1460884809494019, 2.5841524600982666, -1.2228084802627563, 0.41898444294929504, 0.2922929525375366, 1.1767572164535522, -1.4612129926681519, 0.330974280834198, -0.37255555391311646, 2.051380157470703, 0.18960566818714142, 1.2232874631881714, -0.5490638017654419, -2.160489559173584, 0.7446786165237427, -1.286885142326355, -1.08119535446167, 0.806878924369812, -0.909054160118103, -0.04398106783628464, -1.3525573015213013, -0.2438119649887085, -0.8909309506416321, -1.2803984880447388, 0.7787041068077087, 0.2917214035987854, 0.4310556650161743, -0.5577017068862915, 0.27064207196235657, -2.1830430030822754, -1.389375925064087, -0.2536007761955261, -0.9676550030708313, 0.3826179802417755, -0.33105143904685974, 0.5920175909996033, -0.25640740990638733, 0.034324534237384796, 0.35134196281433105, 1.3939788341522217, 3.3913826942443848, 0.23851698637008667, 0.5227457284927368, -0.1753210872411728, -0.9450101852416992, 1.5657193660736084, 0.9926508665084839, -0.08564618229866028, -0.5047410130500793, -1.0099973678588867, 1.2770395278930664, 1.9321401119232178, 1.1020787954330444, 0.034084953367710114, -0.7351113557815552, -0.6624162793159485, 0.0059463223442435265, 0.22039107978343964, 0.4787604510784149, 0.949220597743988, -0.10878346860408783, 0.08480799943208694, 1.449681282043457, 1.279771089553833, -0.5422796607017517, 0.5202264785766602, -0.866938054561615, -0.3301789164543152, 0.5079657435417175, 0.25558242201805115, -0.019271178171038628, 0.3230638802051544, -1.0779385566711426, -0.271675169467926, -0.26462188363075256, -1.0337904691696167, -0.7597249150276184, -0.3761795461177826, -0.3915063738822937, 1.6279491186141968, 0.12012876570224762, -0.38690295815467834, -0.05398020148277283, -0.733040988445282, -0.1760302186012268, -1.0591892004013062, 0.1545085906982422, -0.04248133674263954, -0.17200806736946106, -0.15501587092876434, 1.9485061168670654, -1.1095794439315796, -2.300474166870117, 0.3803587257862091, 0.17130567133426666, -0.4317553639411926, 0.20316794514656067, 1.5585235357284546, 0.4055444002151489, 1.4381388425827026, 1.3433083295822144, 1.0688613653182983, -0.661020815372467, -1.2512701749801636, 0.7184788584709167, 0.9605151414871216, -1.425493597984314, 0.7511436343193054, -0.12080468237400055, -0.4989473223686218, 0.7578391432762146, 1.2452011108398438, 0.4646081328392029, -1.9955096244812012, 0.7735084295272827, -0.8710424304008484, 0.7090402841567993, 0.697542667388916, 0.8161499500274658, 0.32414180040359497, 0.8392072319984436, -1.255898356437683, -1.1978942155838013, -0.8202886581420898, -0.5888569355010986, 1.8606271743774414, -0.08508853614330292, 0.5864633917808533, -0.03094276413321495, -1.3123425245285034, -0.06314260512590408, 0.7219249606132507, 0.3219285309314728, -0.29247331619262695, 0.8285256624221802, -0.7237832546234131, -0.9942381978034973, -1.4487437009811401, -0.42090731859207153, -1.0237905979156494, -0.9015661478042603, 1.0588972568511963, 0.7641722559928894, 0.21276132762432098, 1.9586812257766724, 0.5645434260368347, 0.33764129877090454, -2.6742589473724365, 0.965887725353241, 0.24555902183055878, 0.06968767195940018, 0.8379029035568237, 0.39056235551834106, 1.127892255783081, -0.026749402284622192, 0.4520971179008484, -2.4082677364349365, 2.2619740962982178, -0.2197602093219757, 0.7658171653747559, -0.03735513240098953, -0.1388384848833084, 1.1418920755386353, 0.639758288860321, 0.5820006132125854, -1.127662181854248, 0.6804654598236084, -0.6045993566513062, 1.2227675914764404, 0.9845502376556396, -0.7624801993370056, 0.04661210998892784, 1.3134160041809082, 0.46793803572654724, -0.3699333667755127, -0.8727266788482666, -0.8220088481903076, 0.8706838488578796, 1.7585713863372803, -0.032121337950229645, 0.039144378155469894, 0.7599809765815735, 0.5801252126693726, -1.3154451847076416, -0.006077839992940426, -0.7724699974060059, -0.7734009623527527, 1.6681432723999023, 1.9795562028884888, -0.20069919526576996, -0.1253751814365387, -0.7731231451034546, -1.1534465551376343, 0.8332377672195435, -0.04508247599005699, 0.1561642289161682, 0.6761762499809265, -0.6439619064331055, 1.1747560501098633, 0.9074246883392334, 0.8387100100517273, 0.1457051783800125, 0.3267713487148285, 0.3871498703956604, -0.1888500452041626, -1.0491207838058472, -0.3342861831188202, -1.200259804725647, -2.607670545578003, 0.4939521849155426, -0.4049960672855377, -1.3903602361679077, -0.007367891259491444, -1.0370056629180908, 0.8625817894935608, -0.5123705863952637, -1.0418411493301392, -1.4983127117156982, 0.23268263041973114, -0.22173240780830383, 0.9091252684593201, -1.5000101327896118, -0.07123909890651703, 1.2041027545928955, 0.9078665971755981, -0.6787310242652893, 1.0242222547531128, 0.1904701292514801, 1.0239118337631226, 0.8000907897949219, -0.4047783613204956, 0.43525540828704834, 0.15579959750175476, -1.2487434148788452, 0.3536512851715088, 1.0648690462112427, 0.1286870539188385, 1.3519502878189087, -0.5183215737342834, -0.07299227267503738, 0.43541690707206726, -0.6460431218147278, -0.4933360815048218, -0.5890465378761292, 0.7047208547592163, 0.006082131527364254, -0.9103125929832458, 0.10966163873672485, -0.15432487428188324, -0.2844570279121399, 0.31085601449012756, -1.626253604888916, -0.30368244647979736, -0.39842990040779114, -0.5080708265304565, -1.3377430438995361, 0.04971747472882271, 1.4321388006210327, -0.7368433475494385, -0.2650822699069977, 0.49623891711235046, 0.4456539750099182, 0.48169374465942383, 0.5856038331985474, -0.75083327293396, -0.3283955752849579, -0.3172471523284912, -0.169044628739357, 0.27296197414398193, 1.3257373571395874, -0.16321240365505219, -1.0826503038406372, 0.7498807311058044, -0.4093703627586365, 0.10324820131063461, 2.0291965007781982, 0.12232083082199097, -0.9032341241836548, 0.30297061800956726, -0.6769420504570007, 1.9019041061401367, 1.7353949546813965, 1.3418114185333252, -0.05242631956934929, -0.865082323551178, 0.6487521529197693, -0.15931914746761322, -0.27000513672828674, 0.8645126819610596, 0.5123100876808167, -0.22703249752521515, -1.5297833681106567, 0.5567873120307922, 1.2905983924865723, -0.7727525234222412, -0.823617696762085, 0.029174726456403732, -0.8732526898384094, 1.0649148225784302, 0.76820307970047, 0.524612307548523, 0.16643184423446655, 1.5845859050750732, 0.7121675610542297, -0.5116046667098999, 0.4851997196674347, 0.5012064576148987, -0.12983429431915283, -2.1042277812957764, -1.0259764194488525, 0.27719083428382874, -0.42567646503448486, -1.5212717056274414, 1.341133713722229, -1.1361603736877441, -0.8351406455039978, 0.5304193496704102, 0.0466814823448658, 1.4583523273468018, 0.2665565609931946, 1.5634031295776367, 2.0731163024902344, 0.9383234977722168, 0.3127160668373108, 1.3871721029281616, -0.22053173184394836, -0.45426544547080994, 1.8252214193344116, -0.4703415632247925, 0.5145850777626038, 1.0820115804672241, -0.3640514612197876, -0.9460119009017944, -0.7764167189598083, -1.0731695890426636, -0.6820003986358643, 1.1794565916061401, 0.16793933510780334, -1.15351402759552, 0.16263805329799652, 1.5520191192626953, 0.14074468612670898, -0.2887726426124573, 0.5505943298339844, 0.40936535596847534, -0.770877480506897, -0.08393774181604385, -0.9607091546058655, 0.5440382361412048, -0.2771233320236206, -0.402731329202652, 0.37190431356430054, 0.4579138457775116, 1.0704785585403442, -0.06330092996358871, 0.10947853326797485, 1.2798361778259277, -1.3152329921722412, 1.396228551864624, -0.5813526511192322, 0.1712903380393982, -2.3984925746917725, 1.4872761964797974, -0.737562894821167, 1.8588355779647827, -2.6083812713623047, 0.41272327303886414, -0.6624407172203064, -0.43863022327423096, 0.38725823163986206, -0.4058762788772583, 0.11184953153133392, -0.19045205414295197, -1.0845516920089722, -0.11169110983610153, -0.6819003820419312, 0.5199205279350281, 1.2402191162109375, 1.2355833053588867, -1.0026882886886597, -0.3208881616592407, -1.7279876470565796, -0.1731974482536316, -0.6988046765327454, 0.3363892734050751, -2.1260359287261963, -0.27031761407852173, -1.846066951751709, -2.3014330863952637, -1.3837240934371948, -0.7934468388557434, 1.2243998050689697, 0.2289639562368393, -0.8966341614723206, 1.1090725660324097, -0.3361312448978424, -1.7563438415527344, 1.0929049253463745, -2.161426067352295 ]
https://github.com/huggingface/datasets/issues/5209
Implement ability to define splits in metadata section of dataset card
@merveenoyan @lhoestq I see two solutions to this case. 1. Parse configurations automatically from directories names. That is, if you have data structure like: ``` tabular-benchmark └─clf_cat_compass └─compass.csv └─clf_cat_cat_covertype └─covertype.csv ... └─reg_cat_house_sales └─house_sales.csv ``` you'll get "clf_cat_compass", "clf_cat_cat_covertype", ... "reg_cat_house_sales" configurations that would contain **only files from corresponding directories**. **\+** this is a requested change and needed in general and would solve other problems, see https://github.com/huggingface/datasets/issues/4578, would also help with https://github.com/huggingface/datasets/pull/5213 which I'm working on currently **\+** would allow users to do just `load_dataset(“inria-soda/tabular-benchmark”, “clf_cat_compass”)`, no `data_files` param required **\-** in this specific case it would require restructuring of the data - putting each file in a directory named as a config name (to me personally it doesn't seem to be a big deal) 2. More or less what we discussed before - add support for manually specifying parameters in the metadata. We can add new metadata yaml field (say, `"custom_configs_info"`), so that we can provide smth like: ```yaml --- ... dataset_info: ... custom_configs_info: - config_name: reg_cat_house_sales data_files: - reg_cat/house_sales.csv - config_name: clf_cat_compass data_files: - clf_cat/compass.csv ... --- ``` **\+** Would be useful not only for tabular data and not only for `data_files` parameter - any packaged dataset’s viewer can be customized to use specific, non-default parameters. @merveenoyan do you maybe have any other examples/use cases in mind where you want to provide any specific parameters to the viewer? **\-** I'm not sure here but assume that it might require changes in interaction with the viewer on the hub side - to parse these configurations, as they not default configurations (not in `BUILDER_CONFIGS` list). cc @severo But probably this can be solved on the `datasets` side too. Overall, I would start from implementing the first solution since it's related to what I'm doing now and is super useful for `datasets` in general. And then if we agree that having more flexibility in providing parameters to the viewer is required, I can implement the second one. Let me know what you think :)
### Feature request If you go here: https://huggingface.co/datasets/inria-soda/tabular-benchmark/tree/main you will see bunch of folders that has various CSV files. I’d like dataset viewer to show these files instead of only one dataset like it currently does. (and also people to be able to load them as splits instead of loading through `data_files`) e.g GLUE has various splits on viewer but it’s too overkill to ask people to implement loading script, so it would be better to let them define these in the README file instead. Also pinging @polinaeterna @lhoestq @adrinjalali
437
332
Implement ability to define splits in metadata section of dataset card ### Feature request If you go here: https://huggingface.co/datasets/inria-soda/tabular-benchmark/tree/main you will see bunch of folders that has various CSV files. I’d like dataset viewer to show these files instead of only one dataset like it currently does. (and also people to be able to load them as splits instead of loading through `data_files`) e.g GLUE has various splits on viewer but it’s too overkill to ask people to implement loading script, so it would be better to let them define these in the README file instead. Also pinging @polinaeterna @lhoestq @adrinjalali @merveenoyan @lhoestq I see two solutions to this case. 1. Parse configurations automatically from directories names. That is, if you have data structure like: ``` tabular-benchmark └─clf_cat_compass └─compass.csv └─clf_cat_cat_covertype └─covertype.csv ... └─reg_cat_house_sales └─house_sales.csv ``` you'll get "clf_cat_compass", "clf_cat_cat_covertype", ... "reg_cat_house_sales" configurations that would contain **only files from corresponding directories**. **\+** this is a requested change and needed in general and would solve other problems, see https://github.com/huggingface/datasets/issues/4578, would also help with https://github.com/huggingface/datasets/pull/5213 which I'm working on currently **\+** would allow users to do just `load_dataset(“inria-soda/tabular-benchmark”, “clf_cat_compass”)`, no `data_files` param required **\-** in this specific case it would require restructuring of the data - putting each file in a directory named as a config name (to me personally it doesn't seem to be a big deal) 2. More or less what we discussed before - add support for manually specifying parameters in the metadata. We can add new metadata yaml field (say, `"custom_configs_info"`), so that we can provide smth like: ```yaml --- ... dataset_info: ... custom_configs_info: - config_name: reg_cat_house_sales data_files: - reg_cat/house_sales.csv - config_name: clf_cat_compass data_files: - clf_cat/compass.csv ... --- ``` **\+** Would be useful not only for tabular data and not only for `data_files` parameter - any packaged dataset’s viewer can be customized to use specific, non-default parameters. @merveenoyan do you maybe have any other examples/use cases in mind where you want to provide any specific parameters to the viewer? **\-** I'm not sure here but assume that it might require changes in interaction with the viewer on the hub side - to parse these configurations, as they not default configurations (not in `BUILDER_CONFIGS` list). cc @severo But probably this can be solved on the `datasets` side too. Overall, I would start from implementing the first solution since it's related to what I'm doing now and is super useful for `datasets` in general. And then if we agree that having more flexibility in providing parameters to the viewer is required, I can implement the second one. Let me know what you think :)
[ -1.1987993717193604, -1.0131442546844482, -0.6616778373718262, 1.5056648254394531, -0.1159435287117958, -1.285260558128357, 0.25341281294822693, -1.0271482467651367, 1.6325511932373047, -0.766135573387146, 0.3584505021572113, -1.6633027791976929, 0.05637441202998161, -0.6300699710845947, -0.7541787028312683, -0.7941391468048096, -0.4494222402572632, -0.8004711866378784, 1.0257385969161987, 2.4048447608947754, 1.2285797595977783, -1.4042112827301025, 2.738643169403076, 0.6712639927864075, -0.19049659371376038, -1.0218101739883423, 0.4689844250679016, 0.08799034357070923, -1.2377963066101074, -0.44977644085884094, -0.8969520330429077, -0.059890348464250565, -0.561657190322876, -0.43032655119895935, 0.07219984382390976, 0.46455734968185425, -0.17697013914585114, -0.38545364141464233, -0.6200475692749023, -0.6388229727745056, 0.5127784609794617, -0.41240689158439636, 0.9635812640190125, -0.30241939425468445, 1.825365662574768, -0.629072904586792, 0.43435412645339966, 0.7437175512313843, 1.3352038860321045, 0.18178504705429077, 0.013797762803733349, 0.22497542202472687, 0.39584439992904663, -0.025447096675634384, 0.5064159631729126, 1.1752532720565796, 0.6620293259620667, 0.5269371271133423, 0.7451289892196655, -2.2214159965515137, 1.3573856353759766, -0.9094412922859192, 0.40221965312957764, 1.3381149768829346, -0.9473463296890259, 0.3701545298099518, -1.8121711015701294, -0.06005893647670746, 0.5586856603622437, -2.2907888889312744, 0.21892191469669342, -1.2865816354751587, -0.5311466455459595, 0.9040345549583435, 0.2511083483695984, -1.1890133619308472, 0.27618199586868286, -0.5067049860954285, 0.9752114415168762, 0.4507380723953247, 1.1062114238739014, -1.7203116416931152, -0.05195734277367592, -0.16974562406539917, 0.16364343464374542, -1.2141616344451904, -1.5781515836715698, 0.521255612373352, 0.656074583530426, 0.5321897268295288, -0.1862163543701172, 0.9593954086303711, -1.0664576292037964, 0.8832825422286987, -0.9805266261100769, -1.6380115747451782, -1.404341220855713, -2.271949529647827, -2.306842088699341, 0.7889299392700195, -0.44606316089630127, -0.5115530490875244, 2.0042662620544434, -0.9812575578689575, -1.739393949508667, 1.1524213552474976, 0.27741238474845886, 0.054263386875391006, 2.346618890762329, 0.1778198778629303, -0.6660687327384949, 0.4553249478340149, -0.7315685749053955, 0.8015020489692688, -0.4203716516494751, 1.3329137563705444, 0.41273581981658936, -1.0268372297286987, 1.550593614578247, -0.40051230788230896, 0.582626223564148, -0.6901658773422241, -0.5420670509338379, -0.7469926476478577, 0.3197147250175476, 1.9175269603729248, -0.30364951491355896, 1.5377957820892334, -0.3815920054912567, -1.687463402748108, -1.598308801651001, 0.8566207885742188, 0.4749225974082947, -0.7240707874298096, 0.0264427550137043, -0.4753513038158417, 0.20047159492969513, -0.04235982894897461, 1.1083269119262695, 1.2402034997940063, 0.7404797077178955, -0.39141613245010376, -0.8136904835700989, 0.16649718582630157, -0.13439609110355377, -0.6171162128448486, -1.8412997722625732, -0.2739598751068115, 0.28783202171325684, 0.607992947101593, -1.154927134513855, 1.6937716007232666, 0.9010919332504272, 1.9818806648254395, 0.9702745079994202, -0.3053213953971863, 1.5211365222930908, -0.004840795882046223, 1.8343818187713623, -0.540066659450531, 0.6349758505821228, -0.3445952236652374, -1.0830024480819702, 0.8172637820243835, -0.3305491805076599, -2.0446457862854004, -0.7144771218299866, -0.783149003982544, -0.18784016370773315, -0.7188539505004883, 0.9575081467628479, -0.2675766944885254, -1.37740159034729, 0.20293028652668, -0.6374701857566833, 0.15146765112876892, -1.19554603099823, 0.26321688294410706, 0.7781670689582825, -0.6962261199951172, 0.016209375113248825, -0.235014870762825, -1.2860153913497925, -0.461757093667984, 0.36305344104766846, 1.8401671648025513, -0.7037177085876465, 0.895391047000885, 1.0392906665802002, -0.6947109699249268, 0.15850192308425903, 0.31036198139190674, -0.312470018863678, 0.7828972935676575, -1.0617977380752563, -0.33734577894210815, 1.0813301801681519, -0.19917525351047516, -0.543373167514801, 1.4653160572052002, 0.7935273051261902, -1.0316510200500488, -0.21198299527168274, -0.16157200932502747, -0.8143874406814575, 0.055708978325128555, -1.526163101196289, -0.1714445948600769, 0.3176068663597107, -1.485663652420044, -0.40480273962020874, -0.2911178469657898, 1.2974095344543457, -0.11717405915260315, 1.4283051490783691, -0.22588461637496948, -0.1793777495622635, -0.35649436712265015, -0.45561787486076355, 0.18571215867996216, -0.23863931000232697, -0.6413776278495789, 0.23853233456611633, -0.7803699374198914, 0.3237627446651459, 1.531936526298523, 0.3002238869667053, 0.028342176228761673, 0.49048179388046265, 1.0587265491485596, 0.311767041683197, -0.07692094147205353, -0.8667997121810913, -1.5572830438613892, 2.021552562713623, -1.5107227563858032, 1.959691047668457, 0.8555079698562622, -0.013331830501556396, -1.73642098903656, -1.870082139968872, 1.3499648571014404, 1.1742864847183228, 2.4571402072906494, 0.4683789014816284, 0.3447374999523163, -0.8259223699569702, -0.6740822792053223, 0.3884909749031067, -1.034875512123108, -0.7161509990692139, 0.14022493362426758, 2.35577130317688, 1.799465537071228, -0.5465747714042664, -0.18439429998397827, -1.0011597871780396, 1.4005604982376099, -0.16071325540542603, 0.2399410605430603, 2.080976724624634, -0.2425863891839981, -1.0517929792404175, 1.2972537279129028, -2.3457300662994385, 0.20098719000816345, 1.9576557874679565, 0.26135683059692383, 0.052670110017061234, -1.3996623754501343, -0.5920310616493225, -0.2976084351539612, -0.4166473150253296, -1.281732201576233, 0.5410969257354736, -0.21795126795768738, -0.8354466557502747, -1.4853225946426392, 0.18006785213947296, -1.1804611682891846, -1.6377050876617432, 0.36592552065849304, 1.8317738771438599, 2.0610008239746094, -0.8005035519599915, 1.436627745628357, -0.30830976366996765, 0.11236067116260529, 1.1979031562805176, 1.2346787452697754, 3.1446762084960938, 1.8900007009506226, -1.2422325611114502, 0.652531087398529, -0.19037586450576782, -0.48270276188850403, 1.0552666187286377, -1.122565746307373, 1.2318366765975952, -0.1703050434589386, -1.1792757511138916, -1.2394160032272339, 1.060620665550232, 0.5408139824867249, 0.05394377186894417, -0.47526854276657104, 1.1848610639572144, 0.19401724636554718, 1.3954542875289917, 0.5719794034957886, -0.357477605342865, 0.5924865007400513, -0.43263596296310425, -0.5907488465309143, 1.5724951028823853, 0.16271434724330902, -1.5241972208023071, -2.2671031951904297, -0.18518079817295074, -0.8866357207298279, -0.031428463757038116, -0.5961487293243408, -0.9578016996383667, 1.597350835800171, 0.37257060408592224, -1.3061485290527344, -0.2222638875246048, -0.3762214183807373, -0.5909997820854187, 2.6297249794006348, -1.368190050125122, -0.20373636484146118, -0.9442909359931946, -0.6091262698173523, 1.6173840761184692, -1.2595012187957764, -0.3116052746772766, -1.0495976209640503, -0.5352416038513184, -1.236646056175232, -0.5245940685272217, 0.016549311578273773, -0.8767589330673218, 0.7598039507865906, 0.1504121869802475, -1.1293361186981201, -0.39785391092300415, -0.8699953556060791, 0.9367877244949341, -0.12836170196533203, 0.20496027171611786, 1.8027186393737793, 0.3266828656196594, -0.4239906966686249, 0.6820344924926758, 1.1629908084869385, 0.5648179054260254, -0.6248996257781982, 0.15967035293579102, -0.6835671663284302, 0.29725563526153564, -1.3638564348220825, 0.3176991939544678, -2.8857033252716064, 0.6702410578727722, -0.10343152284622192, -0.14211639761924744, -0.05897340923547745, -1.411500096321106, 1.1522635221481323, 2.623537063598633, -1.1778041124343872, 0.4206748306751251, 0.4004087746143341, 1.134930968284607, -1.530382513999939, 0.3101547360420227, -0.3980850875377655, 2.0633721351623535, 0.16977734863758087, 1.2023353576660156, -0.5481820106506348, -2.239516496658325, 0.593333899974823, -1.211753249168396, -1.1299412250518799, 0.7429737448692322, -0.8905590772628784, 0.08308833837509155, -1.440377116203308, -0.25875696539878845, -0.9067172408103943, -1.2871322631835938, 0.6484553217887878, 0.15940313041210175, 0.42027366161346436, -0.6655858159065247, 0.3046140968799591, -2.1726233959198, -1.3547163009643555, -0.2927227020263672, -0.9739534258842468, 0.47916266322135925, -0.37241944670677185, 0.6354995965957642, -0.15430602431297302, 0.050617899745702744, 0.3219033479690552, 1.4652467966079712, 3.4030983448028564, 0.16786210238933563, 0.3970048725605011, -0.16537192463874817, -0.9443687200546265, 1.4544905424118042, 0.9639646410942078, -0.10393831133842468, -0.5481970906257629, -1.0350290536880493, 1.2830735445022583, 2.0269601345062256, 1.1121068000793457, 0.03634101152420044, -0.7735946178436279, -0.8046517968177795, 0.027605805546045303, 0.15408994257450104, 0.46037986874580383, 0.9746362566947937, 0.011807060800492764, 0.07216735929250717, 1.420842170715332, 1.226185917854309, -0.4256320297718048, 0.3868812024593353, -0.904293417930603, -0.4190664291381836, 0.46428877115249634, 0.3319873809814453, -0.01232091709971428, 0.35659897327423096, -1.0438557863235474, -0.23493851721286774, -0.3181828260421753, -0.9509590268135071, -0.7486356496810913, -0.4548790454864502, -0.37916266918182373, 1.688727617263794, 0.16544248163700104, -0.43187281489372253, 0.013529072515666485, -0.682258129119873, -0.14380943775177002, -1.065143346786499, 0.25511059165000916, -0.03934428095817566, -0.09293688088655472, -0.20280160009860992, 1.7518259286880493, -0.9449267387390137, -2.129366874694824, 0.27878057956695557, 0.20598016679286957, -0.4326511323451996, 0.14144597947597504, 1.6764694452285767, 0.4794572591781616, 1.4634708166122437, 1.3183388710021973, 1.0338045358657837, -0.6198554039001465, -1.2550731897354126, 0.7226347923278809, 0.9632022976875305, -1.3648639917373657, 0.7709774971008301, -0.0852338969707489, -0.5178506970405579, 0.7210676074028015, 1.2956434488296509, 0.4142448306083679, -2.0949485301971436, 0.8161963820457458, -0.9891998171806335, 0.7268799543380737, 0.7554836273193359, 0.7602925300598145, 0.24989259243011475, 0.8408668041229248, -1.2687630653381348, -1.1729973554611206, -0.7571311593055725, -0.6597625613212585, 1.9918218851089478, -0.23318102955818176, 0.5478822588920593, -0.14193832874298096, -1.3105823993682861, -0.0784628614783287, 0.8247749209403992, 0.43404433131217957, -0.4511062204837799, 0.8202106356620789, -0.7370983362197876, -0.9627662301063538, -1.3195202350616455, -0.40331363677978516, -1.027230143547058, -0.9605216979980469, 0.962563157081604, 0.8531115651130676, 0.35795077681541443, 1.9363937377929688, 0.654543399810791, 0.3613779842853546, -2.627331256866455, 0.928065299987793, 0.3251872658729553, -0.04525238275527954, 0.9316971302032471, 0.315826416015625, 1.088054895401001, 0.011699398048222065, 0.5554569959640503, -2.440913200378418, 2.2138853073120117, -0.1928648203611374, 0.7668190598487854, -0.05387648195028305, -0.2209896296262741, 1.135680079460144, 0.5784589648246765, 0.5584874153137207, -1.155726671218872, 0.6968026757240295, -0.6254108548164368, 1.1758620738983154, 0.8593177795410156, -0.7807703018188477, -0.018584106117486954, 1.3289140462875366, 0.42615774273872375, -0.48754990100860596, -0.9633660316467285, -0.9616703987121582, 0.8512618541717529, 1.7824491262435913, -0.07485626637935638, 0.01483845990151167, 0.8172000050544739, 0.7021445035934448, -1.2858325242996216, 0.02670121192932129, -0.7368313670158386, -0.7866523861885071, 1.6535779237747192, 2.0151009559631348, -0.10689351707696915, -0.12019798904657364, -0.7580928206443787, -1.222284197807312, 0.7552973628044128, -0.019739054143428802, 0.11194892227649689, 0.6611284613609314, -0.6472640037536621, 1.1132285594940186, 0.809137225151062, 0.9268142580986023, 0.1405704766511917, 0.36781230568885803, 0.4537883996963501, -0.3314276337623596, -1.115680456161499, -0.41392678022384644, -1.1689224243164062, -2.5331969261169434, 0.49502623081207275, -0.23453949391841888, -1.477894902229309, 0.04895247519016266, -1.0066438913345337, 0.8528096079826355, -0.6113600730895996, -1.1114786863327026, -1.514139175415039, 0.24550318717956543, -0.11712651699781418, 0.9186702370643616, -1.5111136436462402, -0.12889407575130463, 1.1036982536315918, 0.8605429530143738, -0.5518648624420166, 0.9537606239318848, 0.18383929133415222, 0.9667383432388306, 0.8454788327217102, -0.3510843813419342, 0.487952321767807, 0.14503653347492218, -1.2887301445007324, 0.4249148964881897, 1.1781015396118164, 0.20696407556533813, 1.3294250965118408, -0.5162522196769714, 0.04263688623905182, 0.44189438223838806, -0.6609721779823303, -0.4434352219104767, -0.5090299248695374, 0.6791294813156128, -0.010653098113834858, -0.9811420440673828, 0.055364806205034256, -0.1589941531419754, -0.25179070234298706, 0.2074924260377884, -1.5454044342041016, -0.21392519772052765, -0.40189066529273987, -0.5100666284561157, -1.3089139461517334, -0.01923530548810959, 1.414882779121399, -0.7101954221725464, -0.23854827880859375, 0.4838714003562927, 0.47197380661964417, 0.560756266117096, 0.6183649301528931, -0.7425315380096436, -0.2627130150794983, -0.2825055420398712, -0.30127787590026855, 0.3107984960079193, 1.343501329421997, -0.0733528882265091, -1.0192769765853882, 0.7321181893348694, -0.45767414569854736, 0.09505994617938995, 2.0080084800720215, 0.09738648682832718, -0.7998290061950684, 0.32003074884414673, -0.7716398239135742, 1.8602908849716187, 1.7896138429641724, 1.3315249681472778, -0.06094740331172943, -0.9583826065063477, 0.6117249727249146, -0.33037784695625305, -0.3656642436981201, 0.9420010447502136, 0.4149447977542877, -0.2589998245239258, -1.474341869354248, 0.5967119336128235, 1.3096532821655273, -0.8463481068611145, -0.8055239319801331, 0.09755653887987137, -0.8754462599754333, 1.206424355506897, 0.6400498151779175, 0.40095341205596924, 0.20771212875843048, 1.6580616235733032, 0.7134312391281128, -0.45436644554138184, 0.5142172574996948, 0.5929642915725708, -0.25799131393432617, -2.1404166221618652, -1.1707360744476318, 0.2718569338321686, -0.49100473523139954, -1.5729000568389893, 1.3794190883636475, -1.1221524477005005, -0.9726048707962036, 0.46107029914855957, 0.0067065441980957985, 1.386145830154419, 0.3908461630344391, 1.6072851419448853, 2.0956485271453857, 0.8597073554992676, 0.394992470741272, 1.3124496936798096, -0.17453643679618835, -0.5103062987327576, 1.871720552444458, -0.4687111973762512, 0.5269474983215332, 1.137197732925415, -0.3868071138858795, -1.06050705909729, -0.8310373425483704, -1.1025152206420898, -0.6767041683197021, 1.2310408353805542, 0.09079983830451965, -1.1245023012161255, 0.2888449728488922, 1.6062129735946655, 0.1976630538702011, -0.3243095874786377, 0.6267390251159668, 0.3646904528141022, -0.7451038360595703, -0.07154589891433716, -0.9477500915527344, 0.519122302532196, -0.2664053738117218, -0.33868950605392456, 0.30966365337371826, 0.5301141738891602, 1.1496862173080444, -0.081893190741539, 0.05154386907815933, 1.2075811624526978, -1.426893949508667, 1.467012882232666, -0.6723614931106567, 0.2917460501194, -2.419541120529175, 1.4543700218200684, -0.7191941738128662, 1.9444531202316284, -2.6331567764282227, 0.37176448106765747, -0.5418732762336731, -0.5275340676307678, 0.3485652506351471, -0.33831724524497986, 0.11009398847818375, -0.11403236538171768, -1.1683018207550049, -0.055555328726768494, -0.7465339303016663, 0.5788996815681458, 1.148903489112854, 1.3810561895370483, -1.0239955186843872, -0.29792726039886475, -1.718737244606018, -0.18436415493488312, -0.7425290942192078, 0.3563292622566223, -1.9929325580596924, -0.16677728295326233, -1.9077848196029663, -2.306231737136841, -1.3508358001708984, -0.8502460718154907, 1.0663052797317505, 0.19678054749965668, -0.8921892642974854, 1.1248414516448975, -0.39223241806030273, -1.8339942693710327, 1.073986291885376, -2.1814608573913574 ]
https://github.com/huggingface/datasets/issues/5209
Implement ability to define splits in metadata section of dataset card
> We can add new metadata yaml field (say, "custom_configs_info"), so that we can provide smth like: Love it ! Some other ideas to name the "custom_configs_info" field: "configs", "parameters", "config_args", "configurations" > it might require changes in interaction with the viewer on the hub side - to parse these configurations, as they not default configurations (not in BUILDER_CONFIGS list) If we update the `get_dataset_config_names()` function in `datasets` in inspect.py we should be fine - that's what the viewer is using > Overall, I would start from implementing the first solution since it's related to what I'm doing now and is super useful for datasets in general. And then if we agree that having more flexibility in providing parameters to the viewer is required, I can implement the second one. Let me know what you think :) Actually I feel like the second solution includes the first use case you mentioned. If you implement the second solution, then users would just have to add a few lines of YAML and their directories would be considered configurations no ? Maybe there's no need to implement two different logics to do the same thing
### Feature request If you go here: https://huggingface.co/datasets/inria-soda/tabular-benchmark/tree/main you will see bunch of folders that has various CSV files. I’d like dataset viewer to show these files instead of only one dataset like it currently does. (and also people to be able to load them as splits instead of loading through `data_files`) e.g GLUE has various splits on viewer but it’s too overkill to ask people to implement loading script, so it would be better to let them define these in the README file instead. Also pinging @polinaeterna @lhoestq @adrinjalali
437
192
Implement ability to define splits in metadata section of dataset card ### Feature request If you go here: https://huggingface.co/datasets/inria-soda/tabular-benchmark/tree/main you will see bunch of folders that has various CSV files. I’d like dataset viewer to show these files instead of only one dataset like it currently does. (and also people to be able to load them as splits instead of loading through `data_files`) e.g GLUE has various splits on viewer but it’s too overkill to ask people to implement loading script, so it would be better to let them define these in the README file instead. Also pinging @polinaeterna @lhoestq @adrinjalali > We can add new metadata yaml field (say, "custom_configs_info"), so that we can provide smth like: Love it ! Some other ideas to name the "custom_configs_info" field: "configs", "parameters", "config_args", "configurations" > it might require changes in interaction with the viewer on the hub side - to parse these configurations, as they not default configurations (not in BUILDER_CONFIGS list) If we update the `get_dataset_config_names()` function in `datasets` in inspect.py we should be fine - that's what the viewer is using > Overall, I would start from implementing the first solution since it's related to what I'm doing now and is super useful for datasets in general. And then if we agree that having more flexibility in providing parameters to the viewer is required, I can implement the second one. Let me know what you think :) Actually I feel like the second solution includes the first use case you mentioned. If you implement the second solution, then users would just have to add a few lines of YAML and their directories would be considered configurations no ? Maybe there's no need to implement two different logics to do the same thing
[ -1.2331514358520508, -0.9539881348609924, -0.8395516872406006, 1.4312694072723389, -0.12476809322834015, -1.252092957496643, 0.1671333611011505, -1.1161906719207764, 1.648813009262085, -0.8593993186950684, 0.3605314791202545, -1.6549519300460815, 0.0963735282421112, -0.6016249060630798, -0.7955706119537354, -0.9111654758453369, -0.44996020197868347, -0.797728419303894, 1.082945704460144, 2.4608635902404785, 1.200877070426941, -1.4863946437835693, 2.7267725467681885, 0.6058476567268372, -0.13019506633281708, -1.038031816482544, 0.5616498589515686, 0.04648521542549133, -1.2061477899551392, -0.49802958965301514, -0.9754216074943542, -0.059565361589193344, -0.6106727719306946, -0.472627192735672, 0.03745175898075104, 0.3551753759384155, -0.2418966293334961, -0.4045884311199188, -0.5845191478729248, -0.7198451161384583, 0.5088094472885132, -0.3806331157684326, 1.0123159885406494, -0.31453242897987366, 1.8669276237487793, -0.5161176919937134, 0.41816532611846924, 0.7856800556182861, 1.3585758209228516, 0.2337220162153244, 0.00428007822483778, 0.21115612983703613, 0.4086878299713135, -0.10893875360488892, 0.5088269114494324, 1.1590142250061035, 0.6809948682785034, 0.5376841425895691, 0.7546630501747131, -2.1750831604003906, 1.3201196193695068, -0.9927325248718262, 0.3622128963470459, 1.382190227508545, -0.907854437828064, 0.3562951683998108, -1.8239060640335083, -0.07605180889368057, 0.5532550811767578, -2.2750792503356934, 0.22806617617607117, -1.2137998342514038, -0.4644850492477417, 0.9794126152992249, 0.27300363779067993, -1.2258367538452148, 0.2110193520784378, -0.4506670832633972, 1.0133882761001587, 0.4562585949897766, 1.196040153503418, -1.6852892637252808, 0.031623855233192444, -0.28846365213394165, 0.11060304939746857, -1.1926361322402954, -1.5565929412841797, 0.4480924606323242, 0.5887964963912964, 0.42173466086387634, -0.08897881209850311, 0.9984520077705383, -1.0463502407073975, 0.7968136668205261, -0.9063883423805237, -1.5770504474639893, -1.4412552118301392, -2.2652816772460938, -2.3098607063293457, 0.7677082419395447, -0.48658955097198486, -0.5844672918319702, 2.094273567199707, -1.0483152866363525, -1.725691318511963, 1.210801601409912, 0.31338244676589966, 0.03633620962500572, 2.4138762950897217, 0.19098781049251556, -0.6538670063018799, 0.5113191604614258, -0.6350022554397583, 0.840450644493103, -0.42239850759506226, 1.3803435564041138, 0.4630852937698364, -1.028247356414795, 1.5868659019470215, -0.44427603483200073, 0.5536960959434509, -0.6357419490814209, -0.48013314604759216, -0.7912026047706604, 0.3083709180355072, 1.833046317100525, -0.31404343247413635, 1.525689721107483, -0.3397928774356842, -1.6024316549301147, -1.6555293798446655, 0.9378660321235657, 0.46117204427719116, -0.8287938833236694, 0.03286706656217575, -0.3642805516719818, 0.11222634464502335, -0.008720743469893932, 1.1237967014312744, 1.2402433156967163, 0.7183277010917664, -0.3600309491157532, -0.8834798336029053, 0.1302720308303833, -0.17625412344932556, -0.7007006406784058, -1.8094667196273804, -0.32314378023147583, 0.14012446999549866, 0.6187295317649841, -1.1849161386489868, 1.7023355960845947, 0.9706323742866516, 1.8776508569717407, 0.9999893307685852, -0.3229857385158539, 1.503400444984436, 0.026904482394456863, 1.8094791173934937, -0.48403191566467285, 0.6330443024635315, -0.329666405916214, -1.2176345586776733, 0.8085253238677979, -0.34156614542007446, -2.0440750122070312, -0.8110924959182739, -0.8287579417228699, -0.20771999657154083, -0.7065646648406982, 0.922267735004425, -0.2982131540775299, -1.3666929006576538, 0.2735620141029358, -0.6125423908233643, 0.11903733015060425, -1.228589415550232, 0.3482470214366913, 0.7026081085205078, -0.7389234304428101, -0.0022022435441613197, -0.22767649590969086, -1.2641305923461914, -0.46626102924346924, 0.3097178041934967, 1.853040337562561, -0.7783467173576355, 0.8226320147514343, 1.042953372001648, -0.7041727304458618, 0.028381500393152237, 0.3058970272541046, -0.32554423809051514, 0.8236083984375, -1.0814063549041748, -0.40722933411598206, 1.1536204814910889, -0.16714902222156525, -0.6252950429916382, 1.389461636543274, 0.7222313284873962, -0.9868556261062622, -0.1864243894815445, -0.11809033155441284, -0.8814597129821777, 0.004577195271849632, -1.5631754398345947, -0.14239069819450378, 0.30771222710609436, -1.5473525524139404, -0.457351416349411, -0.28133225440979004, 1.2620480060577393, -0.17619121074676514, 1.4772744178771973, -0.37642964720726013, -0.13678643107414246, -0.3706120252609253, -0.4469107985496521, 0.24727389216423035, -0.19280259311199188, -0.5990110039710999, 0.21665751934051514, -0.7855145335197449, 0.29978111386299133, 1.4782217741012573, 0.40904825925827026, 0.029127828776836395, 0.4783576428890228, 1.0580346584320068, 0.3366803824901581, -0.009034127928316593, -0.8435870409011841, -1.5171111822128296, 2.064852237701416, -1.466313123703003, 2.0094964504241943, 0.8542012572288513, -0.020860854536294937, -1.745115041732788, -1.843299150466919, 1.414319634437561, 1.173874855041504, 2.3472049236297607, 0.4602367877960205, 0.338504821062088, -0.8162002563476562, -0.6522133350372314, 0.40235644578933716, -1.0438648462295532, -0.7520308494567871, 0.07589484006166458, 2.371718406677246, 1.7683185338974, -0.4677256643772125, -0.15048621594905853, -1.0141265392303467, 1.3717862367630005, -0.11639082431793213, 0.19052153825759888, 2.014920234680176, -0.2298610359430313, -1.1154570579528809, 1.2932865619659424, -2.324918270111084, 0.13274593651294708, 1.9658467769622803, 0.2665219306945801, 0.05221714451909065, -1.4099332094192505, -0.5900037288665771, -0.2277420461177826, -0.4109281897544861, -1.2801833152770996, 0.5824568271636963, -0.24314197897911072, -0.7701814770698547, -1.4560762643814087, 0.19398370385169983, -1.2098172903060913, -1.5970783233642578, 0.3171502947807312, 1.8367887735366821, 2.108236312866211, -0.7974643111228943, 1.5338095426559448, -0.2825494110584259, 0.15792076289653778, 1.1812435388565063, 1.1935443878173828, 3.1901373863220215, 1.8867180347442627, -1.3236886262893677, 0.5396328568458557, -0.12919214367866516, -0.5638742446899414, 1.0973005294799805, -1.1295257806777954, 1.313344120979309, -0.16008883714675903, -1.1436431407928467, -1.2079888582229614, 1.011725664138794, 0.5106754302978516, 0.06799421459436417, -0.4902786910533905, 1.1856727600097656, 0.09675674140453339, 1.3193893432617188, 0.5087040662765503, -0.35980740189552307, 0.6181482672691345, -0.39324817061424255, -0.5929654240608215, 1.5603760480880737, 0.1487431675195694, -1.4746781587600708, -2.249006509780884, -0.20134922862052917, -0.843282163143158, 0.05754878371953964, -0.5764615535736084, -0.9670999050140381, 1.6518070697784424, 0.3372984230518341, -1.3186038732528687, -0.3642093241214752, -0.3690051734447479, -0.5904197096824646, 2.5814387798309326, -1.4135849475860596, -0.2264220267534256, -0.923076331615448, -0.655562698841095, 1.5786938667297363, -1.2160100936889648, -0.2398417443037033, -1.051797866821289, -0.5572841763496399, -1.2808990478515625, -0.5595683455467224, 0.02720441296696663, -0.9306077361106873, 0.7931331396102905, 0.2247987538576126, -1.123118281364441, -0.3569463789463043, -0.8446382284164429, 0.792309582233429, -0.0941350907087326, 0.254625141620636, 1.834349513053894, 0.35816067457199097, -0.4264979958534241, 0.6700959205627441, 1.1538327932357788, 0.6098488569259644, -0.6209370493888855, 0.17444638907909393, -0.6579925417900085, 0.30468103289604187, -1.2817946672439575, 0.31017085909843445, -2.887988567352295, 0.6682454347610474, -0.12204170227050781, -0.13381226360797882, 0.031054258346557617, -1.3117423057556152, 1.066762924194336, 2.561760902404785, -1.1615478992462158, 0.45284849405288696, 0.327377051115036, 1.162747859954834, -1.6072731018066406, 0.29063645005226135, -0.3693687319755554, 2.091136932373047, 0.16901719570159912, 1.2007215023040771, -0.5165398120880127, -2.304068088531494, 0.6006205677986145, -1.2126573324203491, -1.1875755786895752, 0.7796090841293335, -0.8306868076324463, 0.021995853632688522, -1.394012689590454, -0.27350112795829773, -0.8897712230682373, -1.2427051067352295, 0.7099321484565735, 0.19314201176166534, 0.39932215213775635, -0.6163280010223389, 0.24770915508270264, -2.1601970195770264, -1.3597502708435059, -0.20764537155628204, -0.8899118900299072, 0.4629681408405304, -0.3975595533847809, 0.6497976183891296, -0.20030052959918976, 0.017997536808252335, 0.335861474275589, 1.419784665107727, 3.393204927444458, 0.2625904381275177, 0.45134201645851135, -0.17397813498973846, -0.9425160884857178, 1.499119758605957, 0.919367790222168, -0.14940011501312256, -0.5472655296325684, -1.0856010913848877, 1.2761387825012207, 1.9645907878875732, 0.9680043458938599, -0.019898440688848495, -0.7140174508094788, -0.6657930612564087, -0.07585590332746506, 0.13127745687961578, 0.4431154727935791, 0.950347900390625, -0.04823027923703194, 0.08553753793239594, 1.4348775148391724, 1.2438981533050537, -0.46634846925735474, 0.4034198522567749, -0.7547687292098999, -0.4826432764530182, 0.47628727555274963, 0.3347395062446594, -0.009661026298999786, 0.34362104535102844, -1.0084928274154663, -0.25208741426467896, -0.39748823642730713, -0.9779966473579407, -0.6978458166122437, -0.4132063686847687, -0.3227689862251282, 1.6099108457565308, 0.1538759171962738, -0.4824802279472351, 0.048808906227350235, -0.7295249104499817, -0.1395464688539505, -1.0868709087371826, 0.20982469618320465, -0.10965029150247574, -0.18828296661376953, -0.09055990725755692, 1.7710777521133423, -0.9297313094139099, -2.1450939178466797, 0.22808794677257538, 0.24485158920288086, -0.36106768250465393, 0.20310966670513153, 1.6462780237197876, 0.4177772104740143, 1.455863118171692, 1.3831872940063477, 0.9522662162780762, -0.6705706715583801, -1.2356114387512207, 0.731218695640564, 0.9950917363166809, -1.437821626663208, 0.7980085611343384, -0.09320785105228424, -0.5919559597969055, 0.7639774680137634, 1.2123186588287354, 0.460188627243042, -2.0292952060699463, 0.8599786758422852, -0.9278842806816101, 0.7404212355613708, 0.6858629584312439, 0.7271689176559448, 0.2759312093257904, 0.8093096613883972, -1.204643726348877, -1.1418490409851074, -0.7338910698890686, -0.6796601414680481, 1.9934853315353394, -0.2618892192840576, 0.591356635093689, -0.14267997443675995, -1.3201409578323364, -0.12568677961826324, 0.723233163356781, 0.34866875410079956, -0.3868885636329651, 0.745691180229187, -0.7477957606315613, -1.0724694728851318, -1.457395315170288, -0.35382649302482605, -1.084822177886963, -0.8974955081939697, 1.0656147003173828, 0.8551759719848633, 0.22573141753673553, 1.9592972993850708, 0.6687281727790833, 0.2802024781703949, -2.620722770690918, 0.906823456287384, 0.3508087694644928, -0.08188560605049133, 0.9117623567581177, 0.37579914927482605, 1.0817278623580933, 0.03385230526328087, 0.5348384976387024, -2.4100096225738525, 2.288909673690796, -0.2478925585746765, 0.7696611285209656, -0.0733967050909996, -0.23140741884708405, 1.1626453399658203, 0.6188715100288391, 0.6125822067260742, -1.1737715005874634, 0.6876186728477478, -0.5565693974494934, 1.1652618646621704, 0.9623872637748718, -0.8010968565940857, 0.004937067627906799, 1.3737211227416992, 0.4704846739768982, -0.5186031460762024, -0.9251320362091064, -0.91786128282547, 0.8798914551734924, 1.8313319683074951, -0.05629775673151016, 0.05073225125670433, 0.7912649512290955, 0.6835356950759888, -1.3139781951904297, 0.11543469876050949, -0.7570273280143738, -0.8778198957443237, 1.655600666999817, 2.0095632076263428, -0.1294158548116684, -0.14772586524486542, -0.7221099138259888, -1.3410941362380981, 0.8459364771842957, -0.020957618951797485, 0.18350976705551147, 0.6064640879631042, -0.6797193288803101, 1.1290465593338013, 0.9107738137245178, 0.8835349082946777, 0.19282744824886322, 0.2375122755765915, 0.43946561217308044, -0.23010823130607605, -1.066451907157898, -0.21545307338237762, -1.1394543647766113, -2.5383553504943848, 0.4646606743335724, -0.20683811604976654, -1.4192814826965332, -0.02551855519413948, -0.9201213121414185, 0.9059887528419495, -0.5159821510314941, -1.1145405769348145, -1.5512008666992188, 0.2419097125530243, -0.05960790440440178, 0.8934652209281921, -1.567637324333191, -0.11653851717710495, 1.1689022779464722, 0.9244664907455444, -0.6128228306770325, 0.9770901799201965, 0.21876315772533417, 0.9787842631340027, 0.8237708210945129, -0.4012366235256195, 0.4918648898601532, 0.10185796022415161, -1.3085284233093262, 0.40497758984565735, 1.1438205242156982, 0.14654982089996338, 1.376846194267273, -0.5386523604393005, -0.002202431671321392, 0.3693218529224396, -0.5681983828544617, -0.41736656427383423, -0.5338886380195618, 0.6303352117538452, -0.04087616875767708, -0.8841421008110046, 0.09670461714267731, -0.14962436258792877, -0.2892802953720093, 0.2122207134962082, -1.5111151933670044, -0.18989130854606628, -0.4365706145763397, -0.5104880928993225, -1.2753046751022339, -0.008046438917517662, 1.4613744020462036, -0.7392686009407043, -0.2516247034072876, 0.5000917911529541, 0.4792778491973877, 0.5005806684494019, 0.6217033863067627, -0.7372678518295288, -0.3132050335407257, -0.2689397931098938, -0.3341498374938965, 0.2544906437397003, 1.360841989517212, -0.1692006140947342, -0.9640020728111267, 0.7215990424156189, -0.35559505224227905, 0.04356752336025238, 1.9445101022720337, 0.1248142421245575, -0.7998462319374084, 0.3416806757450104, -0.7038724422454834, 1.9393069744110107, 1.8276540040969849, 1.3623042106628418, -0.10587518662214279, -0.937134861946106, 0.7145715355873108, -0.3533878028392792, -0.3148002028465271, 0.9888268113136292, 0.40621447563171387, -0.16151973605155945, -1.5038779973983765, 0.5726240873336792, 1.2413575649261475, -0.8024219870567322, -0.770785391330719, 0.05341162160038948, -0.8682193756103516, 1.1110862493515015, 0.652781069278717, 0.5056484341621399, 0.170974463224411, 1.6623437404632568, 0.7523250579833984, -0.4878544211387634, 0.5306386351585388, 0.6193603873252869, -0.19549795985221863, -2.119647979736328, -1.129379391670227, 0.24956649541854858, -0.452266663312912, -1.5742124319076538, 1.3995283842086792, -1.0908963680267334, -0.9509015083312988, 0.4895307719707489, -0.03686264902353287, 1.4037010669708252, 0.35833171010017395, 1.6103767156600952, 2.140317678451538, 0.9167338609695435, 0.4025512933731079, 1.2912020683288574, -0.16044333577156067, -0.38188186287879944, 1.8638222217559814, -0.40737518668174744, 0.3935888707637787, 1.171437382698059, -0.4021545350551605, -0.9777319431304932, -0.781368613243103, -1.116032361984253, -0.7042827010154724, 1.1578588485717773, 0.03535480052232742, -1.0607661008834839, 0.2754262387752533, 1.6279252767562866, 0.11099820584058762, -0.3646527826786041, 0.6214331984519958, 0.4612126350402832, -0.7166605591773987, -0.11208464950323105, -0.9289205074310303, 0.5297495722770691, -0.29112786054611206, -0.4038139879703522, 0.3741310238838196, 0.4322197735309601, 1.2712111473083496, -0.06878381222486496, 0.11072319000959396, 1.1571577787399292, -1.4258019924163818, 1.4164777994155884, -0.6893145442008972, 0.21370132267475128, -2.406210422515869, 1.4475436210632324, -0.7093040943145752, 1.962116003036499, -2.5826308727264404, 0.445658802986145, -0.6623654365539551, -0.5057065486907959, 0.41027331352233887, -0.3758538067340851, 0.11582425236701965, -0.18337947130203247, -1.0977436304092407, -0.10188977420330048, -0.6428120136260986, 0.6023480892181396, 1.192787528038025, 1.2964956760406494, -1.049272060394287, -0.309565931558609, -1.6789281368255615, -0.13553492724895477, -0.6583714485168457, 0.3185614347457886, -2.059535026550293, -0.23000162839889526, -1.921133279800415, -2.352499008178711, -1.3495546579360962, -0.8040568828582764, 1.1670864820480347, 0.23744139075279236, -0.9144070744514465, 1.1896995306015015, -0.3300912082195282, -1.8603895902633667, 1.1398946046829224, -2.1368062496185303 ]
https://github.com/huggingface/datasets/issues/5209
Implement ability to define splits in metadata section of dataset card
@merveenoyan I haven't started working on this yet, working on adding configs to packaged datasets instead: https://github.com/huggingface/datasets/pull/5213 because this both would allow you to solve your issue and is a frequently requested feature. adding arbitrary parameters to yaml would be my next task i think!
### Feature request If you go here: https://huggingface.co/datasets/inria-soda/tabular-benchmark/tree/main you will see bunch of folders that has various CSV files. I’d like dataset viewer to show these files instead of only one dataset like it currently does. (and also people to be able to load them as splits instead of loading through `data_files`) e.g GLUE has various splits on viewer but it’s too overkill to ask people to implement loading script, so it would be better to let them define these in the README file instead. Also pinging @polinaeterna @lhoestq @adrinjalali
437
45
Implement ability to define splits in metadata section of dataset card ### Feature request If you go here: https://huggingface.co/datasets/inria-soda/tabular-benchmark/tree/main you will see bunch of folders that has various CSV files. I’d like dataset viewer to show these files instead of only one dataset like it currently does. (and also people to be able to load them as splits instead of loading through `data_files`) e.g GLUE has various splits on viewer but it’s too overkill to ask people to implement loading script, so it would be better to let them define these in the README file instead. Also pinging @polinaeterna @lhoestq @adrinjalali @merveenoyan I haven't started working on this yet, working on adding configs to packaged datasets instead: https://github.com/huggingface/datasets/pull/5213 because this both would allow you to solve your issue and is a frequently requested feature. adding arbitrary parameters to yaml would be my next task i think!
[ -1.1746667623519897, -1.0280810594558716, -0.8656846880912781, 1.5066019296646118, -0.11112380027770996, -1.200455904006958, 0.0631195455789566, -1.0491706132888794, 1.6311368942260742, -0.7760852575302124, 0.4136194884777069, -1.6600960493087769, 0.12242704629898071, -0.6262632608413696, -0.7676149010658264, -0.9642442464828491, -0.4327239692211151, -0.7615002393722534, 1.0096368789672852, 2.4731342792510986, 1.2241153717041016, -1.3648351430892944, 2.780930995941162, 0.6262830495834351, -0.2044827789068222, -1.148276925086975, 0.567001461982727, 0.09979422390460968, -1.1855398416519165, -0.4340142607688904, -0.9508755207061768, -0.06437194347381592, -0.563558042049408, -0.5111663937568665, 0.05651156231760979, 0.3798562288284302, -0.15939219295978546, -0.3073943853378296, -0.503227949142456, -0.7090404629707336, 0.5364977717399597, -0.34370777010917664, 0.9845520257949829, -0.3075663447380066, 1.86991286277771, -0.5480585098266602, 0.3071962893009186, 0.7137572765350342, 1.3991906642913818, 0.2046261876821518, 0.0020437417551875114, 0.17405563592910767, 0.41055288910865784, -0.050021324306726456, 0.4382950961589813, 1.1392041444778442, 0.5830491185188293, 0.5622531175613403, 0.7043715119361877, -2.163818120956421, 1.3857663869857788, -0.8735198378562927, 0.3903731107711792, 1.2869101762771606, -0.9820302724838257, 0.32977813482284546, -1.7507888078689575, -0.11585302650928497, 0.5540397763252258, -2.270345687866211, 0.18245929479599, -1.1988250017166138, -0.5554810762405396, 0.9785686135292053, 0.22273823618888855, -1.2784281969070435, 0.2419709712266922, -0.46348974108695984, 1.0141969919204712, 0.5522662997245789, 1.1526343822479248, -1.6808472871780396, 0.1003744900226593, -0.24868787825107574, 0.08541730046272278, -1.3000417947769165, -1.5021960735321045, 0.43066200613975525, 0.6536747217178345, 0.5410951375961304, -0.02045796439051628, 0.8409566879272461, -0.9119823575019836, 0.8851765394210815, -0.8979254364967346, -1.6129050254821777, -1.367908000946045, -2.257761001586914, -2.3904850482940674, 0.8011161088943481, -0.40300142765045166, -0.6007248163223267, 1.937222957611084, -0.9865162372589111, -1.8685500621795654, 1.1794933080673218, 0.25249576568603516, 0.0444074347615242, 2.435239791870117, 0.1565810739994049, -0.6413571834564209, 0.45479345321655273, -0.6801299452781677, 0.8872599005699158, -0.4300503134727478, 1.4571808576583862, 0.5319657325744629, -1.0449235439300537, 1.6548210382461548, -0.4861724376678467, 0.4705134332180023, -0.685712993144989, -0.5333436727523804, -0.8426618576049805, 0.3482591509819031, 1.8606337308883667, -0.3454444110393524, 1.586021900177002, -0.41099733114242554, -1.6503716707229614, -1.637313961982727, 0.8325762152671814, 0.4780740439891815, -0.798292338848114, 0.07525956630706787, -0.4238188564777374, 0.1287965625524521, 0.015822559595108032, 1.0334171056747437, 1.1681933403015137, 0.6362513303756714, -0.3130791187286377, -0.850225567817688, 0.198371022939682, -0.0605144202709198, -0.6083070635795593, -1.8782716989517212, -0.26005202531814575, 0.23434221744537354, 0.6667755246162415, -1.19064199924469, 1.6225650310516357, 0.8712745308876038, 1.9814083576202393, 0.9960002899169922, -0.22311986982822418, 1.5641993284225464, -0.11168114840984344, 1.8074437379837036, -0.5047171711921692, 0.662186324596405, -0.3242240846157074, -1.1330392360687256, 0.7406066656112671, -0.3661133646965027, -2.0135695934295654, -0.8330060839653015, -0.85041344165802, -0.15063875913619995, -0.763229489326477, 1.0303887128829956, -0.34741830825805664, -1.3773726224899292, 0.2686800956726074, -0.6547057628631592, 0.12232449650764465, -1.2379053831100464, 0.2875901460647583, 0.7403113842010498, -0.7222901582717896, -0.009188088588416576, -0.26827359199523926, -1.2173287868499756, -0.5162363648414612, 0.31926482915878296, 1.8958498239517212, -0.7881558537483215, 0.8684708476066589, 0.969589352607727, -0.6394791007041931, 0.10165107250213623, 0.37634769082069397, -0.29924705624580383, 0.7979187965393066, -1.0504640340805054, -0.31804710626602173, 1.1179656982421875, -0.13998472690582275, -0.662699282169342, 1.4748704433441162, 0.9039398431777954, -1.0132580995559692, -0.12893150746822357, -0.18151719868183136, -0.7575191259384155, -0.03868982940912247, -1.6450932025909424, -0.12582659721374512, 0.22977314889431, -1.4786282777786255, -0.40245822072029114, -0.28916653990745544, 1.2255619764328003, -0.1275475025177002, 1.3989793062210083, -0.32485705614089966, -0.2708214819431305, -0.3593740463256836, -0.45964163541793823, 0.20536461472511292, -0.17736271023750305, -0.6772068738937378, 0.2776835560798645, -0.8080244660377502, 0.36970654129981995, 1.5595059394836426, 0.394756019115448, 0.14292588829994202, 0.4977383315563202, 1.0928391218185425, 0.26501742005348206, -0.028495624661445618, -0.8552807569503784, -1.5847269296646118, 2.072173833847046, -1.4713481664657593, 1.9824861288070679, 0.8432650566101074, -0.0604705810546875, -1.7508528232574463, -1.7977451086044312, 1.4509634971618652, 1.1993857622146606, 2.36742901802063, 0.5825362205505371, 0.24866627156734467, -0.8439511060714722, -0.6127691268920898, 0.32110777497291565, -1.112370252609253, -0.781731128692627, 0.0727086067199707, 2.3524272441864014, 1.8039559125900269, -0.5232833027839661, -0.19510532915592194, -1.0632511377334595, 1.3172085285186768, -0.14270587265491486, 0.17059311270713806, 2.079800605773926, -0.3072824478149414, -1.0924899578094482, 1.227189540863037, -2.3069939613342285, 0.13164953887462616, 1.8993655443191528, 0.24777193367481232, 0.09125909209251404, -1.476183533668518, -0.6473666429519653, -0.24238932132720947, -0.4014940857887268, -1.277850866317749, 0.6186782717704773, -0.24650441110134125, -0.8384793996810913, -1.419331669807434, 0.1503334641456604, -1.1472042798995972, -1.6746634244918823, 0.44336751103401184, 1.7486419677734375, 2.0989787578582764, -0.8344838619232178, 1.5041929483413696, -0.21407538652420044, 0.18397748470306396, 1.3487908840179443, 1.2183376550674438, 3.181999683380127, 1.8607988357543945, -1.2298877239227295, 0.654169499874115, -0.13973964750766754, -0.5143163204193115, 1.1521142721176147, -1.1103317737579346, 1.2654855251312256, -0.26039573550224304, -1.2095412015914917, -1.2920562028884888, 1.0335520505905151, 0.4733304977416992, 0.09202942252159119, -0.5108129382133484, 1.2480909824371338, 0.12923100590705872, 1.2957885265350342, 0.48270606994628906, -0.34822213649749756, 0.5727818608283997, -0.41035932302474976, -0.6056105494499207, 1.5579484701156616, 0.15718811750411987, -1.5891865491867065, -2.215040683746338, -0.13123305141925812, -0.7907555103302002, -0.1430414766073227, -0.4947993755340576, -1.0760282278060913, 1.5748095512390137, 0.4118853509426117, -1.3332674503326416, -0.28305745124816895, -0.40248703956604004, -0.6357069611549377, 2.5933001041412354, -1.427764654159546, -0.261802613735199, -0.9446861147880554, -0.5522626638412476, 1.6481233835220337, -1.1862547397613525, -0.2186099737882614, -0.9812408685684204, -0.6087397933006287, -1.3582642078399658, -0.5441691279411316, 0.015522759407758713, -0.9131419062614441, 0.729484498500824, 0.1025715172290802, -1.072686791419983, -0.2930533289909363, -0.8604635000228882, 0.8440594673156738, -0.11134015023708344, 0.3861762583255768, 1.87423574924469, 0.4427917003631592, -0.44440433382987976, 0.6305751800537109, 1.1525870561599731, 0.6026877760887146, -0.7042384743690491, 0.2424515038728714, -0.7138336300849915, 0.2692411243915558, -1.331017255783081, 0.335374116897583, -2.8693976402282715, 0.7390777468681335, -0.07531753182411194, -0.19352403283119202, 0.0015466483309864998, -1.3174846172332764, 1.156679630279541, 2.6504969596862793, -1.1634267568588257, 0.4022497832775116, 0.3337169885635376, 1.198728322982788, -1.548139214515686, 0.3600679337978363, -0.38196173310279846, 2.050569772720337, 0.1701251119375229, 1.2771589756011963, -0.5039508938789368, -2.205559730529785, 0.7148902416229248, -1.2855846881866455, -1.1273866891860962, 0.7804610133171082, -0.8486117720603943, -0.028430480509996414, -1.4241938591003418, -0.23798461258411407, -0.970345675945282, -1.2826141119003296, 0.7792477607727051, 0.22791169583797455, 0.3872661590576172, -0.555651068687439, 0.2937648594379425, -2.129619598388672, -1.4070521593093872, -0.24901419878005981, -0.9346680641174316, 0.4412054717540741, -0.2996344566345215, 0.5457053780555725, -0.19986210763454437, 0.04007488116621971, 0.33805152773857117, 1.3903931379318237, 3.3945109844207764, 0.272800087928772, 0.4851510524749756, -0.12432260811328888, -0.9443185925483704, 1.5304813385009766, 0.9767842292785645, -0.12625952064990997, -0.5061513185501099, -0.9754766821861267, 1.2934845685958862, 1.9482030868530273, 1.1328884363174438, 0.04866589605808258, -0.7393707633018494, -0.7028518319129944, 0.021314995363354683, 0.19350871443748474, 0.43931686878204346, 0.928445041179657, -0.09055761992931366, 0.13062570989131927, 1.3992695808410645, 1.3053404092788696, -0.463367760181427, 0.47847652435302734, -0.8935402631759644, -0.33998894691467285, 0.5117555856704712, 0.2670620381832123, 0.054776404052972794, 0.38782209157943726, -1.0742651224136353, -0.22243110835552216, -0.2876244783401489, -1.0684007406234741, -0.7706710696220398, -0.4845627248287201, -0.34552350640296936, 1.5703386068344116, 0.12338492274284363, -0.424875408411026, -0.011506704613566399, -0.7804999947547913, -0.15583212673664093, -1.0458457469940186, 0.1521463543176651, -0.07718823850154877, -0.17236296832561493, -0.15474848449230194, 1.8541159629821777, -1.1171035766601562, -2.2414093017578125, 0.35087481141090393, 0.252215713262558, -0.45047828555107117, 0.18423056602478027, 1.5222517251968384, 0.42234063148498535, 1.4367315769195557, 1.321761131286621, 1.0424261093139648, -0.6573085188865662, -1.2158112525939941, 0.7288612127304077, 0.9807948470115662, -1.391414761543274, 0.8182493448257446, -0.08320076763629913, -0.49775004386901855, 0.7677910327911377, 1.2608108520507812, 0.3826178014278412, -1.9838206768035889, 0.7405789494514465, -0.8042512536048889, 0.7232518196105957, 0.6585416793823242, 0.82076495885849, 0.2758885324001312, 0.8322411775588989, -1.2866021394729614, -1.1385177373886108, -0.7718597650527954, -0.5722272396087646, 1.8896944522857666, -0.07606673240661621, 0.5795001983642578, -0.05282582342624664, -1.2684764862060547, -0.07631656527519226, 0.7197890281677246, 0.3268769383430481, -0.3379320204257965, 0.8364908695220947, -0.7286778092384338, -0.9507244229316711, -1.3958618640899658, -0.4139980971813202, -0.961280107498169, -0.9185930490493774, 0.9982258081436157, 0.843407928943634, 0.24440519511699677, 1.9716652631759644, 0.5858046412467957, 0.3288009762763977, -2.6675078868865967, 0.9394194483757019, 0.2592618763446808, 0.02655351161956787, 0.8860594630241394, 0.30413901805877686, 1.0557290315628052, 0.010136362165212631, 0.4849337339401245, -2.385335922241211, 2.2742154598236084, -0.2515751123428345, 0.6997455358505249, -0.031014515087008476, -0.19304801523685455, 1.170899510383606, 0.6194226145744324, 0.6027654409408569, -1.1754372119903564, 0.7198993563652039, -0.5911651253700256, 1.1837512254714966, 0.9770825505256653, -0.8475369811058044, 0.015293741598725319, 1.284486174583435, 0.41278398036956787, -0.3815019726753235, -0.9018561840057373, -0.8133195042610168, 0.8752231597900391, 1.765467643737793, -0.002272713463753462, 0.03570018336176872, 0.8142157196998596, 0.6264665722846985, -1.2972172498703003, -0.007921705022454262, -0.7752431631088257, -0.7695897221565247, 1.7307811975479126, 1.9815953969955444, -0.16188128292560577, -0.16303475201129913, -0.8036901950836182, -1.1356233358383179, 0.8446694016456604, -0.025521408766508102, 0.1441935896873474, 0.6633113026618958, -0.687026858329773, 1.2103712558746338, 0.8764878511428833, 0.8912001252174377, 0.10493601858615875, 0.3587695062160492, 0.3846948444843292, -0.2510221302509308, -1.112155556678772, -0.37679994106292725, -1.2037373781204224, -2.568854808807373, 0.46444734930992126, -0.3485493063926697, -1.3938912153244019, -0.003430658020079136, -1.0691263675689697, 0.8698086142539978, -0.5616405606269836, -1.058340311050415, -1.4988961219787598, 0.248890683054924, -0.22658151388168335, 0.9050602316856384, -1.5232819318771362, 0.014079596847295761, 1.169389009475708, 0.9249070882797241, -0.5988344550132751, 0.9955309629440308, 0.2155836969614029, 1.0155272483825684, 0.8242783546447754, -0.3897036015987396, 0.4793563187122345, 0.15213505923748016, -1.2701565027236938, 0.37266093492507935, 1.0931861400604248, 0.18478427827358246, 1.3525882959365845, -0.533324122428894, 0.019337546080350876, 0.43432989716529846, -0.6566685438156128, -0.5054430961608887, -0.5648508667945862, 0.7478533387184143, 0.08385486900806427, -0.9296677708625793, 0.11089593172073364, -0.1331605613231659, -0.23831883072853088, 0.2814983129501343, -1.6403312683105469, -0.3035334348678589, -0.35732996463775635, -0.5622053146362305, -1.286792516708374, 0.011773856356739998, 1.4244531393051147, -0.7671582698822021, -0.2538750469684601, 0.4839949309825897, 0.4313151240348816, 0.4818865954875946, 0.5733689665794373, -0.7044738531112671, -0.3705001473426819, -0.31674471497535706, -0.18732231855392456, 0.2268315553665161, 1.2682791948318481, -0.1587439626455307, -1.0486810207366943, 0.7673932909965515, -0.4445415437221527, 0.12061762809753418, 2.006129026412964, 0.10150434076786041, -0.8647690415382385, 0.3181585669517517, -0.6743189096450806, 1.897932529449463, 1.7540357112884521, 1.3625062704086304, -0.11819884181022644, -0.9040640592575073, 0.611402690410614, -0.2022605836391449, -0.3016798794269562, 0.9284669160842896, 0.45458105206489563, -0.1562596559524536, -1.4568028450012207, 0.5341053605079651, 1.276104211807251, -0.8468858003616333, -0.8209256529808044, 0.03878425806760788, -0.9183289408683777, 1.0721155405044556, 0.674853503704071, 0.49555596709251404, 0.19391785562038422, 1.5896683931350708, 0.6507803797721863, -0.5261617302894592, 0.4037480354309082, 0.4644758999347687, -0.14827919006347656, -2.097827434539795, -1.0198100805282593, 0.23815491795539856, -0.4520455598831177, -1.5680495500564575, 1.3101342916488647, -1.1590497493743896, -0.8388898372650146, 0.5399353504180908, 0.07236377894878387, 1.4484128952026367, 0.2543094754219055, 1.5768449306488037, 2.1292166709899902, 0.8743312358856201, 0.3144626319408417, 1.32472562789917, -0.15203844010829926, -0.43637317419052124, 1.8556984663009644, -0.4186417758464813, 0.5553968548774719, 1.1119892597198486, -0.39139941334724426, -0.9770594835281372, -0.7975443005561829, -1.1091231107711792, -0.6195105314254761, 1.1724276542663574, 0.16580751538276672, -1.2046235799789429, 0.20511747896671295, 1.6133581399917603, 0.07186207175254822, -0.2995750308036804, 0.596663773059845, 0.40633702278137207, -0.7403810024261475, -0.046193115413188934, -0.9408109188079834, 0.5720149874687195, -0.2592030167579651, -0.36126890778541565, 0.30466657876968384, 0.480834037065506, 1.0900095701217651, -0.09910508990287781, 0.07927484810352325, 1.3006311655044556, -1.315358281135559, 1.4439682960510254, -0.6198433637619019, 0.24510373175144196, -2.4326860904693604, 1.4405652284622192, -0.72991943359375, 1.8474090099334717, -2.6253604888916016, 0.39987409114837646, -0.6880249381065369, -0.4876828193664551, 0.3495868146419525, -0.4178254306316376, 0.10961773991584778, -0.17825239896774292, -1.026845097541809, -0.07924972474575043, -0.7116492390632629, 0.5327041745185852, 1.2742382287979126, 1.2802698612213135, -1.0797159671783447, -0.2849771976470947, -1.77859365940094, -0.20243093371391296, -0.7243525385856628, 0.3683185577392578, -2.115583896636963, -0.1716802716255188, -1.8712849617004395, -2.2980549335479736, -1.4471051692962646, -0.8322170376777649, 1.1189823150634766, 0.19427841901779175, -0.9304305911064148, 1.0997108221054077, -0.3857627213001251, -1.7595081329345703, 1.11411714553833, -2.1707513332366943 ]
https://github.com/huggingface/datasets/issues/5207
Connection error of the HuggingFace's dataset Hub due to SSLError with proxy
Hi ! It looks like an issue with your python environment, can you make sure you're able to run GET requests to https://huggingface.co using `requests` in python ?
### Describe the bug It's weird. I could not normally connect the dataset Hub of HuggingFace due to a SSLError in my office. Even when I try to connect using my company's proxy address (e.g., http_proxy and https_proxy), I'm getting the SSLError issue. What should I do to download the datanet stored in HuggingFace normally? I welcome any comments. I think those comments will be helpful to me. * Dataset address - https://huggingface.co/datasets/moyix/debian_csrc/viewer/moyix--debian_csrc * Log message ``` ............ OMISSION .............. Traceback (most recent call last): File "/data/home/geunsik-lim/qtlab/./transformers/examples/pytorch/language-modeling/run_clm.py", line 587, in <module> main() File "/data/home/geunsik-lim/qtlab/./transformers/examples/pytorch/language-modeling/run_clm.py", line 278, in main raw_datasets = load_dataset( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1719, in load_dataset builder_instance = load_dataset_builder( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1497, in load_dataset_builder dataset_module = dataset_module_factory( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1222, in dataset_module_factory raise e1 from None File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1179, in dataset_module_factory raise ConnectionError(f"Couldn't reach '{path}' on the Hub ({type(e).__name__})") ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError) [2022-11-07 15:23:38,476] [INFO] [launch.py:318:sigkill_handler] Killing subprocess 6760 [2022-11-07 15:23:38,476] [ERROR] [launch.py:324:sigkill_handler] ['/home/geunsik-lim/anaconda3/envs/deepspeed/bin/python', '-u', './transformers/examples/pytorch/language-modeling/run_clm.py', '--local_rank=0', '--model_name_or_path=Salesforce/codegen-350M-multi', '--per_device_train_batch_size=1', '--learning_rate', '2e-5', '--num_train_epochs', '1', '--output_dir=./codegen-350M-finetuned', '--overwrite_output_dir', '--dataset_name', 'moyix/debian_csrc', '--cache_dir', '/data/home/geunsik-lim/.cache', '--tokenizer_name', 'Salesforce/codegen-350M-multi', '--block_size', '2048', '--gradient_accumulation_steps', '32', '--do_train', '--fp16', '--deepspeed', 'ds_config_zero2.json'] exits with return code = 1 real 0m7.742s user 0m4.930s ``` ### Steps to reproduce the bug Steps to reproduce this behavior. ``` (deepspeed) geunsik-lim@ai02:~/qtlab$ ./test_debian_csrc_dataset.py Traceback (most recent call last): File "/data/home/geunsik-lim/qtlab/./test_debian_csrc_dataset.py", line 6, in <module> dataset = load_dataset("moyix/debian_csrc") File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1719, in load_dataset builder_instance = load_dataset_builder( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1497, in load_dataset_builder dataset_module = dataset_module_factory( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1222, in dataset_module_factory raise e1 from None File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1179, in dataset_module_factory raise ConnectionError(f"Couldn't reach '{path}' on the Hub ({type(e).__name__})") ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError) (deepspeed) geunsik-lim@ai02:~/qtlab$ (deepspeed) geunsik-lim@ai02:~/qtlab$ (deepspeed) geunsik-lim@ai02:~/qtlab$ (deepspeed) geunsik-lim@ai02:~/qtlab$ cat ./test_debian_csrc_dataset.py #!/usr/bin/env python from datasets import load_dataset dataset = load_dataset("moyix/debian_csrc") ``` 1. Adde proxy address of a company in /etc/profile 2. Download dataset with load_dataset() function of datasets package that is provided by HuggingFace. 3. In this case, the address would be "moyix--debian_csrc". 4. I get the "`ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError`)" error message. ### Expected behavior * error message: ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError) ### Environment info * software version information: ``` (deepspeed) geunsik-lim@ai02:~$ (deepspeed) geunsik-lim@ai02:~$ conda list -f pytorch # packages in environment at /home/geunsik-lim/anaconda3/envs/deepspeed: # # Name Version Build Channel pytorch 1.13.0 py3.10_cuda11.7_cudnn8.5.0_0 pytorch (deepspeed) geunsik-lim@ai02:~$ conda list -f python # packages in environment at /home/geunsik-lim/anaconda3/envs/deepspeed: # # Name Version Build Channel python 3.10.6 haa1d7c7_1 (deepspeed) geunsik-lim@ai02:~$ conda list -f datasets # packages in environment at /home/geunsik-lim/anaconda3/envs/deepspeed: # # Name Version Build Channel datasets 2.6.1 py_0 huggingface (deepspeed) geunsik-lim@ai02:~$ uname -a Linux ai02 5.4.0-131-generic #147-Ubuntu SMP Fri Oct 14 17:07:22 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux (deepspeed) geunsik-lim@ai02:~$ cat /etc/lsb-release DISTRIB_ID=Ubuntu DISTRIB_RELEASE=20.04 DISTRIB_CODENAME=focal DISTRIB_DESCRIPTION="Ubuntu 20.04.5 LTS" ```
438
28
Connection error of the HuggingFace's dataset Hub due to SSLError with proxy ### Describe the bug It's weird. I could not normally connect the dataset Hub of HuggingFace due to a SSLError in my office. Even when I try to connect using my company's proxy address (e.g., http_proxy and https_proxy), I'm getting the SSLError issue. What should I do to download the datanet stored in HuggingFace normally? I welcome any comments. I think those comments will be helpful to me. * Dataset address - https://huggingface.co/datasets/moyix/debian_csrc/viewer/moyix--debian_csrc * Log message ``` ............ OMISSION .............. Traceback (most recent call last): File "/data/home/geunsik-lim/qtlab/./transformers/examples/pytorch/language-modeling/run_clm.py", line 587, in <module> main() File "/data/home/geunsik-lim/qtlab/./transformers/examples/pytorch/language-modeling/run_clm.py", line 278, in main raw_datasets = load_dataset( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1719, in load_dataset builder_instance = load_dataset_builder( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1497, in load_dataset_builder dataset_module = dataset_module_factory( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1222, in dataset_module_factory raise e1 from None File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1179, in dataset_module_factory raise ConnectionError(f"Couldn't reach '{path}' on the Hub ({type(e).__name__})") ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError) [2022-11-07 15:23:38,476] [INFO] [launch.py:318:sigkill_handler] Killing subprocess 6760 [2022-11-07 15:23:38,476] [ERROR] [launch.py:324:sigkill_handler] ['/home/geunsik-lim/anaconda3/envs/deepspeed/bin/python', '-u', './transformers/examples/pytorch/language-modeling/run_clm.py', '--local_rank=0', '--model_name_or_path=Salesforce/codegen-350M-multi', '--per_device_train_batch_size=1', '--learning_rate', '2e-5', '--num_train_epochs', '1', '--output_dir=./codegen-350M-finetuned', '--overwrite_output_dir', '--dataset_name', 'moyix/debian_csrc', '--cache_dir', '/data/home/geunsik-lim/.cache', '--tokenizer_name', 'Salesforce/codegen-350M-multi', '--block_size', '2048', '--gradient_accumulation_steps', '32', '--do_train', '--fp16', '--deepspeed', 'ds_config_zero2.json'] exits with return code = 1 real 0m7.742s user 0m4.930s ``` ### Steps to reproduce the bug Steps to reproduce this behavior. ``` (deepspeed) geunsik-lim@ai02:~/qtlab$ ./test_debian_csrc_dataset.py Traceback (most recent call last): File "/data/home/geunsik-lim/qtlab/./test_debian_csrc_dataset.py", line 6, in <module> dataset = load_dataset("moyix/debian_csrc") File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1719, in load_dataset builder_instance = load_dataset_builder( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1497, in load_dataset_builder dataset_module = dataset_module_factory( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1222, in dataset_module_factory raise e1 from None File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1179, in dataset_module_factory raise ConnectionError(f"Couldn't reach '{path}' on the Hub ({type(e).__name__})") ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError) (deepspeed) geunsik-lim@ai02:~/qtlab$ (deepspeed) geunsik-lim@ai02:~/qtlab$ (deepspeed) geunsik-lim@ai02:~/qtlab$ (deepspeed) geunsik-lim@ai02:~/qtlab$ cat ./test_debian_csrc_dataset.py #!/usr/bin/env python from datasets import load_dataset dataset = load_dataset("moyix/debian_csrc") ``` 1. Adde proxy address of a company in /etc/profile 2. Download dataset with load_dataset() function of datasets package that is provided by HuggingFace. 3. In this case, the address would be "moyix--debian_csrc". 4. I get the "`ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError`)" error message. ### Expected behavior * error message: ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError) ### Environment info * software version information: ``` (deepspeed) geunsik-lim@ai02:~$ (deepspeed) geunsik-lim@ai02:~$ conda list -f pytorch # packages in environment at /home/geunsik-lim/anaconda3/envs/deepspeed: # # Name Version Build Channel pytorch 1.13.0 py3.10_cuda11.7_cudnn8.5.0_0 pytorch (deepspeed) geunsik-lim@ai02:~$ conda list -f python # packages in environment at /home/geunsik-lim/anaconda3/envs/deepspeed: # # Name Version Build Channel python 3.10.6 haa1d7c7_1 (deepspeed) geunsik-lim@ai02:~$ conda list -f datasets # packages in environment at /home/geunsik-lim/anaconda3/envs/deepspeed: # # Name Version Build Channel datasets 2.6.1 py_0 huggingface (deepspeed) geunsik-lim@ai02:~$ uname -a Linux ai02 5.4.0-131-generic #147-Ubuntu SMP Fri Oct 14 17:07:22 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux (deepspeed) geunsik-lim@ai02:~$ cat /etc/lsb-release DISTRIB_ID=Ubuntu DISTRIB_RELEASE=20.04 DISTRIB_CODENAME=focal DISTRIB_DESCRIPTION="Ubuntu 20.04.5 LTS" ``` Hi ! It looks like an issue with your python environment, can you make sure you're able to run GET requests to https://huggingface.co using `requests` in python ?
[ -1.2101938724517822, -0.9848392009735107, -0.6463838219642639, 1.3610045909881592, -0.09259431064128876, -1.2543190717697144, 0.13538286089897156, -0.9358691573143005, 1.5802162885665894, -0.6993018388748169, 0.18023976683616638, -1.6747028827667236, -0.18417586386203766, -0.4960053563117981, -0.6286711096763611, -0.9252771735191345, -0.3985865116119385, -0.8789850473403931, 1.0254299640655518, 2.530298948287964, 1.266221046447754, -1.2969276905059814, 2.805175304412842, 0.6511660814285278, -0.20531319081783295, -1.0805259943008423, 0.5593867301940918, 0.07102074474096298, -1.2718101739883423, -0.4310920536518097, -0.9308435916900635, -0.00741206668317318, -0.5506141781806946, -0.42432647943496704, 0.1443902552127838, 0.4096880257129669, -0.25387468934059143, -0.35998496413230896, -0.6688349843025208, -0.7198262810707092, 0.5128029584884644, -0.33434128761291504, 0.9185602068901062, -0.3634459972381592, 1.6761783361434937, -0.600292980670929, 0.5399637222290039, 0.7416286468505859, 1.2766711711883545, 0.157023623585701, 0.09921001642942429, 0.24196843802928925, 0.45718324184417725, 0.0920686423778534, 0.5639286637306213, 1.2364999055862427, 0.6044960021972656, 0.4897504150867462, 0.5809116959571838, -2.2312734127044678, 1.2733315229415894, -0.833156406879425, 0.2782244384288788, 1.3331902027130127, -0.8512033224105835, 0.37776651978492737, -1.8559792041778564, -0.13974614441394806, 0.6241037249565125, -2.3138301372528076, 0.1460530012845993, -1.345330834388733, -0.5994529128074646, 0.8775726556777954, 0.32758817076683044, -1.1515437364578247, 0.16351456940174103, -0.5405865907669067, 1.0597742795944214, 0.5473578572273254, 1.2075157165527344, -1.6380376815795898, -0.05842793732881546, -0.09930671751499176, 0.09961128979921341, -1.2229857444763184, -1.6419204473495483, 0.6020138263702393, 0.623964786529541, 0.6639888882637024, -0.13402239978313446, 0.902113676071167, -1.0196586847305298, 0.8403614163398743, -0.921943724155426, -1.623733639717102, -1.43673574924469, -2.4208462238311768, -2.4227964878082275, 0.8413307666778564, -0.48788243532180786, -0.41753485798835754, 1.9787778854370117, -0.9790158867835999, -1.8349056243896484, 1.0496647357940674, 0.2826404273509979, 0.0948261171579361, 2.339967966079712, 0.2963159680366516, -0.7453152537345886, 0.45124366879463196, -0.7123053073883057, 0.7387742400169373, -0.30891621112823486, 1.3154641389846802, 0.4964520037174225, -0.9075322151184082, 1.5839773416519165, -0.4754719138145447, 0.5346035957336426, -0.6385346055030823, -0.48134511709213257, -0.7530764937400818, 0.22485525906085968, 1.90009343624115, -0.33567890524864197, 1.5732975006103516, -0.3303106427192688, -1.6014206409454346, -1.5826328992843628, 0.8092432618141174, 0.5102069973945618, -0.818970799446106, -0.019466478377580643, -0.5070441961288452, 0.23261116445064545, 0.0617339089512825, 1.0833910703659058, 1.2416359186172485, 0.7722309827804565, -0.3323046565055847, -0.8364039659500122, 0.24179254472255707, -0.15943995118141174, -0.6460431814193726, -1.8663921356201172, -0.29116788506507874, 0.2807075083255768, 0.6327033042907715, -1.2587414979934692, 1.734540581703186, 0.8652622699737549, 2.0775387287139893, 0.9935553669929504, -0.3738793730735779, 1.4822192192077637, 0.04954508692026138, 1.9431580305099487, -0.48535507917404175, 0.6066707372665405, -0.3363996744155884, -1.093932032585144, 0.7892741560935974, -0.3685470521450043, -1.991749882698059, -0.7231224775314331, -0.847476065158844, -0.16552825272083282, -0.7470046877861023, 0.915972113609314, -0.2519790232181549, -1.4050005674362183, 0.11658287048339844, -0.7078359127044678, 0.14379289746284485, -1.2697150707244873, 0.16970579326152802, 0.7346994876861572, -0.7368481755256653, 0.007386434823274612, -0.28139257431030273, -1.3813148736953735, -0.5134096145629883, 0.3638860881328583, 1.9437031745910645, -0.5980596542358398, 0.9344896674156189, 0.976900577545166, -0.784520149230957, 0.0952678844332695, 0.24971826374530792, -0.32141298055648804, 0.7205543518066406, -1.1007938385009766, -0.3305029273033142, 1.1537811756134033, -0.2799825668334961, -0.7015653252601624, 1.433353066444397, 0.8323634266853333, -1.048343300819397, -0.30110737681388855, -0.21266025304794312, -0.8434891104698181, -0.008939110673964024, -1.569558024406433, -0.2113167643547058, 0.30968955159187317, -1.4713935852050781, -0.4453803300857544, -0.24000708758831024, 1.3647958040237427, -0.15304701030254364, 1.4482595920562744, -0.2743191123008728, -0.20540837943553925, -0.3417135775089264, -0.4314921200275421, 0.2359715700149536, -0.25905123353004456, -0.6110643744468689, 0.21991345286369324, -0.9171579480171204, 0.24858234822750092, 1.5320059061050415, 0.3319348990917206, 0.03676220774650574, 0.49887725710868835, 1.058790683746338, 0.37779977917671204, -0.0725904032588005, -0.8494987487792969, -1.5580881834030151, 2.043576240539551, -1.4148190021514893, 1.8966516256332397, 0.6860719919204712, -0.10404862463474274, -1.844902753829956, -1.8770201206207275, 1.161267876625061, 1.019837498664856, 2.4735724925994873, 0.504600465297699, 0.4225270450115204, -0.7275466918945312, -0.7544103860855103, 0.30322813987731934, -0.8923482894897461, -0.7358286380767822, 0.18174776434898376, 2.354684829711914, 1.7802053689956665, -0.6334859728813171, -0.2213420271873474, -0.9219489693641663, 1.2588279247283936, -0.22724361717700958, 0.2797517478466034, 2.0653414726257324, -0.34672725200653076, -0.9282051920890808, 1.329399585723877, -2.3420753479003906, 0.314253032207489, 2.062631607055664, 0.2939664125442505, 0.12375102937221527, -1.5398575067520142, -0.6506750583648682, -0.29279717803001404, -0.4760562777519226, -1.2055679559707642, 0.6198215484619141, -0.3601400554180145, -0.9874690771102905, -1.4452238082885742, -0.003779920283704996, -1.1126996278762817, -1.7747029066085815, 0.31700506806373596, 1.9122331142425537, 2.0207669734954834, -0.7844468951225281, 1.3024810552597046, -0.22190742194652557, 0.031264737248420715, 1.3270342350006104, 1.2580658197402954, 3.1251723766326904, 1.9954344034194946, -1.244377851486206, 0.8388042449951172, -0.1758500188589096, -0.40927740931510925, 1.0763534307479858, -1.1066572666168213, 1.0901659727096558, -0.24116367101669312, -1.2654154300689697, -1.228888750076294, 1.1343066692352295, 0.545258104801178, -0.07393918931484222, -0.47284650802612305, 1.2851961851119995, 0.11195667088031769, 1.3914036750793457, 0.5809236764907837, -0.46803396940231323, 0.6160642504692078, -0.3343643248081207, -0.6155844330787659, 1.6932507753372192, 0.19172856211662292, -1.6242891550064087, -2.295448064804077, -0.2991616725921631, -1.004981279373169, -0.12246046960353851, -0.6197105050086975, -0.9563761353492737, 1.604910969734192, 0.4791000485420227, -1.2292146682739258, -0.219857320189476, -0.30000996589660645, -0.5639417767524719, 2.6922903060913086, -1.2744641304016113, -0.1587761640548706, -0.9372479915618896, -0.5327082872390747, 1.5891929864883423, -1.2240570783615112, -0.22004106640815735, -1.0574254989624023, -0.6614238619804382, -1.2614446878433228, -0.4952686131000519, 0.048112720251083374, -0.8925455212593079, 0.7178272008895874, 0.07201635837554932, -1.0519498586654663, -0.23036164045333862, -0.9065776467323303, 1.0907516479492188, -0.03391668573021889, 0.1806006282567978, 1.9309877157211304, 0.2997954189777374, -0.39509016275405884, 0.6387832164764404, 1.166185736656189, 0.588657021522522, -0.6758812069892883, 0.04944082349538803, -0.7216836810112, 0.29591432213783264, -1.4088406562805176, 0.17301493883132935, -2.9303505420684814, 0.7213566303253174, -0.13164053857326508, -0.18862922489643097, -0.0817440003156662, -1.2792123556137085, 1.096771240234375, 2.602665662765503, -1.1677626371383667, 0.5138667225837708, 0.4709905982017517, 1.118680477142334, -1.5230634212493896, 0.31883254647254944, -0.46271607279777527, 2.1025662422180176, 0.22581617534160614, 1.1643304824829102, -0.5320730209350586, -2.083970308303833, 0.6662347912788391, -1.1145086288452148, -1.0465697050094604, 0.7753913998603821, -0.8930227756500244, 0.2550831139087677, -1.4400606155395508, -0.15180061757564545, -0.9052006006240845, -1.2549748420715332, 0.6689123511314392, 0.12365543842315674, 0.4714145362377167, -0.5919266939163208, 0.39856722950935364, -2.1977667808532715, -1.3547680377960205, -0.2224193811416626, -1.0108156204223633, 0.5230529308319092, -0.32101985812187195, 0.599599301815033, -0.05451236665248871, 0.041711658239364624, 0.28557920455932617, 1.431061863899231, 3.3859264850616455, 0.1442875862121582, 0.12102675437927246, -0.0554683655500412, -1.0835407972335815, 1.448081374168396, 0.9233081340789795, -0.12457627058029175, -0.4855106770992279, -0.9963406920433044, 1.3020135164260864, 2.0627474784851074, 1.2284245491027832, 0.20865961909294128, -0.8637051582336426, -0.8437049388885498, 0.08279643952846527, 0.13301706314086914, 0.546917200088501, 0.9916512370109558, -0.049991145730018616, 0.12448941171169281, 1.436536192893982, 1.2274129390716553, -0.24234703183174133, 0.45929038524627686, -0.9979048371315002, -0.38358837366104126, 0.3695952594280243, 0.2483922690153122, 0.02852858416736126, 0.4030681848526001, -1.1724179983139038, -0.243775874376297, -0.2818835973739624, -0.8340128660202026, -0.7568509578704834, -0.3921731412410736, -0.4187728762626648, 1.5882070064544678, 0.16235022246837616, -0.5093159675598145, 0.06754458695650101, -0.6957557201385498, -0.11245029419660568, -1.0878310203552246, 0.24026788771152496, -0.08702076226472855, -0.03263659030199051, -0.1809389740228653, 1.6621038913726807, -0.9048901796340942, -2.2064759731292725, 0.19137148559093475, 0.2941451370716095, -0.408750057220459, 0.17310766875743866, 1.7232794761657715, 0.575240969657898, 1.348678708076477, 1.34182870388031, 1.0277857780456543, -0.5214507579803467, -1.2477277517318726, 0.7440639734268188, 0.8636590242385864, -1.400339961051941, 0.8900837898254395, -0.1968204230070114, -0.49254634976387024, 0.6882780194282532, 1.3137520551681519, 0.29059717059135437, -2.0828144550323486, 0.9499753713607788, -0.8319701552391052, 0.6803613901138306, 0.6941599249839783, 0.8330775499343872, 0.22894467413425446, 0.8574993014335632, -1.2451331615447998, -1.1235296726226807, -0.7495859265327454, -0.572376549243927, 1.8681137561798096, -0.14432233572006226, 0.5620013475418091, -0.2324371337890625, -1.2110430002212524, -0.07528283447027206, 0.7733743786811829, 0.35899147391319275, -0.4315747618675232, 0.9168691635131836, -0.6058486700057983, -1.0628750324249268, -1.2165154218673706, -0.4133034646511078, -1.0476559400558472, -0.8567384481430054, 0.9794536232948303, 0.7299903035163879, 0.5615618824958801, 1.8946986198425293, 0.5362038016319275, 0.3486790657043457, -2.7106480598449707, 0.8826967477798462, 0.2861660122871399, 0.008470961824059486, 0.8783252835273743, 0.2544199824333191, 1.1979392766952515, -0.09945198148488998, 0.5765464305877686, -2.3076775074005127, 2.1905360221862793, -0.26602309942245483, 0.6710407733917236, 0.036682598292827606, -0.13137145340442657, 1.0464459657669067, 0.6316334009170532, 0.6674495339393616, -1.154430627822876, 0.8008698225021362, -0.5652693510055542, 1.0742096900939941, 0.9655672311782837, -0.8490721583366394, 0.06020203232765198, 1.4150935411453247, 0.5122062563896179, -0.3738832473754883, -0.9780703186988831, -0.8600805401802063, 0.9179123044013977, 1.6804094314575195, -0.11309666931629181, -0.011029762215912342, 0.914372980594635, 0.609463095664978, -1.2993860244750977, 0.01722101680934429, -0.753664493560791, -0.5817071795463562, 1.729153037071228, 2.0180611610412598, -0.08539870381355286, -0.22433234751224518, -0.6936497092247009, -1.3153845071792603, 0.7081789374351501, -0.100128173828125, 0.039959922432899475, 0.7756526470184326, -0.6430738568305969, 1.068272590637207, 0.5351724624633789, 1.0309146642684937, 0.0002792375162243843, 0.3414400517940521, 0.2725507915019989, -0.37274080514907837, -1.2210400104522705, -0.3660553991794586, -1.062043309211731, -2.4605257511138916, 0.44597339630126953, -0.28047725558280945, -1.529068112373352, 0.11079179495573044, -1.016734004020691, 0.8569089770317078, -0.6029643416404724, -1.0659462213516235, -1.377393364906311, 0.337065726518631, -0.19359341263771057, 0.9087976217269897, -1.692196011543274, -0.1607421189546585, 1.2383592128753662, 0.8237171173095703, -0.5223172307014465, 0.974932849407196, 0.33063647150993347, 1.0053054094314575, 0.7762323021888733, -0.3915334939956665, 0.5029335021972656, 0.0026428643614053726, -1.3312065601348877, 0.3631543517112732, 1.1733226776123047, 0.2242339551448822, 1.3032537698745728, -0.5785112380981445, 0.14021791517734528, 0.43588903546333313, -0.6688278913497925, -0.4742282032966614, -0.38530147075653076, 0.7722625732421875, -0.08347965776920319, -1.0674980878829956, -0.14312197268009186, -0.14327672123908997, -0.23241524398326874, 0.2537137269973755, -1.422317624092102, -0.23922523856163025, -0.324656218290329, -0.4942038357257843, -1.3655717372894287, 0.04735906422138214, 1.2768436670303345, -0.9256664514541626, -0.1906023919582367, 0.4328668713569641, 0.34149062633514404, 0.6293171048164368, 0.5267755389213562, -0.7051588892936707, -0.1917072981595993, -0.3547005355358124, -0.25497546792030334, 0.21008048951625824, 1.2646876573562622, -0.056042663753032684, -1.037827968597412, 0.7112687230110168, -0.36700668931007385, 0.1743965893983841, 2.0898008346557617, 0.01882123202085495, -0.6858804225921631, 0.3025953769683838, -0.7078500390052795, 1.7495222091674805, 1.7270715236663818, 1.3228960037231445, -0.11705700308084488, -0.8095453381538391, 0.4207831919193268, -0.32627683877944946, -0.3100837767124176, 0.8376888632774353, 0.48213112354278564, -0.21957184374332428, -1.3386094570159912, 0.528097927570343, 1.3108603954315186, -0.834561824798584, -0.7658274173736572, 0.13702651858329773, -0.9070854187011719, 1.2553255558013916, 0.6848639249801636, 0.36747926473617554, 0.17951956391334534, 1.5198873281478882, 0.7240201830863953, -0.5055926442146301, 0.48101016879081726, 0.5938921570777893, -0.22542113065719604, -2.1318936347961426, -1.0050030946731567, 0.2666763365268707, -0.36359903216362, -1.6032044887542725, 1.3488402366638184, -1.1806944608688354, -1.0274051427841187, 0.5191311240196228, 0.19799916446208954, 1.3381623029708862, 0.36945194005966187, 1.7137683629989624, 2.136659622192383, 0.9157043099403381, 0.40599584579467773, 1.2704917192459106, -0.023741688579320908, -0.45977944135665894, 1.840864658355713, -0.3820706009864807, 0.605563223361969, 1.0157393217086792, -0.440067857503891, -1.049451470375061, -0.8634418249130249, -1.133239507675171, -0.5489416718482971, 1.1791335344314575, 0.11838933825492859, -1.0654003620147705, 0.19005154073238373, 1.5810335874557495, 0.07306818664073944, -0.28770509362220764, 0.7168276906013489, 0.3737070560455322, -0.6427023410797119, -0.050469256937503815, -0.8950226306915283, 0.49520620703697205, -0.11070451885461807, -0.29631733894348145, 0.21590621769428253, 0.5048563480377197, 1.269000768661499, -0.03388584777712822, 0.12012775242328644, 1.249561071395874, -1.3124167919158936, 1.5345638990402222, -0.5964063405990601, 0.2800378203392029, -2.418687105178833, 1.3795493841171265, -0.8087407350540161, 1.8364537954330444, -2.560482978820801, 0.450914591550827, -0.5275850892066956, -0.48665356636047363, 0.20063936710357666, -0.43682464957237244, 0.01652822270989418, -0.059560626745224, -1.0022931098937988, -0.025107603520154953, -0.7814114093780518, 0.5857306122779846, 1.1408171653747559, 1.4348269701004028, -1.1343231201171875, -0.3056958317756653, -1.7783968448638916, -0.22981463372707367, -0.8435412645339966, 0.4242849349975586, -1.8779150247573853, -0.15031902492046356, -1.950347661972046, -2.371351957321167, -1.379634976387024, -0.917955219745636, 1.0195949077606201, 0.12182950973510742, -0.9299824833869934, 1.1759635210037231, -0.34863319993019104, -1.9203864336013794, 1.099747896194458, -2.2218995094299316 ]
https://github.com/huggingface/datasets/issues/5207
Connection error of the HuggingFace's dataset Hub due to SSLError with proxy
Thanks for your reply. Does this mean that I have to use the `do_dataset `function and the `requests `function to download the dataset from the company's proxy environment? * Reference: ```bash ### How to load this dataset directly with the [datasets](https://github.com/huggingface/datasets) library * https://huggingface.co/datasets/moyix/debian_csrc * from datasets import load_dataset dataset = load_dataset("moyix/debian_csrc") ### Or just clone the dataset repo git lfs install git clone https://huggingface.co/datasets/moyix/debian_csrc # if you want to clone without large files – just their pointers # prepend your git clone with the following env var: GIT_LFS_SKIP_SMUDGE=1 ```
### Describe the bug It's weird. I could not normally connect the dataset Hub of HuggingFace due to a SSLError in my office. Even when I try to connect using my company's proxy address (e.g., http_proxy and https_proxy), I'm getting the SSLError issue. What should I do to download the datanet stored in HuggingFace normally? I welcome any comments. I think those comments will be helpful to me. * Dataset address - https://huggingface.co/datasets/moyix/debian_csrc/viewer/moyix--debian_csrc * Log message ``` ............ OMISSION .............. Traceback (most recent call last): File "/data/home/geunsik-lim/qtlab/./transformers/examples/pytorch/language-modeling/run_clm.py", line 587, in <module> main() File "/data/home/geunsik-lim/qtlab/./transformers/examples/pytorch/language-modeling/run_clm.py", line 278, in main raw_datasets = load_dataset( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1719, in load_dataset builder_instance = load_dataset_builder( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1497, in load_dataset_builder dataset_module = dataset_module_factory( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1222, in dataset_module_factory raise e1 from None File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1179, in dataset_module_factory raise ConnectionError(f"Couldn't reach '{path}' on the Hub ({type(e).__name__})") ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError) [2022-11-07 15:23:38,476] [INFO] [launch.py:318:sigkill_handler] Killing subprocess 6760 [2022-11-07 15:23:38,476] [ERROR] [launch.py:324:sigkill_handler] ['/home/geunsik-lim/anaconda3/envs/deepspeed/bin/python', '-u', './transformers/examples/pytorch/language-modeling/run_clm.py', '--local_rank=0', '--model_name_or_path=Salesforce/codegen-350M-multi', '--per_device_train_batch_size=1', '--learning_rate', '2e-5', '--num_train_epochs', '1', '--output_dir=./codegen-350M-finetuned', '--overwrite_output_dir', '--dataset_name', 'moyix/debian_csrc', '--cache_dir', '/data/home/geunsik-lim/.cache', '--tokenizer_name', 'Salesforce/codegen-350M-multi', '--block_size', '2048', '--gradient_accumulation_steps', '32', '--do_train', '--fp16', '--deepspeed', 'ds_config_zero2.json'] exits with return code = 1 real 0m7.742s user 0m4.930s ``` ### Steps to reproduce the bug Steps to reproduce this behavior. ``` (deepspeed) geunsik-lim@ai02:~/qtlab$ ./test_debian_csrc_dataset.py Traceback (most recent call last): File "/data/home/geunsik-lim/qtlab/./test_debian_csrc_dataset.py", line 6, in <module> dataset = load_dataset("moyix/debian_csrc") File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1719, in load_dataset builder_instance = load_dataset_builder( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1497, in load_dataset_builder dataset_module = dataset_module_factory( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1222, in dataset_module_factory raise e1 from None File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1179, in dataset_module_factory raise ConnectionError(f"Couldn't reach '{path}' on the Hub ({type(e).__name__})") ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError) (deepspeed) geunsik-lim@ai02:~/qtlab$ (deepspeed) geunsik-lim@ai02:~/qtlab$ (deepspeed) geunsik-lim@ai02:~/qtlab$ (deepspeed) geunsik-lim@ai02:~/qtlab$ cat ./test_debian_csrc_dataset.py #!/usr/bin/env python from datasets import load_dataset dataset = load_dataset("moyix/debian_csrc") ``` 1. Adde proxy address of a company in /etc/profile 2. Download dataset with load_dataset() function of datasets package that is provided by HuggingFace. 3. In this case, the address would be "moyix--debian_csrc". 4. I get the "`ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError`)" error message. ### Expected behavior * error message: ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError) ### Environment info * software version information: ``` (deepspeed) geunsik-lim@ai02:~$ (deepspeed) geunsik-lim@ai02:~$ conda list -f pytorch # packages in environment at /home/geunsik-lim/anaconda3/envs/deepspeed: # # Name Version Build Channel pytorch 1.13.0 py3.10_cuda11.7_cudnn8.5.0_0 pytorch (deepspeed) geunsik-lim@ai02:~$ conda list -f python # packages in environment at /home/geunsik-lim/anaconda3/envs/deepspeed: # # Name Version Build Channel python 3.10.6 haa1d7c7_1 (deepspeed) geunsik-lim@ai02:~$ conda list -f datasets # packages in environment at /home/geunsik-lim/anaconda3/envs/deepspeed: # # Name Version Build Channel datasets 2.6.1 py_0 huggingface (deepspeed) geunsik-lim@ai02:~$ uname -a Linux ai02 5.4.0-131-generic #147-Ubuntu SMP Fri Oct 14 17:07:22 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux (deepspeed) geunsik-lim@ai02:~$ cat /etc/lsb-release DISTRIB_ID=Ubuntu DISTRIB_RELEASE=20.04 DISTRIB_CODENAME=focal DISTRIB_DESCRIPTION="Ubuntu 20.04.5 LTS" ```
438
90
Connection error of the HuggingFace's dataset Hub due to SSLError with proxy ### Describe the bug It's weird. I could not normally connect the dataset Hub of HuggingFace due to a SSLError in my office. Even when I try to connect using my company's proxy address (e.g., http_proxy and https_proxy), I'm getting the SSLError issue. What should I do to download the datanet stored in HuggingFace normally? I welcome any comments. I think those comments will be helpful to me. * Dataset address - https://huggingface.co/datasets/moyix/debian_csrc/viewer/moyix--debian_csrc * Log message ``` ............ OMISSION .............. Traceback (most recent call last): File "/data/home/geunsik-lim/qtlab/./transformers/examples/pytorch/language-modeling/run_clm.py", line 587, in <module> main() File "/data/home/geunsik-lim/qtlab/./transformers/examples/pytorch/language-modeling/run_clm.py", line 278, in main raw_datasets = load_dataset( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1719, in load_dataset builder_instance = load_dataset_builder( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1497, in load_dataset_builder dataset_module = dataset_module_factory( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1222, in dataset_module_factory raise e1 from None File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1179, in dataset_module_factory raise ConnectionError(f"Couldn't reach '{path}' on the Hub ({type(e).__name__})") ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError) [2022-11-07 15:23:38,476] [INFO] [launch.py:318:sigkill_handler] Killing subprocess 6760 [2022-11-07 15:23:38,476] [ERROR] [launch.py:324:sigkill_handler] ['/home/geunsik-lim/anaconda3/envs/deepspeed/bin/python', '-u', './transformers/examples/pytorch/language-modeling/run_clm.py', '--local_rank=0', '--model_name_or_path=Salesforce/codegen-350M-multi', '--per_device_train_batch_size=1', '--learning_rate', '2e-5', '--num_train_epochs', '1', '--output_dir=./codegen-350M-finetuned', '--overwrite_output_dir', '--dataset_name', 'moyix/debian_csrc', '--cache_dir', '/data/home/geunsik-lim/.cache', '--tokenizer_name', 'Salesforce/codegen-350M-multi', '--block_size', '2048', '--gradient_accumulation_steps', '32', '--do_train', '--fp16', '--deepspeed', 'ds_config_zero2.json'] exits with return code = 1 real 0m7.742s user 0m4.930s ``` ### Steps to reproduce the bug Steps to reproduce this behavior. ``` (deepspeed) geunsik-lim@ai02:~/qtlab$ ./test_debian_csrc_dataset.py Traceback (most recent call last): File "/data/home/geunsik-lim/qtlab/./test_debian_csrc_dataset.py", line 6, in <module> dataset = load_dataset("moyix/debian_csrc") File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1719, in load_dataset builder_instance = load_dataset_builder( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1497, in load_dataset_builder dataset_module = dataset_module_factory( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1222, in dataset_module_factory raise e1 from None File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1179, in dataset_module_factory raise ConnectionError(f"Couldn't reach '{path}' on the Hub ({type(e).__name__})") ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError) (deepspeed) geunsik-lim@ai02:~/qtlab$ (deepspeed) geunsik-lim@ai02:~/qtlab$ (deepspeed) geunsik-lim@ai02:~/qtlab$ (deepspeed) geunsik-lim@ai02:~/qtlab$ cat ./test_debian_csrc_dataset.py #!/usr/bin/env python from datasets import load_dataset dataset = load_dataset("moyix/debian_csrc") ``` 1. Adde proxy address of a company in /etc/profile 2. Download dataset with load_dataset() function of datasets package that is provided by HuggingFace. 3. In this case, the address would be "moyix--debian_csrc". 4. I get the "`ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError`)" error message. ### Expected behavior * error message: ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError) ### Environment info * software version information: ``` (deepspeed) geunsik-lim@ai02:~$ (deepspeed) geunsik-lim@ai02:~$ conda list -f pytorch # packages in environment at /home/geunsik-lim/anaconda3/envs/deepspeed: # # Name Version Build Channel pytorch 1.13.0 py3.10_cuda11.7_cudnn8.5.0_0 pytorch (deepspeed) geunsik-lim@ai02:~$ conda list -f python # packages in environment at /home/geunsik-lim/anaconda3/envs/deepspeed: # # Name Version Build Channel python 3.10.6 haa1d7c7_1 (deepspeed) geunsik-lim@ai02:~$ conda list -f datasets # packages in environment at /home/geunsik-lim/anaconda3/envs/deepspeed: # # Name Version Build Channel datasets 2.6.1 py_0 huggingface (deepspeed) geunsik-lim@ai02:~$ uname -a Linux ai02 5.4.0-131-generic #147-Ubuntu SMP Fri Oct 14 17:07:22 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux (deepspeed) geunsik-lim@ai02:~$ cat /etc/lsb-release DISTRIB_ID=Ubuntu DISTRIB_RELEASE=20.04 DISTRIB_CODENAME=focal DISTRIB_DESCRIPTION="Ubuntu 20.04.5 LTS" ``` Thanks for your reply. Does this mean that I have to use the `do_dataset `function and the `requests `function to download the dataset from the company's proxy environment? * Reference: ```bash ### How to load this dataset directly with the [datasets](https://github.com/huggingface/datasets) library * https://huggingface.co/datasets/moyix/debian_csrc * from datasets import load_dataset dataset = load_dataset("moyix/debian_csrc") ### Or just clone the dataset repo git lfs install git clone https://huggingface.co/datasets/moyix/debian_csrc # if you want to clone without large files – just their pointers # prepend your git clone with the following env var: GIT_LFS_SKIP_SMUDGE=1 ```
[ -1.2101938724517822, -0.9848392009735107, -0.6463838219642639, 1.3610045909881592, -0.09259431064128876, -1.2543190717697144, 0.13538286089897156, -0.9358691573143005, 1.5802162885665894, -0.6993018388748169, 0.18023976683616638, -1.6747028827667236, -0.18417586386203766, -0.4960053563117981, -0.6286711096763611, -0.9252771735191345, -0.3985865116119385, -0.8789850473403931, 1.0254299640655518, 2.530298948287964, 1.266221046447754, -1.2969276905059814, 2.805175304412842, 0.6511660814285278, -0.20531319081783295, -1.0805259943008423, 0.5593867301940918, 0.07102074474096298, -1.2718101739883423, -0.4310920536518097, -0.9308435916900635, -0.00741206668317318, -0.5506141781806946, -0.42432647943496704, 0.1443902552127838, 0.4096880257129669, -0.25387468934059143, -0.35998496413230896, -0.6688349843025208, -0.7198262810707092, 0.5128029584884644, -0.33434128761291504, 0.9185602068901062, -0.3634459972381592, 1.6761783361434937, -0.600292980670929, 0.5399637222290039, 0.7416286468505859, 1.2766711711883545, 0.157023623585701, 0.09921001642942429, 0.24196843802928925, 0.45718324184417725, 0.0920686423778534, 0.5639286637306213, 1.2364999055862427, 0.6044960021972656, 0.4897504150867462, 0.5809116959571838, -2.2312734127044678, 1.2733315229415894, -0.833156406879425, 0.2782244384288788, 1.3331902027130127, -0.8512033224105835, 0.37776651978492737, -1.8559792041778564, -0.13974614441394806, 0.6241037249565125, -2.3138301372528076, 0.1460530012845993, -1.345330834388733, -0.5994529128074646, 0.8775726556777954, 0.32758817076683044, -1.1515437364578247, 0.16351456940174103, -0.5405865907669067, 1.0597742795944214, 0.5473578572273254, 1.2075157165527344, -1.6380376815795898, -0.05842793732881546, -0.09930671751499176, 0.09961128979921341, -1.2229857444763184, -1.6419204473495483, 0.6020138263702393, 0.623964786529541, 0.6639888882637024, -0.13402239978313446, 0.902113676071167, -1.0196586847305298, 0.8403614163398743, -0.921943724155426, -1.623733639717102, -1.43673574924469, -2.4208462238311768, -2.4227964878082275, 0.8413307666778564, -0.48788243532180786, -0.41753485798835754, 1.9787778854370117, -0.9790158867835999, -1.8349056243896484, 1.0496647357940674, 0.2826404273509979, 0.0948261171579361, 2.339967966079712, 0.2963159680366516, -0.7453152537345886, 0.45124366879463196, -0.7123053073883057, 0.7387742400169373, -0.30891621112823486, 1.3154641389846802, 0.4964520037174225, -0.9075322151184082, 1.5839773416519165, -0.4754719138145447, 0.5346035957336426, -0.6385346055030823, -0.48134511709213257, -0.7530764937400818, 0.22485525906085968, 1.90009343624115, -0.33567890524864197, 1.5732975006103516, -0.3303106427192688, -1.6014206409454346, -1.5826328992843628, 0.8092432618141174, 0.5102069973945618, -0.818970799446106, -0.019466478377580643, -0.5070441961288452, 0.23261116445064545, 0.0617339089512825, 1.0833910703659058, 1.2416359186172485, 0.7722309827804565, -0.3323046565055847, -0.8364039659500122, 0.24179254472255707, -0.15943995118141174, -0.6460431814193726, -1.8663921356201172, -0.29116788506507874, 0.2807075083255768, 0.6327033042907715, -1.2587414979934692, 1.734540581703186, 0.8652622699737549, 2.0775387287139893, 0.9935553669929504, -0.3738793730735779, 1.4822192192077637, 0.04954508692026138, 1.9431580305099487, -0.48535507917404175, 0.6066707372665405, -0.3363996744155884, -1.093932032585144, 0.7892741560935974, -0.3685470521450043, -1.991749882698059, -0.7231224775314331, -0.847476065158844, -0.16552825272083282, -0.7470046877861023, 0.915972113609314, -0.2519790232181549, -1.4050005674362183, 0.11658287048339844, -0.7078359127044678, 0.14379289746284485, -1.2697150707244873, 0.16970579326152802, 0.7346994876861572, -0.7368481755256653, 0.007386434823274612, -0.28139257431030273, -1.3813148736953735, -0.5134096145629883, 0.3638860881328583, 1.9437031745910645, -0.5980596542358398, 0.9344896674156189, 0.976900577545166, -0.784520149230957, 0.0952678844332695, 0.24971826374530792, -0.32141298055648804, 0.7205543518066406, -1.1007938385009766, -0.3305029273033142, 1.1537811756134033, -0.2799825668334961, -0.7015653252601624, 1.433353066444397, 0.8323634266853333, -1.048343300819397, -0.30110737681388855, -0.21266025304794312, -0.8434891104698181, -0.008939110673964024, -1.569558024406433, -0.2113167643547058, 0.30968955159187317, -1.4713935852050781, -0.4453803300857544, -0.24000708758831024, 1.3647958040237427, -0.15304701030254364, 1.4482595920562744, -0.2743191123008728, -0.20540837943553925, -0.3417135775089264, -0.4314921200275421, 0.2359715700149536, -0.25905123353004456, -0.6110643744468689, 0.21991345286369324, -0.9171579480171204, 0.24858234822750092, 1.5320059061050415, 0.3319348990917206, 0.03676220774650574, 0.49887725710868835, 1.058790683746338, 0.37779977917671204, -0.0725904032588005, -0.8494987487792969, -1.5580881834030151, 2.043576240539551, -1.4148190021514893, 1.8966516256332397, 0.6860719919204712, -0.10404862463474274, -1.844902753829956, -1.8770201206207275, 1.161267876625061, 1.019837498664856, 2.4735724925994873, 0.504600465297699, 0.4225270450115204, -0.7275466918945312, -0.7544103860855103, 0.30322813987731934, -0.8923482894897461, -0.7358286380767822, 0.18174776434898376, 2.354684829711914, 1.7802053689956665, -0.6334859728813171, -0.2213420271873474, -0.9219489693641663, 1.2588279247283936, -0.22724361717700958, 0.2797517478466034, 2.0653414726257324, -0.34672725200653076, -0.9282051920890808, 1.329399585723877, -2.3420753479003906, 0.314253032207489, 2.062631607055664, 0.2939664125442505, 0.12375102937221527, -1.5398575067520142, -0.6506750583648682, -0.29279717803001404, -0.4760562777519226, -1.2055679559707642, 0.6198215484619141, -0.3601400554180145, -0.9874690771102905, -1.4452238082885742, -0.003779920283704996, -1.1126996278762817, -1.7747029066085815, 0.31700506806373596, 1.9122331142425537, 2.0207669734954834, -0.7844468951225281, 1.3024810552597046, -0.22190742194652557, 0.031264737248420715, 1.3270342350006104, 1.2580658197402954, 3.1251723766326904, 1.9954344034194946, -1.244377851486206, 0.8388042449951172, -0.1758500188589096, -0.40927740931510925, 1.0763534307479858, -1.1066572666168213, 1.0901659727096558, -0.24116367101669312, -1.2654154300689697, -1.228888750076294, 1.1343066692352295, 0.545258104801178, -0.07393918931484222, -0.47284650802612305, 1.2851961851119995, 0.11195667088031769, 1.3914036750793457, 0.5809236764907837, -0.46803396940231323, 0.6160642504692078, -0.3343643248081207, -0.6155844330787659, 1.6932507753372192, 0.19172856211662292, -1.6242891550064087, -2.295448064804077, -0.2991616725921631, -1.004981279373169, -0.12246046960353851, -0.6197105050086975, -0.9563761353492737, 1.604910969734192, 0.4791000485420227, -1.2292146682739258, -0.219857320189476, -0.30000996589660645, -0.5639417767524719, 2.6922903060913086, -1.2744641304016113, -0.1587761640548706, -0.9372479915618896, -0.5327082872390747, 1.5891929864883423, -1.2240570783615112, -0.22004106640815735, -1.0574254989624023, -0.6614238619804382, -1.2614446878433228, -0.4952686131000519, 0.048112720251083374, -0.8925455212593079, 0.7178272008895874, 0.07201635837554932, -1.0519498586654663, -0.23036164045333862, -0.9065776467323303, 1.0907516479492188, -0.03391668573021889, 0.1806006282567978, 1.9309877157211304, 0.2997954189777374, -0.39509016275405884, 0.6387832164764404, 1.166185736656189, 0.588657021522522, -0.6758812069892883, 0.04944082349538803, -0.7216836810112, 0.29591432213783264, -1.4088406562805176, 0.17301493883132935, -2.9303505420684814, 0.7213566303253174, -0.13164053857326508, -0.18862922489643097, -0.0817440003156662, -1.2792123556137085, 1.096771240234375, 2.602665662765503, -1.1677626371383667, 0.5138667225837708, 0.4709905982017517, 1.118680477142334, -1.5230634212493896, 0.31883254647254944, -0.46271607279777527, 2.1025662422180176, 0.22581617534160614, 1.1643304824829102, -0.5320730209350586, -2.083970308303833, 0.6662347912788391, -1.1145086288452148, -1.0465697050094604, 0.7753913998603821, -0.8930227756500244, 0.2550831139087677, -1.4400606155395508, -0.15180061757564545, -0.9052006006240845, -1.2549748420715332, 0.6689123511314392, 0.12365543842315674, 0.4714145362377167, -0.5919266939163208, 0.39856722950935364, -2.1977667808532715, -1.3547680377960205, -0.2224193811416626, -1.0108156204223633, 0.5230529308319092, -0.32101985812187195, 0.599599301815033, -0.05451236665248871, 0.041711658239364624, 0.28557920455932617, 1.431061863899231, 3.3859264850616455, 0.1442875862121582, 0.12102675437927246, -0.0554683655500412, -1.0835407972335815, 1.448081374168396, 0.9233081340789795, -0.12457627058029175, -0.4855106770992279, -0.9963406920433044, 1.3020135164260864, 2.0627474784851074, 1.2284245491027832, 0.20865961909294128, -0.8637051582336426, -0.8437049388885498, 0.08279643952846527, 0.13301706314086914, 0.546917200088501, 0.9916512370109558, -0.049991145730018616, 0.12448941171169281, 1.436536192893982, 1.2274129390716553, -0.24234703183174133, 0.45929038524627686, -0.9979048371315002, -0.38358837366104126, 0.3695952594280243, 0.2483922690153122, 0.02852858416736126, 0.4030681848526001, -1.1724179983139038, -0.243775874376297, -0.2818835973739624, -0.8340128660202026, -0.7568509578704834, -0.3921731412410736, -0.4187728762626648, 1.5882070064544678, 0.16235022246837616, -0.5093159675598145, 0.06754458695650101, -0.6957557201385498, -0.11245029419660568, -1.0878310203552246, 0.24026788771152496, -0.08702076226472855, -0.03263659030199051, -0.1809389740228653, 1.6621038913726807, -0.9048901796340942, -2.2064759731292725, 0.19137148559093475, 0.2941451370716095, -0.408750057220459, 0.17310766875743866, 1.7232794761657715, 0.575240969657898, 1.348678708076477, 1.34182870388031, 1.0277857780456543, -0.5214507579803467, -1.2477277517318726, 0.7440639734268188, 0.8636590242385864, -1.400339961051941, 0.8900837898254395, -0.1968204230070114, -0.49254634976387024, 0.6882780194282532, 1.3137520551681519, 0.29059717059135437, -2.0828144550323486, 0.9499753713607788, -0.8319701552391052, 0.6803613901138306, 0.6941599249839783, 0.8330775499343872, 0.22894467413425446, 0.8574993014335632, -1.2451331615447998, -1.1235296726226807, -0.7495859265327454, -0.572376549243927, 1.8681137561798096, -0.14432233572006226, 0.5620013475418091, -0.2324371337890625, -1.2110430002212524, -0.07528283447027206, 0.7733743786811829, 0.35899147391319275, -0.4315747618675232, 0.9168691635131836, -0.6058486700057983, -1.0628750324249268, -1.2165154218673706, -0.4133034646511078, -1.0476559400558472, -0.8567384481430054, 0.9794536232948303, 0.7299903035163879, 0.5615618824958801, 1.8946986198425293, 0.5362038016319275, 0.3486790657043457, -2.7106480598449707, 0.8826967477798462, 0.2861660122871399, 0.008470961824059486, 0.8783252835273743, 0.2544199824333191, 1.1979392766952515, -0.09945198148488998, 0.5765464305877686, -2.3076775074005127, 2.1905360221862793, -0.26602309942245483, 0.6710407733917236, 0.036682598292827606, -0.13137145340442657, 1.0464459657669067, 0.6316334009170532, 0.6674495339393616, -1.154430627822876, 0.8008698225021362, -0.5652693510055542, 1.0742096900939941, 0.9655672311782837, -0.8490721583366394, 0.06020203232765198, 1.4150935411453247, 0.5122062563896179, -0.3738832473754883, -0.9780703186988831, -0.8600805401802063, 0.9179123044013977, 1.6804094314575195, -0.11309666931629181, -0.011029762215912342, 0.914372980594635, 0.609463095664978, -1.2993860244750977, 0.01722101680934429, -0.753664493560791, -0.5817071795463562, 1.729153037071228, 2.0180611610412598, -0.08539870381355286, -0.22433234751224518, -0.6936497092247009, -1.3153845071792603, 0.7081789374351501, -0.100128173828125, 0.039959922432899475, 0.7756526470184326, -0.6430738568305969, 1.068272590637207, 0.5351724624633789, 1.0309146642684937, 0.0002792375162243843, 0.3414400517940521, 0.2725507915019989, -0.37274080514907837, -1.2210400104522705, -0.3660553991794586, -1.062043309211731, -2.4605257511138916, 0.44597339630126953, -0.28047725558280945, -1.529068112373352, 0.11079179495573044, -1.016734004020691, 0.8569089770317078, -0.6029643416404724, -1.0659462213516235, -1.377393364906311, 0.337065726518631, -0.19359341263771057, 0.9087976217269897, -1.692196011543274, -0.1607421189546585, 1.2383592128753662, 0.8237171173095703, -0.5223172307014465, 0.974932849407196, 0.33063647150993347, 1.0053054094314575, 0.7762323021888733, -0.3915334939956665, 0.5029335021972656, 0.0026428643614053726, -1.3312065601348877, 0.3631543517112732, 1.1733226776123047, 0.2242339551448822, 1.3032537698745728, -0.5785112380981445, 0.14021791517734528, 0.43588903546333313, -0.6688278913497925, -0.4742282032966614, -0.38530147075653076, 0.7722625732421875, -0.08347965776920319, -1.0674980878829956, -0.14312197268009186, -0.14327672123908997, -0.23241524398326874, 0.2537137269973755, -1.422317624092102, -0.23922523856163025, -0.324656218290329, -0.4942038357257843, -1.3655717372894287, 0.04735906422138214, 1.2768436670303345, -0.9256664514541626, -0.1906023919582367, 0.4328668713569641, 0.34149062633514404, 0.6293171048164368, 0.5267755389213562, -0.7051588892936707, -0.1917072981595993, -0.3547005355358124, -0.25497546792030334, 0.21008048951625824, 1.2646876573562622, -0.056042663753032684, -1.037827968597412, 0.7112687230110168, -0.36700668931007385, 0.1743965893983841, 2.0898008346557617, 0.01882123202085495, -0.6858804225921631, 0.3025953769683838, -0.7078500390052795, 1.7495222091674805, 1.7270715236663818, 1.3228960037231445, -0.11705700308084488, -0.8095453381538391, 0.4207831919193268, -0.32627683877944946, -0.3100837767124176, 0.8376888632774353, 0.48213112354278564, -0.21957184374332428, -1.3386094570159912, 0.528097927570343, 1.3108603954315186, -0.834561824798584, -0.7658274173736572, 0.13702651858329773, -0.9070854187011719, 1.2553255558013916, 0.6848639249801636, 0.36747926473617554, 0.17951956391334534, 1.5198873281478882, 0.7240201830863953, -0.5055926442146301, 0.48101016879081726, 0.5938921570777893, -0.22542113065719604, -2.1318936347961426, -1.0050030946731567, 0.2666763365268707, -0.36359903216362, -1.6032044887542725, 1.3488402366638184, -1.1806944608688354, -1.0274051427841187, 0.5191311240196228, 0.19799916446208954, 1.3381623029708862, 0.36945194005966187, 1.7137683629989624, 2.136659622192383, 0.9157043099403381, 0.40599584579467773, 1.2704917192459106, -0.023741688579320908, -0.45977944135665894, 1.840864658355713, -0.3820706009864807, 0.605563223361969, 1.0157393217086792, -0.440067857503891, -1.049451470375061, -0.8634418249130249, -1.133239507675171, -0.5489416718482971, 1.1791335344314575, 0.11838933825492859, -1.0654003620147705, 0.19005154073238373, 1.5810335874557495, 0.07306818664073944, -0.28770509362220764, 0.7168276906013489, 0.3737070560455322, -0.6427023410797119, -0.050469256937503815, -0.8950226306915283, 0.49520620703697205, -0.11070451885461807, -0.29631733894348145, 0.21590621769428253, 0.5048563480377197, 1.269000768661499, -0.03388584777712822, 0.12012775242328644, 1.249561071395874, -1.3124167919158936, 1.5345638990402222, -0.5964063405990601, 0.2800378203392029, -2.418687105178833, 1.3795493841171265, -0.8087407350540161, 1.8364537954330444, -2.560482978820801, 0.450914591550827, -0.5275850892066956, -0.48665356636047363, 0.20063936710357666, -0.43682464957237244, 0.01652822270989418, -0.059560626745224, -1.0022931098937988, -0.025107603520154953, -0.7814114093780518, 0.5857306122779846, 1.1408171653747559, 1.4348269701004028, -1.1343231201171875, -0.3056958317756653, -1.7783968448638916, -0.22981463372707367, -0.8435412645339966, 0.4242849349975586, -1.8779150247573853, -0.15031902492046356, -1.950347661972046, -2.371351957321167, -1.379634976387024, -0.917955219745636, 1.0195949077606201, 0.12182950973510742, -0.9299824833869934, 1.1759635210037231, -0.34863319993019104, -1.9203864336013794, 1.099747896194458, -2.2218995094299316 ]
https://github.com/huggingface/datasets/issues/5207
Connection error of the HuggingFace's dataset Hub due to SSLError with proxy
You can use `requests` to see if downloading a file from the Hugging Face Hub works. If so, then `datasets` should work as well. If not, then you have to find another way using an internet connection that works
### Describe the bug It's weird. I could not normally connect the dataset Hub of HuggingFace due to a SSLError in my office. Even when I try to connect using my company's proxy address (e.g., http_proxy and https_proxy), I'm getting the SSLError issue. What should I do to download the datanet stored in HuggingFace normally? I welcome any comments. I think those comments will be helpful to me. * Dataset address - https://huggingface.co/datasets/moyix/debian_csrc/viewer/moyix--debian_csrc * Log message ``` ............ OMISSION .............. Traceback (most recent call last): File "/data/home/geunsik-lim/qtlab/./transformers/examples/pytorch/language-modeling/run_clm.py", line 587, in <module> main() File "/data/home/geunsik-lim/qtlab/./transformers/examples/pytorch/language-modeling/run_clm.py", line 278, in main raw_datasets = load_dataset( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1719, in load_dataset builder_instance = load_dataset_builder( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1497, in load_dataset_builder dataset_module = dataset_module_factory( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1222, in dataset_module_factory raise e1 from None File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1179, in dataset_module_factory raise ConnectionError(f"Couldn't reach '{path}' on the Hub ({type(e).__name__})") ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError) [2022-11-07 15:23:38,476] [INFO] [launch.py:318:sigkill_handler] Killing subprocess 6760 [2022-11-07 15:23:38,476] [ERROR] [launch.py:324:sigkill_handler] ['/home/geunsik-lim/anaconda3/envs/deepspeed/bin/python', '-u', './transformers/examples/pytorch/language-modeling/run_clm.py', '--local_rank=0', '--model_name_or_path=Salesforce/codegen-350M-multi', '--per_device_train_batch_size=1', '--learning_rate', '2e-5', '--num_train_epochs', '1', '--output_dir=./codegen-350M-finetuned', '--overwrite_output_dir', '--dataset_name', 'moyix/debian_csrc', '--cache_dir', '/data/home/geunsik-lim/.cache', '--tokenizer_name', 'Salesforce/codegen-350M-multi', '--block_size', '2048', '--gradient_accumulation_steps', '32', '--do_train', '--fp16', '--deepspeed', 'ds_config_zero2.json'] exits with return code = 1 real 0m7.742s user 0m4.930s ``` ### Steps to reproduce the bug Steps to reproduce this behavior. ``` (deepspeed) geunsik-lim@ai02:~/qtlab$ ./test_debian_csrc_dataset.py Traceback (most recent call last): File "/data/home/geunsik-lim/qtlab/./test_debian_csrc_dataset.py", line 6, in <module> dataset = load_dataset("moyix/debian_csrc") File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1719, in load_dataset builder_instance = load_dataset_builder( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1497, in load_dataset_builder dataset_module = dataset_module_factory( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1222, in dataset_module_factory raise e1 from None File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1179, in dataset_module_factory raise ConnectionError(f"Couldn't reach '{path}' on the Hub ({type(e).__name__})") ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError) (deepspeed) geunsik-lim@ai02:~/qtlab$ (deepspeed) geunsik-lim@ai02:~/qtlab$ (deepspeed) geunsik-lim@ai02:~/qtlab$ (deepspeed) geunsik-lim@ai02:~/qtlab$ cat ./test_debian_csrc_dataset.py #!/usr/bin/env python from datasets import load_dataset dataset = load_dataset("moyix/debian_csrc") ``` 1. Adde proxy address of a company in /etc/profile 2. Download dataset with load_dataset() function of datasets package that is provided by HuggingFace. 3. In this case, the address would be "moyix--debian_csrc". 4. I get the "`ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError`)" error message. ### Expected behavior * error message: ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError) ### Environment info * software version information: ``` (deepspeed) geunsik-lim@ai02:~$ (deepspeed) geunsik-lim@ai02:~$ conda list -f pytorch # packages in environment at /home/geunsik-lim/anaconda3/envs/deepspeed: # # Name Version Build Channel pytorch 1.13.0 py3.10_cuda11.7_cudnn8.5.0_0 pytorch (deepspeed) geunsik-lim@ai02:~$ conda list -f python # packages in environment at /home/geunsik-lim/anaconda3/envs/deepspeed: # # Name Version Build Channel python 3.10.6 haa1d7c7_1 (deepspeed) geunsik-lim@ai02:~$ conda list -f datasets # packages in environment at /home/geunsik-lim/anaconda3/envs/deepspeed: # # Name Version Build Channel datasets 2.6.1 py_0 huggingface (deepspeed) geunsik-lim@ai02:~$ uname -a Linux ai02 5.4.0-131-generic #147-Ubuntu SMP Fri Oct 14 17:07:22 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux (deepspeed) geunsik-lim@ai02:~$ cat /etc/lsb-release DISTRIB_ID=Ubuntu DISTRIB_RELEASE=20.04 DISTRIB_CODENAME=focal DISTRIB_DESCRIPTION="Ubuntu 20.04.5 LTS" ```
438
39
Connection error of the HuggingFace's dataset Hub due to SSLError with proxy ### Describe the bug It's weird. I could not normally connect the dataset Hub of HuggingFace due to a SSLError in my office. Even when I try to connect using my company's proxy address (e.g., http_proxy and https_proxy), I'm getting the SSLError issue. What should I do to download the datanet stored in HuggingFace normally? I welcome any comments. I think those comments will be helpful to me. * Dataset address - https://huggingface.co/datasets/moyix/debian_csrc/viewer/moyix--debian_csrc * Log message ``` ............ OMISSION .............. Traceback (most recent call last): File "/data/home/geunsik-lim/qtlab/./transformers/examples/pytorch/language-modeling/run_clm.py", line 587, in <module> main() File "/data/home/geunsik-lim/qtlab/./transformers/examples/pytorch/language-modeling/run_clm.py", line 278, in main raw_datasets = load_dataset( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1719, in load_dataset builder_instance = load_dataset_builder( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1497, in load_dataset_builder dataset_module = dataset_module_factory( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1222, in dataset_module_factory raise e1 from None File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1179, in dataset_module_factory raise ConnectionError(f"Couldn't reach '{path}' on the Hub ({type(e).__name__})") ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError) [2022-11-07 15:23:38,476] [INFO] [launch.py:318:sigkill_handler] Killing subprocess 6760 [2022-11-07 15:23:38,476] [ERROR] [launch.py:324:sigkill_handler] ['/home/geunsik-lim/anaconda3/envs/deepspeed/bin/python', '-u', './transformers/examples/pytorch/language-modeling/run_clm.py', '--local_rank=0', '--model_name_or_path=Salesforce/codegen-350M-multi', '--per_device_train_batch_size=1', '--learning_rate', '2e-5', '--num_train_epochs', '1', '--output_dir=./codegen-350M-finetuned', '--overwrite_output_dir', '--dataset_name', 'moyix/debian_csrc', '--cache_dir', '/data/home/geunsik-lim/.cache', '--tokenizer_name', 'Salesforce/codegen-350M-multi', '--block_size', '2048', '--gradient_accumulation_steps', '32', '--do_train', '--fp16', '--deepspeed', 'ds_config_zero2.json'] exits with return code = 1 real 0m7.742s user 0m4.930s ``` ### Steps to reproduce the bug Steps to reproduce this behavior. ``` (deepspeed) geunsik-lim@ai02:~/qtlab$ ./test_debian_csrc_dataset.py Traceback (most recent call last): File "/data/home/geunsik-lim/qtlab/./test_debian_csrc_dataset.py", line 6, in <module> dataset = load_dataset("moyix/debian_csrc") File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1719, in load_dataset builder_instance = load_dataset_builder( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1497, in load_dataset_builder dataset_module = dataset_module_factory( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1222, in dataset_module_factory raise e1 from None File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1179, in dataset_module_factory raise ConnectionError(f"Couldn't reach '{path}' on the Hub ({type(e).__name__})") ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError) (deepspeed) geunsik-lim@ai02:~/qtlab$ (deepspeed) geunsik-lim@ai02:~/qtlab$ (deepspeed) geunsik-lim@ai02:~/qtlab$ (deepspeed) geunsik-lim@ai02:~/qtlab$ cat ./test_debian_csrc_dataset.py #!/usr/bin/env python from datasets import load_dataset dataset = load_dataset("moyix/debian_csrc") ``` 1. Adde proxy address of a company in /etc/profile 2. Download dataset with load_dataset() function of datasets package that is provided by HuggingFace. 3. In this case, the address would be "moyix--debian_csrc". 4. I get the "`ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError`)" error message. ### Expected behavior * error message: ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError) ### Environment info * software version information: ``` (deepspeed) geunsik-lim@ai02:~$ (deepspeed) geunsik-lim@ai02:~$ conda list -f pytorch # packages in environment at /home/geunsik-lim/anaconda3/envs/deepspeed: # # Name Version Build Channel pytorch 1.13.0 py3.10_cuda11.7_cudnn8.5.0_0 pytorch (deepspeed) geunsik-lim@ai02:~$ conda list -f python # packages in environment at /home/geunsik-lim/anaconda3/envs/deepspeed: # # Name Version Build Channel python 3.10.6 haa1d7c7_1 (deepspeed) geunsik-lim@ai02:~$ conda list -f datasets # packages in environment at /home/geunsik-lim/anaconda3/envs/deepspeed: # # Name Version Build Channel datasets 2.6.1 py_0 huggingface (deepspeed) geunsik-lim@ai02:~$ uname -a Linux ai02 5.4.0-131-generic #147-Ubuntu SMP Fri Oct 14 17:07:22 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux (deepspeed) geunsik-lim@ai02:~$ cat /etc/lsb-release DISTRIB_ID=Ubuntu DISTRIB_RELEASE=20.04 DISTRIB_CODENAME=focal DISTRIB_DESCRIPTION="Ubuntu 20.04.5 LTS" ``` You can use `requests` to see if downloading a file from the Hugging Face Hub works. If so, then `datasets` should work as well. If not, then you have to find another way using an internet connection that works
[ -1.2101938724517822, -0.9848392009735107, -0.6463838219642639, 1.3610045909881592, -0.09259431064128876, -1.2543190717697144, 0.13538286089897156, -0.9358691573143005, 1.5802162885665894, -0.6993018388748169, 0.18023976683616638, -1.6747028827667236, -0.18417586386203766, -0.4960053563117981, -0.6286711096763611, -0.9252771735191345, -0.3985865116119385, -0.8789850473403931, 1.0254299640655518, 2.530298948287964, 1.266221046447754, -1.2969276905059814, 2.805175304412842, 0.6511660814285278, -0.20531319081783295, -1.0805259943008423, 0.5593867301940918, 0.07102074474096298, -1.2718101739883423, -0.4310920536518097, -0.9308435916900635, -0.00741206668317318, -0.5506141781806946, -0.42432647943496704, 0.1443902552127838, 0.4096880257129669, -0.25387468934059143, -0.35998496413230896, -0.6688349843025208, -0.7198262810707092, 0.5128029584884644, -0.33434128761291504, 0.9185602068901062, -0.3634459972381592, 1.6761783361434937, -0.600292980670929, 0.5399637222290039, 0.7416286468505859, 1.2766711711883545, 0.157023623585701, 0.09921001642942429, 0.24196843802928925, 0.45718324184417725, 0.0920686423778534, 0.5639286637306213, 1.2364999055862427, 0.6044960021972656, 0.4897504150867462, 0.5809116959571838, -2.2312734127044678, 1.2733315229415894, -0.833156406879425, 0.2782244384288788, 1.3331902027130127, -0.8512033224105835, 0.37776651978492737, -1.8559792041778564, -0.13974614441394806, 0.6241037249565125, -2.3138301372528076, 0.1460530012845993, -1.345330834388733, -0.5994529128074646, 0.8775726556777954, 0.32758817076683044, -1.1515437364578247, 0.16351456940174103, -0.5405865907669067, 1.0597742795944214, 0.5473578572273254, 1.2075157165527344, -1.6380376815795898, -0.05842793732881546, -0.09930671751499176, 0.09961128979921341, -1.2229857444763184, -1.6419204473495483, 0.6020138263702393, 0.623964786529541, 0.6639888882637024, -0.13402239978313446, 0.902113676071167, -1.0196586847305298, 0.8403614163398743, -0.921943724155426, -1.623733639717102, -1.43673574924469, -2.4208462238311768, -2.4227964878082275, 0.8413307666778564, -0.48788243532180786, -0.41753485798835754, 1.9787778854370117, -0.9790158867835999, -1.8349056243896484, 1.0496647357940674, 0.2826404273509979, 0.0948261171579361, 2.339967966079712, 0.2963159680366516, -0.7453152537345886, 0.45124366879463196, -0.7123053073883057, 0.7387742400169373, -0.30891621112823486, 1.3154641389846802, 0.4964520037174225, -0.9075322151184082, 1.5839773416519165, -0.4754719138145447, 0.5346035957336426, -0.6385346055030823, -0.48134511709213257, -0.7530764937400818, 0.22485525906085968, 1.90009343624115, -0.33567890524864197, 1.5732975006103516, -0.3303106427192688, -1.6014206409454346, -1.5826328992843628, 0.8092432618141174, 0.5102069973945618, -0.818970799446106, -0.019466478377580643, -0.5070441961288452, 0.23261116445064545, 0.0617339089512825, 1.0833910703659058, 1.2416359186172485, 0.7722309827804565, -0.3323046565055847, -0.8364039659500122, 0.24179254472255707, -0.15943995118141174, -0.6460431814193726, -1.8663921356201172, -0.29116788506507874, 0.2807075083255768, 0.6327033042907715, -1.2587414979934692, 1.734540581703186, 0.8652622699737549, 2.0775387287139893, 0.9935553669929504, -0.3738793730735779, 1.4822192192077637, 0.04954508692026138, 1.9431580305099487, -0.48535507917404175, 0.6066707372665405, -0.3363996744155884, -1.093932032585144, 0.7892741560935974, -0.3685470521450043, -1.991749882698059, -0.7231224775314331, -0.847476065158844, -0.16552825272083282, -0.7470046877861023, 0.915972113609314, -0.2519790232181549, -1.4050005674362183, 0.11658287048339844, -0.7078359127044678, 0.14379289746284485, -1.2697150707244873, 0.16970579326152802, 0.7346994876861572, -0.7368481755256653, 0.007386434823274612, -0.28139257431030273, -1.3813148736953735, -0.5134096145629883, 0.3638860881328583, 1.9437031745910645, -0.5980596542358398, 0.9344896674156189, 0.976900577545166, -0.784520149230957, 0.0952678844332695, 0.24971826374530792, -0.32141298055648804, 0.7205543518066406, -1.1007938385009766, -0.3305029273033142, 1.1537811756134033, -0.2799825668334961, -0.7015653252601624, 1.433353066444397, 0.8323634266853333, -1.048343300819397, -0.30110737681388855, -0.21266025304794312, -0.8434891104698181, -0.008939110673964024, -1.569558024406433, -0.2113167643547058, 0.30968955159187317, -1.4713935852050781, -0.4453803300857544, -0.24000708758831024, 1.3647958040237427, -0.15304701030254364, 1.4482595920562744, -0.2743191123008728, -0.20540837943553925, -0.3417135775089264, -0.4314921200275421, 0.2359715700149536, -0.25905123353004456, -0.6110643744468689, 0.21991345286369324, -0.9171579480171204, 0.24858234822750092, 1.5320059061050415, 0.3319348990917206, 0.03676220774650574, 0.49887725710868835, 1.058790683746338, 0.37779977917671204, -0.0725904032588005, -0.8494987487792969, -1.5580881834030151, 2.043576240539551, -1.4148190021514893, 1.8966516256332397, 0.6860719919204712, -0.10404862463474274, -1.844902753829956, -1.8770201206207275, 1.161267876625061, 1.019837498664856, 2.4735724925994873, 0.504600465297699, 0.4225270450115204, -0.7275466918945312, -0.7544103860855103, 0.30322813987731934, -0.8923482894897461, -0.7358286380767822, 0.18174776434898376, 2.354684829711914, 1.7802053689956665, -0.6334859728813171, -0.2213420271873474, -0.9219489693641663, 1.2588279247283936, -0.22724361717700958, 0.2797517478466034, 2.0653414726257324, -0.34672725200653076, -0.9282051920890808, 1.329399585723877, -2.3420753479003906, 0.314253032207489, 2.062631607055664, 0.2939664125442505, 0.12375102937221527, -1.5398575067520142, -0.6506750583648682, -0.29279717803001404, -0.4760562777519226, -1.2055679559707642, 0.6198215484619141, -0.3601400554180145, -0.9874690771102905, -1.4452238082885742, -0.003779920283704996, -1.1126996278762817, -1.7747029066085815, 0.31700506806373596, 1.9122331142425537, 2.0207669734954834, -0.7844468951225281, 1.3024810552597046, -0.22190742194652557, 0.031264737248420715, 1.3270342350006104, 1.2580658197402954, 3.1251723766326904, 1.9954344034194946, -1.244377851486206, 0.8388042449951172, -0.1758500188589096, -0.40927740931510925, 1.0763534307479858, -1.1066572666168213, 1.0901659727096558, -0.24116367101669312, -1.2654154300689697, -1.228888750076294, 1.1343066692352295, 0.545258104801178, -0.07393918931484222, -0.47284650802612305, 1.2851961851119995, 0.11195667088031769, 1.3914036750793457, 0.5809236764907837, -0.46803396940231323, 0.6160642504692078, -0.3343643248081207, -0.6155844330787659, 1.6932507753372192, 0.19172856211662292, -1.6242891550064087, -2.295448064804077, -0.2991616725921631, -1.004981279373169, -0.12246046960353851, -0.6197105050086975, -0.9563761353492737, 1.604910969734192, 0.4791000485420227, -1.2292146682739258, -0.219857320189476, -0.30000996589660645, -0.5639417767524719, 2.6922903060913086, -1.2744641304016113, -0.1587761640548706, -0.9372479915618896, -0.5327082872390747, 1.5891929864883423, -1.2240570783615112, -0.22004106640815735, -1.0574254989624023, -0.6614238619804382, -1.2614446878433228, -0.4952686131000519, 0.048112720251083374, -0.8925455212593079, 0.7178272008895874, 0.07201635837554932, -1.0519498586654663, -0.23036164045333862, -0.9065776467323303, 1.0907516479492188, -0.03391668573021889, 0.1806006282567978, 1.9309877157211304, 0.2997954189777374, -0.39509016275405884, 0.6387832164764404, 1.166185736656189, 0.588657021522522, -0.6758812069892883, 0.04944082349538803, -0.7216836810112, 0.29591432213783264, -1.4088406562805176, 0.17301493883132935, -2.9303505420684814, 0.7213566303253174, -0.13164053857326508, -0.18862922489643097, -0.0817440003156662, -1.2792123556137085, 1.096771240234375, 2.602665662765503, -1.1677626371383667, 0.5138667225837708, 0.4709905982017517, 1.118680477142334, -1.5230634212493896, 0.31883254647254944, -0.46271607279777527, 2.1025662422180176, 0.22581617534160614, 1.1643304824829102, -0.5320730209350586, -2.083970308303833, 0.6662347912788391, -1.1145086288452148, -1.0465697050094604, 0.7753913998603821, -0.8930227756500244, 0.2550831139087677, -1.4400606155395508, -0.15180061757564545, -0.9052006006240845, -1.2549748420715332, 0.6689123511314392, 0.12365543842315674, 0.4714145362377167, -0.5919266939163208, 0.39856722950935364, -2.1977667808532715, -1.3547680377960205, -0.2224193811416626, -1.0108156204223633, 0.5230529308319092, -0.32101985812187195, 0.599599301815033, -0.05451236665248871, 0.041711658239364624, 0.28557920455932617, 1.431061863899231, 3.3859264850616455, 0.1442875862121582, 0.12102675437927246, -0.0554683655500412, -1.0835407972335815, 1.448081374168396, 0.9233081340789795, -0.12457627058029175, -0.4855106770992279, -0.9963406920433044, 1.3020135164260864, 2.0627474784851074, 1.2284245491027832, 0.20865961909294128, -0.8637051582336426, -0.8437049388885498, 0.08279643952846527, 0.13301706314086914, 0.546917200088501, 0.9916512370109558, -0.049991145730018616, 0.12448941171169281, 1.436536192893982, 1.2274129390716553, -0.24234703183174133, 0.45929038524627686, -0.9979048371315002, -0.38358837366104126, 0.3695952594280243, 0.2483922690153122, 0.02852858416736126, 0.4030681848526001, -1.1724179983139038, -0.243775874376297, -0.2818835973739624, -0.8340128660202026, -0.7568509578704834, -0.3921731412410736, -0.4187728762626648, 1.5882070064544678, 0.16235022246837616, -0.5093159675598145, 0.06754458695650101, -0.6957557201385498, -0.11245029419660568, -1.0878310203552246, 0.24026788771152496, -0.08702076226472855, -0.03263659030199051, -0.1809389740228653, 1.6621038913726807, -0.9048901796340942, -2.2064759731292725, 0.19137148559093475, 0.2941451370716095, -0.408750057220459, 0.17310766875743866, 1.7232794761657715, 0.575240969657898, 1.348678708076477, 1.34182870388031, 1.0277857780456543, -0.5214507579803467, -1.2477277517318726, 0.7440639734268188, 0.8636590242385864, -1.400339961051941, 0.8900837898254395, -0.1968204230070114, -0.49254634976387024, 0.6882780194282532, 1.3137520551681519, 0.29059717059135437, -2.0828144550323486, 0.9499753713607788, -0.8319701552391052, 0.6803613901138306, 0.6941599249839783, 0.8330775499343872, 0.22894467413425446, 0.8574993014335632, -1.2451331615447998, -1.1235296726226807, -0.7495859265327454, -0.572376549243927, 1.8681137561798096, -0.14432233572006226, 0.5620013475418091, -0.2324371337890625, -1.2110430002212524, -0.07528283447027206, 0.7733743786811829, 0.35899147391319275, -0.4315747618675232, 0.9168691635131836, -0.6058486700057983, -1.0628750324249268, -1.2165154218673706, -0.4133034646511078, -1.0476559400558472, -0.8567384481430054, 0.9794536232948303, 0.7299903035163879, 0.5615618824958801, 1.8946986198425293, 0.5362038016319275, 0.3486790657043457, -2.7106480598449707, 0.8826967477798462, 0.2861660122871399, 0.008470961824059486, 0.8783252835273743, 0.2544199824333191, 1.1979392766952515, -0.09945198148488998, 0.5765464305877686, -2.3076775074005127, 2.1905360221862793, -0.26602309942245483, 0.6710407733917236, 0.036682598292827606, -0.13137145340442657, 1.0464459657669067, 0.6316334009170532, 0.6674495339393616, -1.154430627822876, 0.8008698225021362, -0.5652693510055542, 1.0742096900939941, 0.9655672311782837, -0.8490721583366394, 0.06020203232765198, 1.4150935411453247, 0.5122062563896179, -0.3738832473754883, -0.9780703186988831, -0.8600805401802063, 0.9179123044013977, 1.6804094314575195, -0.11309666931629181, -0.011029762215912342, 0.914372980594635, 0.609463095664978, -1.2993860244750977, 0.01722101680934429, -0.753664493560791, -0.5817071795463562, 1.729153037071228, 2.0180611610412598, -0.08539870381355286, -0.22433234751224518, -0.6936497092247009, -1.3153845071792603, 0.7081789374351501, -0.100128173828125, 0.039959922432899475, 0.7756526470184326, -0.6430738568305969, 1.068272590637207, 0.5351724624633789, 1.0309146642684937, 0.0002792375162243843, 0.3414400517940521, 0.2725507915019989, -0.37274080514907837, -1.2210400104522705, -0.3660553991794586, -1.062043309211731, -2.4605257511138916, 0.44597339630126953, -0.28047725558280945, -1.529068112373352, 0.11079179495573044, -1.016734004020691, 0.8569089770317078, -0.6029643416404724, -1.0659462213516235, -1.377393364906311, 0.337065726518631, -0.19359341263771057, 0.9087976217269897, -1.692196011543274, -0.1607421189546585, 1.2383592128753662, 0.8237171173095703, -0.5223172307014465, 0.974932849407196, 0.33063647150993347, 1.0053054094314575, 0.7762323021888733, -0.3915334939956665, 0.5029335021972656, 0.0026428643614053726, -1.3312065601348877, 0.3631543517112732, 1.1733226776123047, 0.2242339551448822, 1.3032537698745728, -0.5785112380981445, 0.14021791517734528, 0.43588903546333313, -0.6688278913497925, -0.4742282032966614, -0.38530147075653076, 0.7722625732421875, -0.08347965776920319, -1.0674980878829956, -0.14312197268009186, -0.14327672123908997, -0.23241524398326874, 0.2537137269973755, -1.422317624092102, -0.23922523856163025, -0.324656218290329, -0.4942038357257843, -1.3655717372894287, 0.04735906422138214, 1.2768436670303345, -0.9256664514541626, -0.1906023919582367, 0.4328668713569641, 0.34149062633514404, 0.6293171048164368, 0.5267755389213562, -0.7051588892936707, -0.1917072981595993, -0.3547005355358124, -0.25497546792030334, 0.21008048951625824, 1.2646876573562622, -0.056042663753032684, -1.037827968597412, 0.7112687230110168, -0.36700668931007385, 0.1743965893983841, 2.0898008346557617, 0.01882123202085495, -0.6858804225921631, 0.3025953769683838, -0.7078500390052795, 1.7495222091674805, 1.7270715236663818, 1.3228960037231445, -0.11705700308084488, -0.8095453381538391, 0.4207831919193268, -0.32627683877944946, -0.3100837767124176, 0.8376888632774353, 0.48213112354278564, -0.21957184374332428, -1.3386094570159912, 0.528097927570343, 1.3108603954315186, -0.834561824798584, -0.7658274173736572, 0.13702651858329773, -0.9070854187011719, 1.2553255558013916, 0.6848639249801636, 0.36747926473617554, 0.17951956391334534, 1.5198873281478882, 0.7240201830863953, -0.5055926442146301, 0.48101016879081726, 0.5938921570777893, -0.22542113065719604, -2.1318936347961426, -1.0050030946731567, 0.2666763365268707, -0.36359903216362, -1.6032044887542725, 1.3488402366638184, -1.1806944608688354, -1.0274051427841187, 0.5191311240196228, 0.19799916446208954, 1.3381623029708862, 0.36945194005966187, 1.7137683629989624, 2.136659622192383, 0.9157043099403381, 0.40599584579467773, 1.2704917192459106, -0.023741688579320908, -0.45977944135665894, 1.840864658355713, -0.3820706009864807, 0.605563223361969, 1.0157393217086792, -0.440067857503891, -1.049451470375061, -0.8634418249130249, -1.133239507675171, -0.5489416718482971, 1.1791335344314575, 0.11838933825492859, -1.0654003620147705, 0.19005154073238373, 1.5810335874557495, 0.07306818664073944, -0.28770509362220764, 0.7168276906013489, 0.3737070560455322, -0.6427023410797119, -0.050469256937503815, -0.8950226306915283, 0.49520620703697205, -0.11070451885461807, -0.29631733894348145, 0.21590621769428253, 0.5048563480377197, 1.269000768661499, -0.03388584777712822, 0.12012775242328644, 1.249561071395874, -1.3124167919158936, 1.5345638990402222, -0.5964063405990601, 0.2800378203392029, -2.418687105178833, 1.3795493841171265, -0.8087407350540161, 1.8364537954330444, -2.560482978820801, 0.450914591550827, -0.5275850892066956, -0.48665356636047363, 0.20063936710357666, -0.43682464957237244, 0.01652822270989418, -0.059560626745224, -1.0022931098937988, -0.025107603520154953, -0.7814114093780518, 0.5857306122779846, 1.1408171653747559, 1.4348269701004028, -1.1343231201171875, -0.3056958317756653, -1.7783968448638916, -0.22981463372707367, -0.8435412645339966, 0.4242849349975586, -1.8779150247573853, -0.15031902492046356, -1.950347661972046, -2.371351957321167, -1.379634976387024, -0.917955219745636, 1.0195949077606201, 0.12182950973510742, -0.9299824833869934, 1.1759635210037231, -0.34863319993019104, -1.9203864336013794, 1.099747896194458, -2.2218995094299316 ]
https://github.com/huggingface/datasets/issues/5207
Connection error of the HuggingFace's dataset Hub due to SSLError with proxy
I resolved this issue by applying to "unblock websites" at https://huggingface.com in a corporate network environment with a firewall.
### Describe the bug It's weird. I could not normally connect the dataset Hub of HuggingFace due to a SSLError in my office. Even when I try to connect using my company's proxy address (e.g., http_proxy and https_proxy), I'm getting the SSLError issue. What should I do to download the datanet stored in HuggingFace normally? I welcome any comments. I think those comments will be helpful to me. * Dataset address - https://huggingface.co/datasets/moyix/debian_csrc/viewer/moyix--debian_csrc * Log message ``` ............ OMISSION .............. Traceback (most recent call last): File "/data/home/geunsik-lim/qtlab/./transformers/examples/pytorch/language-modeling/run_clm.py", line 587, in <module> main() File "/data/home/geunsik-lim/qtlab/./transformers/examples/pytorch/language-modeling/run_clm.py", line 278, in main raw_datasets = load_dataset( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1719, in load_dataset builder_instance = load_dataset_builder( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1497, in load_dataset_builder dataset_module = dataset_module_factory( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1222, in dataset_module_factory raise e1 from None File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1179, in dataset_module_factory raise ConnectionError(f"Couldn't reach '{path}' on the Hub ({type(e).__name__})") ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError) [2022-11-07 15:23:38,476] [INFO] [launch.py:318:sigkill_handler] Killing subprocess 6760 [2022-11-07 15:23:38,476] [ERROR] [launch.py:324:sigkill_handler] ['/home/geunsik-lim/anaconda3/envs/deepspeed/bin/python', '-u', './transformers/examples/pytorch/language-modeling/run_clm.py', '--local_rank=0', '--model_name_or_path=Salesforce/codegen-350M-multi', '--per_device_train_batch_size=1', '--learning_rate', '2e-5', '--num_train_epochs', '1', '--output_dir=./codegen-350M-finetuned', '--overwrite_output_dir', '--dataset_name', 'moyix/debian_csrc', '--cache_dir', '/data/home/geunsik-lim/.cache', '--tokenizer_name', 'Salesforce/codegen-350M-multi', '--block_size', '2048', '--gradient_accumulation_steps', '32', '--do_train', '--fp16', '--deepspeed', 'ds_config_zero2.json'] exits with return code = 1 real 0m7.742s user 0m4.930s ``` ### Steps to reproduce the bug Steps to reproduce this behavior. ``` (deepspeed) geunsik-lim@ai02:~/qtlab$ ./test_debian_csrc_dataset.py Traceback (most recent call last): File "/data/home/geunsik-lim/qtlab/./test_debian_csrc_dataset.py", line 6, in <module> dataset = load_dataset("moyix/debian_csrc") File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1719, in load_dataset builder_instance = load_dataset_builder( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1497, in load_dataset_builder dataset_module = dataset_module_factory( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1222, in dataset_module_factory raise e1 from None File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1179, in dataset_module_factory raise ConnectionError(f"Couldn't reach '{path}' on the Hub ({type(e).__name__})") ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError) (deepspeed) geunsik-lim@ai02:~/qtlab$ (deepspeed) geunsik-lim@ai02:~/qtlab$ (deepspeed) geunsik-lim@ai02:~/qtlab$ (deepspeed) geunsik-lim@ai02:~/qtlab$ cat ./test_debian_csrc_dataset.py #!/usr/bin/env python from datasets import load_dataset dataset = load_dataset("moyix/debian_csrc") ``` 1. Adde proxy address of a company in /etc/profile 2. Download dataset with load_dataset() function of datasets package that is provided by HuggingFace. 3. In this case, the address would be "moyix--debian_csrc". 4. I get the "`ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError`)" error message. ### Expected behavior * error message: ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError) ### Environment info * software version information: ``` (deepspeed) geunsik-lim@ai02:~$ (deepspeed) geunsik-lim@ai02:~$ conda list -f pytorch # packages in environment at /home/geunsik-lim/anaconda3/envs/deepspeed: # # Name Version Build Channel pytorch 1.13.0 py3.10_cuda11.7_cudnn8.5.0_0 pytorch (deepspeed) geunsik-lim@ai02:~$ conda list -f python # packages in environment at /home/geunsik-lim/anaconda3/envs/deepspeed: # # Name Version Build Channel python 3.10.6 haa1d7c7_1 (deepspeed) geunsik-lim@ai02:~$ conda list -f datasets # packages in environment at /home/geunsik-lim/anaconda3/envs/deepspeed: # # Name Version Build Channel datasets 2.6.1 py_0 huggingface (deepspeed) geunsik-lim@ai02:~$ uname -a Linux ai02 5.4.0-131-generic #147-Ubuntu SMP Fri Oct 14 17:07:22 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux (deepspeed) geunsik-lim@ai02:~$ cat /etc/lsb-release DISTRIB_ID=Ubuntu DISTRIB_RELEASE=20.04 DISTRIB_CODENAME=focal DISTRIB_DESCRIPTION="Ubuntu 20.04.5 LTS" ```
438
19
Connection error of the HuggingFace's dataset Hub due to SSLError with proxy ### Describe the bug It's weird. I could not normally connect the dataset Hub of HuggingFace due to a SSLError in my office. Even when I try to connect using my company's proxy address (e.g., http_proxy and https_proxy), I'm getting the SSLError issue. What should I do to download the datanet stored in HuggingFace normally? I welcome any comments. I think those comments will be helpful to me. * Dataset address - https://huggingface.co/datasets/moyix/debian_csrc/viewer/moyix--debian_csrc * Log message ``` ............ OMISSION .............. Traceback (most recent call last): File "/data/home/geunsik-lim/qtlab/./transformers/examples/pytorch/language-modeling/run_clm.py", line 587, in <module> main() File "/data/home/geunsik-lim/qtlab/./transformers/examples/pytorch/language-modeling/run_clm.py", line 278, in main raw_datasets = load_dataset( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1719, in load_dataset builder_instance = load_dataset_builder( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1497, in load_dataset_builder dataset_module = dataset_module_factory( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1222, in dataset_module_factory raise e1 from None File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1179, in dataset_module_factory raise ConnectionError(f"Couldn't reach '{path}' on the Hub ({type(e).__name__})") ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError) [2022-11-07 15:23:38,476] [INFO] [launch.py:318:sigkill_handler] Killing subprocess 6760 [2022-11-07 15:23:38,476] [ERROR] [launch.py:324:sigkill_handler] ['/home/geunsik-lim/anaconda3/envs/deepspeed/bin/python', '-u', './transformers/examples/pytorch/language-modeling/run_clm.py', '--local_rank=0', '--model_name_or_path=Salesforce/codegen-350M-multi', '--per_device_train_batch_size=1', '--learning_rate', '2e-5', '--num_train_epochs', '1', '--output_dir=./codegen-350M-finetuned', '--overwrite_output_dir', '--dataset_name', 'moyix/debian_csrc', '--cache_dir', '/data/home/geunsik-lim/.cache', '--tokenizer_name', 'Salesforce/codegen-350M-multi', '--block_size', '2048', '--gradient_accumulation_steps', '32', '--do_train', '--fp16', '--deepspeed', 'ds_config_zero2.json'] exits with return code = 1 real 0m7.742s user 0m4.930s ``` ### Steps to reproduce the bug Steps to reproduce this behavior. ``` (deepspeed) geunsik-lim@ai02:~/qtlab$ ./test_debian_csrc_dataset.py Traceback (most recent call last): File "/data/home/geunsik-lim/qtlab/./test_debian_csrc_dataset.py", line 6, in <module> dataset = load_dataset("moyix/debian_csrc") File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1719, in load_dataset builder_instance = load_dataset_builder( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1497, in load_dataset_builder dataset_module = dataset_module_factory( File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1222, in dataset_module_factory raise e1 from None File "/home/geunsik-lim/anaconda3/envs/deepspeed/lib/python3.10/site-packages/datasets/load.py", line 1179, in dataset_module_factory raise ConnectionError(f"Couldn't reach '{path}' on the Hub ({type(e).__name__})") ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError) (deepspeed) geunsik-lim@ai02:~/qtlab$ (deepspeed) geunsik-lim@ai02:~/qtlab$ (deepspeed) geunsik-lim@ai02:~/qtlab$ (deepspeed) geunsik-lim@ai02:~/qtlab$ cat ./test_debian_csrc_dataset.py #!/usr/bin/env python from datasets import load_dataset dataset = load_dataset("moyix/debian_csrc") ``` 1. Adde proxy address of a company in /etc/profile 2. Download dataset with load_dataset() function of datasets package that is provided by HuggingFace. 3. In this case, the address would be "moyix--debian_csrc". 4. I get the "`ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError`)" error message. ### Expected behavior * error message: ConnectionError: Couldn't reach 'moyix/debian_csrc' on the Hub (SSLError) ### Environment info * software version information: ``` (deepspeed) geunsik-lim@ai02:~$ (deepspeed) geunsik-lim@ai02:~$ conda list -f pytorch # packages in environment at /home/geunsik-lim/anaconda3/envs/deepspeed: # # Name Version Build Channel pytorch 1.13.0 py3.10_cuda11.7_cudnn8.5.0_0 pytorch (deepspeed) geunsik-lim@ai02:~$ conda list -f python # packages in environment at /home/geunsik-lim/anaconda3/envs/deepspeed: # # Name Version Build Channel python 3.10.6 haa1d7c7_1 (deepspeed) geunsik-lim@ai02:~$ conda list -f datasets # packages in environment at /home/geunsik-lim/anaconda3/envs/deepspeed: # # Name Version Build Channel datasets 2.6.1 py_0 huggingface (deepspeed) geunsik-lim@ai02:~$ uname -a Linux ai02 5.4.0-131-generic #147-Ubuntu SMP Fri Oct 14 17:07:22 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux (deepspeed) geunsik-lim@ai02:~$ cat /etc/lsb-release DISTRIB_ID=Ubuntu DISTRIB_RELEASE=20.04 DISTRIB_CODENAME=focal DISTRIB_DESCRIPTION="Ubuntu 20.04.5 LTS" ``` I resolved this issue by applying to "unblock websites" at https://huggingface.com in a corporate network environment with a firewall.
[ -1.2101938724517822, -0.9848392009735107, -0.6463838219642639, 1.3610045909881592, -0.09259431064128876, -1.2543190717697144, 0.13538286089897156, -0.9358691573143005, 1.5802162885665894, -0.6993018388748169, 0.18023976683616638, -1.6747028827667236, -0.18417586386203766, -0.4960053563117981, -0.6286711096763611, -0.9252771735191345, -0.3985865116119385, -0.8789850473403931, 1.0254299640655518, 2.530298948287964, 1.266221046447754, -1.2969276905059814, 2.805175304412842, 0.6511660814285278, -0.20531319081783295, -1.0805259943008423, 0.5593867301940918, 0.07102074474096298, -1.2718101739883423, -0.4310920536518097, -0.9308435916900635, -0.00741206668317318, -0.5506141781806946, -0.42432647943496704, 0.1443902552127838, 0.4096880257129669, -0.25387468934059143, -0.35998496413230896, -0.6688349843025208, -0.7198262810707092, 0.5128029584884644, -0.33434128761291504, 0.9185602068901062, -0.3634459972381592, 1.6761783361434937, -0.600292980670929, 0.5399637222290039, 0.7416286468505859, 1.2766711711883545, 0.157023623585701, 0.09921001642942429, 0.24196843802928925, 0.45718324184417725, 0.0920686423778534, 0.5639286637306213, 1.2364999055862427, 0.6044960021972656, 0.4897504150867462, 0.5809116959571838, -2.2312734127044678, 1.2733315229415894, -0.833156406879425, 0.2782244384288788, 1.3331902027130127, -0.8512033224105835, 0.37776651978492737, -1.8559792041778564, -0.13974614441394806, 0.6241037249565125, -2.3138301372528076, 0.1460530012845993, -1.345330834388733, -0.5994529128074646, 0.8775726556777954, 0.32758817076683044, -1.1515437364578247, 0.16351456940174103, -0.5405865907669067, 1.0597742795944214, 0.5473578572273254, 1.2075157165527344, -1.6380376815795898, -0.05842793732881546, -0.09930671751499176, 0.09961128979921341, -1.2229857444763184, -1.6419204473495483, 0.6020138263702393, 0.623964786529541, 0.6639888882637024, -0.13402239978313446, 0.902113676071167, -1.0196586847305298, 0.8403614163398743, -0.921943724155426, -1.623733639717102, -1.43673574924469, -2.4208462238311768, -2.4227964878082275, 0.8413307666778564, -0.48788243532180786, -0.41753485798835754, 1.9787778854370117, -0.9790158867835999, -1.8349056243896484, 1.0496647357940674, 0.2826404273509979, 0.0948261171579361, 2.339967966079712, 0.2963159680366516, -0.7453152537345886, 0.45124366879463196, -0.7123053073883057, 0.7387742400169373, -0.30891621112823486, 1.3154641389846802, 0.4964520037174225, -0.9075322151184082, 1.5839773416519165, -0.4754719138145447, 0.5346035957336426, -0.6385346055030823, -0.48134511709213257, -0.7530764937400818, 0.22485525906085968, 1.90009343624115, -0.33567890524864197, 1.5732975006103516, -0.3303106427192688, -1.6014206409454346, -1.5826328992843628, 0.8092432618141174, 0.5102069973945618, -0.818970799446106, -0.019466478377580643, -0.5070441961288452, 0.23261116445064545, 0.0617339089512825, 1.0833910703659058, 1.2416359186172485, 0.7722309827804565, -0.3323046565055847, -0.8364039659500122, 0.24179254472255707, -0.15943995118141174, -0.6460431814193726, -1.8663921356201172, -0.29116788506507874, 0.2807075083255768, 0.6327033042907715, -1.2587414979934692, 1.734540581703186, 0.8652622699737549, 2.0775387287139893, 0.9935553669929504, -0.3738793730735779, 1.4822192192077637, 0.04954508692026138, 1.9431580305099487, -0.48535507917404175, 0.6066707372665405, -0.3363996744155884, -1.093932032585144, 0.7892741560935974, -0.3685470521450043, -1.991749882698059, -0.7231224775314331, -0.847476065158844, -0.16552825272083282, -0.7470046877861023, 0.915972113609314, -0.2519790232181549, -1.4050005674362183, 0.11658287048339844, -0.7078359127044678, 0.14379289746284485, -1.2697150707244873, 0.16970579326152802, 0.7346994876861572, -0.7368481755256653, 0.007386434823274612, -0.28139257431030273, -1.3813148736953735, -0.5134096145629883, 0.3638860881328583, 1.9437031745910645, -0.5980596542358398, 0.9344896674156189, 0.976900577545166, -0.784520149230957, 0.0952678844332695, 0.24971826374530792, -0.32141298055648804, 0.7205543518066406, -1.1007938385009766, -0.3305029273033142, 1.1537811756134033, -0.2799825668334961, -0.7015653252601624, 1.433353066444397, 0.8323634266853333, -1.048343300819397, -0.30110737681388855, -0.21266025304794312, -0.8434891104698181, -0.008939110673964024, -1.569558024406433, -0.2113167643547058, 0.30968955159187317, -1.4713935852050781, -0.4453803300857544, -0.24000708758831024, 1.3647958040237427, -0.15304701030254364, 1.4482595920562744, -0.2743191123008728, -0.20540837943553925, -0.3417135775089264, -0.4314921200275421, 0.2359715700149536, -0.25905123353004456, -0.6110643744468689, 0.21991345286369324, -0.9171579480171204, 0.24858234822750092, 1.5320059061050415, 0.3319348990917206, 0.03676220774650574, 0.49887725710868835, 1.058790683746338, 0.37779977917671204, -0.0725904032588005, -0.8494987487792969, -1.5580881834030151, 2.043576240539551, -1.4148190021514893, 1.8966516256332397, 0.6860719919204712, -0.10404862463474274, -1.844902753829956, -1.8770201206207275, 1.161267876625061, 1.019837498664856, 2.4735724925994873, 0.504600465297699, 0.4225270450115204, -0.7275466918945312, -0.7544103860855103, 0.30322813987731934, -0.8923482894897461, -0.7358286380767822, 0.18174776434898376, 2.354684829711914, 1.7802053689956665, -0.6334859728813171, -0.2213420271873474, -0.9219489693641663, 1.2588279247283936, -0.22724361717700958, 0.2797517478466034, 2.0653414726257324, -0.34672725200653076, -0.9282051920890808, 1.329399585723877, -2.3420753479003906, 0.314253032207489, 2.062631607055664, 0.2939664125442505, 0.12375102937221527, -1.5398575067520142, -0.6506750583648682, -0.29279717803001404, -0.4760562777519226, -1.2055679559707642, 0.6198215484619141, -0.3601400554180145, -0.9874690771102905, -1.4452238082885742, -0.003779920283704996, -1.1126996278762817, -1.7747029066085815, 0.31700506806373596, 1.9122331142425537, 2.0207669734954834, -0.7844468951225281, 1.3024810552597046, -0.22190742194652557, 0.031264737248420715, 1.3270342350006104, 1.2580658197402954, 3.1251723766326904, 1.9954344034194946, -1.244377851486206, 0.8388042449951172, -0.1758500188589096, -0.40927740931510925, 1.0763534307479858, -1.1066572666168213, 1.0901659727096558, -0.24116367101669312, -1.2654154300689697, -1.228888750076294, 1.1343066692352295, 0.545258104801178, -0.07393918931484222, -0.47284650802612305, 1.2851961851119995, 0.11195667088031769, 1.3914036750793457, 0.5809236764907837, -0.46803396940231323, 0.6160642504692078, -0.3343643248081207, -0.6155844330787659, 1.6932507753372192, 0.19172856211662292, -1.6242891550064087, -2.295448064804077, -0.2991616725921631, -1.004981279373169, -0.12246046960353851, -0.6197105050086975, -0.9563761353492737, 1.604910969734192, 0.4791000485420227, -1.2292146682739258, -0.219857320189476, -0.30000996589660645, -0.5639417767524719, 2.6922903060913086, -1.2744641304016113, -0.1587761640548706, -0.9372479915618896, -0.5327082872390747, 1.5891929864883423, -1.2240570783615112, -0.22004106640815735, -1.0574254989624023, -0.6614238619804382, -1.2614446878433228, -0.4952686131000519, 0.048112720251083374, -0.8925455212593079, 0.7178272008895874, 0.07201635837554932, -1.0519498586654663, -0.23036164045333862, -0.9065776467323303, 1.0907516479492188, -0.03391668573021889, 0.1806006282567978, 1.9309877157211304, 0.2997954189777374, -0.39509016275405884, 0.6387832164764404, 1.166185736656189, 0.588657021522522, -0.6758812069892883, 0.04944082349538803, -0.7216836810112, 0.29591432213783264, -1.4088406562805176, 0.17301493883132935, -2.9303505420684814, 0.7213566303253174, -0.13164053857326508, -0.18862922489643097, -0.0817440003156662, -1.2792123556137085, 1.096771240234375, 2.602665662765503, -1.1677626371383667, 0.5138667225837708, 0.4709905982017517, 1.118680477142334, -1.5230634212493896, 0.31883254647254944, -0.46271607279777527, 2.1025662422180176, 0.22581617534160614, 1.1643304824829102, -0.5320730209350586, -2.083970308303833, 0.6662347912788391, -1.1145086288452148, -1.0465697050094604, 0.7753913998603821, -0.8930227756500244, 0.2550831139087677, -1.4400606155395508, -0.15180061757564545, -0.9052006006240845, -1.2549748420715332, 0.6689123511314392, 0.12365543842315674, 0.4714145362377167, -0.5919266939163208, 0.39856722950935364, -2.1977667808532715, -1.3547680377960205, -0.2224193811416626, -1.0108156204223633, 0.5230529308319092, -0.32101985812187195, 0.599599301815033, -0.05451236665248871, 0.041711658239364624, 0.28557920455932617, 1.431061863899231, 3.3859264850616455, 0.1442875862121582, 0.12102675437927246, -0.0554683655500412, -1.0835407972335815, 1.448081374168396, 0.9233081340789795, -0.12457627058029175, -0.4855106770992279, -0.9963406920433044, 1.3020135164260864, 2.0627474784851074, 1.2284245491027832, 0.20865961909294128, -0.8637051582336426, -0.8437049388885498, 0.08279643952846527, 0.13301706314086914, 0.546917200088501, 0.9916512370109558, -0.049991145730018616, 0.12448941171169281, 1.436536192893982, 1.2274129390716553, -0.24234703183174133, 0.45929038524627686, -0.9979048371315002, -0.38358837366104126, 0.3695952594280243, 0.2483922690153122, 0.02852858416736126, 0.4030681848526001, -1.1724179983139038, -0.243775874376297, -0.2818835973739624, -0.8340128660202026, -0.7568509578704834, -0.3921731412410736, -0.4187728762626648, 1.5882070064544678, 0.16235022246837616, -0.5093159675598145, 0.06754458695650101, -0.6957557201385498, -0.11245029419660568, -1.0878310203552246, 0.24026788771152496, -0.08702076226472855, -0.03263659030199051, -0.1809389740228653, 1.6621038913726807, -0.9048901796340942, -2.2064759731292725, 0.19137148559093475, 0.2941451370716095, -0.408750057220459, 0.17310766875743866, 1.7232794761657715, 0.575240969657898, 1.348678708076477, 1.34182870388031, 1.0277857780456543, -0.5214507579803467, -1.2477277517318726, 0.7440639734268188, 0.8636590242385864, -1.400339961051941, 0.8900837898254395, -0.1968204230070114, -0.49254634976387024, 0.6882780194282532, 1.3137520551681519, 0.29059717059135437, -2.0828144550323486, 0.9499753713607788, -0.8319701552391052, 0.6803613901138306, 0.6941599249839783, 0.8330775499343872, 0.22894467413425446, 0.8574993014335632, -1.2451331615447998, -1.1235296726226807, -0.7495859265327454, -0.572376549243927, 1.8681137561798096, -0.14432233572006226, 0.5620013475418091, -0.2324371337890625, -1.2110430002212524, -0.07528283447027206, 0.7733743786811829, 0.35899147391319275, -0.4315747618675232, 0.9168691635131836, -0.6058486700057983, -1.0628750324249268, -1.2165154218673706, -0.4133034646511078, -1.0476559400558472, -0.8567384481430054, 0.9794536232948303, 0.7299903035163879, 0.5615618824958801, 1.8946986198425293, 0.5362038016319275, 0.3486790657043457, -2.7106480598449707, 0.8826967477798462, 0.2861660122871399, 0.008470961824059486, 0.8783252835273743, 0.2544199824333191, 1.1979392766952515, -0.09945198148488998, 0.5765464305877686, -2.3076775074005127, 2.1905360221862793, -0.26602309942245483, 0.6710407733917236, 0.036682598292827606, -0.13137145340442657, 1.0464459657669067, 0.6316334009170532, 0.6674495339393616, -1.154430627822876, 0.8008698225021362, -0.5652693510055542, 1.0742096900939941, 0.9655672311782837, -0.8490721583366394, 0.06020203232765198, 1.4150935411453247, 0.5122062563896179, -0.3738832473754883, -0.9780703186988831, -0.8600805401802063, 0.9179123044013977, 1.6804094314575195, -0.11309666931629181, -0.011029762215912342, 0.914372980594635, 0.609463095664978, -1.2993860244750977, 0.01722101680934429, -0.753664493560791, -0.5817071795463562, 1.729153037071228, 2.0180611610412598, -0.08539870381355286, -0.22433234751224518, -0.6936497092247009, -1.3153845071792603, 0.7081789374351501, -0.100128173828125, 0.039959922432899475, 0.7756526470184326, -0.6430738568305969, 1.068272590637207, 0.5351724624633789, 1.0309146642684937, 0.0002792375162243843, 0.3414400517940521, 0.2725507915019989, -0.37274080514907837, -1.2210400104522705, -0.3660553991794586, -1.062043309211731, -2.4605257511138916, 0.44597339630126953, -0.28047725558280945, -1.529068112373352, 0.11079179495573044, -1.016734004020691, 0.8569089770317078, -0.6029643416404724, -1.0659462213516235, -1.377393364906311, 0.337065726518631, -0.19359341263771057, 0.9087976217269897, -1.692196011543274, -0.1607421189546585, 1.2383592128753662, 0.8237171173095703, -0.5223172307014465, 0.974932849407196, 0.33063647150993347, 1.0053054094314575, 0.7762323021888733, -0.3915334939956665, 0.5029335021972656, 0.0026428643614053726, -1.3312065601348877, 0.3631543517112732, 1.1733226776123047, 0.2242339551448822, 1.3032537698745728, -0.5785112380981445, 0.14021791517734528, 0.43588903546333313, -0.6688278913497925, -0.4742282032966614, -0.38530147075653076, 0.7722625732421875, -0.08347965776920319, -1.0674980878829956, -0.14312197268009186, -0.14327672123908997, -0.23241524398326874, 0.2537137269973755, -1.422317624092102, -0.23922523856163025, -0.324656218290329, -0.4942038357257843, -1.3655717372894287, 0.04735906422138214, 1.2768436670303345, -0.9256664514541626, -0.1906023919582367, 0.4328668713569641, 0.34149062633514404, 0.6293171048164368, 0.5267755389213562, -0.7051588892936707, -0.1917072981595993, -0.3547005355358124, -0.25497546792030334, 0.21008048951625824, 1.2646876573562622, -0.056042663753032684, -1.037827968597412, 0.7112687230110168, -0.36700668931007385, 0.1743965893983841, 2.0898008346557617, 0.01882123202085495, -0.6858804225921631, 0.3025953769683838, -0.7078500390052795, 1.7495222091674805, 1.7270715236663818, 1.3228960037231445, -0.11705700308084488, -0.8095453381538391, 0.4207831919193268, -0.32627683877944946, -0.3100837767124176, 0.8376888632774353, 0.48213112354278564, -0.21957184374332428, -1.3386094570159912, 0.528097927570343, 1.3108603954315186, -0.834561824798584, -0.7658274173736572, 0.13702651858329773, -0.9070854187011719, 1.2553255558013916, 0.6848639249801636, 0.36747926473617554, 0.17951956391334534, 1.5198873281478882, 0.7240201830863953, -0.5055926442146301, 0.48101016879081726, 0.5938921570777893, -0.22542113065719604, -2.1318936347961426, -1.0050030946731567, 0.2666763365268707, -0.36359903216362, -1.6032044887542725, 1.3488402366638184, -1.1806944608688354, -1.0274051427841187, 0.5191311240196228, 0.19799916446208954, 1.3381623029708862, 0.36945194005966187, 1.7137683629989624, 2.136659622192383, 0.9157043099403381, 0.40599584579467773, 1.2704917192459106, -0.023741688579320908, -0.45977944135665894, 1.840864658355713, -0.3820706009864807, 0.605563223361969, 1.0157393217086792, -0.440067857503891, -1.049451470375061, -0.8634418249130249, -1.133239507675171, -0.5489416718482971, 1.1791335344314575, 0.11838933825492859, -1.0654003620147705, 0.19005154073238373, 1.5810335874557495, 0.07306818664073944, -0.28770509362220764, 0.7168276906013489, 0.3737070560455322, -0.6427023410797119, -0.050469256937503815, -0.8950226306915283, 0.49520620703697205, -0.11070451885461807, -0.29631733894348145, 0.21590621769428253, 0.5048563480377197, 1.269000768661499, -0.03388584777712822, 0.12012775242328644, 1.249561071395874, -1.3124167919158936, 1.5345638990402222, -0.5964063405990601, 0.2800378203392029, -2.418687105178833, 1.3795493841171265, -0.8087407350540161, 1.8364537954330444, -2.560482978820801, 0.450914591550827, -0.5275850892066956, -0.48665356636047363, 0.20063936710357666, -0.43682464957237244, 0.01652822270989418, -0.059560626745224, -1.0022931098937988, -0.025107603520154953, -0.7814114093780518, 0.5857306122779846, 1.1408171653747559, 1.4348269701004028, -1.1343231201171875, -0.3056958317756653, -1.7783968448638916, -0.22981463372707367, -0.8435412645339966, 0.4242849349975586, -1.8779150247573853, -0.15031902492046356, -1.950347661972046, -2.371351957321167, -1.379634976387024, -0.917955219745636, 1.0195949077606201, 0.12182950973510742, -0.9299824833869934, 1.1759635210037231, -0.34863319993019104, -1.9203864336013794, 1.099747896194458, -2.2218995094299316 ]
https://github.com/huggingface/datasets/issues/5206
Use logging instead of printing to console
Actually upon closer inspection, it is documented in the code that this behavior is intentional, so I'll close this.
### Describe the bug Some logs ([here](https://github.com/huggingface/datasets/blob/4a6e1fe2735505efc7e3a3dbd3e1835da0702575/src/datasets/builder.py#L778), [here](https://github.com/huggingface/datasets/blob/4a6e1fe2735505efc7e3a3dbd3e1835da0702575/src/datasets/builder.py#L786), and [here](https://github.com/huggingface/datasets/blob/4a6e1fe2735505efc7e3a3dbd3e1835da0702575/src/datasets/builder.py#L830)) generated by the `DatasetBuilder` are printed to the console instead of passed to `datasets` logger. ### Steps to reproduce the bug ```python >> import datasets >> datasets.load_dataset("some-dataset") Downloading and preparing dataset csv/data to <path>... Downloading data files: 100%|██████████████████████████████████████████████████████████████████████████| 3/3 [00:00<00:00, 7729.06it/s] Extracting data files: 100%|████████████████████████████████████████████████████████████████████████████| 3/3 [00:00<00:00, 527.23it/s] Dataset csv downloaded and prepared to <path>. Subsequent calls will reuse this data. ``` ### Expected behavior The logs should not be printed to the console directly but passed to the logger so that the user can redirect them wherever he wants. ### Environment info - `datasets` version: 2.6.1 - Platform: macOS-13.0-x86_64-i386-64bit - Python version: 3.9.15 - PyArrow version: 10.0.0 - Pandas version: 1.5.1
439
19
Use logging instead of printing to console ### Describe the bug Some logs ([here](https://github.com/huggingface/datasets/blob/4a6e1fe2735505efc7e3a3dbd3e1835da0702575/src/datasets/builder.py#L778), [here](https://github.com/huggingface/datasets/blob/4a6e1fe2735505efc7e3a3dbd3e1835da0702575/src/datasets/builder.py#L786), and [here](https://github.com/huggingface/datasets/blob/4a6e1fe2735505efc7e3a3dbd3e1835da0702575/src/datasets/builder.py#L830)) generated by the `DatasetBuilder` are printed to the console instead of passed to `datasets` logger. ### Steps to reproduce the bug ```python >> import datasets >> datasets.load_dataset("some-dataset") Downloading and preparing dataset csv/data to <path>... Downloading data files: 100%|██████████████████████████████████████████████████████████████████████████| 3/3 [00:00<00:00, 7729.06it/s] Extracting data files: 100%|████████████████████████████████████████████████████████████████████████████| 3/3 [00:00<00:00, 527.23it/s] Dataset csv downloaded and prepared to <path>. Subsequent calls will reuse this data. ``` ### Expected behavior The logs should not be printed to the console directly but passed to the logger so that the user can redirect them wherever he wants. ### Environment info - `datasets` version: 2.6.1 - Platform: macOS-13.0-x86_64-i386-64bit - Python version: 3.9.15 - PyArrow version: 10.0.0 - Pandas version: 1.5.1 Actually upon closer inspection, it is documented in the code that this behavior is intentional, so I'll close this.
[ -1.1690433025360107, -0.8284521102905273, -0.7834874987602234, 1.4183673858642578, -0.05941249430179596, -1.2755928039550781, 0.08558012545108795, -1.0675758123397827, 1.6408439874649048, -0.7074066996574402, 0.21026097238063812, -1.6962523460388184, -0.03347335755825043, -0.5359618663787842, -0.7501111030578613, -0.8806869387626648, -0.40658167004585266, -0.7793660759925842, 0.9687090516090393, 2.551161050796509, 1.2057100534439087, -1.3435603380203247, 2.769608497619629, 0.7282711267471313, -0.2210359424352646, -0.9882217049598694, 0.586073100566864, 0.008971255272626877, -1.3768218755722046, -0.4017074704170227, -0.8704310655593872, -0.08444515615701675, -0.5366821885108948, -0.5126169323921204, 0.09548483788967133, 0.3828175663948059, -0.24341556429862976, -0.3898552358150482, -0.5707151889801025, -0.7489076256752014, 0.45864608883857727, -0.37803900241851807, 0.8833765387535095, -0.3414055407047272, 1.7976269721984863, -0.5618207454681396, 0.40610170364379883, 0.7274052500724792, 1.2894483804702759, 0.14930002391338348, 0.03364953398704529, 0.36727598309516907, 0.3372754156589508, 0.028076915070414543, 0.4243776202201843, 1.2296139001846313, 0.6494876146316528, 0.43515968322753906, 0.6990975141525269, -2.184605360031128, 1.2673909664154053, -0.8592179417610168, 0.30034029483795166, 1.322898030281067, -0.9290969371795654, 0.31800276041030884, -1.809154987335205, -0.08507991582155228, 0.5556651949882507, -2.269084930419922, 0.19585131108760834, -1.3201881647109985, -0.5338953137397766, 0.9729771614074707, 0.34968802332878113, -1.2018840312957764, 0.20615361630916595, -0.5432687401771545, 1.0550591945648193, 0.49596887826919556, 1.2977161407470703, -1.6702381372451782, -0.07219145447015762, -0.26522907614707947, 0.07046268880367279, -1.264922022819519, -1.6018426418304443, 0.5566902756690979, 0.7004884481430054, 0.678634524345398, -0.08815299719572067, 0.9431617856025696, -0.8921176195144653, 0.7785133719444275, -0.9492853879928589, -1.8125951290130615, -1.3412724733352661, -2.272827386856079, -2.288022041320801, 0.7798452377319336, -0.42305290699005127, -0.46805787086486816, 2.0313401222229004, -1.0434848070144653, -1.8158726692199707, 1.068867564201355, 0.29781416058540344, -0.03408375382423401, 2.359462261199951, 0.3004609942436218, -0.6915990114212036, 0.4152422547340393, -0.6201175451278687, 0.809558629989624, -0.32737770676612854, 1.3649022579193115, 0.47490373253822327, -0.9833381772041321, 1.571529746055603, -0.4460415244102478, 0.5961129665374756, -0.7289938926696777, -0.42910847067832947, -0.7771664261817932, 0.3266914188861847, 1.889965295791626, -0.4218381345272064, 1.6080039739608765, -0.3184196352958679, -1.6281434297561646, -1.566713571548462, 0.774564802646637, 0.580411434173584, -0.764056921005249, 0.027155576273798943, -0.42060011625289917, 0.05462866276502609, 0.022465920075774193, 1.0853657722473145, 1.2710943222045898, 0.6808364987373352, -0.35560712218284607, -0.901103675365448, 0.22980165481567383, -0.041569605469703674, -0.7179818749427795, -1.7726802825927734, -0.28524351119995117, 0.18556290864944458, 0.6520590782165527, -1.297265648841858, 1.6968995332717896, 0.8661538362503052, 1.9979535341262817, 1.0626887083053589, -0.4091007709503174, 1.4911139011383057, 0.005796797573566437, 1.9263825416564941, -0.4705602824687958, 0.6386510729789734, -0.32527148723602295, -1.2142975330352783, 0.8395482897758484, -0.3617621958255768, -2.0577211380004883, -0.7590591907501221, -0.83603835105896, -0.16022339463233948, -0.7520493865013123, 0.9426091909408569, -0.27677181363105774, -1.3954555988311768, 0.21539820730686188, -0.7724087834358215, 0.10757561773061752, -1.3206441402435303, 0.2086251676082611, 0.7258011698722839, -0.6284255385398865, -0.012382950633764267, -0.22030897438526154, -1.3243361711502075, -0.4301738440990448, 0.2725376486778259, 1.894210696220398, -0.6668440103530884, 0.9793826937675476, 1.0979325771331787, -0.671113133430481, 0.10706028342247009, 0.30923837423324585, -0.327044814825058, 0.860826313495636, -1.1663111448287964, -0.3233727812767029, 1.1567884683609009, -0.14383073151111603, -0.6452418565750122, 1.4456629753112793, 0.8467485904693604, -1.0538105964660645, -0.23833560943603516, -0.11900006234645844, -0.8088563084602356, -0.013224409893155098, -1.6795146465301514, -0.1564454287290573, 0.35763153433799744, -1.5183576345443726, -0.5050925016403198, -0.31986647844314575, 1.260687232017517, -0.053955428302288055, 1.4098724126815796, -0.3077661395072937, -0.20886574685573578, -0.38114306330680847, -0.4480724632740021, 0.16430959105491638, -0.2523716688156128, -0.6582059264183044, 0.26446157693862915, -0.791538417339325, 0.25807565450668335, 1.4865385293960571, 0.3722221553325653, 0.14314676821231842, 0.5714465975761414, 1.0922645330429077, 0.37937408685684204, -0.09698478877544403, -0.8132506012916565, -1.5940202474594116, 2.04777455329895, -1.4463964700698853, 1.920945644378662, 0.7867626547813416, -0.03080136515200138, -1.8598159551620483, -1.939208984375, 1.3829237222671509, 1.0740811824798584, 2.4205808639526367, 0.5470598340034485, 0.4650364816188812, -0.7876740097999573, -0.6796311736106873, 0.3225049078464508, -0.9450653195381165, -0.6997683644294739, 0.1334652304649353, 2.421480178833008, 1.719528079032898, -0.5037953853607178, -0.18829096853733063, -0.9476735591888428, 1.2866896390914917, -0.13084158301353455, 0.1527615636587143, 2.029658079147339, -0.2104848027229309, -1.0311967134475708, 1.2260969877243042, -2.3363234996795654, 0.17161665856838226, 1.9745670557022095, 0.21730846166610718, 0.05525786429643631, -1.458845615386963, -0.6739218235015869, -0.35893747210502625, -0.43725699186325073, -1.2945106029510498, 0.5738649368286133, -0.2866802513599396, -0.9110291004180908, -1.510812759399414, 0.08940307050943375, -1.1307748556137085, -1.7212189435958862, 0.3082234263420105, 1.9013595581054688, 1.958351731300354, -0.765097975730896, 1.5048335790634155, -0.32792598009109497, 0.09090664237737656, 1.249887466430664, 1.2189334630966187, 3.167696714401245, 1.8524612188339233, -1.316460371017456, 0.7599807977676392, -0.11245360970497131, -0.4498140513896942, 1.1563550233840942, -1.1078424453735352, 1.2336394786834717, -0.256213515996933, -1.3099955320358276, -1.1850881576538086, 1.034032940864563, 0.5168551802635193, 0.07418929785490036, -0.48549526929855347, 1.332245111465454, 0.04751710593700409, 1.3172798156738281, 0.5899757742881775, -0.3730723559856415, 0.6271806359291077, -0.341533899307251, -0.4740436375141144, 1.6257137060165405, 0.18413865566253662, -1.4573004245758057, -2.4055559635162354, -0.2678377628326416, -0.8871157765388489, -0.029215388000011444, -0.6408881545066833, -1.0468031167984009, 1.666330099105835, 0.39526206254959106, -1.2238541841506958, -0.32656577229499817, -0.3470117449760437, -0.5586679577827454, 2.62054181098938, -1.4051439762115479, -0.15855079889297485, -0.9480863213539124, -0.471367746591568, 1.5884628295898438, -1.1635822057724, -0.1982325166463852, -1.0275764465332031, -0.598625659942627, -1.2814011573791504, -0.5544937252998352, 0.0060536228120327, -0.9203901290893555, 0.7727238535881042, 0.08447980135679245, -1.0958971977233887, -0.1982002854347229, -0.9337422251701355, 0.9633687734603882, -0.11122908443212509, 0.20117036998271942, 1.9233232736587524, 0.4906342625617981, -0.40806886553764343, 0.7181940078735352, 1.1781734228134155, 0.636086106300354, -0.6949468851089478, 0.128716841340065, -0.7167973518371582, 0.22593075037002563, -1.4085880517959595, 0.18779775500297546, -2.8260273933410645, 0.688849925994873, -0.13381822407245636, -0.009807686321437359, 0.06328380852937698, -1.2568364143371582, 1.0887006521224976, 2.6176810264587402, -1.213621973991394, 0.4600883424282074, 0.33177170157432556, 1.1578704118728638, -1.5022735595703125, 0.3159189224243164, -0.4887625575065613, 2.051398277282715, 0.13072797656059265, 1.193165898323059, -0.4927999973297119, -2.1245856285095215, 0.6477394104003906, -1.2371643781661987, -1.0911450386047363, 0.8517055511474609, -0.8828927874565125, 0.13542187213897705, -1.3897590637207031, -0.175184965133667, -0.9045762419700623, -1.2226651906967163, 0.6846781373023987, 0.12176761031150818, 0.46577438712120056, -0.5761278867721558, 0.31686049699783325, -2.2005486488342285, -1.3991156816482544, -0.1758410781621933, -0.9538512229919434, 0.5213162302970886, -0.31017354130744934, 0.7084764242172241, -0.10407976061105728, 0.0430372878909111, 0.3309386968612671, 1.318770408630371, 3.348717451095581, 0.17515340447425842, 0.2829081416130066, -0.14449039101600647, -1.0870542526245117, 1.4144643545150757, 0.9171944260597229, -0.14366154372692108, -0.5670435428619385, -0.997800350189209, 1.2155356407165527, 2.023768186569214, 1.167592167854309, -0.009802639484405518, -0.8784997463226318, -0.759903609752655, 0.10379686206579208, 0.25537732243537903, 0.5104455351829529, 0.9213131070137024, -0.021208088845014572, 0.09389790892601013, 1.4555697441101074, 1.200437307357788, -0.3997768759727478, 0.44892457127571106, -0.8897857069969177, -0.43820005655288696, 0.4806699752807617, 0.29437482357025146, 0.08026807755231857, 0.3751542270183563, -1.1620678901672363, -0.26109185814857483, -0.3433627188205719, -0.9215573668479919, -0.7921968698501587, -0.4194919168949127, -0.3766903281211853, 1.5882607698440552, 0.016844378784298897, -0.4425775110721588, 0.0320875346660614, -0.70738285779953, -0.0716562494635582, -1.0999336242675781, 0.3154848515987396, -0.22099369764328003, -0.07016421854496002, -0.06176456809043884, 1.7364922761917114, -1.0360139608383179, -2.075015068054199, 0.2669884264469147, 0.21794277429580688, -0.46084165573120117, 0.1793491095304489, 1.6653977632522583, 0.6506366729736328, 1.3901398181915283, 1.3749363422393799, 0.9417028427124023, -0.6778217554092407, -1.2381361722946167, 0.6487528085708618, 0.9982767105102539, -1.3441718816757202, 0.8003121614456177, -0.08830880373716354, -0.6194608211517334, 0.6865065097808838, 1.3674370050430298, 0.4323992431163788, -2.061410903930664, 0.8589969277381897, -0.7813537120819092, 0.757745087146759, 0.6383434534072876, 0.8161249160766602, 0.1674720197916031, 0.7767757177352905, -1.3052926063537598, -1.153774619102478, -0.6927674412727356, -0.608227014541626, 1.856967568397522, -0.13371826708316803, 0.4889433681964874, -0.23217065632343292, -1.271668553352356, -0.06248579919338226, 0.66825932264328, 0.3653706908226013, -0.4573562443256378, 0.8052587509155273, -0.6327471137046814, -1.1534441709518433, -1.3407155275344849, -0.52386075258255, -0.9398311376571655, -0.8390513062477112, 0.9660094380378723, 0.7896210551261902, 0.402256578207016, 1.9198846817016602, 0.5924238562583923, 0.26589128375053406, -2.6608598232269287, 0.874292254447937, 0.3590207099914551, -0.0539853572845459, 0.896198034286499, 0.28815871477127075, 1.1334158182144165, 0.0002153012901544571, 0.5052038431167603, -2.2869763374328613, 2.25325083732605, -0.25411370396614075, 0.6932157278060913, -0.07041371613740921, -0.14313998818397522, 1.0383330583572388, 0.5616817474365234, 0.5796129703521729, -1.101224422454834, 0.7193713784217834, -0.6640297174453735, 1.1252970695495605, 0.8885372281074524, -0.8604974746704102, 0.050552934408187866, 1.360480785369873, 0.5180805921554565, -0.45547351241111755, -0.966614842414856, -0.8623656630516052, 0.9683844447135925, 1.7756761312484741, -0.09743856638669968, 0.10947950184345245, 0.8638472557067871, 0.6093246340751648, -1.3769633769989014, 0.06332956254482269, -0.7066547870635986, -0.7433028817176819, 1.6494418382644653, 1.9818404912948608, -0.06572575122117996, -0.15477952361106873, -0.7941001653671265, -1.278552770614624, 0.7940643429756165, -0.09366653859615326, 0.10756400972604752, 0.7079017758369446, -0.663037121295929, 1.2257226705551147, 0.6974050998687744, 0.9698978662490845, 0.06338147819042206, 0.3297213017940521, 0.3208882808685303, -0.3096247613430023, -1.144844651222229, -0.30827784538269043, -1.0109189748764038, -2.444662570953369, 0.5137019753456116, -0.23393599689006805, -1.511401891708374, 0.019332606345415115, -1.0007925033569336, 0.9518350958824158, -0.5714167356491089, -0.9881464242935181, -1.4962608814239502, 0.32564225792884827, -0.1379057615995407, 0.9537272453308105, -1.5865520238876343, -0.10259661823511124, 1.2467812299728394, 0.9274477958679199, -0.5354382395744324, 0.9824786186218262, 0.34805282950401306, 1.0151410102844238, 0.8484628200531006, -0.32906875014305115, 0.45407524704933167, 0.10437522083520889, -1.2881306409835815, 0.391207754611969, 1.2302972078323364, 0.19920866191387177, 1.4137765169143677, -0.5533700585365295, 0.04644846171140671, 0.37985867261886597, -0.47049421072006226, -0.4622054696083069, -0.5859838128089905, 0.6464348435401917, 0.03692641854286194, -0.9628061056137085, -0.005696311127394438, -0.14357611536979675, -0.17734688520431519, 0.29296064376831055, -1.5234346389770508, -0.2395317107439041, -0.3798275291919708, -0.5767189860343933, -1.2554287910461426, 0.01411493495106697, 1.3414490222930908, -0.805854856967926, -0.2040020227432251, 0.4588649570941925, 0.36568358540534973, 0.5623093843460083, 0.602109432220459, -0.6589640974998474, -0.3738182485103607, -0.33171549439430237, -0.3943466246128082, 0.23932497203350067, 1.2568554878234863, -0.15217457711696625, -1.0033161640167236, 0.7283524870872498, -0.42172443866729736, 0.06380727142095566, 1.974893569946289, 0.05738397687673569, -0.8288602828979492, 0.30658450722694397, -0.688997745513916, 1.8617748022079468, 1.705678105354309, 1.323581337928772, -0.1375524401664734, -0.9200477600097656, 0.576059877872467, -0.2474689781665802, -0.30711501836776733, 0.9389698505401611, 0.44735631346702576, -0.22188836336135864, -1.4038392305374146, 0.5487134456634521, 1.3150966167449951, -0.9251801371574402, -0.7660696506500244, 0.07566662132740021, -0.8609277009963989, 1.1251760721206665, 0.7321211695671082, 0.39012545347213745, 0.21750332415103912, 1.563052773475647, 0.7193735837936401, -0.5128246545791626, 0.5036107897758484, 0.4445142149925232, -0.11470363289117813, -2.1171891689300537, -0.9648699760437012, 0.33893489837646484, -0.32960349321365356, -1.6341255903244019, 1.369580626487732, -1.201473593711853, -0.9174994230270386, 0.46678462624549866, 0.13700929284095764, 1.366589069366455, 0.32202568650245667, 1.671387791633606, 2.1259894371032715, 0.9122681021690369, 0.30116480588912964, 1.305241584777832, -0.05356563627719879, -0.3690526485443115, 1.8081567287445068, -0.44467517733573914, 0.5638800859451294, 1.0142569541931152, -0.4048728048801422, -0.9905390739440918, -0.860892653465271, -1.2249585390090942, -0.7395230531692505, 1.1519114971160889, 0.062048569321632385, -1.1586506366729736, 0.2824033200740814, 1.587450623512268, 0.12397605180740356, -0.28095483779907227, 0.7339847087860107, 0.403898686170578, -0.7525765895843506, -0.16710400581359863, -0.9281139969825745, 0.46428588032722473, -0.10608174651861191, -0.2934702932834625, 0.25421133637428284, 0.5119466781616211, 1.278385877609253, -0.011922583915293217, 0.11463809013366699, 1.2905606031417847, -1.3379677534103394, 1.5001888275146484, -0.6586573719978333, 0.26797133684158325, -2.4272310733795166, 1.4193278551101685, -0.7648062705993652, 1.787002444267273, -2.6170032024383545, 0.4169744849205017, -0.5211918950080872, -0.4115491509437561, 0.27253273129463196, -0.3125403821468353, 0.150975301861763, -0.19613860547542572, -1.0658739805221558, -0.14208294451236725, -0.7950036525726318, 0.6036481857299805, 1.1941097974777222, 1.3629411458969116, -1.0520857572555542, -0.21823027729988098, -1.7400044202804565, -0.20594921708106995, -0.6931275129318237, 0.3439622223377228, -1.954814076423645, -0.14209850132465363, -1.9220540523529053, -2.4907305240631104, -1.3675105571746826, -0.8870952725410461, 1.1098637580871582, 0.16760779917240143, -0.9508993029594421, 1.1064708232879639, -0.4075580835342407, -1.8271571397781372, 1.0989915132522583, -2.200308322906494 ]
https://github.com/huggingface/datasets/issues/5200
Some links to canonical datasets in the docs are outdated
Thanks for catching this, I can go through the docs and replace the links to their corresponding datasets on the Hub!
As we don't have canonical datasets in the github repo anymore, some old links to them doesn't work. I don't know how many of them are there, I found link to SuperGlue here: https://huggingface.co/docs/datasets/dataset_script#multiple-configurations, probably there are more of them. These links should be replaced by links to the corresponding datasets on the Hub.
442
21
Some links to canonical datasets in the docs are outdated As we don't have canonical datasets in the github repo anymore, some old links to them doesn't work. I don't know how many of them are there, I found link to SuperGlue here: https://huggingface.co/docs/datasets/dataset_script#multiple-configurations, probably there are more of them. These links should be replaced by links to the corresponding datasets on the Hub. Thanks for catching this, I can go through the docs and replace the links to their corresponding datasets on the Hub!
[ -1.3324542045593262, -1.0137128829956055, -0.9206834435462952, 1.3249833583831787, -0.18255123496055603, -1.3979787826538086, 0.009944787248969078, -1.1800767183303833, 1.739585280418396, -0.7850052714347839, 0.23059406876564026, -1.6495558023452759, -0.050423383712768555, -0.506814181804657, -0.7500870823860168, -0.9349172711372375, -0.4514934718608856, -0.8435057401657104, 1.020133376121521, 2.4545493125915527, 1.133115530014038, -1.4075112342834473, 2.6918296813964844, 0.8015205264091492, -0.11598676443099976, -1.1010141372680664, 0.6428325176239014, 0.1021873950958252, -1.2130470275878906, -0.4546486735343933, -1.0166645050048828, 0.06545479595661163, -0.5938466787338257, -0.4761224687099457, 0.040695734322071075, 0.3779454827308655, -0.1562327891588211, -0.35038474202156067, -0.49805647134780884, -0.6151862144470215, 0.4579452872276306, -0.33079010248184204, 1.0355511903762817, -0.524506688117981, 1.840429663658142, -0.3506135642528534, 0.34166690707206726, 0.7039251327514648, 1.4759793281555176, 0.0879526436328888, 0.00886891782283783, 0.1971844881772995, 0.2737925350666046, 0.014268271625041962, 0.4081728458404541, 1.0624103546142578, 0.4666726291179657, 0.5856279730796814, 0.606425940990448, -2.145602226257324, 1.314456582069397, -1.0408251285552979, 0.34593844413757324, 1.5478307008743286, -0.9936855435371399, 0.37127771973609924, -1.7460051774978638, -0.07654882967472076, 0.6155524849891663, -2.3276286125183105, 0.20362316071987152, -1.0566784143447876, -0.44589367508888245, 0.9977962374687195, 0.3004034757614136, -1.317354679107666, 0.3199613690376282, -0.4796876907348633, 1.00660240650177, 0.6211854815483093, 1.2259429693222046, -1.5741121768951416, 0.22956377267837524, -0.3368464708328247, -0.0828063040971756, -1.4041143655776978, -1.4133774042129517, 0.41359779238700867, 0.5226462483406067, 0.6679171323776245, -0.05756452679634094, 0.8934786319732666, -1.0174219608306885, 0.7727352380752563, -0.752329409122467, -1.5720016956329346, -1.2142553329467773, -2.3937578201293945, -2.4379124641418457, 0.9410648941993713, -0.46767881512641907, -0.5693374276161194, 2.0961997509002686, -1.0426541566848755, -1.8010447025299072, 1.246964931488037, 0.3387224078178406, 0.17453452944755554, 2.400773048400879, 0.14328913390636444, -0.6428265571594238, 0.43212607502937317, -0.6584631204605103, 1.0111913681030273, -0.3429358899593353, 1.4069432020187378, 0.5128691792488098, -1.0030043125152588, 1.684409737586975, -0.5369066596031189, 0.6406065225601196, -0.5543714761734009, -0.6696967482566833, -0.9045435786247253, 0.4019024074077606, 1.7794396877288818, -0.2418082058429718, 1.6675583124160767, -0.40717613697052, -1.5685476064682007, -1.5912736654281616, 0.948854386806488, 0.6004253625869751, -0.9244256615638733, -0.019988249987363815, -0.2629300653934479, 0.017713535577058792, -0.04703264683485031, 1.1267441511154175, 1.20419442653656, 0.6351262331008911, -0.33472493290901184, -0.8777098059654236, 0.177954763174057, -0.058351583778858185, -0.7115375995635986, -1.7632949352264404, -0.3129565119743347, 0.10567151755094528, 0.6232312917709351, -1.1749212741851807, 1.7200288772583008, 1.0121225118637085, 1.9648152589797974, 0.8672136664390564, -0.31896886229515076, 1.4477614164352417, -0.10029847174882889, 1.872671127319336, -0.47330087423324585, 0.6080582737922668, -0.24981683492660522, -1.3074450492858887, 0.7484907507896423, -0.3993283212184906, -1.919974446296692, -0.9261156320571899, -0.9266063570976257, -0.26415252685546875, -0.6010234951972961, 1.0356063842773438, -0.3546348810195923, -1.3142168521881104, 0.1415519416332245, -0.535507321357727, 0.22864888608455658, -1.2629978656768799, 0.23716408014297485, 0.7180710434913635, -0.6559441089630127, -0.14154629409313202, -0.23297186195850372, -1.2457436323165894, -0.5490696430206299, 0.3959748446941376, 1.7417528629302979, -0.8636268973350525, 0.9124455451965332, 0.9677325487136841, -0.8079355955123901, -0.012124249711632729, 0.2782801389694214, -0.298809677362442, 0.8513224720954895, -1.0198619365692139, -0.5052912831306458, 1.1324478387832642, -0.1969173401594162, -0.689496636390686, 1.489456295967102, 0.7348458170890808, -0.9768027663230896, -0.11066196113824844, -0.23303358256816864, -0.8789600133895874, -0.07000074535608292, -1.6208398342132568, -0.16885189712047577, 0.19808073341846466, -1.4937572479248047, -0.4854651689529419, -0.2222086489200592, 1.3687182664871216, -0.10503029823303223, 1.3289800882339478, -0.2937750518321991, -0.2415768951177597, -0.37511226534843445, -0.565632164478302, 0.34218907356262207, -0.109815813601017, -0.6155878901481628, 0.3196428716182709, -0.894584596157074, 0.3475951850414276, 1.4605603218078613, 0.3100120723247528, 0.03405848145484924, 0.6039655804634094, 0.9711769819259644, 0.3466818630695343, -0.19171647727489471, -0.8973813056945801, -1.5324512720108032, 1.9510869979858398, -1.5113264322280884, 1.847011923789978, 0.6565139889717102, -0.14394629001617432, -1.7293548583984375, -1.8912001848220825, 1.4575629234313965, 1.2471238374710083, 2.2008044719696045, 0.5587390661239624, 0.2950476408004761, -0.8855257630348206, -0.7321411371231079, 0.2719874680042267, -0.990170419216156, -0.7516751885414124, 0.02375015802681446, 2.2188735008239746, 1.7665579319000244, -0.6051989793777466, -0.15569153428077698, -1.0658540725708008, 1.3084219694137573, -0.20002686977386475, 0.3654111921787262, 2.0157058238983154, -0.46496036648750305, -1.1219295263290405, 1.375535488128662, -2.44267201423645, 0.09835552424192429, 1.9580565690994263, 0.28964072465896606, 0.06491509079933167, -1.5089014768600464, -0.6883726716041565, -0.17005251348018646, -0.4995405673980713, -1.1988468170166016, 0.6605736017227173, -0.30340948700904846, -0.8507101535797119, -1.512697458267212, 0.0779990404844284, -1.1806682348251343, -1.6919697523117065, 0.5549886226654053, 1.8366142511367798, 1.987428903579712, -0.6586698889732361, 1.6349880695343018, -0.2067873179912567, 0.08756083250045776, 1.2533061504364014, 1.2056841850280762, 3.024240255355835, 1.8070439100265503, -1.1998512744903564, 0.6496027112007141, -0.03566117584705353, -0.5638913512229919, 1.118800401687622, -0.93541020154953, 1.3202682733535767, -0.13628506660461426, -1.1611603498458862, -1.3158842325210571, 0.9057251811027527, 0.5303642749786377, 0.149221271276474, -0.5071054697036743, 1.2804169654846191, 0.00012877583503723145, 1.2988423109054565, 0.4842069745063782, -0.538902997970581, 0.525574266910553, -0.4328540861606598, -0.6157580614089966, 1.5921417474746704, 0.1100626140832901, -1.6078922748565674, -2.253889799118042, -0.33376967906951904, -0.6954163908958435, -0.047554075717926025, -0.5783500671386719, -0.9304704070091248, 1.5199049711227417, 0.4746242165565491, -1.169632911682129, -0.2720164954662323, -0.42158883810043335, -0.634385347366333, 2.610111713409424, -1.3373205661773682, -0.2074296772480011, -0.800899088382721, -0.47950130701065063, 1.6459298133850098, -1.1983267068862915, -0.1915782392024994, -1.0526862144470215, -0.7257320880889893, -1.4086917638778687, -0.5454220175743103, 0.14321330189704895, -1.0246543884277344, 0.8536173105239868, -0.007896709255874157, -0.9882708787918091, -0.19400370121002197, -0.7695136070251465, 0.9359404444694519, -0.1043134480714798, 0.4021582305431366, 1.8588407039642334, 0.42960241436958313, -0.36453428864479065, 0.7013683319091797, 1.3142316341400146, 0.6273446679115295, -0.6984773278236389, 0.18552929162979126, -0.6679226160049438, 0.32519209384918213, -1.3256486654281616, 0.2521643042564392, -3.048542022705078, 0.6680236458778381, -0.1692996770143509, -0.0616331472992897, 0.026559045538306236, -1.345579743385315, 1.1356492042541504, 2.5183632373809814, -1.2896950244903564, 0.4374421536922455, 0.4014787971973419, 1.1404610872268677, -1.4975229501724243, 0.30770257115364075, -0.4343579411506653, 2.0738065242767334, 0.04711553454399109, 1.112538456916809, -0.5203979015350342, -2.066549777984619, 0.6944943070411682, -1.2713054418563843, -1.1884618997573853, 0.7450162768363953, -0.866650402545929, 0.10206776857376099, -1.6097265481948853, -0.04662229120731354, -0.9179821610450745, -1.301966905593872, 0.7828174233436584, 0.2655675411224365, 0.35574477910995483, -0.5945211052894592, 0.3685172498226166, -2.181154727935791, -1.2462666034698486, -0.11844069510698318, -0.9555065631866455, 0.4922758638858795, -0.3253174126148224, 0.5770871639251709, -0.1600945144891739, 0.1345137357711792, 0.33295175433158875, 1.285990834236145, 3.40252947807312, 0.025473175570368767, 0.40609657764434814, -0.08225549757480621, -0.9873040318489075, 1.63108229637146, 1.13722825050354, -0.06648881733417511, -0.5444173216819763, -0.9138405323028564, 1.256093978881836, 1.975649356842041, 1.0991430282592773, 0.07928293943405151, -0.8838880658149719, -0.45732182264328003, -0.047187045216560364, 0.19482477009296417, 0.5454740524291992, 0.9712470769882202, -0.08529354631900787, 0.022211218252778053, 1.398972511291504, 1.2551343441009521, -0.3887783885002136, 0.48437079787254333, -0.8596007227897644, -0.44105979800224304, 0.4309319853782654, 0.33515244722366333, -0.0015067104250192642, 0.42544862627983093, -0.9341701865196228, -0.2872123718261719, -0.24435487389564514, -0.9739442467689514, -0.5955599546432495, -0.39387956261634827, -0.5258949398994446, 1.6029012203216553, 0.10310668498277664, -0.6091645359992981, -0.014002727344632149, -0.8126067519187927, -0.15742705762386322, -1.0969592332839966, 0.24148307740688324, -0.17782087624073029, -0.06652750074863434, -0.23683801293373108, 1.7231009006500244, -1.0973068475723267, -2.2170443534851074, 0.20938009023666382, 0.3202719986438751, -0.28331515192985535, 0.16227424144744873, 1.56658935546875, 0.431112676858902, 1.548624038696289, 1.358393907546997, 0.912068247795105, -0.6645665764808655, -1.359521508216858, 0.7278156280517578, 1.0107877254486084, -1.3877599239349365, 0.8066437244415283, -0.05342749506235123, -0.6246656775474548, 0.7542996406555176, 1.2004607915878296, 0.39809373021125793, -1.8853230476379395, 0.9990367293357849, -0.8762609362602234, 0.8445107340812683, 0.5296212434768677, 0.818402111530304, 0.2090935856103897, 0.8532441854476929, -1.2322520017623901, -1.1493091583251953, -0.8015540242195129, -0.6882582902908325, 2.066314697265625, -0.21680396795272827, 0.5398035645484924, -0.18487706780433655, -1.1346441507339478, -0.19860409200191498, 0.6265504956245422, 0.41555964946746826, -0.3021880090236664, 0.7986055016517639, -0.6762675046920776, -1.0834033489227295, -1.562046766281128, -0.3965963125228882, -0.9514026641845703, -0.711365818977356, 1.0520222187042236, 0.8331639170646667, 0.17454546689987183, 1.8988739252090454, 0.4796571731567383, 0.30297428369522095, -2.548004150390625, 0.8473016619682312, 0.35882824659347534, -0.07489508390426636, 0.8665063381195068, 0.31495681405067444, 1.1232424974441528, -0.10754678398370743, 0.49390408396720886, -2.1949217319488525, 2.1733710765838623, -0.26802363991737366, 0.5939804315567017, 0.0583212748169899, -0.16276688873767853, 1.2302190065383911, 0.58177250623703, 0.6142411828041077, -1.1896954774856567, 0.7421992421150208, -0.534874677658081, 1.223855972290039, 1.0744508504867554, -0.8012439012527466, -0.0370776541531086, 1.3666472434997559, 0.608810544013977, -0.3590286672115326, -0.9469215273857117, -0.7035875916481018, 0.9710774421691895, 1.6361380815505981, -0.0809096097946167, 0.012923330068588257, 0.7819532752037048, 0.6373370885848999, -1.3443191051483154, 0.03126625716686249, -0.767274796962738, -0.7163134217262268, 1.6012030839920044, 1.940065622329712, 0.10329873859882355, -0.09139323979616165, -0.7856394052505493, -1.2119601964950562, 0.7010214328765869, -0.1255176067352295, 0.2048809975385666, 0.5948958396911621, -0.6998141407966614, 1.2209243774414062, 0.9296156167984009, 0.7703010439872742, -0.06404060125350952, 0.2717934846878052, 0.3385065793991089, -0.0884467214345932, -1.040492296218872, -0.24547240138053894, -1.0246622562408447, -2.5310370922088623, 0.4827592670917511, -0.41498684883117676, -1.5165141820907593, -0.09875909239053726, -1.0043563842773438, 1.0759944915771484, -0.4962559640407562, -1.0520745515823364, -1.547808051109314, 0.18765926361083984, -0.09794293344020844, 0.8617087006568909, -1.4923820495605469, -0.13065071403980255, 1.340927004814148, 0.7945374846458435, -0.7838689088821411, 1.1824558973312378, 0.32437825202941895, 1.0564489364624023, 0.615740180015564, -0.5703427195549011, 0.4369238317012787, 0.0885758176445961, -1.469164252281189, 0.4946111738681793, 0.9932581782341003, 0.127630352973938, 1.3466527462005615, -0.48068317770957947, 0.08351217955350876, 0.553400456905365, -0.5038749575614929, -0.5291162729263306, -0.47856539487838745, 0.7583478689193726, 0.0546385794878006, -0.8397642970085144, -0.01982569321990013, -0.2059132605791092, -0.34380969405174255, 0.17466171085834503, -1.4762016534805298, -0.5075921416282654, -0.5535823702812195, -0.37926048040390015, -1.289272665977478, 0.1768583059310913, 1.3820488452911377, -0.6955228447914124, -0.23358318209648132, 0.5342715382575989, 0.48432299494743347, 0.510016143321991, 0.752062976360321, -0.662676990032196, -0.20304401218891144, -0.37427082657814026, -0.2983349859714508, 0.19029028713703156, 1.3085263967514038, -0.2453490048646927, -1.0117478370666504, 0.7149195075035095, -0.32513779401779175, -0.010785183869302273, 2.096250534057617, 0.043252237141132355, -0.9057818055152893, 0.44537729024887085, -0.7455451488494873, 1.887651801109314, 1.6315875053405762, 1.3009182214736938, -0.15319590270519257, -0.7925508618354797, 0.5913335680961609, -0.15350915491580963, -0.20960931479930878, 0.9301268458366394, 0.5455111861228943, -0.09987001866102219, -1.5344666242599487, 0.5161498188972473, 1.1418663263320923, -0.8280722498893738, -0.6607356667518616, 0.04967767745256424, -0.7834412455558777, 1.0492385625839233, 0.8271688222885132, 0.5514187216758728, 0.32927852869033813, 1.5947946310043335, 0.6154828667640686, -0.529546320438385, 0.4261999726295471, 0.5351924896240234, -0.12981842458248138, -2.0762975215911865, -0.9949209690093994, 0.31511399149894714, -0.5675269365310669, -1.5165351629257202, 1.3065346479415894, -1.0644848346710205, -0.8118739128112793, 0.46869340538978577, -0.011324516497552395, 1.4811972379684448, 0.41013699769973755, 1.6630221605300903, 2.0284626483917236, 0.9593402743339539, 0.21394795179367065, 1.5511820316314697, -0.11434223502874374, -0.2875576317310333, 1.8856648206710815, -0.39428502321243286, 0.46273869276046753, 1.2044867277145386, -0.40266817808151245, -0.8291261792182922, -0.6931466460227966, -1.1420190334320068, -0.5192852020263672, 1.135905385017395, 0.1182815283536911, -1.1424620151519775, 0.18137891590595245, 1.580665946006775, 0.07314376533031464, -0.29789918661117554, 0.6060888767242432, 0.48202553391456604, -0.8217092752456665, -0.07798043638467789, -0.9406164884567261, 0.42131128907203674, -0.22188682854175568, -0.41423937678337097, 0.38684335350990295, 0.4118603467941284, 1.2826600074768066, -0.09163437783718109, 0.2844589948654175, 1.1006851196289062, -1.4639452695846558, 1.4053804874420166, -0.703692615032196, 0.22171662747859955, -2.445821523666382, 1.3801534175872803, -0.7176674604415894, 2.073934555053711, -2.7037928104400635, 0.31526172161102295, -0.5784955024719238, -0.41632235050201416, 0.3924470841884613, -0.40041014552116394, 0.10131441801786423, -0.11970949172973633, -1.0500563383102417, 0.007872644811868668, -0.6802985668182373, 0.758880615234375, 1.2372251749038696, 1.2101110219955444, -0.9967450499534607, -0.37444397807121277, -1.7568297386169434, -0.2879561483860016, -0.7315163612365723, 0.4429464638233185, -2.14974045753479, -0.29399603605270386, -1.8828095197677612, -2.4120569229125977, -1.3926283121109009, -0.8111260533332825, 1.333807110786438, 0.22112348675727844, -1.0386000871658325, 1.139777660369873, -0.34947842359542847, -1.7277261018753052, 0.9894399642944336, -2.184969186782837 ]
https://github.com/huggingface/datasets/issues/5193
"One or several metadata. were found, but not in the same directory or in a parent directory"
Also unrelated but still: https://huggingface.co/docs/datasets/image_dataset#generate-the-dataset ```If your loading script passed the test, you should now have a dataset_infos.json file in your dataset folder.``` It's not the case anymore as it's now in the readme.md, it was confusing to me
### Describe the bug When loading my own dataset, on loading it I get an error. Here is my dataset link: https://huggingface.co/datasets/corentinm7/MyoQuant-SDH-Data And the error after loading with: ```python from datasets import load_dataset load_dataset("corentinm7/MyoQuant-SDH-Data") ``` ```python Downloading readme: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.34k/3.34k [00:00<00:00, 4.45MB/s] Using custom data configuration SDH_16k-53e7301a92ab0025 Downloading and preparing dataset None/SDH_16k to /home/corentin/.cache/huggingface/datasets/corentinm7___imagefolder/SDH_16k-53e7301a92ab0025/0.0.0/37fbb85cc714a338bea574ac6c7d0b5be5aff46c1862c1989b20e0771199e93f... Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.28M/3.28M [00:00<00:00, 4.31MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:01<00:00, 1.75s/it] Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1.13G/1.13G [00:15<00:00, 74.3MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:16<00:00, 16.09s/it] Extracting data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:13<00:00, 13.16s/it] Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/load.py", line 1742, in load_dataset builder_instance.download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 814, in download_and_prepare self._download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 1423, in _download_and_prepare super()._download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 905, in _download_and_prepare self._prepare_split(split_generator, **prepare_split_kwargs) File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 1374, in _prepare_split for key, record in logging.tqdm( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/tqdm/std.py", line 1195, in __iter__ for obj in iterable: File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/packaged_modules/folder_based_builder/folder_based_builder.py", line 394, in _generate_examples raise ValueError( ValueError: One or several metadata. were found, but not in the same directory or in a parent directory of /home/corentin/.cache/huggingface/datasets/downloads/extracted/60c4aa8d4da3065bb3d310de4373dffd73bd4dc331aedcb4ee867febe4fdb7cd/validation/sick/2_CG_SDH_TAM_Bin1cKO_ko_pla_4_1640.tif. ``` However the test command is working fine. ```datasets-cli test hugging_face_play/ds_test/SDH_16k.py --save_info --all_configs --force_redownload``` ``` Using custom data configuration SDH_16k Testing builder 'SDH_16k' (1/1) Downloading and preparing dataset sdh_16k/SDH_16k to /home/corentin/.cache/huggingface/datasets/sdh_16k/SDH_16k/1.0.0/21b584239a638aeeda33cba1ac2ca4869d48e4b4f20fb22274d5a5ddc487659d... Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1.13G/1.13G [00:14<00:00, 76.5MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:15<00:00, 15.66s/it] Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.28M/3.28M [00:02<00:00, 1.44MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:03<00:00, 3.21s/it] Downloading data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:00<00:00, 11586.48it/s] Extracting data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:13<00:00, 13.42s/it] Dataset sdh_16k downloaded and prepared to /home/corentin/.cache/huggingface/datasets/sdh_16k/SDH_16k/1.0.0/21b584239a638aeeda33cba1ac2ca4869d48e4b4f20fb22274d5a5ddc487659d. Subsequent calls will reuse this data. 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3/3 [00:00<00:00, 605.27it/s] Dataset card saved at hugging_face_play/ds_test/README.md Test successful. ``` ### Steps to reproduce the bug Simply run on python ```python from datasets import load_dataset load_dataset("corentinm7/MyoQuant-SDH-Data") ``` ### Expected behavior As the test command worked, this error should not appear ### Environment info - `datasets` version: 2.6.1 - Platform: Linux-5.10.16.3-microsoft-standard-WSL2-x86_64-with-glibc2.31 - Python version: 3.10.6 - PyArrow version: 10.0.0 - Pandas version: 1.5.1
443
39
"One or several metadata. were found, but not in the same directory or in a parent directory" ### Describe the bug When loading my own dataset, on loading it I get an error. Here is my dataset link: https://huggingface.co/datasets/corentinm7/MyoQuant-SDH-Data And the error after loading with: ```python from datasets import load_dataset load_dataset("corentinm7/MyoQuant-SDH-Data") ``` ```python Downloading readme: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.34k/3.34k [00:00<00:00, 4.45MB/s] Using custom data configuration SDH_16k-53e7301a92ab0025 Downloading and preparing dataset None/SDH_16k to /home/corentin/.cache/huggingface/datasets/corentinm7___imagefolder/SDH_16k-53e7301a92ab0025/0.0.0/37fbb85cc714a338bea574ac6c7d0b5be5aff46c1862c1989b20e0771199e93f... Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.28M/3.28M [00:00<00:00, 4.31MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:01<00:00, 1.75s/it] Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1.13G/1.13G [00:15<00:00, 74.3MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:16<00:00, 16.09s/it] Extracting data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:13<00:00, 13.16s/it] Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/load.py", line 1742, in load_dataset builder_instance.download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 814, in download_and_prepare self._download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 1423, in _download_and_prepare super()._download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 905, in _download_and_prepare self._prepare_split(split_generator, **prepare_split_kwargs) File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 1374, in _prepare_split for key, record in logging.tqdm( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/tqdm/std.py", line 1195, in __iter__ for obj in iterable: File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/packaged_modules/folder_based_builder/folder_based_builder.py", line 394, in _generate_examples raise ValueError( ValueError: One or several metadata. were found, but not in the same directory or in a parent directory of /home/corentin/.cache/huggingface/datasets/downloads/extracted/60c4aa8d4da3065bb3d310de4373dffd73bd4dc331aedcb4ee867febe4fdb7cd/validation/sick/2_CG_SDH_TAM_Bin1cKO_ko_pla_4_1640.tif. ``` However the test command is working fine. ```datasets-cli test hugging_face_play/ds_test/SDH_16k.py --save_info --all_configs --force_redownload``` ``` Using custom data configuration SDH_16k Testing builder 'SDH_16k' (1/1) Downloading and preparing dataset sdh_16k/SDH_16k to /home/corentin/.cache/huggingface/datasets/sdh_16k/SDH_16k/1.0.0/21b584239a638aeeda33cba1ac2ca4869d48e4b4f20fb22274d5a5ddc487659d... Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1.13G/1.13G [00:14<00:00, 76.5MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:15<00:00, 15.66s/it] Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.28M/3.28M [00:02<00:00, 1.44MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:03<00:00, 3.21s/it] Downloading data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:00<00:00, 11586.48it/s] Extracting data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:13<00:00, 13.42s/it] Dataset sdh_16k downloaded and prepared to /home/corentin/.cache/huggingface/datasets/sdh_16k/SDH_16k/1.0.0/21b584239a638aeeda33cba1ac2ca4869d48e4b4f20fb22274d5a5ddc487659d. Subsequent calls will reuse this data. 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3/3 [00:00<00:00, 605.27it/s] Dataset card saved at hugging_face_play/ds_test/README.md Test successful. ``` ### Steps to reproduce the bug Simply run on python ```python from datasets import load_dataset load_dataset("corentinm7/MyoQuant-SDH-Data") ``` ### Expected behavior As the test command worked, this error should not appear ### Environment info - `datasets` version: 2.6.1 - Platform: Linux-5.10.16.3-microsoft-standard-WSL2-x86_64-with-glibc2.31 - Python version: 3.10.6 - PyArrow version: 10.0.0 - Pandas version: 1.5.1 Also unrelated but still: https://huggingface.co/docs/datasets/image_dataset#generate-the-dataset ```If your loading script passed the test, you should now have a dataset_infos.json file in your dataset folder.``` It's not the case anymore as it's now in the readme.md, it was confusing to me
[ -1.1513481140136719, -0.8950071930885315, -0.7690081000328064, 1.4270761013031006, -0.05569703131914139, -1.244236946105957, 0.12335053086280823, -1.1508922576904297, 1.5475118160247803, -0.6729012131690979, 0.29542702436447144, -1.7627599239349365, -0.03960840404033661, -0.5458818674087524, -0.7904717326164246, -0.8730937242507935, -0.39900246262550354, -0.8042073249816895, 0.9166461825370789, 2.4917469024658203, 1.2181382179260254, -1.355351448059082, 2.7918732166290283, 0.6390748023986816, -0.26768362522125244, -0.9507211446762085, 0.5859518647193909, 0.056174591183662415, -1.3944108486175537, -0.3314271867275238, -0.8961967825889587, -0.0630229040980339, -0.5856070518493652, -0.44000744819641113, 0.16081306338310242, 0.39702466130256653, -0.2866356670856476, -0.4238445460796356, -0.5518879294395447, -0.7803190350532532, 0.5477887988090515, -0.30618831515312195, 0.9749169945716858, -0.356801837682724, 1.7831218242645264, -0.6768479943275452, 0.3875423073768616, 0.7589303851127625, 1.260462760925293, 0.1495506763458252, 0.11132361739873886, 0.3958492875099182, 0.3549879789352417, 0.011983383446931839, 0.37305545806884766, 1.2434604167938232, 0.5187172889709473, 0.4216814637184143, 0.7459096908569336, -2.124134063720703, 1.3102226257324219, -0.9111434817314148, 0.2678227126598358, 1.361147165298462, -0.7931784987449646, 0.2778749167919159, -1.8839540481567383, -0.11444097757339478, 0.5824437141418457, -2.1739790439605713, 0.2869797945022583, -1.272953987121582, -0.5031480193138123, 0.9034112691879272, 0.34270286560058594, -1.0776703357696533, 0.2140909731388092, -0.5959327220916748, 1.0001859664916992, 0.4509925842285156, 1.1855924129486084, -1.6878068447113037, -0.0600484199821949, -0.2128417193889618, 0.13158097863197327, -1.34938645362854, -1.6057531833648682, 0.6287413835525513, 0.6119655966758728, 0.676578164100647, -0.0882943645119667, 1.0231482982635498, -1.0165541172027588, 0.8717881441116333, -0.9961537718772888, -1.7461130619049072, -1.3024768829345703, -2.314701795578003, -2.3139610290527344, 0.7555503845214844, -0.439631849527359, -0.45525044202804565, 1.9843285083770752, -0.9247167706489563, -1.7471132278442383, 1.0836687088012695, 0.28158020973205566, -0.028086910024285316, 2.396171808242798, 0.2568790912628174, -0.779274046421051, 0.4610007405281067, -0.7601338624954224, 0.7869120240211487, -0.20604504644870758, 1.3353841304779053, 0.4674963355064392, -0.8935851454734802, 1.548727035522461, -0.4630432426929474, 0.5005245208740234, -0.7024719715118408, -0.5334359407424927, -0.7364922761917114, 0.23865658044815063, 1.9233484268188477, -0.42383038997650146, 1.5508630275726318, -0.3679881691932678, -1.6113908290863037, -1.495116949081421, 0.8324441313743591, 0.5686793923377991, -0.8695210814476013, 0.03016284480690956, -0.39604976773262024, 0.18780970573425293, 0.008881762623786926, 1.0786433219909668, 1.2615690231323242, 0.7484303116798401, -0.3310778737068176, -0.8446767330169678, 0.19008518755435944, -0.11297627538442612, -0.8354676365852356, -1.7350094318389893, -0.324643075466156, 0.22538529336452484, 0.6949381828308105, -1.353224754333496, 1.7768988609313965, 0.9033784866333008, 2.062497615814209, 0.9594843983650208, -0.4511496424674988, 1.5336472988128662, 0.03194117546081543, 1.8902013301849365, -0.4876079261302948, 0.6098837852478027, -0.43267345428466797, -1.102311611175537, 0.8554531335830688, -0.2887655198574066, -1.9970715045928955, -0.8012484312057495, -0.8494881391525269, -0.14663003385066986, -0.7619706988334656, 0.9281796216964722, -0.31167641282081604, -1.5509533882141113, 0.19786155223846436, -0.7092428803443909, 0.02716352418065071, -1.2282228469848633, 0.13936936855316162, 0.651091992855072, -0.6888821125030518, 0.0740366280078888, -0.19999133050441742, -1.3391478061676025, -0.4930115342140198, 0.3091401159763336, 1.9523181915283203, -0.7012122273445129, 0.9624255895614624, 1.0754199028015137, -0.6794649958610535, 0.14529035985469818, 0.328689843416214, -0.33727362751960754, 0.7726941108703613, -1.208702564239502, -0.38269293308258057, 1.0776350498199463, -0.04745514318346977, -0.5583831071853638, 1.4944581985473633, 0.8078822493553162, -1.0622241497039795, -0.2787948250770569, -0.1408083289861679, -0.8132069110870361, -0.032916173338890076, -1.5833837985992432, -0.06800748407840729, 0.32760000228881836, -1.437854290008545, -0.43708252906799316, -0.26154905557632446, 1.1959543228149414, -0.14346742630004883, 1.4330010414123535, -0.3074665367603302, -0.2247018963098526, -0.3905750811100006, -0.45016953349113464, 0.09773241728544235, -0.32931894063949585, -0.5874088406562805, 0.23618637025356293, -0.847489058971405, 0.26867958903312683, 1.5039350986480713, 0.27552685141563416, 0.09165970236063004, 0.45360052585601807, 1.1524734497070312, 0.36595606803894043, 0.06776563078165054, -0.8602113127708435, -1.509901523590088, 2.0463716983795166, -1.5893404483795166, 1.9567499160766602, 0.7536913156509399, -0.01516249030828476, -1.836583137512207, -1.8751928806304932, 1.3658771514892578, 1.0911085605621338, 2.451479911804199, 0.5792697072029114, 0.43776679039001465, -0.7700514793395996, -0.7366793751716614, 0.3618931472301483, -0.935401976108551, -0.6850456595420837, 0.26834145188331604, 2.3727428913116455, 1.706296682357788, -0.5786855816841125, -0.2310444563627243, -0.8549292087554932, 1.3564746379852295, -0.0768507793545723, 0.20616069436073303, 2.04994797706604, -0.19971463084220886, -1.118680477142334, 1.262486219406128, -2.3488731384277344, 0.1674761027097702, 2.003664016723633, 0.2983110547065735, 0.12134553492069244, -1.4230964183807373, -0.6571397185325623, -0.3851408362388611, -0.4624551832675934, -1.2292499542236328, 0.6096989512443542, -0.29440250992774963, -0.9131664633750916, -1.474195957183838, 0.03905776888132095, -1.1584880352020264, -1.7335197925567627, 0.3595767319202423, 1.8945825099945068, 2.1348023414611816, -0.7562553882598877, 1.441354513168335, -0.33584165573120117, 0.04444023594260216, 1.1793906688690186, 1.292923927307129, 3.0534279346466064, 1.8321499824523926, -1.2424020767211914, 0.7614278197288513, -0.14163008332252502, -0.45329415798187256, 1.082557201385498, -1.0869264602661133, 1.1351773738861084, -0.19746308028697968, -1.205437421798706, -1.1502463817596436, 1.0558764934539795, 0.3917936086654663, 0.04795142263174057, -0.5126159191131592, 1.311513900756836, 0.07889058440923691, 1.3403947353363037, 0.5844317674636841, -0.2719807028770447, 0.56777024269104, -0.36403506994247437, -0.5597935318946838, 1.6431701183319092, 0.1781744658946991, -1.4560937881469727, -2.516721487045288, -0.2649511694908142, -0.8839423656463623, 0.035654496401548386, -0.6581291556358337, -1.1138861179351807, 1.6405889987945557, 0.3793220520019531, -1.307363748550415, -0.2525630593299866, -0.349832683801651, -0.5881023406982422, 2.626633644104004, -1.416243076324463, -0.10334441810846329, -0.9074795246124268, -0.5116516947746277, 1.6082003116607666, -1.1500682830810547, -0.24226710200309753, -1.1136605739593506, -0.567676842212677, -1.350315809249878, -0.5899694561958313, 0.0623999685049057, -0.895219087600708, 0.7958406805992126, 0.17607825994491577, -1.0855822563171387, -0.26272884011268616, -0.9276371598243713, 0.9914315342903137, -0.0545816607773304, 0.25904616713523865, 1.8715956211090088, 0.40830036997795105, -0.3789440393447876, 0.7166363596916199, 1.1759214401245117, 0.6499977111816406, -0.6554539799690247, 0.06486876308917999, -0.6491432785987854, 0.23234140872955322, -1.408212661743164, 0.24928516149520874, -2.823524236679077, 0.7073701024055481, -0.09373742341995239, 0.0020622191950678825, -0.044905729591846466, -1.2705597877502441, 1.1748764514923096, 2.6833372116088867, -1.142648458480835, 0.5339173674583435, 0.35736438632011414, 1.1827950477600098, -1.4712300300598145, 0.26699885725975037, -0.39934059977531433, 2.0325000286102295, 0.06230513006448746, 1.170525312423706, -0.5601316094398499, -2.177494525909424, 0.6072453260421753, -1.2915232181549072, -1.093179702758789, 0.8512124419212341, -0.8744171261787415, 0.2232491374015808, -1.4630002975463867, -0.27639174461364746, -0.9837376475334167, -1.236189365386963, 0.6797045469284058, 0.11581212282180786, 0.5405554175376892, -0.543260931968689, 0.37450990080833435, -2.2846362590789795, -1.446869134902954, -0.17385882139205933, -1.0147674083709717, 0.5676365494728088, -0.3260263502597809, 0.7176563739776611, -0.09841689467430115, 0.06029035151004791, 0.4273790419101715, 1.3145558834075928, 3.360629081726074, 0.1646161824464798, 0.26494458317756653, -0.12166551500558853, -1.0329430103302002, 1.358548879623413, 0.9996828436851501, -0.10063111037015915, -0.5722072124481201, -1.0157599449157715, 1.2015328407287598, 2.03369140625, 1.0931243896484375, -0.01000891625881195, -0.8446508049964905, -0.8463783264160156, 0.1345713883638382, 0.2113482654094696, 0.6129223704338074, 0.956882894039154, -0.055721789598464966, 0.11378221213817596, 1.472623348236084, 1.1372480392456055, -0.436359703540802, 0.44929632544517517, -0.9114785194396973, -0.4093230366706848, 0.47958919405937195, 0.18357770144939423, 0.04459501802921295, 0.4212489128112793, -1.0924553871154785, -0.30797532200813293, -0.30899161100387573, -0.8948781490325928, -0.6658729910850525, -0.43526262044906616, -0.4302772581577301, 1.5971639156341553, 0.08876854926347733, -0.44572558999061584, 0.10277868807315826, -0.6755667328834534, -0.15152379870414734, -1.1707265377044678, 0.22035850584506989, -0.2043609917163849, -0.022755460813641548, -0.08342966437339783, 1.837325096130371, -0.9350897073745728, -2.0669143199920654, 0.16520848870277405, 0.2813240587711334, -0.3923700451850891, 0.24408817291259766, 1.70039963722229, 0.6338827013969421, 1.3505780696868896, 1.2984814643859863, 0.8921394348144531, -0.6856156587600708, -1.257873773574829, 0.6068567633628845, 0.9351285099983215, -1.3557560443878174, 0.7877652645111084, -0.12785778939723969, -0.4687468111515045, 0.644012451171875, 1.34373140335083, 0.3852587938308716, -2.0921084880828857, 0.8778418898582458, -0.8541280627250671, 0.7719696164131165, 0.7038345336914062, 0.7436479926109314, 0.20975252985954285, 0.7769941687583923, -1.2338426113128662, -1.086381435394287, -0.8179945945739746, -0.6450372338294983, 1.8991057872772217, -0.1962120682001114, 0.40249213576316833, -0.22068285942077637, -1.1977481842041016, -0.10834809392690659, 0.7151972651481628, 0.3748984634876251, -0.43124130368232727, 0.7780368328094482, -0.5401567220687866, -1.1127324104309082, -1.2308645248413086, -0.5540781021118164, -1.0293517112731934, -0.9000663757324219, 0.941565990447998, 0.7121763825416565, 0.42758920788764954, 1.8834295272827148, 0.6826808452606201, 0.24039563536643982, -2.697089433670044, 0.9418428540229797, 0.30148816108703613, -0.04596703499555588, 0.9811089038848877, 0.33273079991340637, 1.1527118682861328, -0.05802620202302933, 0.5842932462692261, -2.4085745811462402, 2.2982699871063232, -0.23040863871574402, 0.7362977862358093, -0.043138958513736725, -0.23207098245620728, 1.1067941188812256, 0.5272631645202637, 0.5380838513374329, -1.0799355506896973, 0.6497417092323303, -0.7008094787597656, 1.0924787521362305, 0.850045382976532, -0.8871825933456421, 0.0878080502152443, 1.2750964164733887, 0.4982439875602722, -0.4196550250053406, -0.9472859501838684, -0.8253911137580872, 0.9836701154708862, 1.6957314014434814, -0.08405783027410507, 0.08703908324241638, 0.9426915049552917, 0.5794355869293213, -1.3065645694732666, 0.009720170870423317, -0.6990299820899963, -0.8183271884918213, 1.7513439655303955, 2.132476806640625, -0.09379429370164871, -0.09737097471952438, -0.7643058896064758, -1.2322075366973877, 0.7723854184150696, -0.06378144770860672, 0.1612231433391571, 0.5317140221595764, -0.712695300579071, 1.242621898651123, 0.6372846961021423, 0.9686493277549744, 0.08572104573249817, 0.3713941276073456, 0.2943043112754822, -0.3413039445877075, -1.1585943698883057, -0.3764116168022156, -1.068821907043457, -2.4039623737335205, 0.5434005856513977, -0.14232264459133148, -1.4884283542633057, 0.04628803953528404, -0.9921693205833435, 0.8899607062339783, -0.5686308145523071, -1.0231549739837646, -1.4575176239013672, 0.3554272949695587, -0.23128998279571533, 1.009629487991333, -1.644036054611206, -0.08741676062345505, 1.2032442092895508, 0.893016517162323, -0.5762561559677124, 0.9623696804046631, 0.3390819728374481, 1.0059046745300293, 0.8208916783332825, -0.3177860975265503, 0.5695604085922241, 0.1117515116930008, -1.2789876461029053, 0.40760537981987, 1.1903886795043945, 0.14040744304656982, 1.436255693435669, -0.4422539472579956, 0.07354798167943954, 0.35420385003089905, -0.46131688356399536, -0.4501640200614929, -0.5442419052124023, 0.5951755046844482, 0.15469776093959808, -1.0739636421203613, -0.1181337758898735, -0.04441928490996361, -0.19752788543701172, 0.2941344976425171, -1.500652551651001, -0.29525208473205566, -0.3711174428462982, -0.4850594997406006, -1.2491703033447266, 0.05569808930158615, 1.3067777156829834, -0.8017001152038574, -0.23832285404205322, 0.4000936448574066, 0.3669297397136688, 0.5967146754264832, 0.639492392539978, -0.6759822964668274, -0.3874078691005707, -0.30812960863113403, -0.34758180379867554, 0.23947565257549286, 1.2277140617370605, -0.10522263497114182, -1.0755610466003418, 0.7324354648590088, -0.4545269310474396, 0.09479999542236328, 1.9358851909637451, -0.04677160829305649, -0.7268698215484619, 0.31264176964759827, -0.6923533082008362, 1.9189105033874512, 1.7735915184020996, 1.272773027420044, -0.20546264946460724, -0.8926507234573364, 0.5763269066810608, -0.31978654861450195, -0.22494478523731232, 0.9336066842079163, 0.4297490119934082, -0.19055216014385223, -1.4224355220794678, 0.486291766166687, 1.363673448562622, -0.893842875957489, -0.7976875305175781, 0.13479283452033997, -0.8358256220817566, 1.1265802383422852, 0.7129209637641907, 0.32614389061927795, 0.3083014488220215, 1.5180299282073975, 0.7791673541069031, -0.5000765323638916, 0.5970894694328308, 0.4158252775669098, -0.12339584529399872, -2.1541597843170166, -1.1511454582214355, 0.3774460256099701, -0.29745033383369446, -1.608638048171997, 1.3731272220611572, -1.0900952816009521, -0.9374119639396667, 0.5718950033187866, 0.03636741638183594, 1.294400691986084, 0.3412879705429077, 1.6510262489318848, 2.0523462295532227, 0.8939493894577026, 0.27901414036750793, 1.3092777729034424, -0.0659836158156395, -0.44496071338653564, 1.8562805652618408, -0.5436741709709167, 0.4899655878543854, 1.0222673416137695, -0.3963838219642639, -1.0214312076568604, -0.7901312708854675, -1.2594609260559082, -0.6962406635284424, 1.1476776599884033, 0.0791839137673378, -1.2248289585113525, 0.24992510676383972, 1.6803746223449707, 0.10206639766693115, -0.2503906488418579, 0.734736442565918, 0.42630645632743835, -0.791186511516571, -0.12093118578195572, -0.9024736881256104, 0.5244492292404175, -0.1165451928973198, -0.24696758389472961, 0.2044251710176468, 0.5142940878868103, 1.2933149337768555, -0.004106536041945219, 0.07968569546937943, 1.2674732208251953, -1.3896150588989258, 1.4912166595458984, -0.6348900198936462, 0.3363434970378876, -2.429456949234009, 1.3182454109191895, -0.7572859525680542, 1.8073227405548096, -2.60520339012146, 0.3974285125732422, -0.554563045501709, -0.5101087093353271, 0.21334029734134674, -0.2650969922542572, 0.18495149910449982, -0.1411752551794052, -0.986203134059906, -0.059530794620513916, -0.7845174670219421, 0.5819364786148071, 1.0677433013916016, 1.4098520278930664, -0.9571059346199036, -0.2349909245967865, -1.7473530769348145, -0.10524901747703552, -0.6533030867576599, 0.3108111619949341, -1.9339635372161865, -0.10550384223461151, -2.0085337162017822, -2.2727315425872803, -1.4903881549835205, -0.8796289563179016, 1.0937819480895996, 0.14588558673858643, -1.0359282493591309, 1.110337495803833, -0.41871291399002075, -1.7237944602966309, 1.132631540298462, -2.1923458576202393 ]
https://github.com/huggingface/datasets/issues/5193
"One or several metadata. were found, but not in the same directory or in a parent directory"
And here is my data loader script: https://huggingface.co/datasets/corentinm7/MyoQuant-SDH-Data/blob/main/SDH_16k.py I have one file archive to download that contains the images for all splits and one `metadata.jsonl` to download that contains the informations about what image goes into what split.
### Describe the bug When loading my own dataset, on loading it I get an error. Here is my dataset link: https://huggingface.co/datasets/corentinm7/MyoQuant-SDH-Data And the error after loading with: ```python from datasets import load_dataset load_dataset("corentinm7/MyoQuant-SDH-Data") ``` ```python Downloading readme: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.34k/3.34k [00:00<00:00, 4.45MB/s] Using custom data configuration SDH_16k-53e7301a92ab0025 Downloading and preparing dataset None/SDH_16k to /home/corentin/.cache/huggingface/datasets/corentinm7___imagefolder/SDH_16k-53e7301a92ab0025/0.0.0/37fbb85cc714a338bea574ac6c7d0b5be5aff46c1862c1989b20e0771199e93f... Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.28M/3.28M [00:00<00:00, 4.31MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:01<00:00, 1.75s/it] Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1.13G/1.13G [00:15<00:00, 74.3MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:16<00:00, 16.09s/it] Extracting data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:13<00:00, 13.16s/it] Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/load.py", line 1742, in load_dataset builder_instance.download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 814, in download_and_prepare self._download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 1423, in _download_and_prepare super()._download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 905, in _download_and_prepare self._prepare_split(split_generator, **prepare_split_kwargs) File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 1374, in _prepare_split for key, record in logging.tqdm( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/tqdm/std.py", line 1195, in __iter__ for obj in iterable: File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/packaged_modules/folder_based_builder/folder_based_builder.py", line 394, in _generate_examples raise ValueError( ValueError: One or several metadata. were found, but not in the same directory or in a parent directory of /home/corentin/.cache/huggingface/datasets/downloads/extracted/60c4aa8d4da3065bb3d310de4373dffd73bd4dc331aedcb4ee867febe4fdb7cd/validation/sick/2_CG_SDH_TAM_Bin1cKO_ko_pla_4_1640.tif. ``` However the test command is working fine. ```datasets-cli test hugging_face_play/ds_test/SDH_16k.py --save_info --all_configs --force_redownload``` ``` Using custom data configuration SDH_16k Testing builder 'SDH_16k' (1/1) Downloading and preparing dataset sdh_16k/SDH_16k to /home/corentin/.cache/huggingface/datasets/sdh_16k/SDH_16k/1.0.0/21b584239a638aeeda33cba1ac2ca4869d48e4b4f20fb22274d5a5ddc487659d... Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1.13G/1.13G [00:14<00:00, 76.5MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:15<00:00, 15.66s/it] Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.28M/3.28M [00:02<00:00, 1.44MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:03<00:00, 3.21s/it] Downloading data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:00<00:00, 11586.48it/s] Extracting data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:13<00:00, 13.42s/it] Dataset sdh_16k downloaded and prepared to /home/corentin/.cache/huggingface/datasets/sdh_16k/SDH_16k/1.0.0/21b584239a638aeeda33cba1ac2ca4869d48e4b4f20fb22274d5a5ddc487659d. Subsequent calls will reuse this data. 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3/3 [00:00<00:00, 605.27it/s] Dataset card saved at hugging_face_play/ds_test/README.md Test successful. ``` ### Steps to reproduce the bug Simply run on python ```python from datasets import load_dataset load_dataset("corentinm7/MyoQuant-SDH-Data") ``` ### Expected behavior As the test command worked, this error should not appear ### Environment info - `datasets` version: 2.6.1 - Platform: Linux-5.10.16.3-microsoft-standard-WSL2-x86_64-with-glibc2.31 - Python version: 3.10.6 - PyArrow version: 10.0.0 - Pandas version: 1.5.1
443
38
"One or several metadata. were found, but not in the same directory or in a parent directory" ### Describe the bug When loading my own dataset, on loading it I get an error. Here is my dataset link: https://huggingface.co/datasets/corentinm7/MyoQuant-SDH-Data And the error after loading with: ```python from datasets import load_dataset load_dataset("corentinm7/MyoQuant-SDH-Data") ``` ```python Downloading readme: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.34k/3.34k [00:00<00:00, 4.45MB/s] Using custom data configuration SDH_16k-53e7301a92ab0025 Downloading and preparing dataset None/SDH_16k to /home/corentin/.cache/huggingface/datasets/corentinm7___imagefolder/SDH_16k-53e7301a92ab0025/0.0.0/37fbb85cc714a338bea574ac6c7d0b5be5aff46c1862c1989b20e0771199e93f... Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.28M/3.28M [00:00<00:00, 4.31MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:01<00:00, 1.75s/it] Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1.13G/1.13G [00:15<00:00, 74.3MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:16<00:00, 16.09s/it] Extracting data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:13<00:00, 13.16s/it] Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/load.py", line 1742, in load_dataset builder_instance.download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 814, in download_and_prepare self._download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 1423, in _download_and_prepare super()._download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 905, in _download_and_prepare self._prepare_split(split_generator, **prepare_split_kwargs) File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 1374, in _prepare_split for key, record in logging.tqdm( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/tqdm/std.py", line 1195, in __iter__ for obj in iterable: File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/packaged_modules/folder_based_builder/folder_based_builder.py", line 394, in _generate_examples raise ValueError( ValueError: One or several metadata. were found, but not in the same directory or in a parent directory of /home/corentin/.cache/huggingface/datasets/downloads/extracted/60c4aa8d4da3065bb3d310de4373dffd73bd4dc331aedcb4ee867febe4fdb7cd/validation/sick/2_CG_SDH_TAM_Bin1cKO_ko_pla_4_1640.tif. ``` However the test command is working fine. ```datasets-cli test hugging_face_play/ds_test/SDH_16k.py --save_info --all_configs --force_redownload``` ``` Using custom data configuration SDH_16k Testing builder 'SDH_16k' (1/1) Downloading and preparing dataset sdh_16k/SDH_16k to /home/corentin/.cache/huggingface/datasets/sdh_16k/SDH_16k/1.0.0/21b584239a638aeeda33cba1ac2ca4869d48e4b4f20fb22274d5a5ddc487659d... Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1.13G/1.13G [00:14<00:00, 76.5MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:15<00:00, 15.66s/it] Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.28M/3.28M [00:02<00:00, 1.44MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:03<00:00, 3.21s/it] Downloading data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:00<00:00, 11586.48it/s] Extracting data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:13<00:00, 13.42s/it] Dataset sdh_16k downloaded and prepared to /home/corentin/.cache/huggingface/datasets/sdh_16k/SDH_16k/1.0.0/21b584239a638aeeda33cba1ac2ca4869d48e4b4f20fb22274d5a5ddc487659d. Subsequent calls will reuse this data. 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3/3 [00:00<00:00, 605.27it/s] Dataset card saved at hugging_face_play/ds_test/README.md Test successful. ``` ### Steps to reproduce the bug Simply run on python ```python from datasets import load_dataset load_dataset("corentinm7/MyoQuant-SDH-Data") ``` ### Expected behavior As the test command worked, this error should not appear ### Environment info - `datasets` version: 2.6.1 - Platform: Linux-5.10.16.3-microsoft-standard-WSL2-x86_64-with-glibc2.31 - Python version: 3.10.6 - PyArrow version: 10.0.0 - Pandas version: 1.5.1 And here is my data loader script: https://huggingface.co/datasets/corentinm7/MyoQuant-SDH-Data/blob/main/SDH_16k.py I have one file archive to download that contains the images for all splits and one `metadata.jsonl` to download that contains the informations about what image goes into what split.
[ -1.1513481140136719, -0.8950071930885315, -0.7690081000328064, 1.4270761013031006, -0.05569703131914139, -1.244236946105957, 0.12335053086280823, -1.1508922576904297, 1.5475118160247803, -0.6729012131690979, 0.29542702436447144, -1.7627599239349365, -0.03960840404033661, -0.5458818674087524, -0.7904717326164246, -0.8730937242507935, -0.39900246262550354, -0.8042073249816895, 0.9166461825370789, 2.4917469024658203, 1.2181382179260254, -1.355351448059082, 2.7918732166290283, 0.6390748023986816, -0.26768362522125244, -0.9507211446762085, 0.5859518647193909, 0.056174591183662415, -1.3944108486175537, -0.3314271867275238, -0.8961967825889587, -0.0630229040980339, -0.5856070518493652, -0.44000744819641113, 0.16081306338310242, 0.39702466130256653, -0.2866356670856476, -0.4238445460796356, -0.5518879294395447, -0.7803190350532532, 0.5477887988090515, -0.30618831515312195, 0.9749169945716858, -0.356801837682724, 1.7831218242645264, -0.6768479943275452, 0.3875423073768616, 0.7589303851127625, 1.260462760925293, 0.1495506763458252, 0.11132361739873886, 0.3958492875099182, 0.3549879789352417, 0.011983383446931839, 0.37305545806884766, 1.2434604167938232, 0.5187172889709473, 0.4216814637184143, 0.7459096908569336, -2.124134063720703, 1.3102226257324219, -0.9111434817314148, 0.2678227126598358, 1.361147165298462, -0.7931784987449646, 0.2778749167919159, -1.8839540481567383, -0.11444097757339478, 0.5824437141418457, -2.1739790439605713, 0.2869797945022583, -1.272953987121582, -0.5031480193138123, 0.9034112691879272, 0.34270286560058594, -1.0776703357696533, 0.2140909731388092, -0.5959327220916748, 1.0001859664916992, 0.4509925842285156, 1.1855924129486084, -1.6878068447113037, -0.0600484199821949, -0.2128417193889618, 0.13158097863197327, -1.34938645362854, -1.6057531833648682, 0.6287413835525513, 0.6119655966758728, 0.676578164100647, -0.0882943645119667, 1.0231482982635498, -1.0165541172027588, 0.8717881441116333, -0.9961537718772888, -1.7461130619049072, -1.3024768829345703, -2.314701795578003, -2.3139610290527344, 0.7555503845214844, -0.439631849527359, -0.45525044202804565, 1.9843285083770752, -0.9247167706489563, -1.7471132278442383, 1.0836687088012695, 0.28158020973205566, -0.028086910024285316, 2.396171808242798, 0.2568790912628174, -0.779274046421051, 0.4610007405281067, -0.7601338624954224, 0.7869120240211487, -0.20604504644870758, 1.3353841304779053, 0.4674963355064392, -0.8935851454734802, 1.548727035522461, -0.4630432426929474, 0.5005245208740234, -0.7024719715118408, -0.5334359407424927, -0.7364922761917114, 0.23865658044815063, 1.9233484268188477, -0.42383038997650146, 1.5508630275726318, -0.3679881691932678, -1.6113908290863037, -1.495116949081421, 0.8324441313743591, 0.5686793923377991, -0.8695210814476013, 0.03016284480690956, -0.39604976773262024, 0.18780970573425293, 0.008881762623786926, 1.0786433219909668, 1.2615690231323242, 0.7484303116798401, -0.3310778737068176, -0.8446767330169678, 0.19008518755435944, -0.11297627538442612, -0.8354676365852356, -1.7350094318389893, -0.324643075466156, 0.22538529336452484, 0.6949381828308105, -1.353224754333496, 1.7768988609313965, 0.9033784866333008, 2.062497615814209, 0.9594843983650208, -0.4511496424674988, 1.5336472988128662, 0.03194117546081543, 1.8902013301849365, -0.4876079261302948, 0.6098837852478027, -0.43267345428466797, -1.102311611175537, 0.8554531335830688, -0.2887655198574066, -1.9970715045928955, -0.8012484312057495, -0.8494881391525269, -0.14663003385066986, -0.7619706988334656, 0.9281796216964722, -0.31167641282081604, -1.5509533882141113, 0.19786155223846436, -0.7092428803443909, 0.02716352418065071, -1.2282228469848633, 0.13936936855316162, 0.651091992855072, -0.6888821125030518, 0.0740366280078888, -0.19999133050441742, -1.3391478061676025, -0.4930115342140198, 0.3091401159763336, 1.9523181915283203, -0.7012122273445129, 0.9624255895614624, 1.0754199028015137, -0.6794649958610535, 0.14529035985469818, 0.328689843416214, -0.33727362751960754, 0.7726941108703613, -1.208702564239502, -0.38269293308258057, 1.0776350498199463, -0.04745514318346977, -0.5583831071853638, 1.4944581985473633, 0.8078822493553162, -1.0622241497039795, -0.2787948250770569, -0.1408083289861679, -0.8132069110870361, -0.032916173338890076, -1.5833837985992432, -0.06800748407840729, 0.32760000228881836, -1.437854290008545, -0.43708252906799316, -0.26154905557632446, 1.1959543228149414, -0.14346742630004883, 1.4330010414123535, -0.3074665367603302, -0.2247018963098526, -0.3905750811100006, -0.45016953349113464, 0.09773241728544235, -0.32931894063949585, -0.5874088406562805, 0.23618637025356293, -0.847489058971405, 0.26867958903312683, 1.5039350986480713, 0.27552685141563416, 0.09165970236063004, 0.45360052585601807, 1.1524734497070312, 0.36595606803894043, 0.06776563078165054, -0.8602113127708435, -1.509901523590088, 2.0463716983795166, -1.5893404483795166, 1.9567499160766602, 0.7536913156509399, -0.01516249030828476, -1.836583137512207, -1.8751928806304932, 1.3658771514892578, 1.0911085605621338, 2.451479911804199, 0.5792697072029114, 0.43776679039001465, -0.7700514793395996, -0.7366793751716614, 0.3618931472301483, -0.935401976108551, -0.6850456595420837, 0.26834145188331604, 2.3727428913116455, 1.706296682357788, -0.5786855816841125, -0.2310444563627243, -0.8549292087554932, 1.3564746379852295, -0.0768507793545723, 0.20616069436073303, 2.04994797706604, -0.19971463084220886, -1.118680477142334, 1.262486219406128, -2.3488731384277344, 0.1674761027097702, 2.003664016723633, 0.2983110547065735, 0.12134553492069244, -1.4230964183807373, -0.6571397185325623, -0.3851408362388611, -0.4624551832675934, -1.2292499542236328, 0.6096989512443542, -0.29440250992774963, -0.9131664633750916, -1.474195957183838, 0.03905776888132095, -1.1584880352020264, -1.7335197925567627, 0.3595767319202423, 1.8945825099945068, 2.1348023414611816, -0.7562553882598877, 1.441354513168335, -0.33584165573120117, 0.04444023594260216, 1.1793906688690186, 1.292923927307129, 3.0534279346466064, 1.8321499824523926, -1.2424020767211914, 0.7614278197288513, -0.14163008332252502, -0.45329415798187256, 1.082557201385498, -1.0869264602661133, 1.1351773738861084, -0.19746308028697968, -1.205437421798706, -1.1502463817596436, 1.0558764934539795, 0.3917936086654663, 0.04795142263174057, -0.5126159191131592, 1.311513900756836, 0.07889058440923691, 1.3403947353363037, 0.5844317674636841, -0.2719807028770447, 0.56777024269104, -0.36403506994247437, -0.5597935318946838, 1.6431701183319092, 0.1781744658946991, -1.4560937881469727, -2.516721487045288, -0.2649511694908142, -0.8839423656463623, 0.035654496401548386, -0.6581291556358337, -1.1138861179351807, 1.6405889987945557, 0.3793220520019531, -1.307363748550415, -0.2525630593299866, -0.349832683801651, -0.5881023406982422, 2.626633644104004, -1.416243076324463, -0.10334441810846329, -0.9074795246124268, -0.5116516947746277, 1.6082003116607666, -1.1500682830810547, -0.24226710200309753, -1.1136605739593506, -0.567676842212677, -1.350315809249878, -0.5899694561958313, 0.0623999685049057, -0.895219087600708, 0.7958406805992126, 0.17607825994491577, -1.0855822563171387, -0.26272884011268616, -0.9276371598243713, 0.9914315342903137, -0.0545816607773304, 0.25904616713523865, 1.8715956211090088, 0.40830036997795105, -0.3789440393447876, 0.7166363596916199, 1.1759214401245117, 0.6499977111816406, -0.6554539799690247, 0.06486876308917999, -0.6491432785987854, 0.23234140872955322, -1.408212661743164, 0.24928516149520874, -2.823524236679077, 0.7073701024055481, -0.09373742341995239, 0.0020622191950678825, -0.044905729591846466, -1.2705597877502441, 1.1748764514923096, 2.6833372116088867, -1.142648458480835, 0.5339173674583435, 0.35736438632011414, 1.1827950477600098, -1.4712300300598145, 0.26699885725975037, -0.39934059977531433, 2.0325000286102295, 0.06230513006448746, 1.170525312423706, -0.5601316094398499, -2.177494525909424, 0.6072453260421753, -1.2915232181549072, -1.093179702758789, 0.8512124419212341, -0.8744171261787415, 0.2232491374015808, -1.4630002975463867, -0.27639174461364746, -0.9837376475334167, -1.236189365386963, 0.6797045469284058, 0.11581212282180786, 0.5405554175376892, -0.543260931968689, 0.37450990080833435, -2.2846362590789795, -1.446869134902954, -0.17385882139205933, -1.0147674083709717, 0.5676365494728088, -0.3260263502597809, 0.7176563739776611, -0.09841689467430115, 0.06029035151004791, 0.4273790419101715, 1.3145558834075928, 3.360629081726074, 0.1646161824464798, 0.26494458317756653, -0.12166551500558853, -1.0329430103302002, 1.358548879623413, 0.9996828436851501, -0.10063111037015915, -0.5722072124481201, -1.0157599449157715, 1.2015328407287598, 2.03369140625, 1.0931243896484375, -0.01000891625881195, -0.8446508049964905, -0.8463783264160156, 0.1345713883638382, 0.2113482654094696, 0.6129223704338074, 0.956882894039154, -0.055721789598464966, 0.11378221213817596, 1.472623348236084, 1.1372480392456055, -0.436359703540802, 0.44929632544517517, -0.9114785194396973, -0.4093230366706848, 0.47958919405937195, 0.18357770144939423, 0.04459501802921295, 0.4212489128112793, -1.0924553871154785, -0.30797532200813293, -0.30899161100387573, -0.8948781490325928, -0.6658729910850525, -0.43526262044906616, -0.4302772581577301, 1.5971639156341553, 0.08876854926347733, -0.44572558999061584, 0.10277868807315826, -0.6755667328834534, -0.15152379870414734, -1.1707265377044678, 0.22035850584506989, -0.2043609917163849, -0.022755460813641548, -0.08342966437339783, 1.837325096130371, -0.9350897073745728, -2.0669143199920654, 0.16520848870277405, 0.2813240587711334, -0.3923700451850891, 0.24408817291259766, 1.70039963722229, 0.6338827013969421, 1.3505780696868896, 1.2984814643859863, 0.8921394348144531, -0.6856156587600708, -1.257873773574829, 0.6068567633628845, 0.9351285099983215, -1.3557560443878174, 0.7877652645111084, -0.12785778939723969, -0.4687468111515045, 0.644012451171875, 1.34373140335083, 0.3852587938308716, -2.0921084880828857, 0.8778418898582458, -0.8541280627250671, 0.7719696164131165, 0.7038345336914062, 0.7436479926109314, 0.20975252985954285, 0.7769941687583923, -1.2338426113128662, -1.086381435394287, -0.8179945945739746, -0.6450372338294983, 1.8991057872772217, -0.1962120682001114, 0.40249213576316833, -0.22068285942077637, -1.1977481842041016, -0.10834809392690659, 0.7151972651481628, 0.3748984634876251, -0.43124130368232727, 0.7780368328094482, -0.5401567220687866, -1.1127324104309082, -1.2308645248413086, -0.5540781021118164, -1.0293517112731934, -0.9000663757324219, 0.941565990447998, 0.7121763825416565, 0.42758920788764954, 1.8834295272827148, 0.6826808452606201, 0.24039563536643982, -2.697089433670044, 0.9418428540229797, 0.30148816108703613, -0.04596703499555588, 0.9811089038848877, 0.33273079991340637, 1.1527118682861328, -0.05802620202302933, 0.5842932462692261, -2.4085745811462402, 2.2982699871063232, -0.23040863871574402, 0.7362977862358093, -0.043138958513736725, -0.23207098245620728, 1.1067941188812256, 0.5272631645202637, 0.5380838513374329, -1.0799355506896973, 0.6497417092323303, -0.7008094787597656, 1.0924787521362305, 0.850045382976532, -0.8871825933456421, 0.0878080502152443, 1.2750964164733887, 0.4982439875602722, -0.4196550250053406, -0.9472859501838684, -0.8253911137580872, 0.9836701154708862, 1.6957314014434814, -0.08405783027410507, 0.08703908324241638, 0.9426915049552917, 0.5794355869293213, -1.3065645694732666, 0.009720170870423317, -0.6990299820899963, -0.8183271884918213, 1.7513439655303955, 2.132476806640625, -0.09379429370164871, -0.09737097471952438, -0.7643058896064758, -1.2322075366973877, 0.7723854184150696, -0.06378144770860672, 0.1612231433391571, 0.5317140221595764, -0.712695300579071, 1.242621898651123, 0.6372846961021423, 0.9686493277549744, 0.08572104573249817, 0.3713941276073456, 0.2943043112754822, -0.3413039445877075, -1.1585943698883057, -0.3764116168022156, -1.068821907043457, -2.4039623737335205, 0.5434005856513977, -0.14232264459133148, -1.4884283542633057, 0.04628803953528404, -0.9921693205833435, 0.8899607062339783, -0.5686308145523071, -1.0231549739837646, -1.4575176239013672, 0.3554272949695587, -0.23128998279571533, 1.009629487991333, -1.644036054611206, -0.08741676062345505, 1.2032442092895508, 0.893016517162323, -0.5762561559677124, 0.9623696804046631, 0.3390819728374481, 1.0059046745300293, 0.8208916783332825, -0.3177860975265503, 0.5695604085922241, 0.1117515116930008, -1.2789876461029053, 0.40760537981987, 1.1903886795043945, 0.14040744304656982, 1.436255693435669, -0.4422539472579956, 0.07354798167943954, 0.35420385003089905, -0.46131688356399536, -0.4501640200614929, -0.5442419052124023, 0.5951755046844482, 0.15469776093959808, -1.0739636421203613, -0.1181337758898735, -0.04441928490996361, -0.19752788543701172, 0.2941344976425171, -1.500652551651001, -0.29525208473205566, -0.3711174428462982, -0.4850594997406006, -1.2491703033447266, 0.05569808930158615, 1.3067777156829834, -0.8017001152038574, -0.23832285404205322, 0.4000936448574066, 0.3669297397136688, 0.5967146754264832, 0.639492392539978, -0.6759822964668274, -0.3874078691005707, -0.30812960863113403, -0.34758180379867554, 0.23947565257549286, 1.2277140617370605, -0.10522263497114182, -1.0755610466003418, 0.7324354648590088, -0.4545269310474396, 0.09479999542236328, 1.9358851909637451, -0.04677160829305649, -0.7268698215484619, 0.31264176964759827, -0.6923533082008362, 1.9189105033874512, 1.7735915184020996, 1.272773027420044, -0.20546264946460724, -0.8926507234573364, 0.5763269066810608, -0.31978654861450195, -0.22494478523731232, 0.9336066842079163, 0.4297490119934082, -0.19055216014385223, -1.4224355220794678, 0.486291766166687, 1.363673448562622, -0.893842875957489, -0.7976875305175781, 0.13479283452033997, -0.8358256220817566, 1.1265802383422852, 0.7129209637641907, 0.32614389061927795, 0.3083014488220215, 1.5180299282073975, 0.7791673541069031, -0.5000765323638916, 0.5970894694328308, 0.4158252775669098, -0.12339584529399872, -2.1541597843170166, -1.1511454582214355, 0.3774460256099701, -0.29745033383369446, -1.608638048171997, 1.3731272220611572, -1.0900952816009521, -0.9374119639396667, 0.5718950033187866, 0.03636741638183594, 1.294400691986084, 0.3412879705429077, 1.6510262489318848, 2.0523462295532227, 0.8939493894577026, 0.27901414036750793, 1.3092777729034424, -0.0659836158156395, -0.44496071338653564, 1.8562805652618408, -0.5436741709709167, 0.4899655878543854, 1.0222673416137695, -0.3963838219642639, -1.0214312076568604, -0.7901312708854675, -1.2594609260559082, -0.6962406635284424, 1.1476776599884033, 0.0791839137673378, -1.2248289585113525, 0.24992510676383972, 1.6803746223449707, 0.10206639766693115, -0.2503906488418579, 0.734736442565918, 0.42630645632743835, -0.791186511516571, -0.12093118578195572, -0.9024736881256104, 0.5244492292404175, -0.1165451928973198, -0.24696758389472961, 0.2044251710176468, 0.5142940878868103, 1.2933149337768555, -0.004106536041945219, 0.07968569546937943, 1.2674732208251953, -1.3896150588989258, 1.4912166595458984, -0.6348900198936462, 0.3363434970378876, -2.429456949234009, 1.3182454109191895, -0.7572859525680542, 1.8073227405548096, -2.60520339012146, 0.3974285125732422, -0.554563045501709, -0.5101087093353271, 0.21334029734134674, -0.2650969922542572, 0.18495149910449982, -0.1411752551794052, -0.986203134059906, -0.059530794620513916, -0.7845174670219421, 0.5819364786148071, 1.0677433013916016, 1.4098520278930664, -0.9571059346199036, -0.2349909245967865, -1.7473530769348145, -0.10524901747703552, -0.6533030867576599, 0.3108111619949341, -1.9339635372161865, -0.10550384223461151, -2.0085337162017822, -2.2727315425872803, -1.4903881549835205, -0.8796289563179016, 1.0937819480895996, 0.14588558673858643, -1.0359282493591309, 1.110337495803833, -0.41871291399002075, -1.7237944602966309, 1.132631540298462, -2.1923458576202393 ]
https://github.com/huggingface/datasets/issues/5193
"One or several metadata. were found, but not in the same directory or in a parent directory"
Hi @lambda-science! It seems that your repo is recognized as a packaged module [ImageFolder](https://huggingface.co/docs/datasets/main/en/image_dataset#imagefolder), not as a dataset with the custom loading script, because loader looks for a script that has the same name as the dataset repo. So please try to rename your script to `MyoQuant-SDH-Data.py`, this should help.
### Describe the bug When loading my own dataset, on loading it I get an error. Here is my dataset link: https://huggingface.co/datasets/corentinm7/MyoQuant-SDH-Data And the error after loading with: ```python from datasets import load_dataset load_dataset("corentinm7/MyoQuant-SDH-Data") ``` ```python Downloading readme: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.34k/3.34k [00:00<00:00, 4.45MB/s] Using custom data configuration SDH_16k-53e7301a92ab0025 Downloading and preparing dataset None/SDH_16k to /home/corentin/.cache/huggingface/datasets/corentinm7___imagefolder/SDH_16k-53e7301a92ab0025/0.0.0/37fbb85cc714a338bea574ac6c7d0b5be5aff46c1862c1989b20e0771199e93f... Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.28M/3.28M [00:00<00:00, 4.31MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:01<00:00, 1.75s/it] Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1.13G/1.13G [00:15<00:00, 74.3MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:16<00:00, 16.09s/it] Extracting data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:13<00:00, 13.16s/it] Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/load.py", line 1742, in load_dataset builder_instance.download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 814, in download_and_prepare self._download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 1423, in _download_and_prepare super()._download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 905, in _download_and_prepare self._prepare_split(split_generator, **prepare_split_kwargs) File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 1374, in _prepare_split for key, record in logging.tqdm( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/tqdm/std.py", line 1195, in __iter__ for obj in iterable: File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/packaged_modules/folder_based_builder/folder_based_builder.py", line 394, in _generate_examples raise ValueError( ValueError: One or several metadata. were found, but not in the same directory or in a parent directory of /home/corentin/.cache/huggingface/datasets/downloads/extracted/60c4aa8d4da3065bb3d310de4373dffd73bd4dc331aedcb4ee867febe4fdb7cd/validation/sick/2_CG_SDH_TAM_Bin1cKO_ko_pla_4_1640.tif. ``` However the test command is working fine. ```datasets-cli test hugging_face_play/ds_test/SDH_16k.py --save_info --all_configs --force_redownload``` ``` Using custom data configuration SDH_16k Testing builder 'SDH_16k' (1/1) Downloading and preparing dataset sdh_16k/SDH_16k to /home/corentin/.cache/huggingface/datasets/sdh_16k/SDH_16k/1.0.0/21b584239a638aeeda33cba1ac2ca4869d48e4b4f20fb22274d5a5ddc487659d... Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1.13G/1.13G [00:14<00:00, 76.5MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:15<00:00, 15.66s/it] Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.28M/3.28M [00:02<00:00, 1.44MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:03<00:00, 3.21s/it] Downloading data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:00<00:00, 11586.48it/s] Extracting data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:13<00:00, 13.42s/it] Dataset sdh_16k downloaded and prepared to /home/corentin/.cache/huggingface/datasets/sdh_16k/SDH_16k/1.0.0/21b584239a638aeeda33cba1ac2ca4869d48e4b4f20fb22274d5a5ddc487659d. Subsequent calls will reuse this data. 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3/3 [00:00<00:00, 605.27it/s] Dataset card saved at hugging_face_play/ds_test/README.md Test successful. ``` ### Steps to reproduce the bug Simply run on python ```python from datasets import load_dataset load_dataset("corentinm7/MyoQuant-SDH-Data") ``` ### Expected behavior As the test command worked, this error should not appear ### Environment info - `datasets` version: 2.6.1 - Platform: Linux-5.10.16.3-microsoft-standard-WSL2-x86_64-with-glibc2.31 - Python version: 3.10.6 - PyArrow version: 10.0.0 - Pandas version: 1.5.1
443
50
"One or several metadata. were found, but not in the same directory or in a parent directory" ### Describe the bug When loading my own dataset, on loading it I get an error. Here is my dataset link: https://huggingface.co/datasets/corentinm7/MyoQuant-SDH-Data And the error after loading with: ```python from datasets import load_dataset load_dataset("corentinm7/MyoQuant-SDH-Data") ``` ```python Downloading readme: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.34k/3.34k [00:00<00:00, 4.45MB/s] Using custom data configuration SDH_16k-53e7301a92ab0025 Downloading and preparing dataset None/SDH_16k to /home/corentin/.cache/huggingface/datasets/corentinm7___imagefolder/SDH_16k-53e7301a92ab0025/0.0.0/37fbb85cc714a338bea574ac6c7d0b5be5aff46c1862c1989b20e0771199e93f... Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.28M/3.28M [00:00<00:00, 4.31MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:01<00:00, 1.75s/it] Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1.13G/1.13G [00:15<00:00, 74.3MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:16<00:00, 16.09s/it] Extracting data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:13<00:00, 13.16s/it] Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/load.py", line 1742, in load_dataset builder_instance.download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 814, in download_and_prepare self._download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 1423, in _download_and_prepare super()._download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 905, in _download_and_prepare self._prepare_split(split_generator, **prepare_split_kwargs) File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 1374, in _prepare_split for key, record in logging.tqdm( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/tqdm/std.py", line 1195, in __iter__ for obj in iterable: File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/packaged_modules/folder_based_builder/folder_based_builder.py", line 394, in _generate_examples raise ValueError( ValueError: One or several metadata. were found, but not in the same directory or in a parent directory of /home/corentin/.cache/huggingface/datasets/downloads/extracted/60c4aa8d4da3065bb3d310de4373dffd73bd4dc331aedcb4ee867febe4fdb7cd/validation/sick/2_CG_SDH_TAM_Bin1cKO_ko_pla_4_1640.tif. ``` However the test command is working fine. ```datasets-cli test hugging_face_play/ds_test/SDH_16k.py --save_info --all_configs --force_redownload``` ``` Using custom data configuration SDH_16k Testing builder 'SDH_16k' (1/1) Downloading and preparing dataset sdh_16k/SDH_16k to /home/corentin/.cache/huggingface/datasets/sdh_16k/SDH_16k/1.0.0/21b584239a638aeeda33cba1ac2ca4869d48e4b4f20fb22274d5a5ddc487659d... Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1.13G/1.13G [00:14<00:00, 76.5MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:15<00:00, 15.66s/it] Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.28M/3.28M [00:02<00:00, 1.44MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:03<00:00, 3.21s/it] Downloading data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:00<00:00, 11586.48it/s] Extracting data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:13<00:00, 13.42s/it] Dataset sdh_16k downloaded and prepared to /home/corentin/.cache/huggingface/datasets/sdh_16k/SDH_16k/1.0.0/21b584239a638aeeda33cba1ac2ca4869d48e4b4f20fb22274d5a5ddc487659d. Subsequent calls will reuse this data. 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3/3 [00:00<00:00, 605.27it/s] Dataset card saved at hugging_face_play/ds_test/README.md Test successful. ``` ### Steps to reproduce the bug Simply run on python ```python from datasets import load_dataset load_dataset("corentinm7/MyoQuant-SDH-Data") ``` ### Expected behavior As the test command worked, this error should not appear ### Environment info - `datasets` version: 2.6.1 - Platform: Linux-5.10.16.3-microsoft-standard-WSL2-x86_64-with-glibc2.31 - Python version: 3.10.6 - PyArrow version: 10.0.0 - Pandas version: 1.5.1 Hi @lambda-science! It seems that your repo is recognized as a packaged module [ImageFolder](https://huggingface.co/docs/datasets/main/en/image_dataset#imagefolder), not as a dataset with the custom loading script, because loader looks for a script that has the same name as the dataset repo. So please try to rename your script to `MyoQuant-SDH-Data.py`, this should help.
[ -1.1513481140136719, -0.8950071930885315, -0.7690081000328064, 1.4270761013031006, -0.05569703131914139, -1.244236946105957, 0.12335053086280823, -1.1508922576904297, 1.5475118160247803, -0.6729012131690979, 0.29542702436447144, -1.7627599239349365, -0.03960840404033661, -0.5458818674087524, -0.7904717326164246, -0.8730937242507935, -0.39900246262550354, -0.8042073249816895, 0.9166461825370789, 2.4917469024658203, 1.2181382179260254, -1.355351448059082, 2.7918732166290283, 0.6390748023986816, -0.26768362522125244, -0.9507211446762085, 0.5859518647193909, 0.056174591183662415, -1.3944108486175537, -0.3314271867275238, -0.8961967825889587, -0.0630229040980339, -0.5856070518493652, -0.44000744819641113, 0.16081306338310242, 0.39702466130256653, -0.2866356670856476, -0.4238445460796356, -0.5518879294395447, -0.7803190350532532, 0.5477887988090515, -0.30618831515312195, 0.9749169945716858, -0.356801837682724, 1.7831218242645264, -0.6768479943275452, 0.3875423073768616, 0.7589303851127625, 1.260462760925293, 0.1495506763458252, 0.11132361739873886, 0.3958492875099182, 0.3549879789352417, 0.011983383446931839, 0.37305545806884766, 1.2434604167938232, 0.5187172889709473, 0.4216814637184143, 0.7459096908569336, -2.124134063720703, 1.3102226257324219, -0.9111434817314148, 0.2678227126598358, 1.361147165298462, -0.7931784987449646, 0.2778749167919159, -1.8839540481567383, -0.11444097757339478, 0.5824437141418457, -2.1739790439605713, 0.2869797945022583, -1.272953987121582, -0.5031480193138123, 0.9034112691879272, 0.34270286560058594, -1.0776703357696533, 0.2140909731388092, -0.5959327220916748, 1.0001859664916992, 0.4509925842285156, 1.1855924129486084, -1.6878068447113037, -0.0600484199821949, -0.2128417193889618, 0.13158097863197327, -1.34938645362854, -1.6057531833648682, 0.6287413835525513, 0.6119655966758728, 0.676578164100647, -0.0882943645119667, 1.0231482982635498, -1.0165541172027588, 0.8717881441116333, -0.9961537718772888, -1.7461130619049072, -1.3024768829345703, -2.314701795578003, -2.3139610290527344, 0.7555503845214844, -0.439631849527359, -0.45525044202804565, 1.9843285083770752, -0.9247167706489563, -1.7471132278442383, 1.0836687088012695, 0.28158020973205566, -0.028086910024285316, 2.396171808242798, 0.2568790912628174, -0.779274046421051, 0.4610007405281067, -0.7601338624954224, 0.7869120240211487, -0.20604504644870758, 1.3353841304779053, 0.4674963355064392, -0.8935851454734802, 1.548727035522461, -0.4630432426929474, 0.5005245208740234, -0.7024719715118408, -0.5334359407424927, -0.7364922761917114, 0.23865658044815063, 1.9233484268188477, -0.42383038997650146, 1.5508630275726318, -0.3679881691932678, -1.6113908290863037, -1.495116949081421, 0.8324441313743591, 0.5686793923377991, -0.8695210814476013, 0.03016284480690956, -0.39604976773262024, 0.18780970573425293, 0.008881762623786926, 1.0786433219909668, 1.2615690231323242, 0.7484303116798401, -0.3310778737068176, -0.8446767330169678, 0.19008518755435944, -0.11297627538442612, -0.8354676365852356, -1.7350094318389893, -0.324643075466156, 0.22538529336452484, 0.6949381828308105, -1.353224754333496, 1.7768988609313965, 0.9033784866333008, 2.062497615814209, 0.9594843983650208, -0.4511496424674988, 1.5336472988128662, 0.03194117546081543, 1.8902013301849365, -0.4876079261302948, 0.6098837852478027, -0.43267345428466797, -1.102311611175537, 0.8554531335830688, -0.2887655198574066, -1.9970715045928955, -0.8012484312057495, -0.8494881391525269, -0.14663003385066986, -0.7619706988334656, 0.9281796216964722, -0.31167641282081604, -1.5509533882141113, 0.19786155223846436, -0.7092428803443909, 0.02716352418065071, -1.2282228469848633, 0.13936936855316162, 0.651091992855072, -0.6888821125030518, 0.0740366280078888, -0.19999133050441742, -1.3391478061676025, -0.4930115342140198, 0.3091401159763336, 1.9523181915283203, -0.7012122273445129, 0.9624255895614624, 1.0754199028015137, -0.6794649958610535, 0.14529035985469818, 0.328689843416214, -0.33727362751960754, 0.7726941108703613, -1.208702564239502, -0.38269293308258057, 1.0776350498199463, -0.04745514318346977, -0.5583831071853638, 1.4944581985473633, 0.8078822493553162, -1.0622241497039795, -0.2787948250770569, -0.1408083289861679, -0.8132069110870361, -0.032916173338890076, -1.5833837985992432, -0.06800748407840729, 0.32760000228881836, -1.437854290008545, -0.43708252906799316, -0.26154905557632446, 1.1959543228149414, -0.14346742630004883, 1.4330010414123535, -0.3074665367603302, -0.2247018963098526, -0.3905750811100006, -0.45016953349113464, 0.09773241728544235, -0.32931894063949585, -0.5874088406562805, 0.23618637025356293, -0.847489058971405, 0.26867958903312683, 1.5039350986480713, 0.27552685141563416, 0.09165970236063004, 0.45360052585601807, 1.1524734497070312, 0.36595606803894043, 0.06776563078165054, -0.8602113127708435, -1.509901523590088, 2.0463716983795166, -1.5893404483795166, 1.9567499160766602, 0.7536913156509399, -0.01516249030828476, -1.836583137512207, -1.8751928806304932, 1.3658771514892578, 1.0911085605621338, 2.451479911804199, 0.5792697072029114, 0.43776679039001465, -0.7700514793395996, -0.7366793751716614, 0.3618931472301483, -0.935401976108551, -0.6850456595420837, 0.26834145188331604, 2.3727428913116455, 1.706296682357788, -0.5786855816841125, -0.2310444563627243, -0.8549292087554932, 1.3564746379852295, -0.0768507793545723, 0.20616069436073303, 2.04994797706604, -0.19971463084220886, -1.118680477142334, 1.262486219406128, -2.3488731384277344, 0.1674761027097702, 2.003664016723633, 0.2983110547065735, 0.12134553492069244, -1.4230964183807373, -0.6571397185325623, -0.3851408362388611, -0.4624551832675934, -1.2292499542236328, 0.6096989512443542, -0.29440250992774963, -0.9131664633750916, -1.474195957183838, 0.03905776888132095, -1.1584880352020264, -1.7335197925567627, 0.3595767319202423, 1.8945825099945068, 2.1348023414611816, -0.7562553882598877, 1.441354513168335, -0.33584165573120117, 0.04444023594260216, 1.1793906688690186, 1.292923927307129, 3.0534279346466064, 1.8321499824523926, -1.2424020767211914, 0.7614278197288513, -0.14163008332252502, -0.45329415798187256, 1.082557201385498, -1.0869264602661133, 1.1351773738861084, -0.19746308028697968, -1.205437421798706, -1.1502463817596436, 1.0558764934539795, 0.3917936086654663, 0.04795142263174057, -0.5126159191131592, 1.311513900756836, 0.07889058440923691, 1.3403947353363037, 0.5844317674636841, -0.2719807028770447, 0.56777024269104, -0.36403506994247437, -0.5597935318946838, 1.6431701183319092, 0.1781744658946991, -1.4560937881469727, -2.516721487045288, -0.2649511694908142, -0.8839423656463623, 0.035654496401548386, -0.6581291556358337, -1.1138861179351807, 1.6405889987945557, 0.3793220520019531, -1.307363748550415, -0.2525630593299866, -0.349832683801651, -0.5881023406982422, 2.626633644104004, -1.416243076324463, -0.10334441810846329, -0.9074795246124268, -0.5116516947746277, 1.6082003116607666, -1.1500682830810547, -0.24226710200309753, -1.1136605739593506, -0.567676842212677, -1.350315809249878, -0.5899694561958313, 0.0623999685049057, -0.895219087600708, 0.7958406805992126, 0.17607825994491577, -1.0855822563171387, -0.26272884011268616, -0.9276371598243713, 0.9914315342903137, -0.0545816607773304, 0.25904616713523865, 1.8715956211090088, 0.40830036997795105, -0.3789440393447876, 0.7166363596916199, 1.1759214401245117, 0.6499977111816406, -0.6554539799690247, 0.06486876308917999, -0.6491432785987854, 0.23234140872955322, -1.408212661743164, 0.24928516149520874, -2.823524236679077, 0.7073701024055481, -0.09373742341995239, 0.0020622191950678825, -0.044905729591846466, -1.2705597877502441, 1.1748764514923096, 2.6833372116088867, -1.142648458480835, 0.5339173674583435, 0.35736438632011414, 1.1827950477600098, -1.4712300300598145, 0.26699885725975037, -0.39934059977531433, 2.0325000286102295, 0.06230513006448746, 1.170525312423706, -0.5601316094398499, -2.177494525909424, 0.6072453260421753, -1.2915232181549072, -1.093179702758789, 0.8512124419212341, -0.8744171261787415, 0.2232491374015808, -1.4630002975463867, -0.27639174461364746, -0.9837376475334167, -1.236189365386963, 0.6797045469284058, 0.11581212282180786, 0.5405554175376892, -0.543260931968689, 0.37450990080833435, -2.2846362590789795, -1.446869134902954, -0.17385882139205933, -1.0147674083709717, 0.5676365494728088, -0.3260263502597809, 0.7176563739776611, -0.09841689467430115, 0.06029035151004791, 0.4273790419101715, 1.3145558834075928, 3.360629081726074, 0.1646161824464798, 0.26494458317756653, -0.12166551500558853, -1.0329430103302002, 1.358548879623413, 0.9996828436851501, -0.10063111037015915, -0.5722072124481201, -1.0157599449157715, 1.2015328407287598, 2.03369140625, 1.0931243896484375, -0.01000891625881195, -0.8446508049964905, -0.8463783264160156, 0.1345713883638382, 0.2113482654094696, 0.6129223704338074, 0.956882894039154, -0.055721789598464966, 0.11378221213817596, 1.472623348236084, 1.1372480392456055, -0.436359703540802, 0.44929632544517517, -0.9114785194396973, -0.4093230366706848, 0.47958919405937195, 0.18357770144939423, 0.04459501802921295, 0.4212489128112793, -1.0924553871154785, -0.30797532200813293, -0.30899161100387573, -0.8948781490325928, -0.6658729910850525, -0.43526262044906616, -0.4302772581577301, 1.5971639156341553, 0.08876854926347733, -0.44572558999061584, 0.10277868807315826, -0.6755667328834534, -0.15152379870414734, -1.1707265377044678, 0.22035850584506989, -0.2043609917163849, -0.022755460813641548, -0.08342966437339783, 1.837325096130371, -0.9350897073745728, -2.0669143199920654, 0.16520848870277405, 0.2813240587711334, -0.3923700451850891, 0.24408817291259766, 1.70039963722229, 0.6338827013969421, 1.3505780696868896, 1.2984814643859863, 0.8921394348144531, -0.6856156587600708, -1.257873773574829, 0.6068567633628845, 0.9351285099983215, -1.3557560443878174, 0.7877652645111084, -0.12785778939723969, -0.4687468111515045, 0.644012451171875, 1.34373140335083, 0.3852587938308716, -2.0921084880828857, 0.8778418898582458, -0.8541280627250671, 0.7719696164131165, 0.7038345336914062, 0.7436479926109314, 0.20975252985954285, 0.7769941687583923, -1.2338426113128662, -1.086381435394287, -0.8179945945739746, -0.6450372338294983, 1.8991057872772217, -0.1962120682001114, 0.40249213576316833, -0.22068285942077637, -1.1977481842041016, -0.10834809392690659, 0.7151972651481628, 0.3748984634876251, -0.43124130368232727, 0.7780368328094482, -0.5401567220687866, -1.1127324104309082, -1.2308645248413086, -0.5540781021118164, -1.0293517112731934, -0.9000663757324219, 0.941565990447998, 0.7121763825416565, 0.42758920788764954, 1.8834295272827148, 0.6826808452606201, 0.24039563536643982, -2.697089433670044, 0.9418428540229797, 0.30148816108703613, -0.04596703499555588, 0.9811089038848877, 0.33273079991340637, 1.1527118682861328, -0.05802620202302933, 0.5842932462692261, -2.4085745811462402, 2.2982699871063232, -0.23040863871574402, 0.7362977862358093, -0.043138958513736725, -0.23207098245620728, 1.1067941188812256, 0.5272631645202637, 0.5380838513374329, -1.0799355506896973, 0.6497417092323303, -0.7008094787597656, 1.0924787521362305, 0.850045382976532, -0.8871825933456421, 0.0878080502152443, 1.2750964164733887, 0.4982439875602722, -0.4196550250053406, -0.9472859501838684, -0.8253911137580872, 0.9836701154708862, 1.6957314014434814, -0.08405783027410507, 0.08703908324241638, 0.9426915049552917, 0.5794355869293213, -1.3065645694732666, 0.009720170870423317, -0.6990299820899963, -0.8183271884918213, 1.7513439655303955, 2.132476806640625, -0.09379429370164871, -0.09737097471952438, -0.7643058896064758, -1.2322075366973877, 0.7723854184150696, -0.06378144770860672, 0.1612231433391571, 0.5317140221595764, -0.712695300579071, 1.242621898651123, 0.6372846961021423, 0.9686493277549744, 0.08572104573249817, 0.3713941276073456, 0.2943043112754822, -0.3413039445877075, -1.1585943698883057, -0.3764116168022156, -1.068821907043457, -2.4039623737335205, 0.5434005856513977, -0.14232264459133148, -1.4884283542633057, 0.04628803953528404, -0.9921693205833435, 0.8899607062339783, -0.5686308145523071, -1.0231549739837646, -1.4575176239013672, 0.3554272949695587, -0.23128998279571533, 1.009629487991333, -1.644036054611206, -0.08741676062345505, 1.2032442092895508, 0.893016517162323, -0.5762561559677124, 0.9623696804046631, 0.3390819728374481, 1.0059046745300293, 0.8208916783332825, -0.3177860975265503, 0.5695604085922241, 0.1117515116930008, -1.2789876461029053, 0.40760537981987, 1.1903886795043945, 0.14040744304656982, 1.436255693435669, -0.4422539472579956, 0.07354798167943954, 0.35420385003089905, -0.46131688356399536, -0.4501640200614929, -0.5442419052124023, 0.5951755046844482, 0.15469776093959808, -1.0739636421203613, -0.1181337758898735, -0.04441928490996361, -0.19752788543701172, 0.2941344976425171, -1.500652551651001, -0.29525208473205566, -0.3711174428462982, -0.4850594997406006, -1.2491703033447266, 0.05569808930158615, 1.3067777156829834, -0.8017001152038574, -0.23832285404205322, 0.4000936448574066, 0.3669297397136688, 0.5967146754264832, 0.639492392539978, -0.6759822964668274, -0.3874078691005707, -0.30812960863113403, -0.34758180379867554, 0.23947565257549286, 1.2277140617370605, -0.10522263497114182, -1.0755610466003418, 0.7324354648590088, -0.4545269310474396, 0.09479999542236328, 1.9358851909637451, -0.04677160829305649, -0.7268698215484619, 0.31264176964759827, -0.6923533082008362, 1.9189105033874512, 1.7735915184020996, 1.272773027420044, -0.20546264946460724, -0.8926507234573364, 0.5763269066810608, -0.31978654861450195, -0.22494478523731232, 0.9336066842079163, 0.4297490119934082, -0.19055216014385223, -1.4224355220794678, 0.486291766166687, 1.363673448562622, -0.893842875957489, -0.7976875305175781, 0.13479283452033997, -0.8358256220817566, 1.1265802383422852, 0.7129209637641907, 0.32614389061927795, 0.3083014488220215, 1.5180299282073975, 0.7791673541069031, -0.5000765323638916, 0.5970894694328308, 0.4158252775669098, -0.12339584529399872, -2.1541597843170166, -1.1511454582214355, 0.3774460256099701, -0.29745033383369446, -1.608638048171997, 1.3731272220611572, -1.0900952816009521, -0.9374119639396667, 0.5718950033187866, 0.03636741638183594, 1.294400691986084, 0.3412879705429077, 1.6510262489318848, 2.0523462295532227, 0.8939493894577026, 0.27901414036750793, 1.3092777729034424, -0.0659836158156395, -0.44496071338653564, 1.8562805652618408, -0.5436741709709167, 0.4899655878543854, 1.0222673416137695, -0.3963838219642639, -1.0214312076568604, -0.7901312708854675, -1.2594609260559082, -0.6962406635284424, 1.1476776599884033, 0.0791839137673378, -1.2248289585113525, 0.24992510676383972, 1.6803746223449707, 0.10206639766693115, -0.2503906488418579, 0.734736442565918, 0.42630645632743835, -0.791186511516571, -0.12093118578195572, -0.9024736881256104, 0.5244492292404175, -0.1165451928973198, -0.24696758389472961, 0.2044251710176468, 0.5142940878868103, 1.2933149337768555, -0.004106536041945219, 0.07968569546937943, 1.2674732208251953, -1.3896150588989258, 1.4912166595458984, -0.6348900198936462, 0.3363434970378876, -2.429456949234009, 1.3182454109191895, -0.7572859525680542, 1.8073227405548096, -2.60520339012146, 0.3974285125732422, -0.554563045501709, -0.5101087093353271, 0.21334029734134674, -0.2650969922542572, 0.18495149910449982, -0.1411752551794052, -0.986203134059906, -0.059530794620513916, -0.7845174670219421, 0.5819364786148071, 1.0677433013916016, 1.4098520278930664, -0.9571059346199036, -0.2349909245967865, -1.7473530769348145, -0.10524901747703552, -0.6533030867576599, 0.3108111619949341, -1.9339635372161865, -0.10550384223461151, -2.0085337162017822, -2.2727315425872803, -1.4903881549835205, -0.8796289563179016, 1.0937819480895996, 0.14588558673858643, -1.0359282493591309, 1.110337495803833, -0.41871291399002075, -1.7237944602966309, 1.132631540298462, -2.1923458576202393 ]
https://github.com/huggingface/datasets/issues/5193
"One or several metadata. were found, but not in the same directory or in a parent directory"
> Hi @lambda-science! It seems that your repo is recognized as a packaged module [ImageFolder](https://huggingface.co/docs/datasets/main/en/image_dataset#imagefolder), not as a dataset with the custom loading script, because loader looks for a script that has the same name as the dataset repo. So please try to rename your script to `MyoQuant-SDH-Data.py`, this should help. Hi ! Thank you for your answer. That was... embarrassingly easy, sorry for this issue, everything is fixed now ! Have a nice day ! :)
### Describe the bug When loading my own dataset, on loading it I get an error. Here is my dataset link: https://huggingface.co/datasets/corentinm7/MyoQuant-SDH-Data And the error after loading with: ```python from datasets import load_dataset load_dataset("corentinm7/MyoQuant-SDH-Data") ``` ```python Downloading readme: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.34k/3.34k [00:00<00:00, 4.45MB/s] Using custom data configuration SDH_16k-53e7301a92ab0025 Downloading and preparing dataset None/SDH_16k to /home/corentin/.cache/huggingface/datasets/corentinm7___imagefolder/SDH_16k-53e7301a92ab0025/0.0.0/37fbb85cc714a338bea574ac6c7d0b5be5aff46c1862c1989b20e0771199e93f... Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.28M/3.28M [00:00<00:00, 4.31MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:01<00:00, 1.75s/it] Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1.13G/1.13G [00:15<00:00, 74.3MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:16<00:00, 16.09s/it] Extracting data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:13<00:00, 13.16s/it] Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/load.py", line 1742, in load_dataset builder_instance.download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 814, in download_and_prepare self._download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 1423, in _download_and_prepare super()._download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 905, in _download_and_prepare self._prepare_split(split_generator, **prepare_split_kwargs) File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 1374, in _prepare_split for key, record in logging.tqdm( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/tqdm/std.py", line 1195, in __iter__ for obj in iterable: File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/packaged_modules/folder_based_builder/folder_based_builder.py", line 394, in _generate_examples raise ValueError( ValueError: One or several metadata. were found, but not in the same directory or in a parent directory of /home/corentin/.cache/huggingface/datasets/downloads/extracted/60c4aa8d4da3065bb3d310de4373dffd73bd4dc331aedcb4ee867febe4fdb7cd/validation/sick/2_CG_SDH_TAM_Bin1cKO_ko_pla_4_1640.tif. ``` However the test command is working fine. ```datasets-cli test hugging_face_play/ds_test/SDH_16k.py --save_info --all_configs --force_redownload``` ``` Using custom data configuration SDH_16k Testing builder 'SDH_16k' (1/1) Downloading and preparing dataset sdh_16k/SDH_16k to /home/corentin/.cache/huggingface/datasets/sdh_16k/SDH_16k/1.0.0/21b584239a638aeeda33cba1ac2ca4869d48e4b4f20fb22274d5a5ddc487659d... Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1.13G/1.13G [00:14<00:00, 76.5MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:15<00:00, 15.66s/it] Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.28M/3.28M [00:02<00:00, 1.44MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:03<00:00, 3.21s/it] Downloading data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:00<00:00, 11586.48it/s] Extracting data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:13<00:00, 13.42s/it] Dataset sdh_16k downloaded and prepared to /home/corentin/.cache/huggingface/datasets/sdh_16k/SDH_16k/1.0.0/21b584239a638aeeda33cba1ac2ca4869d48e4b4f20fb22274d5a5ddc487659d. Subsequent calls will reuse this data. 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3/3 [00:00<00:00, 605.27it/s] Dataset card saved at hugging_face_play/ds_test/README.md Test successful. ``` ### Steps to reproduce the bug Simply run on python ```python from datasets import load_dataset load_dataset("corentinm7/MyoQuant-SDH-Data") ``` ### Expected behavior As the test command worked, this error should not appear ### Environment info - `datasets` version: 2.6.1 - Platform: Linux-5.10.16.3-microsoft-standard-WSL2-x86_64-with-glibc2.31 - Python version: 3.10.6 - PyArrow version: 10.0.0 - Pandas version: 1.5.1
443
77
"One or several metadata. were found, but not in the same directory or in a parent directory" ### Describe the bug When loading my own dataset, on loading it I get an error. Here is my dataset link: https://huggingface.co/datasets/corentinm7/MyoQuant-SDH-Data And the error after loading with: ```python from datasets import load_dataset load_dataset("corentinm7/MyoQuant-SDH-Data") ``` ```python Downloading readme: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.34k/3.34k [00:00<00:00, 4.45MB/s] Using custom data configuration SDH_16k-53e7301a92ab0025 Downloading and preparing dataset None/SDH_16k to /home/corentin/.cache/huggingface/datasets/corentinm7___imagefolder/SDH_16k-53e7301a92ab0025/0.0.0/37fbb85cc714a338bea574ac6c7d0b5be5aff46c1862c1989b20e0771199e93f... Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.28M/3.28M [00:00<00:00, 4.31MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:01<00:00, 1.75s/it] Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1.13G/1.13G [00:15<00:00, 74.3MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:16<00:00, 16.09s/it] Extracting data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:13<00:00, 13.16s/it] Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/load.py", line 1742, in load_dataset builder_instance.download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 814, in download_and_prepare self._download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 1423, in _download_and_prepare super()._download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 905, in _download_and_prepare self._prepare_split(split_generator, **prepare_split_kwargs) File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 1374, in _prepare_split for key, record in logging.tqdm( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/tqdm/std.py", line 1195, in __iter__ for obj in iterable: File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/packaged_modules/folder_based_builder/folder_based_builder.py", line 394, in _generate_examples raise ValueError( ValueError: One or several metadata. were found, but not in the same directory or in a parent directory of /home/corentin/.cache/huggingface/datasets/downloads/extracted/60c4aa8d4da3065bb3d310de4373dffd73bd4dc331aedcb4ee867febe4fdb7cd/validation/sick/2_CG_SDH_TAM_Bin1cKO_ko_pla_4_1640.tif. ``` However the test command is working fine. ```datasets-cli test hugging_face_play/ds_test/SDH_16k.py --save_info --all_configs --force_redownload``` ``` Using custom data configuration SDH_16k Testing builder 'SDH_16k' (1/1) Downloading and preparing dataset sdh_16k/SDH_16k to /home/corentin/.cache/huggingface/datasets/sdh_16k/SDH_16k/1.0.0/21b584239a638aeeda33cba1ac2ca4869d48e4b4f20fb22274d5a5ddc487659d... Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1.13G/1.13G [00:14<00:00, 76.5MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:15<00:00, 15.66s/it] Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.28M/3.28M [00:02<00:00, 1.44MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:03<00:00, 3.21s/it] Downloading data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:00<00:00, 11586.48it/s] Extracting data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:13<00:00, 13.42s/it] Dataset sdh_16k downloaded and prepared to /home/corentin/.cache/huggingface/datasets/sdh_16k/SDH_16k/1.0.0/21b584239a638aeeda33cba1ac2ca4869d48e4b4f20fb22274d5a5ddc487659d. Subsequent calls will reuse this data. 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3/3 [00:00<00:00, 605.27it/s] Dataset card saved at hugging_face_play/ds_test/README.md Test successful. ``` ### Steps to reproduce the bug Simply run on python ```python from datasets import load_dataset load_dataset("corentinm7/MyoQuant-SDH-Data") ``` ### Expected behavior As the test command worked, this error should not appear ### Environment info - `datasets` version: 2.6.1 - Platform: Linux-5.10.16.3-microsoft-standard-WSL2-x86_64-with-glibc2.31 - Python version: 3.10.6 - PyArrow version: 10.0.0 - Pandas version: 1.5.1 > Hi @lambda-science! It seems that your repo is recognized as a packaged module [ImageFolder](https://huggingface.co/docs/datasets/main/en/image_dataset#imagefolder), not as a dataset with the custom loading script, because loader looks for a script that has the same name as the dataset repo. So please try to rename your script to `MyoQuant-SDH-Data.py`, this should help. Hi ! Thank you for your answer. That was... embarrassingly easy, sorry for this issue, everything is fixed now ! Have a nice day ! :)
[ -1.1513481140136719, -0.8950071930885315, -0.7690081000328064, 1.4270761013031006, -0.05569703131914139, -1.244236946105957, 0.12335053086280823, -1.1508922576904297, 1.5475118160247803, -0.6729012131690979, 0.29542702436447144, -1.7627599239349365, -0.03960840404033661, -0.5458818674087524, -0.7904717326164246, -0.8730937242507935, -0.39900246262550354, -0.8042073249816895, 0.9166461825370789, 2.4917469024658203, 1.2181382179260254, -1.355351448059082, 2.7918732166290283, 0.6390748023986816, -0.26768362522125244, -0.9507211446762085, 0.5859518647193909, 0.056174591183662415, -1.3944108486175537, -0.3314271867275238, -0.8961967825889587, -0.0630229040980339, -0.5856070518493652, -0.44000744819641113, 0.16081306338310242, 0.39702466130256653, -0.2866356670856476, -0.4238445460796356, -0.5518879294395447, -0.7803190350532532, 0.5477887988090515, -0.30618831515312195, 0.9749169945716858, -0.356801837682724, 1.7831218242645264, -0.6768479943275452, 0.3875423073768616, 0.7589303851127625, 1.260462760925293, 0.1495506763458252, 0.11132361739873886, 0.3958492875099182, 0.3549879789352417, 0.011983383446931839, 0.37305545806884766, 1.2434604167938232, 0.5187172889709473, 0.4216814637184143, 0.7459096908569336, -2.124134063720703, 1.3102226257324219, -0.9111434817314148, 0.2678227126598358, 1.361147165298462, -0.7931784987449646, 0.2778749167919159, -1.8839540481567383, -0.11444097757339478, 0.5824437141418457, -2.1739790439605713, 0.2869797945022583, -1.272953987121582, -0.5031480193138123, 0.9034112691879272, 0.34270286560058594, -1.0776703357696533, 0.2140909731388092, -0.5959327220916748, 1.0001859664916992, 0.4509925842285156, 1.1855924129486084, -1.6878068447113037, -0.0600484199821949, -0.2128417193889618, 0.13158097863197327, -1.34938645362854, -1.6057531833648682, 0.6287413835525513, 0.6119655966758728, 0.676578164100647, -0.0882943645119667, 1.0231482982635498, -1.0165541172027588, 0.8717881441116333, -0.9961537718772888, -1.7461130619049072, -1.3024768829345703, -2.314701795578003, -2.3139610290527344, 0.7555503845214844, -0.439631849527359, -0.45525044202804565, 1.9843285083770752, -0.9247167706489563, -1.7471132278442383, 1.0836687088012695, 0.28158020973205566, -0.028086910024285316, 2.396171808242798, 0.2568790912628174, -0.779274046421051, 0.4610007405281067, -0.7601338624954224, 0.7869120240211487, -0.20604504644870758, 1.3353841304779053, 0.4674963355064392, -0.8935851454734802, 1.548727035522461, -0.4630432426929474, 0.5005245208740234, -0.7024719715118408, -0.5334359407424927, -0.7364922761917114, 0.23865658044815063, 1.9233484268188477, -0.42383038997650146, 1.5508630275726318, -0.3679881691932678, -1.6113908290863037, -1.495116949081421, 0.8324441313743591, 0.5686793923377991, -0.8695210814476013, 0.03016284480690956, -0.39604976773262024, 0.18780970573425293, 0.008881762623786926, 1.0786433219909668, 1.2615690231323242, 0.7484303116798401, -0.3310778737068176, -0.8446767330169678, 0.19008518755435944, -0.11297627538442612, -0.8354676365852356, -1.7350094318389893, -0.324643075466156, 0.22538529336452484, 0.6949381828308105, -1.353224754333496, 1.7768988609313965, 0.9033784866333008, 2.062497615814209, 0.9594843983650208, -0.4511496424674988, 1.5336472988128662, 0.03194117546081543, 1.8902013301849365, -0.4876079261302948, 0.6098837852478027, -0.43267345428466797, -1.102311611175537, 0.8554531335830688, -0.2887655198574066, -1.9970715045928955, -0.8012484312057495, -0.8494881391525269, -0.14663003385066986, -0.7619706988334656, 0.9281796216964722, -0.31167641282081604, -1.5509533882141113, 0.19786155223846436, -0.7092428803443909, 0.02716352418065071, -1.2282228469848633, 0.13936936855316162, 0.651091992855072, -0.6888821125030518, 0.0740366280078888, -0.19999133050441742, -1.3391478061676025, -0.4930115342140198, 0.3091401159763336, 1.9523181915283203, -0.7012122273445129, 0.9624255895614624, 1.0754199028015137, -0.6794649958610535, 0.14529035985469818, 0.328689843416214, -0.33727362751960754, 0.7726941108703613, -1.208702564239502, -0.38269293308258057, 1.0776350498199463, -0.04745514318346977, -0.5583831071853638, 1.4944581985473633, 0.8078822493553162, -1.0622241497039795, -0.2787948250770569, -0.1408083289861679, -0.8132069110870361, -0.032916173338890076, -1.5833837985992432, -0.06800748407840729, 0.32760000228881836, -1.437854290008545, -0.43708252906799316, -0.26154905557632446, 1.1959543228149414, -0.14346742630004883, 1.4330010414123535, -0.3074665367603302, -0.2247018963098526, -0.3905750811100006, -0.45016953349113464, 0.09773241728544235, -0.32931894063949585, -0.5874088406562805, 0.23618637025356293, -0.847489058971405, 0.26867958903312683, 1.5039350986480713, 0.27552685141563416, 0.09165970236063004, 0.45360052585601807, 1.1524734497070312, 0.36595606803894043, 0.06776563078165054, -0.8602113127708435, -1.509901523590088, 2.0463716983795166, -1.5893404483795166, 1.9567499160766602, 0.7536913156509399, -0.01516249030828476, -1.836583137512207, -1.8751928806304932, 1.3658771514892578, 1.0911085605621338, 2.451479911804199, 0.5792697072029114, 0.43776679039001465, -0.7700514793395996, -0.7366793751716614, 0.3618931472301483, -0.935401976108551, -0.6850456595420837, 0.26834145188331604, 2.3727428913116455, 1.706296682357788, -0.5786855816841125, -0.2310444563627243, -0.8549292087554932, 1.3564746379852295, -0.0768507793545723, 0.20616069436073303, 2.04994797706604, -0.19971463084220886, -1.118680477142334, 1.262486219406128, -2.3488731384277344, 0.1674761027097702, 2.003664016723633, 0.2983110547065735, 0.12134553492069244, -1.4230964183807373, -0.6571397185325623, -0.3851408362388611, -0.4624551832675934, -1.2292499542236328, 0.6096989512443542, -0.29440250992774963, -0.9131664633750916, -1.474195957183838, 0.03905776888132095, -1.1584880352020264, -1.7335197925567627, 0.3595767319202423, 1.8945825099945068, 2.1348023414611816, -0.7562553882598877, 1.441354513168335, -0.33584165573120117, 0.04444023594260216, 1.1793906688690186, 1.292923927307129, 3.0534279346466064, 1.8321499824523926, -1.2424020767211914, 0.7614278197288513, -0.14163008332252502, -0.45329415798187256, 1.082557201385498, -1.0869264602661133, 1.1351773738861084, -0.19746308028697968, -1.205437421798706, -1.1502463817596436, 1.0558764934539795, 0.3917936086654663, 0.04795142263174057, -0.5126159191131592, 1.311513900756836, 0.07889058440923691, 1.3403947353363037, 0.5844317674636841, -0.2719807028770447, 0.56777024269104, -0.36403506994247437, -0.5597935318946838, 1.6431701183319092, 0.1781744658946991, -1.4560937881469727, -2.516721487045288, -0.2649511694908142, -0.8839423656463623, 0.035654496401548386, -0.6581291556358337, -1.1138861179351807, 1.6405889987945557, 0.3793220520019531, -1.307363748550415, -0.2525630593299866, -0.349832683801651, -0.5881023406982422, 2.626633644104004, -1.416243076324463, -0.10334441810846329, -0.9074795246124268, -0.5116516947746277, 1.6082003116607666, -1.1500682830810547, -0.24226710200309753, -1.1136605739593506, -0.567676842212677, -1.350315809249878, -0.5899694561958313, 0.0623999685049057, -0.895219087600708, 0.7958406805992126, 0.17607825994491577, -1.0855822563171387, -0.26272884011268616, -0.9276371598243713, 0.9914315342903137, -0.0545816607773304, 0.25904616713523865, 1.8715956211090088, 0.40830036997795105, -0.3789440393447876, 0.7166363596916199, 1.1759214401245117, 0.6499977111816406, -0.6554539799690247, 0.06486876308917999, -0.6491432785987854, 0.23234140872955322, -1.408212661743164, 0.24928516149520874, -2.823524236679077, 0.7073701024055481, -0.09373742341995239, 0.0020622191950678825, -0.044905729591846466, -1.2705597877502441, 1.1748764514923096, 2.6833372116088867, -1.142648458480835, 0.5339173674583435, 0.35736438632011414, 1.1827950477600098, -1.4712300300598145, 0.26699885725975037, -0.39934059977531433, 2.0325000286102295, 0.06230513006448746, 1.170525312423706, -0.5601316094398499, -2.177494525909424, 0.6072453260421753, -1.2915232181549072, -1.093179702758789, 0.8512124419212341, -0.8744171261787415, 0.2232491374015808, -1.4630002975463867, -0.27639174461364746, -0.9837376475334167, -1.236189365386963, 0.6797045469284058, 0.11581212282180786, 0.5405554175376892, -0.543260931968689, 0.37450990080833435, -2.2846362590789795, -1.446869134902954, -0.17385882139205933, -1.0147674083709717, 0.5676365494728088, -0.3260263502597809, 0.7176563739776611, -0.09841689467430115, 0.06029035151004791, 0.4273790419101715, 1.3145558834075928, 3.360629081726074, 0.1646161824464798, 0.26494458317756653, -0.12166551500558853, -1.0329430103302002, 1.358548879623413, 0.9996828436851501, -0.10063111037015915, -0.5722072124481201, -1.0157599449157715, 1.2015328407287598, 2.03369140625, 1.0931243896484375, -0.01000891625881195, -0.8446508049964905, -0.8463783264160156, 0.1345713883638382, 0.2113482654094696, 0.6129223704338074, 0.956882894039154, -0.055721789598464966, 0.11378221213817596, 1.472623348236084, 1.1372480392456055, -0.436359703540802, 0.44929632544517517, -0.9114785194396973, -0.4093230366706848, 0.47958919405937195, 0.18357770144939423, 0.04459501802921295, 0.4212489128112793, -1.0924553871154785, -0.30797532200813293, -0.30899161100387573, -0.8948781490325928, -0.6658729910850525, -0.43526262044906616, -0.4302772581577301, 1.5971639156341553, 0.08876854926347733, -0.44572558999061584, 0.10277868807315826, -0.6755667328834534, -0.15152379870414734, -1.1707265377044678, 0.22035850584506989, -0.2043609917163849, -0.022755460813641548, -0.08342966437339783, 1.837325096130371, -0.9350897073745728, -2.0669143199920654, 0.16520848870277405, 0.2813240587711334, -0.3923700451850891, 0.24408817291259766, 1.70039963722229, 0.6338827013969421, 1.3505780696868896, 1.2984814643859863, 0.8921394348144531, -0.6856156587600708, -1.257873773574829, 0.6068567633628845, 0.9351285099983215, -1.3557560443878174, 0.7877652645111084, -0.12785778939723969, -0.4687468111515045, 0.644012451171875, 1.34373140335083, 0.3852587938308716, -2.0921084880828857, 0.8778418898582458, -0.8541280627250671, 0.7719696164131165, 0.7038345336914062, 0.7436479926109314, 0.20975252985954285, 0.7769941687583923, -1.2338426113128662, -1.086381435394287, -0.8179945945739746, -0.6450372338294983, 1.8991057872772217, -0.1962120682001114, 0.40249213576316833, -0.22068285942077637, -1.1977481842041016, -0.10834809392690659, 0.7151972651481628, 0.3748984634876251, -0.43124130368232727, 0.7780368328094482, -0.5401567220687866, -1.1127324104309082, -1.2308645248413086, -0.5540781021118164, -1.0293517112731934, -0.9000663757324219, 0.941565990447998, 0.7121763825416565, 0.42758920788764954, 1.8834295272827148, 0.6826808452606201, 0.24039563536643982, -2.697089433670044, 0.9418428540229797, 0.30148816108703613, -0.04596703499555588, 0.9811089038848877, 0.33273079991340637, 1.1527118682861328, -0.05802620202302933, 0.5842932462692261, -2.4085745811462402, 2.2982699871063232, -0.23040863871574402, 0.7362977862358093, -0.043138958513736725, -0.23207098245620728, 1.1067941188812256, 0.5272631645202637, 0.5380838513374329, -1.0799355506896973, 0.6497417092323303, -0.7008094787597656, 1.0924787521362305, 0.850045382976532, -0.8871825933456421, 0.0878080502152443, 1.2750964164733887, 0.4982439875602722, -0.4196550250053406, -0.9472859501838684, -0.8253911137580872, 0.9836701154708862, 1.6957314014434814, -0.08405783027410507, 0.08703908324241638, 0.9426915049552917, 0.5794355869293213, -1.3065645694732666, 0.009720170870423317, -0.6990299820899963, -0.8183271884918213, 1.7513439655303955, 2.132476806640625, -0.09379429370164871, -0.09737097471952438, -0.7643058896064758, -1.2322075366973877, 0.7723854184150696, -0.06378144770860672, 0.1612231433391571, 0.5317140221595764, -0.712695300579071, 1.242621898651123, 0.6372846961021423, 0.9686493277549744, 0.08572104573249817, 0.3713941276073456, 0.2943043112754822, -0.3413039445877075, -1.1585943698883057, -0.3764116168022156, -1.068821907043457, -2.4039623737335205, 0.5434005856513977, -0.14232264459133148, -1.4884283542633057, 0.04628803953528404, -0.9921693205833435, 0.8899607062339783, -0.5686308145523071, -1.0231549739837646, -1.4575176239013672, 0.3554272949695587, -0.23128998279571533, 1.009629487991333, -1.644036054611206, -0.08741676062345505, 1.2032442092895508, 0.893016517162323, -0.5762561559677124, 0.9623696804046631, 0.3390819728374481, 1.0059046745300293, 0.8208916783332825, -0.3177860975265503, 0.5695604085922241, 0.1117515116930008, -1.2789876461029053, 0.40760537981987, 1.1903886795043945, 0.14040744304656982, 1.436255693435669, -0.4422539472579956, 0.07354798167943954, 0.35420385003089905, -0.46131688356399536, -0.4501640200614929, -0.5442419052124023, 0.5951755046844482, 0.15469776093959808, -1.0739636421203613, -0.1181337758898735, -0.04441928490996361, -0.19752788543701172, 0.2941344976425171, -1.500652551651001, -0.29525208473205566, -0.3711174428462982, -0.4850594997406006, -1.2491703033447266, 0.05569808930158615, 1.3067777156829834, -0.8017001152038574, -0.23832285404205322, 0.4000936448574066, 0.3669297397136688, 0.5967146754264832, 0.639492392539978, -0.6759822964668274, -0.3874078691005707, -0.30812960863113403, -0.34758180379867554, 0.23947565257549286, 1.2277140617370605, -0.10522263497114182, -1.0755610466003418, 0.7324354648590088, -0.4545269310474396, 0.09479999542236328, 1.9358851909637451, -0.04677160829305649, -0.7268698215484619, 0.31264176964759827, -0.6923533082008362, 1.9189105033874512, 1.7735915184020996, 1.272773027420044, -0.20546264946460724, -0.8926507234573364, 0.5763269066810608, -0.31978654861450195, -0.22494478523731232, 0.9336066842079163, 0.4297490119934082, -0.19055216014385223, -1.4224355220794678, 0.486291766166687, 1.363673448562622, -0.893842875957489, -0.7976875305175781, 0.13479283452033997, -0.8358256220817566, 1.1265802383422852, 0.7129209637641907, 0.32614389061927795, 0.3083014488220215, 1.5180299282073975, 0.7791673541069031, -0.5000765323638916, 0.5970894694328308, 0.4158252775669098, -0.12339584529399872, -2.1541597843170166, -1.1511454582214355, 0.3774460256099701, -0.29745033383369446, -1.608638048171997, 1.3731272220611572, -1.0900952816009521, -0.9374119639396667, 0.5718950033187866, 0.03636741638183594, 1.294400691986084, 0.3412879705429077, 1.6510262489318848, 2.0523462295532227, 0.8939493894577026, 0.27901414036750793, 1.3092777729034424, -0.0659836158156395, -0.44496071338653564, 1.8562805652618408, -0.5436741709709167, 0.4899655878543854, 1.0222673416137695, -0.3963838219642639, -1.0214312076568604, -0.7901312708854675, -1.2594609260559082, -0.6962406635284424, 1.1476776599884033, 0.0791839137673378, -1.2248289585113525, 0.24992510676383972, 1.6803746223449707, 0.10206639766693115, -0.2503906488418579, 0.734736442565918, 0.42630645632743835, -0.791186511516571, -0.12093118578195572, -0.9024736881256104, 0.5244492292404175, -0.1165451928973198, -0.24696758389472961, 0.2044251710176468, 0.5142940878868103, 1.2933149337768555, -0.004106536041945219, 0.07968569546937943, 1.2674732208251953, -1.3896150588989258, 1.4912166595458984, -0.6348900198936462, 0.3363434970378876, -2.429456949234009, 1.3182454109191895, -0.7572859525680542, 1.8073227405548096, -2.60520339012146, 0.3974285125732422, -0.554563045501709, -0.5101087093353271, 0.21334029734134674, -0.2650969922542572, 0.18495149910449982, -0.1411752551794052, -0.986203134059906, -0.059530794620513916, -0.7845174670219421, 0.5819364786148071, 1.0677433013916016, 1.4098520278930664, -0.9571059346199036, -0.2349909245967865, -1.7473530769348145, -0.10524901747703552, -0.6533030867576599, 0.3108111619949341, -1.9339635372161865, -0.10550384223461151, -2.0085337162017822, -2.2727315425872803, -1.4903881549835205, -0.8796289563179016, 1.0937819480895996, 0.14588558673858643, -1.0359282493591309, 1.110337495803833, -0.41871291399002075, -1.7237944602966309, 1.132631540298462, -2.1923458576202393 ]
https://github.com/huggingface/datasets/issues/5193
"One or several metadata. were found, but not in the same directory or in a parent directory"
@lambda-science that's not embarrassing at all! it's actually not clear from the documentation that the script should have the same name, so thank you for the issue, we'll add this information to the docs :)
### Describe the bug When loading my own dataset, on loading it I get an error. Here is my dataset link: https://huggingface.co/datasets/corentinm7/MyoQuant-SDH-Data And the error after loading with: ```python from datasets import load_dataset load_dataset("corentinm7/MyoQuant-SDH-Data") ``` ```python Downloading readme: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.34k/3.34k [00:00<00:00, 4.45MB/s] Using custom data configuration SDH_16k-53e7301a92ab0025 Downloading and preparing dataset None/SDH_16k to /home/corentin/.cache/huggingface/datasets/corentinm7___imagefolder/SDH_16k-53e7301a92ab0025/0.0.0/37fbb85cc714a338bea574ac6c7d0b5be5aff46c1862c1989b20e0771199e93f... Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.28M/3.28M [00:00<00:00, 4.31MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:01<00:00, 1.75s/it] Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1.13G/1.13G [00:15<00:00, 74.3MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:16<00:00, 16.09s/it] Extracting data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:13<00:00, 13.16s/it] Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/load.py", line 1742, in load_dataset builder_instance.download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 814, in download_and_prepare self._download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 1423, in _download_and_prepare super()._download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 905, in _download_and_prepare self._prepare_split(split_generator, **prepare_split_kwargs) File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 1374, in _prepare_split for key, record in logging.tqdm( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/tqdm/std.py", line 1195, in __iter__ for obj in iterable: File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/packaged_modules/folder_based_builder/folder_based_builder.py", line 394, in _generate_examples raise ValueError( ValueError: One or several metadata. were found, but not in the same directory or in a parent directory of /home/corentin/.cache/huggingface/datasets/downloads/extracted/60c4aa8d4da3065bb3d310de4373dffd73bd4dc331aedcb4ee867febe4fdb7cd/validation/sick/2_CG_SDH_TAM_Bin1cKO_ko_pla_4_1640.tif. ``` However the test command is working fine. ```datasets-cli test hugging_face_play/ds_test/SDH_16k.py --save_info --all_configs --force_redownload``` ``` Using custom data configuration SDH_16k Testing builder 'SDH_16k' (1/1) Downloading and preparing dataset sdh_16k/SDH_16k to /home/corentin/.cache/huggingface/datasets/sdh_16k/SDH_16k/1.0.0/21b584239a638aeeda33cba1ac2ca4869d48e4b4f20fb22274d5a5ddc487659d... Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1.13G/1.13G [00:14<00:00, 76.5MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:15<00:00, 15.66s/it] Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.28M/3.28M [00:02<00:00, 1.44MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:03<00:00, 3.21s/it] Downloading data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:00<00:00, 11586.48it/s] Extracting data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:13<00:00, 13.42s/it] Dataset sdh_16k downloaded and prepared to /home/corentin/.cache/huggingface/datasets/sdh_16k/SDH_16k/1.0.0/21b584239a638aeeda33cba1ac2ca4869d48e4b4f20fb22274d5a5ddc487659d. Subsequent calls will reuse this data. 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3/3 [00:00<00:00, 605.27it/s] Dataset card saved at hugging_face_play/ds_test/README.md Test successful. ``` ### Steps to reproduce the bug Simply run on python ```python from datasets import load_dataset load_dataset("corentinm7/MyoQuant-SDH-Data") ``` ### Expected behavior As the test command worked, this error should not appear ### Environment info - `datasets` version: 2.6.1 - Platform: Linux-5.10.16.3-microsoft-standard-WSL2-x86_64-with-glibc2.31 - Python version: 3.10.6 - PyArrow version: 10.0.0 - Pandas version: 1.5.1
443
35
"One or several metadata. were found, but not in the same directory or in a parent directory" ### Describe the bug When loading my own dataset, on loading it I get an error. Here is my dataset link: https://huggingface.co/datasets/corentinm7/MyoQuant-SDH-Data And the error after loading with: ```python from datasets import load_dataset load_dataset("corentinm7/MyoQuant-SDH-Data") ``` ```python Downloading readme: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.34k/3.34k [00:00<00:00, 4.45MB/s] Using custom data configuration SDH_16k-53e7301a92ab0025 Downloading and preparing dataset None/SDH_16k to /home/corentin/.cache/huggingface/datasets/corentinm7___imagefolder/SDH_16k-53e7301a92ab0025/0.0.0/37fbb85cc714a338bea574ac6c7d0b5be5aff46c1862c1989b20e0771199e93f... Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.28M/3.28M [00:00<00:00, 4.31MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:01<00:00, 1.75s/it] Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1.13G/1.13G [00:15<00:00, 74.3MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:16<00:00, 16.09s/it] Extracting data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:13<00:00, 13.16s/it] Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/load.py", line 1742, in load_dataset builder_instance.download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 814, in download_and_prepare self._download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 1423, in _download_and_prepare super()._download_and_prepare( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 905, in _download_and_prepare self._prepare_split(split_generator, **prepare_split_kwargs) File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/builder.py", line 1374, in _prepare_split for key, record in logging.tqdm( File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/tqdm/std.py", line 1195, in __iter__ for obj in iterable: File "/home/corentin/code-project/hugging_face_play/.venv/lib/python3.10/site-packages/datasets/packaged_modules/folder_based_builder/folder_based_builder.py", line 394, in _generate_examples raise ValueError( ValueError: One or several metadata. were found, but not in the same directory or in a parent directory of /home/corentin/.cache/huggingface/datasets/downloads/extracted/60c4aa8d4da3065bb3d310de4373dffd73bd4dc331aedcb4ee867febe4fdb7cd/validation/sick/2_CG_SDH_TAM_Bin1cKO_ko_pla_4_1640.tif. ``` However the test command is working fine. ```datasets-cli test hugging_face_play/ds_test/SDH_16k.py --save_info --all_configs --force_redownload``` ``` Using custom data configuration SDH_16k Testing builder 'SDH_16k' (1/1) Downloading and preparing dataset sdh_16k/SDH_16k to /home/corentin/.cache/huggingface/datasets/sdh_16k/SDH_16k/1.0.0/21b584239a638aeeda33cba1ac2ca4869d48e4b4f20fb22274d5a5ddc487659d... Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1.13G/1.13G [00:14<00:00, 76.5MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:15<00:00, 15.66s/it] Downloading data: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3.28M/3.28M [00:02<00:00, 1.44MB/s] Downloading data files: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:03<00:00, 3.21s/it] Downloading data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:00<00:00, 11586.48it/s] Extracting data files: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:13<00:00, 13.42s/it] Dataset sdh_16k downloaded and prepared to /home/corentin/.cache/huggingface/datasets/sdh_16k/SDH_16k/1.0.0/21b584239a638aeeda33cba1ac2ca4869d48e4b4f20fb22274d5a5ddc487659d. Subsequent calls will reuse this data. 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 3/3 [00:00<00:00, 605.27it/s] Dataset card saved at hugging_face_play/ds_test/README.md Test successful. ``` ### Steps to reproduce the bug Simply run on python ```python from datasets import load_dataset load_dataset("corentinm7/MyoQuant-SDH-Data") ``` ### Expected behavior As the test command worked, this error should not appear ### Environment info - `datasets` version: 2.6.1 - Platform: Linux-5.10.16.3-microsoft-standard-WSL2-x86_64-with-glibc2.31 - Python version: 3.10.6 - PyArrow version: 10.0.0 - Pandas version: 1.5.1 @lambda-science that's not embarrassing at all! it's actually not clear from the documentation that the script should have the same name, so thank you for the issue, we'll add this information to the docs :)
[ -1.1513481140136719, -0.8950071930885315, -0.7690081000328064, 1.4270761013031006, -0.05569703131914139, -1.244236946105957, 0.12335053086280823, -1.1508922576904297, 1.5475118160247803, -0.6729012131690979, 0.29542702436447144, -1.7627599239349365, -0.03960840404033661, -0.5458818674087524, -0.7904717326164246, -0.8730937242507935, -0.39900246262550354, -0.8042073249816895, 0.9166461825370789, 2.4917469024658203, 1.2181382179260254, -1.355351448059082, 2.7918732166290283, 0.6390748023986816, -0.26768362522125244, -0.9507211446762085, 0.5859518647193909, 0.056174591183662415, -1.3944108486175537, -0.3314271867275238, -0.8961967825889587, -0.0630229040980339, -0.5856070518493652, -0.44000744819641113, 0.16081306338310242, 0.39702466130256653, -0.2866356670856476, -0.4238445460796356, -0.5518879294395447, -0.7803190350532532, 0.5477887988090515, -0.30618831515312195, 0.9749169945716858, -0.356801837682724, 1.7831218242645264, -0.6768479943275452, 0.3875423073768616, 0.7589303851127625, 1.260462760925293, 0.1495506763458252, 0.11132361739873886, 0.3958492875099182, 0.3549879789352417, 0.011983383446931839, 0.37305545806884766, 1.2434604167938232, 0.5187172889709473, 0.4216814637184143, 0.7459096908569336, -2.124134063720703, 1.3102226257324219, -0.9111434817314148, 0.2678227126598358, 1.361147165298462, -0.7931784987449646, 0.2778749167919159, -1.8839540481567383, -0.11444097757339478, 0.5824437141418457, -2.1739790439605713, 0.2869797945022583, -1.272953987121582, -0.5031480193138123, 0.9034112691879272, 0.34270286560058594, -1.0776703357696533, 0.2140909731388092, -0.5959327220916748, 1.0001859664916992, 0.4509925842285156, 1.1855924129486084, -1.6878068447113037, -0.0600484199821949, -0.2128417193889618, 0.13158097863197327, -1.34938645362854, -1.6057531833648682, 0.6287413835525513, 0.6119655966758728, 0.676578164100647, -0.0882943645119667, 1.0231482982635498, -1.0165541172027588, 0.8717881441116333, -0.9961537718772888, -1.7461130619049072, -1.3024768829345703, -2.314701795578003, -2.3139610290527344, 0.7555503845214844, -0.439631849527359, -0.45525044202804565, 1.9843285083770752, -0.9247167706489563, -1.7471132278442383, 1.0836687088012695, 0.28158020973205566, -0.028086910024285316, 2.396171808242798, 0.2568790912628174, -0.779274046421051, 0.4610007405281067, -0.7601338624954224, 0.7869120240211487, -0.20604504644870758, 1.3353841304779053, 0.4674963355064392, -0.8935851454734802, 1.548727035522461, -0.4630432426929474, 0.5005245208740234, -0.7024719715118408, -0.5334359407424927, -0.7364922761917114, 0.23865658044815063, 1.9233484268188477, -0.42383038997650146, 1.5508630275726318, -0.3679881691932678, -1.6113908290863037, -1.495116949081421, 0.8324441313743591, 0.5686793923377991, -0.8695210814476013, 0.03016284480690956, -0.39604976773262024, 0.18780970573425293, 0.008881762623786926, 1.0786433219909668, 1.2615690231323242, 0.7484303116798401, -0.3310778737068176, -0.8446767330169678, 0.19008518755435944, -0.11297627538442612, -0.8354676365852356, -1.7350094318389893, -0.324643075466156, 0.22538529336452484, 0.6949381828308105, -1.353224754333496, 1.7768988609313965, 0.9033784866333008, 2.062497615814209, 0.9594843983650208, -0.4511496424674988, 1.5336472988128662, 0.03194117546081543, 1.8902013301849365, -0.4876079261302948, 0.6098837852478027, -0.43267345428466797, -1.102311611175537, 0.8554531335830688, -0.2887655198574066, -1.9970715045928955, -0.8012484312057495, -0.8494881391525269, -0.14663003385066986, -0.7619706988334656, 0.9281796216964722, -0.31167641282081604, -1.5509533882141113, 0.19786155223846436, -0.7092428803443909, 0.02716352418065071, -1.2282228469848633, 0.13936936855316162, 0.651091992855072, -0.6888821125030518, 0.0740366280078888, -0.19999133050441742, -1.3391478061676025, -0.4930115342140198, 0.3091401159763336, 1.9523181915283203, -0.7012122273445129, 0.9624255895614624, 1.0754199028015137, -0.6794649958610535, 0.14529035985469818, 0.328689843416214, -0.33727362751960754, 0.7726941108703613, -1.208702564239502, -0.38269293308258057, 1.0776350498199463, -0.04745514318346977, -0.5583831071853638, 1.4944581985473633, 0.8078822493553162, -1.0622241497039795, -0.2787948250770569, -0.1408083289861679, -0.8132069110870361, -0.032916173338890076, -1.5833837985992432, -0.06800748407840729, 0.32760000228881836, -1.437854290008545, -0.43708252906799316, -0.26154905557632446, 1.1959543228149414, -0.14346742630004883, 1.4330010414123535, -0.3074665367603302, -0.2247018963098526, -0.3905750811100006, -0.45016953349113464, 0.09773241728544235, -0.32931894063949585, -0.5874088406562805, 0.23618637025356293, -0.847489058971405, 0.26867958903312683, 1.5039350986480713, 0.27552685141563416, 0.09165970236063004, 0.45360052585601807, 1.1524734497070312, 0.36595606803894043, 0.06776563078165054, -0.8602113127708435, -1.509901523590088, 2.0463716983795166, -1.5893404483795166, 1.9567499160766602, 0.7536913156509399, -0.01516249030828476, -1.836583137512207, -1.8751928806304932, 1.3658771514892578, 1.0911085605621338, 2.451479911804199, 0.5792697072029114, 0.43776679039001465, -0.7700514793395996, -0.7366793751716614, 0.3618931472301483, -0.935401976108551, -0.6850456595420837, 0.26834145188331604, 2.3727428913116455, 1.706296682357788, -0.5786855816841125, -0.2310444563627243, -0.8549292087554932, 1.3564746379852295, -0.0768507793545723, 0.20616069436073303, 2.04994797706604, -0.19971463084220886, -1.118680477142334, 1.262486219406128, -2.3488731384277344, 0.1674761027097702, 2.003664016723633, 0.2983110547065735, 0.12134553492069244, -1.4230964183807373, -0.6571397185325623, -0.3851408362388611, -0.4624551832675934, -1.2292499542236328, 0.6096989512443542, -0.29440250992774963, -0.9131664633750916, -1.474195957183838, 0.03905776888132095, -1.1584880352020264, -1.7335197925567627, 0.3595767319202423, 1.8945825099945068, 2.1348023414611816, -0.7562553882598877, 1.441354513168335, -0.33584165573120117, 0.04444023594260216, 1.1793906688690186, 1.292923927307129, 3.0534279346466064, 1.8321499824523926, -1.2424020767211914, 0.7614278197288513, -0.14163008332252502, -0.45329415798187256, 1.082557201385498, -1.0869264602661133, 1.1351773738861084, -0.19746308028697968, -1.205437421798706, -1.1502463817596436, 1.0558764934539795, 0.3917936086654663, 0.04795142263174057, -0.5126159191131592, 1.311513900756836, 0.07889058440923691, 1.3403947353363037, 0.5844317674636841, -0.2719807028770447, 0.56777024269104, -0.36403506994247437, -0.5597935318946838, 1.6431701183319092, 0.1781744658946991, -1.4560937881469727, -2.516721487045288, -0.2649511694908142, -0.8839423656463623, 0.035654496401548386, -0.6581291556358337, -1.1138861179351807, 1.6405889987945557, 0.3793220520019531, -1.307363748550415, -0.2525630593299866, -0.349832683801651, -0.5881023406982422, 2.626633644104004, -1.416243076324463, -0.10334441810846329, -0.9074795246124268, -0.5116516947746277, 1.6082003116607666, -1.1500682830810547, -0.24226710200309753, -1.1136605739593506, -0.567676842212677, -1.350315809249878, -0.5899694561958313, 0.0623999685049057, -0.895219087600708, 0.7958406805992126, 0.17607825994491577, -1.0855822563171387, -0.26272884011268616, -0.9276371598243713, 0.9914315342903137, -0.0545816607773304, 0.25904616713523865, 1.8715956211090088, 0.40830036997795105, -0.3789440393447876, 0.7166363596916199, 1.1759214401245117, 0.6499977111816406, -0.6554539799690247, 0.06486876308917999, -0.6491432785987854, 0.23234140872955322, -1.408212661743164, 0.24928516149520874, -2.823524236679077, 0.7073701024055481, -0.09373742341995239, 0.0020622191950678825, -0.044905729591846466, -1.2705597877502441, 1.1748764514923096, 2.6833372116088867, -1.142648458480835, 0.5339173674583435, 0.35736438632011414, 1.1827950477600098, -1.4712300300598145, 0.26699885725975037, -0.39934059977531433, 2.0325000286102295, 0.06230513006448746, 1.170525312423706, -0.5601316094398499, -2.177494525909424, 0.6072453260421753, -1.2915232181549072, -1.093179702758789, 0.8512124419212341, -0.8744171261787415, 0.2232491374015808, -1.4630002975463867, -0.27639174461364746, -0.9837376475334167, -1.236189365386963, 0.6797045469284058, 0.11581212282180786, 0.5405554175376892, -0.543260931968689, 0.37450990080833435, -2.2846362590789795, -1.446869134902954, -0.17385882139205933, -1.0147674083709717, 0.5676365494728088, -0.3260263502597809, 0.7176563739776611, -0.09841689467430115, 0.06029035151004791, 0.4273790419101715, 1.3145558834075928, 3.360629081726074, 0.1646161824464798, 0.26494458317756653, -0.12166551500558853, -1.0329430103302002, 1.358548879623413, 0.9996828436851501, -0.10063111037015915, -0.5722072124481201, -1.0157599449157715, 1.2015328407287598, 2.03369140625, 1.0931243896484375, -0.01000891625881195, -0.8446508049964905, -0.8463783264160156, 0.1345713883638382, 0.2113482654094696, 0.6129223704338074, 0.956882894039154, -0.055721789598464966, 0.11378221213817596, 1.472623348236084, 1.1372480392456055, -0.436359703540802, 0.44929632544517517, -0.9114785194396973, -0.4093230366706848, 0.47958919405937195, 0.18357770144939423, 0.04459501802921295, 0.4212489128112793, -1.0924553871154785, -0.30797532200813293, -0.30899161100387573, -0.8948781490325928, -0.6658729910850525, -0.43526262044906616, -0.4302772581577301, 1.5971639156341553, 0.08876854926347733, -0.44572558999061584, 0.10277868807315826, -0.6755667328834534, -0.15152379870414734, -1.1707265377044678, 0.22035850584506989, -0.2043609917163849, -0.022755460813641548, -0.08342966437339783, 1.837325096130371, -0.9350897073745728, -2.0669143199920654, 0.16520848870277405, 0.2813240587711334, -0.3923700451850891, 0.24408817291259766, 1.70039963722229, 0.6338827013969421, 1.3505780696868896, 1.2984814643859863, 0.8921394348144531, -0.6856156587600708, -1.257873773574829, 0.6068567633628845, 0.9351285099983215, -1.3557560443878174, 0.7877652645111084, -0.12785778939723969, -0.4687468111515045, 0.644012451171875, 1.34373140335083, 0.3852587938308716, -2.0921084880828857, 0.8778418898582458, -0.8541280627250671, 0.7719696164131165, 0.7038345336914062, 0.7436479926109314, 0.20975252985954285, 0.7769941687583923, -1.2338426113128662, -1.086381435394287, -0.8179945945739746, -0.6450372338294983, 1.8991057872772217, -0.1962120682001114, 0.40249213576316833, -0.22068285942077637, -1.1977481842041016, -0.10834809392690659, 0.7151972651481628, 0.3748984634876251, -0.43124130368232727, 0.7780368328094482, -0.5401567220687866, -1.1127324104309082, -1.2308645248413086, -0.5540781021118164, -1.0293517112731934, -0.9000663757324219, 0.941565990447998, 0.7121763825416565, 0.42758920788764954, 1.8834295272827148, 0.6826808452606201, 0.24039563536643982, -2.697089433670044, 0.9418428540229797, 0.30148816108703613, -0.04596703499555588, 0.9811089038848877, 0.33273079991340637, 1.1527118682861328, -0.05802620202302933, 0.5842932462692261, -2.4085745811462402, 2.2982699871063232, -0.23040863871574402, 0.7362977862358093, -0.043138958513736725, -0.23207098245620728, 1.1067941188812256, 0.5272631645202637, 0.5380838513374329, -1.0799355506896973, 0.6497417092323303, -0.7008094787597656, 1.0924787521362305, 0.850045382976532, -0.8871825933456421, 0.0878080502152443, 1.2750964164733887, 0.4982439875602722, -0.4196550250053406, -0.9472859501838684, -0.8253911137580872, 0.9836701154708862, 1.6957314014434814, -0.08405783027410507, 0.08703908324241638, 0.9426915049552917, 0.5794355869293213, -1.3065645694732666, 0.009720170870423317, -0.6990299820899963, -0.8183271884918213, 1.7513439655303955, 2.132476806640625, -0.09379429370164871, -0.09737097471952438, -0.7643058896064758, -1.2322075366973877, 0.7723854184150696, -0.06378144770860672, 0.1612231433391571, 0.5317140221595764, -0.712695300579071, 1.242621898651123, 0.6372846961021423, 0.9686493277549744, 0.08572104573249817, 0.3713941276073456, 0.2943043112754822, -0.3413039445877075, -1.1585943698883057, -0.3764116168022156, -1.068821907043457, -2.4039623737335205, 0.5434005856513977, -0.14232264459133148, -1.4884283542633057, 0.04628803953528404, -0.9921693205833435, 0.8899607062339783, -0.5686308145523071, -1.0231549739837646, -1.4575176239013672, 0.3554272949695587, -0.23128998279571533, 1.009629487991333, -1.644036054611206, -0.08741676062345505, 1.2032442092895508, 0.893016517162323, -0.5762561559677124, 0.9623696804046631, 0.3390819728374481, 1.0059046745300293, 0.8208916783332825, -0.3177860975265503, 0.5695604085922241, 0.1117515116930008, -1.2789876461029053, 0.40760537981987, 1.1903886795043945, 0.14040744304656982, 1.436255693435669, -0.4422539472579956, 0.07354798167943954, 0.35420385003089905, -0.46131688356399536, -0.4501640200614929, -0.5442419052124023, 0.5951755046844482, 0.15469776093959808, -1.0739636421203613, -0.1181337758898735, -0.04441928490996361, -0.19752788543701172, 0.2941344976425171, -1.500652551651001, -0.29525208473205566, -0.3711174428462982, -0.4850594997406006, -1.2491703033447266, 0.05569808930158615, 1.3067777156829834, -0.8017001152038574, -0.23832285404205322, 0.4000936448574066, 0.3669297397136688, 0.5967146754264832, 0.639492392539978, -0.6759822964668274, -0.3874078691005707, -0.30812960863113403, -0.34758180379867554, 0.23947565257549286, 1.2277140617370605, -0.10522263497114182, -1.0755610466003418, 0.7324354648590088, -0.4545269310474396, 0.09479999542236328, 1.9358851909637451, -0.04677160829305649, -0.7268698215484619, 0.31264176964759827, -0.6923533082008362, 1.9189105033874512, 1.7735915184020996, 1.272773027420044, -0.20546264946460724, -0.8926507234573364, 0.5763269066810608, -0.31978654861450195, -0.22494478523731232, 0.9336066842079163, 0.4297490119934082, -0.19055216014385223, -1.4224355220794678, 0.486291766166687, 1.363673448562622, -0.893842875957489, -0.7976875305175781, 0.13479283452033997, -0.8358256220817566, 1.1265802383422852, 0.7129209637641907, 0.32614389061927795, 0.3083014488220215, 1.5180299282073975, 0.7791673541069031, -0.5000765323638916, 0.5970894694328308, 0.4158252775669098, -0.12339584529399872, -2.1541597843170166, -1.1511454582214355, 0.3774460256099701, -0.29745033383369446, -1.608638048171997, 1.3731272220611572, -1.0900952816009521, -0.9374119639396667, 0.5718950033187866, 0.03636741638183594, 1.294400691986084, 0.3412879705429077, 1.6510262489318848, 2.0523462295532227, 0.8939493894577026, 0.27901414036750793, 1.3092777729034424, -0.0659836158156395, -0.44496071338653564, 1.8562805652618408, -0.5436741709709167, 0.4899655878543854, 1.0222673416137695, -0.3963838219642639, -1.0214312076568604, -0.7901312708854675, -1.2594609260559082, -0.6962406635284424, 1.1476776599884033, 0.0791839137673378, -1.2248289585113525, 0.24992510676383972, 1.6803746223449707, 0.10206639766693115, -0.2503906488418579, 0.734736442565918, 0.42630645632743835, -0.791186511516571, -0.12093118578195572, -0.9024736881256104, 0.5244492292404175, -0.1165451928973198, -0.24696758389472961, 0.2044251710176468, 0.5142940878868103, 1.2933149337768555, -0.004106536041945219, 0.07968569546937943, 1.2674732208251953, -1.3896150588989258, 1.4912166595458984, -0.6348900198936462, 0.3363434970378876, -2.429456949234009, 1.3182454109191895, -0.7572859525680542, 1.8073227405548096, -2.60520339012146, 0.3974285125732422, -0.554563045501709, -0.5101087093353271, 0.21334029734134674, -0.2650969922542572, 0.18495149910449982, -0.1411752551794052, -0.986203134059906, -0.059530794620513916, -0.7845174670219421, 0.5819364786148071, 1.0677433013916016, 1.4098520278930664, -0.9571059346199036, -0.2349909245967865, -1.7473530769348145, -0.10524901747703552, -0.6533030867576599, 0.3108111619949341, -1.9339635372161865, -0.10550384223461151, -2.0085337162017822, -2.2727315425872803, -1.4903881549835205, -0.8796289563179016, 1.0937819480895996, 0.14588558673858643, -1.0359282493591309, 1.110337495803833, -0.41871291399002075, -1.7237944602966309, 1.132631540298462, -2.1923458576202393 ]
https://github.com/huggingface/datasets/issues/5190
`path` is `None` when downloading a custom audio dataset from the Hub
Hi! Yes, this is expected behavior - we do this as a security measure to not leak local paths (this info would be useless on other users' machines anyways) and only push audio bytes.
### Describe the bug I've created an [audio dataset](https://huggingface.co/datasets/lewtun/audio-test-push) using the `audiofolder` feature desribed in the [docs](https://huggingface.co/docs/datasets/audio_dataset#audiofolder) and then pushed it to the Hub. Locally, I can see the `audio.path` feature is of the expected form `path/to/data_dir`, but when I download the dataset from the Hub, I see `audio.path` is `None` Here's an example: ```python from datasets import load_dataset ds = load_dataset("lewtun/audio-test-push") ds["train"][0] # { # "audio": { # "path": None, <-- Is this expected? # "array": array( # [ # 3.97140226e-07, # 7.30310290e-07, # 7.56406735e-07, # ..., # -1.19636677e-01, # -1.16811886e-01, # -1.12441722e-01, # ] # ), # "sampling_rate": 44100, # }, # "song_id": 0, # "genre_id": 0, # "genre": "Electronic", # } ``` Is this expected behaviour? If yes, feel free to close this issue as it's not a true bug then :) ### Steps to reproduce the bug 1. Create an audio dataset with the `audiofolder` feature 2. Push the dataset to the Hub with `push_to_hub()` 3. Download the Hub dataset and inspect the `audio.path` feature ### Expected behavior `audio.path` points to the file associated with the audio data ### Environment info - `datasets` version: 2.6.2.dev0 - Platform: macOS-10.16-x86_64-i386-64bit - Python version: 3.8.13 - PyArrow version: 9.0.0 - Pandas version: 1.5.1
444
34
`path` is `None` when downloading a custom audio dataset from the Hub ### Describe the bug I've created an [audio dataset](https://huggingface.co/datasets/lewtun/audio-test-push) using the `audiofolder` feature desribed in the [docs](https://huggingface.co/docs/datasets/audio_dataset#audiofolder) and then pushed it to the Hub. Locally, I can see the `audio.path` feature is of the expected form `path/to/data_dir`, but when I download the dataset from the Hub, I see `audio.path` is `None` Here's an example: ```python from datasets import load_dataset ds = load_dataset("lewtun/audio-test-push") ds["train"][0] # { # "audio": { # "path": None, <-- Is this expected? # "array": array( # [ # 3.97140226e-07, # 7.30310290e-07, # 7.56406735e-07, # ..., # -1.19636677e-01, # -1.16811886e-01, # -1.12441722e-01, # ] # ), # "sampling_rate": 44100, # }, # "song_id": 0, # "genre_id": 0, # "genre": "Electronic", # } ``` Is this expected behaviour? If yes, feel free to close this issue as it's not a true bug then :) ### Steps to reproduce the bug 1. Create an audio dataset with the `audiofolder` feature 2. Push the dataset to the Hub with `push_to_hub()` 3. Download the Hub dataset and inspect the `audio.path` feature ### Expected behavior `audio.path` points to the file associated with the audio data ### Environment info - `datasets` version: 2.6.2.dev0 - Platform: macOS-10.16-x86_64-i386-64bit - Python version: 3.8.13 - PyArrow version: 9.0.0 - Pandas version: 1.5.1 Hi! Yes, this is expected behavior - we do this as a security measure to not leak local paths (this info would be useless on other users' machines anyways) and only push audio bytes.
[ -1.0838909149169922, -0.7923132181167603, -0.7978888750076294, 1.4520854949951172, -0.15892907977104187, -1.3243805170059204, 0.17290517687797546, -1.0513060092926025, 1.6806758642196655, -0.7659683227539062, 0.3273233473300934, -1.7522423267364502, -0.019192906096577644, -0.655708909034729, -0.7460217475891113, -0.8547263145446777, -0.4274156093597412, -0.647323489189148, 0.9771115779876709, 2.5131633281707764, 1.2443660497665405, -1.268797516822815, 2.6519453525543213, 0.7133916616439819, -0.21825993061065674, -0.899543046951294, 0.4454664885997772, -0.052747637033462524, -1.3631157875061035, -0.422245055437088, -0.9501769542694092, -0.11069847643375397, -0.551210880279541, -0.56471848487854, 0.005056669935584068, 0.48844313621520996, -0.36776793003082275, -0.4790004789829254, -0.5374540090560913, -0.8831865787506104, 0.394776314496994, -0.4692174196243286, 1.0053046941757202, -0.3494343161582947, 1.7849971055984497, -0.6209174394607544, 0.5048562288284302, 0.7097868919372559, 1.2691646814346313, 0.250029057264328, 0.06923086196184158, 0.36109495162963867, 0.48288214206695557, -0.04843242093920708, 0.4869619309902191, 1.1743075847625732, 0.6281455755233765, 0.5542106628417969, 0.7434549331665039, -2.2375264167785645, 1.2078560590744019, -0.9019455909729004, 0.2499140501022339, 1.4422200918197632, -0.9260920286178589, 0.3099493086338043, -1.7867990732192993, -0.03532388061285019, 0.561686635017395, -2.2315688133239746, 0.2695465385913849, -1.303658127784729, -0.49661916494369507, 1.0475412607192993, 0.4164372980594635, -1.2406319379806519, 0.008939385414123535, -0.3625173270702362, 0.930182695388794, 0.3914720416069031, 1.1407550573349, -1.6553130149841309, -0.10865481197834015, -0.3212168216705322, 0.04690801352262497, -1.21732759475708, -1.511386752128601, 0.5498126745223999, 0.6904876232147217, 0.6178629398345947, -0.15403781831264496, 0.9623184204101562, -1.0422577857971191, 0.7374465465545654, -0.9826972484588623, -1.9249937534332275, -1.431599497795105, -2.295771360397339, -2.3103837966918945, 0.7512651681900024, -0.455172061920166, -0.4763692617416382, 2.0734217166900635, -1.0266268253326416, -1.700252890586853, 1.1423543691635132, 0.29532334208488464, -0.03629104048013687, 2.377424955368042, 0.30267080664634705, -0.6989496946334839, 0.548115611076355, -0.7484210729598999, 0.7030012607574463, -0.4625226855278015, 1.2264970541000366, 0.35506004095077515, -1.0826491117477417, 1.5989981889724731, -0.4466305375099182, 0.587969183921814, -0.7457871437072754, -0.36527135968208313, -0.6968042850494385, 0.29990246891975403, 1.8172590732574463, -0.30480948090553284, 1.5495606660842896, -0.23710136115550995, -1.5262486934661865, -1.5832680463790894, 0.811967134475708, 0.45675069093704224, -0.7253972291946411, 0.11660157144069672, -0.3243621587753296, 0.17060630023479462, -0.1045549213886261, 1.1397851705551147, 1.2668428421020508, 0.7524592876434326, -0.30833330750465393, -0.8274641036987305, 0.24794164299964905, -0.015293282456696033, -0.8098163604736328, -1.6158440113067627, -0.2991618812084198, 0.14798174798488617, 0.5879402160644531, -1.204363465309143, 1.831486701965332, 0.8394848108291626, 1.9094477891921997, 1.0477957725524902, -0.37505966424942017, 1.4519728422164917, 0.15627190470695496, 1.8822168111801147, -0.4790990352630615, 0.6766287088394165, -0.441560834646225, -1.1954848766326904, 0.8521808385848999, -0.3825472593307495, -2.01928448677063, -0.6841189861297607, -0.8544366359710693, -0.14899888634681702, -0.7568216323852539, 1.0137195587158203, -0.2148219496011734, -1.324027419090271, 0.2036956399679184, -0.736342191696167, 0.059094011783599854, -1.3310109376907349, 0.29091915488243103, 0.7331531047821045, -0.6432185173034668, 0.10838859528303146, -0.22347985208034515, -1.3153284788131714, -0.41125062108039856, 0.31097841262817383, 1.8716797828674316, -0.7699426412582397, 0.9569276571273804, 0.9924881458282471, -0.6548713445663452, -0.05646468698978424, 0.36510077118873596, -0.3471059203147888, 0.882636547088623, -1.011763095855713, -0.43410030007362366, 1.2125917673110962, -0.2718195915222168, -0.6220211982727051, 1.4054564237594604, 0.6600744724273682, -1.0167280435562134, -0.19452935457229614, -0.130171000957489, -0.8607542514801025, 0.042283713817596436, -1.6278941631317139, -0.07842358201742172, 0.42365044355392456, -1.5368658304214478, -0.4677547514438629, -0.1873026341199875, 1.2809302806854248, -0.13740666210651398, 1.3949917554855347, -0.2629704177379608, -0.19152326881885529, -0.4288281798362732, -0.4240415692329407, 0.06500820070505142, -0.24060076475143433, -0.655716061592102, 0.2250792682170868, -0.6433310508728027, 0.3353821337223053, 1.3560477495193481, 0.23591075837612152, 0.059593960642814636, 0.544579029083252, 1.097283959388733, 0.3966794013977051, -0.10586494952440262, -0.9258420467376709, -1.5664961338043213, 2.005312204360962, -1.4516024589538574, 1.949407696723938, 0.7673525810241699, -0.05613601952791214, -1.7456539869308472, -1.9091932773590088, 1.4197208881378174, 1.0556952953338623, 2.366462469100952, 0.6165976524353027, 0.5204367637634277, -0.7699159383773804, -0.6514277458190918, 0.31690075993537903, -0.9497988224029541, -0.7285984754562378, 0.16049277782440186, 2.44059681892395, 1.7062034606933594, -0.4730730950832367, -0.21251140534877777, -1.0565214157104492, 1.358662486076355, -0.15056660771369934, 0.20665138959884644, 2.0338473320007324, -0.31479325890541077, -0.9794853925704956, 1.2572325468063354, -2.289154529571533, 0.13271987438201904, 1.9840383529663086, 0.1433003842830658, 0.029353618621826172, -1.3250861167907715, -0.7032953500747681, -0.2553788125514984, -0.4520174562931061, -1.2136693000793457, 0.5559539794921875, -0.2016640305519104, -0.7580991983413696, -1.3832060098648071, 0.13192953169345856, -1.0817515850067139, -1.6528681516647339, 0.11572840809822083, 1.93362295627594, 1.9731324911117554, -0.7932618856430054, 1.546485185623169, -0.2687773108482361, 0.1479681432247162, 1.2400211095809937, 1.2821180820465088, 3.221848249435425, 1.9751992225646973, -1.3104634284973145, 0.7019379138946533, -0.12448874861001968, -0.4116474986076355, 1.1956138610839844, -1.1376221179962158, 1.2550811767578125, -0.11352676898241043, -1.3010005950927734, -1.226173758506775, 0.9123408794403076, 0.4605869650840759, 0.004802165552973747, -0.51495361328125, 1.1949876546859741, 0.08689109236001968, 1.3350337743759155, 0.6494019031524658, -0.3274850845336914, 0.6393253803253174, -0.33861809968948364, -0.4451969563961029, 1.5754098892211914, 0.20691588521003723, -1.4094358682632446, -2.372403621673584, -0.2218935787677765, -0.9370404481887817, -0.0263283122330904, -0.6739435195922852, -1.0119024515151978, 1.6440420150756836, 0.42901521921157837, -1.185853123664856, -0.3323037922382355, -0.33896520733833313, -0.5537418127059937, 2.7894277572631836, -1.4465962648391724, -0.22823937237262726, -1.031014323234558, -0.6368945837020874, 1.7244335412979126, -1.1705931425094604, -0.2052065134048462, -1.093589186668396, -0.538833498954773, -1.3441777229309082, -0.5750671625137329, 0.06839567422866821, -0.928168535232544, 0.9528611898422241, 0.1626206338405609, -1.2852848768234253, -0.25091442465782166, -0.9791650772094727, 0.8186967372894287, -0.17803677916526794, 0.15554334223270416, 1.9528578519821167, 0.440305233001709, -0.37586385011672974, 0.7362856864929199, 1.2152107954025269, 0.6981616020202637, -0.6450434923171997, 0.2252359688282013, -0.6662498712539673, 0.29684120416641235, -1.2937438488006592, 0.21332646906375885, -2.7524964809417725, 0.5449976921081543, -0.10435987263917923, -0.09579306095838547, 0.016234735026955605, -1.2386835813522339, 1.0333281755447388, 2.457335948944092, -1.1964244842529297, 0.5148788690567017, 0.2683311700820923, 1.2778377532958984, -1.6919941902160645, 0.21689535677433014, -0.5035051107406616, 2.0958003997802734, 0.08590380847454071, 1.1691005229949951, -0.41241684556007385, -2.2129406929016113, 0.5972095727920532, -1.3175736665725708, -1.1104233264923096, 0.8512492179870605, -0.8042078018188477, 0.13899777829647064, -1.3748905658721924, -0.22676341235637665, -0.7983447313308716, -1.2594374418258667, 0.6518430709838867, 0.019681081175804138, 0.5559933185577393, -0.6072249412536621, 0.28590652346611023, -2.243788003921509, -1.388399600982666, -0.28521615266799927, -0.895199179649353, 0.3871540129184723, -0.3558864891529083, 0.7887750864028931, -0.27334627509117126, -0.022961318492889404, 0.3434928059577942, 1.4577456712722778, 3.3928167819976807, 0.20473751425743103, 0.3487957715988159, -0.1933962106704712, -0.9954519271850586, 1.4243825674057007, 0.926719069480896, -0.0954049676656723, -0.5638301372528076, -1.0719431638717651, 1.236093282699585, 1.950937271118164, 1.0890201330184937, 0.0986420065164566, -0.8411794900894165, -0.7403446435928345, -0.054083507508039474, 0.17976737022399902, 0.4239780306816101, 0.908843994140625, 0.10038631409406662, 0.08081889152526855, 1.4951108694076538, 1.0927574634552002, -0.3185567259788513, 0.41222840547561646, -0.8194313049316406, -0.4940817058086395, 0.5088478326797485, 0.34050437808036804, 0.021193677559494972, 0.3186117112636566, -1.0564708709716797, -0.28449809551239014, -0.41607600450515747, -0.8935126066207886, -0.7062187194824219, -0.38941532373428345, -0.3562542498111725, 1.669360637664795, 0.012374058365821838, -0.5212632417678833, -0.025169964879751205, -0.7290444374084473, -0.09402252733707428, -1.0310158729553223, 0.25872889161109924, -0.17727258801460266, -0.07045549154281616, -0.07815299183130264, 1.712849736213684, -0.9721356630325317, -2.110440731048584, 0.184557244181633, 0.20185503363609314, -0.33250874280929565, 0.14823618531227112, 1.63529372215271, 0.606393575668335, 1.4313257932662964, 1.4860576391220093, 1.0143613815307617, -0.7301468849182129, -1.3938862085342407, 0.6555678844451904, 1.033872365951538, -1.3682860136032104, 0.7938982248306274, -0.05266989767551422, -0.5576744079589844, 0.5473498106002808, 1.2829618453979492, 0.4181842803955078, -1.957384705543518, 0.8088122606277466, -0.9470325708389282, 0.7853816747665405, 0.7383203506469727, 0.7558606863021851, 0.20112861692905426, 0.6704667806625366, -1.2191810607910156, -1.1564637422561646, -0.6443883180618286, -0.6547505855560303, 1.9168274402618408, -0.28627344965934753, 0.5993475914001465, -0.20403029024600983, -1.333086371421814, 0.0004529878497123718, 0.6880064010620117, 0.39333873987197876, -0.48737362027168274, 0.6778388023376465, -0.5867128372192383, -1.048397183418274, -1.381331205368042, -0.44494402408599854, -1.1044787168502808, -0.9125281572341919, 1.0263056755065918, 0.7885942459106445, 0.32363390922546387, 1.8337233066558838, 0.7717170715332031, 0.28981828689575195, -2.6555020809173584, 0.887566328048706, 0.3495715856552124, -0.07073052227497101, 0.8031742572784424, 0.3802279829978943, 1.1164582967758179, -0.09652391821146011, 0.601043701171875, -2.4534213542938232, 2.3148858547210693, -0.29627442359924316, 0.6016590595245361, -0.013968393206596375, -0.0940212532877922, 1.0423877239227295, 0.5508782863616943, 0.5305187702178955, -0.9930105209350586, 0.6712803840637207, -0.6077374219894409, 1.226951003074646, 0.8913321495056152, -0.8695800304412842, -0.002697370480746031, 1.3824527263641357, 0.5780951976776123, -0.5262362957000732, -0.956741213798523, -0.8968795537948608, 0.925133466720581, 1.74831223487854, -0.03241758793592453, -0.0024308115243911743, 0.9783570766448975, 0.596632719039917, -1.2495108842849731, 0.13141994178295135, -0.6610927581787109, -0.7295452356338501, 1.679118037223816, 2.07698130607605, -0.11568275094032288, -0.2415369302034378, -0.7738872766494751, -1.2826186418533325, 0.8165209293365479, -0.008689465001225471, 0.04513627663254738, 0.8225398063659668, -0.6170903444290161, 1.0713292360305786, 0.7959282398223877, 0.9103565216064453, 0.27748462557792664, 0.19130349159240723, 0.3424215316772461, -0.3012845516204834, -1.1665905714035034, -0.21638645231723785, -1.0492366552352905, -2.476733684539795, 0.5139205455780029, -0.2195269763469696, -1.4371087551116943, 0.001308755949139595, -1.0589656829833984, 0.9290616512298584, -0.5581411123275757, -1.1295171976089478, -1.5097956657409668, 0.2231551855802536, -0.0419904887676239, 0.8649650812149048, -1.5488604307174683, -0.17032618820667267, 1.1859076023101807, 0.8824466466903687, -0.7628427743911743, 0.9025974273681641, 0.20198023319244385, 1.0434138774871826, 0.8632478713989258, -0.35672444105148315, 0.4654726982116699, -0.0070306966081261635, -1.3800643682479858, 0.4935436546802521, 1.2053359746932983, 0.1400768756866455, 1.516770362854004, -0.5425446033477783, -0.04117511212825775, 0.3888092637062073, -0.31033506989479065, -0.39574968814849854, -0.6306184530258179, 0.5926018953323364, 0.0977751836180687, -0.8708007335662842, -0.04392853379249573, -0.021223856136202812, -0.2542552351951599, 0.16310445964336395, -1.4208223819732666, -0.02784695103764534, -0.3386019766330719, -0.6253829002380371, -1.1830995082855225, -0.06005438044667244, 1.2998816967010498, -0.7521184682846069, -0.22388403117656708, 0.603062629699707, 0.18672563135623932, 0.45392176508903503, 0.5390913486480713, -0.6602104902267456, -0.31052520871162415, -0.2313704937696457, -0.3732385039329529, 0.3279377222061157, 1.4174153804779053, -0.07405304908752441, -1.0316065549850464, 0.6392084360122681, -0.3859022259712219, 0.11899720132350922, 1.9624980688095093, 0.08792299777269363, -0.8440622091293335, 0.24378660321235657, -0.677435040473938, 1.9344968795776367, 1.7002687454223633, 1.3279118537902832, -0.06853395700454712, -0.9683592319488525, 0.6203885078430176, -0.33918288350105286, -0.4458980858325958, 0.8886746168136597, 0.2867219150066376, -0.20686869323253632, -1.4309805631637573, 0.6883659362792969, 1.277017593383789, -0.8875616788864136, -0.8667404651641846, 0.2037212997674942, -0.8961824178695679, 1.1369414329528809, 0.738943338394165, 0.39223524928092957, 0.2272881120443344, 1.6541670560836792, 0.8478083610534668, -0.4127596914768219, 0.5450839996337891, 0.47592785954475403, -0.11192496120929718, -2.086184024810791, -1.1482959985733032, 0.2980548143386841, -0.4529893398284912, -1.6179568767547607, 1.4340670108795166, -1.2241191864013672, -0.939664363861084, 0.5890477895736694, 0.0945134162902832, 1.4394062757492065, 0.37713125348091125, 1.5916662216186523, 2.0457820892333984, 0.9104021787643433, 0.445548415184021, 1.2418805360794067, -0.17070743441581726, -0.39883795380592346, 1.7498725652694702, -0.5009669065475464, 0.573932409286499, 1.073038101196289, -0.3666933476924896, -1.117653489112854, -0.7781388759613037, -1.265805959701538, -0.7041966915130615, 1.1333028078079224, 0.10425075143575668, -1.0538110733032227, 0.33055579662323, 1.5193617343902588, 0.046772755682468414, -0.37025704979896545, 0.6795837879180908, 0.4488401412963867, -0.8571758270263672, -0.07448116689920425, -0.8092857599258423, 0.5737209320068359, -0.08758418262004852, -0.28782036900520325, 0.34362736344337463, 0.5184158086776733, 1.4423216581344604, 0.001514894887804985, 0.13003244996070862, 1.1943645477294922, -1.3799110651016235, 1.491037130355835, -0.7265678644180298, 0.18147136270999908, -2.330670118331909, 1.4172788858413696, -0.8286073207855225, 1.8560515642166138, -2.646996259689331, 0.3694557845592499, -0.44405925273895264, -0.4959031045436859, 0.2509597837924957, -0.3073030710220337, 0.1359502226114273, -0.17308735847473145, -1.2255942821502686, -0.07991934567689896, -0.7265523672103882, 0.5633764266967773, 1.1695281267166138, 1.4316843748092651, -1.0941696166992188, -0.33296629786491394, -1.722663402557373, -0.10566060245037079, -0.6735094785690308, 0.334126353263855, -1.8854142427444458, -0.1542385071516037, -1.9195500612258911, -2.4081647396087646, -1.3605968952178955, -0.8605265617370605, 1.1198395490646362, 0.14419394731521606, -0.936623215675354, 1.237287163734436, -0.36513751745224, -1.8348114490509033, 1.1044366359710693, -2.2072322368621826 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
I have to admit I'm not a fan of this idea, as this would result in a non-consistent behavior between tabular and non-tabular datasets, which is confusing if done without the context you provided. Instead, we could consider returning a `Dataset` object rather than `DatasetDict` if there is only one split in the generated dataset. But then again, I think this lib is a bit too old to make such changes. @lhoestq @albertvillanova WDYT?
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
74
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! I have to admit I'm not a fan of this idea, as this would result in a non-consistent behavior between tabular and non-tabular datasets, which is confusing if done without the context you provided. Instead, we could consider returning a `Dataset` object rather than `DatasetDict` if there is only one split in the generated dataset. But then again, I think this lib is a bit too old to make such changes. @lhoestq @albertvillanova WDYT?
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
We can brainstorm here to see how we could make it happen ? And then depending on the options we see if it's a change we can do. I'm starting with a first reasoning Currently not passing `split=` in `load_dataset` means "return a dict with each split". Now what would happen if a dataset has no split ? Ideally it should return one Dataset. And passing `split=` would have no sense. So depending on the dataset content, not passing `split=` should return a dict or a Dataset. In particular, those two cases should work: ```python # case 1: dataset without split ds = load_dataset("dataset_without_split") ds[0], ds["column_name"], list(ds) # we want this # case 2: dataset with splits ds = load_dataset("dataset_with_splits") ds["train"] # this works and can't be changed ds = load_dataset("dataset_with_splits", split="train") ds[0], ds["column_name"], list(ds) # this works and can't be changed ``` I can see several ideas: 1. allowing `load_dataset` to return a different object based on the dataset content - either a Dataset or a DatasetDict - we can update `get_dataset_split_names` to return None or a list if users want to know in advance what object will be returned. They can also use `isinstance` _a posteriori_ - but in this case we expect users to be careful when loading datasets and always to extra steps to check if they got a Dataset or DatasetDict 2. merge Dataset and DatasetDict objects - they already share many functions: map, filter, push_to_hub etc. - we can define `ds[0]` to be the first item of the first split, and consider that the uses accesses rows from the full table of all the splits concatenated - however there is a collision when doing `ds["column_name"]` or `ds["train"]` that we need to address: the first returns a list, while the other returns a Dataset. What are your opinions on those two ideas ? Do you have other ideas in mind ?
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
316
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! We can brainstorm here to see how we could make it happen ? And then depending on the options we see if it's a change we can do. I'm starting with a first reasoning Currently not passing `split=` in `load_dataset` means "return a dict with each split". Now what would happen if a dataset has no split ? Ideally it should return one Dataset. And passing `split=` would have no sense. So depending on the dataset content, not passing `split=` should return a dict or a Dataset. In particular, those two cases should work: ```python # case 1: dataset without split ds = load_dataset("dataset_without_split") ds[0], ds["column_name"], list(ds) # we want this # case 2: dataset with splits ds = load_dataset("dataset_with_splits") ds["train"] # this works and can't be changed ds = load_dataset("dataset_with_splits", split="train") ds[0], ds["column_name"], list(ds) # this works and can't be changed ``` I can see several ideas: 1. allowing `load_dataset` to return a different object based on the dataset content - either a Dataset or a DatasetDict - we can update `get_dataset_split_names` to return None or a list if users want to know in advance what object will be returned. They can also use `isinstance` _a posteriori_ - but in this case we expect users to be careful when loading datasets and always to extra steps to check if they got a Dataset or DatasetDict 2. merge Dataset and DatasetDict objects - they already share many functions: map, filter, push_to_hub etc. - we can define `ds[0]` to be the first item of the first split, and consider that the uses accesses rows from the full table of all the splits concatenated - however there is a collision when doing `ds["column_name"]` or `ds["train"]` that we need to address: the first returns a list, while the other returns a Dataset. What are your opinions on those two ideas ? Do you have other ideas in mind ?
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
I like the first idea more (concatenating splits doesn't seem useful, no?). This is a significant breaking change, so I think we should do a poll (or something similar) to gather more info on the actual "expected behavior" and wait for Datasets 3.0 if we decide to implement it. PS: @thomwolf also suggested the same thing a while ago (https://github.com/huggingface/datasets/issues/743#issuecomment-746074641).
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
60
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! I like the first idea more (concatenating splits doesn't seem useful, no?). This is a significant breaking change, so I think we should do a poll (or something similar) to gather more info on the actual "expected behavior" and wait for Datasets 3.0 if we decide to implement it. PS: @thomwolf also suggested the same thing a while ago (https://github.com/huggingface/datasets/issues/743#issuecomment-746074641).
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
I think it's an interesting improvement to the user experience for a case that comes often (no split) so I would definitively support it. I would be more in favor of option 2 rather than returning various types of objects from load_dataset and handling carefully the possible collisions indeed
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
49
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! I think it's an interesting improvement to the user experience for a case that comes often (no split) so I would definitively support it. I would be more in favor of option 2 rather than returning various types of objects from load_dataset and handling carefully the possible collisions indeed
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
Related: if a dataset only has one split, we don't show the splits select control in the dataset viewer on the Hub, eg. compare https://huggingface.co/datasets/hf-internal-testing/fixtures_image_utils/viewer/image/test with https://huggingface.co/datasets/glue/viewer/mnli/test. See https://github.com/huggingface/moon-landing/pull/3858 for more details (internal)
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
33
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! Related: if a dataset only has one split, we don't show the splits select control in the dataset viewer on the Hub, eg. compare https://huggingface.co/datasets/hf-internal-testing/fixtures_image_utils/viewer/image/test with https://huggingface.co/datasets/glue/viewer/mnli/test. See https://github.com/huggingface/moon-landing/pull/3858 for more details (internal)
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
I feel like the second idea is a bit more overkill. @severo I would say it's a bit irrelevant to the problem we have but is a separate problem @polinaeterna is solving at the moment. 😅 (also discussed on slack)
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
40
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! I feel like the second idea is a bit more overkill. @severo I would say it's a bit irrelevant to the problem we have but is a separate problem @polinaeterna is solving at the moment. 😅 (also discussed on slack)
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
OK, sorry for polluting the thread. The relation I saw with the dataset viewer is that from a UX point of view, we hide the concepts of split and configuration whenever possible -> this issue feels like doing the same in the datasets library.
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
44
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! OK, sorry for polluting the thread. The relation I saw with the dataset viewer is that from a UX point of view, we hide the concepts of split and configuration whenever possible -> this issue feels like doing the same in the datasets library.
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
I would agree that returning different types based on the content of the dataset might be confusing. We can do something similar to what `fetch_*` or `load_*` from `sklearn.datasets` do, which is to have an arg which changes the type of the returned type. For instance, `load_iris` would return a dict, but `load_iris(..., return_X_y=True)` would return a tuple. Here we can have a similar arg such as `return_X` which would then only return a single `DataSet` or an array.
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
79
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! I would agree that returning different types based on the content of the dataset might be confusing. We can do something similar to what `fetch_*` or `load_*` from `sklearn.datasets` do, which is to have an arg which changes the type of the returned type. For instance, `load_iris` would return a dict, but `load_iris(..., return_X_y=True)` would return a tuple. Here we can have a similar arg such as `return_X` which would then only return a single `DataSet` or an array.
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
> I feel like the second idea is a bit more overkill. Overkill in what sense ? > Here we can have a similar arg such as return_X which would then only return a single DataSet or an array. Right now one can already pass `split="all"` to get one `Dataset` object with all the data in it (unsplit). We could also have something like `return_all=True` so make the API clearer. > I would be more in favor of option 2 rather than returning various types of objects from load_dataset and handling carefully the possible collisions indeed I think it would be ok to handle the collision by allowing both `ds["train"]` and `ds["column_name"]` (and maybe adding something like `ds.splits` for those who want to iterate over the splits or add new ones)
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
131
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! > I feel like the second idea is a bit more overkill. Overkill in what sense ? > Here we can have a similar arg such as return_X which would then only return a single DataSet or an array. Right now one can already pass `split="all"` to get one `Dataset` object with all the data in it (unsplit). We could also have something like `return_all=True` so make the API clearer. > I would be more in favor of option 2 rather than returning various types of objects from load_dataset and handling carefully the possible collisions indeed I think it would be ok to handle the collision by allowing both `ds["train"]` and `ds["column_name"]` (and maybe adding something like `ds.splits` for those who want to iterate over the splits or add new ones)
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
Would it make sense to remove the notion of "split" in `load_dataset`? I feel a lof of it comes from the want to have some sort of group of more or less similar dataset. "train"/"test"/"validation" are the traditional ones, but there are some datasets that have much more splits. Would it make sense to force `load_dataset` to only load a single `Dataset` object, and fail if it doesn't point to one. And have another method that's like `load_dataset_group_info` that can return a very arbitrary info class (Dict, List whatever), but you need to pass individual infos to `load_dataset` to run anything? Typically I don't think `DatasetDict.map` is really that helpful, but that's my personal opinion. This would help make things more readable (typically knowing if an object is a `Dataset` or a `DatasetDict`)
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
133
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! Would it make sense to remove the notion of "split" in `load_dataset`? I feel a lof of it comes from the want to have some sort of group of more or less similar dataset. "train"/"test"/"validation" are the traditional ones, but there are some datasets that have much more splits. Would it make sense to force `load_dataset` to only load a single `Dataset` object, and fail if it doesn't point to one. And have another method that's like `load_dataset_group_info` that can return a very arbitrary info class (Dict, List whatever), but you need to pass individual infos to `load_dataset` to run anything? Typically I don't think `DatasetDict.map` is really that helpful, but that's my personal opinion. This would help make things more readable (typically knowing if an object is a `Dataset` or a `DatasetDict`)
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
> Would it make sense to remove the notion of "split" in load_dataset? I think we need to keep it - though in practice people can name the splits whatever they want anyway. > Would it make sense to force load_dataset to only load a single Dataset object, and fail if it doesn't point to one. We need to keep backward compatibility ideally - in particular the load_dataset + ds["train"] one
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
71
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! > Would it make sense to remove the notion of "split" in load_dataset? I think we need to keep it - though in practice people can name the splits whatever they want anyway. > Would it make sense to force load_dataset to only load a single Dataset object, and fail if it doesn't point to one. We need to keep backward compatibility ideally - in particular the load_dataset + ds["train"] one
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
> I think we need to keep it - though in practice people can name the splits whatever they want anyway. It was my understanding that the whole issue was that `load_dataset` returned multiple types of objects. > We need to keep backward compatibility ideally - in particular the load_dataset + ds["train"] one Yeah sorry I meant ideally. One can always start developing `load_dataset_v2` can deprecate the first one and remove it in the longer term.
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
76
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! > I think we need to keep it - though in practice people can name the splits whatever they want anyway. It was my understanding that the whole issue was that `load_dataset` returned multiple types of objects. > We need to keep backward compatibility ideally - in particular the load_dataset + ds["train"] one Yeah sorry I meant ideally. One can always start developing `load_dataset_v2` can deprecate the first one and remove it in the longer term.
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
> It was my understanding that the whole issue was that load_dataset returned multiple types of objects. Yes indeed, but we still want to keep a way to load the train/val/test/whatever splits alone ;)
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
34
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! > It was my understanding that the whole issue was that load_dataset returned multiple types of objects. Yes indeed, but we still want to keep a way to load the train/val/test/whatever splits alone ;)
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
Started to experiment with merging Dataset and DatasetDict. My plan is to define the splits of a Dataset in Dataset.info.splits (already exists, but never used). A Dataset would then be the concatenation of its splits if they exist. Not sure yet this is the way to go. My plan is to play with it and see and share it with you, so we can see if it makes sense from a UX point of view.
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
75
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! Started to experiment with merging Dataset and DatasetDict. My plan is to define the splits of a Dataset in Dataset.info.splits (already exists, but never used). A Dataset would then be the concatenation of its splits if they exist. Not sure yet this is the way to go. My plan is to play with it and see and share it with you, so we can see if it makes sense from a UX point of view.
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
So just to make sure that I understand the current direction, people will have to be extra careful when handling splits right? Imagine "potato" a dataset containing train/validation split: ``` load_dataset("potato") # returns the concatenation of all the splits ``` Previously the design would force you to choose a split (it would raise otherwise), or manually concat them if you really wanted to play with concatenated splits. Now it would potentially run without raising for a bit of time until you figure out that you've been training on both train and validation split. Would it make sense to use a dataset specific default instead of using the concatenation, typically "potato" dataset's default would be train? ``` load_dataset("potato") # returns "train" split load_dataset("potato", split="train") # returns "train" split load_dataset("potato", split="validation") # returns "validation" split concatenate_datasets([load_dataset("potato", split="train"), load_dataset("potato", split="validation")]) # returns concatenation ```
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
141
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! So just to make sure that I understand the current direction, people will have to be extra careful when handling splits right? Imagine "potato" a dataset containing train/validation split: ``` load_dataset("potato") # returns the concatenation of all the splits ``` Previously the design would force you to choose a split (it would raise otherwise), or manually concat them if you really wanted to play with concatenated splits. Now it would potentially run without raising for a bit of time until you figure out that you've been training on both train and validation split. Would it make sense to use a dataset specific default instead of using the concatenation, typically "potato" dataset's default would be train? ``` load_dataset("potato") # returns "train" split load_dataset("potato", split="train") # returns "train" split load_dataset("potato", split="validation") # returns "validation" split concatenate_datasets([load_dataset("potato", split="train"), load_dataset("potato", split="validation")]) # returns concatenation ```
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
> load_dataset("potato") # returns "train" split To avoid a breaking change we need to be able to do `load_dataset("potato")["validation"]` as well. In that case I'd wonder where the validation split comes from, since the rows of the dataset wouldn't contain the validation split according to your example. That's why I'm more in favor of concatenating. A dataset is one table, that optionally has some split info about subsets (e.g. for training an evaluation) This also allows anyone to re-split the dataset the way they want if they're not happy with the default: ```python ds = load_dataset("potato").train_test_split(test_size=0.2) train_ds = ds["train"] test_ds = ds["test"] ```
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
103
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! > load_dataset("potato") # returns "train" split To avoid a breaking change we need to be able to do `load_dataset("potato")["validation"]` as well. In that case I'd wonder where the validation split comes from, since the rows of the dataset wouldn't contain the validation split according to your example. That's why I'm more in favor of concatenating. A dataset is one table, that optionally has some split info about subsets (e.g. for training an evaluation) This also allows anyone to re-split the dataset the way they want if they're not happy with the default: ```python ds = load_dataset("potato").train_test_split(test_size=0.2) train_ds = ds["train"] test_ds = ds["test"] ```
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
Just thinking about this, we could just have `to_dataframe()` as `load_dataset("blah").to_dataframe()` to get the whole dataset, and not change anything else.
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
21
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! Just thinking about this, we could just have `to_dataframe()` as `load_dataset("blah").to_dataframe()` to get the whole dataset, and not change anything else.
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
I have a first implementation of option 2 (merging Dataset and DatasetDict) in this PR: https://github.com/huggingface/datasets/pull/5301/ Feel free to play with it if you're interested, and let me know what you think. In this PR, a dataset is one table that optionally has some split info about subsets.
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
48
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! I have a first implementation of option 2 (merging Dataset and DatasetDict) in this PR: https://github.com/huggingface/datasets/pull/5301/ Feel free to play with it if you're interested, and let me know what you think. In this PR, a dataset is one table that optionally has some split info about subsets.
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
@adrinjalali we already have [to_pandas](https://huggingface.co/docs/datasets/package_reference/main_classes#datasets.Dataset.to_pandas) AFAIK that essentially does the same thing (for a dataset, not for a dataset dict), I was wondering if it makes sense to have this as I don't know portion of people who load non-tabular datasets into dataframes. @lhoestq I saw your PR and it will break a lot of things imo, WDYT of this option?
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
61
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! @adrinjalali we already have [to_pandas](https://huggingface.co/docs/datasets/package_reference/main_classes#datasets.Dataset.to_pandas) AFAIK that essentially does the same thing (for a dataset, not for a dataset dict), I was wondering if it makes sense to have this as I don't know portion of people who load non-tabular datasets into dataframes. @lhoestq I saw your PR and it will break a lot of things imo, WDYT of this option?
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
> we already have [to_pandas](https://huggingface.co/docs/datasets/package_reference/main_classes#datasets.Dataset.to_pandas) AFAIK that essentially does the same thing (for a dataset, not for a dataset dict) yes correct :) > I saw your PR and it will break a lot of things imo Do you have concrete examples you can share ? > WDYT of this option? The to_dataframe option ? I think it not enough, since you'd still get a `DatasetDict({"train": Dataset()})` if you load a dataset with no splits (e.g. one CSV), and this doesn't really make sense. Note that in the PR I opened you can do ```python ds = load_dataset("dataset_with_just_one_csv") # Dataset type df = load_dataset("dataset_with_just_one_csv").to_pandas() # DataFrame type ```
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
108
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! > we already have [to_pandas](https://huggingface.co/docs/datasets/package_reference/main_classes#datasets.Dataset.to_pandas) AFAIK that essentially does the same thing (for a dataset, not for a dataset dict) yes correct :) > I saw your PR and it will break a lot of things imo Do you have concrete examples you can share ? > WDYT of this option? The to_dataframe option ? I think it not enough, since you'd still get a `DatasetDict({"train": Dataset()})` if you load a dataset with no splits (e.g. one CSV), and this doesn't really make sense. Note that in the PR I opened you can do ```python ds = load_dataset("dataset_with_just_one_csv") # Dataset type df = load_dataset("dataset_with_just_one_csv").to_pandas() # DataFrame type ```
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
@lhoestq no I think @adrinjalali and I meant when user calls `to_dataframe` if there's only train split in `DatasetDict` we could directly load that into dataframe. This might cause a confusion given there's to_pandas but I think it's more intuitive and least breaking change. (given people -who use `datasets` for tabular workflows- will eventually call `to_pandas` anyway)
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
57
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! @lhoestq no I think @adrinjalali and I meant when user calls `to_dataframe` if there's only train split in `DatasetDict` we could directly load that into dataframe. This might cause a confusion given there's to_pandas but I think it's more intuitive and least breaking change. (given people -who use `datasets` for tabular workflows- will eventually call `to_pandas` anyway)
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
So in that case it would be fine to still end up with a dataset dict with a "train" split ?
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
21
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! So in that case it would be fine to still end up with a dataset dict with a "train" split ?
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
yeah what I mean is this: ```py dataset = load_dataset("blah") # deal with a split of the dataset train = dataset["train"] train_df = dataset["train"].to_dataframe() # deal with the whole dataset dataset_df = dataset.to_dataframe() ``` So we do two things to improve tabular experience: - allow datasets to have a single split - add `to_dataframe` to the root dict level so that users can simply call `df = load_dataset("blah").to_dataframe()` and have it in their `pandas.DataFrame` object.
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
75
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! yeah what I mean is this: ```py dataset = load_dataset("blah") # deal with a split of the dataset train = dataset["train"] train_df = dataset["train"].to_dataframe() # deal with the whole dataset dataset_df = dataset.to_dataframe() ``` So we do two things to improve tabular experience: - allow datasets to have a single split - add `to_dataframe` to the root dict level so that users can simply call `df = load_dataset("blah").to_dataframe()` and have it in their `pandas.DataFrame` object.
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
Ok ! Note that we already have `Dataset.to_pandas()` so for consistency I'd call it `DatasetDict.to_pandas()` as well, does it sound good to you ? This is something we can add pretty easily
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
32
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! Ok ! Note that we already have `Dataset.to_pandas()` so for consistency I'd call it `DatasetDict.to_pandas()` as well, does it sound good to you ? This is something we can add pretty easily
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
> So just to make sure that I understand the current direction, people will have to be extra careful when handling splits right? We can raise an error if someone does `load_dataset(...)[0]` if the dataset is made of several splits, and return the first example if there's one or zero splits (i.e. when it's not ambiguous). Had this idea from the dicussions in #5312 WDYT @thomasw21 ?
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
67
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! > So just to make sure that I understand the current direction, people will have to be extra careful when handling splits right? We can raise an error if someone does `load_dataset(...)[0]` if the dataset is made of several splits, and return the first example if there's one or zero splits (i.e. when it's not ambiguous). Had this idea from the dicussions in #5312 WDYT @thomasw21 ?
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
> We can raise an error if someone does load_dataset(...)[0] if the dataset is made of several splits, But then how is that different to have the distinction between DatasetDict and Dataset then? Is it just that "default behaviour when there are no splits or single split, it returns directly the split when there's no ambiguity". Also I was wondering how the concatenation could have heavy impacts when running mapping functions/filtering in batch? Typically can batch be somehow mixed?
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
79
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! > We can raise an error if someone does load_dataset(...)[0] if the dataset is made of several splits, But then how is that different to have the distinction between DatasetDict and Dataset then? Is it just that "default behaviour when there are no splits or single split, it returns directly the split when there's no ambiguity". Also I was wondering how the concatenation could have heavy impacts when running mapping functions/filtering in batch? Typically can batch be somehow mixed?
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
> But then how is that different to have the distinction between DatasetDict and Dataset then? Because it doesn't make sense to be able to do `example = ds[0]` or `examples = list(ds)` on a class named `DatasetDict` of type `Dict[str, Dataset]`. > Also I was wondering how the concatenation could have heavy impacts when running mapping functions/filtering in batch? Typically can batch be somehow mixed? No, we run each function on each split separated
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
75
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! > But then how is that different to have the distinction between DatasetDict and Dataset then? Because it doesn't make sense to be able to do `example = ds[0]` or `examples = list(ds)` on a class named `DatasetDict` of type `Dict[str, Dataset]`. > Also I was wondering how the concatenation could have heavy impacts when running mapping functions/filtering in batch? Typically can batch be somehow mixed? No, we run each function on each split separated
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5189
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded
> Because it doesn't make sense to be able to do example = ds[0] or examples = list(ds) on a class named DatasetDict of type Dict[str, Dataset]. Hum but you're still going to raise an exception in both those cases with your current change no? (actually list(ds) would return the name of the splits no?) > No, we run each function on each split separated Nice!
### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first!
445
66
Reduce friction in tabular dataset workflow by eliminating having splits when dataset is loaded ### Feature request Sorry for cryptic name but I'd like to explain using code itself. When I want to load a specific dataset from a repository (for instance, this: https://huggingface.co/datasets/inria-soda/tabular-benchmark) ```python from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) print(next(iter(dataset["train"]))) ``` `datasets` library is essentially designed for people who'd like to use benchmark datasets on various modalities to fine-tune their models, and these benchmark datasets usually have pre-defined train and test splits. However, for tabular workflows, having train and test splits usually ends up model overfitting to validation split so usually the users would like to do validation techniques like `StratifiedKFoldCrossValidation` or when they tune for hyperparameters they do `GridSearchCrossValidation` so often the behavior is to create their own splits. Even [in this paper](https://hal.archives-ouvertes.fr/hal-03723551) a benchmark is introduced but the split is done by authors. It's a bit confusing for average tabular user to try and load a dataset and see `"train"` so it would be nice if we would not load dataset into a split called `train `by default. ```diff from datasets import load_dataset dataset = load_dataset("inria-soda/tabular-benchmark", data_files=["reg_cat/house_sales.csv"], streaming=True) -print(next(iter(dataset["train"]))) +print(next(iter(dataset))) ``` ### Motivation I explained it above 😅 ### Your contribution I think this is quite a big change that seems small (e.g. how to determine datasets that will not be load to train split?), it's best if we discuss first! > Because it doesn't make sense to be able to do example = ds[0] or examples = list(ds) on a class named DatasetDict of type Dict[str, Dataset]. Hum but you're still going to raise an exception in both those cases with your current change no? (actually list(ds) would return the name of the splits no?) > No, we run each function on each split separated Nice!
[ -1.1914674043655396, -0.9442957639694214, -0.6595273017883301, 1.4820173978805542, -0.02795322984457016, -1.2646749019622803, 0.12972185015678406, -1.0703541040420532, 1.676597237586975, -0.832597553730011, 0.36734265089035034, -1.7358667850494385, 0.010983324609696865, -0.6361969113349915, -0.7146538496017456, -0.8758326172828674, -0.4448721408843994, -0.7822366952896118, 1.0286768674850464, 2.462001323699951, 1.258065104484558, -1.363305687904358, 2.776832342147827, 0.715023934841156, -0.20607608556747437, -1.0146182775497437, 0.4706685245037079, -0.014824757352471352, -1.3147616386413574, -0.4335939586162567, -1.0138561725616455, -0.12729811668395996, -0.5531818270683289, -0.5892882347106934, 0.061663124710321426, 0.4610978960990906, -0.30872297286987305, -0.4219632148742676, -0.6188876628875732, -0.7417505979537964, 0.5127089023590088, -0.4148258864879608, 1.0040996074676514, -0.3005834221839905, 1.825520396232605, -0.5949099063873291, 0.46105241775512695, 0.6532025337219238, 1.3686069250106812, 0.21476516127586365, -0.03578459098935127, 0.38751500844955444, 0.33845677971839905, -0.01309164147824049, 0.5782209634780884, 1.236610770225525, 0.6302655339241028, 0.5367618203163147, 0.8097448945045471, -2.1526682376861572, 1.305046558380127, -0.9835980534553528, 0.37935250997543335, 1.3157918453216553, -0.9608544707298279, 0.3648555278778076, -1.7710570096969604, -0.09755954146385193, 0.5443620681762695, -2.2236292362213135, 0.16913385689258575, -1.2808631658554077, -0.4827059209346771, 1.0364645719528198, 0.3260643482208252, -1.1512104272842407, 0.23526239395141602, -0.44787830114364624, 0.9777233004570007, 0.42848172783851624, 1.1398640871047974, -1.7404905557632446, -0.06380925327539444, -0.31643009185791016, 0.18091736733913422, -1.2491602897644043, -1.5637874603271484, 0.6092801690101624, 0.7490524649620056, 0.624693751335144, -0.18141955137252808, 1.0431177616119385, -1.0088168382644653, 0.7259753942489624, -1.053200125694275, -1.704040765762329, -1.4196621179580688, -2.2220611572265625, -2.333296298980713, 0.7586666941642761, -0.4821672737598419, -0.563485324382782, 2.0680084228515625, -1.0334097146987915, -1.786645770072937, 1.1506091356277466, 0.30854880809783936, -0.032255884259939194, 2.401660919189453, 0.1913929283618927, -0.7275235056877136, 0.5622112154960632, -0.6568435430526733, 0.7860492467880249, -0.4053021967411041, 1.3292500972747803, 0.4279983639717102, -1.0721174478530884, 1.600827932357788, -0.4235824942588806, 0.6031380891799927, -0.6654375791549683, -0.5095133185386658, -0.7189246416091919, 0.35547274351119995, 1.88985013961792, -0.3206828236579895, 1.5723623037338257, -0.32125771045684814, -1.5990607738494873, -1.6407662630081177, 0.8256913423538208, 0.4135192334651947, -0.6787169575691223, 0.043897420167922974, -0.42441678047180176, 0.11340498924255371, 0.03530636429786682, 1.1474055051803589, 1.1953681707382202, 0.6896442174911499, -0.28370869159698486, -0.8548169732093811, 0.16102267801761627, 0.006938005797564983, -0.7104572057723999, -1.700534462928772, -0.3694441020488739, 0.2025279402732849, 0.511959969997406, -1.1255956888198853, 1.7972383499145508, 0.9210692048072815, 1.9351195096969604, 1.0317438840866089, -0.24929116666316986, 1.5117106437683105, 0.09718014299869537, 1.8275281190872192, -0.4563085436820984, 0.6074087619781494, -0.336232990026474, -1.175658106803894, 0.7614872455596924, -0.35455891489982605, -2.012510299682617, -0.6624682545661926, -0.7773264646530151, -0.07325447350740433, -0.7924821972846985, 0.9585795402526855, -0.22983244061470032, -1.4050688743591309, 0.2542532980442047, -0.6933581233024597, 0.12208119034767151, -1.2537434101104736, 0.26641756296157837, 0.7140970826148987, -0.6509629487991333, 0.10273302346467972, -0.22988945245742798, -1.285524606704712, -0.3714579641819, 0.24324390292167664, 1.9003432989120483, -0.7892481088638306, 0.8471695184707642, 1.0871284008026123, -0.7159643769264221, 0.017698969691991806, 0.32890114188194275, -0.288811057806015, 0.840553343296051, -1.0171027183532715, -0.34560078382492065, 1.1854668855667114, -0.10156184434890747, -0.5723785758018494, 1.4285295009613037, 0.7090733051300049, -1.029557704925537, -0.18154843151569366, -0.14912353456020355, -0.8947698473930359, 0.006351487711071968, -1.5631073713302612, -0.06779157370328903, 0.3362969756126404, -1.4712201356887817, -0.4459482729434967, -0.2543513774871826, 1.1917973756790161, -0.10694663971662521, 1.3900786638259888, -0.36287739872932434, -0.19572047889232635, -0.3428354561328888, -0.47777295112609863, 0.08409886807203293, -0.2844064235687256, -0.6664656400680542, 0.1779012680053711, -0.7045866847038269, 0.36025798320770264, 1.5394002199172974, 0.3217722773551941, 0.1104072704911232, 0.4959232211112976, 1.137037992477417, 0.3235708475112915, -0.10442537069320679, -0.8670699596405029, -1.593305230140686, 1.9970430135726929, -1.429890751838684, 1.9127137660980225, 0.8015294075012207, 0.023383330553770065, -1.7941155433654785, -1.790839672088623, 1.3906067609786987, 1.185174584388733, 2.4282760620117188, 0.5442047119140625, 0.35259169340133667, -0.7989549040794373, -0.6962742805480957, 0.39589762687683105, -0.9479320049285889, -0.684552788734436, 0.13639043271541595, 2.3617331981658936, 1.8741250038146973, -0.5014310479164124, -0.2261098027229309, -0.9935706257820129, 1.4438905715942383, -0.3111305236816406, 0.1879296451807022, 2.0078577995300293, -0.32261526584625244, -1.0541754961013794, 1.3519634008407593, -2.292809009552002, 0.10756552219390869, 1.9575215578079224, 0.2827732264995575, 0.023414570838212967, -1.3503336906433105, -0.6258244514465332, -0.32118290662765503, -0.40641242265701294, -1.3499480485916138, 0.4863629937171936, -0.2916749119758606, -0.7430607080459595, -1.4646003246307373, 0.12219633162021637, -1.159946084022522, -1.6261647939682007, 0.22803360223770142, 1.807382345199585, 2.031722068786621, -0.8254055976867676, 1.4683934450149536, -0.309083491563797, 0.25746431946754456, 1.2315529584884644, 1.2408539056777954, 3.1313955783843994, 1.8714449405670166, -1.2764993906021118, 0.7048605680465698, -0.15752950310707092, -0.5228980779647827, 1.225701093673706, -1.1737529039382935, 1.2983001470565796, -0.18933357298374176, -1.2417895793914795, -1.2152281999588013, 0.9273204803466797, 0.4973224401473999, 0.02677289769053459, -0.5436111688613892, 1.187381625175476, 0.08998763561248779, 1.274354100227356, 0.5726756453514099, -0.3703100085258484, 0.655039370059967, -0.32371601462364197, -0.5593989491462708, 1.4642314910888672, 0.20980001986026764, -1.4626365900039673, -2.2463934421539307, -0.14701178669929504, -0.851314127445221, 0.0014586681500077248, -0.662255048751831, -0.9808991551399231, 1.6541575193405151, 0.33368536829948425, -1.2560546398162842, -0.1951611042022705, -0.33955520391464233, -0.5346062779426575, 2.69661283493042, -1.3513474464416504, -0.19570748507976532, -1.071213960647583, -0.6160128116607666, 1.6277241706848145, -1.1481090784072876, -0.2199903279542923, -1.0351990461349487, -0.5198087692260742, -1.2654829025268555, -0.5619080066680908, -0.011706087738275528, -0.8440313935279846, 0.7575278282165527, 0.19053508341312408, -1.1756258010864258, -0.30595675110816956, -0.8592910766601562, 0.9319593906402588, -0.23415128886699677, 0.15757472813129425, 1.881794810295105, 0.4122317433357239, -0.41658738255500793, 0.6842982172966003, 1.2169189453125, 0.5735723972320557, -0.6089416742324829, 0.1653086096048355, -0.7761695981025696, 0.2884500026702881, -1.379339337348938, 0.2690626382827759, -2.8482768535614014, 0.635292649269104, -0.04891842231154442, -0.10250689089298248, 0.035168588161468506, -1.3790122270584106, 1.0295075178146362, 2.6193013191223145, -1.1435062885284424, 0.4788656234741211, 0.3169310390949249, 1.1360044479370117, -1.6252309083938599, 0.27518966794013977, -0.42612534761428833, 1.9954801797866821, 0.1472027748823166, 1.1557130813598633, -0.4984869062900543, -2.26419734954834, 0.6025399565696716, -1.2909513711929321, -1.1229978799819946, 0.8395822048187256, -0.9497559666633606, 0.12327894568443298, -1.3889081478118896, -0.20771561563014984, -0.8456428050994873, -1.1519805192947388, 0.7732086777687073, 0.10221026092767715, 0.42895954847335815, -0.5529689788818359, 0.3274464011192322, -2.167285442352295, -1.4313063621520996, -0.24595065414905548, -0.971092700958252, 0.49083560705184937, -0.31789666414260864, 0.6646456718444824, -0.21101385354995728, -0.037165913730859756, 0.35487401485443115, 1.425930380821228, 3.326564311981201, 0.232480987906456, 0.34166303277015686, -0.13492172956466675, -0.9797792434692383, 1.435670256614685, 0.8734431266784668, -0.2312641590833664, -0.5025702118873596, -1.0198057889938354, 1.2939341068267822, 1.885570764541626, 1.0696563720703125, -0.008453075774013996, -0.8331844806671143, -0.8146911859512329, 0.0039238110184669495, 0.14572308957576752, 0.4271494746208191, 0.8856649994850159, 0.09584768116474152, 0.10584225505590439, 1.4522700309753418, 1.192973256111145, -0.3943294286727905, 0.3918911814689636, -0.8402279019355774, -0.5173196792602539, 0.5400858521461487, 0.2847956120967865, 0.06561712920665741, 0.3539246916770935, -0.9968082308769226, -0.26493024826049805, -0.4135831594467163, -0.8685330748558044, -0.7604528069496155, -0.4687676429748535, -0.30953168869018555, 1.6874271631240845, 0.013868994079530239, -0.5444087982177734, 0.05335499346256256, -0.7634189128875732, -0.17237238585948944, -1.0472919940948486, 0.2796063721179962, -0.056281644850969315, -0.15594226121902466, -0.12857051193714142, 1.6655834913253784, -0.9944897890090942, -2.105095863342285, 0.22053880989551544, 0.2844340205192566, -0.3573211133480072, 0.11216921359300613, 1.6860096454620361, 0.5515879988670349, 1.4288086891174316, 1.415656328201294, 0.9725615978240967, -0.6660889387130737, -1.3190582990646362, 0.6984302401542664, 0.9682594537734985, -1.3330209255218506, 0.8793686628341675, 0.01160441618412733, -0.573678731918335, 0.6314356327056885, 1.2830785512924194, 0.470045268535614, -1.949678659439087, 0.7946105003356934, -0.9321669936180115, 0.7069047093391418, 0.7408374547958374, 0.791425347328186, 0.19127674400806427, 0.7592442631721497, -1.2506312131881714, -1.2848998308181763, -0.7461686730384827, -0.6282411217689514, 1.95042884349823, -0.16667747497558594, 0.590219259262085, -0.23226295411586761, -1.3976023197174072, -0.029223855584859848, 0.7247026562690735, 0.35519227385520935, -0.5323641896247864, 0.7530360817909241, -0.7023674845695496, -1.0019851922988892, -1.393050193786621, -0.38482367992401123, -1.1144635677337646, -0.9405825138092041, 1.056363582611084, 0.8014550805091858, 0.2763039767742157, 1.9045134782791138, 0.7571691870689392, 0.30534982681274414, -2.547736644744873, 0.9067613482475281, 0.2666444778442383, -0.07054216414690018, 0.8135391473770142, 0.3752514719963074, 0.9448931217193604, -0.06143699586391449, 0.5463709235191345, -2.343886613845825, 2.234060525894165, -0.18878427147865295, 0.6738365292549133, -0.039679259061813354, -0.20472534000873566, 1.0420719385147095, 0.5539391040802002, 0.5760297775268555, -1.149834394454956, 0.6518692374229431, -0.5200563669204712, 1.141631841659546, 0.8384459614753723, -0.8327520489692688, 0.03017226979136467, 1.3881103992462158, 0.4725845754146576, -0.5291492342948914, -0.9446828365325928, -0.9478027820587158, 0.9747408032417297, 1.6847037076950073, -0.01306091994047165, -0.05434037372469902, 0.9450870156288147, 0.6887485980987549, -1.3015086650848389, 0.04886612668633461, -0.6166824102401733, -0.7051434516906738, 1.6948961019515991, 2.066162109375, -0.17173083126544952, -0.18584983050823212, -0.6882513165473938, -1.1734702587127686, 0.7995641231536865, 0.07411034405231476, 0.09742593765258789, 0.706258237361908, -0.6747443675994873, 1.1793212890625, 0.9104973077774048, 0.8261518478393555, 0.24760949611663818, 0.2884865403175354, 0.42938128113746643, -0.3079790472984314, -1.219225287437439, -0.24195745587348938, -1.0661133527755737, -2.515531539916992, 0.5023279190063477, -0.18726415932178497, -1.45353102684021, 0.056309107691049576, -1.0131043195724487, 0.8839306831359863, -0.6169468760490417, -1.0777817964553833, -1.5809438228607178, 0.25192686915397644, -0.07962958514690399, 0.8569486737251282, -1.570167064666748, -0.10805942863225937, 1.0786148309707642, 0.9570950269699097, -0.6092590093612671, 0.9651000499725342, 0.25568515062332153, 0.9852296113967896, 0.9207122325897217, -0.34333330392837524, 0.5590552687644958, 0.05373769626021385, -1.3497400283813477, 0.39256179332733154, 1.1829088926315308, 0.25739648938179016, 1.3934789896011353, -0.4951903522014618, 0.023926645517349243, 0.38929834961891174, -0.5392597317695618, -0.3865368068218231, -0.6175291538238525, 0.6641036868095398, 0.0745646208524704, -0.9471442103385925, -0.015082595869898796, -0.04863215982913971, -0.30788442492485046, 0.2762874364852905, -1.5231093168258667, -0.09431162476539612, -0.3672502934932709, -0.6223450303077698, -1.2075622081756592, -0.11558885872364044, 1.4810694456100464, -0.8054047226905823, -0.22436413168907166, 0.5313946604728699, 0.35056906938552856, 0.5085399746894836, 0.5736292600631714, -0.7428714632987976, -0.15202994644641876, -0.2282733917236328, -0.38694968819618225, 0.2857597768306732, 1.343252182006836, -0.12572592496871948, -0.9775890707969666, 0.6954992413520813, -0.4461634159088135, 0.0730944350361824, 1.9275935888290405, 0.1232849657535553, -0.8495165109634399, 0.2896031439304352, -0.7647814154624939, 1.883432388305664, 1.8298810720443726, 1.373339295387268, -0.013651881366968155, -0.955897331237793, 0.590569257736206, -0.31877073645591736, -0.37588176131248474, 0.9465239644050598, 0.31568992137908936, -0.21165058016777039, -1.4073699712753296, 0.6991920471191406, 1.2842923402786255, -0.813715934753418, -0.7601511478424072, 0.01455725822597742, -0.9262866973876953, 1.107534646987915, 0.6918982863426208, 0.3301437199115753, 0.2618224024772644, 1.6801178455352783, 0.784653902053833, -0.41510698199272156, 0.5808712244033813, 0.577112078666687, -0.19608770310878754, -2.096606969833374, -1.1142475605010986, 0.2965258061885834, -0.48214834928512573, -1.6411062479019165, 1.33518648147583, -1.215350866317749, -0.9574586749076843, 0.48798152804374695, 0.004035569727420807, 1.5181442499160767, 0.36243489384651184, 1.5003856420516968, 2.115596055984497, 0.8649346232414246, 0.358449250459671, 1.2734966278076172, -0.1726185381412506, -0.3133622705936432, 1.8447864055633545, -0.40703248977661133, 0.5161000490188599, 0.9904257655143738, -0.3638676106929779, -1.1430295705795288, -0.7571061253547668, -1.2890288829803467, -0.6970407962799072, 1.1231580972671509, 0.0339433029294014, -1.1371312141418457, 0.3569876551628113, 1.6299799680709839, 0.05829570069909096, -0.33574602007865906, 0.6601543426513672, 0.4371742904186249, -0.756403923034668, -0.08238594979047775, -0.9507071375846863, 0.5205822587013245, -0.16163936257362366, -0.30509254336357117, 0.2800622284412384, 0.5180971622467041, 1.3071482181549072, 0.07212479412555695, 0.12474802136421204, 1.192861557006836, -1.3810454607009888, 1.4154391288757324, -0.7403439283370972, 0.27877718210220337, -2.3925769329071045, 1.458742380142212, -0.7918224334716797, 1.8992929458618164, -2.6530368328094482, 0.5071437358856201, -0.611208438873291, -0.5370365977287292, 0.2967553734779358, -0.4054686427116394, 0.13975022733211517, -0.05366063117980957, -1.1549625396728516, -0.03659023717045784, -0.6683492660522461, 0.633394181728363, 1.117544412612915, 1.4176325798034668, -1.0980126857757568, -0.3748422861099243, -1.7762150764465332, -0.10306822508573532, -0.718864381313324, 0.2603605389595032, -1.9785345792770386, -0.1824156492948532, -1.894885540008545, -2.440430164337158, -1.2959816455841064, -0.7661502361297607, 1.1530911922454834, 0.162551149725914, -0.9723074436187744, 1.1740672588348389, -0.48542794585227966, -1.8863348960876465, 1.1189171075820923, -2.2366180419921875 ]
https://github.com/huggingface/datasets/issues/5186
Incorrect error message when Dataset.from_sql fails and sqlalchemy not installed
Hi! The first `Dataset.from_sql` call also outputs the "ImportError: Using URI string without sqlalchemy installed." message, but you also get "During handling of the above exception another exception occurred: ..." after which the ValueError is printed. I agree that this behavior makes it easy to miss the original error. I think we can improve this by not throwing the writer's ValueError if the error from a dataset script is already being handled to make debugging easier. @lhoestq @albertvillanova wdyt?
### Describe the bug When calling `Dataset.from_sql` (in my case, with sqlite3), it fails with a message ```ValueError: Please pass `features` or at least one example when writing data``` when I don't have `sqlalchemy` installed. ### Steps to reproduce the bug Make a new sqlite db with `sqlite3` and `pandas` from a remote [URL](https://raw.githubusercontent.com/nytimes/covid-19-data/master/us-states.csv). ```python import sqlite3 import pandas as pd from datasets import Dataset conn = sqlite3.connect('us_covid_data.db') df = pd.read_csv('https://raw.githubusercontent.com/nytimes/covid-19-data/master/us-states.csv') df.to_sql('states', conn, if_exists='replace') ``` Then if you try to query this DB like this: ```python ds = Dataset.from_sql('''SELECT * from states WHERE state=="New York";''', "sqlite:///us_covid_data.db") ``` You run into the error I described above: ```ValueError: Please pass `features` or at least one example when writing data``` However, if you try to pass features, as the error suggests, then you get an error that tells you the underlying problem... ```python from datasets import Dataset, Features, Value features = Features({ 'date': Value('date32'), 'label': Value('string'), 'fips': Value('int32'), 'cases': Value('int32'), 'deaths': Value('int32') }) ds = Dataset.from_sql( '''SELECT * from states WHERE state=="New York";''', "sqlite:///us_covid_data.db", features=features ) ``` Which results in the actual underlying error: `ImportError: Using URI string without sqlalchemy installed.` ### Expected behavior Instead of `ValueError` about needing to pass features, we should provide the actual underlying error about not having SQLAlchemy installed when it isn't found in the environment. ### Environment info - `datasets` version: 2.6.1 - Platform: macOS-10.16-x86_64-i386-64bit - Python version: 3.8.10 - PyArrow version: 10.0.0 - Pandas version: 1.2.5
446
79
Incorrect error message when Dataset.from_sql fails and sqlalchemy not installed ### Describe the bug When calling `Dataset.from_sql` (in my case, with sqlite3), it fails with a message ```ValueError: Please pass `features` or at least one example when writing data``` when I don't have `sqlalchemy` installed. ### Steps to reproduce the bug Make a new sqlite db with `sqlite3` and `pandas` from a remote [URL](https://raw.githubusercontent.com/nytimes/covid-19-data/master/us-states.csv). ```python import sqlite3 import pandas as pd from datasets import Dataset conn = sqlite3.connect('us_covid_data.db') df = pd.read_csv('https://raw.githubusercontent.com/nytimes/covid-19-data/master/us-states.csv') df.to_sql('states', conn, if_exists='replace') ``` Then if you try to query this DB like this: ```python ds = Dataset.from_sql('''SELECT * from states WHERE state=="New York";''', "sqlite:///us_covid_data.db") ``` You run into the error I described above: ```ValueError: Please pass `features` or at least one example when writing data``` However, if you try to pass features, as the error suggests, then you get an error that tells you the underlying problem... ```python from datasets import Dataset, Features, Value features = Features({ 'date': Value('date32'), 'label': Value('string'), 'fips': Value('int32'), 'cases': Value('int32'), 'deaths': Value('int32') }) ds = Dataset.from_sql( '''SELECT * from states WHERE state=="New York";''', "sqlite:///us_covid_data.db", features=features ) ``` Which results in the actual underlying error: `ImportError: Using URI string without sqlalchemy installed.` ### Expected behavior Instead of `ValueError` about needing to pass features, we should provide the actual underlying error about not having SQLAlchemy installed when it isn't found in the environment. ### Environment info - `datasets` version: 2.6.1 - Platform: macOS-10.16-x86_64-i386-64bit - Python version: 3.8.10 - PyArrow version: 10.0.0 - Pandas version: 1.2.5 Hi! The first `Dataset.from_sql` call also outputs the "ImportError: Using URI string without sqlalchemy installed." message, but you also get "During handling of the above exception another exception occurred: ..." after which the ValueError is printed. I agree that this behavior makes it easy to miss the original error. I think we can improve this by not throwing the writer's ValueError if the error from a dataset script is already being handled to make debugging easier. @lhoestq @albertvillanova wdyt?
[ -1.0802981853485107, -0.9882494807243347, -0.8116843104362488, 1.672055721282959, -0.20419006049633026, -1.1929147243499756, 0.13329216837882996, -1.0065010786056519, 1.692153811454773, -0.7212358117103577, 0.2637934982776642, -1.717377781867981, -0.0015429332852363586, -0.6367207765579224, -0.7803648114204407, -0.7606735229492188, -0.37794405221939087, -0.7628090381622314, 1.132609248161316, 2.3819527626037598, 1.1709486246109009, -1.4173308610916138, 2.690288782119751, 0.7435626983642578, -0.09879518300294876, -1.0576153993606567, 0.5166282653808594, -0.07616609334945679, -1.2514127492904663, -0.45506665110588074, -0.9191556572914124, -0.015975575894117355, -0.5960214734077454, -0.5639625787734985, -0.026248391717672348, 0.49791961908340454, -0.3248213529586792, -0.5512511134147644, -0.5275286436080933, -0.6750781536102295, 0.504628598690033, -0.37635937333106995, 0.8754791021347046, -0.2398155927658081, 1.826882004737854, -0.5474698543548584, 0.3933461308479309, 0.7607199549674988, 1.4264144897460938, 0.1883932203054428, -0.06128005310893059, 0.49426019191741943, 0.31622323393821716, 0.029721256345510483, 0.5753325819969177, 1.2208194732666016, 0.6169546246528625, 0.4370327591896057, 0.8816187381744385, -2.3538851737976074, 1.234646201133728, -1.1373957395553589, 0.31461602449417114, 1.2248774766921997, -0.9819541573524475, 0.3564883768558502, -1.7775413990020752, 0.059676412492990494, 0.5560703277587891, -2.144806146621704, 0.41836318373680115, -1.3071423768997192, -0.3994171619415283, 1.0280132293701172, 0.348949670791626, -1.2450145483016968, 0.1469123810529709, -0.35418039560317993, 1.0616374015808105, 0.36277031898498535, 1.0416566133499146, -1.7111796140670776, 0.01163726020604372, -0.24915102124214172, 0.1478280872106552, -1.2225816249847412, -1.5788944959640503, 0.5170720815658569, 0.7053408026695251, 0.6473454236984253, -0.2497742474079132, 1.111668348312378, -1.0709445476531982, 0.6428737640380859, -0.9972865581512451, -1.7321864366531372, -1.4118015766143799, -2.181337833404541, -2.211300849914551, 0.7027763724327087, -0.4509724974632263, -0.42682185769081116, 2.011701822280884, -0.9247839450836182, -1.8706642389297485, 1.1991159915924072, 0.44304218888282776, -0.016772493720054626, 2.2876906394958496, 0.18222489953041077, -0.7449980974197388, 0.44284507632255554, -0.8315679430961609, 0.7871128916740417, -0.3598552644252777, 1.4523130655288696, 0.4237147867679596, -0.9876388311386108, 1.699738621711731, -0.3265998959541321, 0.695200502872467, -0.6823105812072754, -0.3403610587120056, -0.7255164384841919, 0.3637927770614624, 1.9774127006530762, -0.3072919547557831, 1.4607150554656982, -0.39503076672554016, -1.5952184200286865, -1.5844727754592896, 0.8914790749549866, 0.37911108136177063, -0.7660221457481384, 0.15581034123897552, -0.3772951364517212, 0.1322343498468399, -0.10201656818389893, 1.216239333152771, 1.2737077474594116, 0.6804471611976624, -0.34408271312713623, -0.8597555160522461, 0.17972387373447418, -0.0472843274474144, -0.6051281690597534, -1.7840778827667236, -0.37315210700035095, 0.1813146322965622, 0.6449222564697266, -1.1869163513183594, 1.7056516408920288, 0.8446775078773499, 1.9459019899368286, 1.0181002616882324, -0.3586564362049103, 1.5290359258651733, 0.07705610245466232, 1.9539490938186646, -0.5397557020187378, 0.5750778317451477, -0.4297483265399933, -1.1584943532943726, 0.7930792570114136, -0.3389541208744049, -2.0318756103515625, -0.7359120845794678, -0.8162797093391418, -0.1995946317911148, -0.7889170050621033, 0.864356517791748, -0.3673432469367981, -1.4668070077896118, 0.18230204284191132, -0.7223379611968994, 0.1870713084936142, -1.12875497341156, 0.25531765818595886, 0.7107506394386292, -0.6307111978530884, 0.15130265057086945, -0.28102532029151917, -1.3783674240112305, -0.4656726121902466, 0.5309921503067017, 1.8824409246444702, -0.7633057236671448, 0.8321458101272583, 1.0916553735733032, -0.7335571646690369, 0.07397667318582535, 0.30266261100769043, -0.29186034202575684, 0.7861824631690979, -1.039283037185669, -0.5770101547241211, 1.1814829111099243, -0.2130163609981537, -0.6523888111114502, 1.3685963153839111, 0.8422954678535461, -1.0167843103408813, -0.21057243645191193, -0.187383234500885, -0.8086912035942078, -0.001975158229470253, -1.5477015972137451, -0.09477537125349045, 0.4632534384727478, -1.562572956085205, -0.535731852054596, -0.29494190216064453, 1.2758958339691162, -0.10868962109088898, 1.3825875520706177, -0.2947818636894226, -0.15929721295833588, -0.2163955271244049, -0.4626443386077881, 0.2025085836648941, -0.27036041021347046, -0.6418442130088806, 0.13845570385456085, -0.7748240232467651, 0.4077937602996826, 1.4281773567199707, 0.297002911567688, 0.013756276108324528, 0.6114000678062439, 1.2339541912078857, 0.479840487241745, 0.0485699325799942, -0.8807895183563232, -1.5786277055740356, 1.9311895370483398, -1.4396637678146362, 1.9731158018112183, 0.639989972114563, 0.055149536579847336, -1.8134287595748901, -1.886131763458252, 1.483474850654602, 1.2297694683074951, 2.38254714012146, 0.6476295590400696, 0.415947824716568, -0.8906652331352234, -0.6985368728637695, 0.22746717929840088, -1.0224733352661133, -0.7135785818099976, 0.15560996532440186, 2.45890212059021, 1.8166992664337158, -0.47616443037986755, -0.25424832105636597, -0.9570687413215637, 1.439150094985962, -0.2445734739303589, 0.3313843309879303, 2.0201666355133057, -0.17816154658794403, -1.0194374322891235, 1.3095678091049194, -2.4590086936950684, 0.23053070902824402, 2.025413990020752, 0.17491590976715088, 0.20290298759937286, -1.3810834884643555, -0.7173107862472534, -0.16761428117752075, -0.46577340364456177, -1.26060152053833, 0.4809759259223938, -0.18697573244571686, -0.7346276640892029, -1.4127552509307861, 0.2010534107685089, -1.0445913076400757, -1.6001425981521606, 0.22960104048252106, 1.9858815670013428, 1.9996663331985474, -0.8152692914009094, 1.635474443435669, -0.2585301101207733, 0.29728585481643677, 1.287433385848999, 1.3016730546951294, 3.073601484298706, 1.8774274587631226, -1.2398402690887451, 0.6601831316947937, -0.13659465312957764, -0.5432352423667908, 1.1961801052093506, -1.1446144580841064, 1.1626158952713013, -0.22352398931980133, -1.123111605644226, -1.1597357988357544, 0.893826961517334, 0.5140891075134277, 0.028802182525396347, -0.4504949152469635, 1.1461834907531738, 0.036022864282131195, 1.206734299659729, 0.6591364741325378, -0.3485114574432373, 0.5863185524940491, -0.3473950922489166, -0.5418574213981628, 1.471989631652832, 0.16084837913513184, -1.2881007194519043, -2.159259080886841, -0.17340435087680817, -0.8826181292533875, -0.04688536003232002, -0.55986487865448, -0.9640164375305176, 1.5274189710617065, 0.3210764229297638, -1.1917585134506226, -0.15479786694049835, -0.34044092893600464, -0.4756840765476227, 2.6428020000457764, -1.3692448139190674, -0.36496248841285706, -1.02186918258667, -0.6329174637794495, 1.7034666538238525, -1.0570694208145142, -0.24783092737197876, -1.0742888450622559, -0.5147557854652405, -1.311482548713684, -0.6013467311859131, 0.11761518567800522, -0.7890259623527527, 0.9203047752380371, 0.22808362543582916, -1.2521641254425049, -0.3291788101196289, -0.9275409579277039, 0.9846645593643188, -0.19931797683238983, 0.18023714423179626, 1.924011468887329, 0.34246957302093506, -0.3782697916030884, 0.8464425802230835, 1.0545337200164795, 0.5904451608657837, -0.5716721415519714, 0.3492187559604645, -0.6049968004226685, 0.32694441080093384, -1.468045949935913, 0.2105409801006317, -2.8644087314605713, 0.5924910306930542, 0.06624330580234528, -0.05111301317811012, -0.027623716741800308, -1.4389621019363403, 1.0314396619796753, 2.525982618331909, -1.244498610496521, 0.44242605566978455, 0.30878791213035583, 1.33747398853302, -1.6214327812194824, 0.1454801708459854, -0.36072900891304016, 2.098393440246582, 0.10392060875892639, 1.2418766021728516, -0.4550979733467102, -2.36086106300354, 0.5612366795539856, -1.3263417482376099, -1.0965584516525269, 0.7112340927124023, -0.9478579759597778, 0.17954714596271515, -1.4922144412994385, -0.2696237564086914, -0.9085248708724976, -1.1841837167739868, 0.7443477511405945, 0.13348941504955292, 0.287087619304657, -0.6107144951820374, 0.4266405403614044, -2.0090622901916504, -1.4025756120681763, -0.1486208736896515, -0.9328345656394958, 0.5119632482528687, -0.350189745426178, 0.6532498002052307, -0.17159408330917358, 0.010479112155735493, 0.3153645694255829, 1.4737321138381958, 3.3664004802703857, 0.1246289387345314, 0.33403193950653076, -0.15847346186637878, -0.8949676156044006, 1.4329744577407837, 0.9249007701873779, -0.19860367476940155, -0.4747053384780884, -1.1642695665359497, 1.33156156539917, 1.9786885976791382, 0.9903722405433655, 0.02377418801188469, -0.7831239104270935, -0.7792662382125854, 0.04933658242225647, 0.06012104079127312, 0.5103656649589539, 0.8240904211997986, 0.11125598102807999, -0.0036919773556292057, 1.3631155490875244, 1.1344248056411743, -0.41718730330467224, 0.451001912355423, -0.9276931285858154, -0.41998228430747986, 0.41378068923950195, 0.20506083965301514, -0.0010263966396450996, 0.21961762011051178, -1.0072460174560547, -0.24121637642383575, -0.372281938791275, -0.8601779937744141, -0.8287836313247681, -0.4539783298969269, -0.3233964741230011, 1.602103352546692, 0.228213369846344, -0.6499512791633606, -0.1209535300731659, -0.6922030448913574, -0.008157639764249325, -1.005874752998352, 0.1927967518568039, -0.23139935731887817, -0.10690033435821533, -0.20927385985851288, 1.6173436641693115, -0.9028924107551575, -1.9984804391860962, 0.11139441281557083, 0.3097596764564514, -0.29640457034111023, 0.24007590115070343, 1.6806968450546265, 0.517045259475708, 1.4028440713882446, 1.4314895868301392, 1.0418728590011597, -0.6166636943817139, -1.2626208066940308, 0.6319328546524048, 1.0138309001922607, -1.3249576091766357, 0.7438360452651978, 0.02188274636864662, -0.554578959941864, 0.5528857111930847, 1.349628210067749, 0.49125170707702637, -2.0830209255218506, 0.7328031063079834, -0.980559229850769, 0.7986278533935547, 0.6768499612808228, 0.7474042773246765, 0.2911771535873413, 0.7848798036575317, -1.1757044792175293, -1.1039538383483887, -0.8051168918609619, -0.7865466475486755, 1.9524859189987183, -0.2469373643398285, 0.4915657639503479, -0.14543935656547546, -1.3852125406265259, -0.1568405032157898, 0.7285836338996887, 0.41610804200172424, -0.6489714980125427, 0.7850064039230347, -0.6900532245635986, -1.0225235223770142, -1.2764779329299927, -0.5479282140731812, -1.0373115539550781, -0.9518349766731262, 0.9359506964683533, 0.8463494777679443, 0.34900814294815063, 1.850206971168518, 0.6583975553512573, 0.19815155863761902, -2.4973092079162598, 0.9439154863357544, 0.29629161953926086, -0.10267822444438934, 0.7435734272003174, 0.3311691880226135, 1.0448153018951416, -0.06988542526960373, 0.6098455190658569, -2.3517117500305176, 2.184345006942749, -0.16583240032196045, 0.6098081469535828, -0.10770905017852783, -0.2837667167186737, 1.1075613498687744, 0.4020717740058899, 0.5748154520988464, -0.9953608512878418, 0.6086732745170593, -0.6214745044708252, 1.2602399587631226, 0.8840311765670776, -0.9431650638580322, -0.07228516042232513, 1.3400378227233887, 0.36809176206588745, -0.6148048639297485, -0.9823394417762756, -0.9952759742736816, 1.0396933555603027, 1.6112655401229858, -0.15359169244766235, 0.06779773533344269, 0.8741897940635681, 0.6492855548858643, -1.3073970079421997, 0.07559888809919357, -0.7525955438613892, -0.6534868478775024, 1.745107889175415, 1.9999130964279175, -0.3018628656864166, -0.23135913908481598, -0.755205512046814, -1.3164401054382324, 0.7767753005027771, 0.03194773197174072, -0.011219309642910957, 0.7260683178901672, -0.617487907409668, 1.0431432723999023, 0.8107733130455017, 0.8687124848365784, 0.09162915498018265, 0.30159467458724976, 0.41247913241386414, -0.4757833778858185, -1.187482476234436, -0.35042938590049744, -1.1070353984832764, -2.4978346824645996, 0.4860154688358307, -0.029027700424194336, -1.4208799600601196, 0.05424763634800911, -1.0310838222503662, 1.037824273109436, -0.564719557762146, -1.149826169013977, -1.365920901298523, 0.2649816572666168, -0.09533234685659409, 0.8278344869613647, -1.6426434516906738, -0.0062914094887673855, 1.2286429405212402, 0.9838466048240662, -0.7606964707374573, 1.0054447650909424, 0.2286747395992279, 1.0987842082977295, 0.8885005116462708, -0.3273284137248993, 0.5453978776931763, -0.025244109332561493, -1.3128529787063599, 0.5402146577835083, 1.1247961521148682, 0.13644510507583618, 1.4244167804718018, -0.5301163196563721, -0.06360327452421188, 0.45737364888191223, -0.6271291375160217, -0.4956274926662445, -0.5223613381385803, 0.5760306715965271, -0.06021171435713768, -0.8350265026092529, 0.060815516859292984, 0.10115181654691696, -0.2279757559299469, 0.0985063835978508, -1.5694284439086914, -0.13706965744495392, -0.21498315036296844, -0.5839416980743408, -1.2244809865951538, -0.06836780905723572, 1.3557668924331665, -0.5807192325592041, -0.35004642605781555, 0.5439802408218384, 0.25580236315727234, 0.47111228108406067, 0.5170688033103943, -0.6643048524856567, -0.31582483649253845, -0.19080348312854767, -0.38176220655441284, 0.3034936785697937, 1.469025731086731, -0.06212712079286575, -0.950491189956665, 0.6366655230522156, -0.483089804649353, 0.06921285390853882, 1.8263086080551147, 0.007853501476347446, -0.829876720905304, 0.23096568882465363, -0.7175000309944153, 1.9377164840698242, 1.8159183263778687, 1.306647539138794, -0.16368147730827332, -0.8789314031600952, 0.6897778511047363, -0.37541595101356506, -0.4256843030452728, 0.953254759311676, 0.35127511620521545, -0.19878867268562317, -1.382552981376648, 0.7917712330818176, 1.3797506093978882, -0.8717209100723267, -0.8128658533096313, 0.16339194774627686, -0.7809252142906189, 1.1384116411209106, 0.6947256326675415, 0.3131624162197113, 0.2600928246974945, 1.6082733869552612, 0.8478636145591736, -0.3993096351623535, 0.6659961342811584, 0.575504720211029, -0.1867058277130127, -2.171525239944458, -1.262049913406372, 0.2688060998916626, -0.5244799256324768, -1.7164134979248047, 1.3490238189697266, -1.131142497062683, -0.8292931318283081, 0.5817238688468933, 0.13662603497505188, 1.3859657049179077, 0.4050827920436859, 1.470703363418579, 1.9946764707565308, 0.7137328386306763, 0.4588700234889984, 1.2402222156524658, -0.1448635309934616, -0.5195673704147339, 1.7945326566696167, -0.5455443859100342, 0.5391879677772522, 1.0928250551223755, -0.26434263586997986, -1.1454392671585083, -0.7865205407142639, -1.3742574453353882, -0.7608984708786011, 1.1728284358978271, 0.08781640231609344, -1.1779651641845703, 0.3048074245452881, 1.6485861539840698, 0.06413345783948898, -0.4201040267944336, 0.819092333316803, 0.3655446171760559, -0.8886784315109253, -0.05472569167613983, -0.8535917401313782, 0.5031791925430298, -0.20951546728610992, -0.30458375811576843, 0.434615820646286, 0.4357339143753052, 1.340351939201355, 0.031169842928647995, 0.1448492854833603, 1.075154423713684, -1.4386976957321167, 1.6420096158981323, -0.7751607894897461, 0.4005585312843323, -2.3829996585845947, 1.3683831691741943, -0.8241876363754272, 1.9688681364059448, -2.655282735824585, 0.4153043329715729, -0.6023979783058167, -0.5086957216262817, 0.3348868787288666, -0.3326275646686554, -0.00378973875194788, -0.0788186714053154, -1.143320918083191, 0.058954108506441116, -0.6411049365997314, 0.582672655582428, 1.1800955533981323, 1.370696783065796, -1.1226005554199219, -0.2822166681289673, -1.7884639501571655, -0.2184634804725647, -0.6687110662460327, 0.43898096680641174, -2.0877201557159424, -0.25128066539764404, -1.8219189643859863, -2.279038906097412, -1.156627893447876, -0.8260397911071777, 1.1317901611328125, 0.04456533119082451, -0.9170467257499695, 1.2218080759048462, -0.357388436794281, -1.851654052734375, 1.08224618434906, -2.1357171535491943 ]
https://github.com/huggingface/datasets/issues/5186
Incorrect error message when Dataset.from_sql fails and sqlalchemy not installed
Yup ! Alternatively the error can be raised in sql.py before generating the examples ? In `_info` for example
### Describe the bug When calling `Dataset.from_sql` (in my case, with sqlite3), it fails with a message ```ValueError: Please pass `features` or at least one example when writing data``` when I don't have `sqlalchemy` installed. ### Steps to reproduce the bug Make a new sqlite db with `sqlite3` and `pandas` from a remote [URL](https://raw.githubusercontent.com/nytimes/covid-19-data/master/us-states.csv). ```python import sqlite3 import pandas as pd from datasets import Dataset conn = sqlite3.connect('us_covid_data.db') df = pd.read_csv('https://raw.githubusercontent.com/nytimes/covid-19-data/master/us-states.csv') df.to_sql('states', conn, if_exists='replace') ``` Then if you try to query this DB like this: ```python ds = Dataset.from_sql('''SELECT * from states WHERE state=="New York";''', "sqlite:///us_covid_data.db") ``` You run into the error I described above: ```ValueError: Please pass `features` or at least one example when writing data``` However, if you try to pass features, as the error suggests, then you get an error that tells you the underlying problem... ```python from datasets import Dataset, Features, Value features = Features({ 'date': Value('date32'), 'label': Value('string'), 'fips': Value('int32'), 'cases': Value('int32'), 'deaths': Value('int32') }) ds = Dataset.from_sql( '''SELECT * from states WHERE state=="New York";''', "sqlite:///us_covid_data.db", features=features ) ``` Which results in the actual underlying error: `ImportError: Using URI string without sqlalchemy installed.` ### Expected behavior Instead of `ValueError` about needing to pass features, we should provide the actual underlying error about not having SQLAlchemy installed when it isn't found in the environment. ### Environment info - `datasets` version: 2.6.1 - Platform: macOS-10.16-x86_64-i386-64bit - Python version: 3.8.10 - PyArrow version: 10.0.0 - Pandas version: 1.2.5
446
19
Incorrect error message when Dataset.from_sql fails and sqlalchemy not installed ### Describe the bug When calling `Dataset.from_sql` (in my case, with sqlite3), it fails with a message ```ValueError: Please pass `features` or at least one example when writing data``` when I don't have `sqlalchemy` installed. ### Steps to reproduce the bug Make a new sqlite db with `sqlite3` and `pandas` from a remote [URL](https://raw.githubusercontent.com/nytimes/covid-19-data/master/us-states.csv). ```python import sqlite3 import pandas as pd from datasets import Dataset conn = sqlite3.connect('us_covid_data.db') df = pd.read_csv('https://raw.githubusercontent.com/nytimes/covid-19-data/master/us-states.csv') df.to_sql('states', conn, if_exists='replace') ``` Then if you try to query this DB like this: ```python ds = Dataset.from_sql('''SELECT * from states WHERE state=="New York";''', "sqlite:///us_covid_data.db") ``` You run into the error I described above: ```ValueError: Please pass `features` or at least one example when writing data``` However, if you try to pass features, as the error suggests, then you get an error that tells you the underlying problem... ```python from datasets import Dataset, Features, Value features = Features({ 'date': Value('date32'), 'label': Value('string'), 'fips': Value('int32'), 'cases': Value('int32'), 'deaths': Value('int32') }) ds = Dataset.from_sql( '''SELECT * from states WHERE state=="New York";''', "sqlite:///us_covid_data.db", features=features ) ``` Which results in the actual underlying error: `ImportError: Using URI string without sqlalchemy installed.` ### Expected behavior Instead of `ValueError` about needing to pass features, we should provide the actual underlying error about not having SQLAlchemy installed when it isn't found in the environment. ### Environment info - `datasets` version: 2.6.1 - Platform: macOS-10.16-x86_64-i386-64bit - Python version: 3.8.10 - PyArrow version: 10.0.0 - Pandas version: 1.2.5 Yup ! Alternatively the error can be raised in sql.py before generating the examples ? In `_info` for example
[ -1.0802981853485107, -0.9882494807243347, -0.8116843104362488, 1.672055721282959, -0.20419006049633026, -1.1929147243499756, 0.13329216837882996, -1.0065010786056519, 1.692153811454773, -0.7212358117103577, 0.2637934982776642, -1.717377781867981, -0.0015429332852363586, -0.6367207765579224, -0.7803648114204407, -0.7606735229492188, -0.37794405221939087, -0.7628090381622314, 1.132609248161316, 2.3819527626037598, 1.1709486246109009, -1.4173308610916138, 2.690288782119751, 0.7435626983642578, -0.09879518300294876, -1.0576153993606567, 0.5166282653808594, -0.07616609334945679, -1.2514127492904663, -0.45506665110588074, -0.9191556572914124, -0.015975575894117355, -0.5960214734077454, -0.5639625787734985, -0.026248391717672348, 0.49791961908340454, -0.3248213529586792, -0.5512511134147644, -0.5275286436080933, -0.6750781536102295, 0.504628598690033, -0.37635937333106995, 0.8754791021347046, -0.2398155927658081, 1.826882004737854, -0.5474698543548584, 0.3933461308479309, 0.7607199549674988, 1.4264144897460938, 0.1883932203054428, -0.06128005310893059, 0.49426019191741943, 0.31622323393821716, 0.029721256345510483, 0.5753325819969177, 1.2208194732666016, 0.6169546246528625, 0.4370327591896057, 0.8816187381744385, -2.3538851737976074, 1.234646201133728, -1.1373957395553589, 0.31461602449417114, 1.2248774766921997, -0.9819541573524475, 0.3564883768558502, -1.7775413990020752, 0.059676412492990494, 0.5560703277587891, -2.144806146621704, 0.41836318373680115, -1.3071423768997192, -0.3994171619415283, 1.0280132293701172, 0.348949670791626, -1.2450145483016968, 0.1469123810529709, -0.35418039560317993, 1.0616374015808105, 0.36277031898498535, 1.0416566133499146, -1.7111796140670776, 0.01163726020604372, -0.24915102124214172, 0.1478280872106552, -1.2225816249847412, -1.5788944959640503, 0.5170720815658569, 0.7053408026695251, 0.6473454236984253, -0.2497742474079132, 1.111668348312378, -1.0709445476531982, 0.6428737640380859, -0.9972865581512451, -1.7321864366531372, -1.4118015766143799, -2.181337833404541, -2.211300849914551, 0.7027763724327087, -0.4509724974632263, -0.42682185769081116, 2.011701822280884, -0.9247839450836182, -1.8706642389297485, 1.1991159915924072, 0.44304218888282776, -0.016772493720054626, 2.2876906394958496, 0.18222489953041077, -0.7449980974197388, 0.44284507632255554, -0.8315679430961609, 0.7871128916740417, -0.3598552644252777, 1.4523130655288696, 0.4237147867679596, -0.9876388311386108, 1.699738621711731, -0.3265998959541321, 0.695200502872467, -0.6823105812072754, -0.3403610587120056, -0.7255164384841919, 0.3637927770614624, 1.9774127006530762, -0.3072919547557831, 1.4607150554656982, -0.39503076672554016, -1.5952184200286865, -1.5844727754592896, 0.8914790749549866, 0.37911108136177063, -0.7660221457481384, 0.15581034123897552, -0.3772951364517212, 0.1322343498468399, -0.10201656818389893, 1.216239333152771, 1.2737077474594116, 0.6804471611976624, -0.34408271312713623, -0.8597555160522461, 0.17972387373447418, -0.0472843274474144, -0.6051281690597534, -1.7840778827667236, -0.37315210700035095, 0.1813146322965622, 0.6449222564697266, -1.1869163513183594, 1.7056516408920288, 0.8446775078773499, 1.9459019899368286, 1.0181002616882324, -0.3586564362049103, 1.5290359258651733, 0.07705610245466232, 1.9539490938186646, -0.5397557020187378, 0.5750778317451477, -0.4297483265399933, -1.1584943532943726, 0.7930792570114136, -0.3389541208744049, -2.0318756103515625, -0.7359120845794678, -0.8162797093391418, -0.1995946317911148, -0.7889170050621033, 0.864356517791748, -0.3673432469367981, -1.4668070077896118, 0.18230204284191132, -0.7223379611968994, 0.1870713084936142, -1.12875497341156, 0.25531765818595886, 0.7107506394386292, -0.6307111978530884, 0.15130265057086945, -0.28102532029151917, -1.3783674240112305, -0.4656726121902466, 0.5309921503067017, 1.8824409246444702, -0.7633057236671448, 0.8321458101272583, 1.0916553735733032, -0.7335571646690369, 0.07397667318582535, 0.30266261100769043, -0.29186034202575684, 0.7861824631690979, -1.039283037185669, -0.5770101547241211, 1.1814829111099243, -0.2130163609981537, -0.6523888111114502, 1.3685963153839111, 0.8422954678535461, -1.0167843103408813, -0.21057243645191193, -0.187383234500885, -0.8086912035942078, -0.001975158229470253, -1.5477015972137451, -0.09477537125349045, 0.4632534384727478, -1.562572956085205, -0.535731852054596, -0.29494190216064453, 1.2758958339691162, -0.10868962109088898, 1.3825875520706177, -0.2947818636894226, -0.15929721295833588, -0.2163955271244049, -0.4626443386077881, 0.2025085836648941, -0.27036041021347046, -0.6418442130088806, 0.13845570385456085, -0.7748240232467651, 0.4077937602996826, 1.4281773567199707, 0.297002911567688, 0.013756276108324528, 0.6114000678062439, 1.2339541912078857, 0.479840487241745, 0.0485699325799942, -0.8807895183563232, -1.5786277055740356, 1.9311895370483398, -1.4396637678146362, 1.9731158018112183, 0.639989972114563, 0.055149536579847336, -1.8134287595748901, -1.886131763458252, 1.483474850654602, 1.2297694683074951, 2.38254714012146, 0.6476295590400696, 0.415947824716568, -0.8906652331352234, -0.6985368728637695, 0.22746717929840088, -1.0224733352661133, -0.7135785818099976, 0.15560996532440186, 2.45890212059021, 1.8166992664337158, -0.47616443037986755, -0.25424832105636597, -0.9570687413215637, 1.439150094985962, -0.2445734739303589, 0.3313843309879303, 2.0201666355133057, -0.17816154658794403, -1.0194374322891235, 1.3095678091049194, -2.4590086936950684, 0.23053070902824402, 2.025413990020752, 0.17491590976715088, 0.20290298759937286, -1.3810834884643555, -0.7173107862472534, -0.16761428117752075, -0.46577340364456177, -1.26060152053833, 0.4809759259223938, -0.18697573244571686, -0.7346276640892029, -1.4127552509307861, 0.2010534107685089, -1.0445913076400757, -1.6001425981521606, 0.22960104048252106, 1.9858815670013428, 1.9996663331985474, -0.8152692914009094, 1.635474443435669, -0.2585301101207733, 0.29728585481643677, 1.287433385848999, 1.3016730546951294, 3.073601484298706, 1.8774274587631226, -1.2398402690887451, 0.6601831316947937, -0.13659465312957764, -0.5432352423667908, 1.1961801052093506, -1.1446144580841064, 1.1626158952713013, -0.22352398931980133, -1.123111605644226, -1.1597357988357544, 0.893826961517334, 0.5140891075134277, 0.028802182525396347, -0.4504949152469635, 1.1461834907531738, 0.036022864282131195, 1.206734299659729, 0.6591364741325378, -0.3485114574432373, 0.5863185524940491, -0.3473950922489166, -0.5418574213981628, 1.471989631652832, 0.16084837913513184, -1.2881007194519043, -2.159259080886841, -0.17340435087680817, -0.8826181292533875, -0.04688536003232002, -0.55986487865448, -0.9640164375305176, 1.5274189710617065, 0.3210764229297638, -1.1917585134506226, -0.15479786694049835, -0.34044092893600464, -0.4756840765476227, 2.6428020000457764, -1.3692448139190674, -0.36496248841285706, -1.02186918258667, -0.6329174637794495, 1.7034666538238525, -1.0570694208145142, -0.24783092737197876, -1.0742888450622559, -0.5147557854652405, -1.311482548713684, -0.6013467311859131, 0.11761518567800522, -0.7890259623527527, 0.9203047752380371, 0.22808362543582916, -1.2521641254425049, -0.3291788101196289, -0.9275409579277039, 0.9846645593643188, -0.19931797683238983, 0.18023714423179626, 1.924011468887329, 0.34246957302093506, -0.3782697916030884, 0.8464425802230835, 1.0545337200164795, 0.5904451608657837, -0.5716721415519714, 0.3492187559604645, -0.6049968004226685, 0.32694441080093384, -1.468045949935913, 0.2105409801006317, -2.8644087314605713, 0.5924910306930542, 0.06624330580234528, -0.05111301317811012, -0.027623716741800308, -1.4389621019363403, 1.0314396619796753, 2.525982618331909, -1.244498610496521, 0.44242605566978455, 0.30878791213035583, 1.33747398853302, -1.6214327812194824, 0.1454801708459854, -0.36072900891304016, 2.098393440246582, 0.10392060875892639, 1.2418766021728516, -0.4550979733467102, -2.36086106300354, 0.5612366795539856, -1.3263417482376099, -1.0965584516525269, 0.7112340927124023, -0.9478579759597778, 0.17954714596271515, -1.4922144412994385, -0.2696237564086914, -0.9085248708724976, -1.1841837167739868, 0.7443477511405945, 0.13348941504955292, 0.287087619304657, -0.6107144951820374, 0.4266405403614044, -2.0090622901916504, -1.4025756120681763, -0.1486208736896515, -0.9328345656394958, 0.5119632482528687, -0.350189745426178, 0.6532498002052307, -0.17159408330917358, 0.010479112155735493, 0.3153645694255829, 1.4737321138381958, 3.3664004802703857, 0.1246289387345314, 0.33403193950653076, -0.15847346186637878, -0.8949676156044006, 1.4329744577407837, 0.9249007701873779, -0.19860367476940155, -0.4747053384780884, -1.1642695665359497, 1.33156156539917, 1.9786885976791382, 0.9903722405433655, 0.02377418801188469, -0.7831239104270935, -0.7792662382125854, 0.04933658242225647, 0.06012104079127312, 0.5103656649589539, 0.8240904211997986, 0.11125598102807999, -0.0036919773556292057, 1.3631155490875244, 1.1344248056411743, -0.41718730330467224, 0.451001912355423, -0.9276931285858154, -0.41998228430747986, 0.41378068923950195, 0.20506083965301514, -0.0010263966396450996, 0.21961762011051178, -1.0072460174560547, -0.24121637642383575, -0.372281938791275, -0.8601779937744141, -0.8287836313247681, -0.4539783298969269, -0.3233964741230011, 1.602103352546692, 0.228213369846344, -0.6499512791633606, -0.1209535300731659, -0.6922030448913574, -0.008157639764249325, -1.005874752998352, 0.1927967518568039, -0.23139935731887817, -0.10690033435821533, -0.20927385985851288, 1.6173436641693115, -0.9028924107551575, -1.9984804391860962, 0.11139441281557083, 0.3097596764564514, -0.29640457034111023, 0.24007590115070343, 1.6806968450546265, 0.517045259475708, 1.4028440713882446, 1.4314895868301392, 1.0418728590011597, -0.6166636943817139, -1.2626208066940308, 0.6319328546524048, 1.0138309001922607, -1.3249576091766357, 0.7438360452651978, 0.02188274636864662, -0.554578959941864, 0.5528857111930847, 1.349628210067749, 0.49125170707702637, -2.0830209255218506, 0.7328031063079834, -0.980559229850769, 0.7986278533935547, 0.6768499612808228, 0.7474042773246765, 0.2911771535873413, 0.7848798036575317, -1.1757044792175293, -1.1039538383483887, -0.8051168918609619, -0.7865466475486755, 1.9524859189987183, -0.2469373643398285, 0.4915657639503479, -0.14543935656547546, -1.3852125406265259, -0.1568405032157898, 0.7285836338996887, 0.41610804200172424, -0.6489714980125427, 0.7850064039230347, -0.6900532245635986, -1.0225235223770142, -1.2764779329299927, -0.5479282140731812, -1.0373115539550781, -0.9518349766731262, 0.9359506964683533, 0.8463494777679443, 0.34900814294815063, 1.850206971168518, 0.6583975553512573, 0.19815155863761902, -2.4973092079162598, 0.9439154863357544, 0.29629161953926086, -0.10267822444438934, 0.7435734272003174, 0.3311691880226135, 1.0448153018951416, -0.06988542526960373, 0.6098455190658569, -2.3517117500305176, 2.184345006942749, -0.16583240032196045, 0.6098081469535828, -0.10770905017852783, -0.2837667167186737, 1.1075613498687744, 0.4020717740058899, 0.5748154520988464, -0.9953608512878418, 0.6086732745170593, -0.6214745044708252, 1.2602399587631226, 0.8840311765670776, -0.9431650638580322, -0.07228516042232513, 1.3400378227233887, 0.36809176206588745, -0.6148048639297485, -0.9823394417762756, -0.9952759742736816, 1.0396933555603027, 1.6112655401229858, -0.15359169244766235, 0.06779773533344269, 0.8741897940635681, 0.6492855548858643, -1.3073970079421997, 0.07559888809919357, -0.7525955438613892, -0.6534868478775024, 1.745107889175415, 1.9999130964279175, -0.3018628656864166, -0.23135913908481598, -0.755205512046814, -1.3164401054382324, 0.7767753005027771, 0.03194773197174072, -0.011219309642910957, 0.7260683178901672, -0.617487907409668, 1.0431432723999023, 0.8107733130455017, 0.8687124848365784, 0.09162915498018265, 0.30159467458724976, 0.41247913241386414, -0.4757833778858185, -1.187482476234436, -0.35042938590049744, -1.1070353984832764, -2.4978346824645996, 0.4860154688358307, -0.029027700424194336, -1.4208799600601196, 0.05424763634800911, -1.0310838222503662, 1.037824273109436, -0.564719557762146, -1.149826169013977, -1.365920901298523, 0.2649816572666168, -0.09533234685659409, 0.8278344869613647, -1.6426434516906738, -0.0062914094887673855, 1.2286429405212402, 0.9838466048240662, -0.7606964707374573, 1.0054447650909424, 0.2286747395992279, 1.0987842082977295, 0.8885005116462708, -0.3273284137248993, 0.5453978776931763, -0.025244109332561493, -1.3128529787063599, 0.5402146577835083, 1.1247961521148682, 0.13644510507583618, 1.4244167804718018, -0.5301163196563721, -0.06360327452421188, 0.45737364888191223, -0.6271291375160217, -0.4956274926662445, -0.5223613381385803, 0.5760306715965271, -0.06021171435713768, -0.8350265026092529, 0.060815516859292984, 0.10115181654691696, -0.2279757559299469, 0.0985063835978508, -1.5694284439086914, -0.13706965744495392, -0.21498315036296844, -0.5839416980743408, -1.2244809865951538, -0.06836780905723572, 1.3557668924331665, -0.5807192325592041, -0.35004642605781555, 0.5439802408218384, 0.25580236315727234, 0.47111228108406067, 0.5170688033103943, -0.6643048524856567, -0.31582483649253845, -0.19080348312854767, -0.38176220655441284, 0.3034936785697937, 1.469025731086731, -0.06212712079286575, -0.950491189956665, 0.6366655230522156, -0.483089804649353, 0.06921285390853882, 1.8263086080551147, 0.007853501476347446, -0.829876720905304, 0.23096568882465363, -0.7175000309944153, 1.9377164840698242, 1.8159183263778687, 1.306647539138794, -0.16368147730827332, -0.8789314031600952, 0.6897778511047363, -0.37541595101356506, -0.4256843030452728, 0.953254759311676, 0.35127511620521545, -0.19878867268562317, -1.382552981376648, 0.7917712330818176, 1.3797506093978882, -0.8717209100723267, -0.8128658533096313, 0.16339194774627686, -0.7809252142906189, 1.1384116411209106, 0.6947256326675415, 0.3131624162197113, 0.2600928246974945, 1.6082733869552612, 0.8478636145591736, -0.3993096351623535, 0.6659961342811584, 0.575504720211029, -0.1867058277130127, -2.171525239944458, -1.262049913406372, 0.2688060998916626, -0.5244799256324768, -1.7164134979248047, 1.3490238189697266, -1.131142497062683, -0.8292931318283081, 0.5817238688468933, 0.13662603497505188, 1.3859657049179077, 0.4050827920436859, 1.470703363418579, 1.9946764707565308, 0.7137328386306763, 0.4588700234889984, 1.2402222156524658, -0.1448635309934616, -0.5195673704147339, 1.7945326566696167, -0.5455443859100342, 0.5391879677772522, 1.0928250551223755, -0.26434263586997986, -1.1454392671585083, -0.7865205407142639, -1.3742574453353882, -0.7608984708786011, 1.1728284358978271, 0.08781640231609344, -1.1779651641845703, 0.3048074245452881, 1.6485861539840698, 0.06413345783948898, -0.4201040267944336, 0.819092333316803, 0.3655446171760559, -0.8886784315109253, -0.05472569167613983, -0.8535917401313782, 0.5031791925430298, -0.20951546728610992, -0.30458375811576843, 0.434615820646286, 0.4357339143753052, 1.340351939201355, 0.031169842928647995, 0.1448492854833603, 1.075154423713684, -1.4386976957321167, 1.6420096158981323, -0.7751607894897461, 0.4005585312843323, -2.3829996585845947, 1.3683831691741943, -0.8241876363754272, 1.9688681364059448, -2.655282735824585, 0.4153043329715729, -0.6023979783058167, -0.5086957216262817, 0.3348868787288666, -0.3326275646686554, -0.00378973875194788, -0.0788186714053154, -1.143320918083191, 0.058954108506441116, -0.6411049365997314, 0.582672655582428, 1.1800955533981323, 1.370696783065796, -1.1226005554199219, -0.2822166681289673, -1.7884639501571655, -0.2184634804725647, -0.6687110662460327, 0.43898096680641174, -2.0877201557159424, -0.25128066539764404, -1.8219189643859863, -2.279038906097412, -1.156627893447876, -0.8260397911071777, 1.1317901611328125, 0.04456533119082451, -0.9170467257499695, 1.2218080759048462, -0.357388436794281, -1.851654052734375, 1.08224618434906, -2.1357171535491943 ]
https://github.com/huggingface/datasets/issues/5186
Incorrect error message when Dataset.from_sql fails and sqlalchemy not installed
yea @lhoestq that would probably be good. The 2nd error is useless if the 1st error is the real reason it failed.
### Describe the bug When calling `Dataset.from_sql` (in my case, with sqlite3), it fails with a message ```ValueError: Please pass `features` or at least one example when writing data``` when I don't have `sqlalchemy` installed. ### Steps to reproduce the bug Make a new sqlite db with `sqlite3` and `pandas` from a remote [URL](https://raw.githubusercontent.com/nytimes/covid-19-data/master/us-states.csv). ```python import sqlite3 import pandas as pd from datasets import Dataset conn = sqlite3.connect('us_covid_data.db') df = pd.read_csv('https://raw.githubusercontent.com/nytimes/covid-19-data/master/us-states.csv') df.to_sql('states', conn, if_exists='replace') ``` Then if you try to query this DB like this: ```python ds = Dataset.from_sql('''SELECT * from states WHERE state=="New York";''', "sqlite:///us_covid_data.db") ``` You run into the error I described above: ```ValueError: Please pass `features` or at least one example when writing data``` However, if you try to pass features, as the error suggests, then you get an error that tells you the underlying problem... ```python from datasets import Dataset, Features, Value features = Features({ 'date': Value('date32'), 'label': Value('string'), 'fips': Value('int32'), 'cases': Value('int32'), 'deaths': Value('int32') }) ds = Dataset.from_sql( '''SELECT * from states WHERE state=="New York";''', "sqlite:///us_covid_data.db", features=features ) ``` Which results in the actual underlying error: `ImportError: Using URI string without sqlalchemy installed.` ### Expected behavior Instead of `ValueError` about needing to pass features, we should provide the actual underlying error about not having SQLAlchemy installed when it isn't found in the environment. ### Environment info - `datasets` version: 2.6.1 - Platform: macOS-10.16-x86_64-i386-64bit - Python version: 3.8.10 - PyArrow version: 10.0.0 - Pandas version: 1.2.5
446
22
Incorrect error message when Dataset.from_sql fails and sqlalchemy not installed ### Describe the bug When calling `Dataset.from_sql` (in my case, with sqlite3), it fails with a message ```ValueError: Please pass `features` or at least one example when writing data``` when I don't have `sqlalchemy` installed. ### Steps to reproduce the bug Make a new sqlite db with `sqlite3` and `pandas` from a remote [URL](https://raw.githubusercontent.com/nytimes/covid-19-data/master/us-states.csv). ```python import sqlite3 import pandas as pd from datasets import Dataset conn = sqlite3.connect('us_covid_data.db') df = pd.read_csv('https://raw.githubusercontent.com/nytimes/covid-19-data/master/us-states.csv') df.to_sql('states', conn, if_exists='replace') ``` Then if you try to query this DB like this: ```python ds = Dataset.from_sql('''SELECT * from states WHERE state=="New York";''', "sqlite:///us_covid_data.db") ``` You run into the error I described above: ```ValueError: Please pass `features` or at least one example when writing data``` However, if you try to pass features, as the error suggests, then you get an error that tells you the underlying problem... ```python from datasets import Dataset, Features, Value features = Features({ 'date': Value('date32'), 'label': Value('string'), 'fips': Value('int32'), 'cases': Value('int32'), 'deaths': Value('int32') }) ds = Dataset.from_sql( '''SELECT * from states WHERE state=="New York";''', "sqlite:///us_covid_data.db", features=features ) ``` Which results in the actual underlying error: `ImportError: Using URI string without sqlalchemy installed.` ### Expected behavior Instead of `ValueError` about needing to pass features, we should provide the actual underlying error about not having SQLAlchemy installed when it isn't found in the environment. ### Environment info - `datasets` version: 2.6.1 - Platform: macOS-10.16-x86_64-i386-64bit - Python version: 3.8.10 - PyArrow version: 10.0.0 - Pandas version: 1.2.5 yea @lhoestq that would probably be good. The 2nd error is useless if the 1st error is the real reason it failed.
[ -1.0802981853485107, -0.9882494807243347, -0.8116843104362488, 1.672055721282959, -0.20419006049633026, -1.1929147243499756, 0.13329216837882996, -1.0065010786056519, 1.692153811454773, -0.7212358117103577, 0.2637934982776642, -1.717377781867981, -0.0015429332852363586, -0.6367207765579224, -0.7803648114204407, -0.7606735229492188, -0.37794405221939087, -0.7628090381622314, 1.132609248161316, 2.3819527626037598, 1.1709486246109009, -1.4173308610916138, 2.690288782119751, 0.7435626983642578, -0.09879518300294876, -1.0576153993606567, 0.5166282653808594, -0.07616609334945679, -1.2514127492904663, -0.45506665110588074, -0.9191556572914124, -0.015975575894117355, -0.5960214734077454, -0.5639625787734985, -0.026248391717672348, 0.49791961908340454, -0.3248213529586792, -0.5512511134147644, -0.5275286436080933, -0.6750781536102295, 0.504628598690033, -0.37635937333106995, 0.8754791021347046, -0.2398155927658081, 1.826882004737854, -0.5474698543548584, 0.3933461308479309, 0.7607199549674988, 1.4264144897460938, 0.1883932203054428, -0.06128005310893059, 0.49426019191741943, 0.31622323393821716, 0.029721256345510483, 0.5753325819969177, 1.2208194732666016, 0.6169546246528625, 0.4370327591896057, 0.8816187381744385, -2.3538851737976074, 1.234646201133728, -1.1373957395553589, 0.31461602449417114, 1.2248774766921997, -0.9819541573524475, 0.3564883768558502, -1.7775413990020752, 0.059676412492990494, 0.5560703277587891, -2.144806146621704, 0.41836318373680115, -1.3071423768997192, -0.3994171619415283, 1.0280132293701172, 0.348949670791626, -1.2450145483016968, 0.1469123810529709, -0.35418039560317993, 1.0616374015808105, 0.36277031898498535, 1.0416566133499146, -1.7111796140670776, 0.01163726020604372, -0.24915102124214172, 0.1478280872106552, -1.2225816249847412, -1.5788944959640503, 0.5170720815658569, 0.7053408026695251, 0.6473454236984253, -0.2497742474079132, 1.111668348312378, -1.0709445476531982, 0.6428737640380859, -0.9972865581512451, -1.7321864366531372, -1.4118015766143799, -2.181337833404541, -2.211300849914551, 0.7027763724327087, -0.4509724974632263, -0.42682185769081116, 2.011701822280884, -0.9247839450836182, -1.8706642389297485, 1.1991159915924072, 0.44304218888282776, -0.016772493720054626, 2.2876906394958496, 0.18222489953041077, -0.7449980974197388, 0.44284507632255554, -0.8315679430961609, 0.7871128916740417, -0.3598552644252777, 1.4523130655288696, 0.4237147867679596, -0.9876388311386108, 1.699738621711731, -0.3265998959541321, 0.695200502872467, -0.6823105812072754, -0.3403610587120056, -0.7255164384841919, 0.3637927770614624, 1.9774127006530762, -0.3072919547557831, 1.4607150554656982, -0.39503076672554016, -1.5952184200286865, -1.5844727754592896, 0.8914790749549866, 0.37911108136177063, -0.7660221457481384, 0.15581034123897552, -0.3772951364517212, 0.1322343498468399, -0.10201656818389893, 1.216239333152771, 1.2737077474594116, 0.6804471611976624, -0.34408271312713623, -0.8597555160522461, 0.17972387373447418, -0.0472843274474144, -0.6051281690597534, -1.7840778827667236, -0.37315210700035095, 0.1813146322965622, 0.6449222564697266, -1.1869163513183594, 1.7056516408920288, 0.8446775078773499, 1.9459019899368286, 1.0181002616882324, -0.3586564362049103, 1.5290359258651733, 0.07705610245466232, 1.9539490938186646, -0.5397557020187378, 0.5750778317451477, -0.4297483265399933, -1.1584943532943726, 0.7930792570114136, -0.3389541208744049, -2.0318756103515625, -0.7359120845794678, -0.8162797093391418, -0.1995946317911148, -0.7889170050621033, 0.864356517791748, -0.3673432469367981, -1.4668070077896118, 0.18230204284191132, -0.7223379611968994, 0.1870713084936142, -1.12875497341156, 0.25531765818595886, 0.7107506394386292, -0.6307111978530884, 0.15130265057086945, -0.28102532029151917, -1.3783674240112305, -0.4656726121902466, 0.5309921503067017, 1.8824409246444702, -0.7633057236671448, 0.8321458101272583, 1.0916553735733032, -0.7335571646690369, 0.07397667318582535, 0.30266261100769043, -0.29186034202575684, 0.7861824631690979, -1.039283037185669, -0.5770101547241211, 1.1814829111099243, -0.2130163609981537, -0.6523888111114502, 1.3685963153839111, 0.8422954678535461, -1.0167843103408813, -0.21057243645191193, -0.187383234500885, -0.8086912035942078, -0.001975158229470253, -1.5477015972137451, -0.09477537125349045, 0.4632534384727478, -1.562572956085205, -0.535731852054596, -0.29494190216064453, 1.2758958339691162, -0.10868962109088898, 1.3825875520706177, -0.2947818636894226, -0.15929721295833588, -0.2163955271244049, -0.4626443386077881, 0.2025085836648941, -0.27036041021347046, -0.6418442130088806, 0.13845570385456085, -0.7748240232467651, 0.4077937602996826, 1.4281773567199707, 0.297002911567688, 0.013756276108324528, 0.6114000678062439, 1.2339541912078857, 0.479840487241745, 0.0485699325799942, -0.8807895183563232, -1.5786277055740356, 1.9311895370483398, -1.4396637678146362, 1.9731158018112183, 0.639989972114563, 0.055149536579847336, -1.8134287595748901, -1.886131763458252, 1.483474850654602, 1.2297694683074951, 2.38254714012146, 0.6476295590400696, 0.415947824716568, -0.8906652331352234, -0.6985368728637695, 0.22746717929840088, -1.0224733352661133, -0.7135785818099976, 0.15560996532440186, 2.45890212059021, 1.8166992664337158, -0.47616443037986755, -0.25424832105636597, -0.9570687413215637, 1.439150094985962, -0.2445734739303589, 0.3313843309879303, 2.0201666355133057, -0.17816154658794403, -1.0194374322891235, 1.3095678091049194, -2.4590086936950684, 0.23053070902824402, 2.025413990020752, 0.17491590976715088, 0.20290298759937286, -1.3810834884643555, -0.7173107862472534, -0.16761428117752075, -0.46577340364456177, -1.26060152053833, 0.4809759259223938, -0.18697573244571686, -0.7346276640892029, -1.4127552509307861, 0.2010534107685089, -1.0445913076400757, -1.6001425981521606, 0.22960104048252106, 1.9858815670013428, 1.9996663331985474, -0.8152692914009094, 1.635474443435669, -0.2585301101207733, 0.29728585481643677, 1.287433385848999, 1.3016730546951294, 3.073601484298706, 1.8774274587631226, -1.2398402690887451, 0.6601831316947937, -0.13659465312957764, -0.5432352423667908, 1.1961801052093506, -1.1446144580841064, 1.1626158952713013, -0.22352398931980133, -1.123111605644226, -1.1597357988357544, 0.893826961517334, 0.5140891075134277, 0.028802182525396347, -0.4504949152469635, 1.1461834907531738, 0.036022864282131195, 1.206734299659729, 0.6591364741325378, -0.3485114574432373, 0.5863185524940491, -0.3473950922489166, -0.5418574213981628, 1.471989631652832, 0.16084837913513184, -1.2881007194519043, -2.159259080886841, -0.17340435087680817, -0.8826181292533875, -0.04688536003232002, -0.55986487865448, -0.9640164375305176, 1.5274189710617065, 0.3210764229297638, -1.1917585134506226, -0.15479786694049835, -0.34044092893600464, -0.4756840765476227, 2.6428020000457764, -1.3692448139190674, -0.36496248841285706, -1.02186918258667, -0.6329174637794495, 1.7034666538238525, -1.0570694208145142, -0.24783092737197876, -1.0742888450622559, -0.5147557854652405, -1.311482548713684, -0.6013467311859131, 0.11761518567800522, -0.7890259623527527, 0.9203047752380371, 0.22808362543582916, -1.2521641254425049, -0.3291788101196289, -0.9275409579277039, 0.9846645593643188, -0.19931797683238983, 0.18023714423179626, 1.924011468887329, 0.34246957302093506, -0.3782697916030884, 0.8464425802230835, 1.0545337200164795, 0.5904451608657837, -0.5716721415519714, 0.3492187559604645, -0.6049968004226685, 0.32694441080093384, -1.468045949935913, 0.2105409801006317, -2.8644087314605713, 0.5924910306930542, 0.06624330580234528, -0.05111301317811012, -0.027623716741800308, -1.4389621019363403, 1.0314396619796753, 2.525982618331909, -1.244498610496521, 0.44242605566978455, 0.30878791213035583, 1.33747398853302, -1.6214327812194824, 0.1454801708459854, -0.36072900891304016, 2.098393440246582, 0.10392060875892639, 1.2418766021728516, -0.4550979733467102, -2.36086106300354, 0.5612366795539856, -1.3263417482376099, -1.0965584516525269, 0.7112340927124023, -0.9478579759597778, 0.17954714596271515, -1.4922144412994385, -0.2696237564086914, -0.9085248708724976, -1.1841837167739868, 0.7443477511405945, 0.13348941504955292, 0.287087619304657, -0.6107144951820374, 0.4266405403614044, -2.0090622901916504, -1.4025756120681763, -0.1486208736896515, -0.9328345656394958, 0.5119632482528687, -0.350189745426178, 0.6532498002052307, -0.17159408330917358, 0.010479112155735493, 0.3153645694255829, 1.4737321138381958, 3.3664004802703857, 0.1246289387345314, 0.33403193950653076, -0.15847346186637878, -0.8949676156044006, 1.4329744577407837, 0.9249007701873779, -0.19860367476940155, -0.4747053384780884, -1.1642695665359497, 1.33156156539917, 1.9786885976791382, 0.9903722405433655, 0.02377418801188469, -0.7831239104270935, -0.7792662382125854, 0.04933658242225647, 0.06012104079127312, 0.5103656649589539, 0.8240904211997986, 0.11125598102807999, -0.0036919773556292057, 1.3631155490875244, 1.1344248056411743, -0.41718730330467224, 0.451001912355423, -0.9276931285858154, -0.41998228430747986, 0.41378068923950195, 0.20506083965301514, -0.0010263966396450996, 0.21961762011051178, -1.0072460174560547, -0.24121637642383575, -0.372281938791275, -0.8601779937744141, -0.8287836313247681, -0.4539783298969269, -0.3233964741230011, 1.602103352546692, 0.228213369846344, -0.6499512791633606, -0.1209535300731659, -0.6922030448913574, -0.008157639764249325, -1.005874752998352, 0.1927967518568039, -0.23139935731887817, -0.10690033435821533, -0.20927385985851288, 1.6173436641693115, -0.9028924107551575, -1.9984804391860962, 0.11139441281557083, 0.3097596764564514, -0.29640457034111023, 0.24007590115070343, 1.6806968450546265, 0.517045259475708, 1.4028440713882446, 1.4314895868301392, 1.0418728590011597, -0.6166636943817139, -1.2626208066940308, 0.6319328546524048, 1.0138309001922607, -1.3249576091766357, 0.7438360452651978, 0.02188274636864662, -0.554578959941864, 0.5528857111930847, 1.349628210067749, 0.49125170707702637, -2.0830209255218506, 0.7328031063079834, -0.980559229850769, 0.7986278533935547, 0.6768499612808228, 0.7474042773246765, 0.2911771535873413, 0.7848798036575317, -1.1757044792175293, -1.1039538383483887, -0.8051168918609619, -0.7865466475486755, 1.9524859189987183, -0.2469373643398285, 0.4915657639503479, -0.14543935656547546, -1.3852125406265259, -0.1568405032157898, 0.7285836338996887, 0.41610804200172424, -0.6489714980125427, 0.7850064039230347, -0.6900532245635986, -1.0225235223770142, -1.2764779329299927, -0.5479282140731812, -1.0373115539550781, -0.9518349766731262, 0.9359506964683533, 0.8463494777679443, 0.34900814294815063, 1.850206971168518, 0.6583975553512573, 0.19815155863761902, -2.4973092079162598, 0.9439154863357544, 0.29629161953926086, -0.10267822444438934, 0.7435734272003174, 0.3311691880226135, 1.0448153018951416, -0.06988542526960373, 0.6098455190658569, -2.3517117500305176, 2.184345006942749, -0.16583240032196045, 0.6098081469535828, -0.10770905017852783, -0.2837667167186737, 1.1075613498687744, 0.4020717740058899, 0.5748154520988464, -0.9953608512878418, 0.6086732745170593, -0.6214745044708252, 1.2602399587631226, 0.8840311765670776, -0.9431650638580322, -0.07228516042232513, 1.3400378227233887, 0.36809176206588745, -0.6148048639297485, -0.9823394417762756, -0.9952759742736816, 1.0396933555603027, 1.6112655401229858, -0.15359169244766235, 0.06779773533344269, 0.8741897940635681, 0.6492855548858643, -1.3073970079421997, 0.07559888809919357, -0.7525955438613892, -0.6534868478775024, 1.745107889175415, 1.9999130964279175, -0.3018628656864166, -0.23135913908481598, -0.755205512046814, -1.3164401054382324, 0.7767753005027771, 0.03194773197174072, -0.011219309642910957, 0.7260683178901672, -0.617487907409668, 1.0431432723999023, 0.8107733130455017, 0.8687124848365784, 0.09162915498018265, 0.30159467458724976, 0.41247913241386414, -0.4757833778858185, -1.187482476234436, -0.35042938590049744, -1.1070353984832764, -2.4978346824645996, 0.4860154688358307, -0.029027700424194336, -1.4208799600601196, 0.05424763634800911, -1.0310838222503662, 1.037824273109436, -0.564719557762146, -1.149826169013977, -1.365920901298523, 0.2649816572666168, -0.09533234685659409, 0.8278344869613647, -1.6426434516906738, -0.0062914094887673855, 1.2286429405212402, 0.9838466048240662, -0.7606964707374573, 1.0054447650909424, 0.2286747395992279, 1.0987842082977295, 0.8885005116462708, -0.3273284137248993, 0.5453978776931763, -0.025244109332561493, -1.3128529787063599, 0.5402146577835083, 1.1247961521148682, 0.13644510507583618, 1.4244167804718018, -0.5301163196563721, -0.06360327452421188, 0.45737364888191223, -0.6271291375160217, -0.4956274926662445, -0.5223613381385803, 0.5760306715965271, -0.06021171435713768, -0.8350265026092529, 0.060815516859292984, 0.10115181654691696, -0.2279757559299469, 0.0985063835978508, -1.5694284439086914, -0.13706965744495392, -0.21498315036296844, -0.5839416980743408, -1.2244809865951538, -0.06836780905723572, 1.3557668924331665, -0.5807192325592041, -0.35004642605781555, 0.5439802408218384, 0.25580236315727234, 0.47111228108406067, 0.5170688033103943, -0.6643048524856567, -0.31582483649253845, -0.19080348312854767, -0.38176220655441284, 0.3034936785697937, 1.469025731086731, -0.06212712079286575, -0.950491189956665, 0.6366655230522156, -0.483089804649353, 0.06921285390853882, 1.8263086080551147, 0.007853501476347446, -0.829876720905304, 0.23096568882465363, -0.7175000309944153, 1.9377164840698242, 1.8159183263778687, 1.306647539138794, -0.16368147730827332, -0.8789314031600952, 0.6897778511047363, -0.37541595101356506, -0.4256843030452728, 0.953254759311676, 0.35127511620521545, -0.19878867268562317, -1.382552981376648, 0.7917712330818176, 1.3797506093978882, -0.8717209100723267, -0.8128658533096313, 0.16339194774627686, -0.7809252142906189, 1.1384116411209106, 0.6947256326675415, 0.3131624162197113, 0.2600928246974945, 1.6082733869552612, 0.8478636145591736, -0.3993096351623535, 0.6659961342811584, 0.575504720211029, -0.1867058277130127, -2.171525239944458, -1.262049913406372, 0.2688060998916626, -0.5244799256324768, -1.7164134979248047, 1.3490238189697266, -1.131142497062683, -0.8292931318283081, 0.5817238688468933, 0.13662603497505188, 1.3859657049179077, 0.4050827920436859, 1.470703363418579, 1.9946764707565308, 0.7137328386306763, 0.4588700234889984, 1.2402222156524658, -0.1448635309934616, -0.5195673704147339, 1.7945326566696167, -0.5455443859100342, 0.5391879677772522, 1.0928250551223755, -0.26434263586997986, -1.1454392671585083, -0.7865205407142639, -1.3742574453353882, -0.7608984708786011, 1.1728284358978271, 0.08781640231609344, -1.1779651641845703, 0.3048074245452881, 1.6485861539840698, 0.06413345783948898, -0.4201040267944336, 0.819092333316803, 0.3655446171760559, -0.8886784315109253, -0.05472569167613983, -0.8535917401313782, 0.5031791925430298, -0.20951546728610992, -0.30458375811576843, 0.434615820646286, 0.4357339143753052, 1.340351939201355, 0.031169842928647995, 0.1448492854833603, 1.075154423713684, -1.4386976957321167, 1.6420096158981323, -0.7751607894897461, 0.4005585312843323, -2.3829996585845947, 1.3683831691741943, -0.8241876363754272, 1.9688681364059448, -2.655282735824585, 0.4153043329715729, -0.6023979783058167, -0.5086957216262817, 0.3348868787288666, -0.3326275646686554, -0.00378973875194788, -0.0788186714053154, -1.143320918083191, 0.058954108506441116, -0.6411049365997314, 0.582672655582428, 1.1800955533981323, 1.370696783065796, -1.1226005554199219, -0.2822166681289673, -1.7884639501571655, -0.2184634804725647, -0.6687110662460327, 0.43898096680641174, -2.0877201557159424, -0.25128066539764404, -1.8219189643859863, -2.279038906097412, -1.156627893447876, -0.8260397911071777, 1.1317901611328125, 0.04456533119082451, -0.9170467257499695, 1.2218080759048462, -0.357388436794281, -1.851654052734375, 1.08224618434906, -2.1357171535491943 ]
https://github.com/huggingface/datasets/issues/5182
Add notebook / other resource links to the task-specific data loading guides
Yea this would be great! We would need an object detection tutorial notebook too if it doesn't already exist there.
Does it make sense to include links to notebooks / scripts that show how to use a dataset for training / fine-tuning a model? For example, here in [https://huggingface.co/docs/datasets/image_classification] we could include a mention of https://github.com/huggingface/notebooks/blob/main/examples/image_classification.ipynb. Applies to https://huggingface.co/docs/datasets/object_detection as well. Cc: @osanseviero @nateraw
447
20
Add notebook / other resource links to the task-specific data loading guides Does it make sense to include links to notebooks / scripts that show how to use a dataset for training / fine-tuning a model? For example, here in [https://huggingface.co/docs/datasets/image_classification] we could include a mention of https://github.com/huggingface/notebooks/blob/main/examples/image_classification.ipynb. Applies to https://huggingface.co/docs/datasets/object_detection as well. Cc: @osanseviero @nateraw Yea this would be great! We would need an object detection tutorial notebook too if it doesn't already exist there.
[ -1.177746295928955, -0.9205332398414612, -0.8563430309295654, 1.476345181465149, -0.06873856484889984, -1.3601651191711426, 0.00333363376557827, -1.005797028541565, 1.60701584815979, -0.6575381755828857, 0.280807763338089, -1.6734625101089478, -0.10995084792375565, -0.5594936609268188, -0.6875001192092896, -0.8547836542129517, -0.3232615292072296, -0.8521470427513123, 1.0542023181915283, 2.53218936920166, 1.1974270343780518, -1.3862842321395874, 2.6959261894226074, 0.6482342481613159, -0.23977190256118774, -1.1178041696548462, 0.5904107689857483, 0.05115121230483055, -1.1895160675048828, -0.4708949029445648, -0.9860575199127197, 0.11066842079162598, -0.5521669983863831, -0.35776737332344055, 0.07327324897050858, 0.4103686809539795, -0.15044017136096954, -0.20752549171447754, -0.5921142101287842, -0.660537600517273, 0.47052112221717834, -0.21150322258472443, 0.9600970149040222, -0.35969457030296326, 1.7317869663238525, -0.539286732673645, 0.27102452516555786, 0.5782094597816467, 1.4114789962768555, 0.13112571835517883, 0.11047709733247757, 0.10788378119468689, 0.32914602756500244, -0.0884677991271019, 0.5036894679069519, 1.2007668018341064, 0.5086634159088135, 0.5518659353256226, 0.4983541965484619, -2.2408292293548584, 1.3367865085601807, -0.9046809673309326, 0.25139617919921875, 1.4330476522445679, -0.8369839787483215, 0.3587941527366638, -1.7314070463180542, -0.07299278676509857, 0.5443959832191467, -2.3113741874694824, 0.16069871187210083, -1.1590179204940796, -0.6192709803581238, 0.9077233076095581, 0.30172061920166016, -1.2545050382614136, 0.238225519657135, -0.41847318410873413, 1.075324296951294, 0.5517012476921082, 1.2252461910247803, -1.6107043027877808, 0.10582287609577179, -0.170393168926239, -0.0050695110112428665, -1.3750160932540894, -1.5185514688491821, 0.5182668566703796, 0.661851167678833, 0.8070623874664307, -0.020448796451091766, 0.8346660733222961, -0.9240508079528809, 0.9378823041915894, -0.7819334864616394, -1.6368733644485474, -1.3192782402038574, -2.4068808555603027, -2.3820900917053223, 0.8333525061607361, -0.5339946746826172, -0.4448273181915283, 1.9021382331848145, -0.9506014585494995, -1.8839037418365479, 1.0871047973632812, 0.3393724262714386, 0.047489605844020844, 2.4346492290496826, 0.25858548283576965, -0.670792281627655, 0.43610310554504395, -0.749680757522583, 0.902451753616333, -0.3959074914455414, 1.3844330310821533, 0.5784794092178345, -0.9341117739677429, 1.604167103767395, -0.5217209458351135, 0.5517390370368958, -0.7111315727233887, -0.5272698402404785, -0.870533287525177, 0.3231317698955536, 1.8817652463912964, -0.36719247698783875, 1.5948538780212402, -0.34841594099998474, -1.5798312425613403, -1.609136700630188, 0.8233974575996399, 0.5622273683547974, -0.8722231984138489, 0.15358705818653107, -0.5129979252815247, 0.11030831187963486, -0.020345699042081833, 1.0527971982955933, 1.1330727338790894, 0.5961008071899414, -0.25230544805526733, -0.8404566049575806, 0.34880319237709045, -0.035797055810689926, -0.6668597459793091, -1.8678741455078125, -0.2982366681098938, 0.3034854531288147, 0.586567759513855, -1.2706447839736938, 1.7049126625061035, 0.8788442015647888, 2.1035678386688232, 0.8906868100166321, -0.37665873765945435, 1.5216413736343384, -0.1782536655664444, 1.854687213897705, -0.4875200688838959, 0.6090137362480164, -0.2795776426792145, -1.1559922695159912, 0.8130840063095093, -0.48934975266456604, -1.9508076906204224, -0.8717430233955383, -0.9880043268203735, -0.17445781826972961, -0.7506628036499023, 0.9107771515846252, -0.2930927276611328, -1.352938175201416, 0.014068550430238247, -0.6028704643249512, 0.23215192556381226, -1.256644368171692, 0.15881690382957458, 0.8138879537582397, -0.7283892035484314, -0.10023458302021027, -0.24408487975597382, -1.3634952306747437, -0.6073176860809326, 0.3902113139629364, 2.0167057514190674, -0.6216701865196228, 0.8702781796455383, 0.9877095222473145, -0.7175812125205994, 0.169955775141716, 0.27386245131492615, -0.36745697259902954, 0.786835789680481, -1.086723804473877, -0.3700694739818573, 1.1830605268478394, -0.19589774310588837, -0.7493152618408203, 1.581925630569458, 0.9389997720718384, -1.0727614164352417, -0.2288781851530075, -0.2658032774925232, -0.637792706489563, -0.06450203061103821, -1.6086370944976807, -0.24138249456882477, 0.12551254034042358, -1.412671685218811, -0.4744108319282532, -0.19460107386112213, 1.3455699682235718, -0.31026703119277954, 1.4420437812805176, -0.2374643236398697, -0.23949255049228668, -0.4107288718223572, -0.5272684097290039, 0.22842077910900116, -0.2493995726108551, -0.6371392011642456, 0.3503595292568207, -0.8614856600761414, 0.3125225603580475, 1.5271317958831787, 0.3514411449432373, 0.1401594877243042, 0.4574945867061615, 1.0452746152877808, 0.4001896381378174, -0.05280241370201111, -0.9577955007553101, -1.5832555294036865, 2.007262706756592, -1.294685959815979, 1.9536943435668945, 0.812294602394104, -0.08227276057004929, -1.7090411186218262, -1.8501770496368408, 1.3467493057250977, 1.2758738994598389, 2.380476236343384, 0.4446605145931244, 0.34229356050491333, -0.8333069682121277, -0.7326279282569885, 0.3618850111961365, -0.9874526858329773, -0.7708399891853333, 0.02293945848941803, 2.306577682495117, 1.8661965131759644, -0.6305780410766602, -0.26524341106414795, -0.9309828281402588, 1.1887526512145996, -0.204787939786911, 0.23056939244270325, 2.0817549228668213, -0.39112794399261475, -1.00404953956604, 1.317322015762329, -2.4130003452301025, 0.21822038292884827, 2.102870225906372, 0.3011118769645691, 0.12725341320037842, -1.5044223070144653, -0.6616413593292236, -0.26131656765937805, -0.5146266222000122, -1.1653070449829102, 0.6384750604629517, -0.2123364359140396, -0.9436826109886169, -1.448550820350647, 0.09713830053806305, -1.1532198190689087, -1.7977924346923828, 0.4593779742717743, 1.8439079523086548, 2.0736727714538574, -0.8918859958648682, 1.3292409181594849, -0.17992191016674042, 0.07688505947589874, 1.2511422634124756, 1.3185358047485352, 3.1188714504241943, 1.9118653535842896, -1.2030458450317383, 0.8093540668487549, -0.21313504874706268, -0.5529283881187439, 1.1193312406539917, -0.9774757027626038, 1.125087857246399, -0.2853425443172455, -1.2520325183868408, -1.382710576057434, 1.0033608675003052, 0.4808054566383362, 0.032361291348934174, -0.5712006092071533, 1.2351479530334473, 0.11342507600784302, 1.3022491931915283, 0.5347267985343933, -0.43376824259757996, 0.4712601900100708, -0.33462077379226685, -0.617296040058136, 1.6352468729019165, 0.08024047315120697, -1.6197832822799683, -2.3144683837890625, -0.24936336278915405, -0.8924519419670105, -0.23418843746185303, -0.5849416255950928, -1.0775104761123657, 1.5536669492721558, 0.46580740809440613, -1.251143455505371, -0.3164351284503937, -0.2737261652946472, -0.581450879573822, 2.644191026687622, -1.3241753578186035, -0.1574675440788269, -0.9464478492736816, -0.42559853196144104, 1.703561544418335, -1.2207627296447754, -0.13609810173511505, -0.9936093688011169, -0.7915293574333191, -1.3479903936386108, -0.35832229256629944, 0.01495178323239088, -0.8924146294593811, 0.7110486626625061, 0.01320707332342863, -1.0363273620605469, -0.326549232006073, -0.910056471824646, 1.0276538133621216, -0.1402706503868103, 0.2558985948562622, 1.9139604568481445, 0.4088778793811798, -0.45251208543777466, 0.6925026774406433, 1.274200201034546, 0.5724141597747803, -0.7108797430992126, 0.10723810642957687, -0.7031465768814087, 0.4130922555923462, -1.4074488878250122, 0.2296479493379593, -3.0102784633636475, 0.7410423159599304, -0.05186363682150841, -0.17382197082042694, -0.08621165156364441, -1.2728149890899658, 1.241718053817749, 2.565112590789795, -1.2028642892837524, 0.5157923698425293, 0.4137338399887085, 1.1858956813812256, -1.4628428220748901, 0.23227046430110931, -0.3862285614013672, 2.068068027496338, 0.09427416324615479, 1.2019222974777222, -0.5429248213768005, -2.030830144882202, 0.6311938166618347, -1.30594801902771, -0.91002357006073, 0.7596860527992249, -0.9190415740013123, 0.19229498505592346, -1.475658893585205, 0.00433649867773056, -0.9398807287216187, -1.3236836194992065, 0.7532969117164612, 0.048698510974645615, 0.42803651094436646, -0.6636478304862976, 0.4570545256137848, -2.1084744930267334, -1.4424238204956055, -0.20147502422332764, -1.0338051319122314, 0.47226187586784363, -0.3407878577709198, 0.5934158563613892, -0.015508722513914108, 0.1922769397497177, 0.3317902088165283, 1.4015353918075562, 3.438157320022583, 0.1966729313135147, 0.362248033285141, -0.05949091166257858, -0.9442160129547119, 1.5103919506072998, 1.0186187028884888, -0.11393316090106964, -0.49138063192367554, -0.9109712839126587, 1.4025447368621826, 1.9888741970062256, 1.2000120878219604, 0.10437028855085373, -0.9587755799293518, -0.8447828888893127, 0.022527948021888733, 0.2190084159374237, 0.5225077867507935, 1.0057318210601807, -0.10584424436092377, 0.13562318682670593, 1.2848371267318726, 1.2886722087860107, -0.40008676052093506, 0.48174458742141724, -1.018190622329712, -0.3756786584854126, 0.3462943136692047, 0.2511289119720459, 0.033084671944379807, 0.6407933235168457, -0.9810217022895813, -0.22338680922985077, -0.1968085765838623, -0.9569187164306641, -0.7162764072418213, -0.5226375460624695, -0.3825768828392029, 1.5299603939056396, 0.13957376778125763, -0.5059974193572998, 0.11209031194448471, -0.8405357599258423, -0.13897936046123505, -0.9821022748947144, 0.15874390304088593, -0.11234654486179352, -0.024108167737722397, -0.11109499633312225, 1.8053840398788452, -1.1149306297302246, -2.1362407207489014, 0.27654656767845154, 0.31615811586380005, -0.4476483166217804, 0.15503652393817902, 1.7431414127349854, 0.4176064133644104, 1.3681968450546265, 1.1870514154434204, 1.0938135385513306, -0.6248753070831299, -1.2416118383407593, 0.7555221319198608, 0.9629731178283691, -1.3784418106079102, 0.9641188979148865, -0.25230568647384644, -0.36852115392684937, 0.7471798658370972, 1.246286392211914, 0.3511016368865967, -1.8560630083084106, 0.8685771226882935, -0.8652607798576355, 0.8510816097259521, 0.605006217956543, 0.8382758498191833, 0.2942882478237152, 0.8719849586486816, -1.2581366300582886, -1.0559262037277222, -0.8326993584632874, -0.6014940738677979, 1.9193142652511597, -0.1938496083021164, 0.5188156962394714, -0.12970122694969177, -1.2236032485961914, -0.20999164879322052, 0.7848798632621765, 0.3504793345928192, -0.3352208435535431, 0.9789276719093323, -0.6228242516517639, -0.972388505935669, -1.3525753021240234, -0.49591490626335144, -0.8902163505554199, -0.8938692212104797, 1.0417543649673462, 0.7771007418632507, 0.38007238507270813, 1.930190920829773, 0.4770965576171875, 0.29129934310913086, -2.5845725536346436, 0.9856539964675903, 0.25040677189826965, 0.07920224964618683, 0.8634244799613953, 0.2876654267311096, 1.1734246015548706, -0.03683774173259735, 0.5127155780792236, -2.1871259212493896, 2.249680995941162, -0.17538008093833923, 0.6118143796920776, 0.05543084815144539, -0.11728250235319138, 1.1228466033935547, 0.47354644536972046, 0.6386005282402039, -1.296897530555725, 0.7626846432685852, -0.5406577587127686, 1.0972963571548462, 0.9306677579879761, -0.8016200065612793, 0.0553615503013134, 1.296571969985962, 0.46281683444976807, -0.4209149479866028, -1.0021148920059204, -0.8282741904258728, 1.0594860315322876, 1.624079942703247, -0.006288793403655291, -0.02435104176402092, 0.8028944134712219, 0.5885739326477051, -1.296423316001892, -0.03155430033802986, -0.71021968126297, -0.6310098171234131, 1.6887409687042236, 2.043854236602783, -0.0017592767253518105, -0.15118813514709473, -0.7311539649963379, -1.1853786706924438, 0.6624318361282349, -0.06173321604728699, 0.12022653967142105, 0.730143129825592, -0.6765901446342468, 1.1943259239196777, 0.6731826066970825, 0.9134172201156616, -0.16676950454711914, 0.294920414686203, 0.4196600317955017, -0.3371322751045227, -1.1659266948699951, -0.46899861097335815, -1.1772810220718384, -2.594252109527588, 0.34182417392730713, -0.3926134705543518, -1.2909263372421265, -0.03948412835597992, -1.1586889028549194, 0.9014596939086914, -0.6530007123947144, -0.9519428610801697, -1.336893081665039, 0.2778571844100952, -0.27276596426963806, 0.8371668457984924, -1.6397815942764282, -0.16000710427761078, 1.2805622816085815, 0.9221962690353394, -0.650874674320221, 1.0395089387893677, 0.17042215168476105, 1.013309359550476, 0.735568642616272, -0.3677118718624115, 0.4794662594795227, 0.22018647193908691, -1.4064345359802246, 0.3453885614871979, 1.166032075881958, 0.2586537301540375, 1.236299991607666, -0.44672393798828125, 0.2267109602689743, 0.4984585642814636, -0.5518516302108765, -0.5653960704803467, -0.49147430062294006, 0.8371541500091553, 0.14896352589130402, -1.0586200952529907, -0.05725666135549545, -0.1790335774421692, -0.23605646193027496, 0.2100035697221756, -1.5363928079605103, -0.3564987778663635, -0.2509755790233612, -0.4192577600479126, -1.3150782585144043, 0.1952223777770996, 1.3078912496566772, -0.855014443397522, -0.21453538537025452, 0.46578043699264526, 0.35307446122169495, 0.5676893591880798, 0.6729103922843933, -0.7784714698791504, -0.2651049792766571, -0.3688458800315857, -0.21263740956783295, 0.3434886634349823, 1.1849385499954224, -0.1156967505812645, -0.9876171350479126, 0.7148739099502563, -0.44244077801704407, 0.09347458928823471, 2.037804126739502, -0.05879606306552887, -0.8529795408248901, 0.3050980865955353, -0.6678876280784607, 1.8274205923080444, 1.6589072942733765, 1.275826096534729, -0.11569292098283768, -0.7545082569122314, 0.6098230481147766, -0.11931906640529633, -0.24363401532173157, 0.99551922082901, 0.4214080572128296, -0.24148033559322357, -1.5464414358139038, 0.3477037250995636, 1.237982153892517, -0.898737907409668, -0.7228989601135254, 0.011114793829619884, -0.8845898509025574, 1.1455020904541016, 0.7220832109451294, 0.2774035632610321, 0.26685991883277893, 1.513228416442871, 0.6594945788383484, -0.5545785427093506, 0.32554760575294495, 0.5300928950309753, -0.2379751056432724, -2.081310510635376, -0.9310746192932129, 0.18918576836585999, -0.4011814594268799, -1.4866867065429688, 1.2334109544754028, -1.1966890096664429, -0.8901117444038391, 0.5157310366630554, 0.06329108029603958, 1.455265998840332, 0.24808290600776672, 1.7281467914581299, 2.0824012756347656, 0.9222468137741089, 0.1905355602502823, 1.323930025100708, -0.06503895670175552, -0.4394843876361847, 1.8033028841018677, -0.4241524040699005, 0.5175195932388306, 0.9537423253059387, -0.5095497965812683, -1.0550103187561035, -0.779841959476471, -1.0473904609680176, -0.5344253182411194, 1.2772272825241089, 0.21609920263290405, -1.1343339681625366, 0.09986363351345062, 1.5567761659622192, 0.14963869750499725, -0.12611176073551178, 0.6576415300369263, 0.5469169020652771, -0.7300780415534973, 0.0845126137137413, -0.8435425162315369, 0.5513474941253662, -0.1723029464483261, -0.2899699807167053, 0.26679620146751404, 0.45179519057273865, 1.180837869644165, -0.017381776124238968, 0.13571739196777344, 1.1933692693710327, -1.3251070976257324, 1.487177848815918, -0.5368137359619141, 0.27049899101257324, -2.5816283226013184, 1.4019688367843628, -0.7524252533912659, 1.9625073671340942, -2.556792736053467, 0.3656299412250519, -0.6401954889297485, -0.5802710056304932, 0.33674371242523193, -0.5055088400840759, 0.10622186958789825, -0.12516112625598907, -0.8904564380645752, -0.030539751052856445, -0.829230010509491, 0.5677741169929504, 1.1963224411010742, 1.3243781328201294, -0.9786860346794128, -0.36691543459892273, -1.8130673170089722, -0.2586946487426758, -0.742803156375885, 0.3837165832519531, -2.0637662410736084, -0.1875414401292801, -1.966393232345581, -2.248293876647949, -1.5147597789764404, -0.8130536675453186, 1.0590686798095703, 0.17610439658164978, -0.8906689882278442, 1.0954041481018066, -0.3400634527206421, -1.6784461736679077, 0.9736774563789368, -2.192718505859375 ]
https://github.com/huggingface/datasets/issues/5181
Add a guide for semantic segmentation
I am considering `torchvision` and `albumentations`. Also [works with TensorFlow](https://github.com/deep-diver/segformer-tf-transformers/blob/main/notebooks/TFSegFormer_Finetune.ipynb). I am assigning the issue to myself then.
Currently, we have these guides for object detection and image classification: * https://huggingface.co/docs/datasets/object_detection * https://huggingface.co/docs/datasets/image_classification I am proposing adding a similar guide for semantic segmentation. I am happy to contribute a PR for it. Cc: @osanseviero @nateraw
448
18
Add a guide for semantic segmentation Currently, we have these guides for object detection and image classification: * https://huggingface.co/docs/datasets/object_detection * https://huggingface.co/docs/datasets/image_classification I am proposing adding a similar guide for semantic segmentation. I am happy to contribute a PR for it. Cc: @osanseviero @nateraw I am considering `torchvision` and `albumentations`. Also [works with TensorFlow](https://github.com/deep-diver/segformer-tf-transformers/blob/main/notebooks/TFSegFormer_Finetune.ipynb). I am assigning the issue to myself then.
[ -1.2990901470184326, -0.9502537250518799, -0.7494202256202698, 1.407979130744934, -0.11849646270275116, -1.417187213897705, 0.04679892584681511, -1.0702104568481445, 1.7235236167907715, -0.7030975818634033, 0.2929624915122986, -1.6183875799179077, -0.03048136830329895, -0.6079391837120056, -0.7164438366889954, -0.8790680170059204, -0.36947548389434814, -0.8686437010765076, 1.037485122680664, 2.513167142868042, 1.241603136062622, -1.364266037940979, 2.7423384189605713, 0.6939579248428345, -0.300475150346756, -1.0099308490753174, 0.5768896341323853, 0.07582380622625351, -1.2831100225448608, -0.4692364037036896, -1.0028477907180786, 0.019276291131973267, -0.5502256751060486, -0.44531533122062683, 0.03984270244836807, 0.40376847982406616, -0.2039056122303009, -0.2640894949436188, -0.5859702825546265, -0.7203821539878845, 0.49617594480514526, -0.23925994336605072, 0.9320313930511475, -0.40096116065979004, 1.7693699598312378, -0.571108877658844, 0.35564741492271423, 0.5842798948287964, 1.5128496885299683, 0.07181888818740845, 0.0443703755736351, 0.22955703735351562, 0.37381210923194885, 0.019256461411714554, 0.4315176010131836, 1.1786549091339111, 0.5781073570251465, 0.5246900916099548, 0.5492104291915894, -2.1054723262786865, 1.3233058452606201, -0.8358196020126343, 0.23188373446464539, 1.4483534097671509, -0.8944633603096008, 0.33228573203086853, -1.792542576789856, -0.06333357840776443, 0.5011808276176453, -2.31256103515625, 0.15168365836143494, -1.1954668760299683, -0.7213478684425354, 0.9488160610198975, 0.3209100663661957, -1.2623226642608643, 0.14251253008842468, -0.4855586588382721, 1.0540270805358887, 0.5328637361526489, 1.1214193105697632, -1.5720137357711792, 0.06828762590885162, -0.20417392253875732, 0.03686648979783058, -1.2601381540298462, -1.4720258712768555, 0.47160804271698, 0.6940954327583313, 0.8016633987426758, -0.013818332925438881, 0.9117578268051147, -0.8715329766273499, 0.8951339721679688, -0.7381702065467834, -1.6305460929870605, -1.3453434705734253, -2.371717691421509, -2.288639545440674, 0.8568462133407593, -0.48621541261672974, -0.46286875009536743, 1.9364001750946045, -0.9808825254440308, -1.8888188600540161, 1.0618976354599, 0.30529025197029114, 0.07571796327829361, 2.3892037868499756, 0.2416677623987198, -0.7146936058998108, 0.46774861216545105, -0.7112687230110168, 0.8380557298660278, -0.4324805736541748, 1.4212839603424072, 0.5768298506736755, -0.9648905992507935, 1.6403286457061768, -0.3756569027900696, 0.5690100789070129, -0.6675599813461304, -0.48209840059280396, -0.8798961639404297, 0.3947637975215912, 1.8917955160140991, -0.38765957951545715, 1.6256719827651978, -0.3062632381916046, -1.6187063455581665, -1.5419656038284302, 0.820550262928009, 0.5406298041343689, -0.8092520236968994, 0.1594109833240509, -0.46631184220314026, 0.0451400987803936, 0.060799211263656616, 1.0461868047714233, 1.1813520193099976, 0.6844730377197266, -0.24049314856529236, -0.7896978855133057, 0.3971720039844513, 0.023234780877828598, -0.6600794792175293, -1.8454228639602661, -0.31821370124816895, 0.2638367712497711, 0.6402294039726257, -1.2596135139465332, 1.7733584642410278, 0.8241722583770752, 2.0787885189056396, 0.8685382604598999, -0.31624075770378113, 1.497312068939209, -0.10052785277366638, 1.8605526685714722, -0.47169023752212524, 0.6993188858032227, -0.20649999380111694, -1.1198772192001343, 0.8614742755889893, -0.5150272250175476, -1.987376093864441, -0.7363305687904358, -0.9073809385299683, -0.0665404349565506, -0.7799509763717651, 0.9857180714607239, -0.33130595088005066, -1.3616054058074951, 0.12053421884775162, -0.6609874367713928, 0.17833372950553894, -1.268088698387146, 0.17058023810386658, 0.8358660340309143, -0.6654518842697144, -0.09005387127399445, -0.198494553565979, -1.3026440143585205, -0.5547512769699097, 0.3688982427120209, 1.9667104482650757, -0.6442471146583557, 0.9327698945999146, 0.9966427087783813, -0.8045473694801331, 0.16947884857654572, 0.4137975871562958, -0.39897552132606506, 0.8173332214355469, -1.1401578187942505, -0.3056398630142212, 1.1116317510604858, -0.15956971049308777, -0.592415988445282, 1.5110212564468384, 0.9367547631263733, -1.0209578275680542, -0.1553725004196167, -0.2085280418395996, -0.639180064201355, -0.0489562526345253, -1.5788109302520752, -0.23186981678009033, 0.21119922399520874, -1.3901389837265015, -0.44828033447265625, -0.15296466648578644, 1.3206826448440552, -0.22814983129501343, 1.4321495294570923, -0.272151917219162, -0.3014991581439972, -0.4575445055961609, -0.4691673815250397, 0.17307692766189575, -0.22717177867889404, -0.6378543376922607, 0.32706505060195923, -0.8658802509307861, 0.3586771488189697, 1.4625957012176514, 0.30264246463775635, 0.12192226201295853, 0.5050280094146729, 1.0225083827972412, 0.3065445125102997, -0.0928078442811966, -0.9239864349365234, -1.5204572677612305, 2.002077341079712, -1.3542424440383911, 1.9414513111114502, 0.7270675301551819, -0.105491504073143, -1.7613346576690674, -1.849502444267273, 1.3580164909362793, 1.312950611114502, 2.333503484725952, 0.6158466935157776, 0.3082936406135559, -0.8325135111808777, -0.7186623215675354, 0.3523223102092743, -1.0403025150299072, -0.7116093039512634, 0.05243860185146332, 2.27543568611145, 1.888217806816101, -0.5760173201560974, -0.300367146730423, -1.030625581741333, 1.2254191637039185, -0.21533051133155823, 0.16300895810127258, 2.0892555713653564, -0.3763352334499359, -1.01079261302948, 1.274408221244812, -2.344724655151367, 0.23624040186405182, 2.045126438140869, 0.35309478640556335, 0.1534620076417923, -1.5792407989501953, -0.6717571020126343, -0.25242963433265686, -0.49192023277282715, -1.120413899421692, 0.6279663443565369, -0.32340389490127563, -0.9244861602783203, -1.4912657737731934, 0.17191560566425323, -1.094322919845581, -1.8305699825286865, 0.3497842848300934, 1.8113970756530762, 2.0390512943267822, -0.7770150899887085, 1.365280270576477, -0.1782798320055008, 0.12193397432565689, 1.2482044696807861, 1.2780115604400635, 3.0515565872192383, 1.9013090133666992, -1.1476267576217651, 0.781019389629364, -0.27184006571769714, -0.4416365623474121, 1.073604941368103, -1.1463987827301025, 1.21052885055542, -0.2685869336128235, -1.1715394258499146, -1.2558374404907227, 1.0347261428833008, 0.5085254311561584, 0.06721077114343643, -0.5491271018981934, 1.2438260316848755, 0.07242932170629501, 1.2997082471847534, 0.474770188331604, -0.37880706787109375, 0.5288432240486145, -0.2837502062320709, -0.5393686890602112, 1.5936386585235596, 0.09303306043148041, -1.5252249240875244, -2.36114501953125, -0.24236615002155304, -0.8463667035102844, -0.10653814673423767, -0.5967628955841064, -1.030274748802185, 1.6423439979553223, 0.5382735729217529, -1.173256516456604, -0.2159644365310669, -0.35569870471954346, -0.6147002577781677, 2.6542484760284424, -1.2998601198196411, -0.20486266911029816, -0.9744946360588074, -0.41488340497016907, 1.669222116470337, -1.179304838180542, -0.19272157549858093, -0.9780448079109192, -0.7630933523178101, -1.3121968507766724, -0.4887513518333435, -0.041694220155477524, -0.885833740234375, 0.6501144766807556, 0.06256227940320969, -1.046522855758667, -0.38392525911331177, -0.8442789912223816, 0.9952019453048706, -0.11447524279356003, 0.16404496133327484, 1.9389604330062866, 0.36435437202453613, -0.35084864497184753, 0.7273609638214111, 1.1814639568328857, 0.5257800221443176, -0.7313165664672852, 0.20468322932720184, -0.6847798228263855, 0.30393844842910767, -1.3932952880859375, 0.28709161281585693, -3.0092155933380127, 0.7739031910896301, -0.05127076059579849, -0.1806063950061798, -0.07762102037668228, -1.3456326723098755, 1.1808629035949707, 2.5761377811431885, -1.2362624406814575, 0.48018181324005127, 0.3692754805088043, 1.0937775373458862, -1.4483401775360107, 0.2802731394767761, -0.3494572639465332, 2.096656322479248, 0.10814713686704636, 1.2417484521865845, -0.5045598745346069, -2.109889268875122, 0.6637462973594666, -1.2539516687393188, -0.9773165583610535, 0.6369261145591736, -0.9154475331306458, 0.15341880917549133, -1.406028151512146, -0.0886174812912941, -0.925542950630188, -1.273200273513794, 0.7282350063323975, 0.04416518285870552, 0.49536311626434326, -0.6702325344085693, 0.45484301447868347, -2.074249267578125, -1.4227890968322754, -0.216501384973526, -1.065704584121704, 0.4522179067134857, -0.3666069805622101, 0.5849669575691223, -0.04809441789984703, 0.0915190652012825, 0.36111554503440857, 1.4532666206359863, 3.439490556716919, 0.14088760316371918, 0.33186280727386475, -0.003454047255218029, -0.9605001211166382, 1.4332736730575562, 0.9619123339653015, -0.06477532535791397, -0.5721141695976257, -0.9145539999008179, 1.388379693031311, 1.9985687732696533, 1.1432669162750244, 0.1351766735315323, -1.009278416633606, -0.847732663154602, 0.08170510828495026, 0.2470896691083908, 0.4464927613735199, 0.865913450717926, -0.019518546760082245, 0.07789155840873718, 1.4086263179779053, 1.1542515754699707, -0.4581489562988281, 0.4898168742656708, -1.0221009254455566, -0.44226038455963135, 0.3345198929309845, 0.36057615280151367, 0.06386929750442505, 0.551956057548523, -1.0110119581222534, -0.1852763444185257, -0.23219844698905945, -0.9244760274887085, -0.7670850157737732, -0.4740540087223053, -0.3865506052970886, 1.5564324855804443, 0.14333845674991608, -0.5656458735466003, 0.04901213198900223, -0.8119391798973083, -0.10909643769264221, -1.0147022008895874, 0.17342384159564972, -0.06888337433338165, 0.02632112428545952, -0.1622694581747055, 1.7847384214401245, -1.0073236227035522, -2.1899242401123047, 0.24977459013462067, 0.2555385231971741, -0.47002699971199036, 0.15000373125076294, 1.676182508468628, 0.4985805153846741, 1.4189099073410034, 1.2760138511657715, 1.0693851709365845, -0.5870919823646545, -1.2693034410476685, 0.7803224325180054, 0.9383730292320251, -1.4225589036941528, 0.895158052444458, -0.12401469796895981, -0.46112486720085144, 0.6702852249145508, 1.3826611042022705, 0.33686262369155884, -2.0037944316864014, 0.8097505569458008, -0.8260617256164551, 0.9026365280151367, 0.6169143319129944, 0.7968279719352722, 0.28780078887939453, 0.8446744084358215, -1.3492153882980347, -1.1170949935913086, -0.8496419191360474, -0.6246650815010071, 1.9180742502212524, -0.2310100644826889, 0.5654938220977783, -0.17581608891487122, -1.2767030000686646, -0.1937873363494873, 0.7397584915161133, 0.3874002993106842, -0.3242776691913605, 0.9069002270698547, -0.6957802176475525, -1.0673809051513672, -1.3286761045455933, -0.4928600788116455, -0.9284506440162659, -0.9430322647094727, 1.055987000465393, 0.8272006511688232, 0.4631904065608978, 1.9687994718551636, 0.5564679503440857, 0.3264966607093811, -2.609951972961426, 0.9854728579521179, 0.26301077008247375, 0.11363378167152405, 0.8762681484222412, 0.24917630851268768, 1.1422606706619263, -0.08968832343816757, 0.45819172263145447, -2.247758388519287, 2.167006015777588, -0.1017877459526062, 0.6258984208106995, 0.08880365639925003, -0.13305002450942993, 1.1961438655853271, 0.4737507104873657, 0.6241067051887512, -1.2572249174118042, 0.7009553909301758, -0.6043670773506165, 1.1202419996261597, 0.932121992111206, -0.7785356044769287, 0.04050925746560097, 1.2807304859161377, 0.475190132856369, -0.4228789508342743, -0.9411271214485168, -0.8826983571052551, 1.0019434690475464, 1.5968961715698242, -0.01760413870215416, -0.012778756208717823, 0.7811655402183533, 0.6340447068214417, -1.3111655712127686, -0.011673490516841412, -0.8401209712028503, -0.5734121799468994, 1.7306617498397827, 2.03448486328125, -0.0340215228497982, -0.1829642355442047, -0.745919942855835, -1.246670126914978, 0.6790860295295715, -0.07587180286645889, 0.13329766690731049, 0.635064959526062, -0.6684950590133667, 1.1780954599380493, 0.7430461645126343, 0.9988789558410645, -0.07825164496898651, 0.3289031982421875, 0.40342915058135986, -0.30769428610801697, -1.242207407951355, -0.5092086791992188, -1.1210403442382812, -2.538468360900879, 0.398372083902359, -0.38186120986938477, -1.3941898345947266, -0.00766550051048398, -1.161054253578186, 0.8093470931053162, -0.6791345477104187, -0.9113203883171082, -1.3277032375335693, 0.3378257155418396, -0.27658379077911377, 0.8317045569419861, -1.6131103038787842, -0.20177485048770905, 1.3398486375808716, 0.9060285091400146, -0.6459701657295227, 0.9898445010185242, 0.17302130162715912, 0.992620587348938, 0.7833617329597473, -0.4683632254600525, 0.4494404196739197, 0.1715729981660843, -1.3678239583969116, 0.49332231283187866, 1.1324131488800049, 0.2500286102294922, 1.2809762954711914, -0.4512019157409668, 0.19369420409202576, 0.48690152168273926, -0.5734525918960571, -0.5966291427612305, -0.5602291226387024, 0.7708361148834229, 0.08391159027814865, -1.0602177381515503, -0.046671848744153976, -0.16907474398612976, -0.22297818958759308, 0.25369739532470703, -1.5931967496871948, -0.31915298104286194, -0.28157857060432434, -0.46324461698532104, -1.3113569021224976, 0.09387873858213425, 1.3409966230392456, -0.7951074838638306, -0.14258748292922974, 0.4727105498313904, 0.4498187005519867, 0.594231367111206, 0.6369187235832214, -0.7139734625816345, -0.25439247488975525, -0.3290711045265198, -0.30926841497421265, 0.3276864290237427, 1.1597248315811157, -0.12831097841262817, -0.9887682795524597, 0.624453604221344, -0.4675567150115967, 0.12834309041500092, 1.9953832626342773, -0.003410687204450369, -0.7877247929573059, 0.30682167410850525, -0.7146276831626892, 1.9137418270111084, 1.5998576879501343, 1.2704544067382812, -0.0700887069106102, -0.7963297367095947, 0.5372682809829712, -0.11300560086965561, -0.3249231278896332, 0.9472432732582092, 0.43436363339424133, -0.22333648800849915, -1.4224177598953247, 0.44769296050071716, 1.310189127922058, -0.9294848442077637, -0.8489066362380981, -0.00042815692722797394, -0.8973959684371948, 1.0275988578796387, 0.6632105708122253, 0.3450569212436676, 0.3324395418167114, 1.6288564205169678, 0.68365877866745, -0.5194305181503296, 0.3193422853946686, 0.4961446523666382, -0.1783701479434967, -2.0633349418640137, -0.9362749457359314, 0.27007851004600525, -0.4956839978694916, -1.6170663833618164, 1.2046597003936768, -1.1422135829925537, -0.9106321334838867, 0.5575407147407532, 0.1812228560447693, 1.4384328126907349, 0.3357709050178528, 1.6411253213882446, 2.0493273735046387, 0.8707563877105713, 0.2335340678691864, 1.247096300125122, -0.0587816946208477, -0.4172554910182953, 1.8204562664031982, -0.5065914392471313, 0.5862220525741577, 1.0158376693725586, -0.43658918142318726, -1.1067975759506226, -0.9159500598907471, -1.1238948106765747, -0.6016936302185059, 1.2180852890014648, 0.2690301835536957, -1.2385344505310059, 0.1673988252878189, 1.5709279775619507, 0.19971978664398193, -0.2040412873029709, 0.5962364673614502, 0.5037946105003357, -0.7698429822921753, 0.05977999418973923, -0.9395002126693726, 0.5667226910591125, -0.13739147782325745, -0.38461199402809143, 0.28676551580429077, 0.5074739456176758, 1.1831843852996826, -0.06299770623445511, 0.08621226996183395, 1.1161490678787231, -1.3320605754852295, 1.548253059387207, -0.5982705950737, 0.2824096083641052, -2.4975810050964355, 1.4292577505111694, -0.7366183996200562, 1.9389162063598633, -2.652463674545288, 0.40283867716789246, -0.6212120056152344, -0.48284292221069336, 0.3922615647315979, -0.47974106669425964, 0.13274316489696503, -0.11524149775505066, -1.0603224039077759, -0.07294526696205139, -0.7760831117630005, 0.49202823638916016, 1.2123653888702393, 1.3426450490951538, -1.0057648420333862, -0.31813547015190125, -1.8522943258285522, -0.15475991368293762, -0.711746871471405, 0.4270794987678528, -2.119518995285034, -0.1735449731349945, -1.9620529413223267, -2.312455654144287, -1.391947865486145, -0.7188459038734436, 1.0519365072250366, 0.12195982784032822, -0.9014382362365723, 1.1097372770309448, -0.3394317626953125, -1.7398449182510376, 1.0021212100982666, -2.2628824710845947 ]
https://github.com/huggingface/datasets/issues/5180
An example or recommendations for creating large image datasets?
The beam utilities allow to prepare a dataset as parquet in your cloud storage. From my perspective this CLI is not super easy to use, but we've been working on a new python API to prepare a dataset in your cloud storage: ```python from datasets import load_dataset_builder builder = load_dataset_builder("c4", "en") builder.download_and_prepapre("s3://my-bucket/c4", file_format="parquet") ``` And to use Beam you can do: ```python beam_runner = ... # one of "SparkRunner", "DataFlowRunner", "DirectRunner", etc. beam_options = ... builder.download_and_prepapre( "s3://my-bucket/c4", file_format="parquet", beam_runner=beam_runner, beam_options=beam_options ) ``` Though Beam can be used ONLY if there is a dataset script based on the `BeamBasedBuilder` right now - it doesn't work on an arbitrary dataset (see [wikipedia.py](https://huggingface.co/datasets/wikipedia/blob/main/wikipedia.py) for example).
I know that Apache Beam and `datasets` have [some connector utilities](https://huggingface.co/docs/datasets/beam). But it's a little unclear what we mean by "But if you want to run your own Beam pipeline with Dataflow, here is how:". What does that pipeline do? As a user, I was wondering if we have this support for creating large image datasets. If so, we should mention that [here](https://huggingface.co/docs/datasets/image_dataset). Cc @lhoestq
449
112
An example or recommendations for creating large image datasets? I know that Apache Beam and `datasets` have [some connector utilities](https://huggingface.co/docs/datasets/beam). But it's a little unclear what we mean by "But if you want to run your own Beam pipeline with Dataflow, here is how:". What does that pipeline do? As a user, I was wondering if we have this support for creating large image datasets. If so, we should mention that [here](https://huggingface.co/docs/datasets/image_dataset). Cc @lhoestq The beam utilities allow to prepare a dataset as parquet in your cloud storage. From my perspective this CLI is not super easy to use, but we've been working on a new python API to prepare a dataset in your cloud storage: ```python from datasets import load_dataset_builder builder = load_dataset_builder("c4", "en") builder.download_and_prepapre("s3://my-bucket/c4", file_format="parquet") ``` And to use Beam you can do: ```python beam_runner = ... # one of "SparkRunner", "DataFlowRunner", "DirectRunner", etc. beam_options = ... builder.download_and_prepapre( "s3://my-bucket/c4", file_format="parquet", beam_runner=beam_runner, beam_options=beam_options ) ``` Though Beam can be used ONLY if there is a dataset script based on the `BeamBasedBuilder` right now - it doesn't work on an arbitrary dataset (see [wikipedia.py](https://huggingface.co/datasets/wikipedia/blob/main/wikipedia.py) for example).
[ -1.2103344202041626, -0.8975077867507935, -0.7160760164260864, 1.4806675910949707, -0.16451886296272278, -1.2322860956192017, 0.15418381989002228, -1.0467677116394043, 1.6735726594924927, -0.8335275650024414, 0.27733314037323, -1.646422028541565, -0.025358136743307114, -0.5399646162986755, -0.7114862203598022, -0.8349952697753906, -0.41640505194664, -0.7745468020439148, 1.015838623046875, 2.474670886993408, 1.2292200326919556, -1.385368824005127, 2.657505989074707, 0.6655223965644836, -0.2521262764930725, -1.0802843570709229, 0.5411447882652283, 0.114661306142807, -1.2706915140151978, -0.43878504633903503, -0.9267061352729797, -0.061917610466480255, -0.5458439588546753, -0.5297277569770813, -0.030676420778036118, 0.45842525362968445, -0.28976988792419434, -0.36710113286972046, -0.6206627488136292, -0.7214569449424744, 0.4534302055835724, -0.34837430715560913, 0.9780964255332947, -0.3421909809112549, 1.8583956956863403, -0.6126042604446411, 0.4516642093658447, 0.7401019334793091, 1.2374508380889893, 0.2790050208568573, 0.07473328709602356, 0.24027658998966217, 0.424589067697525, -0.06390046328306198, 0.5675129890441895, 1.1436229944229126, 0.5872061252593994, 0.4902680218219757, 0.7376803755760193, -2.315227508544922, 1.3307963609695435, -1.0561490058898926, 0.30131247639656067, 1.377199649810791, -0.8476976752281189, 0.3066609799861908, -1.7386438846588135, -0.06496740877628326, 0.5871209502220154, -2.200185775756836, 0.28682905435562134, -1.3263435363769531, -0.5469963550567627, 1.0308923721313477, 0.3714211583137512, -1.176645278930664, 0.21154780685901642, -0.4546181261539459, 1.0068873167037964, 0.43861299753189087, 1.1732016801834106, -1.6332513093948364, -0.05660545453429222, -0.3031620979309082, 0.10451410710811615, -1.2891619205474854, -1.5715059041976929, 0.5527681708335876, 0.5485915541648865, 0.649551510810852, -0.1341271549463272, 1.0403118133544922, -1.0469539165496826, 0.7839345335960388, -1.0271766185760498, -1.6715351343154907, -1.4717555046081543, -2.244248151779175, -2.333576202392578, 0.7811461687088013, -0.5261141061782837, -0.5178816318511963, 2.020881175994873, -0.952666163444519, -1.745129108428955, 1.107238531112671, 0.32221996784210205, 0.052577171474695206, 2.3473708629608154, 0.23426498472690582, -0.7395641803741455, 0.41262105107307434, -0.7666769027709961, 0.8260310888290405, -0.25180545449256897, 1.2926181554794312, 0.46366822719573975, -1.0231958627700806, 1.5859073400497437, -0.4337907135486603, 0.605186402797699, -0.6358803510665894, -0.5285559892654419, -0.7973109483718872, 0.2987627387046814, 1.8162100315093994, -0.29835548996925354, 1.5554128885269165, -0.3436279594898224, -1.5590476989746094, -1.6550692319869995, 0.8763701319694519, 0.421260803937912, -0.7841894626617432, 0.01340602245181799, -0.3897571265697479, 0.12716515362262726, -0.07556603103876114, 1.174682378768921, 1.2338370084762573, 0.7701144218444824, -0.42790475487709045, -0.83981853723526, 0.13770738244056702, -0.08397374302148819, -0.7480657696723938, -1.7405723333358765, -0.3672716021537781, 0.2641350328922272, 0.5666444897651672, -1.2133036851882935, 1.785176157951355, 0.9385655522346497, 1.9065264463424683, 0.9267939329147339, -0.33604925870895386, 1.5100045204162598, 0.031930867582559586, 1.8707833290100098, -0.5167823433876038, 0.5965065360069275, -0.3940160870552063, -1.1870445013046265, 0.8689385056495667, -0.31773310899734497, -2.0583207607269287, -0.9011522531509399, -0.7994838953018188, -0.2462926208972931, -0.788200855255127, 0.8664838671684265, -0.30589792132377625, -1.4570614099502563, 0.16281242668628693, -0.6917130947113037, 0.08380712568759918, -1.155257225036621, 0.2994782626628876, 0.7104234099388123, -0.679905116558075, 0.04873362556099892, -0.15402579307556152, -1.3389571905136108, -0.42676836252212524, 0.29675909876823425, 1.8484688997268677, -0.6641348600387573, 0.9407909512519836, 1.0608736276626587, -0.7590706944465637, 0.08377020806074142, 0.24849359691143036, -0.27042099833488464, 0.8328626751899719, -0.9968817234039307, -0.4248136281967163, 1.184800148010254, -0.2122913897037506, -0.6827642321586609, 1.5317857265472412, 0.7677218914031982, -0.9833981990814209, -0.18581725656986237, -0.1808481514453888, -0.8023008704185486, -0.009100059978663921, -1.4529826641082764, -0.12566734850406647, 0.3820255696773529, -1.4788256883621216, -0.3817378878593445, -0.22082751989364624, 1.2519739866256714, -0.24532027542591095, 1.407071590423584, -0.4072187542915344, -0.22499096393585205, -0.3027038276195526, -0.4005022644996643, 0.1298064887523651, -0.21635442972183228, -0.6174905896186829, 0.2266024500131607, -0.8518267869949341, 0.3346388041973114, 1.4525796175003052, 0.348432719707489, 0.032454606145620346, 0.40744489431381226, 1.093174695968628, 0.3968406021595001, 0.06266617029905319, -0.9025121927261353, -1.530383586883545, 2.0242791175842285, -1.4229379892349243, 1.914807677268982, 0.7356317639350891, -0.08569151163101196, -1.8156664371490479, -1.876585841178894, 1.2969733476638794, 1.1237117052078247, 2.4046578407287598, 0.47146666049957275, 0.38979223370552063, -0.7768605947494507, -0.7093672752380371, 0.3996620774269104, -1.0339746475219727, -0.5995150208473206, 0.1442345529794693, 2.374145269393921, 1.7977097034454346, -0.46539586782455444, -0.15083275735378265, -0.9818028211593628, 1.3710534572601318, -0.19232948124408722, 0.23079274594783783, 2.057049036026001, -0.27028247714042664, -1.015063762664795, 1.393555760383606, -2.327195167541504, 0.19316838681697845, 2.018383264541626, 0.27000269293785095, 0.08830414712429047, -1.3375431299209595, -0.5849246978759766, -0.2891402542591095, -0.44102397561073303, -1.1994439363479614, 0.5686587691307068, -0.18110260367393494, -0.7986669540405273, -1.4549168348312378, 0.08577624708414078, -1.1894477605819702, -1.7122529745101929, 0.2710544466972351, 1.881545901298523, 2.0001308917999268, -0.8519701957702637, 1.4759784936904907, -0.26539885997772217, 0.14200453460216522, 1.277930736541748, 1.275131344795227, 3.0960733890533447, 1.8633267879486084, -1.27734375, 0.6315245032310486, -0.16718624532222748, -0.4958623945713043, 1.2011597156524658, -1.189380168914795, 1.265188455581665, -0.13023674488067627, -1.1545733213424683, -1.293858289718628, 1.0537718534469604, 0.4485571086406708, 0.07566827535629272, -0.5593863725662231, 1.1385806798934937, 0.1643701046705246, 1.3023362159729004, 0.6227867007255554, -0.37573274970054626, 0.635294497013092, -0.38780978322029114, -0.524921715259552, 1.5854657888412476, 0.21598653495311737, -1.4636863470077515, -2.2484819889068604, -0.2311134934425354, -0.9064647555351257, -0.03258155286312103, -0.5566378235816956, -1.0433939695358276, 1.7279741764068604, 0.3740108907222748, -1.34153413772583, -0.2652930021286011, -0.28875699639320374, -0.592680037021637, 2.7545268535614014, -1.2301963567733765, -0.16368542611598969, -0.9877974987030029, -0.6723602414131165, 1.6414974927902222, -1.1635961532592773, -0.19855789840221405, -1.0124491453170776, -0.6265488862991333, -1.3610808849334717, -0.5024948120117188, 0.07379571348428726, -0.9733073711395264, 0.7953587174415588, 0.1951662302017212, -1.1315515041351318, -0.41448304057121277, -0.855513334274292, 1.0022215843200684, -0.171163409948349, 0.1932947039604187, 1.866072177886963, 0.41550350189208984, -0.3701240122318268, 0.6575866937637329, 1.1940895318984985, 0.6345351338386536, -0.6480486392974854, 0.16629524528980255, -0.7518527507781982, 0.30389872193336487, -1.373713493347168, 0.2725466787815094, -2.876664400100708, 0.5602095723152161, -0.16879503428936005, -0.1564476490020752, -0.02983008697628975, -1.2810759544372559, 1.1344873905181885, 2.486395835876465, -1.0955605506896973, 0.4109835624694824, 0.3938705623149872, 1.1319488286972046, -1.55363929271698, 0.35362640023231506, -0.43883320689201355, 2.094778060913086, 0.19704481959342957, 1.200553059577942, -0.5440102815628052, -2.220036506652832, 0.6161743402481079, -1.2829309701919556, -1.1132440567016602, 0.7653447389602661, -0.9533716440200806, 0.21777492761611938, -1.417576789855957, -0.2280682772397995, -0.8547598719596863, -1.2457001209259033, 0.734086811542511, 0.07869444787502289, 0.3635224401950836, -0.5665944814682007, 0.38272830843925476, -2.2148053646087646, -1.4211468696594238, -0.2197791188955307, -0.9978074431419373, 0.5428399443626404, -0.3681091368198395, 0.6802266240119934, -0.13010546565055847, 0.038428351283073425, 0.2911674678325653, 1.4733928442001343, 3.4127070903778076, 0.32523852586746216, 0.3266867399215698, -0.09029389172792435, -0.9717475175857544, 1.4544471502304077, 0.965682864189148, -0.08959586173295975, -0.48331451416015625, -1.09120512008667, 1.2842903137207031, 1.9892685413360596, 1.1191376447677612, 0.007315543480217457, -0.7885444164276123, -0.8221646547317505, -0.036719419062137604, 0.1313009411096573, 0.43975067138671875, 0.883285403251648, 0.06011147424578667, 0.15242083370685577, 1.4449349641799927, 1.2534185647964478, -0.3780430555343628, 0.33621639013290405, -0.8612580895423889, -0.4719231426715851, 0.4623222351074219, 0.2607876658439636, 0.06774678826332092, 0.49230968952178955, -1.096044898033142, -0.33514025807380676, -0.401279479265213, -0.8460090756416321, -0.6856625080108643, -0.504044771194458, -0.4075830280780792, 1.5848872661590576, 0.06872796267271042, -0.48812136054039, 0.002833937294781208, -0.7639265656471252, -0.14563027024269104, -1.0990610122680664, 0.27646321058273315, -0.10856769979000092, -0.0943487212061882, -0.20295844972133636, 1.8088854551315308, -0.9383203387260437, -1.9881300926208496, 0.18310055136680603, 0.220003142952919, -0.32498452067375183, 0.19250606000423431, 1.6372534036636353, 0.5354539155960083, 1.3991668224334717, 1.3223921060562134, 0.9681270718574524, -0.6227550506591797, -1.2604701519012451, 0.6699007153511047, 0.9368879795074463, -1.3182939291000366, 0.8841263055801392, -0.08023892343044281, -0.5261224508285522, 0.670289158821106, 1.2614681720733643, 0.3958907425403595, -1.9766132831573486, 0.7686421275138855, -0.9113976955413818, 0.7665500640869141, 0.7264738082885742, 0.7847926616668701, 0.23383398354053497, 0.7679948806762695, -1.2432705163955688, -1.1427366733551025, -0.7430702447891235, -0.6911849975585938, 1.991919755935669, -0.32721391320228577, 0.6492979526519775, -0.22505755722522736, -1.2658588886260986, -0.12882377207279205, 0.7603615522384644, 0.37641018629074097, -0.5796117782592773, 0.8472975492477417, -0.5470536947250366, -0.9700535535812378, -1.3526233434677124, -0.40721720457077026, -1.0709816217422485, -0.9098271131515503, 1.0482467412948608, 0.7701202034950256, 0.38053444027900696, 1.9146872758865356, 0.6263715028762817, 0.39118126034736633, -2.651961088180542, 0.9047187566757202, 0.2384076565504074, -0.02246750518679619, 0.8436300158500671, 0.3204118609428406, 1.076316237449646, -0.07028038054704666, 0.6057063341140747, -2.398098945617676, 2.290457010269165, -0.21320530772209167, 0.7067474722862244, -0.03514181077480316, -0.20598989725112915, 1.1667441129684448, 0.5885010957717896, 0.5566425919532776, -1.1297390460968018, 0.6010459661483765, -0.5086235404014587, 1.1335786581039429, 0.8631130456924438, -0.8251655697822571, -0.0183926559984684, 1.4694699048995972, 0.5432165265083313, -0.4215676784515381, -0.9321690201759338, -0.9170418381690979, 0.97293621301651, 1.6719826459884644, -0.05348777770996094, -0.017302006483078003, 0.9583978652954102, 0.6477156281471252, -1.23298180103302, 0.030512921512126923, -0.7122933864593506, -0.6962363719940186, 1.6884628534317017, 2.1606192588806152, -0.1378113478422165, -0.2557796835899353, -0.6622726321220398, -1.257739543914795, 0.7722659111022949, -0.09347937256097794, 0.15552125871181488, 0.6112390160560608, -0.6647316813468933, 1.0930184125900269, 0.7674587368965149, 0.961369514465332, 0.09511017799377441, 0.298132061958313, 0.3674497604370117, -0.3321642279624939, -1.23108971118927, -0.2415143996477127, -1.0266393423080444, -2.5710337162017822, 0.4595392644405365, -0.1965290606021881, -1.472794532775879, 0.028997711837291718, -1.0561726093292236, 0.9746497869491577, -0.5710325241088867, -1.0471112728118896, -1.5257542133331299, 0.21373872458934784, -0.10305077582597733, 1.0077143907546997, -1.5986018180847168, -0.1280916929244995, 1.1943793296813965, 0.8714305758476257, -0.6443366408348083, 0.9823985695838928, 0.2326774150133133, 1.0020169019699097, 0.8269938826560974, -0.38921919465065, 0.5509389042854309, 0.0942930206656456, -1.3239675760269165, 0.3209018409252167, 1.1705552339553833, 0.15477709472179413, 1.4826397895812988, -0.5112027525901794, 0.09833025187253952, 0.48541226983070374, -0.5619628429412842, -0.4259290099143982, -0.4736140966415405, 0.6412429809570312, 0.10029027611017227, -0.9481306076049805, -0.042169176042079926, -0.048394616693258286, -0.26733630895614624, 0.14991413056850433, -1.4686601161956787, -0.19452422857284546, -0.3732765316963196, -0.6163476705551147, -1.2539457082748413, 0.025662317872047424, 1.3474268913269043, -0.788994550704956, -0.1485806107521057, 0.4868927597999573, 0.27676424384117126, 0.5628935694694519, 0.6290529370307922, -0.6759130954742432, -0.31581541895866394, -0.27771610021591187, -0.32411104440689087, 0.3983624279499054, 1.325646996498108, -0.10384325683116913, -0.9502344131469727, 0.6783227324485779, -0.29892095923423767, 0.11140289157629013, 2.0212130546569824, 0.06745800375938416, -0.735051155090332, 0.31184548139572144, -0.7089414596557617, 1.8248560428619385, 1.7696585655212402, 1.3648121356964111, -0.08324625343084335, -0.9048209190368652, 0.5285007953643799, -0.3022984564304352, -0.420695424079895, 0.9340500235557556, 0.3081754446029663, -0.19184738397598267, -1.4231053590774536, 0.7150299549102783, 1.323575496673584, -0.8807394504547119, -0.7437960505485535, 0.13529802858829498, -0.8582354784011841, 1.1417537927627563, 0.5278056859970093, 0.3527694344520569, 0.2164999395608902, 1.5316462516784668, 0.8379221558570862, -0.40446218848228455, 0.5421293377876282, 0.5979741811752319, -0.09970413148403168, -2.097017765045166, -1.1254937648773193, 0.316263347864151, -0.5970412492752075, -1.5948748588562012, 1.4051707983016968, -1.1367623805999756, -1.013636589050293, 0.5869330167770386, 0.011053030379116535, 1.4679208993911743, 0.4225228726863861, 1.5932072401046753, 2.1337890625, 0.8905709981918335, 0.39119666814804077, 1.2688528299331665, -0.1232394352555275, -0.4833497405052185, 1.8363460302352905, -0.48955464363098145, 0.47662392258644104, 1.0574580430984497, -0.3200167715549469, -1.0531432628631592, -0.7769061326980591, -1.2701131105422974, -0.7263450026512146, 1.1435704231262207, 0.08828649669885635, -1.074637770652771, 0.18989863991737366, 1.599711537361145, 0.06633450835943222, -0.30938369035720825, 0.6310035586357117, 0.3879331946372986, -0.8055700063705444, -0.03323743864893913, -0.879651665687561, 0.4929669499397278, -0.11260685324668884, -0.3366784155368805, 0.27480486035346985, 0.4455501437187195, 1.3298118114471436, -0.07871147245168686, 0.12048981338739395, 1.079525113105774, -1.4697239398956299, 1.5509672164916992, -0.6028942465782166, 0.21180826425552368, -2.4030210971832275, 1.435472846031189, -0.8193169832229614, 1.930879831314087, -2.629653215408325, 0.41127440333366394, -0.5464916229248047, -0.5551539063453674, 0.28460121154785156, -0.4377221465110779, 0.12968429923057556, -0.11436079442501068, -1.1049327850341797, -0.06317930668592453, -0.7042722702026367, 0.5463829040527344, 1.0851020812988281, 1.40921151638031, -1.157674789428711, -0.40770021080970764, -1.7145498991012573, -0.20103871822357178, -0.7489928603172302, 0.29447928071022034, -1.9565730094909668, -0.17728210985660553, -1.8816468715667725, -2.371725082397461, -1.3560575246810913, -0.8224871158599854, 1.0555187463760376, 0.08532694727182388, -0.9837125539779663, 1.209140419960022, -0.34002524614334106, -1.8627078533172607, 1.1219658851623535, -2.172804117202759 ]
https://github.com/huggingface/datasets/issues/5179
`map()` fails midway due to format incompatibility
You can end up with a list instead of a tensor if all the tensors inside the list can't be stacked together - can you make sure all your inputs are tensors with the same shape ?
### Describe the bug I am using the `emotion` dataset from Hub for sequence classification. After training the model, I am using it to generate predictions for all the entries present in the `validation` split of the dataset. ```py def get_test_accuracy(model): def fn(batch): inputs = {k:v.to(device) for k,v in batch.items() if k in tokenizer.model_input_names} with torch.no_grad(): output = model(**inputs) pred_label = torch.argmax(output.logits, axis=-1) return {"predicted_label": pred_label.cpu().numpy()} return fn ``` This is how the `get_test_accuracy()` is being used: ```py emotions = load_dataset("emotion") def tokenize(batch): return tokenizer(batch["text"], padding=True, truncation=True) emotions_encoded = emotions.map(tokenize, batched=True) emotions_encoded.set_format("torch", columns=["input_ids", "attention_mask", "label"]) new_dataset = emotions_encoded["validation"].map( accuracy_fn, batched=True, batch_size=128 ) ``` Complete code is available in the Colab Notebook provided below. The `map()` process fails midway giving: ```shell AttributeError Traceback (most recent call last) <ipython-input-8-ad24ac288eb4> in <module> 2 3 new_dataset = emotions_encoded["validation"].map( ----> 4 accuracy_fn, batched=True, batch_size=128 5 ) 7 frames /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in map(self, function, with_indices, with_rank, input_columns, batched, batch_size, drop_last_batch, remove_columns, keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, features, disable_nullable, fn_kwargs, num_proc, suffix_template, new_fingerprint, desc) 2588 new_fingerprint=new_fingerprint, 2589 disable_tqdm=disable_tqdm, -> 2590 desc=desc, 2591 ) 2592 else: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in wrapper(*args, **kwargs) 582 self: "Dataset" = kwargs.pop("self") 583 # apply actual function --> 584 out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs) 585 datasets: List["Dataset"] = list(out.values()) if isinstance(out, dict) else [out] 586 for dataset in datasets: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in wrapper(*args, **kwargs) 549 } 550 # apply actual function --> 551 out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs) 552 datasets: List["Dataset"] = list(out.values()) if isinstance(out, dict) else [out] 553 # re-apply format to the output /usr/local/lib/python3.7/dist-packages/datasets/fingerprint.py in wrapper(*args, **kwargs) 478 # Call actual function 479 --> 480 out = func(self, *args, **kwargs) 481 482 # Update fingerprint of in-place transforms + update in-place history of transforms /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in _map_single(self, function, with_indices, with_rank, input_columns, batched, batch_size, drop_last_batch, remove_columns, keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, features, disable_nullable, fn_kwargs, new_fingerprint, rank, offset, disable_tqdm, desc, cache_only) 2970 indices, 2971 check_same_num_examples=len(input_dataset.list_indexes()) > 0, -> 2972 offset=offset, 2973 ) 2974 except NumExamplesMismatchError: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in apply_function_on_filtered_inputs(inputs, indices, check_same_num_examples, offset) 2850 if with_rank: 2851 additional_args += (rank,) -> 2852 processed_inputs = function(*fn_args, *additional_args, **fn_kwargs) 2853 if update_data is None: 2854 # Check if the function returns updated examples <ipython-input-6-4e0d280426f6> in fn(batch) 1 def get_test_accuracy(model): 2 def fn(batch): ----> 3 inputs = {k:v.to(device) for k,v in batch.items() 4 if k in tokenizer.model_input_names} 5 with torch.no_grad(): <ipython-input-6-4e0d280426f6> in <dictcomp>(.0) 2 def fn(batch): 3 inputs = {k:v.to(device) for k,v in batch.items() ----> 4 if k in tokenizer.model_input_names} 5 with torch.no_grad(): 6 output = model(**inputs) AttributeError: 'list' object has no attribute 'to' ``` As you'd notice in the notebook, the process fails _midway_ and not at the beginning. Is this expected? ### Steps to reproduce the bug Colab Notebook: https://colab.research.google.com/gist/sayakpaul/d1570d537faf39040d02d77b1ed7de07/scratchpad.ipynb ### Expected behavior The mapping process should complete as is. If you switch the `split` to `test` it works as expected. ### Environment info Colab
450
37
`map()` fails midway due to format incompatibility ### Describe the bug I am using the `emotion` dataset from Hub for sequence classification. After training the model, I am using it to generate predictions for all the entries present in the `validation` split of the dataset. ```py def get_test_accuracy(model): def fn(batch): inputs = {k:v.to(device) for k,v in batch.items() if k in tokenizer.model_input_names} with torch.no_grad(): output = model(**inputs) pred_label = torch.argmax(output.logits, axis=-1) return {"predicted_label": pred_label.cpu().numpy()} return fn ``` This is how the `get_test_accuracy()` is being used: ```py emotions = load_dataset("emotion") def tokenize(batch): return tokenizer(batch["text"], padding=True, truncation=True) emotions_encoded = emotions.map(tokenize, batched=True) emotions_encoded.set_format("torch", columns=["input_ids", "attention_mask", "label"]) new_dataset = emotions_encoded["validation"].map( accuracy_fn, batched=True, batch_size=128 ) ``` Complete code is available in the Colab Notebook provided below. The `map()` process fails midway giving: ```shell AttributeError Traceback (most recent call last) <ipython-input-8-ad24ac288eb4> in <module> 2 3 new_dataset = emotions_encoded["validation"].map( ----> 4 accuracy_fn, batched=True, batch_size=128 5 ) 7 frames /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in map(self, function, with_indices, with_rank, input_columns, batched, batch_size, drop_last_batch, remove_columns, keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, features, disable_nullable, fn_kwargs, num_proc, suffix_template, new_fingerprint, desc) 2588 new_fingerprint=new_fingerprint, 2589 disable_tqdm=disable_tqdm, -> 2590 desc=desc, 2591 ) 2592 else: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in wrapper(*args, **kwargs) 582 self: "Dataset" = kwargs.pop("self") 583 # apply actual function --> 584 out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs) 585 datasets: List["Dataset"] = list(out.values()) if isinstance(out, dict) else [out] 586 for dataset in datasets: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in wrapper(*args, **kwargs) 549 } 550 # apply actual function --> 551 out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs) 552 datasets: List["Dataset"] = list(out.values()) if isinstance(out, dict) else [out] 553 # re-apply format to the output /usr/local/lib/python3.7/dist-packages/datasets/fingerprint.py in wrapper(*args, **kwargs) 478 # Call actual function 479 --> 480 out = func(self, *args, **kwargs) 481 482 # Update fingerprint of in-place transforms + update in-place history of transforms /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in _map_single(self, function, with_indices, with_rank, input_columns, batched, batch_size, drop_last_batch, remove_columns, keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, features, disable_nullable, fn_kwargs, new_fingerprint, rank, offset, disable_tqdm, desc, cache_only) 2970 indices, 2971 check_same_num_examples=len(input_dataset.list_indexes()) > 0, -> 2972 offset=offset, 2973 ) 2974 except NumExamplesMismatchError: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in apply_function_on_filtered_inputs(inputs, indices, check_same_num_examples, offset) 2850 if with_rank: 2851 additional_args += (rank,) -> 2852 processed_inputs = function(*fn_args, *additional_args, **fn_kwargs) 2853 if update_data is None: 2854 # Check if the function returns updated examples <ipython-input-6-4e0d280426f6> in fn(batch) 1 def get_test_accuracy(model): 2 def fn(batch): ----> 3 inputs = {k:v.to(device) for k,v in batch.items() 4 if k in tokenizer.model_input_names} 5 with torch.no_grad(): <ipython-input-6-4e0d280426f6> in <dictcomp>(.0) 2 def fn(batch): 3 inputs = {k:v.to(device) for k,v in batch.items() ----> 4 if k in tokenizer.model_input_names} 5 with torch.no_grad(): 6 output = model(**inputs) AttributeError: 'list' object has no attribute 'to' ``` As you'd notice in the notebook, the process fails _midway_ and not at the beginning. Is this expected? ### Steps to reproduce the bug Colab Notebook: https://colab.research.google.com/gist/sayakpaul/d1570d537faf39040d02d77b1ed7de07/scratchpad.ipynb ### Expected behavior The mapping process should complete as is. If you switch the `split` to `test` it works as expected. ### Environment info Colab You can end up with a list instead of a tensor if all the tensors inside the list can't be stacked together - can you make sure all your inputs are tensors with the same shape ?
[ -1.2564349174499512, -0.8618111610412598, -0.6586883068084717, 1.5509893894195557, -0.11722970008850098, -1.2016878128051758, 0.3056619465351105, -1.071123480796814, 1.6652281284332275, -0.8826600909233093, 0.3184569478034973, -1.5744513273239136, 0.06408709287643433, -0.6032147407531738, -0.7170072793960571, -0.827620267868042, -0.391541451215744, -0.7243706583976746, 1.102968454360962, 2.441807985305786, 1.345527172088623, -1.3015437126159668, 2.7619075775146484, 0.7074694037437439, -0.23903891444206238, -1.027679204940796, 0.5006363391876221, -0.04980858787894249, -1.2392507791519165, -0.48583224415779114, -0.9670151472091675, -0.09760599583387375, -0.6154596209526062, -0.4936542510986328, -0.030476875603199005, 0.4526210129261017, -0.34846463799476624, -0.4001949429512024, -0.5780141949653625, -0.8301367163658142, 0.5327627062797546, -0.32234451174736023, 0.9258394241333008, -0.2610061764717102, 1.7740511894226074, -0.6517888307571411, 0.5122497081756592, 0.7529274821281433, 1.3074336051940918, 0.17150403559207916, -0.0720311775803566, 0.36685800552368164, 0.35100361704826355, 0.02520972117781639, 0.5899772047996521, 1.2242026329040527, 0.6695250868797302, 0.5533755421638489, 0.67540043592453, -2.2437541484832764, 1.3265388011932373, -1.0817766189575195, 0.3195015788078308, 1.289945125579834, -0.9156166911125183, 0.28408458828926086, -1.7497355937957764, -0.0831250324845314, 0.5423450469970703, -2.2372968196868896, 0.3418833613395691, -1.3627794981002808, -0.5304228663444519, 0.9875593185424805, 0.34581151604652405, -1.2076531648635864, 0.13749630749225616, -0.44156789779663086, 1.0876474380493164, 0.4285399913787842, 1.0058739185333252, -1.7119542360305786, -0.02024657279253006, -0.2667766511440277, 0.2199711948633194, -1.2193071842193604, -1.5961761474609375, 0.6284483671188354, 0.5396755933761597, 0.525274932384491, -0.1628008335828781, 1.1209796667099, -1.128803014755249, 0.8071145415306091, -1.070693850517273, -1.688642144203186, -1.4215937852859497, -2.2521371841430664, -2.191432476043701, 0.654498815536499, -0.5312331318855286, -0.5206457376480103, 2.0725271701812744, -0.981368362903595, -1.6730248928070068, 1.139477252960205, 0.24169321358203888, -0.0005769440904259682, 2.348796844482422, 0.20958605408668518, -0.671931803226471, 0.4880581200122833, -0.8086337447166443, 0.7906571626663208, -0.3038729429244995, 1.3495352268218994, 0.4183017611503601, -1.0876206159591675, 1.5978964567184448, -0.37174084782600403, 0.5705781579017639, -0.553147554397583, -0.5441300272941589, -0.7247528433799744, 0.23205667734146118, 1.881868839263916, -0.2922987639904022, 1.4447945356369019, -0.3401529788970947, -1.502456784248352, -1.6106919050216675, 0.9807024598121643, 0.4544409215450287, -0.8311120867729187, 0.18271294236183167, -0.5307923555374146, 0.16542144119739532, -0.05783570185303688, 1.2451820373535156, 1.3419694900512695, 0.7997744083404541, -0.3967094421386719, -0.7611581683158875, 0.13777358829975128, -0.07958602160215378, -0.7141509652137756, -1.7604843378067017, -0.38904649019241333, 0.11336493492126465, 0.6691190004348755, -1.103524088859558, 1.837209701538086, 0.9380624294281006, 1.8849183320999146, 1.0147721767425537, -0.37624239921569824, 1.4652131795883179, 0.08214523643255234, 1.8020519018173218, -0.5186798572540283, 0.6336647272109985, -0.4189484715461731, -1.1765495538711548, 0.8918150663375854, -0.3119543194770813, -2.069382905960083, -0.7765493988990784, -0.7259145379066467, -0.1854252964258194, -0.8750786781311035, 0.930161714553833, -0.293204128742218, -1.4624985456466675, 0.20235463976860046, -0.7065148949623108, 0.14351630210876465, -1.1823662519454956, 0.3289157748222351, 0.6754565238952637, -0.650816023349762, 0.10384839028120041, -0.231216698884964, -1.2386047840118408, -0.516243577003479, 0.26797279715538025, 1.8828272819519043, -0.6313206553459167, 0.9253871440887451, 1.0674333572387695, -0.6744243502616882, -0.0685236006975174, 0.2832387685775757, -0.3361179530620575, 0.8468278646469116, -1.0320188999176025, -0.537996768951416, 1.2224764823913574, -0.19796226918697357, -0.5550762414932251, 1.4795533418655396, 0.6074240207672119, -1.0154998302459717, -0.2785501778125763, -0.1537284553050995, -0.8851861357688904, 0.09792763739824295, -1.5087882280349731, -0.14053253829479218, 0.5158325433731079, -1.5553847551345825, -0.4324536621570587, -0.16466334462165833, 1.3224083185195923, -0.19398628175258636, 1.489725947380066, -0.37042659521102905, -0.16392745077610016, -0.2994914650917053, -0.3450047969818115, 0.15702687203884125, -0.09183439612388611, -0.6712797284126282, 0.12571211159229279, -0.8052224516868591, 0.38129231333732605, 1.4665462970733643, 0.2486332207918167, 0.02911742776632309, 0.45866236090660095, 1.100577473640442, 0.3628608286380768, -0.08157375454902649, -0.9239226579666138, -1.5509613752365112, 1.9792550802230835, -1.4797959327697754, 2.00675892829895, 0.7830439805984497, -0.08020652085542679, -1.8123866319656372, -1.7918002605438232, 1.3311359882354736, 1.1580243110656738, 2.3174266815185547, 0.5244920253753662, 0.4165392220020294, -0.7668754458427429, -0.6583884954452515, 0.30397865176200867, -1.0827196836471558, -0.6753581166267395, 0.23990613222122192, 2.4044692516326904, 1.781298279762268, -0.4425797164440155, -0.19101209938526154, -0.9829928278923035, 1.3376902341842651, -0.28112199902534485, 0.21211613714694977, 1.9484807252883911, -0.2299797385931015, -1.0529167652130127, 1.3466925621032715, -2.3654701709747314, 0.22468525171279907, 2.0508697032928467, 0.3507494032382965, 0.12460658699274063, -1.3239268064498901, -0.5475836396217346, -0.28874456882476807, -0.46919599175453186, -1.2885594367980957, 0.4973348081111908, -0.18551316857337952, -0.7874863147735596, -1.348490595817566, 0.19899608194828033, -1.122996211051941, -1.695956826210022, 0.23043550550937653, 1.9107682704925537, 2.1109068393707275, -0.7488948106765747, 1.5649986267089844, -0.42424625158309937, 0.16996417939662933, 1.2032641172409058, 1.312498688697815, 3.071192741394043, 1.8642898797988892, -1.3581467866897583, 0.6676552295684814, -0.2173980325460434, -0.559167206287384, 1.1652779579162598, -1.2637075185775757, 1.264624834060669, -0.11867415904998779, -1.2049411535263062, -1.2521247863769531, 1.0117484331130981, 0.4367265999317169, 0.05127795785665512, -0.4933066666126251, 1.1553038358688354, 0.15893927216529846, 1.3814609050750732, 0.5917761325836182, -0.3316621482372284, 0.6258667707443237, -0.4016607999801636, -0.4500105082988739, 1.5580692291259766, 0.18183785676956177, -1.4025628566741943, -2.283634901046753, -0.14928534626960754, -0.8979191780090332, 0.14238892495632172, -0.6187760233879089, -0.9766247868537903, 1.6309442520141602, 0.3100856840610504, -1.230992078781128, -0.2641846537590027, -0.36611834168434143, -0.5520333051681519, 2.7195887565612793, -1.2184863090515137, -0.2524767220020294, -0.9723224639892578, -0.7886156439781189, 1.59701669216156, -1.2435729503631592, -0.2156052440404892, -0.9555762410163879, -0.5506362915039062, -1.2841285467147827, -0.5390051603317261, 0.04608776420354843, -0.965511679649353, 0.7735902070999146, 0.18929684162139893, -1.2301790714263916, -0.42056599259376526, -0.7898242473602295, 0.9418392777442932, -0.24473094940185547, 0.15271149575710297, 1.8207292556762695, 0.2454354614019394, -0.35870057344436646, 0.8547343015670776, 1.1780147552490234, 0.609052300453186, -0.5519440174102783, 0.1613217294216156, -0.6711052656173706, 0.3499176800251007, -1.2448660135269165, 0.3145863711833954, -2.8695645332336426, 0.671040952205658, -0.021004751324653625, -0.09424528479576111, -0.08122210949659348, -1.4300894737243652, 1.0155657529830933, 2.6010677814483643, -1.1604251861572266, 0.5007954239845276, 0.32741987705230713, 1.1422251462936401, -1.591278314590454, 0.21408309042453766, -0.49440354108810425, 2.0756351947784424, 0.28954532742500305, 1.2567297220230103, -0.45648178458213806, -2.3433303833007812, 0.6205129623413086, -1.3557045459747314, -1.15959632396698, 0.7685874104499817, -0.8521873354911804, 0.1507054567337036, -1.339126706123352, -0.27235254645347595, -0.8838710188865662, -1.1251634359359741, 0.637652575969696, 0.14716266095638275, 0.4194837212562561, -0.6093424558639526, 0.30907759070396423, -2.2107105255126953, -1.3018547296524048, -0.14408697187900543, -0.977510392665863, 0.5190096497535706, -0.48462551832199097, 0.7006571888923645, -0.11337742954492569, -0.013470589183270931, 0.4146192669868469, 1.5095349550247192, 3.386756658554077, 0.2199634462594986, 0.2824596166610718, -0.2776835262775421, -0.9641700387001038, 1.5215599536895752, 0.8457326889038086, -0.17773663997650146, -0.5651062726974487, -1.0686368942260742, 1.256855845451355, 1.8958994150161743, 0.8588723540306091, 0.02651117742061615, -0.8922290802001953, -0.7044177055358887, -0.052574142813682556, 0.11829269677400589, 0.4314849078655243, 0.9280596375465393, 0.13030695915222168, 0.04300333186984062, 1.4032280445098877, 1.1352241039276123, -0.4024324119091034, 0.3544304072856903, -0.8399837017059326, -0.3837916851043701, 0.5275399684906006, 0.27099207043647766, -0.038755375891923904, 0.3699900507926941, -0.920984148979187, -0.2893209457397461, -0.3933523893356323, -0.8521087765693665, -0.7494899034500122, -0.4101017713546753, -0.37057560682296753, 1.6459875106811523, 0.13157469034194946, -0.4926767945289612, -0.02535157836973667, -0.7864295244216919, -0.1456502079963684, -1.1047048568725586, 0.20037318766117096, -0.06104257330298424, -0.14033475518226624, -0.15852662920951843, 1.7353472709655762, -0.8827623128890991, -2.0497517585754395, 0.1912117898464203, 0.20480452477931976, -0.22941423952579498, 0.2140512466430664, 1.6909289360046387, 0.4844909906387329, 1.4448579549789429, 1.2889355421066284, 0.9701460599899292, -0.6217978000640869, -1.2950255870819092, 0.7722205519676208, 0.9390353560447693, -1.3919720649719238, 0.8187793493270874, -0.07688263058662415, -0.4715798795223236, 0.6058039665222168, 1.1926673650741577, 0.5125511884689331, -1.9851857423782349, 0.8043025135993958, -1.0349947214126587, 0.8150075078010559, 0.7428379654884338, 0.6157976388931274, 0.2448112517595291, 0.8692721724510193, -1.2233421802520752, -1.1115431785583496, -0.6526858806610107, -0.7141526937484741, 2.0142617225646973, -0.35835039615631104, 0.6308340430259705, -0.2381220906972885, -1.3672821521759033, -0.08315305411815643, 0.7389456629753113, 0.3749692142009735, -0.506883978843689, 0.7433762550354004, -0.7123759388923645, -1.0244725942611694, -1.3419419527053833, -0.4537983536720276, -1.1077501773834229, -1.023657202720642, 1.0641082525253296, 0.6988312005996704, 0.3103312849998474, 1.9031773805618286, 0.6459838151931763, 0.2619236707687378, -2.537459135055542, 0.861052930355072, 0.2601129412651062, -0.09079334139823914, 0.8776627779006958, 0.46942517161369324, 1.0049712657928467, 0.015680667012929916, 0.6060882806777954, -2.4960954189300537, 2.356536865234375, -0.12105764448642731, 0.7078245878219604, 0.07416543364524841, -0.24286387860774994, 1.173863172531128, 0.5792101621627808, 0.47801917791366577, -1.0627354383468628, 0.6155811548233032, -0.5743517875671387, 1.2609212398529053, 0.8360148072242737, -0.8362006545066833, -0.002662207931280136, 1.3921946287155151, 0.46437886357307434, -0.5007355809211731, -0.9238314032554626, -0.956911027431488, 0.9564623236656189, 1.6793441772460938, -0.05409897863864899, -0.02257390320301056, 0.7253323197364807, 0.7134193181991577, -1.258240818977356, 0.0881405770778656, -0.6925987005233765, -0.7618107795715332, 1.6358152627944946, 2.0891144275665283, -0.21775691211223602, -0.17107610404491425, -0.6862389445304871, -1.3521744012832642, 0.8534873127937317, -0.09288079291582108, 0.10966837406158447, 0.6103137731552124, -0.5857788324356079, 0.969518780708313, 0.8980392813682556, 0.930030107498169, 0.2913565933704376, 0.29146233201026917, 0.394858181476593, -0.3791663348674774, -1.116383671760559, -0.22212131321430206, -1.093349814414978, -2.678900718688965, 0.4207954406738281, -0.2652113139629364, -1.3707736730575562, 0.03746476396918297, -0.9597068428993225, 0.8683139085769653, -0.6084392070770264, -1.1210410594940186, -1.4711421728134155, 0.24895964562892914, 0.006735139526426792, 0.9902312159538269, -1.604506492614746, -0.17397285997867584, 1.1914445161819458, 0.8709969520568848, -0.7049355506896973, 0.9642133116722107, 0.2078114151954651, 1.0250040292739868, 0.8568227887153625, -0.4181331396102905, 0.6182434558868408, 0.03507668152451515, -1.3783280849456787, 0.4445445239543915, 1.2207696437835693, 0.23791398108005524, 1.5120775699615479, -0.38951700925827026, 0.018091395497322083, 0.42769789695739746, -0.6623564958572388, -0.5585848689079285, -0.41871777176856995, 0.5870958566665649, 0.028583165258169174, -0.9827859401702881, -0.09199051558971405, -0.03534920886158943, -0.31863588094711304, 0.1888469159603119, -1.4407734870910645, -0.1417376548051834, -0.4051297903060913, -0.600477397441864, -1.2937644720077515, -0.12243188917636871, 1.4057859182357788, -0.7638819813728333, -0.16007228195667267, 0.40202417969703674, 0.3811003863811493, 0.51077800989151, 0.6530059576034546, -0.8079514503479004, -0.3516363501548767, -0.2352105975151062, -0.3383120000362396, 0.4119672179222107, 1.3774250745773315, -0.08127759397029877, -0.9346227049827576, 0.6019138693809509, -0.3113865852355957, 0.09594712406396866, 1.8889340162277222, 0.064056895673275, -0.7672309279441833, 0.29870420694351196, -0.7527433037757874, 1.8976861238479614, 1.7361884117126465, 1.2734543085098267, -0.1465306133031845, -0.84157395362854, 0.6844934225082397, -0.4384704530239105, -0.3459400534629822, 0.868216872215271, 0.3207721412181854, -0.2318442314863205, -1.5236824750900269, 0.7911661267280579, 1.3275882005691528, -0.7890422344207764, -0.8569883108139038, 0.15691283345222473, -0.7737320065498352, 1.194298505783081, 0.5839184522628784, 0.32634270191192627, 0.2878434956073761, 1.6030879020690918, 0.8075254559516907, -0.40163421630859375, 0.5591980218887329, 0.5148944854736328, -0.1539243757724762, -2.205169200897217, -1.2601948976516724, 0.3416507840156555, -0.5841649770736694, -1.5605953931808472, 1.4439810514450073, -1.0924017429351807, -1.112066626548767, 0.5980516672134399, 0.08635575324296951, 1.3276584148406982, 0.3924199938774109, 1.5543813705444336, 2.0440750122070312, 0.7962685823440552, 0.43006181716918945, 1.22671639919281, -0.1449178159236908, -0.48397305607795715, 1.7556226253509521, -0.41754817962646484, 0.49532386660575867, 1.1325857639312744, -0.27241015434265137, -1.1654233932495117, -0.8186470866203308, -1.2690367698669434, -0.798886775970459, 1.1543046236038208, 0.08968789130449295, -1.0725897550582886, 0.26485493779182434, 1.6204137802124023, 0.1732502430677414, -0.253827840089798, 0.6367133855819702, 0.4354454278945923, -0.7482894062995911, -0.011351436376571655, -0.8824612498283386, 0.5348762273788452, -0.2903853952884674, -0.37671464681625366, 0.32501861453056335, 0.48895135521888733, 1.3226211071014404, -0.05089137703180313, 0.05348017439246178, 1.0252052545547485, -1.467864990234375, 1.4771651029586792, -0.658483624458313, 0.3264654874801636, -2.357149600982666, 1.3275173902511597, -0.7595835328102112, 2.001539707183838, -2.663938283920288, 0.47669604420661926, -0.549942135810852, -0.49217116832733154, 0.28631314635276794, -0.31725940108299255, 0.09084171056747437, -0.131460040807724, -1.101257562637329, -0.0536457821726799, -0.6570311784744263, 0.6248765587806702, 1.1304302215576172, 1.3858965635299683, -1.1660349369049072, -0.23406395316123962, -1.6564133167266846, -0.034714408218860626, -0.743509829044342, 0.17763105034828186, -1.956472635269165, -0.21818798780441284, -1.9411677122116089, -2.355215311050415, -1.2008016109466553, -0.7569925785064697, 1.1258121728897095, 0.13358688354492188, -0.8405548930168152, 1.3179728984832764, -0.398405522108078, -1.8127456903457642, 1.0479952096939087, -2.151811361312866 ]
https://github.com/huggingface/datasets/issues/5179
`map()` fails midway due to format incompatibility
I modified my `tokenize()` function to be like so: ```py def tokenize(batch): return tokenizer(batch["text"], padding="longest") ``` so that the padding always happens w.r.t to the length of the longest sequence in a batch. The issue still persists. Is there any other way?
### Describe the bug I am using the `emotion` dataset from Hub for sequence classification. After training the model, I am using it to generate predictions for all the entries present in the `validation` split of the dataset. ```py def get_test_accuracy(model): def fn(batch): inputs = {k:v.to(device) for k,v in batch.items() if k in tokenizer.model_input_names} with torch.no_grad(): output = model(**inputs) pred_label = torch.argmax(output.logits, axis=-1) return {"predicted_label": pred_label.cpu().numpy()} return fn ``` This is how the `get_test_accuracy()` is being used: ```py emotions = load_dataset("emotion") def tokenize(batch): return tokenizer(batch["text"], padding=True, truncation=True) emotions_encoded = emotions.map(tokenize, batched=True) emotions_encoded.set_format("torch", columns=["input_ids", "attention_mask", "label"]) new_dataset = emotions_encoded["validation"].map( accuracy_fn, batched=True, batch_size=128 ) ``` Complete code is available in the Colab Notebook provided below. The `map()` process fails midway giving: ```shell AttributeError Traceback (most recent call last) <ipython-input-8-ad24ac288eb4> in <module> 2 3 new_dataset = emotions_encoded["validation"].map( ----> 4 accuracy_fn, batched=True, batch_size=128 5 ) 7 frames /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in map(self, function, with_indices, with_rank, input_columns, batched, batch_size, drop_last_batch, remove_columns, keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, features, disable_nullable, fn_kwargs, num_proc, suffix_template, new_fingerprint, desc) 2588 new_fingerprint=new_fingerprint, 2589 disable_tqdm=disable_tqdm, -> 2590 desc=desc, 2591 ) 2592 else: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in wrapper(*args, **kwargs) 582 self: "Dataset" = kwargs.pop("self") 583 # apply actual function --> 584 out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs) 585 datasets: List["Dataset"] = list(out.values()) if isinstance(out, dict) else [out] 586 for dataset in datasets: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in wrapper(*args, **kwargs) 549 } 550 # apply actual function --> 551 out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs) 552 datasets: List["Dataset"] = list(out.values()) if isinstance(out, dict) else [out] 553 # re-apply format to the output /usr/local/lib/python3.7/dist-packages/datasets/fingerprint.py in wrapper(*args, **kwargs) 478 # Call actual function 479 --> 480 out = func(self, *args, **kwargs) 481 482 # Update fingerprint of in-place transforms + update in-place history of transforms /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in _map_single(self, function, with_indices, with_rank, input_columns, batched, batch_size, drop_last_batch, remove_columns, keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, features, disable_nullable, fn_kwargs, new_fingerprint, rank, offset, disable_tqdm, desc, cache_only) 2970 indices, 2971 check_same_num_examples=len(input_dataset.list_indexes()) > 0, -> 2972 offset=offset, 2973 ) 2974 except NumExamplesMismatchError: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in apply_function_on_filtered_inputs(inputs, indices, check_same_num_examples, offset) 2850 if with_rank: 2851 additional_args += (rank,) -> 2852 processed_inputs = function(*fn_args, *additional_args, **fn_kwargs) 2853 if update_data is None: 2854 # Check if the function returns updated examples <ipython-input-6-4e0d280426f6> in fn(batch) 1 def get_test_accuracy(model): 2 def fn(batch): ----> 3 inputs = {k:v.to(device) for k,v in batch.items() 4 if k in tokenizer.model_input_names} 5 with torch.no_grad(): <ipython-input-6-4e0d280426f6> in <dictcomp>(.0) 2 def fn(batch): 3 inputs = {k:v.to(device) for k,v in batch.items() ----> 4 if k in tokenizer.model_input_names} 5 with torch.no_grad(): 6 output = model(**inputs) AttributeError: 'list' object has no attribute 'to' ``` As you'd notice in the notebook, the process fails _midway_ and not at the beginning. Is this expected? ### Steps to reproduce the bug Colab Notebook: https://colab.research.google.com/gist/sayakpaul/d1570d537faf39040d02d77b1ed7de07/scratchpad.ipynb ### Expected behavior The mapping process should complete as is. If you switch the `split` to `test` it works as expected. ### Environment info Colab
450
42
`map()` fails midway due to format incompatibility ### Describe the bug I am using the `emotion` dataset from Hub for sequence classification. After training the model, I am using it to generate predictions for all the entries present in the `validation` split of the dataset. ```py def get_test_accuracy(model): def fn(batch): inputs = {k:v.to(device) for k,v in batch.items() if k in tokenizer.model_input_names} with torch.no_grad(): output = model(**inputs) pred_label = torch.argmax(output.logits, axis=-1) return {"predicted_label": pred_label.cpu().numpy()} return fn ``` This is how the `get_test_accuracy()` is being used: ```py emotions = load_dataset("emotion") def tokenize(batch): return tokenizer(batch["text"], padding=True, truncation=True) emotions_encoded = emotions.map(tokenize, batched=True) emotions_encoded.set_format("torch", columns=["input_ids", "attention_mask", "label"]) new_dataset = emotions_encoded["validation"].map( accuracy_fn, batched=True, batch_size=128 ) ``` Complete code is available in the Colab Notebook provided below. The `map()` process fails midway giving: ```shell AttributeError Traceback (most recent call last) <ipython-input-8-ad24ac288eb4> in <module> 2 3 new_dataset = emotions_encoded["validation"].map( ----> 4 accuracy_fn, batched=True, batch_size=128 5 ) 7 frames /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in map(self, function, with_indices, with_rank, input_columns, batched, batch_size, drop_last_batch, remove_columns, keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, features, disable_nullable, fn_kwargs, num_proc, suffix_template, new_fingerprint, desc) 2588 new_fingerprint=new_fingerprint, 2589 disable_tqdm=disable_tqdm, -> 2590 desc=desc, 2591 ) 2592 else: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in wrapper(*args, **kwargs) 582 self: "Dataset" = kwargs.pop("self") 583 # apply actual function --> 584 out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs) 585 datasets: List["Dataset"] = list(out.values()) if isinstance(out, dict) else [out] 586 for dataset in datasets: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in wrapper(*args, **kwargs) 549 } 550 # apply actual function --> 551 out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs) 552 datasets: List["Dataset"] = list(out.values()) if isinstance(out, dict) else [out] 553 # re-apply format to the output /usr/local/lib/python3.7/dist-packages/datasets/fingerprint.py in wrapper(*args, **kwargs) 478 # Call actual function 479 --> 480 out = func(self, *args, **kwargs) 481 482 # Update fingerprint of in-place transforms + update in-place history of transforms /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in _map_single(self, function, with_indices, with_rank, input_columns, batched, batch_size, drop_last_batch, remove_columns, keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, features, disable_nullable, fn_kwargs, new_fingerprint, rank, offset, disable_tqdm, desc, cache_only) 2970 indices, 2971 check_same_num_examples=len(input_dataset.list_indexes()) > 0, -> 2972 offset=offset, 2973 ) 2974 except NumExamplesMismatchError: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in apply_function_on_filtered_inputs(inputs, indices, check_same_num_examples, offset) 2850 if with_rank: 2851 additional_args += (rank,) -> 2852 processed_inputs = function(*fn_args, *additional_args, **fn_kwargs) 2853 if update_data is None: 2854 # Check if the function returns updated examples <ipython-input-6-4e0d280426f6> in fn(batch) 1 def get_test_accuracy(model): 2 def fn(batch): ----> 3 inputs = {k:v.to(device) for k,v in batch.items() 4 if k in tokenizer.model_input_names} 5 with torch.no_grad(): <ipython-input-6-4e0d280426f6> in <dictcomp>(.0) 2 def fn(batch): 3 inputs = {k:v.to(device) for k,v in batch.items() ----> 4 if k in tokenizer.model_input_names} 5 with torch.no_grad(): 6 output = model(**inputs) AttributeError: 'list' object has no attribute 'to' ``` As you'd notice in the notebook, the process fails _midway_ and not at the beginning. Is this expected? ### Steps to reproduce the bug Colab Notebook: https://colab.research.google.com/gist/sayakpaul/d1570d537faf39040d02d77b1ed7de07/scratchpad.ipynb ### Expected behavior The mapping process should complete as is. If you switch the `split` to `test` it works as expected. ### Environment info Colab I modified my `tokenize()` function to be like so: ```py def tokenize(batch): return tokenizer(batch["text"], padding="longest") ``` so that the padding always happens w.r.t to the length of the longest sequence in a batch. The issue still persists. Is there any other way?
[ -1.2564349174499512, -0.8618111610412598, -0.6586883068084717, 1.5509893894195557, -0.11722970008850098, -1.2016878128051758, 0.3056619465351105, -1.071123480796814, 1.6652281284332275, -0.8826600909233093, 0.3184569478034973, -1.5744513273239136, 0.06408709287643433, -0.6032147407531738, -0.7170072793960571, -0.827620267868042, -0.391541451215744, -0.7243706583976746, 1.102968454360962, 2.441807985305786, 1.345527172088623, -1.3015437126159668, 2.7619075775146484, 0.7074694037437439, -0.23903891444206238, -1.027679204940796, 0.5006363391876221, -0.04980858787894249, -1.2392507791519165, -0.48583224415779114, -0.9670151472091675, -0.09760599583387375, -0.6154596209526062, -0.4936542510986328, -0.030476875603199005, 0.4526210129261017, -0.34846463799476624, -0.4001949429512024, -0.5780141949653625, -0.8301367163658142, 0.5327627062797546, -0.32234451174736023, 0.9258394241333008, -0.2610061764717102, 1.7740511894226074, -0.6517888307571411, 0.5122497081756592, 0.7529274821281433, 1.3074336051940918, 0.17150403559207916, -0.0720311775803566, 0.36685800552368164, 0.35100361704826355, 0.02520972117781639, 0.5899772047996521, 1.2242026329040527, 0.6695250868797302, 0.5533755421638489, 0.67540043592453, -2.2437541484832764, 1.3265388011932373, -1.0817766189575195, 0.3195015788078308, 1.289945125579834, -0.9156166911125183, 0.28408458828926086, -1.7497355937957764, -0.0831250324845314, 0.5423450469970703, -2.2372968196868896, 0.3418833613395691, -1.3627794981002808, -0.5304228663444519, 0.9875593185424805, 0.34581151604652405, -1.2076531648635864, 0.13749630749225616, -0.44156789779663086, 1.0876474380493164, 0.4285399913787842, 1.0058739185333252, -1.7119542360305786, -0.02024657279253006, -0.2667766511440277, 0.2199711948633194, -1.2193071842193604, -1.5961761474609375, 0.6284483671188354, 0.5396755933761597, 0.525274932384491, -0.1628008335828781, 1.1209796667099, -1.128803014755249, 0.8071145415306091, -1.070693850517273, -1.688642144203186, -1.4215937852859497, -2.2521371841430664, -2.191432476043701, 0.654498815536499, -0.5312331318855286, -0.5206457376480103, 2.0725271701812744, -0.981368362903595, -1.6730248928070068, 1.139477252960205, 0.24169321358203888, -0.0005769440904259682, 2.348796844482422, 0.20958605408668518, -0.671931803226471, 0.4880581200122833, -0.8086337447166443, 0.7906571626663208, -0.3038729429244995, 1.3495352268218994, 0.4183017611503601, -1.0876206159591675, 1.5978964567184448, -0.37174084782600403, 0.5705781579017639, -0.553147554397583, -0.5441300272941589, -0.7247528433799744, 0.23205667734146118, 1.881868839263916, -0.2922987639904022, 1.4447945356369019, -0.3401529788970947, -1.502456784248352, -1.6106919050216675, 0.9807024598121643, 0.4544409215450287, -0.8311120867729187, 0.18271294236183167, -0.5307923555374146, 0.16542144119739532, -0.05783570185303688, 1.2451820373535156, 1.3419694900512695, 0.7997744083404541, -0.3967094421386719, -0.7611581683158875, 0.13777358829975128, -0.07958602160215378, -0.7141509652137756, -1.7604843378067017, -0.38904649019241333, 0.11336493492126465, 0.6691190004348755, -1.103524088859558, 1.837209701538086, 0.9380624294281006, 1.8849183320999146, 1.0147721767425537, -0.37624239921569824, 1.4652131795883179, 0.08214523643255234, 1.8020519018173218, -0.5186798572540283, 0.6336647272109985, -0.4189484715461731, -1.1765495538711548, 0.8918150663375854, -0.3119543194770813, -2.069382905960083, -0.7765493988990784, -0.7259145379066467, -0.1854252964258194, -0.8750786781311035, 0.930161714553833, -0.293204128742218, -1.4624985456466675, 0.20235463976860046, -0.7065148949623108, 0.14351630210876465, -1.1823662519454956, 0.3289157748222351, 0.6754565238952637, -0.650816023349762, 0.10384839028120041, -0.231216698884964, -1.2386047840118408, -0.516243577003479, 0.26797279715538025, 1.8828272819519043, -0.6313206553459167, 0.9253871440887451, 1.0674333572387695, -0.6744243502616882, -0.0685236006975174, 0.2832387685775757, -0.3361179530620575, 0.8468278646469116, -1.0320188999176025, -0.537996768951416, 1.2224764823913574, -0.19796226918697357, -0.5550762414932251, 1.4795533418655396, 0.6074240207672119, -1.0154998302459717, -0.2785501778125763, -0.1537284553050995, -0.8851861357688904, 0.09792763739824295, -1.5087882280349731, -0.14053253829479218, 0.5158325433731079, -1.5553847551345825, -0.4324536621570587, -0.16466334462165833, 1.3224083185195923, -0.19398628175258636, 1.489725947380066, -0.37042659521102905, -0.16392745077610016, -0.2994914650917053, -0.3450047969818115, 0.15702687203884125, -0.09183439612388611, -0.6712797284126282, 0.12571211159229279, -0.8052224516868591, 0.38129231333732605, 1.4665462970733643, 0.2486332207918167, 0.02911742776632309, 0.45866236090660095, 1.100577473640442, 0.3628608286380768, -0.08157375454902649, -0.9239226579666138, -1.5509613752365112, 1.9792550802230835, -1.4797959327697754, 2.00675892829895, 0.7830439805984497, -0.08020652085542679, -1.8123866319656372, -1.7918002605438232, 1.3311359882354736, 1.1580243110656738, 2.3174266815185547, 0.5244920253753662, 0.4165392220020294, -0.7668754458427429, -0.6583884954452515, 0.30397865176200867, -1.0827196836471558, -0.6753581166267395, 0.23990613222122192, 2.4044692516326904, 1.781298279762268, -0.4425797164440155, -0.19101209938526154, -0.9829928278923035, 1.3376902341842651, -0.28112199902534485, 0.21211613714694977, 1.9484807252883911, -0.2299797385931015, -1.0529167652130127, 1.3466925621032715, -2.3654701709747314, 0.22468525171279907, 2.0508697032928467, 0.3507494032382965, 0.12460658699274063, -1.3239268064498901, -0.5475836396217346, -0.28874456882476807, -0.46919599175453186, -1.2885594367980957, 0.4973348081111908, -0.18551316857337952, -0.7874863147735596, -1.348490595817566, 0.19899608194828033, -1.122996211051941, -1.695956826210022, 0.23043550550937653, 1.9107682704925537, 2.1109068393707275, -0.7488948106765747, 1.5649986267089844, -0.42424625158309937, 0.16996417939662933, 1.2032641172409058, 1.312498688697815, 3.071192741394043, 1.8642898797988892, -1.3581467866897583, 0.6676552295684814, -0.2173980325460434, -0.559167206287384, 1.1652779579162598, -1.2637075185775757, 1.264624834060669, -0.11867415904998779, -1.2049411535263062, -1.2521247863769531, 1.0117484331130981, 0.4367265999317169, 0.05127795785665512, -0.4933066666126251, 1.1553038358688354, 0.15893927216529846, 1.3814609050750732, 0.5917761325836182, -0.3316621482372284, 0.6258667707443237, -0.4016607999801636, -0.4500105082988739, 1.5580692291259766, 0.18183785676956177, -1.4025628566741943, -2.283634901046753, -0.14928534626960754, -0.8979191780090332, 0.14238892495632172, -0.6187760233879089, -0.9766247868537903, 1.6309442520141602, 0.3100856840610504, -1.230992078781128, -0.2641846537590027, -0.36611834168434143, -0.5520333051681519, 2.7195887565612793, -1.2184863090515137, -0.2524767220020294, -0.9723224639892578, -0.7886156439781189, 1.59701669216156, -1.2435729503631592, -0.2156052440404892, -0.9555762410163879, -0.5506362915039062, -1.2841285467147827, -0.5390051603317261, 0.04608776420354843, -0.965511679649353, 0.7735902070999146, 0.18929684162139893, -1.2301790714263916, -0.42056599259376526, -0.7898242473602295, 0.9418392777442932, -0.24473094940185547, 0.15271149575710297, 1.8207292556762695, 0.2454354614019394, -0.35870057344436646, 0.8547343015670776, 1.1780147552490234, 0.609052300453186, -0.5519440174102783, 0.1613217294216156, -0.6711052656173706, 0.3499176800251007, -1.2448660135269165, 0.3145863711833954, -2.8695645332336426, 0.671040952205658, -0.021004751324653625, -0.09424528479576111, -0.08122210949659348, -1.4300894737243652, 1.0155657529830933, 2.6010677814483643, -1.1604251861572266, 0.5007954239845276, 0.32741987705230713, 1.1422251462936401, -1.591278314590454, 0.21408309042453766, -0.49440354108810425, 2.0756351947784424, 0.28954532742500305, 1.2567297220230103, -0.45648178458213806, -2.3433303833007812, 0.6205129623413086, -1.3557045459747314, -1.15959632396698, 0.7685874104499817, -0.8521873354911804, 0.1507054567337036, -1.339126706123352, -0.27235254645347595, -0.8838710188865662, -1.1251634359359741, 0.637652575969696, 0.14716266095638275, 0.4194837212562561, -0.6093424558639526, 0.30907759070396423, -2.2107105255126953, -1.3018547296524048, -0.14408697187900543, -0.977510392665863, 0.5190096497535706, -0.48462551832199097, 0.7006571888923645, -0.11337742954492569, -0.013470589183270931, 0.4146192669868469, 1.5095349550247192, 3.386756658554077, 0.2199634462594986, 0.2824596166610718, -0.2776835262775421, -0.9641700387001038, 1.5215599536895752, 0.8457326889038086, -0.17773663997650146, -0.5651062726974487, -1.0686368942260742, 1.256855845451355, 1.8958994150161743, 0.8588723540306091, 0.02651117742061615, -0.8922290802001953, -0.7044177055358887, -0.052574142813682556, 0.11829269677400589, 0.4314849078655243, 0.9280596375465393, 0.13030695915222168, 0.04300333186984062, 1.4032280445098877, 1.1352241039276123, -0.4024324119091034, 0.3544304072856903, -0.8399837017059326, -0.3837916851043701, 0.5275399684906006, 0.27099207043647766, -0.038755375891923904, 0.3699900507926941, -0.920984148979187, -0.2893209457397461, -0.3933523893356323, -0.8521087765693665, -0.7494899034500122, -0.4101017713546753, -0.37057560682296753, 1.6459875106811523, 0.13157469034194946, -0.4926767945289612, -0.02535157836973667, -0.7864295244216919, -0.1456502079963684, -1.1047048568725586, 0.20037318766117096, -0.06104257330298424, -0.14033475518226624, -0.15852662920951843, 1.7353472709655762, -0.8827623128890991, -2.0497517585754395, 0.1912117898464203, 0.20480452477931976, -0.22941423952579498, 0.2140512466430664, 1.6909289360046387, 0.4844909906387329, 1.4448579549789429, 1.2889355421066284, 0.9701460599899292, -0.6217978000640869, -1.2950255870819092, 0.7722205519676208, 0.9390353560447693, -1.3919720649719238, 0.8187793493270874, -0.07688263058662415, -0.4715798795223236, 0.6058039665222168, 1.1926673650741577, 0.5125511884689331, -1.9851857423782349, 0.8043025135993958, -1.0349947214126587, 0.8150075078010559, 0.7428379654884338, 0.6157976388931274, 0.2448112517595291, 0.8692721724510193, -1.2233421802520752, -1.1115431785583496, -0.6526858806610107, -0.7141526937484741, 2.0142617225646973, -0.35835039615631104, 0.6308340430259705, -0.2381220906972885, -1.3672821521759033, -0.08315305411815643, 0.7389456629753113, 0.3749692142009735, -0.506883978843689, 0.7433762550354004, -0.7123759388923645, -1.0244725942611694, -1.3419419527053833, -0.4537983536720276, -1.1077501773834229, -1.023657202720642, 1.0641082525253296, 0.6988312005996704, 0.3103312849998474, 1.9031773805618286, 0.6459838151931763, 0.2619236707687378, -2.537459135055542, 0.861052930355072, 0.2601129412651062, -0.09079334139823914, 0.8776627779006958, 0.46942517161369324, 1.0049712657928467, 0.015680667012929916, 0.6060882806777954, -2.4960954189300537, 2.356536865234375, -0.12105764448642731, 0.7078245878219604, 0.07416543364524841, -0.24286387860774994, 1.173863172531128, 0.5792101621627808, 0.47801917791366577, -1.0627354383468628, 0.6155811548233032, -0.5743517875671387, 1.2609212398529053, 0.8360148072242737, -0.8362006545066833, -0.002662207931280136, 1.3921946287155151, 0.46437886357307434, -0.5007355809211731, -0.9238314032554626, -0.956911027431488, 0.9564623236656189, 1.6793441772460938, -0.05409897863864899, -0.02257390320301056, 0.7253323197364807, 0.7134193181991577, -1.258240818977356, 0.0881405770778656, -0.6925987005233765, -0.7618107795715332, 1.6358152627944946, 2.0891144275665283, -0.21775691211223602, -0.17107610404491425, -0.6862389445304871, -1.3521744012832642, 0.8534873127937317, -0.09288079291582108, 0.10966837406158447, 0.6103137731552124, -0.5857788324356079, 0.969518780708313, 0.8980392813682556, 0.930030107498169, 0.2913565933704376, 0.29146233201026917, 0.394858181476593, -0.3791663348674774, -1.116383671760559, -0.22212131321430206, -1.093349814414978, -2.678900718688965, 0.4207954406738281, -0.2652113139629364, -1.3707736730575562, 0.03746476396918297, -0.9597068428993225, 0.8683139085769653, -0.6084392070770264, -1.1210410594940186, -1.4711421728134155, 0.24895964562892914, 0.006735139526426792, 0.9902312159538269, -1.604506492614746, -0.17397285997867584, 1.1914445161819458, 0.8709969520568848, -0.7049355506896973, 0.9642133116722107, 0.2078114151954651, 1.0250040292739868, 0.8568227887153625, -0.4181331396102905, 0.6182434558868408, 0.03507668152451515, -1.3783280849456787, 0.4445445239543915, 1.2207696437835693, 0.23791398108005524, 1.5120775699615479, -0.38951700925827026, 0.018091395497322083, 0.42769789695739746, -0.6623564958572388, -0.5585848689079285, -0.41871777176856995, 0.5870958566665649, 0.028583165258169174, -0.9827859401702881, -0.09199051558971405, -0.03534920886158943, -0.31863588094711304, 0.1888469159603119, -1.4407734870910645, -0.1417376548051834, -0.4051297903060913, -0.600477397441864, -1.2937644720077515, -0.12243188917636871, 1.4057859182357788, -0.7638819813728333, -0.16007228195667267, 0.40202417969703674, 0.3811003863811493, 0.51077800989151, 0.6530059576034546, -0.8079514503479004, -0.3516363501548767, -0.2352105975151062, -0.3383120000362396, 0.4119672179222107, 1.3774250745773315, -0.08127759397029877, -0.9346227049827576, 0.6019138693809509, -0.3113865852355957, 0.09594712406396866, 1.8889340162277222, 0.064056895673275, -0.7672309279441833, 0.29870420694351196, -0.7527433037757874, 1.8976861238479614, 1.7361884117126465, 1.2734543085098267, -0.1465306133031845, -0.84157395362854, 0.6844934225082397, -0.4384704530239105, -0.3459400534629822, 0.868216872215271, 0.3207721412181854, -0.2318442314863205, -1.5236824750900269, 0.7911661267280579, 1.3275882005691528, -0.7890422344207764, -0.8569883108139038, 0.15691283345222473, -0.7737320065498352, 1.194298505783081, 0.5839184522628784, 0.32634270191192627, 0.2878434956073761, 1.6030879020690918, 0.8075254559516907, -0.40163421630859375, 0.5591980218887329, 0.5148944854736328, -0.1539243757724762, -2.205169200897217, -1.2601948976516724, 0.3416507840156555, -0.5841649770736694, -1.5605953931808472, 1.4439810514450073, -1.0924017429351807, -1.112066626548767, 0.5980516672134399, 0.08635575324296951, 1.3276584148406982, 0.3924199938774109, 1.5543813705444336, 2.0440750122070312, 0.7962685823440552, 0.43006181716918945, 1.22671639919281, -0.1449178159236908, -0.48397305607795715, 1.7556226253509521, -0.41754817962646484, 0.49532386660575867, 1.1325857639312744, -0.27241015434265137, -1.1654233932495117, -0.8186470866203308, -1.2690367698669434, -0.798886775970459, 1.1543046236038208, 0.08968789130449295, -1.0725897550582886, 0.26485493779182434, 1.6204137802124023, 0.1732502430677414, -0.253827840089798, 0.6367133855819702, 0.4354454278945923, -0.7482894062995911, -0.011351436376571655, -0.8824612498283386, 0.5348762273788452, -0.2903853952884674, -0.37671464681625366, 0.32501861453056335, 0.48895135521888733, 1.3226211071014404, -0.05089137703180313, 0.05348017439246178, 1.0252052545547485, -1.467864990234375, 1.4771651029586792, -0.658483624458313, 0.3264654874801636, -2.357149600982666, 1.3275173902511597, -0.7595835328102112, 2.001539707183838, -2.663938283920288, 0.47669604420661926, -0.549942135810852, -0.49217116832733154, 0.28631314635276794, -0.31725940108299255, 0.09084171056747437, -0.131460040807724, -1.101257562637329, -0.0536457821726799, -0.6570311784744263, 0.6248765587806702, 1.1304302215576172, 1.3858965635299683, -1.1660349369049072, -0.23406395316123962, -1.6564133167266846, -0.034714408218860626, -0.743509829044342, 0.17763105034828186, -1.956472635269165, -0.21818798780441284, -1.9411677122116089, -2.355215311050415, -1.2008016109466553, -0.7569925785064697, 1.1258121728897095, 0.13358688354492188, -0.8405548930168152, 1.3179728984832764, -0.398405522108078, -1.8127456903457642, 1.0479952096939087, -2.151811361312866 ]
https://github.com/huggingface/datasets/issues/5179
`map()` fails midway due to format incompatibility
tbh I though your first implementation was fine ```python def tokenize(batch): return tokenizer(batch["text"], padding=True, truncation=True) ``` Maybe you can try to see what the erroring data looks like by adding a try/except in `get_test_accuracy` ?
### Describe the bug I am using the `emotion` dataset from Hub for sequence classification. After training the model, I am using it to generate predictions for all the entries present in the `validation` split of the dataset. ```py def get_test_accuracy(model): def fn(batch): inputs = {k:v.to(device) for k,v in batch.items() if k in tokenizer.model_input_names} with torch.no_grad(): output = model(**inputs) pred_label = torch.argmax(output.logits, axis=-1) return {"predicted_label": pred_label.cpu().numpy()} return fn ``` This is how the `get_test_accuracy()` is being used: ```py emotions = load_dataset("emotion") def tokenize(batch): return tokenizer(batch["text"], padding=True, truncation=True) emotions_encoded = emotions.map(tokenize, batched=True) emotions_encoded.set_format("torch", columns=["input_ids", "attention_mask", "label"]) new_dataset = emotions_encoded["validation"].map( accuracy_fn, batched=True, batch_size=128 ) ``` Complete code is available in the Colab Notebook provided below. The `map()` process fails midway giving: ```shell AttributeError Traceback (most recent call last) <ipython-input-8-ad24ac288eb4> in <module> 2 3 new_dataset = emotions_encoded["validation"].map( ----> 4 accuracy_fn, batched=True, batch_size=128 5 ) 7 frames /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in map(self, function, with_indices, with_rank, input_columns, batched, batch_size, drop_last_batch, remove_columns, keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, features, disable_nullable, fn_kwargs, num_proc, suffix_template, new_fingerprint, desc) 2588 new_fingerprint=new_fingerprint, 2589 disable_tqdm=disable_tqdm, -> 2590 desc=desc, 2591 ) 2592 else: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in wrapper(*args, **kwargs) 582 self: "Dataset" = kwargs.pop("self") 583 # apply actual function --> 584 out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs) 585 datasets: List["Dataset"] = list(out.values()) if isinstance(out, dict) else [out] 586 for dataset in datasets: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in wrapper(*args, **kwargs) 549 } 550 # apply actual function --> 551 out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs) 552 datasets: List["Dataset"] = list(out.values()) if isinstance(out, dict) else [out] 553 # re-apply format to the output /usr/local/lib/python3.7/dist-packages/datasets/fingerprint.py in wrapper(*args, **kwargs) 478 # Call actual function 479 --> 480 out = func(self, *args, **kwargs) 481 482 # Update fingerprint of in-place transforms + update in-place history of transforms /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in _map_single(self, function, with_indices, with_rank, input_columns, batched, batch_size, drop_last_batch, remove_columns, keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, features, disable_nullable, fn_kwargs, new_fingerprint, rank, offset, disable_tqdm, desc, cache_only) 2970 indices, 2971 check_same_num_examples=len(input_dataset.list_indexes()) > 0, -> 2972 offset=offset, 2973 ) 2974 except NumExamplesMismatchError: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in apply_function_on_filtered_inputs(inputs, indices, check_same_num_examples, offset) 2850 if with_rank: 2851 additional_args += (rank,) -> 2852 processed_inputs = function(*fn_args, *additional_args, **fn_kwargs) 2853 if update_data is None: 2854 # Check if the function returns updated examples <ipython-input-6-4e0d280426f6> in fn(batch) 1 def get_test_accuracy(model): 2 def fn(batch): ----> 3 inputs = {k:v.to(device) for k,v in batch.items() 4 if k in tokenizer.model_input_names} 5 with torch.no_grad(): <ipython-input-6-4e0d280426f6> in <dictcomp>(.0) 2 def fn(batch): 3 inputs = {k:v.to(device) for k,v in batch.items() ----> 4 if k in tokenizer.model_input_names} 5 with torch.no_grad(): 6 output = model(**inputs) AttributeError: 'list' object has no attribute 'to' ``` As you'd notice in the notebook, the process fails _midway_ and not at the beginning. Is this expected? ### Steps to reproduce the bug Colab Notebook: https://colab.research.google.com/gist/sayakpaul/d1570d537faf39040d02d77b1ed7de07/scratchpad.ipynb ### Expected behavior The mapping process should complete as is. If you switch the `split` to `test` it works as expected. ### Environment info Colab
450
35
`map()` fails midway due to format incompatibility ### Describe the bug I am using the `emotion` dataset from Hub for sequence classification. After training the model, I am using it to generate predictions for all the entries present in the `validation` split of the dataset. ```py def get_test_accuracy(model): def fn(batch): inputs = {k:v.to(device) for k,v in batch.items() if k in tokenizer.model_input_names} with torch.no_grad(): output = model(**inputs) pred_label = torch.argmax(output.logits, axis=-1) return {"predicted_label": pred_label.cpu().numpy()} return fn ``` This is how the `get_test_accuracy()` is being used: ```py emotions = load_dataset("emotion") def tokenize(batch): return tokenizer(batch["text"], padding=True, truncation=True) emotions_encoded = emotions.map(tokenize, batched=True) emotions_encoded.set_format("torch", columns=["input_ids", "attention_mask", "label"]) new_dataset = emotions_encoded["validation"].map( accuracy_fn, batched=True, batch_size=128 ) ``` Complete code is available in the Colab Notebook provided below. The `map()` process fails midway giving: ```shell AttributeError Traceback (most recent call last) <ipython-input-8-ad24ac288eb4> in <module> 2 3 new_dataset = emotions_encoded["validation"].map( ----> 4 accuracy_fn, batched=True, batch_size=128 5 ) 7 frames /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in map(self, function, with_indices, with_rank, input_columns, batched, batch_size, drop_last_batch, remove_columns, keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, features, disable_nullable, fn_kwargs, num_proc, suffix_template, new_fingerprint, desc) 2588 new_fingerprint=new_fingerprint, 2589 disable_tqdm=disable_tqdm, -> 2590 desc=desc, 2591 ) 2592 else: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in wrapper(*args, **kwargs) 582 self: "Dataset" = kwargs.pop("self") 583 # apply actual function --> 584 out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs) 585 datasets: List["Dataset"] = list(out.values()) if isinstance(out, dict) else [out] 586 for dataset in datasets: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in wrapper(*args, **kwargs) 549 } 550 # apply actual function --> 551 out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs) 552 datasets: List["Dataset"] = list(out.values()) if isinstance(out, dict) else [out] 553 # re-apply format to the output /usr/local/lib/python3.7/dist-packages/datasets/fingerprint.py in wrapper(*args, **kwargs) 478 # Call actual function 479 --> 480 out = func(self, *args, **kwargs) 481 482 # Update fingerprint of in-place transforms + update in-place history of transforms /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in _map_single(self, function, with_indices, with_rank, input_columns, batched, batch_size, drop_last_batch, remove_columns, keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, features, disable_nullable, fn_kwargs, new_fingerprint, rank, offset, disable_tqdm, desc, cache_only) 2970 indices, 2971 check_same_num_examples=len(input_dataset.list_indexes()) > 0, -> 2972 offset=offset, 2973 ) 2974 except NumExamplesMismatchError: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in apply_function_on_filtered_inputs(inputs, indices, check_same_num_examples, offset) 2850 if with_rank: 2851 additional_args += (rank,) -> 2852 processed_inputs = function(*fn_args, *additional_args, **fn_kwargs) 2853 if update_data is None: 2854 # Check if the function returns updated examples <ipython-input-6-4e0d280426f6> in fn(batch) 1 def get_test_accuracy(model): 2 def fn(batch): ----> 3 inputs = {k:v.to(device) for k,v in batch.items() 4 if k in tokenizer.model_input_names} 5 with torch.no_grad(): <ipython-input-6-4e0d280426f6> in <dictcomp>(.0) 2 def fn(batch): 3 inputs = {k:v.to(device) for k,v in batch.items() ----> 4 if k in tokenizer.model_input_names} 5 with torch.no_grad(): 6 output = model(**inputs) AttributeError: 'list' object has no attribute 'to' ``` As you'd notice in the notebook, the process fails _midway_ and not at the beginning. Is this expected? ### Steps to reproduce the bug Colab Notebook: https://colab.research.google.com/gist/sayakpaul/d1570d537faf39040d02d77b1ed7de07/scratchpad.ipynb ### Expected behavior The mapping process should complete as is. If you switch the `split` to `test` it works as expected. ### Environment info Colab tbh I though your first implementation was fine ```python def tokenize(batch): return tokenizer(batch["text"], padding=True, truncation=True) ``` Maybe you can try to see what the erroring data looks like by adding a try/except in `get_test_accuracy` ?
[ -1.2564349174499512, -0.8618111610412598, -0.6586883068084717, 1.5509893894195557, -0.11722970008850098, -1.2016878128051758, 0.3056619465351105, -1.071123480796814, 1.6652281284332275, -0.8826600909233093, 0.3184569478034973, -1.5744513273239136, 0.06408709287643433, -0.6032147407531738, -0.7170072793960571, -0.827620267868042, -0.391541451215744, -0.7243706583976746, 1.102968454360962, 2.441807985305786, 1.345527172088623, -1.3015437126159668, 2.7619075775146484, 0.7074694037437439, -0.23903891444206238, -1.027679204940796, 0.5006363391876221, -0.04980858787894249, -1.2392507791519165, -0.48583224415779114, -0.9670151472091675, -0.09760599583387375, -0.6154596209526062, -0.4936542510986328, -0.030476875603199005, 0.4526210129261017, -0.34846463799476624, -0.4001949429512024, -0.5780141949653625, -0.8301367163658142, 0.5327627062797546, -0.32234451174736023, 0.9258394241333008, -0.2610061764717102, 1.7740511894226074, -0.6517888307571411, 0.5122497081756592, 0.7529274821281433, 1.3074336051940918, 0.17150403559207916, -0.0720311775803566, 0.36685800552368164, 0.35100361704826355, 0.02520972117781639, 0.5899772047996521, 1.2242026329040527, 0.6695250868797302, 0.5533755421638489, 0.67540043592453, -2.2437541484832764, 1.3265388011932373, -1.0817766189575195, 0.3195015788078308, 1.289945125579834, -0.9156166911125183, 0.28408458828926086, -1.7497355937957764, -0.0831250324845314, 0.5423450469970703, -2.2372968196868896, 0.3418833613395691, -1.3627794981002808, -0.5304228663444519, 0.9875593185424805, 0.34581151604652405, -1.2076531648635864, 0.13749630749225616, -0.44156789779663086, 1.0876474380493164, 0.4285399913787842, 1.0058739185333252, -1.7119542360305786, -0.02024657279253006, -0.2667766511440277, 0.2199711948633194, -1.2193071842193604, -1.5961761474609375, 0.6284483671188354, 0.5396755933761597, 0.525274932384491, -0.1628008335828781, 1.1209796667099, -1.128803014755249, 0.8071145415306091, -1.070693850517273, -1.688642144203186, -1.4215937852859497, -2.2521371841430664, -2.191432476043701, 0.654498815536499, -0.5312331318855286, -0.5206457376480103, 2.0725271701812744, -0.981368362903595, -1.6730248928070068, 1.139477252960205, 0.24169321358203888, -0.0005769440904259682, 2.348796844482422, 0.20958605408668518, -0.671931803226471, 0.4880581200122833, -0.8086337447166443, 0.7906571626663208, -0.3038729429244995, 1.3495352268218994, 0.4183017611503601, -1.0876206159591675, 1.5978964567184448, -0.37174084782600403, 0.5705781579017639, -0.553147554397583, -0.5441300272941589, -0.7247528433799744, 0.23205667734146118, 1.881868839263916, -0.2922987639904022, 1.4447945356369019, -0.3401529788970947, -1.502456784248352, -1.6106919050216675, 0.9807024598121643, 0.4544409215450287, -0.8311120867729187, 0.18271294236183167, -0.5307923555374146, 0.16542144119739532, -0.05783570185303688, 1.2451820373535156, 1.3419694900512695, 0.7997744083404541, -0.3967094421386719, -0.7611581683158875, 0.13777358829975128, -0.07958602160215378, -0.7141509652137756, -1.7604843378067017, -0.38904649019241333, 0.11336493492126465, 0.6691190004348755, -1.103524088859558, 1.837209701538086, 0.9380624294281006, 1.8849183320999146, 1.0147721767425537, -0.37624239921569824, 1.4652131795883179, 0.08214523643255234, 1.8020519018173218, -0.5186798572540283, 0.6336647272109985, -0.4189484715461731, -1.1765495538711548, 0.8918150663375854, -0.3119543194770813, -2.069382905960083, -0.7765493988990784, -0.7259145379066467, -0.1854252964258194, -0.8750786781311035, 0.930161714553833, -0.293204128742218, -1.4624985456466675, 0.20235463976860046, -0.7065148949623108, 0.14351630210876465, -1.1823662519454956, 0.3289157748222351, 0.6754565238952637, -0.650816023349762, 0.10384839028120041, -0.231216698884964, -1.2386047840118408, -0.516243577003479, 0.26797279715538025, 1.8828272819519043, -0.6313206553459167, 0.9253871440887451, 1.0674333572387695, -0.6744243502616882, -0.0685236006975174, 0.2832387685775757, -0.3361179530620575, 0.8468278646469116, -1.0320188999176025, -0.537996768951416, 1.2224764823913574, -0.19796226918697357, -0.5550762414932251, 1.4795533418655396, 0.6074240207672119, -1.0154998302459717, -0.2785501778125763, -0.1537284553050995, -0.8851861357688904, 0.09792763739824295, -1.5087882280349731, -0.14053253829479218, 0.5158325433731079, -1.5553847551345825, -0.4324536621570587, -0.16466334462165833, 1.3224083185195923, -0.19398628175258636, 1.489725947380066, -0.37042659521102905, -0.16392745077610016, -0.2994914650917053, -0.3450047969818115, 0.15702687203884125, -0.09183439612388611, -0.6712797284126282, 0.12571211159229279, -0.8052224516868591, 0.38129231333732605, 1.4665462970733643, 0.2486332207918167, 0.02911742776632309, 0.45866236090660095, 1.100577473640442, 0.3628608286380768, -0.08157375454902649, -0.9239226579666138, -1.5509613752365112, 1.9792550802230835, -1.4797959327697754, 2.00675892829895, 0.7830439805984497, -0.08020652085542679, -1.8123866319656372, -1.7918002605438232, 1.3311359882354736, 1.1580243110656738, 2.3174266815185547, 0.5244920253753662, 0.4165392220020294, -0.7668754458427429, -0.6583884954452515, 0.30397865176200867, -1.0827196836471558, -0.6753581166267395, 0.23990613222122192, 2.4044692516326904, 1.781298279762268, -0.4425797164440155, -0.19101209938526154, -0.9829928278923035, 1.3376902341842651, -0.28112199902534485, 0.21211613714694977, 1.9484807252883911, -0.2299797385931015, -1.0529167652130127, 1.3466925621032715, -2.3654701709747314, 0.22468525171279907, 2.0508697032928467, 0.3507494032382965, 0.12460658699274063, -1.3239268064498901, -0.5475836396217346, -0.28874456882476807, -0.46919599175453186, -1.2885594367980957, 0.4973348081111908, -0.18551316857337952, -0.7874863147735596, -1.348490595817566, 0.19899608194828033, -1.122996211051941, -1.695956826210022, 0.23043550550937653, 1.9107682704925537, 2.1109068393707275, -0.7488948106765747, 1.5649986267089844, -0.42424625158309937, 0.16996417939662933, 1.2032641172409058, 1.312498688697815, 3.071192741394043, 1.8642898797988892, -1.3581467866897583, 0.6676552295684814, -0.2173980325460434, -0.559167206287384, 1.1652779579162598, -1.2637075185775757, 1.264624834060669, -0.11867415904998779, -1.2049411535263062, -1.2521247863769531, 1.0117484331130981, 0.4367265999317169, 0.05127795785665512, -0.4933066666126251, 1.1553038358688354, 0.15893927216529846, 1.3814609050750732, 0.5917761325836182, -0.3316621482372284, 0.6258667707443237, -0.4016607999801636, -0.4500105082988739, 1.5580692291259766, 0.18183785676956177, -1.4025628566741943, -2.283634901046753, -0.14928534626960754, -0.8979191780090332, 0.14238892495632172, -0.6187760233879089, -0.9766247868537903, 1.6309442520141602, 0.3100856840610504, -1.230992078781128, -0.2641846537590027, -0.36611834168434143, -0.5520333051681519, 2.7195887565612793, -1.2184863090515137, -0.2524767220020294, -0.9723224639892578, -0.7886156439781189, 1.59701669216156, -1.2435729503631592, -0.2156052440404892, -0.9555762410163879, -0.5506362915039062, -1.2841285467147827, -0.5390051603317261, 0.04608776420354843, -0.965511679649353, 0.7735902070999146, 0.18929684162139893, -1.2301790714263916, -0.42056599259376526, -0.7898242473602295, 0.9418392777442932, -0.24473094940185547, 0.15271149575710297, 1.8207292556762695, 0.2454354614019394, -0.35870057344436646, 0.8547343015670776, 1.1780147552490234, 0.609052300453186, -0.5519440174102783, 0.1613217294216156, -0.6711052656173706, 0.3499176800251007, -1.2448660135269165, 0.3145863711833954, -2.8695645332336426, 0.671040952205658, -0.021004751324653625, -0.09424528479576111, -0.08122210949659348, -1.4300894737243652, 1.0155657529830933, 2.6010677814483643, -1.1604251861572266, 0.5007954239845276, 0.32741987705230713, 1.1422251462936401, -1.591278314590454, 0.21408309042453766, -0.49440354108810425, 2.0756351947784424, 0.28954532742500305, 1.2567297220230103, -0.45648178458213806, -2.3433303833007812, 0.6205129623413086, -1.3557045459747314, -1.15959632396698, 0.7685874104499817, -0.8521873354911804, 0.1507054567337036, -1.339126706123352, -0.27235254645347595, -0.8838710188865662, -1.1251634359359741, 0.637652575969696, 0.14716266095638275, 0.4194837212562561, -0.6093424558639526, 0.30907759070396423, -2.2107105255126953, -1.3018547296524048, -0.14408697187900543, -0.977510392665863, 0.5190096497535706, -0.48462551832199097, 0.7006571888923645, -0.11337742954492569, -0.013470589183270931, 0.4146192669868469, 1.5095349550247192, 3.386756658554077, 0.2199634462594986, 0.2824596166610718, -0.2776835262775421, -0.9641700387001038, 1.5215599536895752, 0.8457326889038086, -0.17773663997650146, -0.5651062726974487, -1.0686368942260742, 1.256855845451355, 1.8958994150161743, 0.8588723540306091, 0.02651117742061615, -0.8922290802001953, -0.7044177055358887, -0.052574142813682556, 0.11829269677400589, 0.4314849078655243, 0.9280596375465393, 0.13030695915222168, 0.04300333186984062, 1.4032280445098877, 1.1352241039276123, -0.4024324119091034, 0.3544304072856903, -0.8399837017059326, -0.3837916851043701, 0.5275399684906006, 0.27099207043647766, -0.038755375891923904, 0.3699900507926941, -0.920984148979187, -0.2893209457397461, -0.3933523893356323, -0.8521087765693665, -0.7494899034500122, -0.4101017713546753, -0.37057560682296753, 1.6459875106811523, 0.13157469034194946, -0.4926767945289612, -0.02535157836973667, -0.7864295244216919, -0.1456502079963684, -1.1047048568725586, 0.20037318766117096, -0.06104257330298424, -0.14033475518226624, -0.15852662920951843, 1.7353472709655762, -0.8827623128890991, -2.0497517585754395, 0.1912117898464203, 0.20480452477931976, -0.22941423952579498, 0.2140512466430664, 1.6909289360046387, 0.4844909906387329, 1.4448579549789429, 1.2889355421066284, 0.9701460599899292, -0.6217978000640869, -1.2950255870819092, 0.7722205519676208, 0.9390353560447693, -1.3919720649719238, 0.8187793493270874, -0.07688263058662415, -0.4715798795223236, 0.6058039665222168, 1.1926673650741577, 0.5125511884689331, -1.9851857423782349, 0.8043025135993958, -1.0349947214126587, 0.8150075078010559, 0.7428379654884338, 0.6157976388931274, 0.2448112517595291, 0.8692721724510193, -1.2233421802520752, -1.1115431785583496, -0.6526858806610107, -0.7141526937484741, 2.0142617225646973, -0.35835039615631104, 0.6308340430259705, -0.2381220906972885, -1.3672821521759033, -0.08315305411815643, 0.7389456629753113, 0.3749692142009735, -0.506883978843689, 0.7433762550354004, -0.7123759388923645, -1.0244725942611694, -1.3419419527053833, -0.4537983536720276, -1.1077501773834229, -1.023657202720642, 1.0641082525253296, 0.6988312005996704, 0.3103312849998474, 1.9031773805618286, 0.6459838151931763, 0.2619236707687378, -2.537459135055542, 0.861052930355072, 0.2601129412651062, -0.09079334139823914, 0.8776627779006958, 0.46942517161369324, 1.0049712657928467, 0.015680667012929916, 0.6060882806777954, -2.4960954189300537, 2.356536865234375, -0.12105764448642731, 0.7078245878219604, 0.07416543364524841, -0.24286387860774994, 1.173863172531128, 0.5792101621627808, 0.47801917791366577, -1.0627354383468628, 0.6155811548233032, -0.5743517875671387, 1.2609212398529053, 0.8360148072242737, -0.8362006545066833, -0.002662207931280136, 1.3921946287155151, 0.46437886357307434, -0.5007355809211731, -0.9238314032554626, -0.956911027431488, 0.9564623236656189, 1.6793441772460938, -0.05409897863864899, -0.02257390320301056, 0.7253323197364807, 0.7134193181991577, -1.258240818977356, 0.0881405770778656, -0.6925987005233765, -0.7618107795715332, 1.6358152627944946, 2.0891144275665283, -0.21775691211223602, -0.17107610404491425, -0.6862389445304871, -1.3521744012832642, 0.8534873127937317, -0.09288079291582108, 0.10966837406158447, 0.6103137731552124, -0.5857788324356079, 0.969518780708313, 0.8980392813682556, 0.930030107498169, 0.2913565933704376, 0.29146233201026917, 0.394858181476593, -0.3791663348674774, -1.116383671760559, -0.22212131321430206, -1.093349814414978, -2.678900718688965, 0.4207954406738281, -0.2652113139629364, -1.3707736730575562, 0.03746476396918297, -0.9597068428993225, 0.8683139085769653, -0.6084392070770264, -1.1210410594940186, -1.4711421728134155, 0.24895964562892914, 0.006735139526426792, 0.9902312159538269, -1.604506492614746, -0.17397285997867584, 1.1914445161819458, 0.8709969520568848, -0.7049355506896973, 0.9642133116722107, 0.2078114151954651, 1.0250040292739868, 0.8568227887153625, -0.4181331396102905, 0.6182434558868408, 0.03507668152451515, -1.3783280849456787, 0.4445445239543915, 1.2207696437835693, 0.23791398108005524, 1.5120775699615479, -0.38951700925827026, 0.018091395497322083, 0.42769789695739746, -0.6623564958572388, -0.5585848689079285, -0.41871777176856995, 0.5870958566665649, 0.028583165258169174, -0.9827859401702881, -0.09199051558971405, -0.03534920886158943, -0.31863588094711304, 0.1888469159603119, -1.4407734870910645, -0.1417376548051834, -0.4051297903060913, -0.600477397441864, -1.2937644720077515, -0.12243188917636871, 1.4057859182357788, -0.7638819813728333, -0.16007228195667267, 0.40202417969703674, 0.3811003863811493, 0.51077800989151, 0.6530059576034546, -0.8079514503479004, -0.3516363501548767, -0.2352105975151062, -0.3383120000362396, 0.4119672179222107, 1.3774250745773315, -0.08127759397029877, -0.9346227049827576, 0.6019138693809509, -0.3113865852355957, 0.09594712406396866, 1.8889340162277222, 0.064056895673275, -0.7672309279441833, 0.29870420694351196, -0.7527433037757874, 1.8976861238479614, 1.7361884117126465, 1.2734543085098267, -0.1465306133031845, -0.84157395362854, 0.6844934225082397, -0.4384704530239105, -0.3459400534629822, 0.868216872215271, 0.3207721412181854, -0.2318442314863205, -1.5236824750900269, 0.7911661267280579, 1.3275882005691528, -0.7890422344207764, -0.8569883108139038, 0.15691283345222473, -0.7737320065498352, 1.194298505783081, 0.5839184522628784, 0.32634270191192627, 0.2878434956073761, 1.6030879020690918, 0.8075254559516907, -0.40163421630859375, 0.5591980218887329, 0.5148944854736328, -0.1539243757724762, -2.205169200897217, -1.2601948976516724, 0.3416507840156555, -0.5841649770736694, -1.5605953931808472, 1.4439810514450073, -1.0924017429351807, -1.112066626548767, 0.5980516672134399, 0.08635575324296951, 1.3276584148406982, 0.3924199938774109, 1.5543813705444336, 2.0440750122070312, 0.7962685823440552, 0.43006181716918945, 1.22671639919281, -0.1449178159236908, -0.48397305607795715, 1.7556226253509521, -0.41754817962646484, 0.49532386660575867, 1.1325857639312744, -0.27241015434265137, -1.1654233932495117, -0.8186470866203308, -1.2690367698669434, -0.798886775970459, 1.1543046236038208, 0.08968789130449295, -1.0725897550582886, 0.26485493779182434, 1.6204137802124023, 0.1732502430677414, -0.253827840089798, 0.6367133855819702, 0.4354454278945923, -0.7482894062995911, -0.011351436376571655, -0.8824612498283386, 0.5348762273788452, -0.2903853952884674, -0.37671464681625366, 0.32501861453056335, 0.48895135521888733, 1.3226211071014404, -0.05089137703180313, 0.05348017439246178, 1.0252052545547485, -1.467864990234375, 1.4771651029586792, -0.658483624458313, 0.3264654874801636, -2.357149600982666, 1.3275173902511597, -0.7595835328102112, 2.001539707183838, -2.663938283920288, 0.47669604420661926, -0.549942135810852, -0.49217116832733154, 0.28631314635276794, -0.31725940108299255, 0.09084171056747437, -0.131460040807724, -1.101257562637329, -0.0536457821726799, -0.6570311784744263, 0.6248765587806702, 1.1304302215576172, 1.3858965635299683, -1.1660349369049072, -0.23406395316123962, -1.6564133167266846, -0.034714408218860626, -0.743509829044342, 0.17763105034828186, -1.956472635269165, -0.21818798780441284, -1.9411677122116089, -2.355215311050415, -1.2008016109466553, -0.7569925785064697, 1.1258121728897095, 0.13358688354492188, -0.8405548930168152, 1.3179728984832764, -0.398405522108078, -1.8127456903457642, 1.0479952096939087, -2.151811361312866 ]
https://github.com/huggingface/datasets/issues/5179
`map()` fails midway due to format incompatibility
This is what I got. For the non-erroring data, it looks like (without the labels): ``` tensor([[ 101, 10047, 3110, ..., 0, 0, 0], [ 101, 1045, 2514, ..., 0, 0, 0], [ 101, 1045, 2514, ..., 0, 0, 0], ..., [ 101, 1045, 2005, ..., 0, 0, 0], [ 101, 1045, 2572, ..., 0, 0, 0], [ 101, 10047, 7481, ..., 0, 0, 0]]) 128 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]]) 128 ``` For the erroring part: ``` [tensor([ 101, 1045, 2064, 2102, 2393, 3110, 2066, 2242, 6355, 3047, 2004, 2574, 2004, 1996, 8629, 2357, 2125, 4299, 1045, 2071, 2424, 2009, 2006, 7858, 102, 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, 0, 0, 0, 0, 0]), tensor([ 101, 10047, 5458, 1997, 3110, 11654, 1998, 11055, 102, 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]), tensor([ 101, 1045, 2074, 2064, 2102, 6073, 1996, 3110, 2008, 2026, 14982, 2000, 5587, 2203, 16650, 29563, 2030, 2569, 4506, 2052, 2191, 1037, 2738, 11552, 2208, 17044, 14540, 2100, 3375, 102, 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]), ... [tensor([1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 0, 0, 0, 0, 0]), tensor([1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]), ... ``` I also tried investigating the shapes of the individual entries within a `batch` without the labels: ```py def get_test_accuracy(model): def fn(batch): try: inputs = {k:v.to(device) for k,v in batch.items() if k in tokenizer.model_input_names} with torch.no_grad(): output = model(**inputs) pred_label = torch.argmax(output.logits, axis=-1) return {"predicted_label": pred_label.cpu().numpy()} except: for k in batch: if k != "label": for i in range(len(batch[k])): print(batch[k][i].shape) return fn ``` They are: ``` ... torch.Size([66]) torch.Size([66]) torch.Size([66]) torch.Size([66]) torch.Size([66]) torch.Size([66]) torch.Size([66]) torch.Size([66]) torch.Size([66]) torch.Size([66]) torch.Size([66]) torch.Size([66]) torch.Size([66]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) ``` There are differing shapes. I understand if I set `batch_size=None` in `emotions_encoded = emotions.map(tokenize, batched=True)` the problem should be fixed as the whole dataset would be treated as a single batch. But is there a way to do that in batches?
### Describe the bug I am using the `emotion` dataset from Hub for sequence classification. After training the model, I am using it to generate predictions for all the entries present in the `validation` split of the dataset. ```py def get_test_accuracy(model): def fn(batch): inputs = {k:v.to(device) for k,v in batch.items() if k in tokenizer.model_input_names} with torch.no_grad(): output = model(**inputs) pred_label = torch.argmax(output.logits, axis=-1) return {"predicted_label": pred_label.cpu().numpy()} return fn ``` This is how the `get_test_accuracy()` is being used: ```py emotions = load_dataset("emotion") def tokenize(batch): return tokenizer(batch["text"], padding=True, truncation=True) emotions_encoded = emotions.map(tokenize, batched=True) emotions_encoded.set_format("torch", columns=["input_ids", "attention_mask", "label"]) new_dataset = emotions_encoded["validation"].map( accuracy_fn, batched=True, batch_size=128 ) ``` Complete code is available in the Colab Notebook provided below. The `map()` process fails midway giving: ```shell AttributeError Traceback (most recent call last) <ipython-input-8-ad24ac288eb4> in <module> 2 3 new_dataset = emotions_encoded["validation"].map( ----> 4 accuracy_fn, batched=True, batch_size=128 5 ) 7 frames /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in map(self, function, with_indices, with_rank, input_columns, batched, batch_size, drop_last_batch, remove_columns, keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, features, disable_nullable, fn_kwargs, num_proc, suffix_template, new_fingerprint, desc) 2588 new_fingerprint=new_fingerprint, 2589 disable_tqdm=disable_tqdm, -> 2590 desc=desc, 2591 ) 2592 else: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in wrapper(*args, **kwargs) 582 self: "Dataset" = kwargs.pop("self") 583 # apply actual function --> 584 out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs) 585 datasets: List["Dataset"] = list(out.values()) if isinstance(out, dict) else [out] 586 for dataset in datasets: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in wrapper(*args, **kwargs) 549 } 550 # apply actual function --> 551 out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs) 552 datasets: List["Dataset"] = list(out.values()) if isinstance(out, dict) else [out] 553 # re-apply format to the output /usr/local/lib/python3.7/dist-packages/datasets/fingerprint.py in wrapper(*args, **kwargs) 478 # Call actual function 479 --> 480 out = func(self, *args, **kwargs) 481 482 # Update fingerprint of in-place transforms + update in-place history of transforms /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in _map_single(self, function, with_indices, with_rank, input_columns, batched, batch_size, drop_last_batch, remove_columns, keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, features, disable_nullable, fn_kwargs, new_fingerprint, rank, offset, disable_tqdm, desc, cache_only) 2970 indices, 2971 check_same_num_examples=len(input_dataset.list_indexes()) > 0, -> 2972 offset=offset, 2973 ) 2974 except NumExamplesMismatchError: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in apply_function_on_filtered_inputs(inputs, indices, check_same_num_examples, offset) 2850 if with_rank: 2851 additional_args += (rank,) -> 2852 processed_inputs = function(*fn_args, *additional_args, **fn_kwargs) 2853 if update_data is None: 2854 # Check if the function returns updated examples <ipython-input-6-4e0d280426f6> in fn(batch) 1 def get_test_accuracy(model): 2 def fn(batch): ----> 3 inputs = {k:v.to(device) for k,v in batch.items() 4 if k in tokenizer.model_input_names} 5 with torch.no_grad(): <ipython-input-6-4e0d280426f6> in <dictcomp>(.0) 2 def fn(batch): 3 inputs = {k:v.to(device) for k,v in batch.items() ----> 4 if k in tokenizer.model_input_names} 5 with torch.no_grad(): 6 output = model(**inputs) AttributeError: 'list' object has no attribute 'to' ``` As you'd notice in the notebook, the process fails _midway_ and not at the beginning. Is this expected? ### Steps to reproduce the bug Colab Notebook: https://colab.research.google.com/gist/sayakpaul/d1570d537faf39040d02d77b1ed7de07/scratchpad.ipynb ### Expected behavior The mapping process should complete as is. If you switch the `split` to `test` it works as expected. ### Environment info Colab
450
597
`map()` fails midway due to format incompatibility ### Describe the bug I am using the `emotion` dataset from Hub for sequence classification. After training the model, I am using it to generate predictions for all the entries present in the `validation` split of the dataset. ```py def get_test_accuracy(model): def fn(batch): inputs = {k:v.to(device) for k,v in batch.items() if k in tokenizer.model_input_names} with torch.no_grad(): output = model(**inputs) pred_label = torch.argmax(output.logits, axis=-1) return {"predicted_label": pred_label.cpu().numpy()} return fn ``` This is how the `get_test_accuracy()` is being used: ```py emotions = load_dataset("emotion") def tokenize(batch): return tokenizer(batch["text"], padding=True, truncation=True) emotions_encoded = emotions.map(tokenize, batched=True) emotions_encoded.set_format("torch", columns=["input_ids", "attention_mask", "label"]) new_dataset = emotions_encoded["validation"].map( accuracy_fn, batched=True, batch_size=128 ) ``` Complete code is available in the Colab Notebook provided below. The `map()` process fails midway giving: ```shell AttributeError Traceback (most recent call last) <ipython-input-8-ad24ac288eb4> in <module> 2 3 new_dataset = emotions_encoded["validation"].map( ----> 4 accuracy_fn, batched=True, batch_size=128 5 ) 7 frames /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in map(self, function, with_indices, with_rank, input_columns, batched, batch_size, drop_last_batch, remove_columns, keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, features, disable_nullable, fn_kwargs, num_proc, suffix_template, new_fingerprint, desc) 2588 new_fingerprint=new_fingerprint, 2589 disable_tqdm=disable_tqdm, -> 2590 desc=desc, 2591 ) 2592 else: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in wrapper(*args, **kwargs) 582 self: "Dataset" = kwargs.pop("self") 583 # apply actual function --> 584 out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs) 585 datasets: List["Dataset"] = list(out.values()) if isinstance(out, dict) else [out] 586 for dataset in datasets: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in wrapper(*args, **kwargs) 549 } 550 # apply actual function --> 551 out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs) 552 datasets: List["Dataset"] = list(out.values()) if isinstance(out, dict) else [out] 553 # re-apply format to the output /usr/local/lib/python3.7/dist-packages/datasets/fingerprint.py in wrapper(*args, **kwargs) 478 # Call actual function 479 --> 480 out = func(self, *args, **kwargs) 481 482 # Update fingerprint of in-place transforms + update in-place history of transforms /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in _map_single(self, function, with_indices, with_rank, input_columns, batched, batch_size, drop_last_batch, remove_columns, keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, features, disable_nullable, fn_kwargs, new_fingerprint, rank, offset, disable_tqdm, desc, cache_only) 2970 indices, 2971 check_same_num_examples=len(input_dataset.list_indexes()) > 0, -> 2972 offset=offset, 2973 ) 2974 except NumExamplesMismatchError: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in apply_function_on_filtered_inputs(inputs, indices, check_same_num_examples, offset) 2850 if with_rank: 2851 additional_args += (rank,) -> 2852 processed_inputs = function(*fn_args, *additional_args, **fn_kwargs) 2853 if update_data is None: 2854 # Check if the function returns updated examples <ipython-input-6-4e0d280426f6> in fn(batch) 1 def get_test_accuracy(model): 2 def fn(batch): ----> 3 inputs = {k:v.to(device) for k,v in batch.items() 4 if k in tokenizer.model_input_names} 5 with torch.no_grad(): <ipython-input-6-4e0d280426f6> in <dictcomp>(.0) 2 def fn(batch): 3 inputs = {k:v.to(device) for k,v in batch.items() ----> 4 if k in tokenizer.model_input_names} 5 with torch.no_grad(): 6 output = model(**inputs) AttributeError: 'list' object has no attribute 'to' ``` As you'd notice in the notebook, the process fails _midway_ and not at the beginning. Is this expected? ### Steps to reproduce the bug Colab Notebook: https://colab.research.google.com/gist/sayakpaul/d1570d537faf39040d02d77b1ed7de07/scratchpad.ipynb ### Expected behavior The mapping process should complete as is. If you switch the `split` to `test` it works as expected. ### Environment info Colab This is what I got. For the non-erroring data, it looks like (without the labels): ``` tensor([[ 101, 10047, 3110, ..., 0, 0, 0], [ 101, 1045, 2514, ..., 0, 0, 0], [ 101, 1045, 2514, ..., 0, 0, 0], ..., [ 101, 1045, 2005, ..., 0, 0, 0], [ 101, 1045, 2572, ..., 0, 0, 0], [ 101, 10047, 7481, ..., 0, 0, 0]]) 128 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]]) 128 ``` For the erroring part: ``` [tensor([ 101, 1045, 2064, 2102, 2393, 3110, 2066, 2242, 6355, 3047, 2004, 2574, 2004, 1996, 8629, 2357, 2125, 4299, 1045, 2071, 2424, 2009, 2006, 7858, 102, 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, 0, 0, 0, 0, 0]), tensor([ 101, 10047, 5458, 1997, 3110, 11654, 1998, 11055, 102, 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]), tensor([ 101, 1045, 2074, 2064, 2102, 6073, 1996, 3110, 2008, 2026, 14982, 2000, 5587, 2203, 16650, 29563, 2030, 2569, 4506, 2052, 2191, 1037, 2738, 11552, 2208, 17044, 14540, 2100, 3375, 102, 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]), ... [tensor([1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 0, 0, 0, 0, 0]), tensor([1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]), ... ``` I also tried investigating the shapes of the individual entries within a `batch` without the labels: ```py def get_test_accuracy(model): def fn(batch): try: inputs = {k:v.to(device) for k,v in batch.items() if k in tokenizer.model_input_names} with torch.no_grad(): output = model(**inputs) pred_label = torch.argmax(output.logits, axis=-1) return {"predicted_label": pred_label.cpu().numpy()} except: for k in batch: if k != "label": for i in range(len(batch[k])): print(batch[k][i].shape) return fn ``` They are: ``` ... torch.Size([66]) torch.Size([66]) torch.Size([66]) torch.Size([66]) torch.Size([66]) torch.Size([66]) torch.Size([66]) torch.Size([66]) torch.Size([66]) torch.Size([66]) torch.Size([66]) torch.Size([66]) torch.Size([66]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) torch.Size([69]) ``` There are differing shapes. I understand if I set `batch_size=None` in `emotions_encoded = emotions.map(tokenize, batched=True)` the problem should be fixed as the whole dataset would be treated as a single batch. But is there a way to do that in batches?
[ -1.2564349174499512, -0.8618111610412598, -0.6586883068084717, 1.5509893894195557, -0.11722970008850098, -1.2016878128051758, 0.3056619465351105, -1.071123480796814, 1.6652281284332275, -0.8826600909233093, 0.3184569478034973, -1.5744513273239136, 0.06408709287643433, -0.6032147407531738, -0.7170072793960571, -0.827620267868042, -0.391541451215744, -0.7243706583976746, 1.102968454360962, 2.441807985305786, 1.345527172088623, -1.3015437126159668, 2.7619075775146484, 0.7074694037437439, -0.23903891444206238, -1.027679204940796, 0.5006363391876221, -0.04980858787894249, -1.2392507791519165, -0.48583224415779114, -0.9670151472091675, -0.09760599583387375, -0.6154596209526062, -0.4936542510986328, -0.030476875603199005, 0.4526210129261017, -0.34846463799476624, -0.4001949429512024, -0.5780141949653625, -0.8301367163658142, 0.5327627062797546, -0.32234451174736023, 0.9258394241333008, -0.2610061764717102, 1.7740511894226074, -0.6517888307571411, 0.5122497081756592, 0.7529274821281433, 1.3074336051940918, 0.17150403559207916, -0.0720311775803566, 0.36685800552368164, 0.35100361704826355, 0.02520972117781639, 0.5899772047996521, 1.2242026329040527, 0.6695250868797302, 0.5533755421638489, 0.67540043592453, -2.2437541484832764, 1.3265388011932373, -1.0817766189575195, 0.3195015788078308, 1.289945125579834, -0.9156166911125183, 0.28408458828926086, -1.7497355937957764, -0.0831250324845314, 0.5423450469970703, -2.2372968196868896, 0.3418833613395691, -1.3627794981002808, -0.5304228663444519, 0.9875593185424805, 0.34581151604652405, -1.2076531648635864, 0.13749630749225616, -0.44156789779663086, 1.0876474380493164, 0.4285399913787842, 1.0058739185333252, -1.7119542360305786, -0.02024657279253006, -0.2667766511440277, 0.2199711948633194, -1.2193071842193604, -1.5961761474609375, 0.6284483671188354, 0.5396755933761597, 0.525274932384491, -0.1628008335828781, 1.1209796667099, -1.128803014755249, 0.8071145415306091, -1.070693850517273, -1.688642144203186, -1.4215937852859497, -2.2521371841430664, -2.191432476043701, 0.654498815536499, -0.5312331318855286, -0.5206457376480103, 2.0725271701812744, -0.981368362903595, -1.6730248928070068, 1.139477252960205, 0.24169321358203888, -0.0005769440904259682, 2.348796844482422, 0.20958605408668518, -0.671931803226471, 0.4880581200122833, -0.8086337447166443, 0.7906571626663208, -0.3038729429244995, 1.3495352268218994, 0.4183017611503601, -1.0876206159591675, 1.5978964567184448, -0.37174084782600403, 0.5705781579017639, -0.553147554397583, -0.5441300272941589, -0.7247528433799744, 0.23205667734146118, 1.881868839263916, -0.2922987639904022, 1.4447945356369019, -0.3401529788970947, -1.502456784248352, -1.6106919050216675, 0.9807024598121643, 0.4544409215450287, -0.8311120867729187, 0.18271294236183167, -0.5307923555374146, 0.16542144119739532, -0.05783570185303688, 1.2451820373535156, 1.3419694900512695, 0.7997744083404541, -0.3967094421386719, -0.7611581683158875, 0.13777358829975128, -0.07958602160215378, -0.7141509652137756, -1.7604843378067017, -0.38904649019241333, 0.11336493492126465, 0.6691190004348755, -1.103524088859558, 1.837209701538086, 0.9380624294281006, 1.8849183320999146, 1.0147721767425537, -0.37624239921569824, 1.4652131795883179, 0.08214523643255234, 1.8020519018173218, -0.5186798572540283, 0.6336647272109985, -0.4189484715461731, -1.1765495538711548, 0.8918150663375854, -0.3119543194770813, -2.069382905960083, -0.7765493988990784, -0.7259145379066467, -0.1854252964258194, -0.8750786781311035, 0.930161714553833, -0.293204128742218, -1.4624985456466675, 0.20235463976860046, -0.7065148949623108, 0.14351630210876465, -1.1823662519454956, 0.3289157748222351, 0.6754565238952637, -0.650816023349762, 0.10384839028120041, -0.231216698884964, -1.2386047840118408, -0.516243577003479, 0.26797279715538025, 1.8828272819519043, -0.6313206553459167, 0.9253871440887451, 1.0674333572387695, -0.6744243502616882, -0.0685236006975174, 0.2832387685775757, -0.3361179530620575, 0.8468278646469116, -1.0320188999176025, -0.537996768951416, 1.2224764823913574, -0.19796226918697357, -0.5550762414932251, 1.4795533418655396, 0.6074240207672119, -1.0154998302459717, -0.2785501778125763, -0.1537284553050995, -0.8851861357688904, 0.09792763739824295, -1.5087882280349731, -0.14053253829479218, 0.5158325433731079, -1.5553847551345825, -0.4324536621570587, -0.16466334462165833, 1.3224083185195923, -0.19398628175258636, 1.489725947380066, -0.37042659521102905, -0.16392745077610016, -0.2994914650917053, -0.3450047969818115, 0.15702687203884125, -0.09183439612388611, -0.6712797284126282, 0.12571211159229279, -0.8052224516868591, 0.38129231333732605, 1.4665462970733643, 0.2486332207918167, 0.02911742776632309, 0.45866236090660095, 1.100577473640442, 0.3628608286380768, -0.08157375454902649, -0.9239226579666138, -1.5509613752365112, 1.9792550802230835, -1.4797959327697754, 2.00675892829895, 0.7830439805984497, -0.08020652085542679, -1.8123866319656372, -1.7918002605438232, 1.3311359882354736, 1.1580243110656738, 2.3174266815185547, 0.5244920253753662, 0.4165392220020294, -0.7668754458427429, -0.6583884954452515, 0.30397865176200867, -1.0827196836471558, -0.6753581166267395, 0.23990613222122192, 2.4044692516326904, 1.781298279762268, -0.4425797164440155, -0.19101209938526154, -0.9829928278923035, 1.3376902341842651, -0.28112199902534485, 0.21211613714694977, 1.9484807252883911, -0.2299797385931015, -1.0529167652130127, 1.3466925621032715, -2.3654701709747314, 0.22468525171279907, 2.0508697032928467, 0.3507494032382965, 0.12460658699274063, -1.3239268064498901, -0.5475836396217346, -0.28874456882476807, -0.46919599175453186, -1.2885594367980957, 0.4973348081111908, -0.18551316857337952, -0.7874863147735596, -1.348490595817566, 0.19899608194828033, -1.122996211051941, -1.695956826210022, 0.23043550550937653, 1.9107682704925537, 2.1109068393707275, -0.7488948106765747, 1.5649986267089844, -0.42424625158309937, 0.16996417939662933, 1.2032641172409058, 1.312498688697815, 3.071192741394043, 1.8642898797988892, -1.3581467866897583, 0.6676552295684814, -0.2173980325460434, -0.559167206287384, 1.1652779579162598, -1.2637075185775757, 1.264624834060669, -0.11867415904998779, -1.2049411535263062, -1.2521247863769531, 1.0117484331130981, 0.4367265999317169, 0.05127795785665512, -0.4933066666126251, 1.1553038358688354, 0.15893927216529846, 1.3814609050750732, 0.5917761325836182, -0.3316621482372284, 0.6258667707443237, -0.4016607999801636, -0.4500105082988739, 1.5580692291259766, 0.18183785676956177, -1.4025628566741943, -2.283634901046753, -0.14928534626960754, -0.8979191780090332, 0.14238892495632172, -0.6187760233879089, -0.9766247868537903, 1.6309442520141602, 0.3100856840610504, -1.230992078781128, -0.2641846537590027, -0.36611834168434143, -0.5520333051681519, 2.7195887565612793, -1.2184863090515137, -0.2524767220020294, -0.9723224639892578, -0.7886156439781189, 1.59701669216156, -1.2435729503631592, -0.2156052440404892, -0.9555762410163879, -0.5506362915039062, -1.2841285467147827, -0.5390051603317261, 0.04608776420354843, -0.965511679649353, 0.7735902070999146, 0.18929684162139893, -1.2301790714263916, -0.42056599259376526, -0.7898242473602295, 0.9418392777442932, -0.24473094940185547, 0.15271149575710297, 1.8207292556762695, 0.2454354614019394, -0.35870057344436646, 0.8547343015670776, 1.1780147552490234, 0.609052300453186, -0.5519440174102783, 0.1613217294216156, -0.6711052656173706, 0.3499176800251007, -1.2448660135269165, 0.3145863711833954, -2.8695645332336426, 0.671040952205658, -0.021004751324653625, -0.09424528479576111, -0.08122210949659348, -1.4300894737243652, 1.0155657529830933, 2.6010677814483643, -1.1604251861572266, 0.5007954239845276, 0.32741987705230713, 1.1422251462936401, -1.591278314590454, 0.21408309042453766, -0.49440354108810425, 2.0756351947784424, 0.28954532742500305, 1.2567297220230103, -0.45648178458213806, -2.3433303833007812, 0.6205129623413086, -1.3557045459747314, -1.15959632396698, 0.7685874104499817, -0.8521873354911804, 0.1507054567337036, -1.339126706123352, -0.27235254645347595, -0.8838710188865662, -1.1251634359359741, 0.637652575969696, 0.14716266095638275, 0.4194837212562561, -0.6093424558639526, 0.30907759070396423, -2.2107105255126953, -1.3018547296524048, -0.14408697187900543, -0.977510392665863, 0.5190096497535706, -0.48462551832199097, 0.7006571888923645, -0.11337742954492569, -0.013470589183270931, 0.4146192669868469, 1.5095349550247192, 3.386756658554077, 0.2199634462594986, 0.2824596166610718, -0.2776835262775421, -0.9641700387001038, 1.5215599536895752, 0.8457326889038086, -0.17773663997650146, -0.5651062726974487, -1.0686368942260742, 1.256855845451355, 1.8958994150161743, 0.8588723540306091, 0.02651117742061615, -0.8922290802001953, -0.7044177055358887, -0.052574142813682556, 0.11829269677400589, 0.4314849078655243, 0.9280596375465393, 0.13030695915222168, 0.04300333186984062, 1.4032280445098877, 1.1352241039276123, -0.4024324119091034, 0.3544304072856903, -0.8399837017059326, -0.3837916851043701, 0.5275399684906006, 0.27099207043647766, -0.038755375891923904, 0.3699900507926941, -0.920984148979187, -0.2893209457397461, -0.3933523893356323, -0.8521087765693665, -0.7494899034500122, -0.4101017713546753, -0.37057560682296753, 1.6459875106811523, 0.13157469034194946, -0.4926767945289612, -0.02535157836973667, -0.7864295244216919, -0.1456502079963684, -1.1047048568725586, 0.20037318766117096, -0.06104257330298424, -0.14033475518226624, -0.15852662920951843, 1.7353472709655762, -0.8827623128890991, -2.0497517585754395, 0.1912117898464203, 0.20480452477931976, -0.22941423952579498, 0.2140512466430664, 1.6909289360046387, 0.4844909906387329, 1.4448579549789429, 1.2889355421066284, 0.9701460599899292, -0.6217978000640869, -1.2950255870819092, 0.7722205519676208, 0.9390353560447693, -1.3919720649719238, 0.8187793493270874, -0.07688263058662415, -0.4715798795223236, 0.6058039665222168, 1.1926673650741577, 0.5125511884689331, -1.9851857423782349, 0.8043025135993958, -1.0349947214126587, 0.8150075078010559, 0.7428379654884338, 0.6157976388931274, 0.2448112517595291, 0.8692721724510193, -1.2233421802520752, -1.1115431785583496, -0.6526858806610107, -0.7141526937484741, 2.0142617225646973, -0.35835039615631104, 0.6308340430259705, -0.2381220906972885, -1.3672821521759033, -0.08315305411815643, 0.7389456629753113, 0.3749692142009735, -0.506883978843689, 0.7433762550354004, -0.7123759388923645, -1.0244725942611694, -1.3419419527053833, -0.4537983536720276, -1.1077501773834229, -1.023657202720642, 1.0641082525253296, 0.6988312005996704, 0.3103312849998474, 1.9031773805618286, 0.6459838151931763, 0.2619236707687378, -2.537459135055542, 0.861052930355072, 0.2601129412651062, -0.09079334139823914, 0.8776627779006958, 0.46942517161369324, 1.0049712657928467, 0.015680667012929916, 0.6060882806777954, -2.4960954189300537, 2.356536865234375, -0.12105764448642731, 0.7078245878219604, 0.07416543364524841, -0.24286387860774994, 1.173863172531128, 0.5792101621627808, 0.47801917791366577, -1.0627354383468628, 0.6155811548233032, -0.5743517875671387, 1.2609212398529053, 0.8360148072242737, -0.8362006545066833, -0.002662207931280136, 1.3921946287155151, 0.46437886357307434, -0.5007355809211731, -0.9238314032554626, -0.956911027431488, 0.9564623236656189, 1.6793441772460938, -0.05409897863864899, -0.02257390320301056, 0.7253323197364807, 0.7134193181991577, -1.258240818977356, 0.0881405770778656, -0.6925987005233765, -0.7618107795715332, 1.6358152627944946, 2.0891144275665283, -0.21775691211223602, -0.17107610404491425, -0.6862389445304871, -1.3521744012832642, 0.8534873127937317, -0.09288079291582108, 0.10966837406158447, 0.6103137731552124, -0.5857788324356079, 0.969518780708313, 0.8980392813682556, 0.930030107498169, 0.2913565933704376, 0.29146233201026917, 0.394858181476593, -0.3791663348674774, -1.116383671760559, -0.22212131321430206, -1.093349814414978, -2.678900718688965, 0.4207954406738281, -0.2652113139629364, -1.3707736730575562, 0.03746476396918297, -0.9597068428993225, 0.8683139085769653, -0.6084392070770264, -1.1210410594940186, -1.4711421728134155, 0.24895964562892914, 0.006735139526426792, 0.9902312159538269, -1.604506492614746, -0.17397285997867584, 1.1914445161819458, 0.8709969520568848, -0.7049355506896973, 0.9642133116722107, 0.2078114151954651, 1.0250040292739868, 0.8568227887153625, -0.4181331396102905, 0.6182434558868408, 0.03507668152451515, -1.3783280849456787, 0.4445445239543915, 1.2207696437835693, 0.23791398108005524, 1.5120775699615479, -0.38951700925827026, 0.018091395497322083, 0.42769789695739746, -0.6623564958572388, -0.5585848689079285, -0.41871777176856995, 0.5870958566665649, 0.028583165258169174, -0.9827859401702881, -0.09199051558971405, -0.03534920886158943, -0.31863588094711304, 0.1888469159603119, -1.4407734870910645, -0.1417376548051834, -0.4051297903060913, -0.600477397441864, -1.2937644720077515, -0.12243188917636871, 1.4057859182357788, -0.7638819813728333, -0.16007228195667267, 0.40202417969703674, 0.3811003863811493, 0.51077800989151, 0.6530059576034546, -0.8079514503479004, -0.3516363501548767, -0.2352105975151062, -0.3383120000362396, 0.4119672179222107, 1.3774250745773315, -0.08127759397029877, -0.9346227049827576, 0.6019138693809509, -0.3113865852355957, 0.09594712406396866, 1.8889340162277222, 0.064056895673275, -0.7672309279441833, 0.29870420694351196, -0.7527433037757874, 1.8976861238479614, 1.7361884117126465, 1.2734543085098267, -0.1465306133031845, -0.84157395362854, 0.6844934225082397, -0.4384704530239105, -0.3459400534629822, 0.868216872215271, 0.3207721412181854, -0.2318442314863205, -1.5236824750900269, 0.7911661267280579, 1.3275882005691528, -0.7890422344207764, -0.8569883108139038, 0.15691283345222473, -0.7737320065498352, 1.194298505783081, 0.5839184522628784, 0.32634270191192627, 0.2878434956073761, 1.6030879020690918, 0.8075254559516907, -0.40163421630859375, 0.5591980218887329, 0.5148944854736328, -0.1539243757724762, -2.205169200897217, -1.2601948976516724, 0.3416507840156555, -0.5841649770736694, -1.5605953931808472, 1.4439810514450073, -1.0924017429351807, -1.112066626548767, 0.5980516672134399, 0.08635575324296951, 1.3276584148406982, 0.3924199938774109, 1.5543813705444336, 2.0440750122070312, 0.7962685823440552, 0.43006181716918945, 1.22671639919281, -0.1449178159236908, -0.48397305607795715, 1.7556226253509521, -0.41754817962646484, 0.49532386660575867, 1.1325857639312744, -0.27241015434265137, -1.1654233932495117, -0.8186470866203308, -1.2690367698669434, -0.798886775970459, 1.1543046236038208, 0.08968789130449295, -1.0725897550582886, 0.26485493779182434, 1.6204137802124023, 0.1732502430677414, -0.253827840089798, 0.6367133855819702, 0.4354454278945923, -0.7482894062995911, -0.011351436376571655, -0.8824612498283386, 0.5348762273788452, -0.2903853952884674, -0.37671464681625366, 0.32501861453056335, 0.48895135521888733, 1.3226211071014404, -0.05089137703180313, 0.05348017439246178, 1.0252052545547485, -1.467864990234375, 1.4771651029586792, -0.658483624458313, 0.3264654874801636, -2.357149600982666, 1.3275173902511597, -0.7595835328102112, 2.001539707183838, -2.663938283920288, 0.47669604420661926, -0.549942135810852, -0.49217116832733154, 0.28631314635276794, -0.31725940108299255, 0.09084171056747437, -0.131460040807724, -1.101257562637329, -0.0536457821726799, -0.6570311784744263, 0.6248765587806702, 1.1304302215576172, 1.3858965635299683, -1.1660349369049072, -0.23406395316123962, -1.6564133167266846, -0.034714408218860626, -0.743509829044342, 0.17763105034828186, -1.956472635269165, -0.21818798780441284, -1.9411677122116089, -2.355215311050415, -1.2008016109466553, -0.7569925785064697, 1.1258121728897095, 0.13358688354492188, -0.8405548930168152, 1.3179728984832764, -0.398405522108078, -1.8127456903457642, 1.0479952096939087, -2.151811361312866 ]
https://github.com/huggingface/datasets/issues/5179
`map()` fails midway due to format incompatibility
If you use the same batch_size for your two maps, you should get the exact same batches - therefore all containing the same shapes
### Describe the bug I am using the `emotion` dataset from Hub for sequence classification. After training the model, I am using it to generate predictions for all the entries present in the `validation` split of the dataset. ```py def get_test_accuracy(model): def fn(batch): inputs = {k:v.to(device) for k,v in batch.items() if k in tokenizer.model_input_names} with torch.no_grad(): output = model(**inputs) pred_label = torch.argmax(output.logits, axis=-1) return {"predicted_label": pred_label.cpu().numpy()} return fn ``` This is how the `get_test_accuracy()` is being used: ```py emotions = load_dataset("emotion") def tokenize(batch): return tokenizer(batch["text"], padding=True, truncation=True) emotions_encoded = emotions.map(tokenize, batched=True) emotions_encoded.set_format("torch", columns=["input_ids", "attention_mask", "label"]) new_dataset = emotions_encoded["validation"].map( accuracy_fn, batched=True, batch_size=128 ) ``` Complete code is available in the Colab Notebook provided below. The `map()` process fails midway giving: ```shell AttributeError Traceback (most recent call last) <ipython-input-8-ad24ac288eb4> in <module> 2 3 new_dataset = emotions_encoded["validation"].map( ----> 4 accuracy_fn, batched=True, batch_size=128 5 ) 7 frames /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in map(self, function, with_indices, with_rank, input_columns, batched, batch_size, drop_last_batch, remove_columns, keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, features, disable_nullable, fn_kwargs, num_proc, suffix_template, new_fingerprint, desc) 2588 new_fingerprint=new_fingerprint, 2589 disable_tqdm=disable_tqdm, -> 2590 desc=desc, 2591 ) 2592 else: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in wrapper(*args, **kwargs) 582 self: "Dataset" = kwargs.pop("self") 583 # apply actual function --> 584 out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs) 585 datasets: List["Dataset"] = list(out.values()) if isinstance(out, dict) else [out] 586 for dataset in datasets: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in wrapper(*args, **kwargs) 549 } 550 # apply actual function --> 551 out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs) 552 datasets: List["Dataset"] = list(out.values()) if isinstance(out, dict) else [out] 553 # re-apply format to the output /usr/local/lib/python3.7/dist-packages/datasets/fingerprint.py in wrapper(*args, **kwargs) 478 # Call actual function 479 --> 480 out = func(self, *args, **kwargs) 481 482 # Update fingerprint of in-place transforms + update in-place history of transforms /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in _map_single(self, function, with_indices, with_rank, input_columns, batched, batch_size, drop_last_batch, remove_columns, keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, features, disable_nullable, fn_kwargs, new_fingerprint, rank, offset, disable_tqdm, desc, cache_only) 2970 indices, 2971 check_same_num_examples=len(input_dataset.list_indexes()) > 0, -> 2972 offset=offset, 2973 ) 2974 except NumExamplesMismatchError: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in apply_function_on_filtered_inputs(inputs, indices, check_same_num_examples, offset) 2850 if with_rank: 2851 additional_args += (rank,) -> 2852 processed_inputs = function(*fn_args, *additional_args, **fn_kwargs) 2853 if update_data is None: 2854 # Check if the function returns updated examples <ipython-input-6-4e0d280426f6> in fn(batch) 1 def get_test_accuracy(model): 2 def fn(batch): ----> 3 inputs = {k:v.to(device) for k,v in batch.items() 4 if k in tokenizer.model_input_names} 5 with torch.no_grad(): <ipython-input-6-4e0d280426f6> in <dictcomp>(.0) 2 def fn(batch): 3 inputs = {k:v.to(device) for k,v in batch.items() ----> 4 if k in tokenizer.model_input_names} 5 with torch.no_grad(): 6 output = model(**inputs) AttributeError: 'list' object has no attribute 'to' ``` As you'd notice in the notebook, the process fails _midway_ and not at the beginning. Is this expected? ### Steps to reproduce the bug Colab Notebook: https://colab.research.google.com/gist/sayakpaul/d1570d537faf39040d02d77b1ed7de07/scratchpad.ipynb ### Expected behavior The mapping process should complete as is. If you switch the `split` to `test` it works as expected. ### Environment info Colab
450
24
`map()` fails midway due to format incompatibility ### Describe the bug I am using the `emotion` dataset from Hub for sequence classification. After training the model, I am using it to generate predictions for all the entries present in the `validation` split of the dataset. ```py def get_test_accuracy(model): def fn(batch): inputs = {k:v.to(device) for k,v in batch.items() if k in tokenizer.model_input_names} with torch.no_grad(): output = model(**inputs) pred_label = torch.argmax(output.logits, axis=-1) return {"predicted_label": pred_label.cpu().numpy()} return fn ``` This is how the `get_test_accuracy()` is being used: ```py emotions = load_dataset("emotion") def tokenize(batch): return tokenizer(batch["text"], padding=True, truncation=True) emotions_encoded = emotions.map(tokenize, batched=True) emotions_encoded.set_format("torch", columns=["input_ids", "attention_mask", "label"]) new_dataset = emotions_encoded["validation"].map( accuracy_fn, batched=True, batch_size=128 ) ``` Complete code is available in the Colab Notebook provided below. The `map()` process fails midway giving: ```shell AttributeError Traceback (most recent call last) <ipython-input-8-ad24ac288eb4> in <module> 2 3 new_dataset = emotions_encoded["validation"].map( ----> 4 accuracy_fn, batched=True, batch_size=128 5 ) 7 frames /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in map(self, function, with_indices, with_rank, input_columns, batched, batch_size, drop_last_batch, remove_columns, keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, features, disable_nullable, fn_kwargs, num_proc, suffix_template, new_fingerprint, desc) 2588 new_fingerprint=new_fingerprint, 2589 disable_tqdm=disable_tqdm, -> 2590 desc=desc, 2591 ) 2592 else: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in wrapper(*args, **kwargs) 582 self: "Dataset" = kwargs.pop("self") 583 # apply actual function --> 584 out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs) 585 datasets: List["Dataset"] = list(out.values()) if isinstance(out, dict) else [out] 586 for dataset in datasets: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in wrapper(*args, **kwargs) 549 } 550 # apply actual function --> 551 out: Union["Dataset", "DatasetDict"] = func(self, *args, **kwargs) 552 datasets: List["Dataset"] = list(out.values()) if isinstance(out, dict) else [out] 553 # re-apply format to the output /usr/local/lib/python3.7/dist-packages/datasets/fingerprint.py in wrapper(*args, **kwargs) 478 # Call actual function 479 --> 480 out = func(self, *args, **kwargs) 481 482 # Update fingerprint of in-place transforms + update in-place history of transforms /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in _map_single(self, function, with_indices, with_rank, input_columns, batched, batch_size, drop_last_batch, remove_columns, keep_in_memory, load_from_cache_file, cache_file_name, writer_batch_size, features, disable_nullable, fn_kwargs, new_fingerprint, rank, offset, disable_tqdm, desc, cache_only) 2970 indices, 2971 check_same_num_examples=len(input_dataset.list_indexes()) > 0, -> 2972 offset=offset, 2973 ) 2974 except NumExamplesMismatchError: /usr/local/lib/python3.7/dist-packages/datasets/arrow_dataset.py in apply_function_on_filtered_inputs(inputs, indices, check_same_num_examples, offset) 2850 if with_rank: 2851 additional_args += (rank,) -> 2852 processed_inputs = function(*fn_args, *additional_args, **fn_kwargs) 2853 if update_data is None: 2854 # Check if the function returns updated examples <ipython-input-6-4e0d280426f6> in fn(batch) 1 def get_test_accuracy(model): 2 def fn(batch): ----> 3 inputs = {k:v.to(device) for k,v in batch.items() 4 if k in tokenizer.model_input_names} 5 with torch.no_grad(): <ipython-input-6-4e0d280426f6> in <dictcomp>(.0) 2 def fn(batch): 3 inputs = {k:v.to(device) for k,v in batch.items() ----> 4 if k in tokenizer.model_input_names} 5 with torch.no_grad(): 6 output = model(**inputs) AttributeError: 'list' object has no attribute 'to' ``` As you'd notice in the notebook, the process fails _midway_ and not at the beginning. Is this expected? ### Steps to reproduce the bug Colab Notebook: https://colab.research.google.com/gist/sayakpaul/d1570d537faf39040d02d77b1ed7de07/scratchpad.ipynb ### Expected behavior The mapping process should complete as is. If you switch the `split` to `test` it works as expected. ### Environment info Colab If you use the same batch_size for your two maps, you should get the exact same batches - therefore all containing the same shapes
[ -1.2564349174499512, -0.8618111610412598, -0.6586883068084717, 1.5509893894195557, -0.11722970008850098, -1.2016878128051758, 0.3056619465351105, -1.071123480796814, 1.6652281284332275, -0.8826600909233093, 0.3184569478034973, -1.5744513273239136, 0.06408709287643433, -0.6032147407531738, -0.7170072793960571, -0.827620267868042, -0.391541451215744, -0.7243706583976746, 1.102968454360962, 2.441807985305786, 1.345527172088623, -1.3015437126159668, 2.7619075775146484, 0.7074694037437439, -0.23903891444206238, -1.027679204940796, 0.5006363391876221, -0.04980858787894249, -1.2392507791519165, -0.48583224415779114, -0.9670151472091675, -0.09760599583387375, -0.6154596209526062, -0.4936542510986328, -0.030476875603199005, 0.4526210129261017, -0.34846463799476624, -0.4001949429512024, -0.5780141949653625, -0.8301367163658142, 0.5327627062797546, -0.32234451174736023, 0.9258394241333008, -0.2610061764717102, 1.7740511894226074, -0.6517888307571411, 0.5122497081756592, 0.7529274821281433, 1.3074336051940918, 0.17150403559207916, -0.0720311775803566, 0.36685800552368164, 0.35100361704826355, 0.02520972117781639, 0.5899772047996521, 1.2242026329040527, 0.6695250868797302, 0.5533755421638489, 0.67540043592453, -2.2437541484832764, 1.3265388011932373, -1.0817766189575195, 0.3195015788078308, 1.289945125579834, -0.9156166911125183, 0.28408458828926086, -1.7497355937957764, -0.0831250324845314, 0.5423450469970703, -2.2372968196868896, 0.3418833613395691, -1.3627794981002808, -0.5304228663444519, 0.9875593185424805, 0.34581151604652405, -1.2076531648635864, 0.13749630749225616, -0.44156789779663086, 1.0876474380493164, 0.4285399913787842, 1.0058739185333252, -1.7119542360305786, -0.02024657279253006, -0.2667766511440277, 0.2199711948633194, -1.2193071842193604, -1.5961761474609375, 0.6284483671188354, 0.5396755933761597, 0.525274932384491, -0.1628008335828781, 1.1209796667099, -1.128803014755249, 0.8071145415306091, -1.070693850517273, -1.688642144203186, -1.4215937852859497, -2.2521371841430664, -2.191432476043701, 0.654498815536499, -0.5312331318855286, -0.5206457376480103, 2.0725271701812744, -0.981368362903595, -1.6730248928070068, 1.139477252960205, 0.24169321358203888, -0.0005769440904259682, 2.348796844482422, 0.20958605408668518, -0.671931803226471, 0.4880581200122833, -0.8086337447166443, 0.7906571626663208, -0.3038729429244995, 1.3495352268218994, 0.4183017611503601, -1.0876206159591675, 1.5978964567184448, -0.37174084782600403, 0.5705781579017639, -0.553147554397583, -0.5441300272941589, -0.7247528433799744, 0.23205667734146118, 1.881868839263916, -0.2922987639904022, 1.4447945356369019, -0.3401529788970947, -1.502456784248352, -1.6106919050216675, 0.9807024598121643, 0.4544409215450287, -0.8311120867729187, 0.18271294236183167, -0.5307923555374146, 0.16542144119739532, -0.05783570185303688, 1.2451820373535156, 1.3419694900512695, 0.7997744083404541, -0.3967094421386719, -0.7611581683158875, 0.13777358829975128, -0.07958602160215378, -0.7141509652137756, -1.7604843378067017, -0.38904649019241333, 0.11336493492126465, 0.6691190004348755, -1.103524088859558, 1.837209701538086, 0.9380624294281006, 1.8849183320999146, 1.0147721767425537, -0.37624239921569824, 1.4652131795883179, 0.08214523643255234, 1.8020519018173218, -0.5186798572540283, 0.6336647272109985, -0.4189484715461731, -1.1765495538711548, 0.8918150663375854, -0.3119543194770813, -2.069382905960083, -0.7765493988990784, -0.7259145379066467, -0.1854252964258194, -0.8750786781311035, 0.930161714553833, -0.293204128742218, -1.4624985456466675, 0.20235463976860046, -0.7065148949623108, 0.14351630210876465, -1.1823662519454956, 0.3289157748222351, 0.6754565238952637, -0.650816023349762, 0.10384839028120041, -0.231216698884964, -1.2386047840118408, -0.516243577003479, 0.26797279715538025, 1.8828272819519043, -0.6313206553459167, 0.9253871440887451, 1.0674333572387695, -0.6744243502616882, -0.0685236006975174, 0.2832387685775757, -0.3361179530620575, 0.8468278646469116, -1.0320188999176025, -0.537996768951416, 1.2224764823913574, -0.19796226918697357, -0.5550762414932251, 1.4795533418655396, 0.6074240207672119, -1.0154998302459717, -0.2785501778125763, -0.1537284553050995, -0.8851861357688904, 0.09792763739824295, -1.5087882280349731, -0.14053253829479218, 0.5158325433731079, -1.5553847551345825, -0.4324536621570587, -0.16466334462165833, 1.3224083185195923, -0.19398628175258636, 1.489725947380066, -0.37042659521102905, -0.16392745077610016, -0.2994914650917053, -0.3450047969818115, 0.15702687203884125, -0.09183439612388611, -0.6712797284126282, 0.12571211159229279, -0.8052224516868591, 0.38129231333732605, 1.4665462970733643, 0.2486332207918167, 0.02911742776632309, 0.45866236090660095, 1.100577473640442, 0.3628608286380768, -0.08157375454902649, -0.9239226579666138, -1.5509613752365112, 1.9792550802230835, -1.4797959327697754, 2.00675892829895, 0.7830439805984497, -0.08020652085542679, -1.8123866319656372, -1.7918002605438232, 1.3311359882354736, 1.1580243110656738, 2.3174266815185547, 0.5244920253753662, 0.4165392220020294, -0.7668754458427429, -0.6583884954452515, 0.30397865176200867, -1.0827196836471558, -0.6753581166267395, 0.23990613222122192, 2.4044692516326904, 1.781298279762268, -0.4425797164440155, -0.19101209938526154, -0.9829928278923035, 1.3376902341842651, -0.28112199902534485, 0.21211613714694977, 1.9484807252883911, -0.2299797385931015, -1.0529167652130127, 1.3466925621032715, -2.3654701709747314, 0.22468525171279907, 2.0508697032928467, 0.3507494032382965, 0.12460658699274063, -1.3239268064498901, -0.5475836396217346, -0.28874456882476807, -0.46919599175453186, -1.2885594367980957, 0.4973348081111908, -0.18551316857337952, -0.7874863147735596, -1.348490595817566, 0.19899608194828033, -1.122996211051941, -1.695956826210022, 0.23043550550937653, 1.9107682704925537, 2.1109068393707275, -0.7488948106765747, 1.5649986267089844, -0.42424625158309937, 0.16996417939662933, 1.2032641172409058, 1.312498688697815, 3.071192741394043, 1.8642898797988892, -1.3581467866897583, 0.6676552295684814, -0.2173980325460434, -0.559167206287384, 1.1652779579162598, -1.2637075185775757, 1.264624834060669, -0.11867415904998779, -1.2049411535263062, -1.2521247863769531, 1.0117484331130981, 0.4367265999317169, 0.05127795785665512, -0.4933066666126251, 1.1553038358688354, 0.15893927216529846, 1.3814609050750732, 0.5917761325836182, -0.3316621482372284, 0.6258667707443237, -0.4016607999801636, -0.4500105082988739, 1.5580692291259766, 0.18183785676956177, -1.4025628566741943, -2.283634901046753, -0.14928534626960754, -0.8979191780090332, 0.14238892495632172, -0.6187760233879089, -0.9766247868537903, 1.6309442520141602, 0.3100856840610504, -1.230992078781128, -0.2641846537590027, -0.36611834168434143, -0.5520333051681519, 2.7195887565612793, -1.2184863090515137, -0.2524767220020294, -0.9723224639892578, -0.7886156439781189, 1.59701669216156, -1.2435729503631592, -0.2156052440404892, -0.9555762410163879, -0.5506362915039062, -1.2841285467147827, -0.5390051603317261, 0.04608776420354843, -0.965511679649353, 0.7735902070999146, 0.18929684162139893, -1.2301790714263916, -0.42056599259376526, -0.7898242473602295, 0.9418392777442932, -0.24473094940185547, 0.15271149575710297, 1.8207292556762695, 0.2454354614019394, -0.35870057344436646, 0.8547343015670776, 1.1780147552490234, 0.609052300453186, -0.5519440174102783, 0.1613217294216156, -0.6711052656173706, 0.3499176800251007, -1.2448660135269165, 0.3145863711833954, -2.8695645332336426, 0.671040952205658, -0.021004751324653625, -0.09424528479576111, -0.08122210949659348, -1.4300894737243652, 1.0155657529830933, 2.6010677814483643, -1.1604251861572266, 0.5007954239845276, 0.32741987705230713, 1.1422251462936401, -1.591278314590454, 0.21408309042453766, -0.49440354108810425, 2.0756351947784424, 0.28954532742500305, 1.2567297220230103, -0.45648178458213806, -2.3433303833007812, 0.6205129623413086, -1.3557045459747314, -1.15959632396698, 0.7685874104499817, -0.8521873354911804, 0.1507054567337036, -1.339126706123352, -0.27235254645347595, -0.8838710188865662, -1.1251634359359741, 0.637652575969696, 0.14716266095638275, 0.4194837212562561, -0.6093424558639526, 0.30907759070396423, -2.2107105255126953, -1.3018547296524048, -0.14408697187900543, -0.977510392665863, 0.5190096497535706, -0.48462551832199097, 0.7006571888923645, -0.11337742954492569, -0.013470589183270931, 0.4146192669868469, 1.5095349550247192, 3.386756658554077, 0.2199634462594986, 0.2824596166610718, -0.2776835262775421, -0.9641700387001038, 1.5215599536895752, 0.8457326889038086, -0.17773663997650146, -0.5651062726974487, -1.0686368942260742, 1.256855845451355, 1.8958994150161743, 0.8588723540306091, 0.02651117742061615, -0.8922290802001953, -0.7044177055358887, -0.052574142813682556, 0.11829269677400589, 0.4314849078655243, 0.9280596375465393, 0.13030695915222168, 0.04300333186984062, 1.4032280445098877, 1.1352241039276123, -0.4024324119091034, 0.3544304072856903, -0.8399837017059326, -0.3837916851043701, 0.5275399684906006, 0.27099207043647766, -0.038755375891923904, 0.3699900507926941, -0.920984148979187, -0.2893209457397461, -0.3933523893356323, -0.8521087765693665, -0.7494899034500122, -0.4101017713546753, -0.37057560682296753, 1.6459875106811523, 0.13157469034194946, -0.4926767945289612, -0.02535157836973667, -0.7864295244216919, -0.1456502079963684, -1.1047048568725586, 0.20037318766117096, -0.06104257330298424, -0.14033475518226624, -0.15852662920951843, 1.7353472709655762, -0.8827623128890991, -2.0497517585754395, 0.1912117898464203, 0.20480452477931976, -0.22941423952579498, 0.2140512466430664, 1.6909289360046387, 0.4844909906387329, 1.4448579549789429, 1.2889355421066284, 0.9701460599899292, -0.6217978000640869, -1.2950255870819092, 0.7722205519676208, 0.9390353560447693, -1.3919720649719238, 0.8187793493270874, -0.07688263058662415, -0.4715798795223236, 0.6058039665222168, 1.1926673650741577, 0.5125511884689331, -1.9851857423782349, 0.8043025135993958, -1.0349947214126587, 0.8150075078010559, 0.7428379654884338, 0.6157976388931274, 0.2448112517595291, 0.8692721724510193, -1.2233421802520752, -1.1115431785583496, -0.6526858806610107, -0.7141526937484741, 2.0142617225646973, -0.35835039615631104, 0.6308340430259705, -0.2381220906972885, -1.3672821521759033, -0.08315305411815643, 0.7389456629753113, 0.3749692142009735, -0.506883978843689, 0.7433762550354004, -0.7123759388923645, -1.0244725942611694, -1.3419419527053833, -0.4537983536720276, -1.1077501773834229, -1.023657202720642, 1.0641082525253296, 0.6988312005996704, 0.3103312849998474, 1.9031773805618286, 0.6459838151931763, 0.2619236707687378, -2.537459135055542, 0.861052930355072, 0.2601129412651062, -0.09079334139823914, 0.8776627779006958, 0.46942517161369324, 1.0049712657928467, 0.015680667012929916, 0.6060882806777954, -2.4960954189300537, 2.356536865234375, -0.12105764448642731, 0.7078245878219604, 0.07416543364524841, -0.24286387860774994, 1.173863172531128, 0.5792101621627808, 0.47801917791366577, -1.0627354383468628, 0.6155811548233032, -0.5743517875671387, 1.2609212398529053, 0.8360148072242737, -0.8362006545066833, -0.002662207931280136, 1.3921946287155151, 0.46437886357307434, -0.5007355809211731, -0.9238314032554626, -0.956911027431488, 0.9564623236656189, 1.6793441772460938, -0.05409897863864899, -0.02257390320301056, 0.7253323197364807, 0.7134193181991577, -1.258240818977356, 0.0881405770778656, -0.6925987005233765, -0.7618107795715332, 1.6358152627944946, 2.0891144275665283, -0.21775691211223602, -0.17107610404491425, -0.6862389445304871, -1.3521744012832642, 0.8534873127937317, -0.09288079291582108, 0.10966837406158447, 0.6103137731552124, -0.5857788324356079, 0.969518780708313, 0.8980392813682556, 0.930030107498169, 0.2913565933704376, 0.29146233201026917, 0.394858181476593, -0.3791663348674774, -1.116383671760559, -0.22212131321430206, -1.093349814414978, -2.678900718688965, 0.4207954406738281, -0.2652113139629364, -1.3707736730575562, 0.03746476396918297, -0.9597068428993225, 0.8683139085769653, -0.6084392070770264, -1.1210410594940186, -1.4711421728134155, 0.24895964562892914, 0.006735139526426792, 0.9902312159538269, -1.604506492614746, -0.17397285997867584, 1.1914445161819458, 0.8709969520568848, -0.7049355506896973, 0.9642133116722107, 0.2078114151954651, 1.0250040292739868, 0.8568227887153625, -0.4181331396102905, 0.6182434558868408, 0.03507668152451515, -1.3783280849456787, 0.4445445239543915, 1.2207696437835693, 0.23791398108005524, 1.5120775699615479, -0.38951700925827026, 0.018091395497322083, 0.42769789695739746, -0.6623564958572388, -0.5585848689079285, -0.41871777176856995, 0.5870958566665649, 0.028583165258169174, -0.9827859401702881, -0.09199051558971405, -0.03534920886158943, -0.31863588094711304, 0.1888469159603119, -1.4407734870910645, -0.1417376548051834, -0.4051297903060913, -0.600477397441864, -1.2937644720077515, -0.12243188917636871, 1.4057859182357788, -0.7638819813728333, -0.16007228195667267, 0.40202417969703674, 0.3811003863811493, 0.51077800989151, 0.6530059576034546, -0.8079514503479004, -0.3516363501548767, -0.2352105975151062, -0.3383120000362396, 0.4119672179222107, 1.3774250745773315, -0.08127759397029877, -0.9346227049827576, 0.6019138693809509, -0.3113865852355957, 0.09594712406396866, 1.8889340162277222, 0.064056895673275, -0.7672309279441833, 0.29870420694351196, -0.7527433037757874, 1.8976861238479614, 1.7361884117126465, 1.2734543085098267, -0.1465306133031845, -0.84157395362854, 0.6844934225082397, -0.4384704530239105, -0.3459400534629822, 0.868216872215271, 0.3207721412181854, -0.2318442314863205, -1.5236824750900269, 0.7911661267280579, 1.3275882005691528, -0.7890422344207764, -0.8569883108139038, 0.15691283345222473, -0.7737320065498352, 1.194298505783081, 0.5839184522628784, 0.32634270191192627, 0.2878434956073761, 1.6030879020690918, 0.8075254559516907, -0.40163421630859375, 0.5591980218887329, 0.5148944854736328, -0.1539243757724762, -2.205169200897217, -1.2601948976516724, 0.3416507840156555, -0.5841649770736694, -1.5605953931808472, 1.4439810514450073, -1.0924017429351807, -1.112066626548767, 0.5980516672134399, 0.08635575324296951, 1.3276584148406982, 0.3924199938774109, 1.5543813705444336, 2.0440750122070312, 0.7962685823440552, 0.43006181716918945, 1.22671639919281, -0.1449178159236908, -0.48397305607795715, 1.7556226253509521, -0.41754817962646484, 0.49532386660575867, 1.1325857639312744, -0.27241015434265137, -1.1654233932495117, -0.8186470866203308, -1.2690367698669434, -0.798886775970459, 1.1543046236038208, 0.08968789130449295, -1.0725897550582886, 0.26485493779182434, 1.6204137802124023, 0.1732502430677414, -0.253827840089798, 0.6367133855819702, 0.4354454278945923, -0.7482894062995911, -0.011351436376571655, -0.8824612498283386, 0.5348762273788452, -0.2903853952884674, -0.37671464681625366, 0.32501861453056335, 0.48895135521888733, 1.3226211071014404, -0.05089137703180313, 0.05348017439246178, 1.0252052545547485, -1.467864990234375, 1.4771651029586792, -0.658483624458313, 0.3264654874801636, -2.357149600982666, 1.3275173902511597, -0.7595835328102112, 2.001539707183838, -2.663938283920288, 0.47669604420661926, -0.549942135810852, -0.49217116832733154, 0.28631314635276794, -0.31725940108299255, 0.09084171056747437, -0.131460040807724, -1.101257562637329, -0.0536457821726799, -0.6570311784744263, 0.6248765587806702, 1.1304302215576172, 1.3858965635299683, -1.1660349369049072, -0.23406395316123962, -1.6564133167266846, -0.034714408218860626, -0.743509829044342, 0.17763105034828186, -1.956472635269165, -0.21818798780441284, -1.9411677122116089, -2.355215311050415, -1.2008016109466553, -0.7569925785064697, 1.1258121728897095, 0.13358688354492188, -0.8405548930168152, 1.3179728984832764, -0.398405522108078, -1.8127456903457642, 1.0479952096939087, -2.151811361312866 ]
https://github.com/huggingface/datasets/issues/5178
Unable to download the Chinese `wikipedia`, the dumpstatus.json not found!
In the dumps page of the wiki (https://dumps.wikimedia.org/zhwiki/), I found the following dumps: ``` Index of /zhwiki/ [../](https://dumps.wikimedia.org/) [20220701/](https://dumps.wikimedia.org/zhwiki/20220701/) 21-Aug-2022 01:48 - [20220720/](https://dumps.wikimedia.org/zhwiki/20220720/) 02-Sep-2022 01:48 - [20220801/](https://dumps.wikimedia.org/zhwiki/20220801/) 21-Sep-2022 01:44 - [20220820/](https://dumps.wikimedia.org/zhwiki/20220820/) 01-Oct-2022 09:39 - [20220901/](https://dumps.wikimedia.org/zhwiki/20220901/) 20-Oct-2022 09:44 - [20220920/](https://dumps.wikimedia.org/zhwiki/20220920/) 23-Sep-2022 12:06 - [20221001/](https://dumps.wikimedia.org/zhwiki/20221001/) 04-Oct-2022 15:10 - [20221020/](https://dumps.wikimedia.org/zhwiki/20221020/) 01-Nov-2022 03:15 - [latest/](https://dumps.wikimedia.org/zhwiki/latest/) 01-Nov-2022 03:15 - ``` Maybe the older dumps are not available which caused the downloading failure? However, when I changed to the newer version: ``` data = load_dataset('wikipedia', '20220701.zh', beam_runner='DirectRunner') ``` it shows: ``` ValueError: BuilderConfig 20220701.zh not found. Available: ['20220301.aa', '20220301.ab', '20220301.ace', '20220301.ady', '20220301.af', '20220301.ak', '20220301.als', '20220301.am', '20220301.an', '20220301.ang', '20220301.ar', '20220301.arc', '20220301.arz', '20220301.as', '20220301.ast', '20220301.atj', '20220301.av', '20220301.ay', '20220301.az', '20220301.azb', '20220301.ba', '20220301.bar', '20220301.bat-smg', '20220301.bcl', '20220301.be', '20220301.be-x-old', '20220301.bg', '20220301.bh', '20220301.bi', '20220301.bjn', '20220301.bm', '20220301.bn', '20220301.bo', '20220301.bpy', '20220301.br', '20220301.bs', '20220301.bug', '20220301.bxr', '20220301.ca', '20220301.cbk-zam', '20220301.cdo', '20220301.ce', '20220301.ceb', '20220301.ch', '20220301.cho', '20220301.chr', '20220301.chy', '20220301.ckb', '20220301.co', '20220301.cr', '20220301.crh', '20220301.cs', '20220301.csb', '20220301.cu', '20220301.cv', '20220301.cy', '20220301.da', '20220301.de', '20220301.din', '20220301.diq', '20220301.dsb', '20220301.dty', '20220301.dv', '20220301.dz', '20220301.ee', '20220301.el', '20220301.eml', '20220301.en', '20220301.eo', '20220301.es', '20220301.et', '20220301.eu', '20220301.ext', '20220301.fa', '20220301.ff', '20220301.fi', '20220301.fiu-vro', '20220301.fj', '20220301.fo', '20220301.fr', '20220301.frp', '20220301.frr', '20220301.fur', '20220301.fy', '20220301.ga', '20220301.gag', '20220301.gan', '20220301.gd', '20220301.gl', '20220301.glk', '20220301.gn', '20220301.gom', '20220301.gor', '20220301.got', '20220301.gu', '20220301.gv', '20220301.ha', '20220301.hak', '20220301.haw', '20220301.he', '20220301.hi', '20220301.hif', '20220301.ho', '20220301.hr', '20220301.hsb', '20220301.ht', '20220301.hu', '20220301.hy', '20220301.ia', '20220301.id', '20220301.ie', '20220301.ig', '20220301.ii', '20220301.ik', '20220301.ilo', '20220301.inh', '20220301.io', '20220301.is', '20220301.it', '20220301.iu', '20220301.ja', '20220301.jam', '20220301.jbo', '20220301.jv', '20220301.ka', '20220301.kaa', '20220301.kab', '20220301.kbd', '20220301.kbp', '20220301.kg', '20220301.ki', '20220301.kj', '20220301.kk', '20220301.kl', '20220301.km', '20220301.kn', '20220301.ko', '20220301.koi', '20220301.krc', '20220301.ks', '20220301.ksh', '20220301.ku', '20220301.kv', '20220301.kw', '20220301.ky', '20220301.la', '20220301.lad', '20220301.lb', '20220301.lbe', '20220301.lez', '20220301.lfn', '20220301.lg', '20220301.li', '20220301.lij', '20220301.lmo', '20220301.ln', '20220301.lo', '20220301.lrc', '20220301.lt', '20220301.ltg', '20220301.lv', '20220301.mai', '20220301.map-bms', '20220301.mdf', '20220301.mg', '20220301.mh', '20220301.mhr', '20220301.mi', '20220301.min', '20220301.mk', '20220301.ml', '20220301.mn', '20220301.mr', '20220301.mrj', '20220301.ms', '20220301.mt', '20220301.mus', '20220301.mwl', '20220301.my', '20220301.myv', '20220301.mzn', '20220301.na', '20220301.nah', '20220301.nap', '20220301.nds', '20220301.nds-nl', '20220301.ne', '20220301.new', '20220301.ng', '20220301.nl', '20220301.nn', '20220301.no', '20220301.nov', '20220301.nrm', '20220301.nso', '20220301.nv', '20220301.ny', '20220301.oc', '20220301.olo', '20220301.om', '20220301.or', '20220301.os', '20220301.pa', '20220301.pag', '20220301.pam', '20220301.pap', '20220301.pcd', '20220301.pdc', '20220301.pfl', '20220301.pi', '20220301.pih', '20220301.pl', '20220301.pms', '20220301.pnb', '20220301.pnt', '20220301.ps', '20220301.pt', '20220301.qu', '20220301.rm', '20220301.rmy', '20220301.rn', '20220301.ro', '20220301.roa-rup', '20220301.roa-tara', '20220301.ru', '20220301.rue', '20220301.rw', '20220301.sa', '20220301.sah', '20220301.sat', '20220301.sc', '20220301.scn', '20220301.sco', '20220301.sd', '20220301.se', '20220301.sg', '20220301.sh', '20220301.si', '20220301.simple', '20220301.sk', '20220301.sl', '20220301.sm', '20220301.sn', '20220301.so', '20220301.sq', '20220301.sr', '20220301.srn', '20220301.ss', '20220301.st', '20220301.stq', '20220301.su', '20220301.sv', '20220301.sw', '20220301.szl', '20220301.ta', '20220301.tcy', '20220301.te', '20220301.tet', '20220301.tg', '20220301.th', '20220301.ti', '20220301.tk', '20220301.tl', '20220301.tn', '20220301.to', '20220301.tpi', '20220301.tr', '20220301.ts', '20220301.tt', '20220301.tum', '20220301.tw', '20220301.ty', '20220301.tyv', '20220301.udm', '20220301.ug', '20220301.uk', '20220301.ur', '20220301.uz', '20220301.ve', '20220301.vec', '20220301.vep', '20220301.vi', '20220301.vls', '20220301.vo', '20220301.wa', '20220301.war', '20220301.wo', '20220301.wuu', '20220301.xal', '20220301.xh', '20220301.xmf', '20220301.yi', '20220301.yo', '20220301.za', '20220301.zea', '20220301.zh', '20220301.zh-classical', '20220301.zh-min-nan', '20220301.zh-yue', '20220301.zu'] ``` So I guess adding the latest dumps versions to the `BuilderConfig` may solve the problem? But how to add it?
### Describe the bug I tried: `data = load_dataset('wikipedia', '20220301.zh', beam_runner='DirectRunner')` and `data = load_dataset("wikipedia", language="zh", date="20220301", beam_runner='DirectRunner')` but both got: `FileNotFoundError: Couldn't find file at https://dumps.wikimedia.org/zhwiki/20220301/dumpstatus.json` the full report is: ``` FileNotFoundError Traceback (most recent call last) <ipython-input-13-d07c5021090c> in <module> 1 from datasets import load_dataset 2 ----> 3 data = load_dataset("wikipedia", language="zh", date="20220301", beam_runner='DirectRunner')<?, ?it/s] /opt/conda/lib/python3.8/site-packages/datasets/load.py in load_dataset(path, name, data_dir, data_files, split, cache_dir, features, download_config, download_mode, ignore_verifications, keep_in_memory, save_infos, revision, use_auth_token, task, streaming, **config_kwargs) 1740 1741 # Download and prepare data -> 1742 builder_instance.download_and_prepare( 1743 download_config=download_config, 1744 download_mode=download_mode, /opt/conda/lib/python3.8/site-packages/datasets/builder.py in download_and_prepare(self, output_dir, download_config, download_mode, ignore_verifications, try_from_hf_gcs, dl_manager, base_path, use_auth_token, file_format, max_shard_size, storage_options, **download_and_prepare_kwargs) 812 **download_and_prepare_kwargs, 813 } --> 814 self._download_and_prepare( 815 dl_manager=dl_manager, 816 verify_infos=verify_infos, /opt/conda/lib/python3.8/site-packages/datasets/builder.py in _download_and_prepare(self, dl_manager, verify_infos, **prepare_splits_kwargs) 1645 options=beam_options, 1646 ) -> 1647 super()._download_and_prepare( 1648 dl_manager, verify_infos=False, pipeline=pipeline, **prepare_splits_kwargs 1649 ) # TODO handle verify_infos in beam datasets /opt/conda/lib/python3.8/site-packages/datasets/builder.py in _download_and_prepare(self, dl_manager, verify_infos, **prepare_split_kwargs) 881 split_dict = SplitDict(dataset_name=self.name) 882 split_generators_kwargs = self._make_split_generators_kwargs(prepare_split_kwargs) --> 883 split_generators = self._split_generators(dl_manager, **split_generators_kwargs) 884 885 # Checksums verification ~/.cache/huggingface/modules/datasets_modules/datasets/wikipedia/aa542ed919df55cc5d3347f42dd4521d05ca68751f50dbc32bae2a7f1e167559/wikipedia.py in _split_generators(self, dl_manager, pipeline) 943 info_url = _base_url(lang) + _INFO_FILE 944 # Use dictionary since testing mock always returns the same result. --> 945 downloaded_files = dl_manager.download_and_extract({"info": info_url}) 946 947 xml_urls = [] /opt/conda/lib/python3.8/site-packages/datasets/download/download_manager.py in download_and_extract(self, url_or_urls) 431 extracted_path(s): `str`, extracted paths of given URL(s). 432 """ --> 433 return self.extract(self.download(url_or_urls)) 434 435 def get_recorded_sizes_checksums(self): /opt/conda/lib/python3.8/site-packages/datasets/download/download_manager.py in download(self, url_or_urls) 308 309 start_time = datetime.now() --> 310 downloaded_path_or_paths = map_nested( 311 download_func, 312 url_or_urls, /opt/conda/lib/python3.8/site-packages/datasets/utils/py_utils.py in map_nested(function, data_struct, dict_only, map_list, map_tuple, map_numpy, num_proc, parallel_min_length, types, disable_tqdm, desc) 427 num_proc = 1 428 if num_proc <= 1 or len(iterable) < parallel_min_length: --> 429 mapped = [ 430 _single_map_nested((function, obj, types, None, True, None)) 431 for obj in logging.tqdm(iterable, disable=disable_tqdm, desc=desc) /opt/conda/lib/python3.8/site-packages/datasets/utils/py_utils.py in <listcomp>(.0) 428 if num_proc <= 1 or len(iterable) < parallel_min_length: 429 mapped = [ --> 430 _single_map_nested((function, obj, types, None, True, None)) 431 for obj in logging.tqdm(iterable, disable=disable_tqdm, desc=desc) 432 ] /opt/conda/lib/python3.8/site-packages/datasets/utils/py_utils.py in _single_map_nested(args) 329 # Singleton first to spare some computation 330 if not isinstance(data_struct, dict) and not isinstance(data_struct, types): --> 331 return function(data_struct) 332 333 # Reduce logging to keep things readable in multiprocessing with tqdm /opt/conda/lib/python3.8/site-packages/datasets/download/download_manager.py in _download(self, url_or_filename, download_config) 335 # append the relative path to the base_path 336 url_or_filename = url_or_path_join(self._base_path, url_or_filename) --> 337 return cached_path(url_or_filename, download_config=download_config) 338 339 def iter_archive(self, path_or_buf: Union[str, io.BufferedReader]): /opt/conda/lib/python3.8/site-packages/datasets/utils/file_utils.py in cached_path(url_or_filename, download_config, **download_kwargs) 186 if is_remote_url(url_or_filename): 187 # URL, so get it from the cache (downloading if necessary) --> 188 output_path = get_from_cache( 189 url_or_filename, 190 cache_dir=cache_dir, /opt/conda/lib/python3.8/site-packages/datasets/utils/file_utils.py in get_from_cache(url, cache_dir, force_download, proxies, etag_timeout, resume_download, user_agent, local_files_only, use_etag, max_retries, use_auth_token, ignore_url_params, download_desc) 533 ) 534 elif response is not None and response.status_code == 404: --> 535 raise FileNotFoundError(f"Couldn't find file at {url}") 536 _raise_if_offline_mode_is_enabled(f"Tried to reach {url}") 537 if head_error is not None: FileNotFoundError: Couldn't find file at https://dumps.wikimedia.org/zhwiki/20220301/dumpstatus.json ``` ### Steps to reproduce the bug `data = load_dataset('wikipedia', '20220301.zh', beam_runner='DirectRunner')` ### Expected behavior download the data ### Environment info python3.6 latest datasets/transformers version
451
412
Unable to download the Chinese `wikipedia`, the dumpstatus.json not found! ### Describe the bug I tried: `data = load_dataset('wikipedia', '20220301.zh', beam_runner='DirectRunner')` and `data = load_dataset("wikipedia", language="zh", date="20220301", beam_runner='DirectRunner')` but both got: `FileNotFoundError: Couldn't find file at https://dumps.wikimedia.org/zhwiki/20220301/dumpstatus.json` the full report is: ``` FileNotFoundError Traceback (most recent call last) <ipython-input-13-d07c5021090c> in <module> 1 from datasets import load_dataset 2 ----> 3 data = load_dataset("wikipedia", language="zh", date="20220301", beam_runner='DirectRunner')<?, ?it/s] /opt/conda/lib/python3.8/site-packages/datasets/load.py in load_dataset(path, name, data_dir, data_files, split, cache_dir, features, download_config, download_mode, ignore_verifications, keep_in_memory, save_infos, revision, use_auth_token, task, streaming, **config_kwargs) 1740 1741 # Download and prepare data -> 1742 builder_instance.download_and_prepare( 1743 download_config=download_config, 1744 download_mode=download_mode, /opt/conda/lib/python3.8/site-packages/datasets/builder.py in download_and_prepare(self, output_dir, download_config, download_mode, ignore_verifications, try_from_hf_gcs, dl_manager, base_path, use_auth_token, file_format, max_shard_size, storage_options, **download_and_prepare_kwargs) 812 **download_and_prepare_kwargs, 813 } --> 814 self._download_and_prepare( 815 dl_manager=dl_manager, 816 verify_infos=verify_infos, /opt/conda/lib/python3.8/site-packages/datasets/builder.py in _download_and_prepare(self, dl_manager, verify_infos, **prepare_splits_kwargs) 1645 options=beam_options, 1646 ) -> 1647 super()._download_and_prepare( 1648 dl_manager, verify_infos=False, pipeline=pipeline, **prepare_splits_kwargs 1649 ) # TODO handle verify_infos in beam datasets /opt/conda/lib/python3.8/site-packages/datasets/builder.py in _download_and_prepare(self, dl_manager, verify_infos, **prepare_split_kwargs) 881 split_dict = SplitDict(dataset_name=self.name) 882 split_generators_kwargs = self._make_split_generators_kwargs(prepare_split_kwargs) --> 883 split_generators = self._split_generators(dl_manager, **split_generators_kwargs) 884 885 # Checksums verification ~/.cache/huggingface/modules/datasets_modules/datasets/wikipedia/aa542ed919df55cc5d3347f42dd4521d05ca68751f50dbc32bae2a7f1e167559/wikipedia.py in _split_generators(self, dl_manager, pipeline) 943 info_url = _base_url(lang) + _INFO_FILE 944 # Use dictionary since testing mock always returns the same result. --> 945 downloaded_files = dl_manager.download_and_extract({"info": info_url}) 946 947 xml_urls = [] /opt/conda/lib/python3.8/site-packages/datasets/download/download_manager.py in download_and_extract(self, url_or_urls) 431 extracted_path(s): `str`, extracted paths of given URL(s). 432 """ --> 433 return self.extract(self.download(url_or_urls)) 434 435 def get_recorded_sizes_checksums(self): /opt/conda/lib/python3.8/site-packages/datasets/download/download_manager.py in download(self, url_or_urls) 308 309 start_time = datetime.now() --> 310 downloaded_path_or_paths = map_nested( 311 download_func, 312 url_or_urls, /opt/conda/lib/python3.8/site-packages/datasets/utils/py_utils.py in map_nested(function, data_struct, dict_only, map_list, map_tuple, map_numpy, num_proc, parallel_min_length, types, disable_tqdm, desc) 427 num_proc = 1 428 if num_proc <= 1 or len(iterable) < parallel_min_length: --> 429 mapped = [ 430 _single_map_nested((function, obj, types, None, True, None)) 431 for obj in logging.tqdm(iterable, disable=disable_tqdm, desc=desc) /opt/conda/lib/python3.8/site-packages/datasets/utils/py_utils.py in <listcomp>(.0) 428 if num_proc <= 1 or len(iterable) < parallel_min_length: 429 mapped = [ --> 430 _single_map_nested((function, obj, types, None, True, None)) 431 for obj in logging.tqdm(iterable, disable=disable_tqdm, desc=desc) 432 ] /opt/conda/lib/python3.8/site-packages/datasets/utils/py_utils.py in _single_map_nested(args) 329 # Singleton first to spare some computation 330 if not isinstance(data_struct, dict) and not isinstance(data_struct, types): --> 331 return function(data_struct) 332 333 # Reduce logging to keep things readable in multiprocessing with tqdm /opt/conda/lib/python3.8/site-packages/datasets/download/download_manager.py in _download(self, url_or_filename, download_config) 335 # append the relative path to the base_path 336 url_or_filename = url_or_path_join(self._base_path, url_or_filename) --> 337 return cached_path(url_or_filename, download_config=download_config) 338 339 def iter_archive(self, path_or_buf: Union[str, io.BufferedReader]): /opt/conda/lib/python3.8/site-packages/datasets/utils/file_utils.py in cached_path(url_or_filename, download_config, **download_kwargs) 186 if is_remote_url(url_or_filename): 187 # URL, so get it from the cache (downloading if necessary) --> 188 output_path = get_from_cache( 189 url_or_filename, 190 cache_dir=cache_dir, /opt/conda/lib/python3.8/site-packages/datasets/utils/file_utils.py in get_from_cache(url, cache_dir, force_download, proxies, etag_timeout, resume_download, user_agent, local_files_only, use_etag, max_retries, use_auth_token, ignore_url_params, download_desc) 533 ) 534 elif response is not None and response.status_code == 404: --> 535 raise FileNotFoundError(f"Couldn't find file at {url}") 536 _raise_if_offline_mode_is_enabled(f"Tried to reach {url}") 537 if head_error is not None: FileNotFoundError: Couldn't find file at https://dumps.wikimedia.org/zhwiki/20220301/dumpstatus.json ``` ### Steps to reproduce the bug `data = load_dataset('wikipedia', '20220301.zh', beam_runner='DirectRunner')` ### Expected behavior download the data ### Environment info python3.6 latest datasets/transformers version In the dumps page of the wiki (https://dumps.wikimedia.org/zhwiki/), I found the following dumps: ``` Index of /zhwiki/ [../](https://dumps.wikimedia.org/) [20220701/](https://dumps.wikimedia.org/zhwiki/20220701/) 21-Aug-2022 01:48 - [20220720/](https://dumps.wikimedia.org/zhwiki/20220720/) 02-Sep-2022 01:48 - [20220801/](https://dumps.wikimedia.org/zhwiki/20220801/) 21-Sep-2022 01:44 - [20220820/](https://dumps.wikimedia.org/zhwiki/20220820/) 01-Oct-2022 09:39 - [20220901/](https://dumps.wikimedia.org/zhwiki/20220901/) 20-Oct-2022 09:44 - [20220920/](https://dumps.wikimedia.org/zhwiki/20220920/) 23-Sep-2022 12:06 - [20221001/](https://dumps.wikimedia.org/zhwiki/20221001/) 04-Oct-2022 15:10 - [20221020/](https://dumps.wikimedia.org/zhwiki/20221020/) 01-Nov-2022 03:15 - [latest/](https://dumps.wikimedia.org/zhwiki/latest/) 01-Nov-2022 03:15 - ``` Maybe the older dumps are not available which caused the downloading failure? However, when I changed to the newer version: ``` data = load_dataset('wikipedia', '20220701.zh', beam_runner='DirectRunner') ``` it shows: ``` ValueError: BuilderConfig 20220701.zh not found. Available: ['20220301.aa', '20220301.ab', '20220301.ace', '20220301.ady', '20220301.af', '20220301.ak', '20220301.als', '20220301.am', '20220301.an', '20220301.ang', '20220301.ar', '20220301.arc', '20220301.arz', '20220301.as', '20220301.ast', '20220301.atj', '20220301.av', '20220301.ay', '20220301.az', '20220301.azb', '20220301.ba', '20220301.bar', '20220301.bat-smg', '20220301.bcl', '20220301.be', '20220301.be-x-old', '20220301.bg', '20220301.bh', '20220301.bi', '20220301.bjn', '20220301.bm', '20220301.bn', '20220301.bo', '20220301.bpy', '20220301.br', '20220301.bs', '20220301.bug', '20220301.bxr', '20220301.ca', '20220301.cbk-zam', '20220301.cdo', '20220301.ce', '20220301.ceb', '20220301.ch', '20220301.cho', '20220301.chr', '20220301.chy', '20220301.ckb', '20220301.co', '20220301.cr', '20220301.crh', '20220301.cs', '20220301.csb', '20220301.cu', '20220301.cv', '20220301.cy', '20220301.da', '20220301.de', '20220301.din', '20220301.diq', '20220301.dsb', '20220301.dty', '20220301.dv', '20220301.dz', '20220301.ee', '20220301.el', '20220301.eml', '20220301.en', '20220301.eo', '20220301.es', '20220301.et', '20220301.eu', '20220301.ext', '20220301.fa', '20220301.ff', '20220301.fi', '20220301.fiu-vro', '20220301.fj', '20220301.fo', '20220301.fr', '20220301.frp', '20220301.frr', '20220301.fur', '20220301.fy', '20220301.ga', '20220301.gag', '20220301.gan', '20220301.gd', '20220301.gl', '20220301.glk', '20220301.gn', '20220301.gom', '20220301.gor', '20220301.got', '20220301.gu', '20220301.gv', '20220301.ha', '20220301.hak', '20220301.haw', '20220301.he', '20220301.hi', '20220301.hif', '20220301.ho', '20220301.hr', '20220301.hsb', '20220301.ht', '20220301.hu', '20220301.hy', '20220301.ia', '20220301.id', '20220301.ie', '20220301.ig', '20220301.ii', '20220301.ik', '20220301.ilo', '20220301.inh', '20220301.io', '20220301.is', '20220301.it', '20220301.iu', '20220301.ja', '20220301.jam', '20220301.jbo', '20220301.jv', '20220301.ka', '20220301.kaa', '20220301.kab', '20220301.kbd', '20220301.kbp', '20220301.kg', '20220301.ki', '20220301.kj', '20220301.kk', '20220301.kl', '20220301.km', '20220301.kn', '20220301.ko', '20220301.koi', '20220301.krc', '20220301.ks', '20220301.ksh', '20220301.ku', '20220301.kv', '20220301.kw', '20220301.ky', '20220301.la', '20220301.lad', '20220301.lb', '20220301.lbe', '20220301.lez', '20220301.lfn', '20220301.lg', '20220301.li', '20220301.lij', '20220301.lmo', '20220301.ln', '20220301.lo', '20220301.lrc', '20220301.lt', '20220301.ltg', '20220301.lv', '20220301.mai', '20220301.map-bms', '20220301.mdf', '20220301.mg', '20220301.mh', '20220301.mhr', '20220301.mi', '20220301.min', '20220301.mk', '20220301.ml', '20220301.mn', '20220301.mr', '20220301.mrj', '20220301.ms', '20220301.mt', '20220301.mus', '20220301.mwl', '20220301.my', '20220301.myv', '20220301.mzn', '20220301.na', '20220301.nah', '20220301.nap', '20220301.nds', '20220301.nds-nl', '20220301.ne', '20220301.new', '20220301.ng', '20220301.nl', '20220301.nn', '20220301.no', '20220301.nov', '20220301.nrm', '20220301.nso', '20220301.nv', '20220301.ny', '20220301.oc', '20220301.olo', '20220301.om', '20220301.or', '20220301.os', '20220301.pa', '20220301.pag', '20220301.pam', '20220301.pap', '20220301.pcd', '20220301.pdc', '20220301.pfl', '20220301.pi', '20220301.pih', '20220301.pl', '20220301.pms', '20220301.pnb', '20220301.pnt', '20220301.ps', '20220301.pt', '20220301.qu', '20220301.rm', '20220301.rmy', '20220301.rn', '20220301.ro', '20220301.roa-rup', '20220301.roa-tara', '20220301.ru', '20220301.rue', '20220301.rw', '20220301.sa', '20220301.sah', '20220301.sat', '20220301.sc', '20220301.scn', '20220301.sco', '20220301.sd', '20220301.se', '20220301.sg', '20220301.sh', '20220301.si', '20220301.simple', '20220301.sk', '20220301.sl', '20220301.sm', '20220301.sn', '20220301.so', '20220301.sq', '20220301.sr', '20220301.srn', '20220301.ss', '20220301.st', '20220301.stq', '20220301.su', '20220301.sv', '20220301.sw', '20220301.szl', '20220301.ta', '20220301.tcy', '20220301.te', '20220301.tet', '20220301.tg', '20220301.th', '20220301.ti', '20220301.tk', '20220301.tl', '20220301.tn', '20220301.to', '20220301.tpi', '20220301.tr', '20220301.ts', '20220301.tt', '20220301.tum', '20220301.tw', '20220301.ty', '20220301.tyv', '20220301.udm', '20220301.ug', '20220301.uk', '20220301.ur', '20220301.uz', '20220301.ve', '20220301.vec', '20220301.vep', '20220301.vi', '20220301.vls', '20220301.vo', '20220301.wa', '20220301.war', '20220301.wo', '20220301.wuu', '20220301.xal', '20220301.xh', '20220301.xmf', '20220301.yi', '20220301.yo', '20220301.za', '20220301.zea', '20220301.zh', '20220301.zh-classical', '20220301.zh-min-nan', '20220301.zh-yue', '20220301.zu'] ``` So I guess adding the latest dumps versions to the `BuilderConfig` may solve the problem? But how to add it?
[ -1.2170014381408691, -0.9683899283409119, -0.5608522891998291, 1.4416203498840332, -0.1440241038799286, -1.2146953344345093, 0.21109837293624878, -1.0700407028198242, 1.5621782541275024, -0.8050041198730469, 0.17415069043636322, -1.646943211555481, -0.07499374449253082, -0.6673901677131653, -0.698634684085846, -0.8470911979675293, -0.35006585717201233, -0.8368162512779236, 1.1412231922149658, 2.380309581756592, 1.2196933031082153, -1.4163579940795898, 2.7417874336242676, 0.6633369326591492, -0.23040145635604858, -1.0188965797424316, 0.501268744468689, 0.012220094911754131, -1.1495826244354248, -0.4889415502548218, -0.9659383296966553, -0.08957697451114655, -0.6564934849739075, -0.27322545647621155, -0.07793689519166946, 0.5286354422569275, -0.2828669548034668, -0.3241702914237976, -0.5456913113594055, -0.7878347039222717, 0.5341796278953552, -0.36390984058380127, 0.9367288947105408, -0.2940966784954071, 1.7430444955825806, -0.5860297083854675, 0.4656287729740143, 0.7571712732315063, 1.1900978088378906, 0.16286368668079376, 0.019353650510311127, 0.200439915060997, 0.3252803385257721, -0.04754190519452095, 0.5969112515449524, 1.1658589839935303, 0.657002866268158, 0.5535026788711548, 0.6542642712593079, -2.2177886962890625, 1.3346971273422241, -1.0343025922775269, 0.3304782211780548, 1.4057916402816772, -0.8765290379524231, 0.359151154756546, -1.7557532787322998, -0.058119598776102066, 0.6481783390045166, -2.1933038234710693, 0.40502938628196716, -1.3102895021438599, -0.5210937857627869, 0.8887270092964172, 0.4179205000400543, -1.221529483795166, 0.1517130434513092, -0.4479084610939026, 1.1475095748901367, 0.3964335322380066, 0.9234474301338196, -1.7467167377471924, -0.020484985783696175, -0.16183368861675262, 0.15411970019340515, -1.2843225002288818, -1.661791443824768, 0.5685978531837463, 0.5246251821517944, 0.6904571056365967, -0.18104539811611176, 1.0798536539077759, -1.1522400379180908, 0.7803519368171692, -1.1722726821899414, -1.54086434841156, -1.358656883239746, -2.422412872314453, -2.3394768238067627, 0.7157904505729675, -0.5086732506752014, -0.5012471079826355, 2.130084276199341, -0.9287640452384949, -1.6577832698822021, 1.1695671081542969, 0.22574955224990845, 0.030104633420705795, 2.3914449214935303, 0.20189954340457916, -0.7385568618774414, 0.5369505286216736, -0.8691916465759277, 0.8071199655532837, -0.31477051973342896, 1.3405535221099854, 0.4891539514064789, -1.0191351175308228, 1.509261965751648, -0.4526011645793915, 0.5842145085334778, -0.5968116521835327, -0.541476845741272, -0.754551887512207, 0.239410862326622, 1.818123698234558, -0.1541256457567215, 1.4538711309432983, -0.279835045337677, -1.5517957210540771, -1.5958083868026733, 1.0371630191802979, 0.350869357585907, -0.9378894567489624, 0.13891978561878204, -0.4555055499076843, 0.22229351103305817, -0.08357372134923935, 1.156264305114746, 1.3059521913528442, 0.7350850701332092, -0.3893837332725525, -0.7287031412124634, 0.09019298106431961, -0.2681887745857239, -0.6702597141265869, -1.827178955078125, -0.2600456774234772, 0.03189661726355553, 0.6513438820838928, -1.1375479698181152, 1.878173828125, 0.9382094740867615, 1.9108741283416748, 0.8873557448387146, -0.4488866329193115, 1.4291075468063354, 0.0425947830080986, 1.8661445379257202, -0.6110694408416748, 0.6401342153549194, -0.42213597893714905, -1.1190975904464722, 1.0016587972640991, -0.31376150250434875, -1.9290226697921753, -0.8085372447967529, -0.7683132290840149, -0.22048398852348328, -0.8074562549591064, 0.8433467149734497, -0.25652387738227844, -1.560677409172058, 0.1819024384021759, -0.6673984527587891, 0.2806224524974823, -1.1621015071868896, 0.3294593095779419, 0.7073994874954224, -0.6532617211341858, -0.050659481436014175, -0.17230486869812012, -1.2645000219345093, -0.46781498193740845, 0.4709959328174591, 1.8939436674118042, -0.5660892724990845, 0.8890480995178223, 1.072402000427246, -0.7024014592170715, 0.06341098994016647, 0.25059518218040466, -0.21641218662261963, 0.695263683795929, -1.0395960807800293, -0.5356206297874451, 1.2094756364822388, -0.41201725602149963, -0.6235672831535339, 1.4571666717529297, 0.7134835720062256, -1.1371079683303833, -0.15421031415462494, -0.2110143005847931, -0.8309813737869263, 0.02465224638581276, -1.487969994544983, -0.09829878062009811, 0.5986323952674866, -1.5024986267089844, -0.35740306973457336, -0.172239750623703, 1.3511487245559692, -0.17959894239902496, 1.430333137512207, -0.37571120262145996, -0.0580558218061924, -0.2701750695705414, -0.46856358647346497, 0.2430909126996994, -0.24432943761348724, -0.44457104802131653, 0.054845888167619705, -0.7970159649848938, 0.3180781900882721, 1.508079171180725, 0.21045303344726562, -0.0019034557044506073, 0.3735906779766083, 1.082767367362976, 0.4175396263599396, 0.0024299900978803635, -0.9098672866821289, -1.4250798225402832, 1.8859914541244507, -1.540601372718811, 1.9672565460205078, 0.7408435940742493, -0.08062721788883209, -1.7460697889328003, -1.7993675470352173, 1.293761968612671, 1.0989381074905396, 2.3081729412078857, 0.46779292821884155, 0.3701840937137604, -0.851073682308197, -0.6825761795043945, 0.3060929775238037, -1.0134387016296387, -0.5825333595275879, 0.196160688996315, 2.41171932220459, 1.8015971183776855, -0.44993528723716736, -0.26312771439552307, -0.8733410239219666, 1.4141523838043213, -0.2940051257610321, 0.2762720584869385, 2.146360397338867, -0.34383851289749146, -1.0486966371536255, 1.3723459243774414, -2.4992480278015137, 0.262148916721344, 2.1008694171905518, 0.3361589014530182, 0.19903534650802612, -1.3560481071472168, -0.6228715181350708, -0.34945249557495117, -0.5175646543502808, -1.2474452257156372, 0.5635823011398315, -0.23242801427841187, -0.7024191617965698, -1.4108389616012573, 0.21011096239089966, -1.1210620403289795, -1.7740126848220825, 0.28346139192581177, 1.919077754020691, 2.1673221588134766, -0.842538595199585, 1.478548526763916, -0.31165722012519836, 0.1001129299402237, 1.2399498224258423, 1.3029555082321167, 3.0731348991394043, 1.8347619771957397, -1.2912744283676147, 0.637525737285614, -0.24080081284046173, -0.5345274209976196, 1.12699294090271, -1.146532416343689, 1.2297435998916626, -0.16546837985515594, -1.1698614358901978, -1.2982354164123535, 1.0163917541503906, 0.450277715921402, 0.0838286355137825, -0.5365099906921387, 1.2165857553482056, 0.1779680848121643, 1.3884118795394897, 0.6263922452926636, -0.40945637226104736, 0.48375266790390015, -0.431661993265152, -0.606079638004303, 1.6260478496551514, 0.25985580682754517, -1.544480323791504, -2.264434337615967, -0.3104991912841797, -0.9340025186538696, 0.09693276137113571, -0.6429155468940735, -1.02992844581604, 1.5748367309570312, 0.37800729274749756, -1.1707088947296143, -0.27575168013572693, -0.2745736241340637, -0.5225574970245361, 2.696237087249756, -1.2222782373428345, -0.13263176381587982, -0.9383622407913208, -0.7015168070793152, 1.6360279321670532, -1.2732577323913574, -0.27571070194244385, -1.0673469305038452, -0.6340727210044861, -1.2339082956314087, -0.3848574161529541, 0.06020070239901543, -1.0515685081481934, 0.8193007707595825, 0.26414135098457336, -1.2780214548110962, -0.372059166431427, -0.8718441128730774, 1.070177435874939, -0.11585889011621475, 0.22785641252994537, 1.7039953470230103, 0.2080129086971283, -0.45733511447906494, 0.8459241390228271, 1.209050178527832, 0.6364569664001465, -0.636812150478363, -0.015720395371317863, -0.6464300155639648, 0.4495864808559418, -1.2726433277130127, 0.2385275810956955, -3.024547815322876, 0.6282491683959961, -0.13449279963970184, -0.12116333097219467, -0.10977765917778015, -1.4193363189697266, 1.105175256729126, 2.4960741996765137, -1.1656547784805298, 0.5616940259933472, 0.44614991545677185, 1.2368656396865845, -1.6130276918411255, 0.2853536605834961, -0.48787423968315125, 2.0665886402130127, 0.15769782662391663, 1.2496864795684814, -0.46011292934417725, -2.37412166595459, 0.6117936372756958, -1.2979633808135986, -1.0852065086364746, 0.8027737140655518, -0.8944094777107239, 0.2864745557308197, -1.4088984727859497, -0.26090335845947266, -0.8898468017578125, -1.2489744424819946, 0.664065420627594, 0.13157249987125397, 0.378083199262619, -0.5866467356681824, 0.31549495458602905, -2.1821129322052, -1.3760285377502441, -0.21103531122207642, -0.9226536750793457, 0.5623751282691956, -0.5101042985916138, 0.5642646551132202, -0.12185706198215485, 0.05777108296751976, 0.31627920269966125, 1.6136058568954468, 3.380206823348999, 0.1136578842997551, 0.26071202754974365, -0.16145943105220795, -0.961010217666626, 1.4653918743133545, 0.8998140096664429, -0.10252530872821808, -0.6017000079154968, -1.0557900667190552, 1.3346889019012451, 1.9546042680740356, 0.9796127676963806, -0.005805733613669872, -0.7704516053199768, -0.6538062691688538, -0.07622605562210083, 0.20413696765899658, 0.5462398529052734, 0.9291355013847351, 0.028791993856430054, 0.03794340044260025, 1.3702205419540405, 1.1289827823638916, -0.3221348226070404, 0.3207196593284607, -0.9244656562805176, -0.4059849679470062, 0.45150771737098694, 0.14583609998226166, -0.041328366845846176, 0.4921247065067291, -0.9579594135284424, -0.3088337779045105, -0.29882967472076416, -0.7924419045448303, -0.7197058200836182, -0.4069828391075134, -0.4533673822879791, 1.5916215181350708, 0.1671016812324524, -0.5351323485374451, 0.09591097384691238, -0.64225834608078, -0.20749258995056152, -1.166085124015808, 0.111827552318573, -0.08475694060325623, -0.16535694897174835, -0.21750612556934357, 1.6943265199661255, -0.9106370806694031, -2.060784339904785, 0.112681083381176, 0.35035601258277893, -0.15534742176532745, 0.1796565055847168, 1.7510414123535156, 0.4609483480453491, 1.4435005187988281, 1.258790135383606, 1.0026617050170898, -0.5963815450668335, -1.2956180572509766, 0.8488948941230774, 0.9791117310523987, -1.3631834983825684, 0.866409957408905, -0.1236843541264534, -0.4979773759841919, 0.7001219987869263, 1.2514941692352295, 0.4436571002006531, -1.9929531812667847, 0.8583927154541016, -1.146759271621704, 0.923383891582489, 0.7105684280395508, 0.6595831513404846, 0.2826668322086334, 0.860019326210022, -1.1870485544204712, -1.0909959077835083, -0.6722009778022766, -0.7562681436538696, 2.034639835357666, -0.37319400906562805, 0.5826557874679565, -0.1488100290298462, -1.1538892984390259, -0.10148066282272339, 0.8104291558265686, 0.4080570340156555, -0.42944827675819397, 0.7323336005210876, -0.6571613550186157, -1.0025581121444702, -1.1971629858016968, -0.3766745626926422, -1.1324542760849, -0.9182586669921875, 1.0327980518341064, 0.7393785119056702, 0.4100472927093506, 1.922598958015442, 0.6615173816680908, 0.4013250470161438, -2.5430922508239746, 0.9066964983940125, 0.28707805275917053, -0.1253030151128769, 0.8327445387840271, 0.4110954999923706, 1.1394646167755127, 0.03169175982475281, 0.5966501235961914, -2.4829251766204834, 2.294358968734741, -0.18197566270828247, 0.6231374740600586, 0.02558591216802597, -0.13844144344329834, 1.174985647201538, 0.6353755593299866, 0.35830825567245483, -1.03628671169281, 0.6640870571136475, -0.49978113174438477, 1.1638071537017822, 0.924072265625, -0.855826199054718, 0.04508421942591667, 1.4000383615493774, 0.44983023405075073, -0.5593210458755493, -1.023922324180603, -0.9196360111236572, 0.9656379222869873, 1.601950764656067, -0.1593981832265854, -0.07576262205839157, 0.7072905898094177, 0.6801508665084839, -1.1495915651321411, 0.07477367669343948, -0.5728888511657715, -0.7233093976974487, 1.692077398300171, 2.104736328125, -0.22725799679756165, -0.12874984741210938, -0.7556700706481934, -1.3494372367858887, 0.8081915974617004, -0.11244066059589386, 0.015592117793858051, 0.5690181255340576, -0.5994241833686829, 0.9457734227180481, 0.6448037028312683, 0.9118123054504395, 0.15812146663665771, 0.27638137340545654, 0.47165894508361816, -0.3941633403301239, -1.1330960988998413, -0.3037711977958679, -1.2069180011749268, -2.6697609424591064, 0.34435221552848816, -0.2508181631565094, -1.3857330083847046, 0.024846047163009644, -1.043538212776184, 0.9420125484466553, -0.5942971110343933, -1.183124303817749, -1.473703384399414, 0.3455038368701935, -0.03765144199132919, 0.9741702079772949, -1.6550544500350952, -0.20296348631381989, 1.162786602973938, 0.7588387131690979, -0.7139344811439514, 0.9930270314216614, 0.2301415354013443, 1.0172510147094727, 0.7267889976501465, -0.4096280038356781, 0.722879946231842, 0.016143444925546646, -1.3864203691482544, 0.4798646569252014, 1.2999470233917236, 0.13147525489330292, 1.4166793823242188, -0.4093073308467865, 0.028207633644342422, 0.4101737439632416, -0.6614828109741211, -0.6179669499397278, -0.3092504143714905, 0.61649489402771, 0.03138669580221176, -0.9605509638786316, -0.0880957618355751, -0.08301261812448502, -0.4407540261745453, 0.21981756389141083, -1.4779911041259766, -0.2701922357082367, -0.4885001480579376, -0.4397026300430298, -1.4035513401031494, -0.09345357120037079, 1.3823351860046387, -0.6136641502380371, -0.2607633173465729, 0.48287731409072876, 0.34330618381500244, 0.4977618157863617, 0.6245275139808655, -0.7047929167747498, -0.2206849604845047, -0.31124016642570496, -0.30941706895828247, 0.38961875438690186, 1.3733452558517456, -0.07292836159467697, -0.9359123706817627, 0.6043532490730286, -0.29037368297576904, 0.21843069791793823, 1.9131218194961548, 0.05746011808514595, -0.7420433759689331, 0.3667701482772827, -0.739910364151001, 1.870839238166809, 1.739117980003357, 1.1646950244903564, -0.14208683371543884, -0.8149221539497375, 0.5925320982933044, -0.3625938892364502, -0.3713972568511963, 0.8268902897834778, 0.327970415353775, -0.30247119069099426, -1.4257985353469849, 0.817221462726593, 1.2165766954421997, -0.7083972692489624, -0.8205990791320801, 0.15322424471378326, -0.8102108240127563, 1.2214288711547852, 0.49646177887916565, 0.4289621114730835, 0.2867667078971863, 1.6273289918899536, 0.8508263826370239, -0.4778187870979309, 0.6282122135162354, 0.5028642416000366, -0.20096319913864136, -2.136291265487671, -1.2338007688522339, 0.2510344386100769, -0.6172120571136475, -1.5574766397476196, 1.4210950136184692, -1.002721905708313, -1.054930567741394, 0.6148954629898071, 0.04684268310666084, 1.2750838994979858, 0.425082802772522, 1.5455282926559448, 2.093168258666992, 0.8298642039299011, 0.5490590929985046, 1.2001304626464844, -0.2265365719795227, -0.47244083881378174, 1.8992531299591064, -0.36517012119293213, 0.4507097601890564, 1.1439728736877441, -0.316078782081604, -1.0779838562011719, -0.8175809979438782, -1.2080016136169434, -0.6967859268188477, 1.1208946704864502, 0.08701435476541519, -1.0667985677719116, 0.28405702114105225, 1.6269704103469849, 0.11976712197065353, -0.22628790140151978, 0.6912527680397034, 0.3561188578605652, -0.7939194440841675, -0.07375819236040115, -0.8984496593475342, 0.5331429243087769, -0.3125242292881012, -0.3233226239681244, 0.3225749135017395, 0.5433096885681152, 1.295554280281067, -0.10036730766296387, 0.19405411183834076, 0.9723783135414124, -1.4329570531845093, 1.4417223930358887, -0.5906931757926941, 0.33708253502845764, -2.3168203830718994, 1.2830235958099365, -0.6814137697219849, 2.0614349842071533, -2.6394622325897217, 0.39431673288345337, -0.5553480386734009, -0.5731869339942932, 0.27154409885406494, -0.3612765371799469, 0.09517797082662582, -0.0986931174993515, -1.0936061143875122, 0.05481443926692009, -0.6018697619438171, 0.5871978998184204, 1.1391236782073975, 1.4432947635650635, -1.0556639432907104, -0.22669000923633575, -1.644964337348938, -0.08113828301429749, -0.7896649837493896, 0.21823126077651978, -1.9583266973495483, -0.15668334066867828, -1.965868353843689, -2.2251174449920654, -1.2741742134094238, -0.9023155570030212, 1.1391862630844116, 0.1258905977010727, -0.9208382368087769, 1.3752732276916504, -0.28702208399772644, -1.7495067119598389, 1.0958558320999146, -2.1503026485443115 ]
https://github.com/huggingface/datasets/issues/5178
Unable to download the Chinese `wikipedia`, the dumpstatus.json not found!
Hi, @beyondguo, thanks for reporting. You have all the information in the dataset card: https://huggingface.co/datasets/wikipedia > Then, you can load any subset of Wikipedia per language and per date this way: > ```python > from datasets import load_dataset > > load_dataset("wikipedia", language="sw", date="20220120", beam_runner=...) > ``` > where you can pass as beam_runner any Apache Beam supported runner for (distributed) data processing (see [here](https://beam.apache.org/documentation/runners/capability-matrix/)). Pass "DirectRunner" to run it on your machine. > > You can find the full list of languages and dates [here](https://dumps.wikimedia.org/backup-index.html). Note that you have to pass the language and date as keyword arguments, and the available dates depend on the language and can be found on Wikimedia website.
### Describe the bug I tried: `data = load_dataset('wikipedia', '20220301.zh', beam_runner='DirectRunner')` and `data = load_dataset("wikipedia", language="zh", date="20220301", beam_runner='DirectRunner')` but both got: `FileNotFoundError: Couldn't find file at https://dumps.wikimedia.org/zhwiki/20220301/dumpstatus.json` the full report is: ``` FileNotFoundError Traceback (most recent call last) <ipython-input-13-d07c5021090c> in <module> 1 from datasets import load_dataset 2 ----> 3 data = load_dataset("wikipedia", language="zh", date="20220301", beam_runner='DirectRunner')<?, ?it/s] /opt/conda/lib/python3.8/site-packages/datasets/load.py in load_dataset(path, name, data_dir, data_files, split, cache_dir, features, download_config, download_mode, ignore_verifications, keep_in_memory, save_infos, revision, use_auth_token, task, streaming, **config_kwargs) 1740 1741 # Download and prepare data -> 1742 builder_instance.download_and_prepare( 1743 download_config=download_config, 1744 download_mode=download_mode, /opt/conda/lib/python3.8/site-packages/datasets/builder.py in download_and_prepare(self, output_dir, download_config, download_mode, ignore_verifications, try_from_hf_gcs, dl_manager, base_path, use_auth_token, file_format, max_shard_size, storage_options, **download_and_prepare_kwargs) 812 **download_and_prepare_kwargs, 813 } --> 814 self._download_and_prepare( 815 dl_manager=dl_manager, 816 verify_infos=verify_infos, /opt/conda/lib/python3.8/site-packages/datasets/builder.py in _download_and_prepare(self, dl_manager, verify_infos, **prepare_splits_kwargs) 1645 options=beam_options, 1646 ) -> 1647 super()._download_and_prepare( 1648 dl_manager, verify_infos=False, pipeline=pipeline, **prepare_splits_kwargs 1649 ) # TODO handle verify_infos in beam datasets /opt/conda/lib/python3.8/site-packages/datasets/builder.py in _download_and_prepare(self, dl_manager, verify_infos, **prepare_split_kwargs) 881 split_dict = SplitDict(dataset_name=self.name) 882 split_generators_kwargs = self._make_split_generators_kwargs(prepare_split_kwargs) --> 883 split_generators = self._split_generators(dl_manager, **split_generators_kwargs) 884 885 # Checksums verification ~/.cache/huggingface/modules/datasets_modules/datasets/wikipedia/aa542ed919df55cc5d3347f42dd4521d05ca68751f50dbc32bae2a7f1e167559/wikipedia.py in _split_generators(self, dl_manager, pipeline) 943 info_url = _base_url(lang) + _INFO_FILE 944 # Use dictionary since testing mock always returns the same result. --> 945 downloaded_files = dl_manager.download_and_extract({"info": info_url}) 946 947 xml_urls = [] /opt/conda/lib/python3.8/site-packages/datasets/download/download_manager.py in download_and_extract(self, url_or_urls) 431 extracted_path(s): `str`, extracted paths of given URL(s). 432 """ --> 433 return self.extract(self.download(url_or_urls)) 434 435 def get_recorded_sizes_checksums(self): /opt/conda/lib/python3.8/site-packages/datasets/download/download_manager.py in download(self, url_or_urls) 308 309 start_time = datetime.now() --> 310 downloaded_path_or_paths = map_nested( 311 download_func, 312 url_or_urls, /opt/conda/lib/python3.8/site-packages/datasets/utils/py_utils.py in map_nested(function, data_struct, dict_only, map_list, map_tuple, map_numpy, num_proc, parallel_min_length, types, disable_tqdm, desc) 427 num_proc = 1 428 if num_proc <= 1 or len(iterable) < parallel_min_length: --> 429 mapped = [ 430 _single_map_nested((function, obj, types, None, True, None)) 431 for obj in logging.tqdm(iterable, disable=disable_tqdm, desc=desc) /opt/conda/lib/python3.8/site-packages/datasets/utils/py_utils.py in <listcomp>(.0) 428 if num_proc <= 1 or len(iterable) < parallel_min_length: 429 mapped = [ --> 430 _single_map_nested((function, obj, types, None, True, None)) 431 for obj in logging.tqdm(iterable, disable=disable_tqdm, desc=desc) 432 ] /opt/conda/lib/python3.8/site-packages/datasets/utils/py_utils.py in _single_map_nested(args) 329 # Singleton first to spare some computation 330 if not isinstance(data_struct, dict) and not isinstance(data_struct, types): --> 331 return function(data_struct) 332 333 # Reduce logging to keep things readable in multiprocessing with tqdm /opt/conda/lib/python3.8/site-packages/datasets/download/download_manager.py in _download(self, url_or_filename, download_config) 335 # append the relative path to the base_path 336 url_or_filename = url_or_path_join(self._base_path, url_or_filename) --> 337 return cached_path(url_or_filename, download_config=download_config) 338 339 def iter_archive(self, path_or_buf: Union[str, io.BufferedReader]): /opt/conda/lib/python3.8/site-packages/datasets/utils/file_utils.py in cached_path(url_or_filename, download_config, **download_kwargs) 186 if is_remote_url(url_or_filename): 187 # URL, so get it from the cache (downloading if necessary) --> 188 output_path = get_from_cache( 189 url_or_filename, 190 cache_dir=cache_dir, /opt/conda/lib/python3.8/site-packages/datasets/utils/file_utils.py in get_from_cache(url, cache_dir, force_download, proxies, etag_timeout, resume_download, user_agent, local_files_only, use_etag, max_retries, use_auth_token, ignore_url_params, download_desc) 533 ) 534 elif response is not None and response.status_code == 404: --> 535 raise FileNotFoundError(f"Couldn't find file at {url}") 536 _raise_if_offline_mode_is_enabled(f"Tried to reach {url}") 537 if head_error is not None: FileNotFoundError: Couldn't find file at https://dumps.wikimedia.org/zhwiki/20220301/dumpstatus.json ``` ### Steps to reproduce the bug `data = load_dataset('wikipedia', '20220301.zh', beam_runner='DirectRunner')` ### Expected behavior download the data ### Environment info python3.6 latest datasets/transformers version
451
113
Unable to download the Chinese `wikipedia`, the dumpstatus.json not found! ### Describe the bug I tried: `data = load_dataset('wikipedia', '20220301.zh', beam_runner='DirectRunner')` and `data = load_dataset("wikipedia", language="zh", date="20220301", beam_runner='DirectRunner')` but both got: `FileNotFoundError: Couldn't find file at https://dumps.wikimedia.org/zhwiki/20220301/dumpstatus.json` the full report is: ``` FileNotFoundError Traceback (most recent call last) <ipython-input-13-d07c5021090c> in <module> 1 from datasets import load_dataset 2 ----> 3 data = load_dataset("wikipedia", language="zh", date="20220301", beam_runner='DirectRunner')<?, ?it/s] /opt/conda/lib/python3.8/site-packages/datasets/load.py in load_dataset(path, name, data_dir, data_files, split, cache_dir, features, download_config, download_mode, ignore_verifications, keep_in_memory, save_infos, revision, use_auth_token, task, streaming, **config_kwargs) 1740 1741 # Download and prepare data -> 1742 builder_instance.download_and_prepare( 1743 download_config=download_config, 1744 download_mode=download_mode, /opt/conda/lib/python3.8/site-packages/datasets/builder.py in download_and_prepare(self, output_dir, download_config, download_mode, ignore_verifications, try_from_hf_gcs, dl_manager, base_path, use_auth_token, file_format, max_shard_size, storage_options, **download_and_prepare_kwargs) 812 **download_and_prepare_kwargs, 813 } --> 814 self._download_and_prepare( 815 dl_manager=dl_manager, 816 verify_infos=verify_infos, /opt/conda/lib/python3.8/site-packages/datasets/builder.py in _download_and_prepare(self, dl_manager, verify_infos, **prepare_splits_kwargs) 1645 options=beam_options, 1646 ) -> 1647 super()._download_and_prepare( 1648 dl_manager, verify_infos=False, pipeline=pipeline, **prepare_splits_kwargs 1649 ) # TODO handle verify_infos in beam datasets /opt/conda/lib/python3.8/site-packages/datasets/builder.py in _download_and_prepare(self, dl_manager, verify_infos, **prepare_split_kwargs) 881 split_dict = SplitDict(dataset_name=self.name) 882 split_generators_kwargs = self._make_split_generators_kwargs(prepare_split_kwargs) --> 883 split_generators = self._split_generators(dl_manager, **split_generators_kwargs) 884 885 # Checksums verification ~/.cache/huggingface/modules/datasets_modules/datasets/wikipedia/aa542ed919df55cc5d3347f42dd4521d05ca68751f50dbc32bae2a7f1e167559/wikipedia.py in _split_generators(self, dl_manager, pipeline) 943 info_url = _base_url(lang) + _INFO_FILE 944 # Use dictionary since testing mock always returns the same result. --> 945 downloaded_files = dl_manager.download_and_extract({"info": info_url}) 946 947 xml_urls = [] /opt/conda/lib/python3.8/site-packages/datasets/download/download_manager.py in download_and_extract(self, url_or_urls) 431 extracted_path(s): `str`, extracted paths of given URL(s). 432 """ --> 433 return self.extract(self.download(url_or_urls)) 434 435 def get_recorded_sizes_checksums(self): /opt/conda/lib/python3.8/site-packages/datasets/download/download_manager.py in download(self, url_or_urls) 308 309 start_time = datetime.now() --> 310 downloaded_path_or_paths = map_nested( 311 download_func, 312 url_or_urls, /opt/conda/lib/python3.8/site-packages/datasets/utils/py_utils.py in map_nested(function, data_struct, dict_only, map_list, map_tuple, map_numpy, num_proc, parallel_min_length, types, disable_tqdm, desc) 427 num_proc = 1 428 if num_proc <= 1 or len(iterable) < parallel_min_length: --> 429 mapped = [ 430 _single_map_nested((function, obj, types, None, True, None)) 431 for obj in logging.tqdm(iterable, disable=disable_tqdm, desc=desc) /opt/conda/lib/python3.8/site-packages/datasets/utils/py_utils.py in <listcomp>(.0) 428 if num_proc <= 1 or len(iterable) < parallel_min_length: 429 mapped = [ --> 430 _single_map_nested((function, obj, types, None, True, None)) 431 for obj in logging.tqdm(iterable, disable=disable_tqdm, desc=desc) 432 ] /opt/conda/lib/python3.8/site-packages/datasets/utils/py_utils.py in _single_map_nested(args) 329 # Singleton first to spare some computation 330 if not isinstance(data_struct, dict) and not isinstance(data_struct, types): --> 331 return function(data_struct) 332 333 # Reduce logging to keep things readable in multiprocessing with tqdm /opt/conda/lib/python3.8/site-packages/datasets/download/download_manager.py in _download(self, url_or_filename, download_config) 335 # append the relative path to the base_path 336 url_or_filename = url_or_path_join(self._base_path, url_or_filename) --> 337 return cached_path(url_or_filename, download_config=download_config) 338 339 def iter_archive(self, path_or_buf: Union[str, io.BufferedReader]): /opt/conda/lib/python3.8/site-packages/datasets/utils/file_utils.py in cached_path(url_or_filename, download_config, **download_kwargs) 186 if is_remote_url(url_or_filename): 187 # URL, so get it from the cache (downloading if necessary) --> 188 output_path = get_from_cache( 189 url_or_filename, 190 cache_dir=cache_dir, /opt/conda/lib/python3.8/site-packages/datasets/utils/file_utils.py in get_from_cache(url, cache_dir, force_download, proxies, etag_timeout, resume_download, user_agent, local_files_only, use_etag, max_retries, use_auth_token, ignore_url_params, download_desc) 533 ) 534 elif response is not None and response.status_code == 404: --> 535 raise FileNotFoundError(f"Couldn't find file at {url}") 536 _raise_if_offline_mode_is_enabled(f"Tried to reach {url}") 537 if head_error is not None: FileNotFoundError: Couldn't find file at https://dumps.wikimedia.org/zhwiki/20220301/dumpstatus.json ``` ### Steps to reproduce the bug `data = load_dataset('wikipedia', '20220301.zh', beam_runner='DirectRunner')` ### Expected behavior download the data ### Environment info python3.6 latest datasets/transformers version Hi, @beyondguo, thanks for reporting. You have all the information in the dataset card: https://huggingface.co/datasets/wikipedia > Then, you can load any subset of Wikipedia per language and per date this way: > ```python > from datasets import load_dataset > > load_dataset("wikipedia", language="sw", date="20220120", beam_runner=...) > ``` > where you can pass as beam_runner any Apache Beam supported runner for (distributed) data processing (see [here](https://beam.apache.org/documentation/runners/capability-matrix/)). Pass "DirectRunner" to run it on your machine. > > You can find the full list of languages and dates [here](https://dumps.wikimedia.org/backup-index.html). Note that you have to pass the language and date as keyword arguments, and the available dates depend on the language and can be found on Wikimedia website.
[ -1.2170014381408691, -0.9683899283409119, -0.5608522891998291, 1.4416203498840332, -0.1440241038799286, -1.2146953344345093, 0.21109837293624878, -1.0700407028198242, 1.5621782541275024, -0.8050041198730469, 0.17415069043636322, -1.646943211555481, -0.07499374449253082, -0.6673901677131653, -0.698634684085846, -0.8470911979675293, -0.35006585717201233, -0.8368162512779236, 1.1412231922149658, 2.380309581756592, 1.2196933031082153, -1.4163579940795898, 2.7417874336242676, 0.6633369326591492, -0.23040145635604858, -1.0188965797424316, 0.501268744468689, 0.012220094911754131, -1.1495826244354248, -0.4889415502548218, -0.9659383296966553, -0.08957697451114655, -0.6564934849739075, -0.27322545647621155, -0.07793689519166946, 0.5286354422569275, -0.2828669548034668, -0.3241702914237976, -0.5456913113594055, -0.7878347039222717, 0.5341796278953552, -0.36390984058380127, 0.9367288947105408, -0.2940966784954071, 1.7430444955825806, -0.5860297083854675, 0.4656287729740143, 0.7571712732315063, 1.1900978088378906, 0.16286368668079376, 0.019353650510311127, 0.200439915060997, 0.3252803385257721, -0.04754190519452095, 0.5969112515449524, 1.1658589839935303, 0.657002866268158, 0.5535026788711548, 0.6542642712593079, -2.2177886962890625, 1.3346971273422241, -1.0343025922775269, 0.3304782211780548, 1.4057916402816772, -0.8765290379524231, 0.359151154756546, -1.7557532787322998, -0.058119598776102066, 0.6481783390045166, -2.1933038234710693, 0.40502938628196716, -1.3102895021438599, -0.5210937857627869, 0.8887270092964172, 0.4179205000400543, -1.221529483795166, 0.1517130434513092, -0.4479084610939026, 1.1475095748901367, 0.3964335322380066, 0.9234474301338196, -1.7467167377471924, -0.020484985783696175, -0.16183368861675262, 0.15411970019340515, -1.2843225002288818, -1.661791443824768, 0.5685978531837463, 0.5246251821517944, 0.6904571056365967, -0.18104539811611176, 1.0798536539077759, -1.1522400379180908, 0.7803519368171692, -1.1722726821899414, -1.54086434841156, -1.358656883239746, -2.422412872314453, -2.3394768238067627, 0.7157904505729675, -0.5086732506752014, -0.5012471079826355, 2.130084276199341, -0.9287640452384949, -1.6577832698822021, 1.1695671081542969, 0.22574955224990845, 0.030104633420705795, 2.3914449214935303, 0.20189954340457916, -0.7385568618774414, 0.5369505286216736, -0.8691916465759277, 0.8071199655532837, -0.31477051973342896, 1.3405535221099854, 0.4891539514064789, -1.0191351175308228, 1.509261965751648, -0.4526011645793915, 0.5842145085334778, -0.5968116521835327, -0.541476845741272, -0.754551887512207, 0.239410862326622, 1.818123698234558, -0.1541256457567215, 1.4538711309432983, -0.279835045337677, -1.5517957210540771, -1.5958083868026733, 1.0371630191802979, 0.350869357585907, -0.9378894567489624, 0.13891978561878204, -0.4555055499076843, 0.22229351103305817, -0.08357372134923935, 1.156264305114746, 1.3059521913528442, 0.7350850701332092, -0.3893837332725525, -0.7287031412124634, 0.09019298106431961, -0.2681887745857239, -0.6702597141265869, -1.827178955078125, -0.2600456774234772, 0.03189661726355553, 0.6513438820838928, -1.1375479698181152, 1.878173828125, 0.9382094740867615, 1.9108741283416748, 0.8873557448387146, -0.4488866329193115, 1.4291075468063354, 0.0425947830080986, 1.8661445379257202, -0.6110694408416748, 0.6401342153549194, -0.42213597893714905, -1.1190975904464722, 1.0016587972640991, -0.31376150250434875, -1.9290226697921753, -0.8085372447967529, -0.7683132290840149, -0.22048398852348328, -0.8074562549591064, 0.8433467149734497, -0.25652387738227844, -1.560677409172058, 0.1819024384021759, -0.6673984527587891, 0.2806224524974823, -1.1621015071868896, 0.3294593095779419, 0.7073994874954224, -0.6532617211341858, -0.050659481436014175, -0.17230486869812012, -1.2645000219345093, -0.46781498193740845, 0.4709959328174591, 1.8939436674118042, -0.5660892724990845, 0.8890480995178223, 1.072402000427246, -0.7024014592170715, 0.06341098994016647, 0.25059518218040466, -0.21641218662261963, 0.695263683795929, -1.0395960807800293, -0.5356206297874451, 1.2094756364822388, -0.41201725602149963, -0.6235672831535339, 1.4571666717529297, 0.7134835720062256, -1.1371079683303833, -0.15421031415462494, -0.2110143005847931, -0.8309813737869263, 0.02465224638581276, -1.487969994544983, -0.09829878062009811, 0.5986323952674866, -1.5024986267089844, -0.35740306973457336, -0.172239750623703, 1.3511487245559692, -0.17959894239902496, 1.430333137512207, -0.37571120262145996, -0.0580558218061924, -0.2701750695705414, -0.46856358647346497, 0.2430909126996994, -0.24432943761348724, -0.44457104802131653, 0.054845888167619705, -0.7970159649848938, 0.3180781900882721, 1.508079171180725, 0.21045303344726562, -0.0019034557044506073, 0.3735906779766083, 1.082767367362976, 0.4175396263599396, 0.0024299900978803635, -0.9098672866821289, -1.4250798225402832, 1.8859914541244507, -1.540601372718811, 1.9672565460205078, 0.7408435940742493, -0.08062721788883209, -1.7460697889328003, -1.7993675470352173, 1.293761968612671, 1.0989381074905396, 2.3081729412078857, 0.46779292821884155, 0.3701840937137604, -0.851073682308197, -0.6825761795043945, 0.3060929775238037, -1.0134387016296387, -0.5825333595275879, 0.196160688996315, 2.41171932220459, 1.8015971183776855, -0.44993528723716736, -0.26312771439552307, -0.8733410239219666, 1.4141523838043213, -0.2940051257610321, 0.2762720584869385, 2.146360397338867, -0.34383851289749146, -1.0486966371536255, 1.3723459243774414, -2.4992480278015137, 0.262148916721344, 2.1008694171905518, 0.3361589014530182, 0.19903534650802612, -1.3560481071472168, -0.6228715181350708, -0.34945249557495117, -0.5175646543502808, -1.2474452257156372, 0.5635823011398315, -0.23242801427841187, -0.7024191617965698, -1.4108389616012573, 0.21011096239089966, -1.1210620403289795, -1.7740126848220825, 0.28346139192581177, 1.919077754020691, 2.1673221588134766, -0.842538595199585, 1.478548526763916, -0.31165722012519836, 0.1001129299402237, 1.2399498224258423, 1.3029555082321167, 3.0731348991394043, 1.8347619771957397, -1.2912744283676147, 0.637525737285614, -0.24080081284046173, -0.5345274209976196, 1.12699294090271, -1.146532416343689, 1.2297435998916626, -0.16546837985515594, -1.1698614358901978, -1.2982354164123535, 1.0163917541503906, 0.450277715921402, 0.0838286355137825, -0.5365099906921387, 1.2165857553482056, 0.1779680848121643, 1.3884118795394897, 0.6263922452926636, -0.40945637226104736, 0.48375266790390015, -0.431661993265152, -0.606079638004303, 1.6260478496551514, 0.25985580682754517, -1.544480323791504, -2.264434337615967, -0.3104991912841797, -0.9340025186538696, 0.09693276137113571, -0.6429155468940735, -1.02992844581604, 1.5748367309570312, 0.37800729274749756, -1.1707088947296143, -0.27575168013572693, -0.2745736241340637, -0.5225574970245361, 2.696237087249756, -1.2222782373428345, -0.13263176381587982, -0.9383622407913208, -0.7015168070793152, 1.6360279321670532, -1.2732577323913574, -0.27571070194244385, -1.0673469305038452, -0.6340727210044861, -1.2339082956314087, -0.3848574161529541, 0.06020070239901543, -1.0515685081481934, 0.8193007707595825, 0.26414135098457336, -1.2780214548110962, -0.372059166431427, -0.8718441128730774, 1.070177435874939, -0.11585889011621475, 0.22785641252994537, 1.7039953470230103, 0.2080129086971283, -0.45733511447906494, 0.8459241390228271, 1.209050178527832, 0.6364569664001465, -0.636812150478363, -0.015720395371317863, -0.6464300155639648, 0.4495864808559418, -1.2726433277130127, 0.2385275810956955, -3.024547815322876, 0.6282491683959961, -0.13449279963970184, -0.12116333097219467, -0.10977765917778015, -1.4193363189697266, 1.105175256729126, 2.4960741996765137, -1.1656547784805298, 0.5616940259933472, 0.44614991545677185, 1.2368656396865845, -1.6130276918411255, 0.2853536605834961, -0.48787423968315125, 2.0665886402130127, 0.15769782662391663, 1.2496864795684814, -0.46011292934417725, -2.37412166595459, 0.6117936372756958, -1.2979633808135986, -1.0852065086364746, 0.8027737140655518, -0.8944094777107239, 0.2864745557308197, -1.4088984727859497, -0.26090335845947266, -0.8898468017578125, -1.2489744424819946, 0.664065420627594, 0.13157249987125397, 0.378083199262619, -0.5866467356681824, 0.31549495458602905, -2.1821129322052, -1.3760285377502441, -0.21103531122207642, -0.9226536750793457, 0.5623751282691956, -0.5101042985916138, 0.5642646551132202, -0.12185706198215485, 0.05777108296751976, 0.31627920269966125, 1.6136058568954468, 3.380206823348999, 0.1136578842997551, 0.26071202754974365, -0.16145943105220795, -0.961010217666626, 1.4653918743133545, 0.8998140096664429, -0.10252530872821808, -0.6017000079154968, -1.0557900667190552, 1.3346889019012451, 1.9546042680740356, 0.9796127676963806, -0.005805733613669872, -0.7704516053199768, -0.6538062691688538, -0.07622605562210083, 0.20413696765899658, 0.5462398529052734, 0.9291355013847351, 0.028791993856430054, 0.03794340044260025, 1.3702205419540405, 1.1289827823638916, -0.3221348226070404, 0.3207196593284607, -0.9244656562805176, -0.4059849679470062, 0.45150771737098694, 0.14583609998226166, -0.041328366845846176, 0.4921247065067291, -0.9579594135284424, -0.3088337779045105, -0.29882967472076416, -0.7924419045448303, -0.7197058200836182, -0.4069828391075134, -0.4533673822879791, 1.5916215181350708, 0.1671016812324524, -0.5351323485374451, 0.09591097384691238, -0.64225834608078, -0.20749258995056152, -1.166085124015808, 0.111827552318573, -0.08475694060325623, -0.16535694897174835, -0.21750612556934357, 1.6943265199661255, -0.9106370806694031, -2.060784339904785, 0.112681083381176, 0.35035601258277893, -0.15534742176532745, 0.1796565055847168, 1.7510414123535156, 0.4609483480453491, 1.4435005187988281, 1.258790135383606, 1.0026617050170898, -0.5963815450668335, -1.2956180572509766, 0.8488948941230774, 0.9791117310523987, -1.3631834983825684, 0.866409957408905, -0.1236843541264534, -0.4979773759841919, 0.7001219987869263, 1.2514941692352295, 0.4436571002006531, -1.9929531812667847, 0.8583927154541016, -1.146759271621704, 0.923383891582489, 0.7105684280395508, 0.6595831513404846, 0.2826668322086334, 0.860019326210022, -1.1870485544204712, -1.0909959077835083, -0.6722009778022766, -0.7562681436538696, 2.034639835357666, -0.37319400906562805, 0.5826557874679565, -0.1488100290298462, -1.1538892984390259, -0.10148066282272339, 0.8104291558265686, 0.4080570340156555, -0.42944827675819397, 0.7323336005210876, -0.6571613550186157, -1.0025581121444702, -1.1971629858016968, -0.3766745626926422, -1.1324542760849, -0.9182586669921875, 1.0327980518341064, 0.7393785119056702, 0.4100472927093506, 1.922598958015442, 0.6615173816680908, 0.4013250470161438, -2.5430922508239746, 0.9066964983940125, 0.28707805275917053, -0.1253030151128769, 0.8327445387840271, 0.4110954999923706, 1.1394646167755127, 0.03169175982475281, 0.5966501235961914, -2.4829251766204834, 2.294358968734741, -0.18197566270828247, 0.6231374740600586, 0.02558591216802597, -0.13844144344329834, 1.174985647201538, 0.6353755593299866, 0.35830825567245483, -1.03628671169281, 0.6640870571136475, -0.49978113174438477, 1.1638071537017822, 0.924072265625, -0.855826199054718, 0.04508421942591667, 1.4000383615493774, 0.44983023405075073, -0.5593210458755493, -1.023922324180603, -0.9196360111236572, 0.9656379222869873, 1.601950764656067, -0.1593981832265854, -0.07576262205839157, 0.7072905898094177, 0.6801508665084839, -1.1495915651321411, 0.07477367669343948, -0.5728888511657715, -0.7233093976974487, 1.692077398300171, 2.104736328125, -0.22725799679756165, -0.12874984741210938, -0.7556700706481934, -1.3494372367858887, 0.8081915974617004, -0.11244066059589386, 0.015592117793858051, 0.5690181255340576, -0.5994241833686829, 0.9457734227180481, 0.6448037028312683, 0.9118123054504395, 0.15812146663665771, 0.27638137340545654, 0.47165894508361816, -0.3941633403301239, -1.1330960988998413, -0.3037711977958679, -1.2069180011749268, -2.6697609424591064, 0.34435221552848816, -0.2508181631565094, -1.3857330083847046, 0.024846047163009644, -1.043538212776184, 0.9420125484466553, -0.5942971110343933, -1.183124303817749, -1.473703384399414, 0.3455038368701935, -0.03765144199132919, 0.9741702079772949, -1.6550544500350952, -0.20296348631381989, 1.162786602973938, 0.7588387131690979, -0.7139344811439514, 0.9930270314216614, 0.2301415354013443, 1.0172510147094727, 0.7267889976501465, -0.4096280038356781, 0.722879946231842, 0.016143444925546646, -1.3864203691482544, 0.4798646569252014, 1.2999470233917236, 0.13147525489330292, 1.4166793823242188, -0.4093073308467865, 0.028207633644342422, 0.4101737439632416, -0.6614828109741211, -0.6179669499397278, -0.3092504143714905, 0.61649489402771, 0.03138669580221176, -0.9605509638786316, -0.0880957618355751, -0.08301261812448502, -0.4407540261745453, 0.21981756389141083, -1.4779911041259766, -0.2701922357082367, -0.4885001480579376, -0.4397026300430298, -1.4035513401031494, -0.09345357120037079, 1.3823351860046387, -0.6136641502380371, -0.2607633173465729, 0.48287731409072876, 0.34330618381500244, 0.4977618157863617, 0.6245275139808655, -0.7047929167747498, -0.2206849604845047, -0.31124016642570496, -0.30941706895828247, 0.38961875438690186, 1.3733452558517456, -0.07292836159467697, -0.9359123706817627, 0.6043532490730286, -0.29037368297576904, 0.21843069791793823, 1.9131218194961548, 0.05746011808514595, -0.7420433759689331, 0.3667701482772827, -0.739910364151001, 1.870839238166809, 1.739117980003357, 1.1646950244903564, -0.14208683371543884, -0.8149221539497375, 0.5925320982933044, -0.3625938892364502, -0.3713972568511963, 0.8268902897834778, 0.327970415353775, -0.30247119069099426, -1.4257985353469849, 0.817221462726593, 1.2165766954421997, -0.7083972692489624, -0.8205990791320801, 0.15322424471378326, -0.8102108240127563, 1.2214288711547852, 0.49646177887916565, 0.4289621114730835, 0.2867667078971863, 1.6273289918899536, 0.8508263826370239, -0.4778187870979309, 0.6282122135162354, 0.5028642416000366, -0.20096319913864136, -2.136291265487671, -1.2338007688522339, 0.2510344386100769, -0.6172120571136475, -1.5574766397476196, 1.4210950136184692, -1.002721905708313, -1.054930567741394, 0.6148954629898071, 0.04684268310666084, 1.2750838994979858, 0.425082802772522, 1.5455282926559448, 2.093168258666992, 0.8298642039299011, 0.5490590929985046, 1.2001304626464844, -0.2265365719795227, -0.47244083881378174, 1.8992531299591064, -0.36517012119293213, 0.4507097601890564, 1.1439728736877441, -0.316078782081604, -1.0779838562011719, -0.8175809979438782, -1.2080016136169434, -0.6967859268188477, 1.1208946704864502, 0.08701435476541519, -1.0667985677719116, 0.28405702114105225, 1.6269704103469849, 0.11976712197065353, -0.22628790140151978, 0.6912527680397034, 0.3561188578605652, -0.7939194440841675, -0.07375819236040115, -0.8984496593475342, 0.5331429243087769, -0.3125242292881012, -0.3233226239681244, 0.3225749135017395, 0.5433096885681152, 1.295554280281067, -0.10036730766296387, 0.19405411183834076, 0.9723783135414124, -1.4329570531845093, 1.4417223930358887, -0.5906931757926941, 0.33708253502845764, -2.3168203830718994, 1.2830235958099365, -0.6814137697219849, 2.0614349842071533, -2.6394622325897217, 0.39431673288345337, -0.5553480386734009, -0.5731869339942932, 0.27154409885406494, -0.3612765371799469, 0.09517797082662582, -0.0986931174993515, -1.0936061143875122, 0.05481443926692009, -0.6018697619438171, 0.5871978998184204, 1.1391236782073975, 1.4432947635650635, -1.0556639432907104, -0.22669000923633575, -1.644964337348938, -0.08113828301429749, -0.7896649837493896, 0.21823126077651978, -1.9583266973495483, -0.15668334066867828, -1.965868353843689, -2.2251174449920654, -1.2741742134094238, -0.9023155570030212, 1.1391862630844116, 0.1258905977010727, -0.9208382368087769, 1.3752732276916504, -0.28702208399772644, -1.7495067119598389, 1.0958558320999146, -2.1503026485443115 ]
https://github.com/huggingface/datasets/issues/5178
Unable to download the Chinese `wikipedia`, the dumpstatus.json not found!
Also: > Some subsets of Wikipedia have already been processed by HuggingFace, and you can load them just with: > ```python > load_dataset("wikipedia", "20220301.en") > ``` > The list of pre-processed subsets is: > - "20220301.de" > - "20220301.en" > - "20220301.fr" > - "20220301.frr" > - "20220301.it" > - "20220301.simple"
### Describe the bug I tried: `data = load_dataset('wikipedia', '20220301.zh', beam_runner='DirectRunner')` and `data = load_dataset("wikipedia", language="zh", date="20220301", beam_runner='DirectRunner')` but both got: `FileNotFoundError: Couldn't find file at https://dumps.wikimedia.org/zhwiki/20220301/dumpstatus.json` the full report is: ``` FileNotFoundError Traceback (most recent call last) <ipython-input-13-d07c5021090c> in <module> 1 from datasets import load_dataset 2 ----> 3 data = load_dataset("wikipedia", language="zh", date="20220301", beam_runner='DirectRunner')<?, ?it/s] /opt/conda/lib/python3.8/site-packages/datasets/load.py in load_dataset(path, name, data_dir, data_files, split, cache_dir, features, download_config, download_mode, ignore_verifications, keep_in_memory, save_infos, revision, use_auth_token, task, streaming, **config_kwargs) 1740 1741 # Download and prepare data -> 1742 builder_instance.download_and_prepare( 1743 download_config=download_config, 1744 download_mode=download_mode, /opt/conda/lib/python3.8/site-packages/datasets/builder.py in download_and_prepare(self, output_dir, download_config, download_mode, ignore_verifications, try_from_hf_gcs, dl_manager, base_path, use_auth_token, file_format, max_shard_size, storage_options, **download_and_prepare_kwargs) 812 **download_and_prepare_kwargs, 813 } --> 814 self._download_and_prepare( 815 dl_manager=dl_manager, 816 verify_infos=verify_infos, /opt/conda/lib/python3.8/site-packages/datasets/builder.py in _download_and_prepare(self, dl_manager, verify_infos, **prepare_splits_kwargs) 1645 options=beam_options, 1646 ) -> 1647 super()._download_and_prepare( 1648 dl_manager, verify_infos=False, pipeline=pipeline, **prepare_splits_kwargs 1649 ) # TODO handle verify_infos in beam datasets /opt/conda/lib/python3.8/site-packages/datasets/builder.py in _download_and_prepare(self, dl_manager, verify_infos, **prepare_split_kwargs) 881 split_dict = SplitDict(dataset_name=self.name) 882 split_generators_kwargs = self._make_split_generators_kwargs(prepare_split_kwargs) --> 883 split_generators = self._split_generators(dl_manager, **split_generators_kwargs) 884 885 # Checksums verification ~/.cache/huggingface/modules/datasets_modules/datasets/wikipedia/aa542ed919df55cc5d3347f42dd4521d05ca68751f50dbc32bae2a7f1e167559/wikipedia.py in _split_generators(self, dl_manager, pipeline) 943 info_url = _base_url(lang) + _INFO_FILE 944 # Use dictionary since testing mock always returns the same result. --> 945 downloaded_files = dl_manager.download_and_extract({"info": info_url}) 946 947 xml_urls = [] /opt/conda/lib/python3.8/site-packages/datasets/download/download_manager.py in download_and_extract(self, url_or_urls) 431 extracted_path(s): `str`, extracted paths of given URL(s). 432 """ --> 433 return self.extract(self.download(url_or_urls)) 434 435 def get_recorded_sizes_checksums(self): /opt/conda/lib/python3.8/site-packages/datasets/download/download_manager.py in download(self, url_or_urls) 308 309 start_time = datetime.now() --> 310 downloaded_path_or_paths = map_nested( 311 download_func, 312 url_or_urls, /opt/conda/lib/python3.8/site-packages/datasets/utils/py_utils.py in map_nested(function, data_struct, dict_only, map_list, map_tuple, map_numpy, num_proc, parallel_min_length, types, disable_tqdm, desc) 427 num_proc = 1 428 if num_proc <= 1 or len(iterable) < parallel_min_length: --> 429 mapped = [ 430 _single_map_nested((function, obj, types, None, True, None)) 431 for obj in logging.tqdm(iterable, disable=disable_tqdm, desc=desc) /opt/conda/lib/python3.8/site-packages/datasets/utils/py_utils.py in <listcomp>(.0) 428 if num_proc <= 1 or len(iterable) < parallel_min_length: 429 mapped = [ --> 430 _single_map_nested((function, obj, types, None, True, None)) 431 for obj in logging.tqdm(iterable, disable=disable_tqdm, desc=desc) 432 ] /opt/conda/lib/python3.8/site-packages/datasets/utils/py_utils.py in _single_map_nested(args) 329 # Singleton first to spare some computation 330 if not isinstance(data_struct, dict) and not isinstance(data_struct, types): --> 331 return function(data_struct) 332 333 # Reduce logging to keep things readable in multiprocessing with tqdm /opt/conda/lib/python3.8/site-packages/datasets/download/download_manager.py in _download(self, url_or_filename, download_config) 335 # append the relative path to the base_path 336 url_or_filename = url_or_path_join(self._base_path, url_or_filename) --> 337 return cached_path(url_or_filename, download_config=download_config) 338 339 def iter_archive(self, path_or_buf: Union[str, io.BufferedReader]): /opt/conda/lib/python3.8/site-packages/datasets/utils/file_utils.py in cached_path(url_or_filename, download_config, **download_kwargs) 186 if is_remote_url(url_or_filename): 187 # URL, so get it from the cache (downloading if necessary) --> 188 output_path = get_from_cache( 189 url_or_filename, 190 cache_dir=cache_dir, /opt/conda/lib/python3.8/site-packages/datasets/utils/file_utils.py in get_from_cache(url, cache_dir, force_download, proxies, etag_timeout, resume_download, user_agent, local_files_only, use_etag, max_retries, use_auth_token, ignore_url_params, download_desc) 533 ) 534 elif response is not None and response.status_code == 404: --> 535 raise FileNotFoundError(f"Couldn't find file at {url}") 536 _raise_if_offline_mode_is_enabled(f"Tried to reach {url}") 537 if head_error is not None: FileNotFoundError: Couldn't find file at https://dumps.wikimedia.org/zhwiki/20220301/dumpstatus.json ``` ### Steps to reproduce the bug `data = load_dataset('wikipedia', '20220301.zh', beam_runner='DirectRunner')` ### Expected behavior download the data ### Environment info python3.6 latest datasets/transformers version
451
51
Unable to download the Chinese `wikipedia`, the dumpstatus.json not found! ### Describe the bug I tried: `data = load_dataset('wikipedia', '20220301.zh', beam_runner='DirectRunner')` and `data = load_dataset("wikipedia", language="zh", date="20220301", beam_runner='DirectRunner')` but both got: `FileNotFoundError: Couldn't find file at https://dumps.wikimedia.org/zhwiki/20220301/dumpstatus.json` the full report is: ``` FileNotFoundError Traceback (most recent call last) <ipython-input-13-d07c5021090c> in <module> 1 from datasets import load_dataset 2 ----> 3 data = load_dataset("wikipedia", language="zh", date="20220301", beam_runner='DirectRunner')<?, ?it/s] /opt/conda/lib/python3.8/site-packages/datasets/load.py in load_dataset(path, name, data_dir, data_files, split, cache_dir, features, download_config, download_mode, ignore_verifications, keep_in_memory, save_infos, revision, use_auth_token, task, streaming, **config_kwargs) 1740 1741 # Download and prepare data -> 1742 builder_instance.download_and_prepare( 1743 download_config=download_config, 1744 download_mode=download_mode, /opt/conda/lib/python3.8/site-packages/datasets/builder.py in download_and_prepare(self, output_dir, download_config, download_mode, ignore_verifications, try_from_hf_gcs, dl_manager, base_path, use_auth_token, file_format, max_shard_size, storage_options, **download_and_prepare_kwargs) 812 **download_and_prepare_kwargs, 813 } --> 814 self._download_and_prepare( 815 dl_manager=dl_manager, 816 verify_infos=verify_infos, /opt/conda/lib/python3.8/site-packages/datasets/builder.py in _download_and_prepare(self, dl_manager, verify_infos, **prepare_splits_kwargs) 1645 options=beam_options, 1646 ) -> 1647 super()._download_and_prepare( 1648 dl_manager, verify_infos=False, pipeline=pipeline, **prepare_splits_kwargs 1649 ) # TODO handle verify_infos in beam datasets /opt/conda/lib/python3.8/site-packages/datasets/builder.py in _download_and_prepare(self, dl_manager, verify_infos, **prepare_split_kwargs) 881 split_dict = SplitDict(dataset_name=self.name) 882 split_generators_kwargs = self._make_split_generators_kwargs(prepare_split_kwargs) --> 883 split_generators = self._split_generators(dl_manager, **split_generators_kwargs) 884 885 # Checksums verification ~/.cache/huggingface/modules/datasets_modules/datasets/wikipedia/aa542ed919df55cc5d3347f42dd4521d05ca68751f50dbc32bae2a7f1e167559/wikipedia.py in _split_generators(self, dl_manager, pipeline) 943 info_url = _base_url(lang) + _INFO_FILE 944 # Use dictionary since testing mock always returns the same result. --> 945 downloaded_files = dl_manager.download_and_extract({"info": info_url}) 946 947 xml_urls = [] /opt/conda/lib/python3.8/site-packages/datasets/download/download_manager.py in download_and_extract(self, url_or_urls) 431 extracted_path(s): `str`, extracted paths of given URL(s). 432 """ --> 433 return self.extract(self.download(url_or_urls)) 434 435 def get_recorded_sizes_checksums(self): /opt/conda/lib/python3.8/site-packages/datasets/download/download_manager.py in download(self, url_or_urls) 308 309 start_time = datetime.now() --> 310 downloaded_path_or_paths = map_nested( 311 download_func, 312 url_or_urls, /opt/conda/lib/python3.8/site-packages/datasets/utils/py_utils.py in map_nested(function, data_struct, dict_only, map_list, map_tuple, map_numpy, num_proc, parallel_min_length, types, disable_tqdm, desc) 427 num_proc = 1 428 if num_proc <= 1 or len(iterable) < parallel_min_length: --> 429 mapped = [ 430 _single_map_nested((function, obj, types, None, True, None)) 431 for obj in logging.tqdm(iterable, disable=disable_tqdm, desc=desc) /opt/conda/lib/python3.8/site-packages/datasets/utils/py_utils.py in <listcomp>(.0) 428 if num_proc <= 1 or len(iterable) < parallel_min_length: 429 mapped = [ --> 430 _single_map_nested((function, obj, types, None, True, None)) 431 for obj in logging.tqdm(iterable, disable=disable_tqdm, desc=desc) 432 ] /opt/conda/lib/python3.8/site-packages/datasets/utils/py_utils.py in _single_map_nested(args) 329 # Singleton first to spare some computation 330 if not isinstance(data_struct, dict) and not isinstance(data_struct, types): --> 331 return function(data_struct) 332 333 # Reduce logging to keep things readable in multiprocessing with tqdm /opt/conda/lib/python3.8/site-packages/datasets/download/download_manager.py in _download(self, url_or_filename, download_config) 335 # append the relative path to the base_path 336 url_or_filename = url_or_path_join(self._base_path, url_or_filename) --> 337 return cached_path(url_or_filename, download_config=download_config) 338 339 def iter_archive(self, path_or_buf: Union[str, io.BufferedReader]): /opt/conda/lib/python3.8/site-packages/datasets/utils/file_utils.py in cached_path(url_or_filename, download_config, **download_kwargs) 186 if is_remote_url(url_or_filename): 187 # URL, so get it from the cache (downloading if necessary) --> 188 output_path = get_from_cache( 189 url_or_filename, 190 cache_dir=cache_dir, /opt/conda/lib/python3.8/site-packages/datasets/utils/file_utils.py in get_from_cache(url, cache_dir, force_download, proxies, etag_timeout, resume_download, user_agent, local_files_only, use_etag, max_retries, use_auth_token, ignore_url_params, download_desc) 533 ) 534 elif response is not None and response.status_code == 404: --> 535 raise FileNotFoundError(f"Couldn't find file at {url}") 536 _raise_if_offline_mode_is_enabled(f"Tried to reach {url}") 537 if head_error is not None: FileNotFoundError: Couldn't find file at https://dumps.wikimedia.org/zhwiki/20220301/dumpstatus.json ``` ### Steps to reproduce the bug `data = load_dataset('wikipedia', '20220301.zh', beam_runner='DirectRunner')` ### Expected behavior download the data ### Environment info python3.6 latest datasets/transformers version Also: > Some subsets of Wikipedia have already been processed by HuggingFace, and you can load them just with: > ```python > load_dataset("wikipedia", "20220301.en") > ``` > The list of pre-processed subsets is: > - "20220301.de" > - "20220301.en" > - "20220301.fr" > - "20220301.frr" > - "20220301.it" > - "20220301.simple"
[ -1.2170014381408691, -0.9683899283409119, -0.5608522891998291, 1.4416203498840332, -0.1440241038799286, -1.2146953344345093, 0.21109837293624878, -1.0700407028198242, 1.5621782541275024, -0.8050041198730469, 0.17415069043636322, -1.646943211555481, -0.07499374449253082, -0.6673901677131653, -0.698634684085846, -0.8470911979675293, -0.35006585717201233, -0.8368162512779236, 1.1412231922149658, 2.380309581756592, 1.2196933031082153, -1.4163579940795898, 2.7417874336242676, 0.6633369326591492, -0.23040145635604858, -1.0188965797424316, 0.501268744468689, 0.012220094911754131, -1.1495826244354248, -0.4889415502548218, -0.9659383296966553, -0.08957697451114655, -0.6564934849739075, -0.27322545647621155, -0.07793689519166946, 0.5286354422569275, -0.2828669548034668, -0.3241702914237976, -0.5456913113594055, -0.7878347039222717, 0.5341796278953552, -0.36390984058380127, 0.9367288947105408, -0.2940966784954071, 1.7430444955825806, -0.5860297083854675, 0.4656287729740143, 0.7571712732315063, 1.1900978088378906, 0.16286368668079376, 0.019353650510311127, 0.200439915060997, 0.3252803385257721, -0.04754190519452095, 0.5969112515449524, 1.1658589839935303, 0.657002866268158, 0.5535026788711548, 0.6542642712593079, -2.2177886962890625, 1.3346971273422241, -1.0343025922775269, 0.3304782211780548, 1.4057916402816772, -0.8765290379524231, 0.359151154756546, -1.7557532787322998, -0.058119598776102066, 0.6481783390045166, -2.1933038234710693, 0.40502938628196716, -1.3102895021438599, -0.5210937857627869, 0.8887270092964172, 0.4179205000400543, -1.221529483795166, 0.1517130434513092, -0.4479084610939026, 1.1475095748901367, 0.3964335322380066, 0.9234474301338196, -1.7467167377471924, -0.020484985783696175, -0.16183368861675262, 0.15411970019340515, -1.2843225002288818, -1.661791443824768, 0.5685978531837463, 0.5246251821517944, 0.6904571056365967, -0.18104539811611176, 1.0798536539077759, -1.1522400379180908, 0.7803519368171692, -1.1722726821899414, -1.54086434841156, -1.358656883239746, -2.422412872314453, -2.3394768238067627, 0.7157904505729675, -0.5086732506752014, -0.5012471079826355, 2.130084276199341, -0.9287640452384949, -1.6577832698822021, 1.1695671081542969, 0.22574955224990845, 0.030104633420705795, 2.3914449214935303, 0.20189954340457916, -0.7385568618774414, 0.5369505286216736, -0.8691916465759277, 0.8071199655532837, -0.31477051973342896, 1.3405535221099854, 0.4891539514064789, -1.0191351175308228, 1.509261965751648, -0.4526011645793915, 0.5842145085334778, -0.5968116521835327, -0.541476845741272, -0.754551887512207, 0.239410862326622, 1.818123698234558, -0.1541256457567215, 1.4538711309432983, -0.279835045337677, -1.5517957210540771, -1.5958083868026733, 1.0371630191802979, 0.350869357585907, -0.9378894567489624, 0.13891978561878204, -0.4555055499076843, 0.22229351103305817, -0.08357372134923935, 1.156264305114746, 1.3059521913528442, 0.7350850701332092, -0.3893837332725525, -0.7287031412124634, 0.09019298106431961, -0.2681887745857239, -0.6702597141265869, -1.827178955078125, -0.2600456774234772, 0.03189661726355553, 0.6513438820838928, -1.1375479698181152, 1.878173828125, 0.9382094740867615, 1.9108741283416748, 0.8873557448387146, -0.4488866329193115, 1.4291075468063354, 0.0425947830080986, 1.8661445379257202, -0.6110694408416748, 0.6401342153549194, -0.42213597893714905, -1.1190975904464722, 1.0016587972640991, -0.31376150250434875, -1.9290226697921753, -0.8085372447967529, -0.7683132290840149, -0.22048398852348328, -0.8074562549591064, 0.8433467149734497, -0.25652387738227844, -1.560677409172058, 0.1819024384021759, -0.6673984527587891, 0.2806224524974823, -1.1621015071868896, 0.3294593095779419, 0.7073994874954224, -0.6532617211341858, -0.050659481436014175, -0.17230486869812012, -1.2645000219345093, -0.46781498193740845, 0.4709959328174591, 1.8939436674118042, -0.5660892724990845, 0.8890480995178223, 1.072402000427246, -0.7024014592170715, 0.06341098994016647, 0.25059518218040466, -0.21641218662261963, 0.695263683795929, -1.0395960807800293, -0.5356206297874451, 1.2094756364822388, -0.41201725602149963, -0.6235672831535339, 1.4571666717529297, 0.7134835720062256, -1.1371079683303833, -0.15421031415462494, -0.2110143005847931, -0.8309813737869263, 0.02465224638581276, -1.487969994544983, -0.09829878062009811, 0.5986323952674866, -1.5024986267089844, -0.35740306973457336, -0.172239750623703, 1.3511487245559692, -0.17959894239902496, 1.430333137512207, -0.37571120262145996, -0.0580558218061924, -0.2701750695705414, -0.46856358647346497, 0.2430909126996994, -0.24432943761348724, -0.44457104802131653, 0.054845888167619705, -0.7970159649848938, 0.3180781900882721, 1.508079171180725, 0.21045303344726562, -0.0019034557044506073, 0.3735906779766083, 1.082767367362976, 0.4175396263599396, 0.0024299900978803635, -0.9098672866821289, -1.4250798225402832, 1.8859914541244507, -1.540601372718811, 1.9672565460205078, 0.7408435940742493, -0.08062721788883209, -1.7460697889328003, -1.7993675470352173, 1.293761968612671, 1.0989381074905396, 2.3081729412078857, 0.46779292821884155, 0.3701840937137604, -0.851073682308197, -0.6825761795043945, 0.3060929775238037, -1.0134387016296387, -0.5825333595275879, 0.196160688996315, 2.41171932220459, 1.8015971183776855, -0.44993528723716736, -0.26312771439552307, -0.8733410239219666, 1.4141523838043213, -0.2940051257610321, 0.2762720584869385, 2.146360397338867, -0.34383851289749146, -1.0486966371536255, 1.3723459243774414, -2.4992480278015137, 0.262148916721344, 2.1008694171905518, 0.3361589014530182, 0.19903534650802612, -1.3560481071472168, -0.6228715181350708, -0.34945249557495117, -0.5175646543502808, -1.2474452257156372, 0.5635823011398315, -0.23242801427841187, -0.7024191617965698, -1.4108389616012573, 0.21011096239089966, -1.1210620403289795, -1.7740126848220825, 0.28346139192581177, 1.919077754020691, 2.1673221588134766, -0.842538595199585, 1.478548526763916, -0.31165722012519836, 0.1001129299402237, 1.2399498224258423, 1.3029555082321167, 3.0731348991394043, 1.8347619771957397, -1.2912744283676147, 0.637525737285614, -0.24080081284046173, -0.5345274209976196, 1.12699294090271, -1.146532416343689, 1.2297435998916626, -0.16546837985515594, -1.1698614358901978, -1.2982354164123535, 1.0163917541503906, 0.450277715921402, 0.0838286355137825, -0.5365099906921387, 1.2165857553482056, 0.1779680848121643, 1.3884118795394897, 0.6263922452926636, -0.40945637226104736, 0.48375266790390015, -0.431661993265152, -0.606079638004303, 1.6260478496551514, 0.25985580682754517, -1.544480323791504, -2.264434337615967, -0.3104991912841797, -0.9340025186538696, 0.09693276137113571, -0.6429155468940735, -1.02992844581604, 1.5748367309570312, 0.37800729274749756, -1.1707088947296143, -0.27575168013572693, -0.2745736241340637, -0.5225574970245361, 2.696237087249756, -1.2222782373428345, -0.13263176381587982, -0.9383622407913208, -0.7015168070793152, 1.6360279321670532, -1.2732577323913574, -0.27571070194244385, -1.0673469305038452, -0.6340727210044861, -1.2339082956314087, -0.3848574161529541, 0.06020070239901543, -1.0515685081481934, 0.8193007707595825, 0.26414135098457336, -1.2780214548110962, -0.372059166431427, -0.8718441128730774, 1.070177435874939, -0.11585889011621475, 0.22785641252994537, 1.7039953470230103, 0.2080129086971283, -0.45733511447906494, 0.8459241390228271, 1.209050178527832, 0.6364569664001465, -0.636812150478363, -0.015720395371317863, -0.6464300155639648, 0.4495864808559418, -1.2726433277130127, 0.2385275810956955, -3.024547815322876, 0.6282491683959961, -0.13449279963970184, -0.12116333097219467, -0.10977765917778015, -1.4193363189697266, 1.105175256729126, 2.4960741996765137, -1.1656547784805298, 0.5616940259933472, 0.44614991545677185, 1.2368656396865845, -1.6130276918411255, 0.2853536605834961, -0.48787423968315125, 2.0665886402130127, 0.15769782662391663, 1.2496864795684814, -0.46011292934417725, -2.37412166595459, 0.6117936372756958, -1.2979633808135986, -1.0852065086364746, 0.8027737140655518, -0.8944094777107239, 0.2864745557308197, -1.4088984727859497, -0.26090335845947266, -0.8898468017578125, -1.2489744424819946, 0.664065420627594, 0.13157249987125397, 0.378083199262619, -0.5866467356681824, 0.31549495458602905, -2.1821129322052, -1.3760285377502441, -0.21103531122207642, -0.9226536750793457, 0.5623751282691956, -0.5101042985916138, 0.5642646551132202, -0.12185706198215485, 0.05777108296751976, 0.31627920269966125, 1.6136058568954468, 3.380206823348999, 0.1136578842997551, 0.26071202754974365, -0.16145943105220795, -0.961010217666626, 1.4653918743133545, 0.8998140096664429, -0.10252530872821808, -0.6017000079154968, -1.0557900667190552, 1.3346889019012451, 1.9546042680740356, 0.9796127676963806, -0.005805733613669872, -0.7704516053199768, -0.6538062691688538, -0.07622605562210083, 0.20413696765899658, 0.5462398529052734, 0.9291355013847351, 0.028791993856430054, 0.03794340044260025, 1.3702205419540405, 1.1289827823638916, -0.3221348226070404, 0.3207196593284607, -0.9244656562805176, -0.4059849679470062, 0.45150771737098694, 0.14583609998226166, -0.041328366845846176, 0.4921247065067291, -0.9579594135284424, -0.3088337779045105, -0.29882967472076416, -0.7924419045448303, -0.7197058200836182, -0.4069828391075134, -0.4533673822879791, 1.5916215181350708, 0.1671016812324524, -0.5351323485374451, 0.09591097384691238, -0.64225834608078, -0.20749258995056152, -1.166085124015808, 0.111827552318573, -0.08475694060325623, -0.16535694897174835, -0.21750612556934357, 1.6943265199661255, -0.9106370806694031, -2.060784339904785, 0.112681083381176, 0.35035601258277893, -0.15534742176532745, 0.1796565055847168, 1.7510414123535156, 0.4609483480453491, 1.4435005187988281, 1.258790135383606, 1.0026617050170898, -0.5963815450668335, -1.2956180572509766, 0.8488948941230774, 0.9791117310523987, -1.3631834983825684, 0.866409957408905, -0.1236843541264534, -0.4979773759841919, 0.7001219987869263, 1.2514941692352295, 0.4436571002006531, -1.9929531812667847, 0.8583927154541016, -1.146759271621704, 0.923383891582489, 0.7105684280395508, 0.6595831513404846, 0.2826668322086334, 0.860019326210022, -1.1870485544204712, -1.0909959077835083, -0.6722009778022766, -0.7562681436538696, 2.034639835357666, -0.37319400906562805, 0.5826557874679565, -0.1488100290298462, -1.1538892984390259, -0.10148066282272339, 0.8104291558265686, 0.4080570340156555, -0.42944827675819397, 0.7323336005210876, -0.6571613550186157, -1.0025581121444702, -1.1971629858016968, -0.3766745626926422, -1.1324542760849, -0.9182586669921875, 1.0327980518341064, 0.7393785119056702, 0.4100472927093506, 1.922598958015442, 0.6615173816680908, 0.4013250470161438, -2.5430922508239746, 0.9066964983940125, 0.28707805275917053, -0.1253030151128769, 0.8327445387840271, 0.4110954999923706, 1.1394646167755127, 0.03169175982475281, 0.5966501235961914, -2.4829251766204834, 2.294358968734741, -0.18197566270828247, 0.6231374740600586, 0.02558591216802597, -0.13844144344329834, 1.174985647201538, 0.6353755593299866, 0.35830825567245483, -1.03628671169281, 0.6640870571136475, -0.49978113174438477, 1.1638071537017822, 0.924072265625, -0.855826199054718, 0.04508421942591667, 1.4000383615493774, 0.44983023405075073, -0.5593210458755493, -1.023922324180603, -0.9196360111236572, 0.9656379222869873, 1.601950764656067, -0.1593981832265854, -0.07576262205839157, 0.7072905898094177, 0.6801508665084839, -1.1495915651321411, 0.07477367669343948, -0.5728888511657715, -0.7233093976974487, 1.692077398300171, 2.104736328125, -0.22725799679756165, -0.12874984741210938, -0.7556700706481934, -1.3494372367858887, 0.8081915974617004, -0.11244066059589386, 0.015592117793858051, 0.5690181255340576, -0.5994241833686829, 0.9457734227180481, 0.6448037028312683, 0.9118123054504395, 0.15812146663665771, 0.27638137340545654, 0.47165894508361816, -0.3941633403301239, -1.1330960988998413, -0.3037711977958679, -1.2069180011749268, -2.6697609424591064, 0.34435221552848816, -0.2508181631565094, -1.3857330083847046, 0.024846047163009644, -1.043538212776184, 0.9420125484466553, -0.5942971110343933, -1.183124303817749, -1.473703384399414, 0.3455038368701935, -0.03765144199132919, 0.9741702079772949, -1.6550544500350952, -0.20296348631381989, 1.162786602973938, 0.7588387131690979, -0.7139344811439514, 0.9930270314216614, 0.2301415354013443, 1.0172510147094727, 0.7267889976501465, -0.4096280038356781, 0.722879946231842, 0.016143444925546646, -1.3864203691482544, 0.4798646569252014, 1.2999470233917236, 0.13147525489330292, 1.4166793823242188, -0.4093073308467865, 0.028207633644342422, 0.4101737439632416, -0.6614828109741211, -0.6179669499397278, -0.3092504143714905, 0.61649489402771, 0.03138669580221176, -0.9605509638786316, -0.0880957618355751, -0.08301261812448502, -0.4407540261745453, 0.21981756389141083, -1.4779911041259766, -0.2701922357082367, -0.4885001480579376, -0.4397026300430298, -1.4035513401031494, -0.09345357120037079, 1.3823351860046387, -0.6136641502380371, -0.2607633173465729, 0.48287731409072876, 0.34330618381500244, 0.4977618157863617, 0.6245275139808655, -0.7047929167747498, -0.2206849604845047, -0.31124016642570496, -0.30941706895828247, 0.38961875438690186, 1.3733452558517456, -0.07292836159467697, -0.9359123706817627, 0.6043532490730286, -0.29037368297576904, 0.21843069791793823, 1.9131218194961548, 0.05746011808514595, -0.7420433759689331, 0.3667701482772827, -0.739910364151001, 1.870839238166809, 1.739117980003357, 1.1646950244903564, -0.14208683371543884, -0.8149221539497375, 0.5925320982933044, -0.3625938892364502, -0.3713972568511963, 0.8268902897834778, 0.327970415353775, -0.30247119069099426, -1.4257985353469849, 0.817221462726593, 1.2165766954421997, -0.7083972692489624, -0.8205990791320801, 0.15322424471378326, -0.8102108240127563, 1.2214288711547852, 0.49646177887916565, 0.4289621114730835, 0.2867667078971863, 1.6273289918899536, 0.8508263826370239, -0.4778187870979309, 0.6282122135162354, 0.5028642416000366, -0.20096319913864136, -2.136291265487671, -1.2338007688522339, 0.2510344386100769, -0.6172120571136475, -1.5574766397476196, 1.4210950136184692, -1.002721905708313, -1.054930567741394, 0.6148954629898071, 0.04684268310666084, 1.2750838994979858, 0.425082802772522, 1.5455282926559448, 2.093168258666992, 0.8298642039299011, 0.5490590929985046, 1.2001304626464844, -0.2265365719795227, -0.47244083881378174, 1.8992531299591064, -0.36517012119293213, 0.4507097601890564, 1.1439728736877441, -0.316078782081604, -1.0779838562011719, -0.8175809979438782, -1.2080016136169434, -0.6967859268188477, 1.1208946704864502, 0.08701435476541519, -1.0667985677719116, 0.28405702114105225, 1.6269704103469849, 0.11976712197065353, -0.22628790140151978, 0.6912527680397034, 0.3561188578605652, -0.7939194440841675, -0.07375819236040115, -0.8984496593475342, 0.5331429243087769, -0.3125242292881012, -0.3233226239681244, 0.3225749135017395, 0.5433096885681152, 1.295554280281067, -0.10036730766296387, 0.19405411183834076, 0.9723783135414124, -1.4329570531845093, 1.4417223930358887, -0.5906931757926941, 0.33708253502845764, -2.3168203830718994, 1.2830235958099365, -0.6814137697219849, 2.0614349842071533, -2.6394622325897217, 0.39431673288345337, -0.5553480386734009, -0.5731869339942932, 0.27154409885406494, -0.3612765371799469, 0.09517797082662582, -0.0986931174993515, -1.0936061143875122, 0.05481443926692009, -0.6018697619438171, 0.5871978998184204, 1.1391236782073975, 1.4432947635650635, -1.0556639432907104, -0.22669000923633575, -1.644964337348938, -0.08113828301429749, -0.7896649837493896, 0.21823126077651978, -1.9583266973495483, -0.15668334066867828, -1.965868353843689, -2.2251174449920654, -1.2741742134094238, -0.9023155570030212, 1.1391862630844116, 0.1258905977010727, -0.9208382368087769, 1.3752732276916504, -0.28702208399772644, -1.7495067119598389, 1.0958558320999146, -2.1503026485443115 ]
https://github.com/huggingface/datasets/issues/5176
prepare dataset for cloud storage doesn't work
It looks like an issue with `gcsfs`, are you able to instantiate a `GCSFileSystem` manually ?
### Describe the bug Following the [documentation](https://huggingface.co/docs/datasets/filesystems#load-and-save-your-datasets-using-your-cloud-storage-filesystem) and [this PR](https://github.com/huggingface/datasets/pull/4724), I was downloading and storing huggingface dataset to cloud storage. ``` from datasets import load_dataset, load_dataset_builder dataset = load_dataset_builder("wikipedia", "20220301.en", cache_dir='LOCAL_PATH') dataset.download_and_prepare("gs://Bucket_NAME", file_format="parquet") ``` The above code successfully downloaded dataset, however, it returns error from `download_and_prepare`. > Traceback (most recent call last): > File "/shared/zhuiai/research/wiki/wiki/gcsfs.py", line 12, in <module> > dataset.download_and_prepare("gs://upgen/dataset/wiki", file_format="parquet") > File "/shared/zhuiai/.conda/envs/wiki/lib/python3.9/site-packages/datasets/builder.py", line 671, in download_and_prepare > fs_token_paths = fsspec.get_fs_token_paths(output_dir, storage_options=storage_options) > File "/shared/zhuiai/.conda/envs/wiki/lib/python3.9/site-packages/fsspec/core.py", line 635, in get_fs_token_paths > cls = get_filesystem_class(protocol) > File "/shared/zhuiai/.conda/envs/wiki/lib/python3.9/site-packages/fsspec/registry.py", line 234, in get_filesystem_class > register_implementation(protocol, _import_class(bit["class"])) > File "/shared/zhuiai/.conda/envs/wiki/lib/python3.9/site-packages/fsspec/registry.py", line 257, in _import_class > mod = importlib.import_module(mod) > File "/shared/zhuiai/.conda/envs/wiki/lib/python3.9/importlib/__init__.py", line 127, in import_module > return _bootstrap._gcd_import(name[level:], package, level) > File "<frozen importlib._bootstrap>", line 1030, in _gcd_import > File "<frozen importlib._bootstrap>", line 1007, in _find_and_load > File "<frozen importlib._bootstrap>", line 986, in _find_and_load_unlocked > File "<frozen importlib._bootstrap>", line 680, in _load_unlocked > File "<frozen importlib._bootstrap_external>", line 850, in exec_module > File "<frozen importlib._bootstrap>", line 228, in _call_with_frames_removed > File "/shared/zhuiai/research/wiki/wiki/gcsfs.py", line 12, in <module> > dataset.download_and_prepare("gs://upgen/dataset/wiki", file_format="parquet") > File "/shared/zhuiai/.conda/envs/wiki/lib/python3.9/site-packages/datasets/builder.py", line 671, in download_and_prepare > fs_token_paths = fsspec.get_fs_token_paths(output_dir, storage_options=storage_options) > File "/shared/zhuiai/.conda/envs/wiki/lib/python3.9/site-packages/fsspec/core.py", line 635, in get_fs_token_paths > cls = get_filesystem_class(protocol) > File "/shared/zhuiai/.conda/envs/wiki/lib/python3.9/site-packages/fsspec/registry.py", line 234, in get_filesystem_class > register_implementation(protocol, _import_class(bit["class"])) > File "/shared/zhuiai/.conda/envs/wiki/lib/python3.9/site-packages/fsspec/registry.py", line 258, in _import_class > return getattr(mod, name) > AttributeError: partially initialized module 'gcsfs' has no attribute 'GCSFileSystem' (most likely due to a circular import) ### Steps to reproduce the bug 1. pip install datasets==2.6.1 gcsfs==2022.8.2 2. Run the following code will reproduce the issue (change `LOCAL_PATH` and `Bucket_NAME` accordingly) ``` from datasets import load_dataset, load_dataset_builder dataset = load_dataset_builder("wikipedia", "20220301.en", cache_dir='LOCAL_PATH') dataset.download_and_prepare("gs://Bucket_NAME", file_format="parquet") ``` ### Expected behavior Expecting successful downloading dataset and uploading it to cloud storage. ### Environment info - `datasets` version: 2.6.1 - Platform: Linux-5.15.0-25-generic-x86_64-with-glibc2.35 - Python version: 3.9.12 - PyArrow version: 7.0.0 - Pandas version: 1.5.1
452
16
prepare dataset for cloud storage doesn't work ### Describe the bug Following the [documentation](https://huggingface.co/docs/datasets/filesystems#load-and-save-your-datasets-using-your-cloud-storage-filesystem) and [this PR](https://github.com/huggingface/datasets/pull/4724), I was downloading and storing huggingface dataset to cloud storage. ``` from datasets import load_dataset, load_dataset_builder dataset = load_dataset_builder("wikipedia", "20220301.en", cache_dir='LOCAL_PATH') dataset.download_and_prepare("gs://Bucket_NAME", file_format="parquet") ``` The above code successfully downloaded dataset, however, it returns error from `download_and_prepare`. > Traceback (most recent call last): > File "/shared/zhuiai/research/wiki/wiki/gcsfs.py", line 12, in <module> > dataset.download_and_prepare("gs://upgen/dataset/wiki", file_format="parquet") > File "/shared/zhuiai/.conda/envs/wiki/lib/python3.9/site-packages/datasets/builder.py", line 671, in download_and_prepare > fs_token_paths = fsspec.get_fs_token_paths(output_dir, storage_options=storage_options) > File "/shared/zhuiai/.conda/envs/wiki/lib/python3.9/site-packages/fsspec/core.py", line 635, in get_fs_token_paths > cls = get_filesystem_class(protocol) > File "/shared/zhuiai/.conda/envs/wiki/lib/python3.9/site-packages/fsspec/registry.py", line 234, in get_filesystem_class > register_implementation(protocol, _import_class(bit["class"])) > File "/shared/zhuiai/.conda/envs/wiki/lib/python3.9/site-packages/fsspec/registry.py", line 257, in _import_class > mod = importlib.import_module(mod) > File "/shared/zhuiai/.conda/envs/wiki/lib/python3.9/importlib/__init__.py", line 127, in import_module > return _bootstrap._gcd_import(name[level:], package, level) > File "<frozen importlib._bootstrap>", line 1030, in _gcd_import > File "<frozen importlib._bootstrap>", line 1007, in _find_and_load > File "<frozen importlib._bootstrap>", line 986, in _find_and_load_unlocked > File "<frozen importlib._bootstrap>", line 680, in _load_unlocked > File "<frozen importlib._bootstrap_external>", line 850, in exec_module > File "<frozen importlib._bootstrap>", line 228, in _call_with_frames_removed > File "/shared/zhuiai/research/wiki/wiki/gcsfs.py", line 12, in <module> > dataset.download_and_prepare("gs://upgen/dataset/wiki", file_format="parquet") > File "/shared/zhuiai/.conda/envs/wiki/lib/python3.9/site-packages/datasets/builder.py", line 671, in download_and_prepare > fs_token_paths = fsspec.get_fs_token_paths(output_dir, storage_options=storage_options) > File "/shared/zhuiai/.conda/envs/wiki/lib/python3.9/site-packages/fsspec/core.py", line 635, in get_fs_token_paths > cls = get_filesystem_class(protocol) > File "/shared/zhuiai/.conda/envs/wiki/lib/python3.9/site-packages/fsspec/registry.py", line 234, in get_filesystem_class > register_implementation(protocol, _import_class(bit["class"])) > File "/shared/zhuiai/.conda/envs/wiki/lib/python3.9/site-packages/fsspec/registry.py", line 258, in _import_class > return getattr(mod, name) > AttributeError: partially initialized module 'gcsfs' has no attribute 'GCSFileSystem' (most likely due to a circular import) ### Steps to reproduce the bug 1. pip install datasets==2.6.1 gcsfs==2022.8.2 2. Run the following code will reproduce the issue (change `LOCAL_PATH` and `Bucket_NAME` accordingly) ``` from datasets import load_dataset, load_dataset_builder dataset = load_dataset_builder("wikipedia", "20220301.en", cache_dir='LOCAL_PATH') dataset.download_and_prepare("gs://Bucket_NAME", file_format="parquet") ``` ### Expected behavior Expecting successful downloading dataset and uploading it to cloud storage. ### Environment info - `datasets` version: 2.6.1 - Platform: Linux-5.15.0-25-generic-x86_64-with-glibc2.35 - Python version: 3.9.12 - PyArrow version: 7.0.0 - Pandas version: 1.5.1 It looks like an issue with `gcsfs`, are you able to instantiate a `GCSFileSystem` manually ?
[ -1.211828589439392, -0.9536420702934265, -0.6595884561538696, 1.417645812034607, -0.06256867945194244, -1.308311104774475, 0.0855645090341568, -1.0362889766693115, 1.502653956413269, -0.7664820551872253, 0.2719387412071228, -1.7306181192398071, -0.14110584557056427, -0.52278071641922, -0.6701040863990784, -0.8827526569366455, -0.3289070427417755, -0.877289354801178, 1.109967589378357, 2.444344997406006, 1.3464809656143188, -1.3056281805038452, 2.7965497970581055, 0.634965181350708, -0.2753666639328003, -0.9713055491447449, 0.5250537395477295, -0.014126741327345371, -1.1943209171295166, -0.46718230843544006, -0.9073188900947571, 0.003289797343313694, -0.5736210346221924, -0.40280798077583313, 0.02282414585351944, 0.4857689440250397, -0.31795448064804077, -0.2665821611881256, -0.6081224083900452, -0.7964950799942017, 0.47777965664863586, -0.2958303987979889, 0.9543138146400452, -0.3310953378677368, 1.7584269046783447, -0.6226634979248047, 0.4605345129966736, 0.670133650302887, 1.260652780532837, 0.2122846096754074, 0.14965954422950745, 0.22314809262752533, 0.3107397258281708, 0.0009644366800785065, 0.5891515612602234, 1.260654330253601, 0.5894472002983093, 0.5428287982940674, 0.6594629883766174, -2.220618486404419, 1.310236930847168, -0.8607730269432068, 0.24263203144073486, 1.320132851600647, -0.7984018325805664, 0.3729879558086395, -1.774189829826355, -0.08386621624231339, 0.6138269305229187, -2.2546536922454834, 0.25118231773376465, -1.3035248517990112, -0.5278809070587158, 0.8847910761833191, 0.34498217701911926, -1.1850885152816772, 0.19656608998775482, -0.5303527116775513, 1.1194663047790527, 0.5027258396148682, 1.0622395277023315, -1.665383219718933, -0.004001406021416187, -0.14423805475234985, 0.07710064947605133, -1.2837166786193848, -1.6819266080856323, 0.5594911575317383, 0.5362009406089783, 0.7160398960113525, -0.09946026653051376, 1.0925296545028687, -1.0539672374725342, 0.7758152484893799, -0.9750955700874329, -1.6105071306228638, -1.3967516422271729, -2.3994648456573486, -2.3373336791992188, 0.7829502820968628, -0.5760338306427002, -0.49149829149246216, 1.9767470359802246, -0.9376811385154724, -1.7839446067810059, 1.0247355699539185, 0.2845871150493622, 0.0855068564414978, 2.3992981910705566, 0.25442394614219666, -0.7821735739707947, 0.5156438946723938, -0.7224537134170532, 0.8395659923553467, -0.25512436032295227, 1.3462746143341064, 0.45672914385795593, -1.0267537832260132, 1.575719952583313, -0.4295932352542877, 0.5808048844337463, -0.6480746865272522, -0.5151643753051758, -0.7609080076217651, 0.22002612054347992, 1.8124771118164062, -0.35506701469421387, 1.6032274961471558, -0.3196480870246887, -1.4941790103912354, -1.631813883781433, 0.8046793937683105, 0.3621138334274292, -0.9100525379180908, 0.06866053491830826, -0.4739152491092682, 0.18015477061271667, 0.006484064273536205, 1.130595088005066, 1.280078411102295, 0.6874697804450989, -0.3427860140800476, -0.7702288031578064, 0.20811636745929718, -0.1580914855003357, -0.5802050232887268, -1.8090697526931763, -0.2939288318157196, 0.1936006098985672, 0.6101933121681213, -1.187785029411316, 1.8094686269760132, 0.9003795981407166, 2.0072851181030273, 0.977737545967102, -0.42446574568748474, 1.4512478113174438, 0.004120981320738792, 1.922088623046875, -0.520871639251709, 0.503505289554596, -0.313321053981781, -1.1678193807601929, 0.9336118698120117, -0.3558029234409332, -2.008701801300049, -0.804868221282959, -0.7719546556472778, -0.19058306515216827, -0.839043378829956, 0.8548416495323181, -0.2781483829021454, -1.4902539253234863, 0.1376950591802597, -0.6879318356513977, 0.18388685584068298, -1.2648305892944336, 0.18376384675502777, 0.7441781163215637, -0.6984911561012268, -0.05283975228667259, -0.24694539606571198, -1.285553216934204, -0.5533052682876587, 0.4037097692489624, 1.9818272590637207, -0.5418757796287537, 0.9358646869659424, 1.084380030632019, -0.7356098890304565, 0.15272891521453857, 0.19034799933433533, -0.25367283821105957, 0.7397276759147644, -1.1021062135696411, -0.424686998128891, 1.2054948806762695, -0.36562371253967285, -0.7386550903320312, 1.41489839553833, 0.7922835350036621, -1.0828717947006226, -0.20912203192710876, -0.17971286177635193, -0.7940101623535156, -0.06147942319512367, -1.4572006464004517, -0.18852747976779938, 0.35141125321388245, -1.4697726964950562, -0.3762202858924866, -0.15091127157211304, 1.3669461011886597, -0.20609118044376373, 1.443758249282837, -0.30198168754577637, -0.12094670534133911, -0.3206599950790405, -0.5327783226966858, 0.17005491256713867, -0.20037831366062164, -0.5298658013343811, 0.21486960351467133, -0.8713700771331787, 0.25603437423706055, 1.51205313205719, 0.32935941219329834, 0.02643226832151413, 0.45401912927627563, 1.1030510663986206, 0.4332413971424103, -0.09570612013339996, -0.8348481059074402, -1.5002906322479248, 2.0172479152679443, -1.4229058027267456, 1.9374637603759766, 0.7095431089401245, -0.10332812368869781, -1.8425779342651367, -1.8481392860412598, 1.277745008468628, 1.1056277751922607, 2.380966901779175, 0.5200373530387878, 0.39918413758277893, -0.7601777911186218, -0.7778626680374146, 0.3423735797405243, -0.9806394577026367, -0.6209077835083008, 0.16983076930046082, 2.3722753524780273, 1.771423101425171, -0.529867947101593, -0.2132452130317688, -0.8581527471542358, 1.2484074831008911, -0.27666983008384705, 0.2910899519920349, 2.015019416809082, -0.36171412467956543, -0.9488128423690796, 1.4061261415481567, -2.419363260269165, 0.2855391800403595, 2.1103515625, 0.2814880907535553, 0.14229315519332886, -1.3528075218200684, -0.6411269903182983, -0.33563244342803955, -0.48120132088661194, -1.221357822418213, 0.530133068561554, -0.26189351081848145, -0.862825334072113, -1.460768699645996, 0.03727421537041664, -1.1528921127319336, -1.7413742542266846, 0.36332350969314575, 1.9262995719909668, 2.0942420959472656, -0.7768492698669434, 1.3977547883987427, -0.29251039028167725, 0.003988400101661682, 1.3143768310546875, 1.4051576852798462, 3.0936636924743652, 1.8622757196426392, -1.2568947076797485, 0.7437674403190613, -0.21511775255203247, -0.49178287386894226, 1.1639204025268555, -1.121325969696045, 1.1618090867996216, -0.23999570310115814, -1.2642743587493896, -1.3248860836029053, 1.0917558670043945, 0.4964986741542816, -0.026167064905166626, -0.5631868839263916, 1.3081614971160889, 0.1688227504491806, 1.3188824653625488, 0.595073938369751, -0.42914918065071106, 0.47463616728782654, -0.34349149465560913, -0.5691382884979248, 1.6389577388763428, 0.19889797270298004, -1.6109919548034668, -2.3075449466705322, -0.2873041033744812, -0.9779846668243408, -0.05015084892511368, -0.6262604594230652, -1.0692015886306763, 1.6401618719100952, 0.4350211024284363, -1.1623811721801758, -0.2892511785030365, -0.3372776210308075, -0.5024774074554443, 2.6986517906188965, -1.2352849245071411, -0.11868232488632202, -0.9159507155418396, -0.5744868516921997, 1.6473313570022583, -1.282569169998169, -0.2521383762359619, -0.972352147102356, -0.7111240029335022, -1.3010724782943726, -0.3631926476955414, 0.06445805728435516, -0.9654113054275513, 0.7218025326728821, 0.15337632596492767, -1.1384109258651733, -0.25776252150535583, -0.914596438407898, 1.106202244758606, -0.17006637156009674, 0.2514815926551819, 1.871107816696167, 0.290290892124176, -0.4780295491218567, 0.7566093802452087, 1.216209053993225, 0.6304881572723389, -0.6548639535903931, 0.03559807687997818, -0.6769722700119019, 0.4065679609775543, -1.4017916917800903, 0.18285101652145386, -2.9706592559814453, 0.7244277596473694, -0.1761213093996048, -0.11913114041090012, -0.07057428359985352, -1.3256901502609253, 1.120352864265442, 2.562445878982544, -1.2232319116592407, 0.45145177841186523, 0.467538446187973, 1.1123003959655762, -1.5769373178482056, 0.2503424286842346, -0.5065534114837646, 2.019019603729248, 0.12483574450016022, 1.1956117153167725, -0.4871692657470703, -2.196096420288086, 0.6576499938964844, -1.214933156967163, -1.0385994911193848, 0.8018262982368469, -0.9465745091438293, 0.3010764718055725, -1.4371126890182495, -0.1306346356868744, -0.9318992495536804, -1.2567301988601685, 0.7023269534111023, 0.05850973725318909, 0.3874921202659607, -0.528912365436554, 0.3697359263896942, -2.1447503566741943, -1.4422621726989746, -0.22405603528022766, -0.9692385196685791, 0.5501625537872314, -0.485930472612381, 0.6509804725646973, -0.10997980833053589, 0.05789615958929062, 0.28254571557044983, 1.4931684732437134, 3.3752427101135254, 0.1292986124753952, 0.18453964591026306, -0.08720265328884125, -1.0436508655548096, 1.5071368217468262, 0.873439371585846, -0.14195144176483154, -0.5129110813140869, -1.007097601890564, 1.3321579694747925, 2.0563430786132812, 1.155198335647583, 0.12741295993328094, -0.8968498110771179, -0.7531123161315918, 0.07728613913059235, 0.18627920746803284, 0.5431908965110779, 0.9644220471382141, -0.021221676841378212, 0.10810025036334991, 1.40250563621521, 1.1718621253967285, -0.2807539701461792, 0.3712001144886017, -0.9816932678222656, -0.4220854341983795, 0.4357357621192932, 0.16504186391830444, 0.06765300035476685, 0.5190563201904297, -1.013548731803894, -0.2896782457828522, -0.3006661832332611, -0.8484491109848022, -0.7393330335617065, -0.374806672334671, -0.4475073516368866, 1.536489486694336, 0.045734044164419174, -0.5481823682785034, 0.07681453227996826, -0.6716126203536987, -0.1746731698513031, -1.1305184364318848, 0.16483831405639648, -0.07733231782913208, -0.05260688066482544, -0.17144723236560822, 1.5882899761199951, -0.9565448760986328, -2.1643059253692627, 0.14110998809337616, 0.34663477540016174, -0.3798898756504059, 0.17371788620948792, 1.7395496368408203, 0.48173850774765015, 1.3841890096664429, 1.2608712911605835, 1.0164772272109985, -0.6016804575920105, -1.212183952331543, 0.7489978075027466, 0.9471505880355835, -1.2971457242965698, 1.0000299215316772, -0.2389894425868988, -0.5267151594161987, 0.6283828020095825, 1.2964670658111572, 0.4428108036518097, -2.000305652618408, 0.8871011734008789, -0.9737222194671631, 0.8610289692878723, 0.6753025054931641, 0.8284755945205688, 0.23452399671077728, 0.9027649760246277, -1.2516511678695679, -1.1103154420852661, -0.6565002799034119, -0.6088998317718506, 1.8346686363220215, -0.25233086943626404, 0.5748547315597534, -0.17467918992042542, -1.211884617805481, -0.1458037942647934, 0.8227173089981079, 0.37864911556243896, -0.4552971422672272, 0.8407527208328247, -0.635689914226532, -0.8989554047584534, -1.2622628211975098, -0.4044148921966553, -1.0844734907150269, -0.9121983051300049, 1.0335743427276611, 0.6773423552513123, 0.47080618143081665, 1.928920865058899, 0.5510883331298828, 0.3801371455192566, -2.690382719039917, 0.8874680995941162, 0.27710479497909546, -0.011069249361753464, 0.9313875436782837, 0.3125326931476593, 1.1611515283584595, -0.03938253968954086, 0.5884233117103577, -2.3048293590545654, 2.1871190071105957, -0.20831000804901123, 0.5811973214149475, 0.06216198205947876, -0.09200010448694229, 1.120421051979065, 0.5962114930152893, 0.5276876091957092, -1.1744780540466309, 0.8085201978683472, -0.5149741172790527, 1.017561435699463, 0.9845521450042725, -0.9187588095664978, 0.12763288617134094, 1.420735239982605, 0.4853341281414032, -0.5102256536483765, -1.0073111057281494, -0.7880054712295532, 1.0279207229614258, 1.608157992362976, -0.027149491012096405, -0.011855419725179672, 0.8423442244529724, 0.6135318279266357, -1.2423843145370483, 0.06681704521179199, -0.5957037806510925, -0.5802704095840454, 1.7059211730957031, 1.955521821975708, -0.1071167066693306, -0.14652636647224426, -0.6576811075210571, -1.309576153755188, 0.7515177130699158, -0.15347307920455933, 0.07779022306203842, 0.6975703239440918, -0.7090916037559509, 1.0384823083877563, 0.5434888005256653, 0.9611270427703857, 0.018391288816928864, 0.30202656984329224, 0.4829403758049011, -0.34001973271369934, -1.1703402996063232, -0.31682637333869934, -1.0756076574325562, -2.637770414352417, 0.34750252962112427, -0.2956366539001465, -1.4217593669891357, 0.010346571914851665, -1.0202867984771729, 0.9343178272247314, -0.5817891955375671, -1.1319085359573364, -1.380739450454712, 0.30749747157096863, -0.08857312798500061, 0.8985006809234619, -1.6267857551574707, -0.26927316188812256, 1.2432069778442383, 0.8507060408592224, -0.625537633895874, 0.9873012900352478, 0.2429368495941162, 1.0077592134475708, 0.7150589227676392, -0.38781610131263733, 0.616059422492981, 0.03631499037146568, -1.313140630722046, 0.410724937915802, 1.2605887651443481, 0.1683005392551422, 1.333371639251709, -0.45781630277633667, 0.06784898787736893, 0.43057960271835327, -0.6179857850074768, -0.5889261960983276, -0.44454851746559143, 0.6163678169250488, -0.061155520379543304, -1.0322632789611816, -0.17604604363441467, -0.12263989448547363, -0.2648863196372986, 0.19900785386562347, -1.4908215999603271, -0.25623834133148193, -0.4683881103992462, -0.42566433548927307, -1.3676832914352417, 0.01867218315601349, 1.3452304601669312, -0.777052640914917, -0.22067628800868988, 0.42076119780540466, 0.29245835542678833, 0.5813416838645935, 0.5258831977844238, -0.7610734701156616, -0.1855994313955307, -0.4116734564304352, -0.29640868306159973, 0.3105100691318512, 1.194608449935913, -0.07684318721294403, -1.000803828239441, 0.6888816356658936, -0.35363584756851196, 0.20178064703941345, 2.0325584411621094, 0.035141393542289734, -0.686038076877594, 0.29243364930152893, -0.7292184233665466, 1.7679375410079956, 1.7032073736190796, 1.3185627460479736, -0.1279200315475464, -0.8013573884963989, 0.5761736035346985, -0.24061505496501923, -0.4047743082046509, 0.8766303658485413, 0.3521043658256531, -0.2916977107524872, -1.4827772378921509, 0.6820239424705505, 1.2573716640472412, -0.7981266379356384, -0.7191862463951111, 0.10965381562709808, -0.8668256998062134, 1.221677303314209, 0.5193489789962769, 0.30523937940597534, 0.32791560888290405, 1.5687944889068604, 0.6900402307510376, -0.4852564334869385, 0.4601444900035858, 0.559212863445282, -0.1690264642238617, -2.0490572452545166, -1.0795303583145142, 0.27871841192245483, -0.47781819105148315, -1.5386157035827637, 1.368074893951416, -1.1566036939620972, -1.0629862546920776, 0.6232346296310425, 0.1725478619337082, 1.3422446250915527, 0.36091169714927673, 1.6765142679214478, 2.131387710571289, 0.8587304949760437, 0.42449086904525757, 1.1735540628433228, -0.06964881718158722, -0.4250963032245636, 1.8379504680633545, -0.3604990541934967, 0.5231205821037292, 1.0427459478378296, -0.4013362228870392, -1.080711007118225, -0.8132635951042175, -1.2339768409729004, -0.6406378149986267, 1.1479510068893433, 0.10788717865943909, -1.0519320964813232, 0.2199029177427292, 1.580190658569336, 0.19979332387447357, -0.23693540692329407, 0.6573191285133362, 0.4571588635444641, -0.7427458167076111, -0.0284196138381958, -0.9362627863883972, 0.5679751634597778, -0.1457502692937851, -0.36954861879348755, 0.21618370711803436, 0.5345907807350159, 1.3638575077056885, -0.02241136133670807, 0.18867774307727814, 1.168241262435913, -1.393856406211853, 1.5193713903427124, -0.6047942042350769, 0.2805643677711487, -2.4088430404663086, 1.3873378038406372, -0.7478564977645874, 1.988403081893921, -2.508850574493408, 0.4249016344547272, -0.5626022815704346, -0.5036006569862366, 0.2916240692138672, -0.4212362468242645, 0.08460059762001038, -0.12132757902145386, -0.9712315797805786, 0.012829423882067204, -0.6486521363258362, 0.6134727597236633, 1.177322506904602, 1.4695541858673096, -1.1214178800582886, -0.324323832988739, -1.7419832944869995, -0.16126768290996552, -0.8259920477867126, 0.31752949953079224, -1.9291199445724487, -0.19558754563331604, -1.961769700050354, -2.4155492782592773, -1.3956066370010376, -0.8346940279006958, 1.0899075269699097, 0.18066757917404175, -0.9889538884162903, 1.3143184185028076, -0.36711686849594116, -1.8292076587677002, 1.1718748807907104, -2.2085371017456055 ]
https://github.com/huggingface/datasets/issues/5162
Pip-compile: Could not find a version that matches dill<0.3.6,>=0.3.6
Thanks for reporting, @Rijgersberg. We were waiting for the release of `dill` 0.3.6, that happened 2 days ago (24 Oct 2022): https://github.com/uqfoundation/dill/releases/tag/dill-0.3.6 - See comment: https://github.com/huggingface/datasets/pull/4397#discussion_r880629543 Also `multiprocess` 0.70.14 was released 2 days ago: https://github.com/uqfoundation/multiprocess/releases/tag/multiprocess-0.70.14 We are addressing this issue to align dependencies.
### Describe the bug When using `pip-compile` (part of `pip-tools`) to generate a pinned requirements file that includes `datasets`, a version conflict of `dill` appears. It is caused by a transitive dependency conflict between `datasets` and `multiprocess`. ### Steps to reproduce the bug ```bash $ echo "datasets" > requirements.in $ pip install pip-tools $ pip-compile requirements.in Could not find a version that matches dill<0.3.6,>=0.3.6 (from datasets==2.6.1->-r requirements.in (line 1)) Tried: 0.2, 0.2, 0.2.1, 0.2.1, 0.2.2, 0.2.2, 0.2.3, 0.2.3, 0.2.4, 0.2.4, 0.2.5, 0.2.5, 0.2.6, 0.2.7, 0.2.7.1, 0.2.8, 0.2.8.1, 0.2.8.2, 0.2.9, 0.3.0, 0.3.1, 0.3.1.1, 0.3.2, 0.3.3, 0.3.3, 0.3.4, 0.3.4, 0.3.5, 0.3.5, 0.3.5.1, 0.3.5.1, 0.3.6, 0.3.6 Skipped pre-versions: 0.1a1, 0.2a1, 0.2a1, 0.2b1, 0.2b1 There are incompatible versions in the resolved dependencies: dill<0.3.6 (from datasets==2.6.1->-r requirements.in (line 1)) dill>=0.3.6 (from multiprocess==0.70.14->datasets==2.6.1->-r requirements.in (line 1)) ``` ### Expected behavior A correctly generated file `requirements.txt` with pinned dependencies ### Environment info Tested with versions `2.6.1, 2.6.0, 2.5.2` on Python 3.8 and 3.10 on Ubuntu 20.04LTS and Python 3.10 on MacOS 12.6 (M1).
453
43
Pip-compile: Could not find a version that matches dill<0.3.6,>=0.3.6 ### Describe the bug When using `pip-compile` (part of `pip-tools`) to generate a pinned requirements file that includes `datasets`, a version conflict of `dill` appears. It is caused by a transitive dependency conflict between `datasets` and `multiprocess`. ### Steps to reproduce the bug ```bash $ echo "datasets" > requirements.in $ pip install pip-tools $ pip-compile requirements.in Could not find a version that matches dill<0.3.6,>=0.3.6 (from datasets==2.6.1->-r requirements.in (line 1)) Tried: 0.2, 0.2, 0.2.1, 0.2.1, 0.2.2, 0.2.2, 0.2.3, 0.2.3, 0.2.4, 0.2.4, 0.2.5, 0.2.5, 0.2.6, 0.2.7, 0.2.7.1, 0.2.8, 0.2.8.1, 0.2.8.2, 0.2.9, 0.3.0, 0.3.1, 0.3.1.1, 0.3.2, 0.3.3, 0.3.3, 0.3.4, 0.3.4, 0.3.5, 0.3.5, 0.3.5.1, 0.3.5.1, 0.3.6, 0.3.6 Skipped pre-versions: 0.1a1, 0.2a1, 0.2a1, 0.2b1, 0.2b1 There are incompatible versions in the resolved dependencies: dill<0.3.6 (from datasets==2.6.1->-r requirements.in (line 1)) dill>=0.3.6 (from multiprocess==0.70.14->datasets==2.6.1->-r requirements.in (line 1)) ``` ### Expected behavior A correctly generated file `requirements.txt` with pinned dependencies ### Environment info Tested with versions `2.6.1, 2.6.0, 2.5.2` on Python 3.8 and 3.10 on Ubuntu 20.04LTS and Python 3.10 on MacOS 12.6 (M1). Thanks for reporting, @Rijgersberg. We were waiting for the release of `dill` 0.3.6, that happened 2 days ago (24 Oct 2022): https://github.com/uqfoundation/dill/releases/tag/dill-0.3.6 - See comment: https://github.com/huggingface/datasets/pull/4397#discussion_r880629543 Also `multiprocess` 0.70.14 was released 2 days ago: https://github.com/uqfoundation/multiprocess/releases/tag/multiprocess-0.70.14 We are addressing this issue to align dependencies.
[ -1.3622589111328125, -0.9922836422920227, -0.5274460911750793, 1.3976248502731323, -0.3468988835811615, -1.1460134983062744, 0.20519761741161346, -1.0062435865402222, 1.7358776330947876, -0.850565493106842, 0.16969817876815796, -1.6603925228118896, 0.05620529130101204, -0.44110459089279175, -0.7543696761131287, -0.8874645829200745, -0.46737003326416016, -0.7041770815849304, 1.1449308395385742, 2.694122076034546, 1.1581649780273438, -1.1769026517868042, 2.5943191051483154, 0.8284828662872314, -0.1743823140859604, -1.023284912109375, 0.6627236008644104, 0.057439129799604416, -1.6104553937911987, -0.34319615364074707, -0.9538134932518005, -0.04065414145588875, -0.5893332958221436, -0.5473847985267639, 0.07907373458147049, 0.1875537782907486, -0.3900400698184967, -0.317271888256073, -0.29686829447746277, -0.8784828782081604, 0.3263193964958191, -0.5046695470809937, 0.9222254753112793, -0.37760528922080994, 1.5930479764938354, -0.5466307997703552, 0.6895872950553894, 0.7051492929458618, 1.120438575744629, 0.18582390248775482, 0.08469367027282715, 0.2443249672651291, 0.5779112577438354, 0.18173103034496307, 0.41330769658088684, 0.9640802145004272, 0.5863842964172363, 0.32117512822151184, 0.5268309712409973, -2.296168327331543, 1.4051107168197632, -0.9020522832870483, 0.23137831687927246, 1.4200687408447266, -0.8605395555496216, 0.2525922358036041, -1.6519140005111694, -0.1317967176437378, 0.6376286149024963, -2.369183301925659, 0.23135608434677124, -1.600452184677124, -0.5310876369476318, 1.0373973846435547, 0.5376781821250916, -1.2035514116287231, 0.09962208569049835, -0.3566227853298187, 0.8403468132019043, 0.48393887281417847, 1.023091435432434, -1.7138752937316895, -0.2786950469017029, -0.3468440771102905, 0.09858331084251404, -1.1236135959625244, -1.4691792726516724, 0.5442855358123779, 0.7176721096038818, 0.5241485238075256, -0.11865203827619553, 0.9512019157409668, -1.0899325609207153, 0.7463595271110535, -1.025275707244873, -1.9130083322525024, -1.4306544065475464, -2.526165246963501, -2.3776803016662598, 0.6363195776939392, -0.3829614222049713, -0.4131409823894501, 2.066293478012085, -1.162628173828125, -1.6019268035888672, 1.1301603317260742, 0.2145645171403885, -0.14679265022277832, 2.3830740451812744, 0.09672955423593521, -0.5392563343048096, 0.46273550391197205, -1.075332760810852, 0.5793530941009521, -0.3385748863220215, 1.36423921585083, 0.3918163776397705, -1.076092004776001, 1.3976328372955322, -0.3694542348384857, 0.5774132013320923, -0.6466865539550781, -0.271750807762146, -0.7456673979759216, 0.13974542915821075, 1.8690522909164429, -0.17478834092617035, 1.4124122858047485, -0.1509549468755722, -1.5060547590255737, -1.611313819885254, 0.839565098285675, 0.6080676913261414, -0.6507804989814758, 0.05559520795941353, -0.25685304403305054, 0.14921307563781738, 0.04658758267760277, 1.0644689798355103, 1.3922981023788452, 0.9060071110725403, -0.33921942114830017, -0.9229914546012878, 0.26849138736724854, -0.25591427087783813, -0.8630165457725525, -1.7783589363098145, -0.3476572036743164, -0.03681977838277817, 0.756233274936676, -1.146751880645752, 1.686220407485962, 1.0019066333770752, 1.8974510431289673, 1.0097318887710571, -0.5702629089355469, 1.5414073467254639, 0.22625496983528137, 1.7655366659164429, -0.5121452212333679, 0.9055873155593872, -0.5547932386398315, -1.1210793256759644, 0.8953616619110107, -0.21842101216316223, -2.006253957748413, -0.5192911624908447, -0.811434805393219, -0.2570916414260864, -0.7309942841529846, 1.1025294065475464, -0.12466167658567429, -1.4539605379104614, 0.28764715790748596, -0.8110990524291992, -0.037779975682497025, -1.2656536102294922, 0.43629714846611023, 0.7739757895469666, -0.5116866230964661, 0.09382563829421997, -0.2965143918991089, -1.248829960823059, -0.4421407878398895, 0.27810582518577576, 1.6671980619430542, -0.6219797134399414, 1.1501942873001099, 0.9750794768333435, -0.7490946054458618, -0.09989172220230103, 0.5519524216651917, -0.3100857138633728, 0.8077201247215271, -0.8194859623908997, -0.22794197499752045, 1.2914085388183594, -0.3100031316280365, -0.5546873211860657, 1.5810108184814453, 0.6632882952690125, -0.8890175223350525, -0.1417868733406067, -0.1000155359506607, -0.5369495749473572, 0.20050667226314545, -1.7311172485351562, -0.10736232995986938, 0.44030386209487915, -1.7247503995895386, -0.5934249758720398, -0.23698167502880096, 1.42189621925354, 0.07452329248189926, 1.412320852279663, -0.14540283381938934, -0.22448168694972992, -0.5941756367683411, -0.1887361854314804, 0.1951797902584076, -0.10802184045314789, -0.40503737330436707, 0.5184178948402405, -0.9074258804321289, 0.36977723240852356, 1.5312418937683105, 0.19383077323436737, 0.1194813922047615, 0.453125923871994, 0.7477026581764221, 0.41583871841430664, -0.276899516582489, -0.9308000206947327, -1.6268032789230347, 2.147270679473877, -1.3858230113983154, 1.9775021076202393, 0.7194837331771851, -0.08294978737831116, -1.6348507404327393, -2.0633132457733154, 1.2876585721969604, 0.8610880970954895, 2.3650271892547607, 0.5433031916618347, 0.4502410888671875, -0.7498788833618164, -0.6022669076919556, 0.25743567943573, -0.9595720767974854, -0.9433370232582092, 0.08247634768486023, 2.4338347911834717, 1.5302367210388184, -0.4832870066165924, -0.06154150888323784, -1.3291144371032715, 1.4610079526901245, -0.051465559750795364, 0.22771599888801575, 1.920546293258667, -0.24671408534049988, -1.027251958847046, 1.2485368251800537, -2.2584388256073, 0.18726645410060883, 1.939117431640625, 0.11858726292848587, 0.10943352431058884, -1.5499794483184814, -0.7428646683692932, -0.3426925241947174, -0.5976605415344238, -1.2157986164093018, 0.6637208461761475, -0.21579882502555847, -0.9650245308876038, -1.6125277280807495, 0.10343575477600098, -1.0793143510818481, -1.929896593093872, 0.08326778560876846, 1.787207841873169, 1.9489257335662842, -0.6910820603370667, 1.4809494018554688, -0.16801171004772186, 0.05561001971364021, 1.098621129989624, 1.1353555917739868, 3.036555290222168, 2.218477725982666, -1.2128938436508179, 0.8631724119186401, -0.1739351749420166, -0.30632656812667847, 1.1018630266189575, -1.2304129600524902, 1.4325088262557983, -0.16721758246421814, -1.229761004447937, -1.2292717695236206, 0.9687612652778625, 0.4191111624240875, 0.07228973507881165, -0.3396860659122467, 1.1885730028152466, 0.16026312112808228, 1.3271511793136597, 0.4628300964832306, -0.06471648812294006, 0.8299552798271179, -0.5633025765419006, -0.3456045091152191, 1.6203349828720093, 0.31832313537597656, -1.515622854232788, -2.3688578605651855, -0.40148603916168213, -0.9449655413627625, -0.04374752938747406, -0.5245528817176819, -0.9128690958023071, 1.690330147743225, 0.4970826506614685, -1.006011962890625, -0.09206531196832657, -0.3387126624584198, -0.5926843881607056, 2.721383810043335, -1.2416104078292847, -0.18154221773147583, -0.9732277393341064, -0.717239499092102, 1.3209969997406006, -1.3264081478118896, 0.0875438004732132, -0.9569541215896606, -0.47714877128601074, -1.2571079730987549, -0.4012950658798218, -0.07940424233675003, -1.0465610027313232, 0.7481671571731567, 0.15746189653873444, -1.260959267616272, -0.4746319353580475, -0.9836427569389343, 0.8420743942260742, 0.3630317151546478, 0.16218271851539612, 1.8428759574890137, 0.23337912559509277, -0.29320797324180603, 0.6691388487815857, 1.0380303859710693, 0.6795694828033447, -0.6100386381149292, 0.4016200006008148, -0.6797950863838196, 0.46956443786621094, -1.040574312210083, 0.28872549533843994, -2.6358482837677, 0.6299141645431519, -0.1449047029018402, -0.17031000554561615, -0.14193277060985565, -1.151300311088562, 1.303179383277893, 2.5099589824676514, -1.1242702007293701, 0.6464046835899353, 0.0684928148984909, 1.151046633720398, -1.255012035369873, 0.4359404444694519, -0.4876823127269745, 2.265202045440674, 0.3168482184410095, 1.0700191259384155, -0.342532217502594, -2.3611087799072266, 0.7832245230674744, -1.2485312223434448, -1.0619382858276367, 0.6671330332756042, -0.8502208590507507, -0.13775360584259033, -1.1915148496627808, -0.0907202959060669, -0.7104968428611755, -1.168436884880066, 0.5448334813117981, 0.20993950963020325, 0.6930842995643616, -0.7174537181854248, 0.47738349437713623, -2.3124682903289795, -1.1722544431686401, -0.3538472652435303, -0.8958349227905273, 0.452816903591156, -0.24455581605434418, 0.7200703620910645, -0.17384377121925354, -0.17897988855838776, 0.4788513779640198, 1.3517968654632568, 3.370823860168457, -0.1436682641506195, 0.31396010518074036, -0.12829171121120453, -1.2033672332763672, 1.3970593214035034, 1.018837809562683, -0.11670354008674622, -0.648749589920044, -1.1352384090423584, 1.1475780010223389, 1.9567646980285645, 1.0995796918869019, 0.046978794038295746, -0.9245196580886841, -0.842889666557312, 0.05935775116086006, 0.12541702389717102, 0.45713070034980774, 1.029491662979126, 0.04747669771313667, 0.025897923856973648, 1.6973198652267456, 1.251818060874939, -0.15461456775665283, 0.3221144378185272, -0.7892493605613708, -0.4588780701160431, 0.5941370725631714, 0.4388326108455658, 0.021985948085784912, 0.450618177652359, -1.2010167837142944, -0.10635898262262344, -0.22828471660614014, -0.8913403749465942, -0.7922815084457397, -0.3957439363002777, -0.4120582640171051, 1.7339494228363037, 0.021760806441307068, -0.3985050618648529, 0.008006355725228786, -0.8638803958892822, 0.09557434171438217, -0.8813031911849976, 0.3449828028678894, -0.2107221484184265, 0.03555523604154587, -0.17516982555389404, 1.8320727348327637, -0.9755390882492065, -1.9785810708999634, 0.30476289987564087, -0.00244034081697464, -0.344519704580307, 0.4432077407836914, 1.4888709783554077, 0.816572904586792, 1.52592933177948, 1.2030394077301025, 0.9790661931037903, -0.5043098330497742, -1.4776817560195923, 0.7580454349517822, 0.8834365010261536, -1.4273054599761963, 0.7604292035102844, 0.06725328415632248, -0.4837011992931366, 0.5564436316490173, 1.0715692043304443, 0.3209189176559448, -2.069270372390747, 0.7769496440887451, -0.8893901705741882, 0.8351265788078308, 0.6724205613136292, 0.7274817824363708, 0.035153117030858994, 0.6643079519271851, -1.4007445573806763, -0.8528180122375488, -0.5154282450675964, -0.6669705510139465, 2.0623021125793457, -0.18689370155334473, 0.7034817337989807, -0.3868529200553894, -1.2779181003570557, -0.04108346253633499, 0.4757504165172577, 0.3151402175426483, -0.5295945405960083, 0.8463407754898071, -0.5711972117424011, -1.3495087623596191, -1.3454177379608154, -0.5904005169868469, -1.0796127319335938, -0.8008851408958435, 1.0303339958190918, 0.6252337098121643, 0.5196950435638428, 1.815671443939209, 0.3281685411930084, 0.30242738127708435, -2.8043999671936035, 0.8769140839576721, 0.23459632694721222, -0.08770400285720825, 0.8567519187927246, 0.14588035643100739, 1.0348149538040161, -0.2986685633659363, 0.6807690262794495, -2.290492534637451, 2.469693422317505, -0.23265813291072845, 0.752415120601654, 0.28819477558135986, 0.19531001150608063, 0.9618722796440125, 0.7754167914390564, 0.6284632682800293, -1.0495086908340454, 0.6597902178764343, -0.7430878281593323, 1.5218688249588013, 0.8662071228027344, -0.7861256003379822, -0.26277956366539, 1.160853385925293, 0.4206971228122711, -0.31276944279670715, -0.8797075748443604, -1.1730587482452393, 0.8172687888145447, 1.7807706594467163, -0.3106401264667511, 0.051265887916088104, 0.6718621850013733, 0.6678621768951416, -1.4381831884384155, -0.12815561890602112, -0.818310022354126, -0.4866514503955841, 1.484183669090271, 2.2434911727905273, -0.04053427278995514, -0.2346123605966568, -0.6739328503608704, -1.2282110452651978, 0.681393563747406, 0.0695979967713356, 0.09172063320875168, 0.6504455804824829, -0.36904048919677734, 0.9412227869033813, 0.8725538849830627, 1.0880166292190552, 0.39783379435539246, 0.22349010407924652, 0.16614201664924622, -0.5303272604942322, -1.1310665607452393, -0.3121912479400635, -0.8274590373039246, -2.680712938308716, 0.46807560324668884, -0.23849225044250488, -1.5189086198806763, -0.0816105380654335, -1.0962772369384766, 0.7407214045524597, -0.4829705059528351, -1.0061697959899902, -1.3537002801895142, 0.050090108066797256, -0.22806091606616974, 1.0384292602539062, -1.6827901601791382, 0.04800033941864967, 1.3538926839828491, 0.9117183089256287, -0.5620627403259277, 1.188423991203308, 0.2954297959804535, 1.1083368062973022, 0.8988209366798401, -0.28014934062957764, 0.5749132037162781, 0.20584836602210999, -1.2748160362243652, 0.2752784788608551, 1.1520107984542847, 0.33177417516708374, 1.3197314739227295, -0.9864233136177063, 0.090866819024086, 0.39009448885917664, -0.506095290184021, -0.532006561756134, -0.48676958680152893, 0.7722318172454834, 0.15802069008350372, -0.9852392673492432, 0.05625561252236366, -0.15575428307056427, 0.10926966369152069, 0.09183666110038757, -1.3535555601119995, -0.029099415987730026, -0.28927478194236755, -0.6047630310058594, -1.3206232786178589, -0.19102099537849426, 1.3734455108642578, -0.8900806903839111, 0.018142573535442352, 0.33670884370803833, 0.18828724324703217, 0.6702707409858704, 0.7345815300941467, -0.6735361218452454, -0.5830049514770508, -0.2598470151424408, -0.2714965343475342, 0.423052579164505, 1.4318950176239014, -0.08659055829048157, -1.0192378759384155, 0.7238415479660034, -0.4200945198535919, 0.20868238806724548, 1.9535863399505615, -0.08206035196781158, -0.8570833802223206, 0.3169024586677551, -0.4686363637447357, 1.807293176651001, 1.5463606119155884, 1.208766222000122, -0.21331270039081573, -0.9618432521820068, 0.4449727535247803, -0.3971536457538605, -0.505216658115387, 0.7880185842514038, 0.43148308992385864, -0.32493558526039124, -1.2160115242004395, 0.5349754691123962, 1.2975704669952393, -0.982891321182251, -0.9131126403808594, 0.2865743041038513, -0.7481915950775146, 1.1329399347305298, 0.8499515056610107, 0.5531738996505737, 0.25060781836509705, 1.5824356079101562, 0.8787041306495667, -0.7000696063041687, 0.5795252919197083, 0.23579126596450806, -0.253745973110199, -2.001652717590332, -1.1104542016983032, 0.25150108337402344, -0.6998693346977234, -1.509232521057129, 1.2917604446411133, -1.310678482055664, -0.8920603394508362, 0.5625595450401306, 0.22152486443519592, 1.3754030466079712, 0.39716821908950806, 1.4936740398406982, 2.1273746490478516, 1.047629475593567, 0.5512422919273376, 1.4388537406921387, -0.2958129644393921, -0.5751442313194275, 1.5636615753173828, -0.35759052634239197, 0.5069490075111389, 1.1988646984100342, -0.2368486076593399, -0.727756142616272, -0.908080518245697, -1.0672111511230469, -0.5554324388504028, 1.2581678628921509, 0.19563362002372742, -1.072145938873291, 0.21918897330760956, 1.4384195804595947, -0.08150217682123184, -0.1735439896583557, 0.68581622838974, 0.38650548458099365, -0.7155990600585938, -0.10948890447616577, -0.9725998044013977, 0.4771629869937897, -0.5043083429336548, -0.45346590876579285, 0.3011980652809143, 0.2853626608848572, 1.2547520399093628, -0.0815587192773819, 0.18986330926418304, 1.2683192491531372, -1.1395883560180664, 1.6045256853103638, -0.6877118349075317, 0.21087278425693512, -2.1373956203460693, 1.2092641592025757, -0.8738805651664734, 1.7929941415786743, -2.7874820232391357, 0.30239760875701904, -0.35964345932006836, -0.5050965547561646, 0.16630855202674866, -0.3364744186401367, 0.13653777539730072, -0.3842776417732239, -1.2182387113571167, -0.12400287389755249, -0.8180031776428223, 0.37111249566078186, 0.9245210289955139, 1.3707072734832764, -1.1377477645874023, -0.28119033575057983, -1.9103351831436157, -0.09528620541095734, -0.8089903593063354, 0.45652541518211365, -1.8363450765609741, -0.34727033972740173, -1.7794452905654907, -2.423692464828491, -1.2223769426345825, -0.933836817741394, 1.1718870401382446, -0.15981532633304596, -0.5349230766296387, 1.031390905380249, -0.2196476012468338, -1.986266016960144, 1.032730221748352, -2.2616939544677734 ]
https://github.com/huggingface/datasets/issues/5162
Pip-compile: Could not find a version that matches dill<0.3.6,>=0.3.6
In your specific setup, I guess the compatible configuration is with `multiprocess` 0.70.13 (instead of 0.70.14).
### Describe the bug When using `pip-compile` (part of `pip-tools`) to generate a pinned requirements file that includes `datasets`, a version conflict of `dill` appears. It is caused by a transitive dependency conflict between `datasets` and `multiprocess`. ### Steps to reproduce the bug ```bash $ echo "datasets" > requirements.in $ pip install pip-tools $ pip-compile requirements.in Could not find a version that matches dill<0.3.6,>=0.3.6 (from datasets==2.6.1->-r requirements.in (line 1)) Tried: 0.2, 0.2, 0.2.1, 0.2.1, 0.2.2, 0.2.2, 0.2.3, 0.2.3, 0.2.4, 0.2.4, 0.2.5, 0.2.5, 0.2.6, 0.2.7, 0.2.7.1, 0.2.8, 0.2.8.1, 0.2.8.2, 0.2.9, 0.3.0, 0.3.1, 0.3.1.1, 0.3.2, 0.3.3, 0.3.3, 0.3.4, 0.3.4, 0.3.5, 0.3.5, 0.3.5.1, 0.3.5.1, 0.3.6, 0.3.6 Skipped pre-versions: 0.1a1, 0.2a1, 0.2a1, 0.2b1, 0.2b1 There are incompatible versions in the resolved dependencies: dill<0.3.6 (from datasets==2.6.1->-r requirements.in (line 1)) dill>=0.3.6 (from multiprocess==0.70.14->datasets==2.6.1->-r requirements.in (line 1)) ``` ### Expected behavior A correctly generated file `requirements.txt` with pinned dependencies ### Environment info Tested with versions `2.6.1, 2.6.0, 2.5.2` on Python 3.8 and 3.10 on Ubuntu 20.04LTS and Python 3.10 on MacOS 12.6 (M1).
453
16
Pip-compile: Could not find a version that matches dill<0.3.6,>=0.3.6 ### Describe the bug When using `pip-compile` (part of `pip-tools`) to generate a pinned requirements file that includes `datasets`, a version conflict of `dill` appears. It is caused by a transitive dependency conflict between `datasets` and `multiprocess`. ### Steps to reproduce the bug ```bash $ echo "datasets" > requirements.in $ pip install pip-tools $ pip-compile requirements.in Could not find a version that matches dill<0.3.6,>=0.3.6 (from datasets==2.6.1->-r requirements.in (line 1)) Tried: 0.2, 0.2, 0.2.1, 0.2.1, 0.2.2, 0.2.2, 0.2.3, 0.2.3, 0.2.4, 0.2.4, 0.2.5, 0.2.5, 0.2.6, 0.2.7, 0.2.7.1, 0.2.8, 0.2.8.1, 0.2.8.2, 0.2.9, 0.3.0, 0.3.1, 0.3.1.1, 0.3.2, 0.3.3, 0.3.3, 0.3.4, 0.3.4, 0.3.5, 0.3.5, 0.3.5.1, 0.3.5.1, 0.3.6, 0.3.6 Skipped pre-versions: 0.1a1, 0.2a1, 0.2a1, 0.2b1, 0.2b1 There are incompatible versions in the resolved dependencies: dill<0.3.6 (from datasets==2.6.1->-r requirements.in (line 1)) dill>=0.3.6 (from multiprocess==0.70.14->datasets==2.6.1->-r requirements.in (line 1)) ``` ### Expected behavior A correctly generated file `requirements.txt` with pinned dependencies ### Environment info Tested with versions `2.6.1, 2.6.0, 2.5.2` on Python 3.8 and 3.10 on Ubuntu 20.04LTS and Python 3.10 on MacOS 12.6 (M1). In your specific setup, I guess the compatible configuration is with `multiprocess` 0.70.13 (instead of 0.70.14).
[ -1.3622589111328125, -0.9922836422920227, -0.5274460911750793, 1.3976248502731323, -0.3468988835811615, -1.1460134983062744, 0.20519761741161346, -1.0062435865402222, 1.7358776330947876, -0.850565493106842, 0.16969817876815796, -1.6603925228118896, 0.05620529130101204, -0.44110459089279175, -0.7543696761131287, -0.8874645829200745, -0.46737003326416016, -0.7041770815849304, 1.1449308395385742, 2.694122076034546, 1.1581649780273438, -1.1769026517868042, 2.5943191051483154, 0.8284828662872314, -0.1743823140859604, -1.023284912109375, 0.6627236008644104, 0.057439129799604416, -1.6104553937911987, -0.34319615364074707, -0.9538134932518005, -0.04065414145588875, -0.5893332958221436, -0.5473847985267639, 0.07907373458147049, 0.1875537782907486, -0.3900400698184967, -0.317271888256073, -0.29686829447746277, -0.8784828782081604, 0.3263193964958191, -0.5046695470809937, 0.9222254753112793, -0.37760528922080994, 1.5930479764938354, -0.5466307997703552, 0.6895872950553894, 0.7051492929458618, 1.120438575744629, 0.18582390248775482, 0.08469367027282715, 0.2443249672651291, 0.5779112577438354, 0.18173103034496307, 0.41330769658088684, 0.9640802145004272, 0.5863842964172363, 0.32117512822151184, 0.5268309712409973, -2.296168327331543, 1.4051107168197632, -0.9020522832870483, 0.23137831687927246, 1.4200687408447266, -0.8605395555496216, 0.2525922358036041, -1.6519140005111694, -0.1317967176437378, 0.6376286149024963, -2.369183301925659, 0.23135608434677124, -1.600452184677124, -0.5310876369476318, 1.0373973846435547, 0.5376781821250916, -1.2035514116287231, 0.09962208569049835, -0.3566227853298187, 0.8403468132019043, 0.48393887281417847, 1.023091435432434, -1.7138752937316895, -0.2786950469017029, -0.3468440771102905, 0.09858331084251404, -1.1236135959625244, -1.4691792726516724, 0.5442855358123779, 0.7176721096038818, 0.5241485238075256, -0.11865203827619553, 0.9512019157409668, -1.0899325609207153, 0.7463595271110535, -1.025275707244873, -1.9130083322525024, -1.4306544065475464, -2.526165246963501, -2.3776803016662598, 0.6363195776939392, -0.3829614222049713, -0.4131409823894501, 2.066293478012085, -1.162628173828125, -1.6019268035888672, 1.1301603317260742, 0.2145645171403885, -0.14679265022277832, 2.3830740451812744, 0.09672955423593521, -0.5392563343048096, 0.46273550391197205, -1.075332760810852, 0.5793530941009521, -0.3385748863220215, 1.36423921585083, 0.3918163776397705, -1.076092004776001, 1.3976328372955322, -0.3694542348384857, 0.5774132013320923, -0.6466865539550781, -0.271750807762146, -0.7456673979759216, 0.13974542915821075, 1.8690522909164429, -0.17478834092617035, 1.4124122858047485, -0.1509549468755722, -1.5060547590255737, -1.611313819885254, 0.839565098285675, 0.6080676913261414, -0.6507804989814758, 0.05559520795941353, -0.25685304403305054, 0.14921307563781738, 0.04658758267760277, 1.0644689798355103, 1.3922981023788452, 0.9060071110725403, -0.33921942114830017, -0.9229914546012878, 0.26849138736724854, -0.25591427087783813, -0.8630165457725525, -1.7783589363098145, -0.3476572036743164, -0.03681977838277817, 0.756233274936676, -1.146751880645752, 1.686220407485962, 1.0019066333770752, 1.8974510431289673, 1.0097318887710571, -0.5702629089355469, 1.5414073467254639, 0.22625496983528137, 1.7655366659164429, -0.5121452212333679, 0.9055873155593872, -0.5547932386398315, -1.1210793256759644, 0.8953616619110107, -0.21842101216316223, -2.006253957748413, -0.5192911624908447, -0.811434805393219, -0.2570916414260864, -0.7309942841529846, 1.1025294065475464, -0.12466167658567429, -1.4539605379104614, 0.28764715790748596, -0.8110990524291992, -0.037779975682497025, -1.2656536102294922, 0.43629714846611023, 0.7739757895469666, -0.5116866230964661, 0.09382563829421997, -0.2965143918991089, -1.248829960823059, -0.4421407878398895, 0.27810582518577576, 1.6671980619430542, -0.6219797134399414, 1.1501942873001099, 0.9750794768333435, -0.7490946054458618, -0.09989172220230103, 0.5519524216651917, -0.3100857138633728, 0.8077201247215271, -0.8194859623908997, -0.22794197499752045, 1.2914085388183594, -0.3100031316280365, -0.5546873211860657, 1.5810108184814453, 0.6632882952690125, -0.8890175223350525, -0.1417868733406067, -0.1000155359506607, -0.5369495749473572, 0.20050667226314545, -1.7311172485351562, -0.10736232995986938, 0.44030386209487915, -1.7247503995895386, -0.5934249758720398, -0.23698167502880096, 1.42189621925354, 0.07452329248189926, 1.412320852279663, -0.14540283381938934, -0.22448168694972992, -0.5941756367683411, -0.1887361854314804, 0.1951797902584076, -0.10802184045314789, -0.40503737330436707, 0.5184178948402405, -0.9074258804321289, 0.36977723240852356, 1.5312418937683105, 0.19383077323436737, 0.1194813922047615, 0.453125923871994, 0.7477026581764221, 0.41583871841430664, -0.276899516582489, -0.9308000206947327, -1.6268032789230347, 2.147270679473877, -1.3858230113983154, 1.9775021076202393, 0.7194837331771851, -0.08294978737831116, -1.6348507404327393, -2.0633132457733154, 1.2876585721969604, 0.8610880970954895, 2.3650271892547607, 0.5433031916618347, 0.4502410888671875, -0.7498788833618164, -0.6022669076919556, 0.25743567943573, -0.9595720767974854, -0.9433370232582092, 0.08247634768486023, 2.4338347911834717, 1.5302367210388184, -0.4832870066165924, -0.06154150888323784, -1.3291144371032715, 1.4610079526901245, -0.051465559750795364, 0.22771599888801575, 1.920546293258667, -0.24671408534049988, -1.027251958847046, 1.2485368251800537, -2.2584388256073, 0.18726645410060883, 1.939117431640625, 0.11858726292848587, 0.10943352431058884, -1.5499794483184814, -0.7428646683692932, -0.3426925241947174, -0.5976605415344238, -1.2157986164093018, 0.6637208461761475, -0.21579882502555847, -0.9650245308876038, -1.6125277280807495, 0.10343575477600098, -1.0793143510818481, -1.929896593093872, 0.08326778560876846, 1.787207841873169, 1.9489257335662842, -0.6910820603370667, 1.4809494018554688, -0.16801171004772186, 0.05561001971364021, 1.098621129989624, 1.1353555917739868, 3.036555290222168, 2.218477725982666, -1.2128938436508179, 0.8631724119186401, -0.1739351749420166, -0.30632656812667847, 1.1018630266189575, -1.2304129600524902, 1.4325088262557983, -0.16721758246421814, -1.229761004447937, -1.2292717695236206, 0.9687612652778625, 0.4191111624240875, 0.07228973507881165, -0.3396860659122467, 1.1885730028152466, 0.16026312112808228, 1.3271511793136597, 0.4628300964832306, -0.06471648812294006, 0.8299552798271179, -0.5633025765419006, -0.3456045091152191, 1.6203349828720093, 0.31832313537597656, -1.515622854232788, -2.3688578605651855, -0.40148603916168213, -0.9449655413627625, -0.04374752938747406, -0.5245528817176819, -0.9128690958023071, 1.690330147743225, 0.4970826506614685, -1.006011962890625, -0.09206531196832657, -0.3387126624584198, -0.5926843881607056, 2.721383810043335, -1.2416104078292847, -0.18154221773147583, -0.9732277393341064, -0.717239499092102, 1.3209969997406006, -1.3264081478118896, 0.0875438004732132, -0.9569541215896606, -0.47714877128601074, -1.2571079730987549, -0.4012950658798218, -0.07940424233675003, -1.0465610027313232, 0.7481671571731567, 0.15746189653873444, -1.260959267616272, -0.4746319353580475, -0.9836427569389343, 0.8420743942260742, 0.3630317151546478, 0.16218271851539612, 1.8428759574890137, 0.23337912559509277, -0.29320797324180603, 0.6691388487815857, 1.0380303859710693, 0.6795694828033447, -0.6100386381149292, 0.4016200006008148, -0.6797950863838196, 0.46956443786621094, -1.040574312210083, 0.28872549533843994, -2.6358482837677, 0.6299141645431519, -0.1449047029018402, -0.17031000554561615, -0.14193277060985565, -1.151300311088562, 1.303179383277893, 2.5099589824676514, -1.1242702007293701, 0.6464046835899353, 0.0684928148984909, 1.151046633720398, -1.255012035369873, 0.4359404444694519, -0.4876823127269745, 2.265202045440674, 0.3168482184410095, 1.0700191259384155, -0.342532217502594, -2.3611087799072266, 0.7832245230674744, -1.2485312223434448, -1.0619382858276367, 0.6671330332756042, -0.8502208590507507, -0.13775360584259033, -1.1915148496627808, -0.0907202959060669, -0.7104968428611755, -1.168436884880066, 0.5448334813117981, 0.20993950963020325, 0.6930842995643616, -0.7174537181854248, 0.47738349437713623, -2.3124682903289795, -1.1722544431686401, -0.3538472652435303, -0.8958349227905273, 0.452816903591156, -0.24455581605434418, 0.7200703620910645, -0.17384377121925354, -0.17897988855838776, 0.4788513779640198, 1.3517968654632568, 3.370823860168457, -0.1436682641506195, 0.31396010518074036, -0.12829171121120453, -1.2033672332763672, 1.3970593214035034, 1.018837809562683, -0.11670354008674622, -0.648749589920044, -1.1352384090423584, 1.1475780010223389, 1.9567646980285645, 1.0995796918869019, 0.046978794038295746, -0.9245196580886841, -0.842889666557312, 0.05935775116086006, 0.12541702389717102, 0.45713070034980774, 1.029491662979126, 0.04747669771313667, 0.025897923856973648, 1.6973198652267456, 1.251818060874939, -0.15461456775665283, 0.3221144378185272, -0.7892493605613708, -0.4588780701160431, 0.5941370725631714, 0.4388326108455658, 0.021985948085784912, 0.450618177652359, -1.2010167837142944, -0.10635898262262344, -0.22828471660614014, -0.8913403749465942, -0.7922815084457397, -0.3957439363002777, -0.4120582640171051, 1.7339494228363037, 0.021760806441307068, -0.3985050618648529, 0.008006355725228786, -0.8638803958892822, 0.09557434171438217, -0.8813031911849976, 0.3449828028678894, -0.2107221484184265, 0.03555523604154587, -0.17516982555389404, 1.8320727348327637, -0.9755390882492065, -1.9785810708999634, 0.30476289987564087, -0.00244034081697464, -0.344519704580307, 0.4432077407836914, 1.4888709783554077, 0.816572904586792, 1.52592933177948, 1.2030394077301025, 0.9790661931037903, -0.5043098330497742, -1.4776817560195923, 0.7580454349517822, 0.8834365010261536, -1.4273054599761963, 0.7604292035102844, 0.06725328415632248, -0.4837011992931366, 0.5564436316490173, 1.0715692043304443, 0.3209189176559448, -2.069270372390747, 0.7769496440887451, -0.8893901705741882, 0.8351265788078308, 0.6724205613136292, 0.7274817824363708, 0.035153117030858994, 0.6643079519271851, -1.4007445573806763, -0.8528180122375488, -0.5154282450675964, -0.6669705510139465, 2.0623021125793457, -0.18689370155334473, 0.7034817337989807, -0.3868529200553894, -1.2779181003570557, -0.04108346253633499, 0.4757504165172577, 0.3151402175426483, -0.5295945405960083, 0.8463407754898071, -0.5711972117424011, -1.3495087623596191, -1.3454177379608154, -0.5904005169868469, -1.0796127319335938, -0.8008851408958435, 1.0303339958190918, 0.6252337098121643, 0.5196950435638428, 1.815671443939209, 0.3281685411930084, 0.30242738127708435, -2.8043999671936035, 0.8769140839576721, 0.23459632694721222, -0.08770400285720825, 0.8567519187927246, 0.14588035643100739, 1.0348149538040161, -0.2986685633659363, 0.6807690262794495, -2.290492534637451, 2.469693422317505, -0.23265813291072845, 0.752415120601654, 0.28819477558135986, 0.19531001150608063, 0.9618722796440125, 0.7754167914390564, 0.6284632682800293, -1.0495086908340454, 0.6597902178764343, -0.7430878281593323, 1.5218688249588013, 0.8662071228027344, -0.7861256003379822, -0.26277956366539, 1.160853385925293, 0.4206971228122711, -0.31276944279670715, -0.8797075748443604, -1.1730587482452393, 0.8172687888145447, 1.7807706594467163, -0.3106401264667511, 0.051265887916088104, 0.6718621850013733, 0.6678621768951416, -1.4381831884384155, -0.12815561890602112, -0.818310022354126, -0.4866514503955841, 1.484183669090271, 2.2434911727905273, -0.04053427278995514, -0.2346123605966568, -0.6739328503608704, -1.2282110452651978, 0.681393563747406, 0.0695979967713356, 0.09172063320875168, 0.6504455804824829, -0.36904048919677734, 0.9412227869033813, 0.8725538849830627, 1.0880166292190552, 0.39783379435539246, 0.22349010407924652, 0.16614201664924622, -0.5303272604942322, -1.1310665607452393, -0.3121912479400635, -0.8274590373039246, -2.680712938308716, 0.46807560324668884, -0.23849225044250488, -1.5189086198806763, -0.0816105380654335, -1.0962772369384766, 0.7407214045524597, -0.4829705059528351, -1.0061697959899902, -1.3537002801895142, 0.050090108066797256, -0.22806091606616974, 1.0384292602539062, -1.6827901601791382, 0.04800033941864967, 1.3538926839828491, 0.9117183089256287, -0.5620627403259277, 1.188423991203308, 0.2954297959804535, 1.1083368062973022, 0.8988209366798401, -0.28014934062957764, 0.5749132037162781, 0.20584836602210999, -1.2748160362243652, 0.2752784788608551, 1.1520107984542847, 0.33177417516708374, 1.3197314739227295, -0.9864233136177063, 0.090866819024086, 0.39009448885917664, -0.506095290184021, -0.532006561756134, -0.48676958680152893, 0.7722318172454834, 0.15802069008350372, -0.9852392673492432, 0.05625561252236366, -0.15575428307056427, 0.10926966369152069, 0.09183666110038757, -1.3535555601119995, -0.029099415987730026, -0.28927478194236755, -0.6047630310058594, -1.3206232786178589, -0.19102099537849426, 1.3734455108642578, -0.8900806903839111, 0.018142573535442352, 0.33670884370803833, 0.18828724324703217, 0.6702707409858704, 0.7345815300941467, -0.6735361218452454, -0.5830049514770508, -0.2598470151424408, -0.2714965343475342, 0.423052579164505, 1.4318950176239014, -0.08659055829048157, -1.0192378759384155, 0.7238415479660034, -0.4200945198535919, 0.20868238806724548, 1.9535863399505615, -0.08206035196781158, -0.8570833802223206, 0.3169024586677551, -0.4686363637447357, 1.807293176651001, 1.5463606119155884, 1.208766222000122, -0.21331270039081573, -0.9618432521820068, 0.4449727535247803, -0.3971536457538605, -0.505216658115387, 0.7880185842514038, 0.43148308992385864, -0.32493558526039124, -1.2160115242004395, 0.5349754691123962, 1.2975704669952393, -0.982891321182251, -0.9131126403808594, 0.2865743041038513, -0.7481915950775146, 1.1329399347305298, 0.8499515056610107, 0.5531738996505737, 0.25060781836509705, 1.5824356079101562, 0.8787041306495667, -0.7000696063041687, 0.5795252919197083, 0.23579126596450806, -0.253745973110199, -2.001652717590332, -1.1104542016983032, 0.25150108337402344, -0.6998693346977234, -1.509232521057129, 1.2917604446411133, -1.310678482055664, -0.8920603394508362, 0.5625595450401306, 0.22152486443519592, 1.3754030466079712, 0.39716821908950806, 1.4936740398406982, 2.1273746490478516, 1.047629475593567, 0.5512422919273376, 1.4388537406921387, -0.2958129644393921, -0.5751442313194275, 1.5636615753173828, -0.35759052634239197, 0.5069490075111389, 1.1988646984100342, -0.2368486076593399, -0.727756142616272, -0.908080518245697, -1.0672111511230469, -0.5554324388504028, 1.2581678628921509, 0.19563362002372742, -1.072145938873291, 0.21918897330760956, 1.4384195804595947, -0.08150217682123184, -0.1735439896583557, 0.68581622838974, 0.38650548458099365, -0.7155990600585938, -0.10948890447616577, -0.9725998044013977, 0.4771629869937897, -0.5043083429336548, -0.45346590876579285, 0.3011980652809143, 0.2853626608848572, 1.2547520399093628, -0.0815587192773819, 0.18986330926418304, 1.2683192491531372, -1.1395883560180664, 1.6045256853103638, -0.6877118349075317, 0.21087278425693512, -2.1373956203460693, 1.2092641592025757, -0.8738805651664734, 1.7929941415786743, -2.7874820232391357, 0.30239760875701904, -0.35964345932006836, -0.5050965547561646, 0.16630855202674866, -0.3364744186401367, 0.13653777539730072, -0.3842776417732239, -1.2182387113571167, -0.12400287389755249, -0.8180031776428223, 0.37111249566078186, 0.9245210289955139, 1.3707072734832764, -1.1377477645874023, -0.28119033575057983, -1.9103351831436157, -0.09528620541095734, -0.8089903593063354, 0.45652541518211365, -1.8363450765609741, -0.34727033972740173, -1.7794452905654907, -2.423692464828491, -1.2223769426345825, -0.933836817741394, 1.1718870401382446, -0.15981532633304596, -0.5349230766296387, 1.031390905380249, -0.2196476012468338, -1.986266016960144, 1.032730221748352, -2.2616939544677734 ]
https://github.com/huggingface/datasets/issues/5162
Pip-compile: Could not find a version that matches dill<0.3.6,>=0.3.6
> @Rijgersberg this issue is fixed. It will be available in our next `datasets` release. Any chance you have a eta?
### Describe the bug When using `pip-compile` (part of `pip-tools`) to generate a pinned requirements file that includes `datasets`, a version conflict of `dill` appears. It is caused by a transitive dependency conflict between `datasets` and `multiprocess`. ### Steps to reproduce the bug ```bash $ echo "datasets" > requirements.in $ pip install pip-tools $ pip-compile requirements.in Could not find a version that matches dill<0.3.6,>=0.3.6 (from datasets==2.6.1->-r requirements.in (line 1)) Tried: 0.2, 0.2, 0.2.1, 0.2.1, 0.2.2, 0.2.2, 0.2.3, 0.2.3, 0.2.4, 0.2.4, 0.2.5, 0.2.5, 0.2.6, 0.2.7, 0.2.7.1, 0.2.8, 0.2.8.1, 0.2.8.2, 0.2.9, 0.3.0, 0.3.1, 0.3.1.1, 0.3.2, 0.3.3, 0.3.3, 0.3.4, 0.3.4, 0.3.5, 0.3.5, 0.3.5.1, 0.3.5.1, 0.3.6, 0.3.6 Skipped pre-versions: 0.1a1, 0.2a1, 0.2a1, 0.2b1, 0.2b1 There are incompatible versions in the resolved dependencies: dill<0.3.6 (from datasets==2.6.1->-r requirements.in (line 1)) dill>=0.3.6 (from multiprocess==0.70.14->datasets==2.6.1->-r requirements.in (line 1)) ``` ### Expected behavior A correctly generated file `requirements.txt` with pinned dependencies ### Environment info Tested with versions `2.6.1, 2.6.0, 2.5.2` on Python 3.8 and 3.10 on Ubuntu 20.04LTS and Python 3.10 on MacOS 12.6 (M1).
453
21
Pip-compile: Could not find a version that matches dill<0.3.6,>=0.3.6 ### Describe the bug When using `pip-compile` (part of `pip-tools`) to generate a pinned requirements file that includes `datasets`, a version conflict of `dill` appears. It is caused by a transitive dependency conflict between `datasets` and `multiprocess`. ### Steps to reproduce the bug ```bash $ echo "datasets" > requirements.in $ pip install pip-tools $ pip-compile requirements.in Could not find a version that matches dill<0.3.6,>=0.3.6 (from datasets==2.6.1->-r requirements.in (line 1)) Tried: 0.2, 0.2, 0.2.1, 0.2.1, 0.2.2, 0.2.2, 0.2.3, 0.2.3, 0.2.4, 0.2.4, 0.2.5, 0.2.5, 0.2.6, 0.2.7, 0.2.7.1, 0.2.8, 0.2.8.1, 0.2.8.2, 0.2.9, 0.3.0, 0.3.1, 0.3.1.1, 0.3.2, 0.3.3, 0.3.3, 0.3.4, 0.3.4, 0.3.5, 0.3.5, 0.3.5.1, 0.3.5.1, 0.3.6, 0.3.6 Skipped pre-versions: 0.1a1, 0.2a1, 0.2a1, 0.2b1, 0.2b1 There are incompatible versions in the resolved dependencies: dill<0.3.6 (from datasets==2.6.1->-r requirements.in (line 1)) dill>=0.3.6 (from multiprocess==0.70.14->datasets==2.6.1->-r requirements.in (line 1)) ``` ### Expected behavior A correctly generated file `requirements.txt` with pinned dependencies ### Environment info Tested with versions `2.6.1, 2.6.0, 2.5.2` on Python 3.8 and 3.10 on Ubuntu 20.04LTS and Python 3.10 on MacOS 12.6 (M1). > @Rijgersberg this issue is fixed. It will be available in our next `datasets` release. Any chance you have a eta?
[ -1.3622589111328125, -0.9922836422920227, -0.5274460911750793, 1.3976248502731323, -0.3468988835811615, -1.1460134983062744, 0.20519761741161346, -1.0062435865402222, 1.7358776330947876, -0.850565493106842, 0.16969817876815796, -1.6603925228118896, 0.05620529130101204, -0.44110459089279175, -0.7543696761131287, -0.8874645829200745, -0.46737003326416016, -0.7041770815849304, 1.1449308395385742, 2.694122076034546, 1.1581649780273438, -1.1769026517868042, 2.5943191051483154, 0.8284828662872314, -0.1743823140859604, -1.023284912109375, 0.6627236008644104, 0.057439129799604416, -1.6104553937911987, -0.34319615364074707, -0.9538134932518005, -0.04065414145588875, -0.5893332958221436, -0.5473847985267639, 0.07907373458147049, 0.1875537782907486, -0.3900400698184967, -0.317271888256073, -0.29686829447746277, -0.8784828782081604, 0.3263193964958191, -0.5046695470809937, 0.9222254753112793, -0.37760528922080994, 1.5930479764938354, -0.5466307997703552, 0.6895872950553894, 0.7051492929458618, 1.120438575744629, 0.18582390248775482, 0.08469367027282715, 0.2443249672651291, 0.5779112577438354, 0.18173103034496307, 0.41330769658088684, 0.9640802145004272, 0.5863842964172363, 0.32117512822151184, 0.5268309712409973, -2.296168327331543, 1.4051107168197632, -0.9020522832870483, 0.23137831687927246, 1.4200687408447266, -0.8605395555496216, 0.2525922358036041, -1.6519140005111694, -0.1317967176437378, 0.6376286149024963, -2.369183301925659, 0.23135608434677124, -1.600452184677124, -0.5310876369476318, 1.0373973846435547, 0.5376781821250916, -1.2035514116287231, 0.09962208569049835, -0.3566227853298187, 0.8403468132019043, 0.48393887281417847, 1.023091435432434, -1.7138752937316895, -0.2786950469017029, -0.3468440771102905, 0.09858331084251404, -1.1236135959625244, -1.4691792726516724, 0.5442855358123779, 0.7176721096038818, 0.5241485238075256, -0.11865203827619553, 0.9512019157409668, -1.0899325609207153, 0.7463595271110535, -1.025275707244873, -1.9130083322525024, -1.4306544065475464, -2.526165246963501, -2.3776803016662598, 0.6363195776939392, -0.3829614222049713, -0.4131409823894501, 2.066293478012085, -1.162628173828125, -1.6019268035888672, 1.1301603317260742, 0.2145645171403885, -0.14679265022277832, 2.3830740451812744, 0.09672955423593521, -0.5392563343048096, 0.46273550391197205, -1.075332760810852, 0.5793530941009521, -0.3385748863220215, 1.36423921585083, 0.3918163776397705, -1.076092004776001, 1.3976328372955322, -0.3694542348384857, 0.5774132013320923, -0.6466865539550781, -0.271750807762146, -0.7456673979759216, 0.13974542915821075, 1.8690522909164429, -0.17478834092617035, 1.4124122858047485, -0.1509549468755722, -1.5060547590255737, -1.611313819885254, 0.839565098285675, 0.6080676913261414, -0.6507804989814758, 0.05559520795941353, -0.25685304403305054, 0.14921307563781738, 0.04658758267760277, 1.0644689798355103, 1.3922981023788452, 0.9060071110725403, -0.33921942114830017, -0.9229914546012878, 0.26849138736724854, -0.25591427087783813, -0.8630165457725525, -1.7783589363098145, -0.3476572036743164, -0.03681977838277817, 0.756233274936676, -1.146751880645752, 1.686220407485962, 1.0019066333770752, 1.8974510431289673, 1.0097318887710571, -0.5702629089355469, 1.5414073467254639, 0.22625496983528137, 1.7655366659164429, -0.5121452212333679, 0.9055873155593872, -0.5547932386398315, -1.1210793256759644, 0.8953616619110107, -0.21842101216316223, -2.006253957748413, -0.5192911624908447, -0.811434805393219, -0.2570916414260864, -0.7309942841529846, 1.1025294065475464, -0.12466167658567429, -1.4539605379104614, 0.28764715790748596, -0.8110990524291992, -0.037779975682497025, -1.2656536102294922, 0.43629714846611023, 0.7739757895469666, -0.5116866230964661, 0.09382563829421997, -0.2965143918991089, -1.248829960823059, -0.4421407878398895, 0.27810582518577576, 1.6671980619430542, -0.6219797134399414, 1.1501942873001099, 0.9750794768333435, -0.7490946054458618, -0.09989172220230103, 0.5519524216651917, -0.3100857138633728, 0.8077201247215271, -0.8194859623908997, -0.22794197499752045, 1.2914085388183594, -0.3100031316280365, -0.5546873211860657, 1.5810108184814453, 0.6632882952690125, -0.8890175223350525, -0.1417868733406067, -0.1000155359506607, -0.5369495749473572, 0.20050667226314545, -1.7311172485351562, -0.10736232995986938, 0.44030386209487915, -1.7247503995895386, -0.5934249758720398, -0.23698167502880096, 1.42189621925354, 0.07452329248189926, 1.412320852279663, -0.14540283381938934, -0.22448168694972992, -0.5941756367683411, -0.1887361854314804, 0.1951797902584076, -0.10802184045314789, -0.40503737330436707, 0.5184178948402405, -0.9074258804321289, 0.36977723240852356, 1.5312418937683105, 0.19383077323436737, 0.1194813922047615, 0.453125923871994, 0.7477026581764221, 0.41583871841430664, -0.276899516582489, -0.9308000206947327, -1.6268032789230347, 2.147270679473877, -1.3858230113983154, 1.9775021076202393, 0.7194837331771851, -0.08294978737831116, -1.6348507404327393, -2.0633132457733154, 1.2876585721969604, 0.8610880970954895, 2.3650271892547607, 0.5433031916618347, 0.4502410888671875, -0.7498788833618164, -0.6022669076919556, 0.25743567943573, -0.9595720767974854, -0.9433370232582092, 0.08247634768486023, 2.4338347911834717, 1.5302367210388184, -0.4832870066165924, -0.06154150888323784, -1.3291144371032715, 1.4610079526901245, -0.051465559750795364, 0.22771599888801575, 1.920546293258667, -0.24671408534049988, -1.027251958847046, 1.2485368251800537, -2.2584388256073, 0.18726645410060883, 1.939117431640625, 0.11858726292848587, 0.10943352431058884, -1.5499794483184814, -0.7428646683692932, -0.3426925241947174, -0.5976605415344238, -1.2157986164093018, 0.6637208461761475, -0.21579882502555847, -0.9650245308876038, -1.6125277280807495, 0.10343575477600098, -1.0793143510818481, -1.929896593093872, 0.08326778560876846, 1.787207841873169, 1.9489257335662842, -0.6910820603370667, 1.4809494018554688, -0.16801171004772186, 0.05561001971364021, 1.098621129989624, 1.1353555917739868, 3.036555290222168, 2.218477725982666, -1.2128938436508179, 0.8631724119186401, -0.1739351749420166, -0.30632656812667847, 1.1018630266189575, -1.2304129600524902, 1.4325088262557983, -0.16721758246421814, -1.229761004447937, -1.2292717695236206, 0.9687612652778625, 0.4191111624240875, 0.07228973507881165, -0.3396860659122467, 1.1885730028152466, 0.16026312112808228, 1.3271511793136597, 0.4628300964832306, -0.06471648812294006, 0.8299552798271179, -0.5633025765419006, -0.3456045091152191, 1.6203349828720093, 0.31832313537597656, -1.515622854232788, -2.3688578605651855, -0.40148603916168213, -0.9449655413627625, -0.04374752938747406, -0.5245528817176819, -0.9128690958023071, 1.690330147743225, 0.4970826506614685, -1.006011962890625, -0.09206531196832657, -0.3387126624584198, -0.5926843881607056, 2.721383810043335, -1.2416104078292847, -0.18154221773147583, -0.9732277393341064, -0.717239499092102, 1.3209969997406006, -1.3264081478118896, 0.0875438004732132, -0.9569541215896606, -0.47714877128601074, -1.2571079730987549, -0.4012950658798218, -0.07940424233675003, -1.0465610027313232, 0.7481671571731567, 0.15746189653873444, -1.260959267616272, -0.4746319353580475, -0.9836427569389343, 0.8420743942260742, 0.3630317151546478, 0.16218271851539612, 1.8428759574890137, 0.23337912559509277, -0.29320797324180603, 0.6691388487815857, 1.0380303859710693, 0.6795694828033447, -0.6100386381149292, 0.4016200006008148, -0.6797950863838196, 0.46956443786621094, -1.040574312210083, 0.28872549533843994, -2.6358482837677, 0.6299141645431519, -0.1449047029018402, -0.17031000554561615, -0.14193277060985565, -1.151300311088562, 1.303179383277893, 2.5099589824676514, -1.1242702007293701, 0.6464046835899353, 0.0684928148984909, 1.151046633720398, -1.255012035369873, 0.4359404444694519, -0.4876823127269745, 2.265202045440674, 0.3168482184410095, 1.0700191259384155, -0.342532217502594, -2.3611087799072266, 0.7832245230674744, -1.2485312223434448, -1.0619382858276367, 0.6671330332756042, -0.8502208590507507, -0.13775360584259033, -1.1915148496627808, -0.0907202959060669, -0.7104968428611755, -1.168436884880066, 0.5448334813117981, 0.20993950963020325, 0.6930842995643616, -0.7174537181854248, 0.47738349437713623, -2.3124682903289795, -1.1722544431686401, -0.3538472652435303, -0.8958349227905273, 0.452816903591156, -0.24455581605434418, 0.7200703620910645, -0.17384377121925354, -0.17897988855838776, 0.4788513779640198, 1.3517968654632568, 3.370823860168457, -0.1436682641506195, 0.31396010518074036, -0.12829171121120453, -1.2033672332763672, 1.3970593214035034, 1.018837809562683, -0.11670354008674622, -0.648749589920044, -1.1352384090423584, 1.1475780010223389, 1.9567646980285645, 1.0995796918869019, 0.046978794038295746, -0.9245196580886841, -0.842889666557312, 0.05935775116086006, 0.12541702389717102, 0.45713070034980774, 1.029491662979126, 0.04747669771313667, 0.025897923856973648, 1.6973198652267456, 1.251818060874939, -0.15461456775665283, 0.3221144378185272, -0.7892493605613708, -0.4588780701160431, 0.5941370725631714, 0.4388326108455658, 0.021985948085784912, 0.450618177652359, -1.2010167837142944, -0.10635898262262344, -0.22828471660614014, -0.8913403749465942, -0.7922815084457397, -0.3957439363002777, -0.4120582640171051, 1.7339494228363037, 0.021760806441307068, -0.3985050618648529, 0.008006355725228786, -0.8638803958892822, 0.09557434171438217, -0.8813031911849976, 0.3449828028678894, -0.2107221484184265, 0.03555523604154587, -0.17516982555389404, 1.8320727348327637, -0.9755390882492065, -1.9785810708999634, 0.30476289987564087, -0.00244034081697464, -0.344519704580307, 0.4432077407836914, 1.4888709783554077, 0.816572904586792, 1.52592933177948, 1.2030394077301025, 0.9790661931037903, -0.5043098330497742, -1.4776817560195923, 0.7580454349517822, 0.8834365010261536, -1.4273054599761963, 0.7604292035102844, 0.06725328415632248, -0.4837011992931366, 0.5564436316490173, 1.0715692043304443, 0.3209189176559448, -2.069270372390747, 0.7769496440887451, -0.8893901705741882, 0.8351265788078308, 0.6724205613136292, 0.7274817824363708, 0.035153117030858994, 0.6643079519271851, -1.4007445573806763, -0.8528180122375488, -0.5154282450675964, -0.6669705510139465, 2.0623021125793457, -0.18689370155334473, 0.7034817337989807, -0.3868529200553894, -1.2779181003570557, -0.04108346253633499, 0.4757504165172577, 0.3151402175426483, -0.5295945405960083, 0.8463407754898071, -0.5711972117424011, -1.3495087623596191, -1.3454177379608154, -0.5904005169868469, -1.0796127319335938, -0.8008851408958435, 1.0303339958190918, 0.6252337098121643, 0.5196950435638428, 1.815671443939209, 0.3281685411930084, 0.30242738127708435, -2.8043999671936035, 0.8769140839576721, 0.23459632694721222, -0.08770400285720825, 0.8567519187927246, 0.14588035643100739, 1.0348149538040161, -0.2986685633659363, 0.6807690262794495, -2.290492534637451, 2.469693422317505, -0.23265813291072845, 0.752415120601654, 0.28819477558135986, 0.19531001150608063, 0.9618722796440125, 0.7754167914390564, 0.6284632682800293, -1.0495086908340454, 0.6597902178764343, -0.7430878281593323, 1.5218688249588013, 0.8662071228027344, -0.7861256003379822, -0.26277956366539, 1.160853385925293, 0.4206971228122711, -0.31276944279670715, -0.8797075748443604, -1.1730587482452393, 0.8172687888145447, 1.7807706594467163, -0.3106401264667511, 0.051265887916088104, 0.6718621850013733, 0.6678621768951416, -1.4381831884384155, -0.12815561890602112, -0.818310022354126, -0.4866514503955841, 1.484183669090271, 2.2434911727905273, -0.04053427278995514, -0.2346123605966568, -0.6739328503608704, -1.2282110452651978, 0.681393563747406, 0.0695979967713356, 0.09172063320875168, 0.6504455804824829, -0.36904048919677734, 0.9412227869033813, 0.8725538849830627, 1.0880166292190552, 0.39783379435539246, 0.22349010407924652, 0.16614201664924622, -0.5303272604942322, -1.1310665607452393, -0.3121912479400635, -0.8274590373039246, -2.680712938308716, 0.46807560324668884, -0.23849225044250488, -1.5189086198806763, -0.0816105380654335, -1.0962772369384766, 0.7407214045524597, -0.4829705059528351, -1.0061697959899902, -1.3537002801895142, 0.050090108066797256, -0.22806091606616974, 1.0384292602539062, -1.6827901601791382, 0.04800033941864967, 1.3538926839828491, 0.9117183089256287, -0.5620627403259277, 1.188423991203308, 0.2954297959804535, 1.1083368062973022, 0.8988209366798401, -0.28014934062957764, 0.5749132037162781, 0.20584836602210999, -1.2748160362243652, 0.2752784788608551, 1.1520107984542847, 0.33177417516708374, 1.3197314739227295, -0.9864233136177063, 0.090866819024086, 0.39009448885917664, -0.506095290184021, -0.532006561756134, -0.48676958680152893, 0.7722318172454834, 0.15802069008350372, -0.9852392673492432, 0.05625561252236366, -0.15575428307056427, 0.10926966369152069, 0.09183666110038757, -1.3535555601119995, -0.029099415987730026, -0.28927478194236755, -0.6047630310058594, -1.3206232786178589, -0.19102099537849426, 1.3734455108642578, -0.8900806903839111, 0.018142573535442352, 0.33670884370803833, 0.18828724324703217, 0.6702707409858704, 0.7345815300941467, -0.6735361218452454, -0.5830049514770508, -0.2598470151424408, -0.2714965343475342, 0.423052579164505, 1.4318950176239014, -0.08659055829048157, -1.0192378759384155, 0.7238415479660034, -0.4200945198535919, 0.20868238806724548, 1.9535863399505615, -0.08206035196781158, -0.8570833802223206, 0.3169024586677551, -0.4686363637447357, 1.807293176651001, 1.5463606119155884, 1.208766222000122, -0.21331270039081573, -0.9618432521820068, 0.4449727535247803, -0.3971536457538605, -0.505216658115387, 0.7880185842514038, 0.43148308992385864, -0.32493558526039124, -1.2160115242004395, 0.5349754691123962, 1.2975704669952393, -0.982891321182251, -0.9131126403808594, 0.2865743041038513, -0.7481915950775146, 1.1329399347305298, 0.8499515056610107, 0.5531738996505737, 0.25060781836509705, 1.5824356079101562, 0.8787041306495667, -0.7000696063041687, 0.5795252919197083, 0.23579126596450806, -0.253745973110199, -2.001652717590332, -1.1104542016983032, 0.25150108337402344, -0.6998693346977234, -1.509232521057129, 1.2917604446411133, -1.310678482055664, -0.8920603394508362, 0.5625595450401306, 0.22152486443519592, 1.3754030466079712, 0.39716821908950806, 1.4936740398406982, 2.1273746490478516, 1.047629475593567, 0.5512422919273376, 1.4388537406921387, -0.2958129644393921, -0.5751442313194275, 1.5636615753173828, -0.35759052634239197, 0.5069490075111389, 1.1988646984100342, -0.2368486076593399, -0.727756142616272, -0.908080518245697, -1.0672111511230469, -0.5554324388504028, 1.2581678628921509, 0.19563362002372742, -1.072145938873291, 0.21918897330760956, 1.4384195804595947, -0.08150217682123184, -0.1735439896583557, 0.68581622838974, 0.38650548458099365, -0.7155990600585938, -0.10948890447616577, -0.9725998044013977, 0.4771629869937897, -0.5043083429336548, -0.45346590876579285, 0.3011980652809143, 0.2853626608848572, 1.2547520399093628, -0.0815587192773819, 0.18986330926418304, 1.2683192491531372, -1.1395883560180664, 1.6045256853103638, -0.6877118349075317, 0.21087278425693512, -2.1373956203460693, 1.2092641592025757, -0.8738805651664734, 1.7929941415786743, -2.7874820232391357, 0.30239760875701904, -0.35964345932006836, -0.5050965547561646, 0.16630855202674866, -0.3364744186401367, 0.13653777539730072, -0.3842776417732239, -1.2182387113571167, -0.12400287389755249, -0.8180031776428223, 0.37111249566078186, 0.9245210289955139, 1.3707072734832764, -1.1377477645874023, -0.28119033575057983, -1.9103351831436157, -0.09528620541095734, -0.8089903593063354, 0.45652541518211365, -1.8363450765609741, -0.34727033972740173, -1.7794452905654907, -2.423692464828491, -1.2223769426345825, -0.933836817741394, 1.1718870401382446, -0.15981532633304596, -0.5349230766296387, 1.031390905380249, -0.2196476012468338, -1.986266016960144, 1.032730221748352, -2.2616939544677734 ]
https://github.com/huggingface/datasets/issues/5162
Pip-compile: Could not find a version that matches dill<0.3.6,>=0.3.6
@Rijgersberg, please also that you can make `pip-compile` work by using the backtracking resolver (instead of the legacy one): https://pip-tools.readthedocs.io/en/latest/#a-note-on-resolvers ``` pip-compile --resolver=backtracking requirements.in ``` This resolver will automatically use `multiprocess` 0.70.13 version.
### Describe the bug When using `pip-compile` (part of `pip-tools`) to generate a pinned requirements file that includes `datasets`, a version conflict of `dill` appears. It is caused by a transitive dependency conflict between `datasets` and `multiprocess`. ### Steps to reproduce the bug ```bash $ echo "datasets" > requirements.in $ pip install pip-tools $ pip-compile requirements.in Could not find a version that matches dill<0.3.6,>=0.3.6 (from datasets==2.6.1->-r requirements.in (line 1)) Tried: 0.2, 0.2, 0.2.1, 0.2.1, 0.2.2, 0.2.2, 0.2.3, 0.2.3, 0.2.4, 0.2.4, 0.2.5, 0.2.5, 0.2.6, 0.2.7, 0.2.7.1, 0.2.8, 0.2.8.1, 0.2.8.2, 0.2.9, 0.3.0, 0.3.1, 0.3.1.1, 0.3.2, 0.3.3, 0.3.3, 0.3.4, 0.3.4, 0.3.5, 0.3.5, 0.3.5.1, 0.3.5.1, 0.3.6, 0.3.6 Skipped pre-versions: 0.1a1, 0.2a1, 0.2a1, 0.2b1, 0.2b1 There are incompatible versions in the resolved dependencies: dill<0.3.6 (from datasets==2.6.1->-r requirements.in (line 1)) dill>=0.3.6 (from multiprocess==0.70.14->datasets==2.6.1->-r requirements.in (line 1)) ``` ### Expected behavior A correctly generated file `requirements.txt` with pinned dependencies ### Environment info Tested with versions `2.6.1, 2.6.0, 2.5.2` on Python 3.8 and 3.10 on Ubuntu 20.04LTS and Python 3.10 on MacOS 12.6 (M1).
453
33
Pip-compile: Could not find a version that matches dill<0.3.6,>=0.3.6 ### Describe the bug When using `pip-compile` (part of `pip-tools`) to generate a pinned requirements file that includes `datasets`, a version conflict of `dill` appears. It is caused by a transitive dependency conflict between `datasets` and `multiprocess`. ### Steps to reproduce the bug ```bash $ echo "datasets" > requirements.in $ pip install pip-tools $ pip-compile requirements.in Could not find a version that matches dill<0.3.6,>=0.3.6 (from datasets==2.6.1->-r requirements.in (line 1)) Tried: 0.2, 0.2, 0.2.1, 0.2.1, 0.2.2, 0.2.2, 0.2.3, 0.2.3, 0.2.4, 0.2.4, 0.2.5, 0.2.5, 0.2.6, 0.2.7, 0.2.7.1, 0.2.8, 0.2.8.1, 0.2.8.2, 0.2.9, 0.3.0, 0.3.1, 0.3.1.1, 0.3.2, 0.3.3, 0.3.3, 0.3.4, 0.3.4, 0.3.5, 0.3.5, 0.3.5.1, 0.3.5.1, 0.3.6, 0.3.6 Skipped pre-versions: 0.1a1, 0.2a1, 0.2a1, 0.2b1, 0.2b1 There are incompatible versions in the resolved dependencies: dill<0.3.6 (from datasets==2.6.1->-r requirements.in (line 1)) dill>=0.3.6 (from multiprocess==0.70.14->datasets==2.6.1->-r requirements.in (line 1)) ``` ### Expected behavior A correctly generated file `requirements.txt` with pinned dependencies ### Environment info Tested with versions `2.6.1, 2.6.0, 2.5.2` on Python 3.8 and 3.10 on Ubuntu 20.04LTS and Python 3.10 on MacOS 12.6 (M1). @Rijgersberg, please also that you can make `pip-compile` work by using the backtracking resolver (instead of the legacy one): https://pip-tools.readthedocs.io/en/latest/#a-note-on-resolvers ``` pip-compile --resolver=backtracking requirements.in ``` This resolver will automatically use `multiprocess` 0.70.13 version.
[ -1.3622589111328125, -0.9922836422920227, -0.5274460911750793, 1.3976248502731323, -0.3468988835811615, -1.1460134983062744, 0.20519761741161346, -1.0062435865402222, 1.7358776330947876, -0.850565493106842, 0.16969817876815796, -1.6603925228118896, 0.05620529130101204, -0.44110459089279175, -0.7543696761131287, -0.8874645829200745, -0.46737003326416016, -0.7041770815849304, 1.1449308395385742, 2.694122076034546, 1.1581649780273438, -1.1769026517868042, 2.5943191051483154, 0.8284828662872314, -0.1743823140859604, -1.023284912109375, 0.6627236008644104, 0.057439129799604416, -1.6104553937911987, -0.34319615364074707, -0.9538134932518005, -0.04065414145588875, -0.5893332958221436, -0.5473847985267639, 0.07907373458147049, 0.1875537782907486, -0.3900400698184967, -0.317271888256073, -0.29686829447746277, -0.8784828782081604, 0.3263193964958191, -0.5046695470809937, 0.9222254753112793, -0.37760528922080994, 1.5930479764938354, -0.5466307997703552, 0.6895872950553894, 0.7051492929458618, 1.120438575744629, 0.18582390248775482, 0.08469367027282715, 0.2443249672651291, 0.5779112577438354, 0.18173103034496307, 0.41330769658088684, 0.9640802145004272, 0.5863842964172363, 0.32117512822151184, 0.5268309712409973, -2.296168327331543, 1.4051107168197632, -0.9020522832870483, 0.23137831687927246, 1.4200687408447266, -0.8605395555496216, 0.2525922358036041, -1.6519140005111694, -0.1317967176437378, 0.6376286149024963, -2.369183301925659, 0.23135608434677124, -1.600452184677124, -0.5310876369476318, 1.0373973846435547, 0.5376781821250916, -1.2035514116287231, 0.09962208569049835, -0.3566227853298187, 0.8403468132019043, 0.48393887281417847, 1.023091435432434, -1.7138752937316895, -0.2786950469017029, -0.3468440771102905, 0.09858331084251404, -1.1236135959625244, -1.4691792726516724, 0.5442855358123779, 0.7176721096038818, 0.5241485238075256, -0.11865203827619553, 0.9512019157409668, -1.0899325609207153, 0.7463595271110535, -1.025275707244873, -1.9130083322525024, -1.4306544065475464, -2.526165246963501, -2.3776803016662598, 0.6363195776939392, -0.3829614222049713, -0.4131409823894501, 2.066293478012085, -1.162628173828125, -1.6019268035888672, 1.1301603317260742, 0.2145645171403885, -0.14679265022277832, 2.3830740451812744, 0.09672955423593521, -0.5392563343048096, 0.46273550391197205, -1.075332760810852, 0.5793530941009521, -0.3385748863220215, 1.36423921585083, 0.3918163776397705, -1.076092004776001, 1.3976328372955322, -0.3694542348384857, 0.5774132013320923, -0.6466865539550781, -0.271750807762146, -0.7456673979759216, 0.13974542915821075, 1.8690522909164429, -0.17478834092617035, 1.4124122858047485, -0.1509549468755722, -1.5060547590255737, -1.611313819885254, 0.839565098285675, 0.6080676913261414, -0.6507804989814758, 0.05559520795941353, -0.25685304403305054, 0.14921307563781738, 0.04658758267760277, 1.0644689798355103, 1.3922981023788452, 0.9060071110725403, -0.33921942114830017, -0.9229914546012878, 0.26849138736724854, -0.25591427087783813, -0.8630165457725525, -1.7783589363098145, -0.3476572036743164, -0.03681977838277817, 0.756233274936676, -1.146751880645752, 1.686220407485962, 1.0019066333770752, 1.8974510431289673, 1.0097318887710571, -0.5702629089355469, 1.5414073467254639, 0.22625496983528137, 1.7655366659164429, -0.5121452212333679, 0.9055873155593872, -0.5547932386398315, -1.1210793256759644, 0.8953616619110107, -0.21842101216316223, -2.006253957748413, -0.5192911624908447, -0.811434805393219, -0.2570916414260864, -0.7309942841529846, 1.1025294065475464, -0.12466167658567429, -1.4539605379104614, 0.28764715790748596, -0.8110990524291992, -0.037779975682497025, -1.2656536102294922, 0.43629714846611023, 0.7739757895469666, -0.5116866230964661, 0.09382563829421997, -0.2965143918991089, -1.248829960823059, -0.4421407878398895, 0.27810582518577576, 1.6671980619430542, -0.6219797134399414, 1.1501942873001099, 0.9750794768333435, -0.7490946054458618, -0.09989172220230103, 0.5519524216651917, -0.3100857138633728, 0.8077201247215271, -0.8194859623908997, -0.22794197499752045, 1.2914085388183594, -0.3100031316280365, -0.5546873211860657, 1.5810108184814453, 0.6632882952690125, -0.8890175223350525, -0.1417868733406067, -0.1000155359506607, -0.5369495749473572, 0.20050667226314545, -1.7311172485351562, -0.10736232995986938, 0.44030386209487915, -1.7247503995895386, -0.5934249758720398, -0.23698167502880096, 1.42189621925354, 0.07452329248189926, 1.412320852279663, -0.14540283381938934, -0.22448168694972992, -0.5941756367683411, -0.1887361854314804, 0.1951797902584076, -0.10802184045314789, -0.40503737330436707, 0.5184178948402405, -0.9074258804321289, 0.36977723240852356, 1.5312418937683105, 0.19383077323436737, 0.1194813922047615, 0.453125923871994, 0.7477026581764221, 0.41583871841430664, -0.276899516582489, -0.9308000206947327, -1.6268032789230347, 2.147270679473877, -1.3858230113983154, 1.9775021076202393, 0.7194837331771851, -0.08294978737831116, -1.6348507404327393, -2.0633132457733154, 1.2876585721969604, 0.8610880970954895, 2.3650271892547607, 0.5433031916618347, 0.4502410888671875, -0.7498788833618164, -0.6022669076919556, 0.25743567943573, -0.9595720767974854, -0.9433370232582092, 0.08247634768486023, 2.4338347911834717, 1.5302367210388184, -0.4832870066165924, -0.06154150888323784, -1.3291144371032715, 1.4610079526901245, -0.051465559750795364, 0.22771599888801575, 1.920546293258667, -0.24671408534049988, -1.027251958847046, 1.2485368251800537, -2.2584388256073, 0.18726645410060883, 1.939117431640625, 0.11858726292848587, 0.10943352431058884, -1.5499794483184814, -0.7428646683692932, -0.3426925241947174, -0.5976605415344238, -1.2157986164093018, 0.6637208461761475, -0.21579882502555847, -0.9650245308876038, -1.6125277280807495, 0.10343575477600098, -1.0793143510818481, -1.929896593093872, 0.08326778560876846, 1.787207841873169, 1.9489257335662842, -0.6910820603370667, 1.4809494018554688, -0.16801171004772186, 0.05561001971364021, 1.098621129989624, 1.1353555917739868, 3.036555290222168, 2.218477725982666, -1.2128938436508179, 0.8631724119186401, -0.1739351749420166, -0.30632656812667847, 1.1018630266189575, -1.2304129600524902, 1.4325088262557983, -0.16721758246421814, -1.229761004447937, -1.2292717695236206, 0.9687612652778625, 0.4191111624240875, 0.07228973507881165, -0.3396860659122467, 1.1885730028152466, 0.16026312112808228, 1.3271511793136597, 0.4628300964832306, -0.06471648812294006, 0.8299552798271179, -0.5633025765419006, -0.3456045091152191, 1.6203349828720093, 0.31832313537597656, -1.515622854232788, -2.3688578605651855, -0.40148603916168213, -0.9449655413627625, -0.04374752938747406, -0.5245528817176819, -0.9128690958023071, 1.690330147743225, 0.4970826506614685, -1.006011962890625, -0.09206531196832657, -0.3387126624584198, -0.5926843881607056, 2.721383810043335, -1.2416104078292847, -0.18154221773147583, -0.9732277393341064, -0.717239499092102, 1.3209969997406006, -1.3264081478118896, 0.0875438004732132, -0.9569541215896606, -0.47714877128601074, -1.2571079730987549, -0.4012950658798218, -0.07940424233675003, -1.0465610027313232, 0.7481671571731567, 0.15746189653873444, -1.260959267616272, -0.4746319353580475, -0.9836427569389343, 0.8420743942260742, 0.3630317151546478, 0.16218271851539612, 1.8428759574890137, 0.23337912559509277, -0.29320797324180603, 0.6691388487815857, 1.0380303859710693, 0.6795694828033447, -0.6100386381149292, 0.4016200006008148, -0.6797950863838196, 0.46956443786621094, -1.040574312210083, 0.28872549533843994, -2.6358482837677, 0.6299141645431519, -0.1449047029018402, -0.17031000554561615, -0.14193277060985565, -1.151300311088562, 1.303179383277893, 2.5099589824676514, -1.1242702007293701, 0.6464046835899353, 0.0684928148984909, 1.151046633720398, -1.255012035369873, 0.4359404444694519, -0.4876823127269745, 2.265202045440674, 0.3168482184410095, 1.0700191259384155, -0.342532217502594, -2.3611087799072266, 0.7832245230674744, -1.2485312223434448, -1.0619382858276367, 0.6671330332756042, -0.8502208590507507, -0.13775360584259033, -1.1915148496627808, -0.0907202959060669, -0.7104968428611755, -1.168436884880066, 0.5448334813117981, 0.20993950963020325, 0.6930842995643616, -0.7174537181854248, 0.47738349437713623, -2.3124682903289795, -1.1722544431686401, -0.3538472652435303, -0.8958349227905273, 0.452816903591156, -0.24455581605434418, 0.7200703620910645, -0.17384377121925354, -0.17897988855838776, 0.4788513779640198, 1.3517968654632568, 3.370823860168457, -0.1436682641506195, 0.31396010518074036, -0.12829171121120453, -1.2033672332763672, 1.3970593214035034, 1.018837809562683, -0.11670354008674622, -0.648749589920044, -1.1352384090423584, 1.1475780010223389, 1.9567646980285645, 1.0995796918869019, 0.046978794038295746, -0.9245196580886841, -0.842889666557312, 0.05935775116086006, 0.12541702389717102, 0.45713070034980774, 1.029491662979126, 0.04747669771313667, 0.025897923856973648, 1.6973198652267456, 1.251818060874939, -0.15461456775665283, 0.3221144378185272, -0.7892493605613708, -0.4588780701160431, 0.5941370725631714, 0.4388326108455658, 0.021985948085784912, 0.450618177652359, -1.2010167837142944, -0.10635898262262344, -0.22828471660614014, -0.8913403749465942, -0.7922815084457397, -0.3957439363002777, -0.4120582640171051, 1.7339494228363037, 0.021760806441307068, -0.3985050618648529, 0.008006355725228786, -0.8638803958892822, 0.09557434171438217, -0.8813031911849976, 0.3449828028678894, -0.2107221484184265, 0.03555523604154587, -0.17516982555389404, 1.8320727348327637, -0.9755390882492065, -1.9785810708999634, 0.30476289987564087, -0.00244034081697464, -0.344519704580307, 0.4432077407836914, 1.4888709783554077, 0.816572904586792, 1.52592933177948, 1.2030394077301025, 0.9790661931037903, -0.5043098330497742, -1.4776817560195923, 0.7580454349517822, 0.8834365010261536, -1.4273054599761963, 0.7604292035102844, 0.06725328415632248, -0.4837011992931366, 0.5564436316490173, 1.0715692043304443, 0.3209189176559448, -2.069270372390747, 0.7769496440887451, -0.8893901705741882, 0.8351265788078308, 0.6724205613136292, 0.7274817824363708, 0.035153117030858994, 0.6643079519271851, -1.4007445573806763, -0.8528180122375488, -0.5154282450675964, -0.6669705510139465, 2.0623021125793457, -0.18689370155334473, 0.7034817337989807, -0.3868529200553894, -1.2779181003570557, -0.04108346253633499, 0.4757504165172577, 0.3151402175426483, -0.5295945405960083, 0.8463407754898071, -0.5711972117424011, -1.3495087623596191, -1.3454177379608154, -0.5904005169868469, -1.0796127319335938, -0.8008851408958435, 1.0303339958190918, 0.6252337098121643, 0.5196950435638428, 1.815671443939209, 0.3281685411930084, 0.30242738127708435, -2.8043999671936035, 0.8769140839576721, 0.23459632694721222, -0.08770400285720825, 0.8567519187927246, 0.14588035643100739, 1.0348149538040161, -0.2986685633659363, 0.6807690262794495, -2.290492534637451, 2.469693422317505, -0.23265813291072845, 0.752415120601654, 0.28819477558135986, 0.19531001150608063, 0.9618722796440125, 0.7754167914390564, 0.6284632682800293, -1.0495086908340454, 0.6597902178764343, -0.7430878281593323, 1.5218688249588013, 0.8662071228027344, -0.7861256003379822, -0.26277956366539, 1.160853385925293, 0.4206971228122711, -0.31276944279670715, -0.8797075748443604, -1.1730587482452393, 0.8172687888145447, 1.7807706594467163, -0.3106401264667511, 0.051265887916088104, 0.6718621850013733, 0.6678621768951416, -1.4381831884384155, -0.12815561890602112, -0.818310022354126, -0.4866514503955841, 1.484183669090271, 2.2434911727905273, -0.04053427278995514, -0.2346123605966568, -0.6739328503608704, -1.2282110452651978, 0.681393563747406, 0.0695979967713356, 0.09172063320875168, 0.6504455804824829, -0.36904048919677734, 0.9412227869033813, 0.8725538849830627, 1.0880166292190552, 0.39783379435539246, 0.22349010407924652, 0.16614201664924622, -0.5303272604942322, -1.1310665607452393, -0.3121912479400635, -0.8274590373039246, -2.680712938308716, 0.46807560324668884, -0.23849225044250488, -1.5189086198806763, -0.0816105380654335, -1.0962772369384766, 0.7407214045524597, -0.4829705059528351, -1.0061697959899902, -1.3537002801895142, 0.050090108066797256, -0.22806091606616974, 1.0384292602539062, -1.6827901601791382, 0.04800033941864967, 1.3538926839828491, 0.9117183089256287, -0.5620627403259277, 1.188423991203308, 0.2954297959804535, 1.1083368062973022, 0.8988209366798401, -0.28014934062957764, 0.5749132037162781, 0.20584836602210999, -1.2748160362243652, 0.2752784788608551, 1.1520107984542847, 0.33177417516708374, 1.3197314739227295, -0.9864233136177063, 0.090866819024086, 0.39009448885917664, -0.506095290184021, -0.532006561756134, -0.48676958680152893, 0.7722318172454834, 0.15802069008350372, -0.9852392673492432, 0.05625561252236366, -0.15575428307056427, 0.10926966369152069, 0.09183666110038757, -1.3535555601119995, -0.029099415987730026, -0.28927478194236755, -0.6047630310058594, -1.3206232786178589, -0.19102099537849426, 1.3734455108642578, -0.8900806903839111, 0.018142573535442352, 0.33670884370803833, 0.18828724324703217, 0.6702707409858704, 0.7345815300941467, -0.6735361218452454, -0.5830049514770508, -0.2598470151424408, -0.2714965343475342, 0.423052579164505, 1.4318950176239014, -0.08659055829048157, -1.0192378759384155, 0.7238415479660034, -0.4200945198535919, 0.20868238806724548, 1.9535863399505615, -0.08206035196781158, -0.8570833802223206, 0.3169024586677551, -0.4686363637447357, 1.807293176651001, 1.5463606119155884, 1.208766222000122, -0.21331270039081573, -0.9618432521820068, 0.4449727535247803, -0.3971536457538605, -0.505216658115387, 0.7880185842514038, 0.43148308992385864, -0.32493558526039124, -1.2160115242004395, 0.5349754691123962, 1.2975704669952393, -0.982891321182251, -0.9131126403808594, 0.2865743041038513, -0.7481915950775146, 1.1329399347305298, 0.8499515056610107, 0.5531738996505737, 0.25060781836509705, 1.5824356079101562, 0.8787041306495667, -0.7000696063041687, 0.5795252919197083, 0.23579126596450806, -0.253745973110199, -2.001652717590332, -1.1104542016983032, 0.25150108337402344, -0.6998693346977234, -1.509232521057129, 1.2917604446411133, -1.310678482055664, -0.8920603394508362, 0.5625595450401306, 0.22152486443519592, 1.3754030466079712, 0.39716821908950806, 1.4936740398406982, 2.1273746490478516, 1.047629475593567, 0.5512422919273376, 1.4388537406921387, -0.2958129644393921, -0.5751442313194275, 1.5636615753173828, -0.35759052634239197, 0.5069490075111389, 1.1988646984100342, -0.2368486076593399, -0.727756142616272, -0.908080518245697, -1.0672111511230469, -0.5554324388504028, 1.2581678628921509, 0.19563362002372742, -1.072145938873291, 0.21918897330760956, 1.4384195804595947, -0.08150217682123184, -0.1735439896583557, 0.68581622838974, 0.38650548458099365, -0.7155990600585938, -0.10948890447616577, -0.9725998044013977, 0.4771629869937897, -0.5043083429336548, -0.45346590876579285, 0.3011980652809143, 0.2853626608848572, 1.2547520399093628, -0.0815587192773819, 0.18986330926418304, 1.2683192491531372, -1.1395883560180664, 1.6045256853103638, -0.6877118349075317, 0.21087278425693512, -2.1373956203460693, 1.2092641592025757, -0.8738805651664734, 1.7929941415786743, -2.7874820232391357, 0.30239760875701904, -0.35964345932006836, -0.5050965547561646, 0.16630855202674866, -0.3364744186401367, 0.13653777539730072, -0.3842776417732239, -1.2182387113571167, -0.12400287389755249, -0.8180031776428223, 0.37111249566078186, 0.9245210289955139, 1.3707072734832764, -1.1377477645874023, -0.28119033575057983, -1.9103351831436157, -0.09528620541095734, -0.8089903593063354, 0.45652541518211365, -1.8363450765609741, -0.34727033972740173, -1.7794452905654907, -2.423692464828491, -1.2223769426345825, -0.933836817741394, 1.1718870401382446, -0.15981532633304596, -0.5349230766296387, 1.031390905380249, -0.2196476012468338, -1.986266016960144, 1.032730221748352, -2.2616939544677734 ]
https://github.com/huggingface/datasets/issues/5160
Automatically add filename for image/audio folder
I'm fine with adding a new column with the file name personally. Not sure how breaking this is though
### Feature request When creating a custom audio of image dataset, it would be great to automatically have access to the filename. It should be both: a) Automatically displayed in the viewer b) Automatically added as a column to the dataset when doing `load_dataset` In `diffusers` our test rely quite heavily on images and audio files now and it's a bit tedious at the moment to download specific images from a datasets repo. E.g. we have a dataset of images for tests in `diffusers`: https://huggingface.co/datasets/hf-internal-testing/diffusers-images where it would be extremely nice to have direct access to the filename both visually on the datasets page (@severo ) as well as via the `load_datasets` function. We currently have some akward functionality to download images by path name: https://github.com/huggingface/diffusers/blob/2fb8fafa4b761f6fc144cf75a6f6f0ea6af3a1c1/src/diffusers/utils/testing_utils.py#L131 It would be much nicer to just go over `load_dataset(...)` ### Motivation Intuitively the filename is something people understand directly. E.g if you upload a folder of images online, it's nice if you recognize the image as well as the filename next to it directly and that you're able to use it right away. The label on the other hand is less intuitive to understand as you haven't added it yourself. ### Your contribution Not sure if I have the time to add it myself anytime soon, but it would help us a lot for `diffusers`.
455
19
Automatically add filename for image/audio folder ### Feature request When creating a custom audio of image dataset, it would be great to automatically have access to the filename. It should be both: a) Automatically displayed in the viewer b) Automatically added as a column to the dataset when doing `load_dataset` In `diffusers` our test rely quite heavily on images and audio files now and it's a bit tedious at the moment to download specific images from a datasets repo. E.g. we have a dataset of images for tests in `diffusers`: https://huggingface.co/datasets/hf-internal-testing/diffusers-images where it would be extremely nice to have direct access to the filename both visually on the datasets page (@severo ) as well as via the `load_datasets` function. We currently have some akward functionality to download images by path name: https://github.com/huggingface/diffusers/blob/2fb8fafa4b761f6fc144cf75a6f6f0ea6af3a1c1/src/diffusers/utils/testing_utils.py#L131 It would be much nicer to just go over `load_dataset(...)` ### Motivation Intuitively the filename is something people understand directly. E.g if you upload a folder of images online, it's nice if you recognize the image as well as the filename next to it directly and that you're able to use it right away. The label on the other hand is less intuitive to understand as you haven't added it yourself. ### Your contribution Not sure if I have the time to add it myself anytime soon, but it would help us a lot for `diffusers`. I'm fine with adding a new column with the file name personally. Not sure how breaking this is though
[ -1.179395318031311, -0.9112817049026489, -0.8332205414772034, 1.4563642740249634, -0.12156683951616287, -1.312250018119812, 0.01650187000632286, -1.0012352466583252, 1.7439543008804321, -0.800424337387085, 0.3251853287220001, -1.7068241834640503, 0.08106917142868042, -0.5760043263435364, -0.7732505202293396, -0.8736457228660583, -0.4487067461013794, -0.827809751033783, 1.056072473526001, 2.517998218536377, 1.1836906671524048, -1.4190771579742432, 2.7095108032226562, 0.6495926976203918, -0.15450119972229004, -1.0278773307800293, 0.4462098479270935, 0.01721208170056343, -1.2473094463348389, -0.5111544132232666, -0.8908273577690125, -0.014231385663151741, -0.6154849529266357, -0.567413330078125, 0.020548071712255478, 0.39554885029792786, -0.2987297475337982, -0.3699057102203369, -0.5822055339813232, -0.8332532644271851, 0.46518266201019287, -0.42486509680747986, 0.9534512758255005, -0.29646357893943787, 1.8767188787460327, -0.47296860814094543, 0.4014764130115509, 0.6451677083969116, 1.3924635648727417, 0.19722551107406616, 0.06409163773059845, 0.3010430932044983, 0.2994840443134308, -0.04760338366031647, 0.3890434801578522, 1.1459393501281738, 0.6952979564666748, 0.5149160027503967, 0.7021370530128479, -2.2353415489196777, 1.388323187828064, -0.9604367613792419, 0.2917373776435852, 1.2791457176208496, -0.8934556245803833, 0.34288474917411804, -1.7694751024246216, -0.06778255850076675, 0.5828195810317993, -2.218315601348877, 0.24325181543827057, -1.2589091062545776, -0.4443656802177429, 1.059922456741333, 0.22104479372501373, -1.2647700309753418, 0.2830977141857147, -0.4488898813724518, 1.0601671934127808, 0.41062480211257935, 1.1957834959030151, -1.7929731607437134, -0.025240328162908554, -0.19245277345180511, 0.1102202907204628, -1.3078138828277588, -1.5666173696517944, 0.49209609627723694, 0.6196359395980835, 0.6838876008987427, -0.0363849513232708, 0.9236091375350952, -0.9093133211135864, 0.7731440663337708, -0.9352802038192749, -1.6581096649169922, -1.3642569780349731, -2.2528507709503174, -2.37492036819458, 0.8294157385826111, -0.42236724495887756, -0.513586699962616, 2.0139100551605225, -1.0177452564239502, -1.7964521646499634, 1.137001872062683, 0.2555156648159027, -0.0233724657446146, 2.3802490234375, 0.15367460250854492, -0.7291666269302368, 0.4556273818016052, -0.6834142208099365, 0.8790167570114136, -0.4557025730609894, 1.34968900680542, 0.4451429843902588, -1.015902042388916, 1.5670359134674072, -0.508558452129364, 0.5787421464920044, -0.7405712008476257, -0.4732898771762848, -0.8665416836738586, 0.42491739988327026, 1.8953564167022705, -0.24722373485565186, 1.6199076175689697, -0.35400667786598206, -1.6360772848129272, -1.5925410985946655, 0.8785672783851624, 0.5149709582328796, -0.8184875249862671, 0.02438933774828911, -0.30735650658607483, 0.20339107513427734, 0.020782582461833954, 1.028353214263916, 1.185281753540039, 0.6793724298477173, -0.35743996500968933, -0.963638424873352, 0.2764258086681366, -0.1272733211517334, -0.6806465983390808, -1.7964866161346436, -0.34884342551231384, 0.21511279046535492, 0.5609385371208191, -1.2553077936172485, 1.7121422290802002, 0.9008090496063232, 1.9480516910552979, 1.0344218015670776, -0.3309185206890106, 1.527786374092102, 0.04048828408122063, 1.8847458362579346, -0.4312775135040283, 0.6557497978210449, -0.3274569809436798, -1.180936336517334, 0.7928887009620667, -0.30166491866111755, -1.980813980102539, -0.7442097663879395, -0.7499804496765137, -0.22329895198345184, -0.7378118634223938, 0.8980737924575806, -0.30852729082107544, -1.3898630142211914, 0.24993692338466644, -0.608792245388031, 0.08474887162446976, -1.2419401407241821, 0.21645307540893555, 0.7724327445030212, -0.7270848155021667, 0.07677929103374481, -0.29533863067626953, -1.3291339874267578, -0.4775461256504059, 0.32388362288475037, 1.9147605895996094, -0.7332762479782104, 0.8293026685714722, 1.0671238899230957, -0.7173449993133545, 0.059842512011528015, 0.394914448261261, -0.29817381501197815, 0.8453790545463562, -1.0954363346099854, -0.3573332726955414, 1.2020840644836426, -0.17930983006954193, -0.6449738144874573, 1.3352004289627075, 0.8214847445487976, -1.0317819118499756, -0.11163914203643799, -0.19217300415039062, -0.8658923506736755, 0.02503037452697754, -1.626432180404663, -0.11732268333435059, 0.3060401678085327, -1.4744300842285156, -0.4956457018852234, -0.2945345342159271, 1.2283200025558472, -0.21832461655139923, 1.4134610891342163, -0.4185945689678192, -0.28721243143081665, -0.3865039050579071, -0.3712700605392456, 0.09447558224201202, -0.17858733236789703, -0.6110574007034302, 0.24104614555835724, -0.7337323427200317, 0.3193667531013489, 1.4505562782287598, 0.36326566338539124, 0.08672814071178436, 0.47542473673820496, 1.1271893978118896, 0.3623397648334503, -0.026052098721265793, -0.8679320812225342, -1.5303218364715576, 2.028132915496826, -1.3754637241363525, 1.9898037910461426, 0.8399388790130615, 0.010790581814944744, -1.8298465013504028, -1.811641812324524, 1.3575392961502075, 1.1453273296356201, 2.430527687072754, 0.6237054467201233, 0.3750559389591217, -0.7898415327072144, -0.665969729423523, 0.40697184205055237, -1.0355817079544067, -0.8608315587043762, 0.17517584562301636, 2.349254608154297, 1.7518810033798218, -0.43899044394493103, -0.23051078617572784, -0.9966443777084351, 1.39940345287323, -0.14061173796653748, 0.1836482286453247, 1.952694058418274, -0.2592496871948242, -1.1092721223831177, 1.2486590147018433, -2.288144826889038, 0.164080411195755, 1.9802052974700928, 0.27905839681625366, 0.07937272638082504, -1.4344919919967651, -0.7319271564483643, -0.22333918511867523, -0.35792359709739685, -1.2679115533828735, 0.5169958472251892, -0.312582790851593, -0.7958589196205139, -1.4678399562835693, 0.21350684762001038, -1.1080220937728882, -1.6366263628005981, 0.25318267941474915, 1.918781042098999, 1.9811025857925415, -0.8176915049552917, 1.4980316162109375, -0.2030697464942932, 0.16225576400756836, 1.2532113790512085, 1.2556202411651611, 3.1799228191375732, 1.862519383430481, -1.2645046710968018, 0.5917863249778748, -0.1475507616996765, -0.4609939455986023, 1.0971746444702148, -1.1450037956237793, 1.2017443180084229, -0.19863593578338623, -1.182172417640686, -1.2489908933639526, 0.9853992462158203, 0.5496866703033447, 0.06732039153575897, -0.5203712582588196, 1.209501028060913, -0.024560898542404175, 1.3163951635360718, 0.5156059861183167, -0.4074128568172455, 0.5903955698013306, -0.3857627511024475, -0.6132407188415527, 1.5714491605758667, 0.18376533687114716, -1.4261822700500488, -2.29002046585083, -0.23608073592185974, -0.8071231842041016, -0.041128505021333694, -0.5617852807044983, -0.9661797285079956, 1.6020816564559937, 0.3936334252357483, -1.3086270093917847, -0.2813568115234375, -0.3902733325958252, -0.6603114604949951, 2.5907371044158936, -1.3779240846633911, -0.19846360385417938, -0.9843114018440247, -0.5545929670333862, 1.5651991367340088, -1.139136552810669, -0.23329393565654755, -0.9939544796943665, -0.5980938076972961, -1.2733917236328125, -0.5455940365791321, -0.026195231825113297, -0.8220718502998352, 0.7250151634216309, 0.2022356539964676, -1.1789559125900269, -0.31750088930130005, -0.8765267133712769, 0.8036721348762512, -0.09481926262378693, 0.23187409341335297, 1.876050591468811, 0.5134949088096619, -0.3655608594417572, 0.662411093711853, 1.1307690143585205, 0.5366882681846619, -0.68268883228302, 0.24756811559200287, -0.7315623164176941, 0.2939988970756531, -1.357028841972351, 0.30654847621917725, -2.8230371475219727, 0.7535029053688049, -0.14044110476970673, -0.08322732895612717, 0.056390851736068726, -1.2182577848434448, 1.0957354307174683, 2.752239227294922, -1.1861447095870972, 0.48785001039505005, 0.34494543075561523, 1.1702338457107544, -1.7229927778244019, 0.32899293303489685, -0.35046395659446716, 2.114098072052002, 0.10826461762189865, 1.2187994718551636, -0.5438017249107361, -2.281498670578003, 0.5562127828598022, -1.2182258367538452, -1.1798839569091797, 0.8394408226013184, -0.8341894745826721, -0.01857755333185196, -1.3736013174057007, -0.193107470870018, -0.8166589140892029, -1.3234691619873047, 0.719415009021759, 0.10056019574403763, 0.4659903347492218, -0.5817983746528625, 0.3434131443500519, -2.1533572673797607, -1.3449645042419434, -0.279609352350235, -0.9931800365447998, 0.44730669260025024, -0.34297043085098267, 0.6844179034233093, -0.17751014232635498, 0.05680537968873978, 0.3614252507686615, 1.3869273662567139, 3.4639711380004883, 0.22129510343074799, 0.37916234135627747, -0.12346485257148743, -0.9244612455368042, 1.3738398551940918, 0.9168646335601807, -0.15095801651477814, -0.5110784769058228, -1.082749605178833, 1.209227442741394, 1.992483377456665, 1.0797271728515625, 0.06636465340852737, -0.7330507040023804, -0.7310152649879456, 0.06719691306352615, 0.1697700172662735, 0.4636229872703552, 0.9354407787322998, 0.04374134540557861, 0.07521992176771164, 1.3880454301834106, 1.2756386995315552, -0.37469160556793213, 0.4220747947692871, -0.7670993208885193, -0.46184343099594116, 0.45696762204170227, 0.31397324800491333, -0.0038546198047697544, 0.37787461280822754, -1.0203016996383667, -0.24538053572177887, -0.4526820778846741, -0.9923328161239624, -0.793955385684967, -0.49296414852142334, -0.25258588790893555, 1.6509121656417847, 0.0959562286734581, -0.4950253665447235, 0.0038904910907149315, -0.7348842024803162, -0.10372541099786758, -1.0286720991134644, 0.2405083328485489, -0.08531712740659714, -0.1722314953804016, -0.04672326147556305, 1.7844702005386353, -1.0166884660720825, -2.1646804809570312, 0.23864798247814178, 0.21273767948150635, -0.32636764645576477, 0.2083001434803009, 1.6483622789382935, 0.485194593667984, 1.4627711772918701, 1.352673053741455, 0.9866633415222168, -0.7585968971252441, -1.3347560167312622, 0.6843670010566711, 0.9386720061302185, -1.3675711154937744, 0.8191710710525513, -0.04787733405828476, -0.4834681749343872, 0.6884462833404541, 1.3197717666625977, 0.3828166425228119, -1.9593678712844849, 0.8120110630989075, -0.8774163722991943, 0.7012361288070679, 0.6524543166160583, 0.7311407923698425, 0.19419319927692413, 0.7459905743598938, -1.24558687210083, -1.1302316188812256, -0.7369070053100586, -0.6884556412696838, 1.911428689956665, -0.18958832323551178, 0.5658192038536072, -0.15167637169361115, -1.3625515699386597, -0.09163238108158112, 0.7507503032684326, 0.3832930326461792, -0.42730048298835754, 0.78386390209198, -0.6756489276885986, -1.0632492303848267, -1.4900931119918823, -0.47066882252693176, -1.0203399658203125, -0.8818156719207764, 0.9152747392654419, 0.8845111727714539, 0.21840643882751465, 1.944939374923706, 0.7428710460662842, 0.22849667072296143, -2.68296480178833, 0.9665313363075256, 0.357171893119812, -0.042890969663858414, 0.9750460982322693, 0.31806647777557373, 0.9533434510231018, 0.02109912782907486, 0.522603452205658, -2.314466953277588, 2.3108959197998047, -0.26749297976493835, 0.7129906415939331, -0.029951095581054688, -0.2491178661584854, 1.0977102518081665, 0.5130910873413086, 0.6129147410392761, -1.1694196462631226, 0.7325584888458252, -0.5719475746154785, 1.1539233922958374, 0.9254860877990723, -0.8618738651275635, -0.01499792467802763, 1.3346999883651733, 0.3940299451351166, -0.5569716691970825, -0.8659347891807556, -0.9157445430755615, 0.897020161151886, 1.8117384910583496, -0.05897074192762375, 0.013053272850811481, 0.8943126797676086, 0.548115611076355, -1.3617212772369385, 0.04125651717185974, -0.760431706905365, -0.8171887397766113, 1.6824103593826294, 1.9980742931365967, -0.005387410055845976, -0.3121641278266907, -0.7908200025558472, -1.2352920770645142, 0.8242514729499817, 0.09453075379133224, 0.15412494540214539, 0.6842854619026184, -0.6931527256965637, 1.197478175163269, 0.8902961015701294, 0.927649974822998, 0.11651948094367981, 0.2541543245315552, 0.46054860949516296, -0.38437584042549133, -1.0962307453155518, -0.2827377915382385, -1.1923298835754395, -2.409207582473755, 0.5429027080535889, -0.09795259684324265, -1.4901021718978882, -0.041838470846414566, -0.9854285717010498, 0.913077712059021, -0.4986642301082611, -1.1172980070114136, -1.5119690895080566, 0.2212231159210205, -0.1984112709760666, 0.9052837491035461, -1.6023211479187012, -0.0950605645775795, 1.2213889360427856, 1.002626657485962, -0.6610785126686096, 0.9666376709938049, 0.0882306694984436, 0.9655885696411133, 0.9303711652755737, -0.426714688539505, 0.47587454319000244, 0.06518629938364029, -1.3723047971725464, 0.3677062690258026, 1.0753068923950195, 0.20432648062705994, 1.380590796470642, -0.5325742959976196, 0.005122949369251728, 0.35131826996803284, -0.4892025589942932, -0.45634523034095764, -0.5953231453895569, 0.7625771760940552, 0.08599971234798431, -0.933478832244873, 0.14518506824970245, -0.10990288853645325, -0.15333156287670135, 0.15719878673553467, -1.5191948413848877, -0.24420411884784698, -0.28966063261032104, -0.5093735456466675, -1.1093823909759521, -0.06655985116958618, 1.3874684572219849, -0.751412034034729, -0.21955278515815735, 0.5718060731887817, 0.4395595192909241, 0.5369896292686462, 0.5650860071182251, -0.68760085105896, -0.4148350954055786, -0.2506130337715149, -0.33533838391304016, 0.30246084928512573, 1.3670250177383423, -0.12273962795734406, -0.9560863375663757, 0.7958873510360718, -0.39448896050453186, 0.10763921588659286, 1.9348020553588867, 0.06919144839048386, -0.7699759602546692, 0.2916509807109833, -0.7428732514381409, 1.8899725675582886, 1.7920536994934082, 1.2974213361740112, -0.12368945777416229, -0.9972889423370361, 0.6408663392066956, -0.26145291328430176, -0.3163831830024719, 0.9957776069641113, 0.4545293152332306, -0.16087748110294342, -1.4398345947265625, 0.5018358826637268, 1.2029497623443604, -0.817706823348999, -0.7965524792671204, 0.034918513149023056, -0.8505600094795227, 1.0321829319000244, 0.7123045921325684, 0.45651930570602417, 0.17494407296180725, 1.6652284860610962, 0.7473782896995544, -0.4602765440940857, 0.5625949501991272, 0.5157795548439026, -0.19265250861644745, -2.102142095565796, -1.130476474761963, 0.26642605662345886, -0.3850942552089691, -1.6014374494552612, 1.380815863609314, -1.1722370386123657, -0.9467021822929382, 0.5486884117126465, 0.0055338917300105095, 1.4927301406860352, 0.25754085183143616, 1.5986545085906982, 2.144150733947754, 0.9141415953636169, 0.3214878439903259, 1.2971267700195312, -0.18254797160625458, -0.4205426871776581, 1.8881763219833374, -0.43830421566963196, 0.4948559105396271, 1.0273867845535278, -0.3509737253189087, -1.0127187967300415, -0.7442521452903748, -1.1776793003082275, -0.670894980430603, 1.1602234840393066, 0.08814540505409241, -1.0983076095581055, 0.28892436623573303, 1.6809943914413452, 0.07870231568813324, -0.30657827854156494, 0.6162141561508179, 0.483305960893631, -0.7807492613792419, -0.041454389691352844, -0.8683647513389587, 0.4984528720378876, -0.09041985869407654, -0.32737594842910767, 0.33853667974472046, 0.4571300148963928, 1.2669587135314941, 0.041855935007333755, 0.0982663482427597, 1.2207767963409424, -1.356353521347046, 1.469166874885559, -0.6277452111244202, 0.2567194104194641, -2.4054789543151855, 1.35556161403656, -0.7253636121749878, 1.8635002374649048, -2.5760855674743652, 0.39690911769866943, -0.6149498224258423, -0.5226738452911377, 0.4379342794418335, -0.37953996658325195, 0.1833316683769226, -0.209688201546669, -1.0363097190856934, -0.13072870671749115, -0.7274826765060425, 0.5796464085578918, 1.1638875007629395, 1.3711527585983276, -1.0412629842758179, -0.2370503842830658, -1.7668790817260742, -0.13382560014724731, -0.6247768402099609, 0.3178958296775818, -1.9645451307296753, -0.20287252962589264, -1.9323136806488037, -2.378969430923462, -1.4372774362564087, -0.8035445809364319, 1.024206280708313, 0.14596650004386902, -0.904384434223175, 1.1591887474060059, -0.4248502552509308, -1.8388534784317017, 1.1335445642471313, -2.14939284324646 ]
https://github.com/huggingface/datasets/issues/5160
Automatically add filename for image/audio folder
@patrickvonplaten do you mean just filename or full relative path inside the repo? I think it shouldn't be breaking, at least I cannot come up with any case where it is. Maybe @mariosasko can? also I think that the problem here and in general is that Image/AudioFolder has default configuration which implies automatic label creation if there is not metadata file. It can be changed when you load the dataset with `load_dataset` but not on it's Hub page.
### Feature request When creating a custom audio of image dataset, it would be great to automatically have access to the filename. It should be both: a) Automatically displayed in the viewer b) Automatically added as a column to the dataset when doing `load_dataset` In `diffusers` our test rely quite heavily on images and audio files now and it's a bit tedious at the moment to download specific images from a datasets repo. E.g. we have a dataset of images for tests in `diffusers`: https://huggingface.co/datasets/hf-internal-testing/diffusers-images where it would be extremely nice to have direct access to the filename both visually on the datasets page (@severo ) as well as via the `load_datasets` function. We currently have some akward functionality to download images by path name: https://github.com/huggingface/diffusers/blob/2fb8fafa4b761f6fc144cf75a6f6f0ea6af3a1c1/src/diffusers/utils/testing_utils.py#L131 It would be much nicer to just go over `load_dataset(...)` ### Motivation Intuitively the filename is something people understand directly. E.g if you upload a folder of images online, it's nice if you recognize the image as well as the filename next to it directly and that you're able to use it right away. The label on the other hand is less intuitive to understand as you haven't added it yourself. ### Your contribution Not sure if I have the time to add it myself anytime soon, but it would help us a lot for `diffusers`.
455
78
Automatically add filename for image/audio folder ### Feature request When creating a custom audio of image dataset, it would be great to automatically have access to the filename. It should be both: a) Automatically displayed in the viewer b) Automatically added as a column to the dataset when doing `load_dataset` In `diffusers` our test rely quite heavily on images and audio files now and it's a bit tedious at the moment to download specific images from a datasets repo. E.g. we have a dataset of images for tests in `diffusers`: https://huggingface.co/datasets/hf-internal-testing/diffusers-images where it would be extremely nice to have direct access to the filename both visually on the datasets page (@severo ) as well as via the `load_datasets` function. We currently have some akward functionality to download images by path name: https://github.com/huggingface/diffusers/blob/2fb8fafa4b761f6fc144cf75a6f6f0ea6af3a1c1/src/diffusers/utils/testing_utils.py#L131 It would be much nicer to just go over `load_dataset(...)` ### Motivation Intuitively the filename is something people understand directly. E.g if you upload a folder of images online, it's nice if you recognize the image as well as the filename next to it directly and that you're able to use it right away. The label on the other hand is less intuitive to understand as you haven't added it yourself. ### Your contribution Not sure if I have the time to add it myself anytime soon, but it would help us a lot for `diffusers`. @patrickvonplaten do you mean just filename or full relative path inside the repo? I think it shouldn't be breaking, at least I cannot come up with any case where it is. Maybe @mariosasko can? also I think that the problem here and in general is that Image/AudioFolder has default configuration which implies automatic label creation if there is not metadata file. It can be changed when you load the dataset with `load_dataset` but not on it's Hub page.
[ -1.1710715293884277, -0.9071761965751648, -0.8276890516281128, 1.4214656352996826, -0.13508693873882294, -1.2956526279449463, 0.04042871296405792, -1.0402919054031372, 1.7197107076644897, -0.8044232130050659, 0.30991336703300476, -1.7107936143875122, 0.04518948495388031, -0.5817144513130188, -0.7966829538345337, -0.8598201274871826, -0.4532029926776886, -0.8675361275672913, 1.0432413816452026, 2.5115349292755127, 1.1851071119308472, -1.3980119228363037, 2.7103123664855957, 0.6377886533737183, -0.174467533826828, -1.0425291061401367, 0.4473544955253601, -0.001923197414726019, -1.2590358257293701, -0.4867209196090698, -0.9198863506317139, -0.026080412790179253, -0.6060992479324341, -0.5452741384506226, 0.03702002763748169, 0.3956533372402191, -0.2895917594432831, -0.3782728612422943, -0.622309148311615, -0.7683912515640259, 0.4814528822898865, -0.41691169142723083, 1.0060398578643799, -0.27217531204223633, 1.8650797605514526, -0.4910852611064911, 0.3925095200538635, 0.6690624952316284, 1.407299280166626, 0.21069000661373138, 0.0625414252281189, 0.29314112663269043, 0.31892499327659607, -0.04035118967294693, 0.39093151688575745, 1.1660187244415283, 0.6890578866004944, 0.5242745876312256, 0.7234125137329102, -2.2293965816497803, 1.3663170337677002, -0.9467126131057739, 0.30123171210289, 1.268850326538086, -0.9060343503952026, 0.3480014204978943, -1.815748929977417, -0.02998717501759529, 0.5812055468559265, -2.20458722114563, 0.23013520240783691, -1.2421140670776367, -0.4434678852558136, 1.0398190021514893, 0.21092845499515533, -1.2708736658096313, 0.3010976016521454, -0.462014764547348, 1.0448435544967651, 0.4158267378807068, 1.1801364421844482, -1.7778797149658203, -0.027070138603448868, -0.20541758835315704, 0.14620821177959442, -1.2715429067611694, -1.545663595199585, 0.5219787359237671, 0.6768357753753662, 0.6595033407211304, -0.09879500418901443, 0.9618498682975769, -0.9226916432380676, 0.7647876739501953, -0.9370483160018921, -1.6714701652526855, -1.3947166204452515, -2.2092983722686768, -2.3255624771118164, 0.8019039630889893, -0.45703667402267456, -0.5278354287147522, 2.00907039642334, -1.033161997795105, -1.7674272060394287, 1.1297223567962646, 0.23203091323375702, 0.01089269109070301, 2.3745527267456055, 0.15110328793525696, -0.7391030192375183, 0.4831444025039673, -0.6446585059165955, 0.8666687607765198, -0.43679994344711304, 1.329267978668213, 0.4082566499710083, -1.0056095123291016, 1.5781521797180176, -0.49269819259643555, 0.6005399823188782, -0.6979784369468689, -0.4903929829597473, -0.856601357460022, 0.3935759365558624, 1.9243608713150024, -0.2633792757987976, 1.6166006326675415, -0.3552365303039551, -1.6780766248703003, -1.6072427034378052, 0.8620806932449341, 0.5100627541542053, -0.7954580187797546, 0.03653041273355484, -0.3461777865886688, 0.20622241497039795, 0.0002542119473218918, 1.0276539325714111, 1.212370753288269, 0.6929581165313721, -0.2971123158931732, -0.9405076503753662, 0.28582867980003357, -0.12216320633888245, -0.6891883611679077, -1.798683762550354, -0.3631112277507782, 0.21126390993595123, 0.5736416578292847, -1.2264959812164307, 1.7243741750717163, 0.9148927927017212, 1.9549850225448608, 1.0350894927978516, -0.3474787175655365, 1.5408458709716797, 0.06575939804315567, 1.8524689674377441, -0.43269264698028564, 0.6477119326591492, -0.33477506041526794, -1.174142837524414, 0.7952111959457397, -0.3150922954082489, -1.9721859693527222, -0.7121821045875549, -0.7551063299179077, -0.21398235857486725, -0.7295131087303162, 0.8760870695114136, -0.3027772009372711, -1.3926050662994385, 0.24366779625415802, -0.5901620984077454, 0.09853137284517288, -1.236026644706726, 0.22018682956695557, 0.7790550589561462, -0.7438417673110962, 0.04521205276250839, -0.29264628887176514, -1.3321558237075806, -0.4730609953403473, 0.29295802116394043, 1.9280765056610107, -0.7518823742866516, 0.8249441981315613, 1.0603798627853394, -0.6925491094589233, 0.06299972534179688, 0.3963793218135834, -0.3107830584049225, 0.8171977996826172, -1.0778263807296753, -0.3563435673713684, 1.1912741661071777, -0.16825799643993378, -0.6096403002738953, 1.341495156288147, 0.8140859007835388, -1.0246392488479614, -0.1447121649980545, -0.1957428902387619, -0.8440340161323547, -0.021605107933282852, -1.6439658403396606, -0.11221424490213394, 0.3014817237854004, -1.4815995693206787, -0.5127207636833191, -0.286467045545578, 1.2123987674713135, -0.19568923115730286, 1.4169752597808838, -0.4176776707172394, -0.23469600081443787, -0.3888112008571625, -0.3853972554206848, 0.1026626005768776, -0.20582711696624756, -0.6204416751861572, 0.232413649559021, -0.740952730178833, 0.3166324496269226, 1.4532570838928223, 0.37398266792297363, 0.07110890746116638, 0.4719298183917999, 1.1391236782073975, 0.3827182352542877, -0.016237346455454826, -0.8656165599822998, -1.5127997398376465, 2.020400047302246, -1.3988897800445557, 1.9821417331695557, 0.8476260304450989, -0.008551782928407192, -1.8215811252593994, -1.8007614612579346, 1.3641666173934937, 1.1476984024047852, 2.42297101020813, 0.6119138598442078, 0.38786184787750244, -0.7829824686050415, -0.6381120681762695, 0.40999093651771545, -1.0252656936645508, -0.8458017110824585, 0.15752290189266205, 2.350494623184204, 1.7505122423171997, -0.48104968667030334, -0.2669260799884796, -0.9771932363510132, 1.3671208620071411, -0.16327698528766632, 0.2007559835910797, 1.9774785041809082, -0.26282164454460144, -1.0961308479309082, 1.2800155878067017, -2.2914295196533203, 0.17627081274986267, 1.9812495708465576, 0.2714841663837433, 0.10039500892162323, -1.4385095834732056, -0.7040456533432007, -0.2086470127105713, -0.357857346534729, -1.2777186632156372, 0.52435702085495, -0.3305647373199463, -0.7921217083930969, -1.4614845514297485, 0.2142922580242157, -1.1234068870544434, -1.6417957544326782, 0.2644354999065399, 1.9305081367492676, 1.989578366279602, -0.834657609462738, 1.483014464378357, -0.23076389729976654, 0.17381295561790466, 1.2344224452972412, 1.24020516872406, 3.19474720954895, 1.8739800453186035, -1.257583498954773, 0.6128036379814148, -0.18227875232696533, -0.46262750029563904, 1.0903866291046143, -1.1374258995056152, 1.1944893598556519, -0.20785720646381378, -1.2052685022354126, -1.1915676593780518, 0.9822293519973755, 0.5374858975410461, 0.06390375643968582, -0.5425899624824524, 1.1979718208312988, -0.014533272944390774, 1.3169609308242798, 0.5328710079193115, -0.424511194229126, 0.5991466045379639, -0.37446966767311096, -0.6163066029548645, 1.5626479387283325, 0.1911003291606903, -1.4070093631744385, -2.3006863594055176, -0.2572918236255646, -0.8161290884017944, -0.022382432594895363, -0.5583624243736267, -0.9706747531890869, 1.5982383489608765, 0.3716055750846863, -1.3248023986816406, -0.2958754301071167, -0.38927069306373596, -0.630154550075531, 2.593863010406494, -1.4018367528915405, -0.19616015255451202, -0.9565572738647461, -0.5631887912750244, 1.620836853981018, -1.139238715171814, -0.2582671642303467, -1.0239616632461548, -0.5694119334220886, -1.2835160493850708, -0.5783676505088806, -0.026913490146398544, -0.7849249243736267, 0.7250109314918518, 0.23240119218826294, -1.2088676691055298, -0.32133665680885315, -0.8779460787773132, 0.8509856462478638, -0.10631759464740753, 0.20980986952781677, 1.8936141729354858, 0.5081441402435303, -0.4094317555427551, 0.6751466989517212, 1.1391267776489258, 0.5503571033477783, -0.6989054083824158, 0.21519207954406738, -0.7420469522476196, 0.2968692183494568, -1.389945387840271, 0.28022992610931396, -2.815553665161133, 0.7637485861778259, -0.09884645789861679, -0.08031108230352402, 0.06357095390558243, -1.2398629188537598, 1.0570460557937622, 2.7506890296936035, -1.1753387451171875, 0.45708146691322327, 0.341907262802124, 1.2073010206222534, -1.705076813697815, 0.29120874404907227, -0.38178780674934387, 2.133390426635742, 0.11305362731218338, 1.2242826223373413, -0.5048877000808716, -2.2830214500427246, 0.5306481122970581, -1.2195909023284912, -1.1878639459609985, 0.8413225412368774, -0.8421033620834351, -0.010193601250648499, -1.4054359197616577, -0.1967770755290985, -0.8473040461540222, -1.2851048707962036, 0.7637534737586975, 0.09905370324850082, 0.46745765209198, -0.6182780265808105, 0.3414883315563202, -2.1374127864837646, -1.3574573993682861, -0.279765248298645, -0.9780825972557068, 0.44667738676071167, -0.33026397228240967, 0.6822962760925293, -0.19061744213104248, 0.0352354422211647, 0.38403066992759705, 1.3845820426940918, 3.4381449222564697, 0.20901256799697876, 0.3660951554775238, -0.1596570461988449, -0.923828661441803, 1.3790199756622314, 0.9092886447906494, -0.15689095854759216, -0.5256612300872803, -1.0555708408355713, 1.1924283504486084, 1.976576328277588, 1.0493056774139404, 0.06638985127210617, -0.7264646887779236, -0.7100670337677002, 0.05242875963449478, 0.1610892415046692, 0.48880794644355774, 0.9604458212852478, 0.02053179405629635, 0.07767796516418457, 1.3900041580200195, 1.251953125, -0.3679378628730774, 0.4339059293270111, -0.7672668695449829, -0.49208003282546997, 0.4359825551509857, 0.32342010736465454, 0.005156372673809528, 0.37874752283096313, -1.0297305583953857, -0.2367798089981079, -0.430687814950943, -1.0029003620147705, -0.788743257522583, -0.48654669523239136, -0.23332902789115906, 1.645882248878479, 0.09758488833904266, -0.5004145503044128, -0.01148603018373251, -0.7263060808181763, -0.11194443702697754, -1.035394310951233, 0.2405100166797638, -0.0977369174361229, -0.16194069385528564, -0.04022800177335739, 1.755173683166504, -0.99476158618927, -2.119049072265625, 0.2691494822502136, 0.21928516030311584, -0.3060213625431061, 0.20878641307353973, 1.636630892753601, 0.4950971305370331, 1.4449468851089478, 1.3631690740585327, 1.0114513635635376, -0.7327786684036255, -1.314329981803894, 0.690456211566925, 0.9230291843414307, -1.3817641735076904, 0.842867910861969, -0.06188146024942398, -0.494369775056839, 0.6659307479858398, 1.334939956665039, 0.3893621265888214, -1.9745805263519287, 0.8336383104324341, -0.8880884647369385, 0.6799589395523071, 0.6753408312797546, 0.7351567149162292, 0.2001093477010727, 0.7781962156295776, -1.2123185396194458, -1.1538993120193481, -0.7535851001739502, -0.6968933343887329, 1.922884464263916, -0.20949804782867432, 0.5558512806892395, -0.14385537803173065, -1.3585386276245117, -0.11944437772035599, 0.7580242156982422, 0.3671250641345978, -0.4408298432826996, 0.7891254425048828, -0.6843721270561218, -1.0682004690170288, -1.4494564533233643, -0.4615524113178253, -1.0416287183761597, -0.88462233543396, 0.9166051745414734, 0.8922035098075867, 0.25054702162742615, 1.9051673412322998, 0.7350533604621887, 0.2405441701412201, -2.690706729888916, 0.9724217653274536, 0.35356682538986206, -0.04394915699958801, 0.9593576192855835, 0.315565824508667, 0.9617934823036194, 0.030729996040463448, 0.5472455620765686, -2.3322110176086426, 2.297664165496826, -0.27720579504966736, 0.7142763137817383, -0.026784323155879974, -0.26187944412231445, 1.0886965990066528, 0.5243386030197144, 0.6146470308303833, -1.1462740898132324, 0.7235091328620911, -0.5909304022789001, 1.137524962425232, 0.955889880657196, -0.8768108487129211, 0.015196098014712334, 1.3363583087921143, 0.38171470165252686, -0.5634682178497314, -0.9054924845695496, -0.8978061079978943, 0.9067432880401611, 1.8122280836105347, -0.0550413653254509, 0.0064649758860468864, 0.9001926183700562, 0.6002544164657593, -1.3559178113937378, 0.06797023117542267, -0.777097225189209, -0.8227859735488892, 1.68565833568573, 1.9939513206481934, -0.03515060991048813, -0.2992178499698639, -0.7936787009239197, -1.2128241062164307, 0.8099974393844604, 0.0996420606970787, 0.1469731330871582, 0.6916863918304443, -0.7095733284950256, 1.203647255897522, 0.8513467311859131, 0.9457106590270996, 0.12030809372663498, 0.272819846868515, 0.47599244117736816, -0.3679223954677582, -1.0828129053115845, -0.26118385791778564, -1.1835623979568481, -2.4019722938537598, 0.5204927325248718, -0.11527249217033386, -1.4697935581207275, -0.025547847151756287, -0.9743463397026062, 0.8853257894515991, -0.5207017064094543, -1.1090068817138672, -1.5290501117706299, 0.22244729101657867, -0.1767156720161438, 0.8936969041824341, -1.6123063564300537, -0.09929072856903076, 1.193302035331726, 1.0001877546310425, -0.6604210734367371, 0.9700638651847839, 0.11147245019674301, 0.9836180210113525, 0.9457155466079712, -0.414972186088562, 0.4629983603954315, 0.06726980209350586, -1.3497040271759033, 0.37503647804260254, 1.085260033607483, 0.21959538757801056, 1.417357325553894, -0.5406358242034912, -0.007815256714820862, 0.3630697727203369, -0.49983635544776917, -0.4324876368045807, -0.6254258155822754, 0.7375719547271729, 0.07297791540622711, -0.9150043725967407, 0.11241810768842697, -0.10412538051605225, -0.1695163995027542, 0.16546446084976196, -1.5266004800796509, -0.22025062143802643, -0.29483261704444885, -0.4991883337497711, -1.120530366897583, -0.05935400724411011, 1.3846948146820068, -0.7452338933944702, -0.2306075096130371, 0.5426350831985474, 0.4239232540130615, 0.5191525220870972, 0.5599794983863831, -0.7205634713172913, -0.39440956711769104, -0.24369950592517853, -0.3527492880821228, 0.2861475944519043, 1.377996802330017, -0.12731166183948517, -0.9405766725540161, 0.7525318264961243, -0.4037327468395233, 0.08130506426095963, 1.9525953531265259, 0.08809084445238113, -0.7450440526008606, 0.2927563488483429, -0.766745924949646, 1.8762041330337524, 1.7930322885513306, 1.3058841228485107, -0.11523327976465225, -0.9743061661720276, 0.6696548461914062, -0.281896710395813, -0.3391406834125519, 0.995231032371521, 0.43935373425483704, -0.15111026167869568, -1.457144021987915, 0.5602516531944275, 1.2430452108383179, -0.8006508350372314, -0.7622699737548828, 0.0003560548648238182, -0.8497389554977417, 1.0559518337249756, 0.7145359516143799, 0.43774038553237915, 0.17372679710388184, 1.6424126625061035, 0.7455710768699646, -0.45361852645874023, 0.561613142490387, 0.5242004990577698, -0.17910964787006378, -2.112100124359131, -1.1617228984832764, 0.29105815291404724, -0.3571621775627136, -1.618950366973877, 1.3970640897750854, -1.1964191198349, -0.9715986847877502, 0.5348459482192993, 0.005358712747693062, 1.4700264930725098, 0.2903652489185333, 1.5978928804397583, 2.1558616161346436, 0.9454307556152344, 0.3346298038959503, 1.3064664602279663, -0.16131120920181274, -0.4137454032897949, 1.8805134296417236, -0.46500006318092346, 0.48824501037597656, 1.0147993564605713, -0.3353883624076843, -1.0278868675231934, -0.7535341382026672, -1.175007939338684, -0.6675370335578918, 1.162795901298523, 0.05103345960378647, -1.1170824766159058, 0.2932927906513214, 1.6638294458389282, 0.06796224415302277, -0.30323177576065063, 0.6599791646003723, 0.459850937128067, -0.7631513476371765, -0.04745239019393921, -0.8598852157592773, 0.49795183539390564, -0.08938667923212051, -0.3402264714241028, 0.3510572910308838, 0.4774061441421509, 1.2753055095672607, 0.038043320178985596, 0.07754106819629669, 1.2205930948257446, -1.3585880994796753, 1.4695111513137817, -0.633000910282135, 0.25886279344558716, -2.450932264328003, 1.3749032020568848, -0.7273010611534119, 1.9046605825424194, -2.5509121417999268, 0.3973577618598938, -0.6098468899726868, -0.5343006253242493, 0.44843047857284546, -0.3640972971916199, 0.1692315936088562, -0.17726431787014008, -1.0493289232254028, -0.09810526669025421, -0.722734808921814, 0.5907456874847412, 1.1005513668060303, 1.3570431470870972, -1.0535908937454224, -0.24563106894493103, -1.7722911834716797, -0.13714654743671417, -0.6315566897392273, 0.3014059066772461, -1.9827759265899658, -0.210409015417099, -1.9548612833023071, -2.3570964336395264, -1.4325790405273438, -0.8233181834220886, 1.0250072479248047, 0.1593807488679886, -0.9029494524002075, 1.1824560165405273, -0.4139854907989502, -1.8617115020751953, 1.1145188808441162, -2.1440861225128174 ]
https://github.com/huggingface/datasets/issues/5160
Automatically add filename for image/audio folder
> also I think that the problem here and in general Image/AudioFolder has default configuration which implies automatic label creation if there is not metadata file Yea I agree it's often the wrong default. We can also imagine adding the builder's parameters as YAML in the repo.
### Feature request When creating a custom audio of image dataset, it would be great to automatically have access to the filename. It should be both: a) Automatically displayed in the viewer b) Automatically added as a column to the dataset when doing `load_dataset` In `diffusers` our test rely quite heavily on images and audio files now and it's a bit tedious at the moment to download specific images from a datasets repo. E.g. we have a dataset of images for tests in `diffusers`: https://huggingface.co/datasets/hf-internal-testing/diffusers-images where it would be extremely nice to have direct access to the filename both visually on the datasets page (@severo ) as well as via the `load_datasets` function. We currently have some akward functionality to download images by path name: https://github.com/huggingface/diffusers/blob/2fb8fafa4b761f6fc144cf75a6f6f0ea6af3a1c1/src/diffusers/utils/testing_utils.py#L131 It would be much nicer to just go over `load_dataset(...)` ### Motivation Intuitively the filename is something people understand directly. E.g if you upload a folder of images online, it's nice if you recognize the image as well as the filename next to it directly and that you're able to use it right away. The label on the other hand is less intuitive to understand as you haven't added it yourself. ### Your contribution Not sure if I have the time to add it myself anytime soon, but it would help us a lot for `diffusers`.
455
47
Automatically add filename for image/audio folder ### Feature request When creating a custom audio of image dataset, it would be great to automatically have access to the filename. It should be both: a) Automatically displayed in the viewer b) Automatically added as a column to the dataset when doing `load_dataset` In `diffusers` our test rely quite heavily on images and audio files now and it's a bit tedious at the moment to download specific images from a datasets repo. E.g. we have a dataset of images for tests in `diffusers`: https://huggingface.co/datasets/hf-internal-testing/diffusers-images where it would be extremely nice to have direct access to the filename both visually on the datasets page (@severo ) as well as via the `load_datasets` function. We currently have some akward functionality to download images by path name: https://github.com/huggingface/diffusers/blob/2fb8fafa4b761f6fc144cf75a6f6f0ea6af3a1c1/src/diffusers/utils/testing_utils.py#L131 It would be much nicer to just go over `load_dataset(...)` ### Motivation Intuitively the filename is something people understand directly. E.g if you upload a folder of images online, it's nice if you recognize the image as well as the filename next to it directly and that you're able to use it right away. The label on the other hand is less intuitive to understand as you haven't added it yourself. ### Your contribution Not sure if I have the time to add it myself anytime soon, but it would help us a lot for `diffusers`. > also I think that the problem here and in general Image/AudioFolder has default configuration which implies automatic label creation if there is not metadata file Yea I agree it's often the wrong default. We can also imagine adding the builder's parameters as YAML in the repo.
[ -1.1930876970291138, -0.931432843208313, -0.8455350399017334, 1.4733166694641113, -0.12702994048595428, -1.300837755203247, 0.0185367651283741, -1.0334440469741821, 1.7269428968429565, -0.8089510798454285, 0.3132997155189514, -1.70734441280365, 0.04541242867708206, -0.5670621991157532, -0.7637475728988647, -0.8829795718193054, -0.4521940350532532, -0.8465214371681213, 1.0695068836212158, 2.506279945373535, 1.2022743225097656, -1.4395135641098022, 2.721696376800537, 0.6349112391471863, -0.17005036771297455, -1.0567584037780762, 0.4540684223175049, 0.017307521775364876, -1.2692614793777466, -0.529499888420105, -0.8945087194442749, -0.0031235557980835438, -0.6105062961578369, -0.5339336395263672, 0.046759091317653656, 0.3761301636695862, -0.29184281826019287, -0.38783371448516846, -0.609377920627594, -0.7800250053405762, 0.4512280225753784, -0.41121840476989746, 0.9858664274215698, -0.2749456763267517, 1.8291730880737305, -0.45358145236968994, 0.39347076416015625, 0.6688084602355957, 1.401263952255249, 0.19469113647937775, 0.05523277074098587, 0.2996426820755005, 0.32819926738739014, -0.04195782169699669, 0.41310906410217285, 1.1635905504226685, 0.6702880859375, 0.5118322372436523, 0.717884361743927, -2.245204210281372, 1.3729597330093384, -0.9534122943878174, 0.28465503454208374, 1.2794764041900635, -0.8915748000144958, 0.34135568141937256, -1.8080759048461914, -0.05622495710849762, 0.5897836089134216, -2.2111546993255615, 0.21508340537548065, -1.2535631656646729, -0.4415632486343384, 1.0398496389389038, 0.2063959538936615, -1.2599866390228271, 0.2998799681663513, -0.4639461040496826, 1.0470893383026123, 0.4102579951286316, 1.1879713535308838, -1.7782748937606812, -0.023820500820875168, -0.19091957807540894, 0.12150408327579498, -1.2893882989883423, -1.5620981454849243, 0.48681390285491943, 0.6639693379402161, 0.66023850440979, -0.06532949954271317, 0.9254261255264282, -0.9085506796836853, 0.7811285853385925, -0.9428783059120178, -1.6669434309005737, -1.3951692581176758, -2.2210285663604736, -2.337245225906372, 0.8065546154975891, -0.44917362928390503, -0.5259957909584045, 2.0238213539123535, -1.0244625806808472, -1.7846969366073608, 1.15119206905365, 0.2519915699958801, -0.0005058431997895241, 2.3870697021484375, 0.1487644761800766, -0.7297852039337158, 0.48091983795166016, -0.6414368152618408, 0.8708691000938416, -0.4526103734970093, 1.3093221187591553, 0.41787058115005493, -1.000705361366272, 1.57341730594635, -0.483639657497406, 0.585242509841919, -0.7137231230735779, -0.4610678553581238, -0.8810707330703735, 0.42347365617752075, 1.9013563394546509, -0.23294897377490997, 1.608799934387207, -0.34617388248443604, -1.6466012001037598, -1.5952879190444946, 0.8596038818359375, 0.5168966054916382, -0.8177708387374878, 0.01687583513557911, -0.3025171756744385, 0.23188753426074982, 0.03336147964000702, 1.040177822113037, 1.2164748907089233, 0.6697708964347839, -0.32420527935028076, -0.9441166520118713, 0.2760496735572815, -0.11426863819360733, -0.687079906463623, -1.8002151250839233, -0.3458218574523926, 0.21431273221969604, 0.5668043494224548, -1.2526257038116455, 1.6958684921264648, 0.9228467345237732, 1.95046865940094, 1.029382348060608, -0.3292069435119629, 1.5548760890960693, 0.06792698800563812, 1.8657290935516357, -0.4271999001502991, 0.6487524509429932, -0.3223070502281189, -1.1770751476287842, 0.8138173222541809, -0.3018641471862793, -1.9739445447921753, -0.7314101457595825, -0.7553585171699524, -0.23243755102157593, -0.7029033303260803, 0.8940728306770325, -0.32019078731536865, -1.3613218069076538, 0.2502729296684265, -0.6129782795906067, 0.07817694544792175, -1.2324446439743042, 0.20156148076057434, 0.7667802572250366, -0.7313555479049683, 0.04789083078503609, -0.2834188938140869, -1.3393498659133911, -0.4715076684951782, 0.31527984142303467, 1.9031221866607666, -0.7329270839691162, 0.8117223978042603, 1.0598851442337036, -0.6918142437934875, 0.06422799825668335, 0.3771783709526062, -0.29261380434036255, 0.8401875495910645, -1.091995120048523, -0.3643198609352112, 1.1800068616867065, -0.17766839265823364, -0.6319788098335266, 1.3263919353485107, 0.8107408285140991, -1.03651762008667, -0.16232457756996155, -0.1965917944908142, -0.8921896815299988, 0.00012438278645277023, -1.6453161239624023, -0.13068035244941711, 0.3114548921585083, -1.4979875087738037, -0.4809245467185974, -0.30076491832733154, 1.2441283464431763, -0.1917313039302826, 1.4330363273620605, -0.4092562794685364, -0.24801333248615265, -0.37266647815704346, -0.38040846586227417, 0.10075095295906067, -0.19993604719638824, -0.6145744919776917, 0.23604317009449005, -0.7353586554527283, 0.31162530183792114, 1.4723478555679321, 0.3861675262451172, 0.08433609455823898, 0.46743547916412354, 1.1266601085662842, 0.38770341873168945, -0.01587873511016369, -0.8604738116264343, -1.4960252046585083, 2.0525782108306885, -1.3772822618484497, 1.9780035018920898, 0.8604850769042969, 0.005027555860579014, -1.8287321329116821, -1.8306249380111694, 1.366918683052063, 1.130740761756897, 2.444805383682251, 0.638462245464325, 0.38092488050460815, -0.7851545214653015, -0.6546631455421448, 0.38808536529541016, -1.01265287399292, -0.8660025596618652, 0.1571550816297531, 2.3458993434906006, 1.7666679620742798, -0.4357626438140869, -0.23206940293312073, -0.9616373777389526, 1.3917968273162842, -0.145236998796463, 0.20291075110435486, 1.9851555824279785, -0.22697176039218903, -1.106265664100647, 1.2670118808746338, -2.2640559673309326, 0.16385096311569214, 1.9987647533416748, 0.28500473499298096, 0.0785062313079834, -1.4574371576309204, -0.7316849827766418, -0.20942015945911407, -0.3732796907424927, -1.285241723060608, 0.5299805402755737, -0.33461320400238037, -0.8032262921333313, -1.468632459640503, 0.19232302904129028, -1.133471965789795, -1.6436103582382202, 0.2444160133600235, 1.9322443008422852, 1.981402039527893, -0.8190569877624512, 1.48552668094635, -0.20742498338222504, 0.16664069890975952, 1.2512588500976562, 1.2305635213851929, 3.194082021713257, 1.865235686302185, -1.2709436416625977, 0.5996121764183044, -0.15734510123729706, -0.47362226247787476, 1.08498215675354, -1.1527479887008667, 1.1931713819503784, -0.18744993209838867, -1.212428092956543, -1.2091964483261108, 0.9897766709327698, 0.5503134727478027, 0.06487655639648438, -0.5625067949295044, 1.194035530090332, -0.017343122512102127, 1.2943780422210693, 0.5135244131088257, -0.4226568341255188, 0.580882728099823, -0.383381724357605, -0.6368188261985779, 1.560160517692566, 0.16919173300266266, -1.4287388324737549, -2.3172178268432617, -0.23794373869895935, -0.8053780794143677, -0.04413328319787979, -0.5657840371131897, -0.9479100108146667, 1.610607624053955, 0.3673367500305176, -1.327305793762207, -0.3005567193031311, -0.40039825439453125, -0.6406009197235107, 2.586149215698242, -1.3761324882507324, -0.19914811849594116, -0.9691482782363892, -0.5591568946838379, 1.570648431777954, -1.1264770030975342, -0.23923251032829285, -1.0061461925506592, -0.5667378902435303, -1.253616452217102, -0.5433960556983948, -0.01982000097632408, -0.7836322784423828, 0.7336355447769165, 0.2204030305147171, -1.1818437576293945, -0.32167768478393555, -0.8545776605606079, 0.8253874778747559, -0.10426007211208344, 0.22368043661117554, 1.9001001119613647, 0.5056765079498291, -0.37024956941604614, 0.6628716588020325, 1.1304781436920166, 0.5468308925628662, -0.6781562566757202, 0.21115180850028992, -0.7283648252487183, 0.28801268339157104, -1.3592156171798706, 0.30222564935684204, -2.8345158100128174, 0.741411030292511, -0.11699531227350235, -0.09779684245586395, 0.07362865656614304, -1.2188390493392944, 1.0713638067245483, 2.755025625228882, -1.1604472398757935, 0.4712280035018921, 0.34316426515579224, 1.1869840621948242, -1.7320990562438965, 0.3166545629501343, -0.373848021030426, 2.1321284770965576, 0.10535556823015213, 1.2134342193603516, -0.5350072979927063, -2.278917074203491, 0.5315926671028137, -1.2219456434249878, -1.1840870380401611, 0.8293646574020386, -0.8428005576133728, -0.008841658011078835, -1.414950966835022, -0.20045658946037292, -0.8291533589363098, -1.2815221548080444, 0.7429161071777344, 0.11324956268072128, 0.4596789479255676, -0.5872165560722351, 0.3392676115036011, -2.129007577896118, -1.376335859298706, -0.27468693256378174, -1.002105951309204, 0.4520954489707947, -0.3565215468406677, 0.6766504645347595, -0.16402177512645721, 0.05157632380723953, 0.34909605979919434, 1.3907219171524048, 3.44568133354187, 0.2068796455860138, 0.375124990940094, -0.1468084305524826, -0.9193179607391357, 1.4104478359222412, 0.9159541130065918, -0.16363203525543213, -0.5151971578598022, -1.076655387878418, 1.2160301208496094, 1.981475591659546, 1.056275486946106, 0.07668565958738327, -0.7294867634773254, -0.7476692199707031, 0.038120612502098083, 0.15483590960502625, 0.4861001968383789, 0.9506099224090576, 0.03346310183405876, 0.06608027219772339, 1.4052408933639526, 1.2591264247894287, -0.36338692903518677, 0.44305598735809326, -0.7727285027503967, -0.4873983860015869, 0.43551188707351685, 0.3118396997451782, 0.004509015940129757, 0.37708961963653564, -1.0212534666061401, -0.23682145774364471, -0.4469553828239441, -0.9937372803688049, -0.7743701338768005, -0.47058916091918945, -0.24639087915420532, 1.6419850587844849, 0.09483523666858673, -0.49898213148117065, 0.002756853587925434, -0.7280921936035156, -0.12094050645828247, -1.0234919786453247, 0.26409780979156494, -0.10806187987327576, -0.1655084639787674, -0.05206214264035225, 1.7689436674118042, -0.997619092464447, -2.14249324798584, 0.23477478325366974, 0.21993108093738556, -0.3146267533302307, 0.22814345359802246, 1.6414223909378052, 0.4929649233818054, 1.454687476158142, 1.3770638704299927, 0.9842594861984253, -0.7562745213508606, -1.3212403059005737, 0.6750782132148743, 0.9100542664527893, -1.3689215183258057, 0.8325739502906799, -0.08775683492422104, -0.4953303337097168, 0.6899828314781189, 1.3323333263397217, 0.3647262454032898, -1.9806722402572632, 0.850873589515686, -0.851996660232544, 0.6967751979827881, 0.665728747844696, 0.744777262210846, 0.1989050954580307, 0.73371821641922, -1.2137025594711304, -1.1488871574401855, -0.7626402378082275, -0.6793755888938904, 1.909603476524353, -0.20504306256771088, 0.5688361525535583, -0.15659181773662567, -1.3580286502838135, -0.09499935805797577, 0.7426071166992188, 0.388698935508728, -0.4112231135368347, 0.7740804553031921, -0.6784469485282898, -1.062251329421997, -1.465156078338623, -0.45551103353500366, -1.0283617973327637, -0.8871878385543823, 0.9174942374229431, 0.8949959874153137, 0.22310426831245422, 1.9262170791625977, 0.7248944044113159, 0.2272203266620636, -2.689887285232544, 0.9682093858718872, 0.3267262578010559, -0.04771140590310097, 0.9765120148658752, 0.31207817792892456, 0.982099175453186, 0.032671209424734116, 0.5171955227851868, -2.2987356185913086, 2.3039724826812744, -0.27891576290130615, 0.7189164161682129, -0.055645156651735306, -0.2470683753490448, 1.0923466682434082, 0.5212592482566833, 0.6345480680465698, -1.1463253498077393, 0.744154155254364, -0.5552342534065247, 1.1357457637786865, 0.9331431984901428, -0.8548352718353271, 0.0005140425637364388, 1.3339369297027588, 0.3888029456138611, -0.5791817307472229, -0.89117830991745, -0.8987631797790527, 0.8831459879875183, 1.808120608329773, -0.07243043929338455, 0.009469674900174141, 0.8891652226448059, 0.5648964643478394, -1.3597055673599243, 0.061790451407432556, -0.7667760252952576, -0.835757315158844, 1.6820142269134521, 1.9798741340637207, -0.03895440697669983, -0.3134598731994629, -0.7992320656776428, -1.2318202257156372, 0.7906193137168884, 0.0945817157626152, 0.1420748233795166, 0.6712185740470886, -0.6972973346710205, 1.217557430267334, 0.8794136047363281, 0.9437320828437805, 0.09810774773359299, 0.2569575905799866, 0.46401888132095337, -0.37757182121276855, -1.1037793159484863, -0.28034472465515137, -1.187704086303711, -2.3789291381835938, 0.5294589400291443, -0.11112528294324875, -1.4718014001846313, -0.029048552736639977, -0.9715982675552368, 0.9126607179641724, -0.5098826289176941, -1.124443769454956, -1.520141839981079, 0.20452535152435303, -0.20220765471458435, 0.8887987732887268, -1.6061683893203735, -0.0982445478439331, 1.2007437944412231, 1.0085299015045166, -0.6638484001159668, 0.9573425650596619, 0.10627827048301697, 0.9764248728752136, 0.950657308101654, -0.4235379099845886, 0.47273820638656616, 0.06409452110528946, -1.3494744300842285, 0.3648316264152527, 1.0597913265228271, 0.23393261432647705, 1.393833041191101, -0.5555733442306519, -0.004481173120439053, 0.350632905960083, -0.46311748027801514, -0.41583919525146484, -0.6154201030731201, 0.7576043009757996, 0.05353280156850815, -0.92960125207901, 0.12104642391204834, -0.11531557887792587, -0.1688663363456726, 0.15892232954502106, -1.514210820198059, -0.19451549649238586, -0.28659480810165405, -0.4806947112083435, -1.130199909210205, -0.03497989848256111, 1.3651704788208008, -0.7591714859008789, -0.23165246844291687, 0.562799870967865, 0.4327978491783142, 0.5382227897644043, 0.577353835105896, -0.6964325308799744, -0.3995554447174072, -0.25251680612564087, -0.3466463088989258, 0.2861907482147217, 1.3503376245498657, -0.13018271327018738, -0.9664819240570068, 0.7542834877967834, -0.40294182300567627, 0.07423464953899384, 1.9643265008926392, 0.05314609035849571, -0.7547145485877991, 0.2998431921005249, -0.7239434123039246, 1.8713313341140747, 1.8133419752120972, 1.317599892616272, -0.12028347700834274, -0.9863650798797607, 0.6635071039199829, -0.2963401675224304, -0.3171221613883972, 0.9940471053123474, 0.4556546211242676, -0.1507505178451538, -1.457437515258789, 0.5131527781486511, 1.2316594123840332, -0.803588330745697, -0.7636890411376953, 0.010130271315574646, -0.8388230204582214, 1.0543211698532104, 0.7357518672943115, 0.45043665170669556, 0.1630028635263443, 1.6399805545806885, 0.7589952349662781, -0.44766008853912354, 0.5620878338813782, 0.5603355765342712, -0.200967475771904, -2.1147286891937256, -1.166562557220459, 0.2636285424232483, -0.3521340489387512, -1.6129515171051025, 1.3900896310806274, -1.1946063041687012, -0.9688078761100769, 0.5506628751754761, -0.0010228333994746208, 1.490598440170288, 0.2684103846549988, 1.6035343408584595, 2.173046588897705, 0.9450312256813049, 0.3404596447944641, 1.3048940896987915, -0.1806396245956421, -0.4079555869102478, 1.9011385440826416, -0.455569326877594, 0.4809262752532959, 1.0166280269622803, -0.3548634648323059, -1.0181301832199097, -0.7454867362976074, -1.2038812637329102, -0.6584662795066833, 1.1576673984527588, 0.05746401846408844, -1.0962611436843872, 0.30437517166137695, 1.6730166673660278, 0.07161590456962585, -0.3321388363838196, 0.6260780096054077, 0.479087233543396, -0.7699788212776184, -0.05925419181585312, -0.8591486215591431, 0.48232537508010864, -0.09590183198451996, -0.32582592964172363, 0.360199511051178, 0.43684226274490356, 1.2787806987762451, 0.05194338783621788, 0.10492949187755585, 1.2241787910461426, -1.3290635347366333, 1.4442071914672852, -0.6513881683349609, 0.24633575975894928, -2.4219415187835693, 1.3789182901382446, -0.7422923445701599, 1.8836978673934937, -2.5668132305145264, 0.40148991346359253, -0.6309093236923218, -0.5267035365104675, 0.4512205719947815, -0.37327849864959717, 0.15532530844211578, -0.2062256783246994, -1.0174654722213745, -0.12235577404499054, -0.7233179807662964, 0.5891730785369873, 1.1361370086669922, 1.3462040424346924, -1.0396186113357544, -0.24399980902671814, -1.7769187688827515, -0.13883540034294128, -0.6131526231765747, 0.3152846097946167, -1.9685180187225342, -0.20049510896205902, -1.9509601593017578, -2.3764398097991943, -1.433645248413086, -0.8102940917015076, 1.0295920372009277, 0.16784749925136566, -0.8945811986923218, 1.1759986877441406, -0.3985931873321533, -1.832354187965393, 1.1154067516326904, -2.1355185508728027 ]
https://github.com/huggingface/datasets/issues/5160
Automatically add filename for image/audio folder
@lhoestq yes I also got the idea of some YAML config! not sure of what priority it is though.
### Feature request When creating a custom audio of image dataset, it would be great to automatically have access to the filename. It should be both: a) Automatically displayed in the viewer b) Automatically added as a column to the dataset when doing `load_dataset` In `diffusers` our test rely quite heavily on images and audio files now and it's a bit tedious at the moment to download specific images from a datasets repo. E.g. we have a dataset of images for tests in `diffusers`: https://huggingface.co/datasets/hf-internal-testing/diffusers-images where it would be extremely nice to have direct access to the filename both visually on the datasets page (@severo ) as well as via the `load_datasets` function. We currently have some akward functionality to download images by path name: https://github.com/huggingface/diffusers/blob/2fb8fafa4b761f6fc144cf75a6f6f0ea6af3a1c1/src/diffusers/utils/testing_utils.py#L131 It would be much nicer to just go over `load_dataset(...)` ### Motivation Intuitively the filename is something people understand directly. E.g if you upload a folder of images online, it's nice if you recognize the image as well as the filename next to it directly and that you're able to use it right away. The label on the other hand is less intuitive to understand as you haven't added it yourself. ### Your contribution Not sure if I have the time to add it myself anytime soon, but it would help us a lot for `diffusers`.
455
19
Automatically add filename for image/audio folder ### Feature request When creating a custom audio of image dataset, it would be great to automatically have access to the filename. It should be both: a) Automatically displayed in the viewer b) Automatically added as a column to the dataset when doing `load_dataset` In `diffusers` our test rely quite heavily on images and audio files now and it's a bit tedious at the moment to download specific images from a datasets repo. E.g. we have a dataset of images for tests in `diffusers`: https://huggingface.co/datasets/hf-internal-testing/diffusers-images where it would be extremely nice to have direct access to the filename both visually on the datasets page (@severo ) as well as via the `load_datasets` function. We currently have some akward functionality to download images by path name: https://github.com/huggingface/diffusers/blob/2fb8fafa4b761f6fc144cf75a6f6f0ea6af3a1c1/src/diffusers/utils/testing_utils.py#L131 It would be much nicer to just go over `load_dataset(...)` ### Motivation Intuitively the filename is something people understand directly. E.g if you upload a folder of images online, it's nice if you recognize the image as well as the filename next to it directly and that you're able to use it right away. The label on the other hand is less intuitive to understand as you haven't added it yourself. ### Your contribution Not sure if I have the time to add it myself anytime soon, but it would help us a lot for `diffusers`. @lhoestq yes I also got the idea of some YAML config! not sure of what priority it is though.
[ -1.1704996824264526, -0.9173503518104553, -0.8268527388572693, 1.4715709686279297, -0.11166401207447052, -1.3032108545303345, 0.020015833899378777, -1.010777235031128, 1.7450292110443115, -0.7790379524230957, 0.32988059520721436, -1.6999938488006592, 0.0654868558049202, -0.5893879532814026, -0.7729243636131287, -0.8732810616493225, -0.4579128921031952, -0.8280979990959167, 1.0721477270126343, 2.5288567543029785, 1.2000906467437744, -1.4199343919754028, 2.697934865951538, 0.6441022753715515, -0.15045608580112457, -1.022876262664795, 0.44462576508522034, 0.023666394874453545, -1.254390835762024, -0.5253579616546631, -0.8817463517189026, -0.01644979603588581, -0.6176366806030273, -0.5677542090415955, 0.01155795343220234, 0.4013145864009857, -0.28629937767982483, -0.38333213329315186, -0.5952059030532837, -0.8189886808395386, 0.47227761149406433, -0.404346764087677, 0.966944694519043, -0.28966620564460754, 1.8770800828933716, -0.4722697138786316, 0.3994416296482086, 0.6441090703010559, 1.4070930480957031, 0.1937861293554306, 0.07151620090007782, 0.3014312982559204, 0.3293994963169098, -0.06359682232141495, 0.40196162462234497, 1.156280755996704, 0.7072752118110657, 0.5123918652534485, 0.726860761642456, -2.2152018547058105, 1.3866245746612549, -0.9763309359550476, 0.2987571060657501, 1.2775074243545532, -0.9110889434814453, 0.3258388042449951, -1.7750983238220215, -0.06010752171278, 0.5662775635719299, -2.2252509593963623, 0.22713890671730042, -1.2466063499450684, -0.444775253534317, 1.0463223457336426, 0.21472090482711792, -1.2734214067459106, 0.2890865206718445, -0.46012693643569946, 1.0468608140945435, 0.41159841418266296, 1.18917977809906, -1.809913158416748, -0.023322485387325287, -0.1931779980659485, 0.12226713448762894, -1.297745943069458, -1.546870231628418, 0.47969233989715576, 0.6260565519332886, 0.6763513088226318, -0.04721502959728241, 0.9230629801750183, -0.907075822353363, 0.7654181122779846, -0.9504398703575134, -1.6555219888687134, -1.3764160871505737, -2.246415615081787, -2.3608765602111816, 0.824830949306488, -0.4166772961616516, -0.528348982334137, 2.028358221054077, -1.0150378942489624, -1.7735059261322021, 1.1319342851638794, 0.27440908551216125, -0.015105235390365124, 2.3810312747955322, 0.1558481752872467, -0.7360487580299377, 0.46980535984039307, -0.6722203493118286, 0.8668323755264282, -0.45097023248672485, 1.3501800298690796, 0.44001686573028564, -1.017906904220581, 1.5699498653411865, -0.4936977028846741, 0.5827115774154663, -0.7344411015510559, -0.4724065065383911, -0.8601984977722168, 0.41648268699645996, 1.896559476852417, -0.23779413104057312, 1.6199294328689575, -0.3543035686016083, -1.642262578010559, -1.5858230590820312, 0.8840664029121399, 0.499402791261673, -0.802661120891571, 0.02200881764292717, -0.3040936291217804, 0.22843366861343384, 0.011385735124349594, 1.0253862142562866, 1.1810842752456665, 0.6682906746864319, -0.359624445438385, -0.958251953125, 0.267146497964859, -0.1307777762413025, -0.6910238265991211, -1.7903945446014404, -0.35296598076820374, 0.20836906135082245, 0.566233217716217, -1.2468173503875732, 1.7120094299316406, 0.9070683717727661, 1.9357669353485107, 1.0194941759109497, -0.32941246032714844, 1.535366415977478, 0.04599975794553757, 1.8801511526107788, -0.44096022844314575, 0.6497632265090942, -0.3331528604030609, -1.183673620223999, 0.792930543422699, -0.2962568700313568, -1.9716030359268188, -0.7491822242736816, -0.7524956464767456, -0.21247665584087372, -0.7310317158699036, 0.9129366874694824, -0.31073009967803955, -1.3689906597137451, 0.24118457734584808, -0.6078118085861206, 0.07815174013376236, -1.2498271465301514, 0.2190442532300949, 0.7776639461517334, -0.7290211915969849, 0.09122709929943085, -0.28824928402900696, -1.3284571170806885, -0.4911484122276306, 0.31528735160827637, 1.919625997543335, -0.7397581338882446, 0.823350727558136, 1.0526591539382935, -0.7289769053459167, 0.06377927213907242, 0.4048498570919037, -0.28962305188179016, 0.8397950530052185, -1.0901086330413818, -0.34512242674827576, 1.222020149230957, -0.1836172342300415, -0.6415281295776367, 1.3422623872756958, 0.8273630142211914, -1.0285274982452393, -0.10606539249420166, -0.17771291732788086, -0.8497965335845947, 0.028488902375102043, -1.6147152185440063, -0.123988077044487, 0.31354713439941406, -1.4786003828048706, -0.4890568256378174, -0.2969034016132355, 1.2279821634292603, -0.20974309742450714, 1.4174580574035645, -0.3865562379360199, -0.2659640312194824, -0.3927011489868164, -0.36641982197761536, 0.0873676985502243, -0.17346949875354767, -0.6209911108016968, 0.2548377811908722, -0.726253867149353, 0.32534104585647583, 1.4553582668304443, 0.38358405232429504, 0.08949030190706253, 0.47193989157676697, 1.1205558776855469, 0.35632428526878357, -0.01964404806494713, -0.8671137690544128, -1.5172154903411865, 2.035954713821411, -1.3689383268356323, 1.9847029447555542, 0.8644519448280334, -0.008123338222503662, -1.8032736778259277, -1.803699254989624, 1.3773620128631592, 1.1609681844711304, 2.4482007026672363, 0.632811427116394, 0.37320783734321594, -0.7862160205841064, -0.6299968957901001, 0.3996729552745819, -1.0427058935165405, -0.8497321009635925, 0.18135492503643036, 2.3630757331848145, 1.7573448419570923, -0.4481085538864136, -0.24085228145122528, -1.015055537223816, 1.406843662261963, -0.1325579136610031, 0.17630217969417572, 1.9572241306304932, -0.25619223713874817, -1.0966373682022095, 1.2503458261489868, -2.2768595218658447, 0.1607058048248291, 1.9790430068969727, 0.29110679030418396, 0.07968587428331375, -1.4412719011306763, -0.734288215637207, -0.22986429929733276, -0.3775724470615387, -1.2594459056854248, 0.5359616279602051, -0.32080718874931335, -0.7881194353103638, -1.4822595119476318, 0.21469508111476898, -1.1019104719161987, -1.6537292003631592, 0.2614428997039795, 1.8993463516235352, 1.967439889907837, -0.8033075332641602, 1.4984592199325562, -0.19652460515499115, 0.18469105660915375, 1.2500654458999634, 1.2640142440795898, 3.183759927749634, 1.8744367361068726, -1.2673741579055786, 0.5808805823326111, -0.15720784664154053, -0.462197482585907, 1.0930509567260742, -1.167529821395874, 1.1994603872299194, -0.18535827100276947, -1.191236972808838, -1.249334454536438, 0.9752651453018188, 0.5582075715065002, 0.07139024883508682, -0.5313780307769775, 1.1775915622711182, -0.014250198379158974, 1.3066877126693726, 0.509000301361084, -0.3961949646472931, 0.6018269062042236, -0.38824617862701416, -0.6127361059188843, 1.579035997390747, 0.17382243275642395, -1.4282938241958618, -2.2878096103668213, -0.22890785336494446, -0.7994478344917297, -0.0495944619178772, -0.5713608264923096, -0.9646698832511902, 1.5980992317199707, 0.3838334381580353, -1.335484266281128, -0.2823791205883026, -0.3895874619483948, -0.6740818619728088, 2.5904228687286377, -1.3852242231369019, -0.21360036730766296, -0.9805778861045837, -0.5656795501708984, 1.5657812356948853, -1.1344363689422607, -0.23815084993839264, -1.0041439533233643, -0.5944132804870605, -1.272088885307312, -0.5492275357246399, -0.03269018232822418, -0.8119426965713501, 0.7236766815185547, 0.21802173554897308, -1.1910414695739746, -0.33597734570503235, -0.8719070553779602, 0.7990077137947083, -0.08812607824802399, 0.2298964262008667, 1.8669490814208984, 0.5202821493148804, -0.37288060784339905, 0.6369675397872925, 1.1453925371170044, 0.5460881590843201, -0.6818665862083435, 0.2461887001991272, -0.7361473441123962, 0.28133097290992737, -1.3569360971450806, 0.3074321150779724, -2.8055994510650635, 0.740077555179596, -0.14720933139324188, -0.11031219363212585, 0.06728432327508926, -1.2236354351043701, 1.1037116050720215, 2.7475059032440186, -1.1712864637374878, 0.47243282198905945, 0.33750757575035095, 1.1547290086746216, -1.7113603353500366, 0.3246302604675293, -0.35134536027908325, 2.104541301727295, 0.12135746330022812, 1.2128981351852417, -0.5519610047340393, -2.2729551792144775, 0.5453264117240906, -1.223834753036499, -1.1862242221832275, 0.8302417397499084, -0.851268470287323, -0.011352725327014923, -1.3724535703659058, -0.17682980000972748, -0.8236839175224304, -1.3065203428268433, 0.7347302436828613, 0.10341484844684601, 0.4742833077907562, -0.599312961101532, 0.3429397940635681, -2.1396305561065674, -1.3374323844909668, -0.29165756702423096, -0.9922173619270325, 0.4521324038505554, -0.34868305921554565, 0.6716756224632263, -0.17778031527996063, 0.04365271329879761, 0.36816176772117615, 1.4046300649642944, 3.46294903755188, 0.21586328744888306, 0.3986365497112274, -0.12814639508724213, -0.9309173822402954, 1.3886750936508179, 0.9249743819236755, -0.15480920672416687, -0.5114701986312866, -1.084966778755188, 1.2117321491241455, 1.9950228929519653, 1.0863299369812012, 0.044528014957904816, -0.7196434140205383, -0.7452203631401062, 0.06663650274276733, 0.17595642805099487, 0.4499559700489044, 0.9241026043891907, 0.04438059777021408, 0.05642642825841904, 1.3859117031097412, 1.278132677078247, -0.3939432203769684, 0.41177886724472046, -0.7638207077980042, -0.4599420130252838, 0.4574566185474396, 0.3235025703907013, -0.0065155322663486, 0.37318751215934753, -1.029727578163147, -0.25030842423439026, -0.44063326716423035, -0.9994679689407349, -0.7884641885757446, -0.49544036388397217, -0.24510608613491058, 1.6540886163711548, 0.07576919347047806, -0.4895089864730835, -0.0004045609384775162, -0.7405673861503601, -0.1077042818069458, -1.0457208156585693, 0.24679982662200928, -0.08207093179225922, -0.1624518185853958, -0.06553752720355988, 1.7951377630233765, -1.0248959064483643, -2.173809766769409, 0.25498634576797485, 0.19672326743602753, -0.32196640968322754, 0.2270672470331192, 1.630899429321289, 0.47845348715782166, 1.450250506401062, 1.3604789972305298, 0.9995629191398621, -0.7668380737304688, -1.3219223022460938, 0.6976730227470398, 0.9177531599998474, -1.3752374649047852, 0.8246281743049622, -0.04970128834247589, -0.4830284118652344, 0.6987515091896057, 1.3041715621948242, 0.3743053674697876, -1.9545446634292603, 0.812061071395874, -0.875059187412262, 0.698918879032135, 0.6479046940803528, 0.719555675983429, 0.20364528894424438, 0.7318298816680908, -1.2495709657669067, -1.1447709798812866, -0.7456338405609131, -0.6806689500808716, 1.9298193454742432, -0.19251450896263123, 0.5783727169036865, -0.1382284313440323, -1.357477068901062, -0.09544865041971207, 0.7539295554161072, 0.38138049840927124, -0.4271218776702881, 0.7826471924781799, -0.6824035048484802, -1.0763088464736938, -1.488896369934082, -0.4736517667770386, -1.036844253540039, -0.875079870223999, 0.923882246017456, 0.8764927387237549, 0.20336554944515228, 1.9488961696624756, 0.7434718012809753, 0.24130487442016602, -2.6836729049682617, 0.9681410193443298, 0.3561592400074005, -0.03640734404325485, 0.9661580324172974, 0.3199722170829773, 0.9541521072387695, 0.02769155241549015, 0.5202248096466064, -2.3164381980895996, 2.3174407482147217, -0.26078012585639954, 0.7016797661781311, -0.04297902435064316, -0.25291919708251953, 1.0990592241287231, 0.5140604972839355, 0.606934130191803, -1.1682449579238892, 0.7165476083755493, -0.5787399411201477, 1.1456143856048584, 0.9123969078063965, -0.859207034111023, -0.010723401792347431, 1.3364741802215576, 0.40661686658859253, -0.5561838746070862, -0.8849416375160217, -0.9083560109138489, 0.9031244516372681, 1.8129017353057861, -0.06622026115655899, 0.012957863509654999, 0.8987650871276855, 0.5593901872634888, -1.3581706285476685, 0.04082465171813965, -0.7718411087989807, -0.8168497681617737, 1.6821556091308594, 1.9876652956008911, -0.01663818582892418, -0.31077995896339417, -0.799371063709259, -1.2114664316177368, 0.8193179368972778, 0.09350153803825378, 0.1430538296699524, 0.6802594661712646, -0.702602744102478, 1.1943923234939575, 0.907399594783783, 0.9356983304023743, 0.1277989149093628, 0.24693986773490906, 0.4608566164970398, -0.3789098858833313, -1.110036849975586, -0.27808237075805664, -1.191519021987915, -2.400625705718994, 0.5478652715682983, -0.09371750056743622, -1.4723601341247559, -0.0352189801633358, -1.0025651454925537, 0.8976060748100281, -0.4775151312351227, -1.127636194229126, -1.5208594799041748, 0.1999775767326355, -0.19733721017837524, 0.8938218951225281, -1.6005152463912964, -0.09964101016521454, 1.210057258605957, 0.9989785552024841, -0.6801472902297974, 0.9542601704597473, 0.07711447030305862, 0.9597023725509644, 0.9469820261001587, -0.42449092864990234, 0.4754759669303894, 0.06894577294588089, -1.3700076341629028, 0.37479767203330994, 1.0734795331954956, 0.22248363494873047, 1.3740431070327759, -0.5533040761947632, 0.013365812599658966, 0.351104736328125, -0.4868214726448059, -0.46605217456817627, -0.6107317805290222, 0.7481647729873657, 0.08393940329551697, -0.9336303472518921, 0.14998352527618408, -0.11788791418075562, -0.15980452299118042, 0.14698559045791626, -1.5091729164123535, -0.22659720480442047, -0.30166104435920715, -0.5041207075119019, -1.1148569583892822, -0.05722258985042572, 1.3828823566436768, -0.7637555599212646, -0.23553091287612915, 0.5733997225761414, 0.45290693640708923, 0.5259250998497009, 0.5697491765022278, -0.6898990273475647, -0.4172879457473755, -0.2501896917819977, -0.3497067093849182, 0.31933215260505676, 1.360924243927002, -0.12028515338897705, -0.9616203904151917, 0.7910428047180176, -0.39825814962387085, 0.11574267596006393, 1.9436235427856445, 0.0524955615401268, -0.7671782374382019, 0.29885807633399963, -0.7401638031005859, 1.8932957649230957, 1.7965739965438843, 1.3093292713165283, -0.12188014388084412, -1.005098819732666, 0.64665287733078, -0.27577245235443115, -0.3339608907699585, 1.001267910003662, 0.42266345024108887, -0.1736827939748764, -1.4456534385681152, 0.4906805455684662, 1.2412703037261963, -0.7956173419952393, -0.7752483487129211, 0.04050375521183014, -0.8657248616218567, 1.0266793966293335, 0.7138292789459229, 0.4495207965373993, 0.1748339831829071, 1.6572537422180176, 0.7485846281051636, -0.4377942681312561, 0.5616620182991028, 0.5278192758560181, -0.18627780675888062, -2.113927125930786, -1.1409975290298462, 0.2621382176876068, -0.3810667097568512, -1.5920063257217407, 1.3828403949737549, -1.1798168420791626, -0.9579833149909973, 0.553699791431427, -0.001309249084442854, 1.505660891532898, 0.259435772895813, 1.5829534530639648, 2.164762496948242, 0.9250308275222778, 0.3413049578666687, 1.3008389472961426, -0.185108944773674, -0.4185033142566681, 1.8839364051818848, -0.4349704384803772, 0.48138177394866943, 1.018618106842041, -0.3420126438140869, -1.028597354888916, -0.7366162538528442, -1.1931308507919312, -0.6631788015365601, 1.159693717956543, 0.07111361622810364, -1.1048648357391357, 0.2890472710132599, 1.6694374084472656, 0.08443751931190491, -0.3029455244541168, 0.6126365661621094, 0.46129629015922546, -0.776953935623169, -0.041744962334632874, -0.8872348666191101, 0.5008634328842163, -0.1108853742480278, -0.33375686407089233, 0.3291753828525543, 0.4599962830543518, 1.2576805353164673, 0.05269836634397507, 0.11295683681964874, 1.2196252346038818, -1.3540297746658325, 1.470743179321289, -0.6494809985160828, 0.24951347708702087, -2.3997442722320557, 1.3764926195144653, -0.733113706111908, 1.8694902658462524, -2.581875801086426, 0.40112122893333435, -0.6134533286094666, -0.5288980007171631, 0.4366886019706726, -0.37797296047210693, 0.18424120545387268, -0.20992891490459442, -1.0313539505004883, -0.12703922390937805, -0.7171065807342529, 0.5831336975097656, 1.1561676263809204, 1.3718814849853516, -1.0389314889907837, -0.2505776286125183, -1.764046311378479, -0.12194260209798813, -0.6024356484413147, 0.31329280138015747, -1.9496991634368896, -0.19564129412174225, -1.9208589792251587, -2.3708012104034424, -1.4424453973770142, -0.7978051900863647, 1.0133304595947266, 0.1609998345375061, -0.8972957134246826, 1.1528191566467285, -0.4243892729282379, -1.8323442935943604, 1.128360390663147, -2.166396141052246 ]
https://github.com/huggingface/datasets/issues/5160
Automatically add filename for image/audio folder
I meant just the file name (no path) that would already be super helpful IMO :-) (maybe dir+filename if there are dirs in the folder)
### Feature request When creating a custom audio of image dataset, it would be great to automatically have access to the filename. It should be both: a) Automatically displayed in the viewer b) Automatically added as a column to the dataset when doing `load_dataset` In `diffusers` our test rely quite heavily on images and audio files now and it's a bit tedious at the moment to download specific images from a datasets repo. E.g. we have a dataset of images for tests in `diffusers`: https://huggingface.co/datasets/hf-internal-testing/diffusers-images where it would be extremely nice to have direct access to the filename both visually on the datasets page (@severo ) as well as via the `load_datasets` function. We currently have some akward functionality to download images by path name: https://github.com/huggingface/diffusers/blob/2fb8fafa4b761f6fc144cf75a6f6f0ea6af3a1c1/src/diffusers/utils/testing_utils.py#L131 It would be much nicer to just go over `load_dataset(...)` ### Motivation Intuitively the filename is something people understand directly. E.g if you upload a folder of images online, it's nice if you recognize the image as well as the filename next to it directly and that you're able to use it right away. The label on the other hand is less intuitive to understand as you haven't added it yourself. ### Your contribution Not sure if I have the time to add it myself anytime soon, but it would help us a lot for `diffusers`.
455
25
Automatically add filename for image/audio folder ### Feature request When creating a custom audio of image dataset, it would be great to automatically have access to the filename. It should be both: a) Automatically displayed in the viewer b) Automatically added as a column to the dataset when doing `load_dataset` In `diffusers` our test rely quite heavily on images and audio files now and it's a bit tedious at the moment to download specific images from a datasets repo. E.g. we have a dataset of images for tests in `diffusers`: https://huggingface.co/datasets/hf-internal-testing/diffusers-images where it would be extremely nice to have direct access to the filename both visually on the datasets page (@severo ) as well as via the `load_datasets` function. We currently have some akward functionality to download images by path name: https://github.com/huggingface/diffusers/blob/2fb8fafa4b761f6fc144cf75a6f6f0ea6af3a1c1/src/diffusers/utils/testing_utils.py#L131 It would be much nicer to just go over `load_dataset(...)` ### Motivation Intuitively the filename is something people understand directly. E.g if you upload a folder of images online, it's nice if you recognize the image as well as the filename next to it directly and that you're able to use it right away. The label on the other hand is less intuitive to understand as you haven't added it yourself. ### Your contribution Not sure if I have the time to add it myself anytime soon, but it would help us a lot for `diffusers`. I meant just the file name (no path) that would already be super helpful IMO :-) (maybe dir+filename if there are dirs in the folder)
[ -1.189942717552185, -0.9091562628746033, -0.8413412570953369, 1.4770716428756714, -0.12182930111885071, -1.3160605430603027, -0.01249496079981327, -0.9970698952674866, 1.7396042346954346, -0.7891772985458374, 0.33561959862709045, -1.7096399068832397, 0.06259508430957794, -0.5840696692466736, -0.7922115325927734, -0.8841738104820251, -0.45860767364501953, -0.8374746441841125, 1.0671157836914062, 2.508376359939575, 1.2015032768249512, -1.4442025423049927, 2.703336715698242, 0.6485092043876648, -0.1567467898130417, -1.0355820655822754, 0.44133684039115906, 0.02155255526304245, -1.2561372518539429, -0.5388365983963013, -0.8927028179168701, -0.021747052669525146, -0.6239373683929443, -0.5635915994644165, 0.0412101224064827, 0.39515212178230286, -0.28097429871559143, -0.3771468997001648, -0.5960344076156616, -0.7905629873275757, 0.4778955578804016, -0.3813338875770569, 0.9618468284606934, -0.29567065834999084, 1.8796336650848389, -0.47735652327537537, 0.397407591342926, 0.6197043061256409, 1.421067237854004, 0.20179206132888794, 0.052397239953279495, 0.32278749346733093, 0.3048408329486847, -0.04264364764094353, 0.3985937237739563, 1.160112977027893, 0.699110209941864, 0.5174626111984253, 0.7164939641952515, -2.212277889251709, 1.3932982683181763, -0.9693625569343567, 0.2999838590621948, 1.26985764503479, -0.9110127091407776, 0.3400478959083557, -1.7880244255065918, -0.0821535587310791, 0.5744470953941345, -2.195746421813965, 0.24539682269096375, -1.2522742748260498, -0.4428060054779053, 1.0741996765136719, 0.1982852816581726, -1.2842949628829956, 0.29740601778030396, -0.45750629901885986, 1.053265929222107, 0.377144992351532, 1.2000504732131958, -1.7810412645339966, -0.011255238205194473, -0.20692451298236847, 0.10160304605960846, -1.2597477436065674, -1.5439726114273071, 0.5077669024467468, 0.6263754367828369, 0.6844201683998108, -0.058465588837862015, 0.9202226400375366, -0.9040459394454956, 0.786401629447937, -0.9187503457069397, -1.6593406200408936, -1.378311038017273, -2.258455753326416, -2.3639180660247803, 0.837232232093811, -0.4214695394039154, -0.5173847079277039, 2.0414326190948486, -1.047653079032898, -1.7801544666290283, 1.1163221597671509, 0.2664071321487427, -0.01780823990702629, 2.3850815296173096, 0.1604316532611847, -0.7436646223068237, 0.46461260318756104, -0.6610766649246216, 0.8887352347373962, -0.46192893385887146, 1.369675636291504, 0.4380577504634857, -1.0213947296142578, 1.586292028427124, -0.4833691418170929, 0.5798819065093994, -0.730871856212616, -0.47976332902908325, -0.8783313632011414, 0.4402921199798584, 1.9075640439987183, -0.254921555519104, 1.6321775913238525, -0.34588226675987244, -1.6407612562179565, -1.5712178945541382, 0.8719961047172546, 0.4996223449707031, -0.832669198513031, 0.025586027652025223, -0.3235032260417938, 0.2070172131061554, 0.03855841979384422, 1.0496115684509277, 1.1856911182403564, 0.6667382121086121, -0.34901219606399536, -0.9586017727851868, 0.2696080505847931, -0.11945700645446777, -0.6881920695304871, -1.7914820909500122, -0.3655007481575012, 0.21378688514232635, 0.5660791993141174, -1.2439388036727905, 1.714522361755371, 0.9175516963005066, 1.949929118156433, 1.0203378200531006, -0.3364761173725128, 1.5170174837112427, 0.04119285196065903, 1.8860033750534058, -0.42623934149742126, 0.6460177302360535, -0.3278351426124573, -1.210976243019104, 0.7986161708831787, -0.29546546936035156, -1.9963734149932861, -0.7533287405967712, -0.734683632850647, -0.20357558131217957, -0.7487037777900696, 0.9043946266174316, -0.31155359745025635, -1.3796615600585938, 0.2649346888065338, -0.6121468544006348, 0.09197373688220978, -1.2494614124298096, 0.19730181992053986, 0.7599140405654907, -0.7262058854103088, 0.06338630616664886, -0.2936110496520996, -1.3276435136795044, -0.5011837482452393, 0.3018362522125244, 1.9018585681915283, -0.7471423745155334, 0.8387940526008606, 1.0618093013763428, -0.6964646577835083, 0.06763897836208344, 0.39618125557899475, -0.3081792891025543, 0.8732309341430664, -1.098383903503418, -0.3484792709350586, 1.201097846031189, -0.15741796791553497, -0.6267676949501038, 1.3227823972702026, 0.8124502301216125, -1.0389950275421143, -0.11239209771156311, -0.19942975044250488, -0.8744971752166748, 0.03137914091348648, -1.62039053440094, -0.11895449459552765, 0.3217276930809021, -1.474873661994934, -0.49044719338417053, -0.29253944754600525, 1.2287993431091309, -0.20526273548603058, 1.4243824481964111, -0.41330862045288086, -0.2878396809101105, -0.3945711553096771, -0.37001878023147583, 0.10549664497375488, -0.15827412903308868, -0.6059865951538086, 0.26080527901649475, -0.7326704263687134, 0.3146326541900635, 1.4527363777160645, 0.3748646676540375, 0.08587890863418579, 0.4796037971973419, 1.1417497396469116, 0.35086002945899963, -0.03816183656454086, -0.865060567855835, -1.530455231666565, 2.0456016063690186, -1.3750561475753784, 1.9862630367279053, 0.8580154180526733, 0.010174719616770744, -1.8243744373321533, -1.818095326423645, 1.3792246580123901, 1.186660647392273, 2.446749210357666, 0.6424530744552612, 0.37247782945632935, -0.7978529930114746, -0.6486322283744812, 0.42441147565841675, -1.044226884841919, -0.8524534702301025, 0.16276653110980988, 2.3282930850982666, 1.7716655731201172, -0.4437500834465027, -0.2511688470840454, -0.9925767183303833, 1.3932205438613892, -0.1666916161775589, 0.18138869106769562, 1.9461501836776733, -0.25865188241004944, -1.0937227010726929, 1.2586297988891602, -2.276172161102295, 0.16988033056259155, 1.9872395992279053, 0.2805802822113037, 0.06748396158218384, -1.4420242309570312, -0.7149731516838074, -0.21861794590950012, -0.34993094205856323, -1.2625502347946167, 0.5249324440956116, -0.3220963776111603, -0.7844375371932983, -1.470868468284607, 0.21323443949222565, -1.1330779790878296, -1.6534321308135986, 0.26064372062683105, 1.9029039144515991, 1.983124852180481, -0.8019859194755554, 1.48457932472229, -0.2139606475830078, 0.1998414397239685, 1.2456203699111938, 1.2587242126464844, 3.1890509128570557, 1.855438232421875, -1.2687485218048096, 0.5601379871368408, -0.1563238799571991, -0.47253483533859253, 1.0951249599456787, -1.1548881530761719, 1.206984281539917, -0.20316073298454285, -1.2052754163742065, -1.2334827184677124, 0.9944270849227905, 0.549071192741394, 0.06550496816635132, -0.5284914374351501, 1.1809998750686646, -0.024969669058918953, 1.308659315109253, 0.5174919962882996, -0.41568702459335327, 0.5743176341056824, -0.37209221720695496, -0.6023986339569092, 1.5526416301727295, 0.17604680359363556, -1.416896939277649, -2.293919563293457, -0.2333737015724182, -0.8168448209762573, -0.04192446544766426, -0.5752655267715454, -0.9578867554664612, 1.596497654914856, 0.3842427432537079, -1.3206236362457275, -0.2875453531742096, -0.39229458570480347, -0.6597030758857727, 2.583407163619995, -1.3483697175979614, -0.19784142076969147, -0.9599059224128723, -0.5650926232337952, 1.5780080556869507, -1.097833275794983, -0.24101436138153076, -0.9989256262779236, -0.591780960559845, -1.2702499628067017, -0.5604225397109985, -0.005346812307834625, -0.8018146753311157, 0.7140867114067078, 0.18205498158931732, -1.1942389011383057, -0.33372098207473755, -0.8757700324058533, 0.7976934313774109, -0.08897571265697479, 0.20904642343521118, 1.8711832761764526, 0.5227231383323669, -0.37518879771232605, 0.6648905277252197, 1.1455456018447876, 0.5542976260185242, -0.6710949540138245, 0.23513083159923553, -0.718835711479187, 0.27341651916503906, -1.3500702381134033, 0.3175264894962311, -2.8107972145080566, 0.7604368925094604, -0.14042966067790985, -0.09276482462882996, 0.06939636170864105, -1.2045608758926392, 1.0792375802993774, 2.7477309703826904, -1.1864484548568726, 0.4698217213153839, 0.3257516920566559, 1.1402844190597534, -1.7308119535446167, 0.3001348674297333, -0.3639950454235077, 2.12335467338562, 0.09824903309345245, 1.2214726209640503, -0.5427435636520386, -2.2588412761688232, 0.542787492275238, -1.2203441858291626, -1.1830211877822876, 0.835990309715271, -0.8466593623161316, 0.0021832911297678947, -1.39110267162323, -0.16981914639472961, -0.8296553492546082, -1.3134078979492188, 0.7151452302932739, 0.09644182026386261, 0.46200382709503174, -0.5770168900489807, 0.33114486932754517, -2.148298740386963, -1.3385733366012573, -0.28253576159477234, -0.9973363876342773, 0.46893537044525146, -0.3481396734714508, 0.6796486973762512, -0.15926235914230347, 0.0389256551861763, 0.3716636896133423, 1.3910177946090698, 3.4641189575195312, 0.21600407361984253, 0.3834095895290375, -0.13467556238174438, -0.914354681968689, 1.388163685798645, 0.9096027612686157, -0.17022374272346497, -0.5300015807151794, -1.069737195968628, 1.2296521663665771, 1.9827415943145752, 1.0770220756530762, 0.0570087768137455, -0.7117770314216614, -0.730597734451294, 0.06098948046565056, 0.1688489466905594, 0.4640427231788635, 0.9334865808486938, 0.04959297180175781, 0.057023320347070694, 1.3788524866104126, 1.2525039911270142, -0.38247501850128174, 0.3991554379463196, -0.7565253376960754, -0.4905579686164856, 0.44826117157936096, 0.3096930682659149, 0.011266302317380905, 0.362484335899353, -1.0161542892456055, -0.2700493633747101, -0.45376354455947876, -1.0022016763687134, -0.7901108264923096, -0.49743691086769104, -0.2629690170288086, 1.6368653774261475, 0.06939846277236938, -0.5004290342330933, 0.007378079928457737, -0.7361727952957153, -0.11969625949859619, -1.0188912153244019, 0.24926331639289856, -0.07456183433532715, -0.16329744458198547, -0.0692863017320633, 1.7854790687561035, -1.026920199394226, -2.169126510620117, 0.2554808557033539, 0.20489971339702606, -0.3125433325767517, 0.20018289983272552, 1.6292818784713745, 0.48341846466064453, 1.455026626586914, 1.3627815246582031, 0.9730251431465149, -0.7787719964981079, -1.2980674505233765, 0.7013540267944336, 0.9304221272468567, -1.3833872079849243, 0.8164001107215881, -0.06845785677433014, -0.49176910519599915, 0.6754171252250671, 1.3067578077316284, 0.38259097933769226, -1.963080883026123, 0.8268200755119324, -0.871042013168335, 0.6858289241790771, 0.6464195847511292, 0.7248592376708984, 0.1916869580745697, 0.7323367595672607, -1.247968077659607, -1.128804326057434, -0.7300346493721008, -0.6889526844024658, 1.9049197435379028, -0.18581272661685944, 0.5649339556694031, -0.1640368103981018, -1.3609446287155151, -0.09061349928379059, 0.7357590794563293, 0.37204691767692566, -0.41765159368515015, 0.7957988977432251, -0.6711057424545288, -1.0646705627441406, -1.5061944723129272, -0.4553736448287964, -1.0225411653518677, -0.8769081234931946, 0.9072702527046204, 0.8768132328987122, 0.20960205793380737, 1.94881272315979, 0.7362257242202759, 0.22133517265319824, -2.6797521114349365, 0.9798245429992676, 0.34462425112724304, -0.052569206804037094, 0.9688599109649658, 0.2956197261810303, 0.9589537978172302, 0.01949511468410492, 0.5162448287010193, -2.3001561164855957, 2.300341844558716, -0.2670578360557556, 0.6997188329696655, -0.03072766400873661, -0.27339276671409607, 1.0953413248062134, 0.5097096562385559, 0.6163471937179565, -1.1665090322494507, 0.7328298687934875, -0.5790545344352722, 1.1418653726577759, 0.9251419305801392, -0.854902446269989, -0.007469110190868378, 1.334091305732727, 0.3852993845939636, -0.5472425818443298, -0.900079607963562, -0.8864467740058899, 0.9171626567840576, 1.8067446947097778, -0.05591978505253792, 0.019776269793510437, 0.8836292624473572, 0.5663565397262573, -1.3597095012664795, 0.042594704777002335, -0.7548961639404297, -0.8224744200706482, 1.6812089681625366, 1.9863494634628296, 0.0031603947281837463, -0.30680012702941895, -0.8072257041931152, -1.228231430053711, 0.8341103196144104, 0.08246761560440063, 0.15580938756465912, 0.6905282139778137, -0.7122279405593872, 1.2085293531417847, 0.8967397212982178, 0.9478844404220581, 0.10137006640434265, 0.2202627807855606, 0.46369314193725586, -0.36503154039382935, -1.0979735851287842, -0.2826545834541321, -1.1792222261428833, -2.4099533557891846, 0.5369170308113098, -0.1056058406829834, -1.4708483219146729, -0.035396866500377655, -0.9942941665649414, 0.9220971465110779, -0.4997355341911316, -1.1194120645523071, -1.5230692625045776, 0.21522381901741028, -0.1916184425354004, 0.9098653197288513, -1.6037993431091309, -0.106875479221344, 1.2203718423843384, 0.9978048801422119, -0.6646596789360046, 0.9578577280044556, 0.08748750388622284, 0.9582000374794006, 0.9387397170066833, -0.4160076379776001, 0.46961069107055664, 0.07943004369735718, -1.3766963481903076, 0.3742693066596985, 1.0818718671798706, 0.21613463759422302, 1.3741415739059448, -0.5493057370185852, 0.015918275341391563, 0.3578321635723114, -0.4827696681022644, -0.45732375979423523, -0.6078174114227295, 0.7499309182167053, 0.08762718737125397, -0.9279924035072327, 0.13176663219928741, -0.11430487036705017, -0.1609632521867752, 0.14448635280132294, -1.5233858823776245, -0.2507701516151428, -0.281369149684906, -0.5165906548500061, -1.1058355569839478, -0.07574866712093353, 1.3736177682876587, -0.7634275555610657, -0.21311984956264496, 0.569242537021637, 0.4290671646595001, 0.5635034441947937, 0.5778549313545227, -0.6895123720169067, -0.39239585399627686, -0.25483155250549316, -0.3445509970188141, 0.2865183353424072, 1.356492519378662, -0.09990689158439636, -0.9277947545051575, 0.7877610325813293, -0.3925683796405792, 0.09438802301883698, 1.9502474069595337, 0.08053243160247803, -0.7638788223266602, 0.3121529817581177, -0.7264509201049805, 1.8823554515838623, 1.7765169143676758, 1.2980848550796509, -0.12160132825374603, -0.9954755902290344, 0.6656329035758972, -0.2709658741950989, -0.3232928216457367, 0.991066038608551, 0.42647579312324524, -0.14695870876312256, -1.453632116317749, 0.5179212093353271, 1.2392102479934692, -0.8223176598548889, -0.7749994397163391, 0.02513336017727852, -0.8633896112442017, 1.0225558280944824, 0.7195745706558228, 0.47202274203300476, 0.1835646778345108, 1.6623352766036987, 0.7492669820785522, -0.45637068152427673, 0.5494062900543213, 0.5411806702613831, -0.1850150227546692, -2.0930724143981934, -1.1258805990219116, 0.2685699164867401, -0.37923532724380493, -1.5886470079421997, 1.3692642450332642, -1.1822248697280884, -0.9576089382171631, 0.5709630250930786, -0.001700911670923233, 1.5101932287216187, 0.26991575956344604, 1.5958242416381836, 2.159806966781616, 0.9276647567749023, 0.3295881450176239, 1.2905604839324951, -0.16340337693691254, -0.40319666266441345, 1.88559091091156, -0.4386448860168457, 0.5117335319519043, 1.030326008796692, -0.35179612040519714, -1.0431339740753174, -0.7348703742027283, -1.190577507019043, -0.6823883652687073, 1.1528557538986206, 0.07575535774230957, -1.0971381664276123, 0.2930801212787628, 1.7006518840789795, 0.08045005798339844, -0.3124901354312897, 0.6029385924339294, 0.46238064765930176, -0.7706803679466248, -0.043899644166231155, -0.8856654763221741, 0.49624407291412354, -0.0951276421546936, -0.33552229404449463, 0.34843194484710693, 0.4627281427383423, 1.2780920267105103, 0.05789954587817192, 0.10697239637374878, 1.2032052278518677, -1.3571101427078247, 1.4526879787445068, -0.6361714005470276, 0.2539006471633911, -2.4072465896606445, 1.3834848403930664, -0.741486668586731, 1.8760510683059692, -2.5903308391571045, 0.3990846872329712, -0.6099478602409363, -0.5391704440116882, 0.44101613759994507, -0.37057456374168396, 0.18900389969348907, -0.20611555874347687, -1.0148100852966309, -0.11955271661281586, -0.7153632640838623, 0.6026847958564758, 1.1688320636749268, 1.3602582216262817, -1.033087134361267, -0.2501799464225769, -1.7533504962921143, -0.13211672008037567, -0.5886495113372803, 0.30224889516830444, -1.9673817157745361, -0.18022184073925018, -1.9260385036468506, -2.386596202850342, -1.445182204246521, -0.8120998740196228, 1.0276867151260376, 0.16746141016483307, -0.8951585292816162, 1.164587378501892, -0.43459898233413696, -1.8507850170135498, 1.1116997003555298, -2.161660671234131 ]
https://github.com/huggingface/datasets/issues/5160
Automatically add filename for image/audio folder
@patrickvonplaten one more time, to be sure I understand you. For example, we have data structure like this: ``` ├─ data/ │ └─ subdir/ │ └── cats/ │ ├── 0.jpg │ ├── 1.jpg │ └── 2.jpg │ └── dogs/ │ ├── 0.jpg │ ├── 1.jpg │ └── 2.jpg └── another_subdir/ ├── 10.jpg ├── 11.jpg └── 12.jpg ``` Is it okay to provide `"data/subdir/cats/0.jpg"`, `"data/subdir/dogs/0.jpg"`, `"data/another_subdir/10.jpg"`? I think providing just filenames might be confusing if they are not unique, as in this example.
### Feature request When creating a custom audio of image dataset, it would be great to automatically have access to the filename. It should be both: a) Automatically displayed in the viewer b) Automatically added as a column to the dataset when doing `load_dataset` In `diffusers` our test rely quite heavily on images and audio files now and it's a bit tedious at the moment to download specific images from a datasets repo. E.g. we have a dataset of images for tests in `diffusers`: https://huggingface.co/datasets/hf-internal-testing/diffusers-images where it would be extremely nice to have direct access to the filename both visually on the datasets page (@severo ) as well as via the `load_datasets` function. We currently have some akward functionality to download images by path name: https://github.com/huggingface/diffusers/blob/2fb8fafa4b761f6fc144cf75a6f6f0ea6af3a1c1/src/diffusers/utils/testing_utils.py#L131 It would be much nicer to just go over `load_dataset(...)` ### Motivation Intuitively the filename is something people understand directly. E.g if you upload a folder of images online, it's nice if you recognize the image as well as the filename next to it directly and that you're able to use it right away. The label on the other hand is less intuitive to understand as you haven't added it yourself. ### Your contribution Not sure if I have the time to add it myself anytime soon, but it would help us a lot for `diffusers`.
455
82
Automatically add filename for image/audio folder ### Feature request When creating a custom audio of image dataset, it would be great to automatically have access to the filename. It should be both: a) Automatically displayed in the viewer b) Automatically added as a column to the dataset when doing `load_dataset` In `diffusers` our test rely quite heavily on images and audio files now and it's a bit tedious at the moment to download specific images from a datasets repo. E.g. we have a dataset of images for tests in `diffusers`: https://huggingface.co/datasets/hf-internal-testing/diffusers-images where it would be extremely nice to have direct access to the filename both visually on the datasets page (@severo ) as well as via the `load_datasets` function. We currently have some akward functionality to download images by path name: https://github.com/huggingface/diffusers/blob/2fb8fafa4b761f6fc144cf75a6f6f0ea6af3a1c1/src/diffusers/utils/testing_utils.py#L131 It would be much nicer to just go over `load_dataset(...)` ### Motivation Intuitively the filename is something people understand directly. E.g if you upload a folder of images online, it's nice if you recognize the image as well as the filename next to it directly and that you're able to use it right away. The label on the other hand is less intuitive to understand as you haven't added it yourself. ### Your contribution Not sure if I have the time to add it myself anytime soon, but it would help us a lot for `diffusers`. @patrickvonplaten one more time, to be sure I understand you. For example, we have data structure like this: ``` ├─ data/ │ └─ subdir/ │ └── cats/ │ ├── 0.jpg │ ├── 1.jpg │ └── 2.jpg │ └── dogs/ │ ├── 0.jpg │ ├── 1.jpg │ └── 2.jpg └── another_subdir/ ├── 10.jpg ├── 11.jpg └── 12.jpg ``` Is it okay to provide `"data/subdir/cats/0.jpg"`, `"data/subdir/dogs/0.jpg"`, `"data/another_subdir/10.jpg"`? I think providing just filenames might be confusing if they are not unique, as in this example.
[ -1.1445709466934204, -0.8868544101715088, -0.7736254930496216, 1.4561774730682373, -0.1396993100643158, -1.2579635381698608, 0.07369892299175262, -0.9830206036567688, 1.7020337581634521, -0.7712095975875854, 0.32988229393959045, -1.7008270025253296, 0.09372545778751373, -0.5745177268981934, -0.7612974643707275, -0.8955487012863159, -0.5143970251083374, -0.7965949773788452, 1.0487741231918335, 2.5177602767944336, 1.167919635772705, -1.3765209913253784, 2.6922457218170166, 0.6728915572166443, -0.2056717872619629, -1.0510008335113525, 0.45300325751304626, 0.008400064893066883, -1.308971643447876, -0.46955588459968567, -0.8996047377586365, 0.04582449421286583, -0.6392410397529602, -0.5757690072059631, 0.0992789939045906, 0.43359997868537903, -0.299214631319046, -0.40398919582366943, -0.5951087474822998, -0.7441338896751404, 0.4804084897041321, -0.45660239458084106, 0.9879215955734253, -0.29755446314811707, 1.8675687313079834, -0.5125687718391418, 0.4257682263851166, 0.6728519797325134, 1.373938798904419, 0.20443500578403473, 0.09186720848083496, 0.30120840668678284, 0.3461775779724121, -0.017423734068870544, 0.3644542396068573, 1.20570707321167, 0.6886426210403442, 0.5003865957260132, 0.7399763464927673, -2.217092514038086, 1.3650047779083252, -0.9471961259841919, 0.28876861929893494, 1.281997799873352, -0.8768131136894226, 0.3495747148990631, -1.8020612001419067, -0.014470409601926804, 0.5699525475502014, -2.208608627319336, 0.21305185556411743, -1.2590744495391846, -0.42027026414871216, 1.0350950956344604, 0.22443847358226776, -1.2614853382110596, 0.3301885724067688, -0.45587632060050964, 1.0324159860610962, 0.41994428634643555, 1.1850144863128662, -1.7429484128952026, -0.016597505658864975, -0.22073189914226532, 0.11055365204811096, -1.2794444561004639, -1.5497239828109741, 0.48618870973587036, 0.6668967604637146, 0.6829415559768677, -0.08985079079866409, 0.951969563961029, -0.9457683563232422, 0.773846447467804, -0.9274653196334839, -1.671911358833313, -1.3785029649734497, -2.2650551795959473, -2.334780216217041, 0.781272292137146, -0.38842126727104187, -0.48244771361351013, 1.969947099685669, -1.0020346641540527, -1.7515660524368286, 1.1285195350646973, 0.3039102256298065, -0.022259803488850594, 2.3527796268463135, 0.17864377796649933, -0.7605952024459839, 0.40935957431793213, -0.7045758962631226, 0.8936991095542908, -0.4570453464984894, 1.3768179416656494, 0.44908496737480164, -1.0160906314849854, 1.556286096572876, -0.4662916362285614, 0.6045543551445007, -0.7488089799880981, -0.4885932505130768, -0.8852339386940002, 0.38623955845832825, 1.9024978876113892, -0.2731878161430359, 1.6221230030059814, -0.31571611762046814, -1.6673991680145264, -1.5838991403579712, 0.8307281136512756, 0.5462740659713745, -0.7639374732971191, 0.030972890555858612, -0.31048426032066345, 0.1789092719554901, 0.04138779267668724, 1.0476726293563843, 1.183904767036438, 0.7204836010932922, -0.36627334356307983, -0.990267276763916, 0.2294124811887741, -0.10897532850503922, -0.7199519872665405, -1.8346112966537476, -0.38338330388069153, 0.20665818452835083, 0.5426101088523865, -1.2543479204177856, 1.6875838041305542, 0.8658462166786194, 1.9917945861816406, 1.02348792552948, -0.39901894330978394, 1.5927650928497314, 0.043789610266685486, 1.8700841665267944, -0.4962339401245117, 0.610434353351593, -0.31412947177886963, -1.1919028759002686, 0.8117808699607849, -0.2716640532016754, -2.056124448776245, -0.698215663433075, -0.7829181551933289, -0.2330242097377777, -0.7404260635375977, 0.8851597905158997, -0.29887017607688904, -1.4432265758514404, 0.2462650090456009, -0.592313289642334, 0.02898220345377922, -1.2497369050979614, 0.19023367762565613, 0.7768043875694275, -0.6974555850028992, 0.053520768880844116, -0.2629317045211792, -1.3425440788269043, -0.4780711233615875, 0.29400208592414856, 1.813209891319275, -0.7113580703735352, 0.8766441941261292, 1.074223518371582, -0.6623046398162842, 0.0984329804778099, 0.3653310537338257, -0.31490713357925415, 0.8465123772621155, -1.1022247076034546, -0.3705686330795288, 1.172651767730713, -0.16712607443332672, -0.6143412590026855, 1.3431811332702637, 0.8338478207588196, -1.0640432834625244, -0.16710878908634186, -0.15934890508651733, -0.8889251947402954, 0.046810947358608246, -1.6351253986358643, -0.1550743579864502, 0.3309611678123474, -1.4520690441131592, -0.5047199726104736, -0.26407915353775024, 1.222380518913269, -0.23873022198677063, 1.3913925886154175, -0.3773980736732483, -0.3045024573802948, -0.4220583140850067, -0.4344205856323242, 0.13461634516716003, -0.20109091699123383, -0.6307717561721802, 0.2830139994621277, -0.7553263306617737, 0.3248823881149292, 1.4462355375289917, 0.3716515898704529, 0.0905560851097107, 0.5040403008460999, 1.1212681531906128, 0.3564584255218506, -0.03722574934363365, -0.8868617415428162, -1.588819980621338, 2.041297435760498, -1.4032862186431885, 1.9353176355361938, 0.86722332239151, 0.019065000116825104, -1.802590250968933, -1.806749701499939, 1.3731962442398071, 1.124661922454834, 2.465289354324341, 0.639665961265564, 0.3567672371864319, -0.7691162824630737, -0.7101237177848816, 0.4272327423095703, -1.0699325799942017, -0.8028894662857056, 0.17459286749362946, 2.3495588302612305, 1.7805372476577759, -0.4161956012248993, -0.25179556012153625, -1.010168433189392, 1.4082362651824951, -0.11042160540819168, 0.1795528382062912, 1.9885013103485107, -0.2528591454029083, -1.099607229232788, 1.1866732835769653, -2.2624619007110596, 0.2027902901172638, 1.9571418762207031, 0.2789040505886078, 0.09433139115571976, -1.4745771884918213, -0.7420802116394043, -0.2428765445947647, -0.42192578315734863, -1.228801965713501, 0.5481658577919006, -0.33806660771369934, -0.8076666593551636, -1.4794189929962158, 0.17834343016147614, -1.1389189958572388, -1.6390907764434814, 0.22562578320503235, 1.9133129119873047, 1.9688951969146729, -0.7834863066673279, 1.4818159341812134, -0.23885421454906464, 0.14931510388851166, 1.2356479167938232, 1.25290048122406, 3.1478443145751953, 1.8533577919006348, -1.2475855350494385, 0.6367394328117371, -0.1649911105632782, -0.46682998538017273, 1.060896396636963, -1.1427006721496582, 1.2146023511886597, -0.17368409037590027, -1.1717262268066406, -1.2028419971466064, 1.0115513801574707, 0.5181026458740234, 0.06530003994703293, -0.4818761646747589, 1.1904393434524536, 0.03158174455165863, 1.3315467834472656, 0.5363225340843201, -0.34916889667510986, 0.568950891494751, -0.412306547164917, -0.5989305973052979, 1.5405067205429077, 0.20697306096553802, -1.4202872514724731, -2.3125250339508057, -0.259965181350708, -0.7870238423347473, 0.009330718778073788, -0.5793715119361877, -0.9781233668327332, 1.652441382408142, 0.338654100894928, -1.3198827505111694, -0.23275473713874817, -0.3839396834373474, -0.6055400371551514, 2.615185260772705, -1.3913743495941162, -0.14654222130775452, -0.9546411633491516, -0.5705141425132751, 1.512341022491455, -1.0964401960372925, -0.218098446726799, -0.9850419163703918, -0.5810628533363342, -1.2849305868148804, -0.6091231107711792, 0.02431466430425644, -0.7881741523742676, 0.7031397819519043, 0.19229933619499207, -1.1694122552871704, -0.34460383653640747, -0.8755020499229431, 0.8742416501045227, -0.10081968456506729, 0.2270456850528717, 1.9114738702774048, 0.5015648007392883, -0.32660916447639465, 0.6346026062965393, 1.1304041147232056, 0.5652415752410889, -0.6498044729232788, 0.1769568920135498, -0.754557192325592, 0.21162386238574982, -1.3426439762115479, 0.2986779808998108, -2.7928504943847656, 0.721564769744873, -0.09903919696807861, -0.043525729328393936, 0.04331432282924652, -1.2634718418121338, 1.0797630548477173, 2.765441417694092, -1.1588563919067383, 0.4291025996208191, 0.36073368787765503, 1.158225178718567, -1.6396516561508179, 0.28046083450317383, -0.3544318974018097, 2.089045286178589, 0.10212342441082001, 1.2007524967193604, -0.5740503668785095, -2.242244243621826, 0.540107786655426, -1.1992017030715942, -1.1491925716400146, 0.8567346930503845, -0.8124606609344482, 0.040212202817201614, -1.373159646987915, -0.217254176735878, -0.8415625095367432, -1.3103042840957642, 0.7030993103981018, 0.12276868522167206, 0.5086479187011719, -0.610740602016449, 0.34394457936286926, -2.1423068046569824, -1.3449174165725708, -0.27179092168807983, -1.009763240814209, 0.4507548213005066, -0.3015443682670593, 0.7004691958427429, -0.1424587219953537, 0.03730229660868645, 0.3165266811847687, 1.4152692556381226, 3.4779248237609863, 0.18567419052124023, 0.3348751664161682, -0.09140121936798096, -0.9618555903434753, 1.3570207357406616, 0.9188020825386047, -0.12313371151685715, -0.5786765813827515, -1.0125256776809692, 1.1758710145950317, 2.0056679248809814, 1.1557018756866455, 0.06297428905963898, -0.7567672729492188, -0.7906494140625, 0.09790465235710144, 0.15215574204921722, 0.4652376174926758, 0.8874765038490295, 0.04559023305773735, 0.04488492012023926, 1.4293365478515625, 1.2740663290023804, -0.41463351249694824, 0.4225880801677704, -0.778855562210083, -0.45187318325042725, 0.47311583161354065, 0.30960604548454285, 0.04081272333860397, 0.38782331347465515, -1.0530431270599365, -0.20429442822933197, -0.42922893166542053, -0.9999021887779236, -0.7707007527351379, -0.47411200404167175, -0.2548815906047821, 1.6481947898864746, 0.0975475087761879, -0.4776184856891632, -0.014032887294888496, -0.7261623740196228, -0.15475545823574066, -1.0111279487609863, 0.2227521538734436, -0.10447663068771362, -0.10655099153518677, -0.10018640756607056, 1.7545280456542969, -0.9901704788208008, -2.157491683959961, 0.25172433257102966, 0.20298346877098083, -0.3752869963645935, 0.21902765333652496, 1.6282411813735962, 0.5287287831306458, 1.4359757900238037, 1.3102006912231445, 0.9799696207046509, -0.7660621404647827, -1.3345295190811157, 0.6302564740180969, 0.9681578874588013, -1.3938136100769043, 0.7952662110328674, -0.0329974927008152, -0.4584404528141022, 0.7077329158782959, 1.323057770729065, 0.3615450859069824, -2.023721218109131, 0.8307929635047913, -0.8577759861946106, 0.6640561819076538, 0.6659367084503174, 0.6918781399726868, 0.20214226841926575, 0.7246068120002747, -1.2772258520126343, -1.0907694101333618, -0.8080552816390991, -0.6321245431900024, 1.958731770515442, -0.15285582840442657, 0.5353635549545288, -0.1217898353934288, -1.367252230644226, -0.08141326159238815, 0.7044401168823242, 0.415703147649765, -0.44115060567855835, 0.803741455078125, -0.6969522833824158, -1.1079000234603882, -1.4834043979644775, -0.4776064157485962, -1.0142372846603394, -0.8978067636489868, 0.9672274589538574, 0.8741639256477356, 0.32079675793647766, 1.9272416830062866, 0.7426565885543823, 0.2144799828529358, -2.7253220081329346, 0.9563551545143127, 0.32621029019355774, -0.024981800466775894, 0.9268712401390076, 0.2793388068675995, 0.9818896055221558, -0.04922982677817345, 0.571305513381958, -2.3430023193359375, 2.292438268661499, -0.28457069396972656, 0.7243941426277161, 0.0170365609228611, -0.2399110347032547, 1.0828930139541626, 0.5387862324714661, 0.6757171750068665, -1.184144139289856, 0.7266935110092163, -0.6250617504119873, 1.1785286664962769, 0.9298080801963806, -0.8470019698143005, -0.00024111568927764893, 1.339771032333374, 0.3558405041694641, -0.5053303837776184, -0.8394008278846741, -0.870419442653656, 0.8545659184455872, 1.819678783416748, -0.083973228931427, 0.02375645563006401, 0.8741970658302307, 0.5961273908615112, -1.374738097190857, 0.0672803595662117, -0.7885218858718872, -0.794123113155365, 1.669075846672058, 2.0268328189849854, -0.05625295266509056, -0.2667198181152344, -0.8333441615104675, -1.1621310710906982, 0.7723489999771118, 0.105342335999012, 0.1338583081960678, 0.6798253655433655, -0.7290852069854736, 1.186060905456543, 0.844011664390564, 0.9251757264137268, 0.16482873260974884, 0.28183454275131226, 0.40718379616737366, -0.34146997332572937, -1.1264454126358032, -0.38017797470092773, -1.143232822418213, -2.443208932876587, 0.5337907671928406, -0.10655397176742554, -1.4743270874023438, -0.061146195977926254, -0.9956865906715393, 0.8791479468345642, -0.4768698215484619, -1.10835599899292, -1.519931674003601, 0.2758499085903168, -0.1509641706943512, 0.9008122086524963, -1.6273099184036255, -0.12775324285030365, 1.207485556602478, 0.9966315031051636, -0.6277858018875122, 0.9772024154663086, 0.15025895833969116, 0.9209172129631042, 0.9917119741439819, -0.3679213523864746, 0.4751100540161133, 0.10935737937688828, -1.3557446002960205, 0.36465564370155334, 1.0998897552490234, 0.22348596155643463, 1.3765498399734497, -0.5629477500915527, 0.006669214926660061, 0.33012744784355164, -0.4858439564704895, -0.45115426182746887, -0.5763805508613586, 0.7537127733230591, 0.09709030389785767, -0.9779143929481506, 0.11766088008880615, -0.1422600895166397, -0.10850030183792114, 0.19140125811100006, -1.5004304647445679, -0.23719289898872375, -0.24996121227741241, -0.5165240168571472, -1.1374472379684448, -0.09336759150028229, 1.394721508026123, -0.7556064128875732, -0.22265462577342987, 0.5580456852912903, 0.4054264426231384, 0.5814303159713745, 0.6079358458518982, -0.70699143409729, -0.4254937767982483, -0.25878357887268066, -0.38534146547317505, 0.3368806838989258, 1.3730852603912354, -0.11602278053760529, -0.955348014831543, 0.7653695344924927, -0.4211396872997284, 0.09493276476860046, 1.9961704015731812, 0.1007816269993782, -0.8056579232215881, 0.3377831280231476, -0.7605648636817932, 1.8682756423950195, 1.8349826335906982, 1.2875080108642578, -0.15032467246055603, -0.9976004958152771, 0.6167363524436951, -0.2588796019554138, -0.37949657440185547, 1.0187455415725708, 0.39576104283332825, -0.19989222288131714, -1.410754919052124, 0.5267131924629211, 1.2855290174484253, -0.8831906318664551, -0.7522541284561157, 0.07030743360519409, -0.8420953750610352, 1.0785398483276367, 0.7565851807594299, 0.42144498229026794, 0.18359369039535522, 1.6425169706344604, 0.7588878273963928, -0.46516135334968567, 0.5877725481987, 0.486561119556427, -0.16085663437843323, -2.105842113494873, -1.1399614810943604, 0.2762894332408905, -0.38292840123176575, -1.609315276145935, 1.3890808820724487, -1.187799334526062, -0.9629274606704712, 0.5843579173088074, 0.010379095561802387, 1.4939887523651123, 0.25738489627838135, 1.6173734664916992, 2.1479103565216064, 0.9431310892105103, 0.32055529952049255, 1.308969497680664, -0.11134103685617447, -0.45689019560813904, 1.8834725618362427, -0.4600087106227875, 0.49385350942611694, 1.0509507656097412, -0.36901867389678955, -1.0230000019073486, -0.7282492518424988, -1.1787588596343994, -0.6435049176216125, 1.17098867893219, 0.034248530864715576, -1.1429758071899414, 0.31948715448379517, 1.6836155652999878, 0.06176941469311714, -0.313448041677475, 0.6644521355628967, 0.49236780405044556, -0.7593763470649719, -0.055602699518203735, -0.9148406386375427, 0.4641139507293701, -0.0918966606259346, -0.34424838423728943, 0.29152920842170715, 0.4499722123146057, 1.237196445465088, 0.05994511768221855, 0.08922092616558075, 1.1739238500595093, -1.3548133373260498, 1.4515236616134644, -0.6444762349128723, 0.2582440674304962, -2.422003746032715, 1.3366272449493408, -0.7817043662071228, 1.8656004667282104, -2.5395162105560303, 0.3945970833301544, -0.5903307199478149, -0.5439822673797607, 0.3954671323299408, -0.3526264727115631, 0.16902245581150055, -0.19190682470798492, -1.0322519540786743, -0.0946618914604187, -0.7512115836143494, 0.6122093200683594, 1.103770136833191, 1.3757245540618896, -1.0657891035079956, -0.23954486846923828, -1.7214242219924927, -0.12662623822689056, -0.6282152533531189, 0.35364243388175964, -1.9199833869934082, -0.2223033457994461, -1.9180054664611816, -2.3871302604675293, -1.4795408248901367, -0.8570809364318848, 1.022437334060669, 0.18479086458683014, -0.9277032613754272, 1.1687146425247192, -0.41963762044906616, -1.8945666551589966, 1.1155368089675903, -2.1440510749816895 ]
https://github.com/huggingface/datasets/issues/5158
Fix language and license tag names in all Hub datasets
Hi @ayushthe1, thanks for your offer. But as you can see, I self-assigned this issue. I have already fixed 200 out of the 402 datasets. My script is still running and fixing the rest. For example: https://huggingface.co/datasets/fhamborg/news_sentiment_newsmtsc/discussions/2/files
While working on this: - #5137 we realized there are still many datasets with deprecated "languages" and "licenses" tag names (instead of "language" and "license"). This is a blocking issue: no subsequent PR can be opened to modify their metadata: a ValueError will be thrown. We should fix the "language" and "license" tag names in all Hub datasets. TODO: - [x] Fix language and license tag names in 402 Hub datasets CC: @julien-c
456
37
Fix language and license tag names in all Hub datasets While working on this: - #5137 we realized there are still many datasets with deprecated "languages" and "licenses" tag names (instead of "language" and "license"). This is a blocking issue: no subsequent PR can be opened to modify their metadata: a ValueError will be thrown. We should fix the "language" and "license" tag names in all Hub datasets. TODO: - [x] Fix language and license tag names in 402 Hub datasets CC: @julien-c Hi @ayushthe1, thanks for your offer. But as you can see, I self-assigned this issue. I have already fixed 200 out of the 402 datasets. My script is still running and fixing the rest. For example: https://huggingface.co/datasets/fhamborg/news_sentiment_newsmtsc/discussions/2/files
[ -1.2488325834274292, -0.9008521437644958, -0.8313117623329163, 1.4512993097305298, -0.23268234729766846, -1.2039867639541626, 0.012242388911545277, -1.0919189453125, 1.711693286895752, -0.849819004535675, 0.31996631622314453, -1.6009401082992554, -0.01987495645880699, -0.5381291508674622, -0.6704989671707153, -0.9328916072845459, -0.422959566116333, -0.8389376997947693, 0.9651997089385986, 2.479505777359009, 1.2617506980895996, -1.3658541440963745, 2.7918014526367188, 0.7274841070175171, -0.10907480865716934, -0.9505071043968201, 0.6881682872772217, 0.068489208817482, -1.3337748050689697, -0.3334651291370392, -1.1310713291168213, 0.05590374767780304, -0.36531439423561096, -0.33570727705955505, -0.03607278689742088, 0.2987200915813446, -0.3242272138595581, -0.4189014732837677, -0.5278059244155884, -0.8124661445617676, 0.3942190408706665, -0.25549086928367615, 0.9766311645507812, -0.5116845369338989, 1.8554092645645142, -0.5032140612602234, 0.2616780400276184, 0.7389019131660461, 1.218325138092041, 0.20874130725860596, 0.06408349424600601, 0.1456141173839569, 0.40709397196769714, -0.08877573162317276, 0.4561878442764282, 1.22255277633667, 0.46851876378059387, 0.5459561347961426, 0.70484858751297, -2.1512019634246826, 1.3087282180786133, -0.9356346130371094, 0.2663315236568451, 1.4026997089385986, -0.9167054295539856, 0.3271510899066925, -1.694376826286316, -0.09554476290941238, 0.6640840172767639, -2.24021053314209, 0.2661925256252289, -1.205244779586792, -0.6677600741386414, 1.0049184560775757, 0.2413116842508316, -1.1657131910324097, 0.08998946845531464, -0.4372536242008209, 1.0260380506515503, 0.5723837614059448, 1.1812530755996704, -1.527268409729004, 0.09058955311775208, -0.2992706894874573, -0.04033219814300537, -1.4417051076889038, -1.563693881034851, 0.5774080753326416, 0.6669191122055054, 0.6820393800735474, -0.02424459531903267, 0.9550009369850159, -1.0569323301315308, 0.9766899347305298, -0.8290895819664001, -1.6487524509429932, -1.4351824522018433, -2.369187355041504, -2.240844249725342, 0.8448275327682495, -0.5433002710342407, -0.48051729798316956, 1.9130035638809204, -1.0662659406661987, -1.7226063013076782, 1.2277710437774658, 0.3016531765460968, 0.07786907255649567, 2.38169002532959, 0.31808221340179443, -0.6374647617340088, 0.48542582988739014, -0.7274428009986877, 0.8369142413139343, -0.36528873443603516, 1.3275108337402344, 0.4912415146827698, -0.925932765007019, 1.6505895853042603, -0.5432025194168091, 0.4970576763153076, -0.5857329964637756, -0.5025494694709778, -0.8792362213134766, 0.38127589225769043, 1.7175966501235962, -0.3823936879634857, 1.5380277633666992, -0.29697030782699585, -1.5911856889724731, -1.6959714889526367, 0.7626007795333862, 0.5473433136940002, -0.6719384789466858, 0.03178318217396736, -0.4504927694797516, -0.06731739640235901, -0.02866610884666443, 1.1702969074249268, 1.1537179946899414, 0.796595573425293, -0.275326669216156, -0.8731082081794739, 0.2059648633003235, -0.060481633991003036, -0.731685221195221, -1.781008243560791, -0.27658531069755554, 0.15320080518722534, 0.6169387102127075, -1.2199897766113281, 1.6719518899917603, 0.9774854183197021, 1.9579695463180542, 0.9921838641166687, -0.2590237855911255, 1.5766468048095703, -0.03162184730172157, 1.685500144958496, -0.49578481912612915, 0.6275625824928284, -0.2997393310070038, -1.1579539775848389, 0.8136009573936462, -0.40116390585899353, -1.971246361732483, -0.8825130462646484, -0.9202864170074463, -0.2342170625925064, -0.7208956480026245, 1.0771634578704834, -0.3245254456996918, -1.3909162282943726, 0.2493155598640442, -0.6573032736778259, -0.04390009120106697, -1.16970956325531, 0.2649669349193573, 0.7411876916885376, -0.6396748423576355, -0.040011100471019745, -0.15127933025360107, -1.237194299697876, -0.5126636028289795, 0.30043965578079224, 1.9395077228546143, -0.7005710005760193, 0.8577346205711365, 1.0155754089355469, -0.7262288928031921, 0.11499855667352676, 0.19815409183502197, -0.3797236680984497, 0.8046058416366577, -1.0072345733642578, -0.4181959331035614, 1.2012242078781128, -0.14881230890750885, -0.7096165418624878, 1.5822185277938843, 0.7488787770271301, -0.9591664671897888, -0.23488125205039978, -0.17181278765201569, -0.7317660450935364, -0.038597967475652695, -1.4789795875549316, -0.14393918216228485, 0.13935862481594086, -1.3919678926467896, -0.49957749247550964, -0.1951390653848648, 1.27845299243927, -0.268058717250824, 1.4001033306121826, -0.4136498272418976, -0.3126657009124756, -0.4176645874977112, -0.4001215100288391, 0.20771756768226624, -0.15754841268062592, -0.5898038744926453, 0.2777935862541199, -0.9517868161201477, 0.27708494663238525, 1.4079878330230713, 0.46500417590141296, 0.08329898118972778, 0.6151983737945557, 1.0094033479690552, 0.39300617575645447, -0.013032777234911919, -0.906370222568512, -1.5718023777008057, 2.063858985900879, -1.4756364822387695, 2.0010690689086914, 0.7666144371032715, -0.06490950286388397, -1.8895292282104492, -1.905002236366272, 1.267009973526001, 1.1795648336410522, 2.2746493816375732, 0.5077964663505554, 0.252174973487854, -0.8447343111038208, -0.748171865940094, 0.4362652003765106, -1.140824556350708, -0.6965534090995789, 0.10142502188682556, 2.234273672103882, 1.797420620918274, -0.5504209995269775, -0.12487472593784332, -0.9013005495071411, 1.3301342725753784, -0.060685090720653534, 0.13873325288295746, 2.0078179836273193, -0.3173474371433258, -1.0575648546218872, 1.2799913883209229, -2.3216967582702637, 0.136135995388031, 1.995829463005066, 0.32154154777526855, 0.05566144734621048, -1.3852379322052002, -0.6994341015815735, -0.250405490398407, -0.4722661077976227, -1.2509441375732422, 0.6944270730018616, -0.29825323820114136, -0.9427024126052856, -1.4862946271896362, 0.20919038355350494, -1.2017769813537598, -1.6972975730895996, 0.39843666553497314, 1.8054890632629395, 2.1649930477142334, -0.8393052816390991, 1.5419464111328125, -0.17880287766456604, 0.06294634938240051, 1.1864194869995117, 1.2517893314361572, 3.119605779647827, 1.9258641004562378, -1.2212334871292114, 0.6407795548439026, -0.018859777599573135, -0.4124196767807007, 1.125236988067627, -1.112745761871338, 1.341843843460083, -0.15289293229579926, -1.0917656421661377, -1.2208610773086548, 1.0039314031600952, 0.4296673536300659, 0.11588434875011444, -0.49788206815719604, 1.1686774492263794, 0.1211642473936081, 1.3827321529388428, 0.5574135184288025, -0.34237948060035706, 0.5458770990371704, -0.39244645833969116, -0.48719748854637146, 1.5846176147460938, 0.17394058406352997, -1.472080945968628, -2.183764696121216, -0.24968038499355316, -0.770077109336853, -0.10540489852428436, -0.5512320399284363, -1.0330755710601807, 1.7379975318908691, 0.4046764671802521, -1.2578672170639038, -0.2945934236049652, -0.42281249165534973, -0.5841055512428284, 2.6606030464172363, -1.3318161964416504, -0.221400186419487, -0.9156595468521118, -0.5577183365821838, 1.6132876873016357, -1.244586706161499, -0.1001291275024414, -0.9967123866081238, -0.6510022282600403, -1.4395232200622559, -0.6302067041397095, 0.13253581523895264, -1.027459979057312, 0.8023514151573181, 0.09881751239299774, -1.0097640752792358, -0.3056555390357971, -0.8949142098426819, 0.8509032130241394, -0.1307421177625656, 0.37829843163490295, 2.021146774291992, 0.31555843353271484, -0.3964443802833557, 0.6884003281593323, 1.220927357673645, 0.6367572546005249, -0.6890460848808289, 0.22734315693378448, -0.6865664124488831, 0.3367305397987366, -1.2909208536148071, 0.29650455713272095, -3.043389320373535, 0.7287505865097046, -0.03991849347949028, -0.10602263361215591, -0.017382387071847916, -1.2135978937149048, 1.2003368139266968, 2.576151132583618, -1.183152675628662, 0.4041384160518646, 0.3283405900001526, 1.1698994636535645, -1.599293828010559, 0.336958110332489, -0.36095404624938965, 2.0619540214538574, 0.08422601968050003, 1.2027080059051514, -0.5758265852928162, -2.2101340293884277, 0.7870985269546509, -1.3386696577072144, -1.1373934745788574, 0.7281869053840637, -0.9590917825698853, 0.20778369903564453, -1.4652129411697388, -0.21076281368732452, -0.9324973821640015, -1.2818571329116821, 0.6643599271774292, 0.13344018161296844, 0.43845105171203613, -0.6397565007209778, 0.34869128465652466, -2.2364065647125244, -1.4549107551574707, -0.18228130042552948, -0.9203752875328064, 0.4329180121421814, -0.3849201798439026, 0.6682698130607605, -0.07835863530635834, 0.0312805213034153, 0.4478156864643097, 1.3510321378707886, 3.4141314029693604, 0.18800964951515198, 0.4378437101840973, -0.10573570430278778, -0.95574951171875, 1.5302612781524658, 1.035358190536499, -0.03686871752142906, -0.5708749890327454, -1.0559349060058594, 1.3179783821105957, 1.9502428770065308, 1.003510594367981, 0.05137430876493454, -0.8277826309204102, -0.6337838172912598, -0.10252635180950165, 0.1391616314649582, 0.5074261426925659, 0.9591979384422302, -0.08974887430667877, 0.1604563593864441, 1.5419014692306519, 1.2729454040527344, -0.37093305587768555, 0.25424250960350037, -0.7938958406448364, -0.5133550763130188, 0.5914554595947266, 0.30319085717201233, -0.020410384982824326, 0.5320088267326355, -0.9875033497810364, -0.39902594685554504, -0.27617794275283813, -0.922112762928009, -0.5260008573532104, -0.5084726214408875, -0.3689269721508026, 1.5307234525680542, 0.0841280147433281, -0.5163760781288147, -0.011871770024299622, -0.893573522567749, -0.10668963938951492, -1.0616285800933838, 0.2150004655122757, -0.20344460010528564, -0.05143054947257042, -0.20575843751430511, 1.8802238702774048, -0.9430317878723145, -2.108187198638916, 0.16303926706314087, 0.277370810508728, -0.32321491837501526, 0.18084007501602173, 1.5467207431793213, 0.5404155850410461, 1.4171477556228638, 1.2149149179458618, 1.0047866106033325, -0.6433495879173279, -1.3245733976364136, 0.6591737866401672, 0.9955859780311584, -1.4664852619171143, 0.8595754504203796, -0.20447859168052673, -0.5802700519561768, 0.684217095375061, 1.2388615608215332, 0.384954571723938, -1.8906307220458984, 0.8001521825790405, -0.9150795340538025, 0.8346923589706421, 0.6971916556358337, 0.7397895455360413, 0.15365761518478394, 0.9636533260345459, -1.224147081375122, -1.0823969841003418, -0.8118654489517212, -0.6907637119293213, 1.9625955820083618, -0.23493248224258423, 0.49183571338653564, -0.2146892547607422, -1.227608561515808, -0.018951416015625, 0.590411365032196, 0.1940527707338333, -0.28978782892227173, 0.8566364645957947, -0.7722778916358948, -1.1195932626724243, -1.4445788860321045, -0.36403560638427734, -0.9421883821487427, -0.9335975646972656, 1.1129660606384277, 0.7653252482414246, 0.28798821568489075, 2.059702157974243, 0.6508605480194092, 0.26942262053489685, -2.6532256603240967, 0.9455662369728088, 0.21011236310005188, 0.03691897168755531, 0.9424015879631042, 0.18545128405094147, 1.1548092365264893, 0.004819563589990139, 0.41282153129577637, -2.411431312561035, 2.3624229431152344, -0.3373790979385376, 0.7231299877166748, -0.013521328568458557, -0.19905968010425568, 1.1661787033081055, 0.691779613494873, 0.5997630953788757, -1.133187174797058, 0.6334947943687439, -0.45727670192718506, 1.2129504680633545, 1.045702576637268, -0.7445911169052124, -0.04836109280586243, 1.2356128692626953, 0.5706826448440552, -0.42627227306365967, -0.8503192067146301, -0.8119338154792786, 0.8673319816589355, 1.6918041706085205, 0.024646393954753876, 0.11821058392524719, 0.8360365629196167, 0.586305558681488, -1.2630696296691895, -0.04058317095041275, -0.7552648782730103, -0.7042657732963562, 1.70279061794281, 2.110729217529297, -0.048103995621204376, -0.13811716437339783, -0.6928269863128662, -1.273932695388794, 0.823544442653656, -0.06717640161514282, 0.25378313660621643, 0.6088016629219055, -0.6271939277648926, 0.9945283532142639, 0.8255210518836975, 0.8647050857543945, 0.0974460020661354, 0.39122724533081055, 0.41019129753112793, -0.21717333793640137, -1.1915698051452637, -0.28477638959884644, -1.0413331985473633, -2.632704734802246, 0.43408215045928955, -0.3076382577419281, -1.4003448486328125, -0.12977595627307892, -1.065907597541809, 0.9493054747581482, -0.5913598537445068, -0.9303023219108582, -1.4285178184509277, 0.24480968713760376, -0.13333436846733093, 0.9903708696365356, -1.5163432359695435, -0.19697771966457367, 1.316032886505127, 0.9178898334503174, -0.6542882919311523, 1.0911988019943237, 0.19582641124725342, 1.0505380630493164, 0.742306113243103, -0.4475463628768921, 0.4449179768562317, 0.11190642416477203, -1.417100191116333, 0.34664633870124817, 1.1357905864715576, 0.06510929763317108, 1.4561328887939453, -0.44616708159446716, 0.056005872786045074, 0.471483439207077, -0.5937803983688354, -0.4799717664718628, -0.4532562792301178, 0.7004002928733826, 0.0840379074215889, -0.9327367544174194, -0.016597744077444077, -0.09839265048503876, -0.329561710357666, 0.11872352659702301, -1.534397006034851, -0.24498869478702545, -0.367313414812088, -0.5124632716178894, -1.311293125152588, 0.05125744268298149, 1.3267091512680054, -0.8186054825782776, -0.10230447351932526, 0.41934674978256226, 0.3696955740451813, 0.6868017315864563, 0.721764862537384, -0.7436262369155884, -0.29150059819221497, -0.3656928837299347, -0.21540974080562592, 0.3107219934463501, 1.3755007982254028, -0.16048869490623474, -0.9926731586456299, 0.6655745506286621, -0.28987357020378113, 0.09837859869003296, 2.0608432292938232, 0.05767979472875595, -0.735014021396637, 0.2756715714931488, -0.6998153328895569, 1.8768593072891235, 1.5919899940490723, 1.319041132926941, -0.07934777438640594, -0.7809407711029053, 0.5824187994003296, -0.2545413672924042, -0.2767570912837982, 0.8277108073234558, 0.4912562370300293, -0.168391615152359, -1.3773196935653687, 0.5823226571083069, 1.1778366565704346, -0.9764597415924072, -0.7229616641998291, 0.11238133907318115, -0.7677749395370483, 1.0739178657531738, 0.7552563548088074, 0.43312737345695496, 0.36517658829689026, 1.6165374517440796, 0.7251721620559692, -0.5519701838493347, 0.3547859489917755, 0.4996985197067261, -0.012577587738633156, -2.00813627243042, -0.9788942337036133, 0.3507560193538666, -0.5127961039543152, -1.567703127861023, 1.3478102684020996, -1.139617681503296, -0.9336426854133606, 0.5443719625473022, -0.005735625047236681, 1.3896965980529785, 0.39561542868614197, 1.6477774381637573, 2.0399093627929688, 0.8308829069137573, 0.2740287780761719, 1.3322572708129883, -0.15463823080062866, -0.46111080050468445, 1.8752949237823486, -0.48283034563064575, 0.5049551725387573, 1.0825004577636719, -0.41416096687316895, -0.9984405040740967, -0.7835156321525574, -1.087592363357544, -0.5996624231338501, 1.123509407043457, 0.061961278319358826, -1.1754257678985596, 0.0984436571598053, 1.5529167652130127, 0.04852544516324997, -0.2989242672920227, 0.6167008280754089, 0.4701698422431946, -0.7914796471595764, -0.05944620445370674, -0.9339300394058228, 0.5164414644241333, -0.2060725837945938, -0.45311596989631653, 0.2678544819355011, 0.41953685879707336, 1.3572956323623657, -0.14680710434913635, 0.05374691262841225, 1.1708956956863403, -1.3911995887756348, 1.4587557315826416, -0.6386616230010986, 0.1601920872926712, -2.4625635147094727, 1.3578801155090332, -0.7758163809776306, 1.9337438344955444, -2.6926255226135254, 0.43096286058425903, -0.5756374001502991, -0.47085943818092346, 0.3533421754837036, -0.4392426013946533, 0.17525282502174377, -0.1581866592168808, -1.0688341856002808, -0.11903856694698334, -0.7341240644454956, 0.5285393595695496, 1.1635823249816895, 1.2729756832122803, -1.1165212392807007, -0.39290550351142883, -1.6934537887573242, -0.1768084615468979, -0.819598376750946, 0.25561243295669556, -2.0635476112365723, -0.2856963872909546, -1.8673478364944458, -2.277776002883911, -1.3360390663146973, -0.8703927397727966, 1.1709784269332886, 0.06831428408622742, -0.99710613489151, 1.0959062576293945, -0.3219849467277527, -1.8170288801193237, 1.1401504278182983, -2.110966920852661 ]
https://github.com/huggingface/datasets/issues/5157
Consistent caching between python and jupyter
Hi ! Maybe it's possible to have a consistent hash for a function defined in `__main__` and a function define in a notebook. However for functions imported from another location, pickle uses the location to identify the code, so in that case we can't do much I believe. Would it be ok for you if we only try to do this for functions in `__main__` / jupyter ? If you'd like to contribute, you can read this part of the code and let me know if you have questions: https://github.com/huggingface/datasets/blob/7feeb5648a63b6135a8259dedc3b1e19185ee4c7/src/datasets/utils/py_utils.py#L617-L643 I think the key here would be to also ignore the "co_filename" of functions defined in `__main__`
### Feature request I hope this is not my mistake, currently if I use `load_dataset` from a python session on a custom dataset to do the preprocessing, it will be saved in the cache and in other python sessions it will be loaded from the cache, however calling the same from a jupyter notebook does not work, meaning the preprocessing starts from scratch. If adjusting the hashes is impossible, is there a way to manually set dataset fingerprint to "force" this behaviour? ### Motivation If this is not already the case and I am doing something wrong, it would be useful to have the two fingerprints consistent so one can create the dataset once and then try small things on jupyter without preprocessing everything again. ### Your contribution I am happy to try a PR if you give me some pointers where the changes should happen
457
107
Consistent caching between python and jupyter ### Feature request I hope this is not my mistake, currently if I use `load_dataset` from a python session on a custom dataset to do the preprocessing, it will be saved in the cache and in other python sessions it will be loaded from the cache, however calling the same from a jupyter notebook does not work, meaning the preprocessing starts from scratch. If adjusting the hashes is impossible, is there a way to manually set dataset fingerprint to "force" this behaviour? ### Motivation If this is not already the case and I am doing something wrong, it would be useful to have the two fingerprints consistent so one can create the dataset once and then try small things on jupyter without preprocessing everything again. ### Your contribution I am happy to try a PR if you give me some pointers where the changes should happen Hi ! Maybe it's possible to have a consistent hash for a function defined in `__main__` and a function define in a notebook. However for functions imported from another location, pickle uses the location to identify the code, so in that case we can't do much I believe. Would it be ok for you if we only try to do this for functions in `__main__` / jupyter ? If you'd like to contribute, you can read this part of the code and let me know if you have questions: https://github.com/huggingface/datasets/blob/7feeb5648a63b6135a8259dedc3b1e19185ee4c7/src/datasets/utils/py_utils.py#L617-L643 I think the key here would be to also ignore the "co_filename" of functions defined in `__main__`
[ -1.1666629314422607, -0.9207826256752014, -0.7623497843742371, 1.4837335348129272, -0.1701572835445404, -1.2866624593734741, 0.035648129880428314, -1.1051585674285889, 1.6342405080795288, -0.8299977779388428, 0.31220054626464844, -1.6477141380310059, 0.05498676002025604, -0.6254665851593018, -0.7364988923072815, -0.8738018274307251, -0.4061233699321747, -0.8315232396125793, 0.9875218868255615, 2.513702154159546, 1.1546473503112793, -1.477498173713684, 2.6706924438476562, 0.6471224427223206, -0.18528538942337036, -1.038489580154419, 0.5364027619361877, -0.009650034829974174, -1.2004354000091553, -0.519589364528656, -0.9429168105125427, -0.04156661778688431, -0.5428146123886108, -0.4398432970046997, -0.09821127355098724, 0.4447009563446045, -0.24666298925876617, -0.30799543857574463, -0.536917507648468, -0.7950561046600342, 0.4696933627128601, -0.3584113121032715, 1.012044906616211, -0.3458898365497589, 1.858256459236145, -0.45794451236724854, 0.42086315155029297, 0.7582998275756836, 1.3343371152877808, 0.19786879420280457, -0.01170152984559536, 0.20124146342277527, 0.35932111740112305, -0.14355088770389557, 0.4147014021873474, 1.1228792667388916, 0.6297090649604797, 0.5619173049926758, 0.5753702521324158, -2.1816792488098145, 1.383758783340454, -0.9702065587043762, 0.35142648220062256, 1.3327912092208862, -0.9678212404251099, 0.41398975253105164, -1.7600889205932617, -0.026955557987093925, 0.570698618888855, -2.2270634174346924, 0.2835042178630829, -1.2352197170257568, -0.5513157248497009, 1.0373271703720093, 0.27399125695228577, -1.2892155647277832, 0.1703076809644699, -0.4259074926376343, 1.1453946828842163, 0.4861255884170532, 1.074603796005249, -1.69704008102417, -0.04621652513742447, -0.2765420377254486, 0.07009755074977875, -1.2830034494400024, -1.6236772537231445, 0.47770005464553833, 0.6006520986557007, 0.5203256011009216, -0.030413294211030006, 1.0121345520019531, -0.9889035224914551, 0.8058081269264221, -0.9387525916099548, -1.6140943765640259, -1.3911569118499756, -2.3439958095550537, -2.3503458499908447, 0.7941235303878784, -0.5048588514328003, -0.5841203331947327, 2.060396194458008, -1.0782665014266968, -1.6955152750015259, 1.2287840843200684, 0.27672079205513, 0.002900400198996067, 2.4253265857696533, 0.228827565908432, -0.698005735874176, 0.4325714707374573, -0.6999828219413757, 0.912475049495697, -0.5606468319892883, 1.3321515321731567, 0.477805495262146, -1.0243014097213745, 1.5211139917373657, -0.4727475643157959, 0.49626681208610535, -0.6561741828918457, -0.5407609343528748, -0.8507482409477234, 0.4237261414527893, 1.8397537469863892, -0.3347812294960022, 1.5986565351486206, -0.36464759707450867, -1.580264925956726, -1.6779260635375977, 0.9285049438476562, 0.4191070795059204, -0.8596727848052979, 0.12760180234909058, -0.41915059089660645, 0.10039620101451874, -0.14204666018486023, 1.0829004049301147, 1.2654273509979248, 0.6632727384567261, -0.3287827968597412, -0.8557271957397461, 0.17358937859535217, -0.1776968240737915, -0.6101726293563843, -1.7899304628372192, -0.28789737820625305, 0.18598777055740356, 0.6178093552589417, -1.190782904624939, 1.769930124282837, 0.9168923497200012, 1.9486994743347168, 1.014411211013794, -0.36131906509399414, 1.4983073472976685, 0.06642886996269226, 1.8178186416625977, -0.5131293535232544, 0.641629159450531, -0.27345511317253113, -1.1563067436218262, 0.8665016293525696, -0.40232059359550476, -1.9597558975219727, -0.7923678755760193, -0.8120850324630737, -0.202973410487175, -0.7443432211875916, 0.8923368453979492, -0.30119866132736206, -1.3652729988098145, 0.30000942945480347, -0.6484753489494324, 0.17567649483680725, -1.1573110818862915, 0.3747325539588928, 0.7508503198623657, -0.636394202709198, -0.009624555706977844, -0.2588951587677002, -1.2890267372131348, -0.4204852879047394, 0.38922566175460815, 1.8860609531402588, -0.6685466170310974, 0.9005008339881897, 1.0327543020248413, -0.6121286153793335, -0.023543495684862137, 0.3769530653953552, -0.25996166467666626, 0.817700982093811, -1.1269919872283936, -0.43438583612442017, 1.1710724830627441, -0.3149292767047882, -0.6106042861938477, 1.3962610960006714, 0.7959836721420288, -1.0219576358795166, -0.1492583453655243, -0.24390703439712524, -0.8538385033607483, -0.025530768558382988, -1.5894787311553955, -0.07855542749166489, 0.32863593101501465, -1.6021479368209839, -0.41166284680366516, -0.23545390367507935, 1.3009027242660522, -0.2415812462568283, 1.4206962585449219, -0.366798996925354, -0.13331419229507446, -0.3523356318473816, -0.4632660448551178, 0.1761631965637207, -0.17874093353748322, -0.5072014331817627, 0.13868585228919983, -0.7995190024375916, 0.29486122727394104, 1.4097718000411987, 0.3334827721118927, 0.0666542574763298, 0.46950763463974, 1.1291406154632568, 0.3602748215198517, -0.033633098006248474, -0.8588948845863342, -1.4850040674209595, 2.0586740970611572, -1.4666918516159058, 2.0145175457000732, 0.9345893859863281, 0.0017025964334607124, -1.7884135246276855, -1.8178178071975708, 1.3311477899551392, 1.166522741317749, 2.2886879444122314, 0.5309867858886719, 0.3851880133152008, -0.8527181148529053, -0.6866296529769897, 0.42795655131340027, -1.080757975578308, -0.7318982481956482, 0.06942441314458847, 2.3814902305603027, 1.7852659225463867, -0.4248459041118622, -0.20827922224998474, -0.9700199365615845, 1.4305416345596313, -0.12920217216014862, 0.18700069189071655, 2.0126354694366455, -0.27319589257240295, -1.0666873455047607, 1.222305178642273, -2.4025721549987793, 0.1364946961402893, 2.013977289199829, 0.2177727222442627, 0.0427774116396904, -1.412556529045105, -0.5742670297622681, -0.21678774058818817, -0.3326415419578552, -1.2164552211761475, 0.5349493622779846, -0.30139654874801636, -0.7169358134269714, -1.5229346752166748, 0.18683189153671265, -1.1442829370498657, -1.6460858583450317, 0.29252728819847107, 1.9196958541870117, 2.0553643703460693, -0.83377605676651, 1.5856807231903076, -0.26465582847595215, 0.13725587725639343, 1.2689788341522217, 1.2226552963256836, 3.233142375946045, 1.8766392469406128, -1.3122493028640747, 0.5821289420127869, -0.13781175017356873, -0.47760269045829773, 1.1513140201568604, -1.1166101694107056, 1.3257304430007935, -0.15750204026699066, -1.1598535776138306, -1.2650281190872192, 0.9567102193832397, 0.5429130792617798, 0.045233242213726044, -0.5234948992729187, 1.253947138786316, 0.14142745733261108, 1.3156527280807495, 0.5360503792762756, -0.4055921137332916, 0.5582849979400635, -0.4453873932361603, -0.5994780659675598, 1.5500677824020386, 0.23420587182044983, -1.4458049535751343, -2.2371389865875244, -0.3187856674194336, -0.8264515995979309, -0.01205180399119854, -0.6009085178375244, -1.0361086130142212, 1.5575731992721558, 0.37956008315086365, -1.2852452993392944, -0.4010213017463684, -0.367453396320343, -0.5985815525054932, 2.5673022270202637, -1.3841674327850342, -0.16488662362098694, -0.9839165210723877, -0.5976661443710327, 1.5965219736099243, -1.3202077150344849, -0.20040099322795868, -1.0631506443023682, -0.661132276058197, -1.238525152206421, -0.5211373567581177, -0.023253183811903, -0.8641778826713562, 0.7005541324615479, 0.1992303729057312, -1.0966986417770386, -0.28917577862739563, -0.8089533448219299, 0.867437481880188, -0.1130119189620018, 0.3106510639190674, 1.7735122442245483, 0.39594870805740356, -0.4835366904735565, 0.7456748485565186, 1.179301381111145, 0.5767361521720886, -0.6596081256866455, 0.10969670116901398, -0.7232317924499512, 0.3173064589500427, -1.250313401222229, 0.33330056071281433, -2.9283359050750732, 0.6651657223701477, -0.047426044940948486, -0.11834113299846649, -0.016927864402532578, -1.3254008293151855, 1.0993071794509888, 2.570725440979004, -1.1457921266555786, 0.49667713046073914, 0.3604799509048462, 1.1844109296798706, -1.6847387552261353, 0.3768213391304016, -0.41023483872413635, 2.19760799407959, 0.13638189435005188, 1.2080556154251099, -0.5051590204238892, -2.3966317176818848, 0.5540202260017395, -1.2276082038879395, -1.1509230136871338, 0.8602380752563477, -0.8999066352844238, 0.01261787861585617, -1.4324630498886108, -0.22302062809467316, -0.8859899640083313, -1.2968571186065674, 0.7717623114585876, 0.0671033263206482, 0.43701329827308655, -0.5975245833396912, 0.30826157331466675, -2.1307339668273926, -1.3821072578430176, -0.18255513906478882, -0.907820999622345, 0.43746739625930786, -0.4133754372596741, 0.6521512269973755, -0.15572400391101837, 0.08972712606191635, 0.3006964921951294, 1.4283549785614014, 3.440643072128296, 0.24659113585948944, 0.414420485496521, -0.10737190395593643, -0.8778418898582458, 1.3656244277954102, 0.8559532761573792, -0.11163926124572754, -0.5702999830245972, -0.9756794571876526, 1.2806323766708374, 2.011307716369629, 1.0054315328598022, 0.09853023290634155, -0.7230126857757568, -0.670566201210022, -0.02210683375597, 0.175206258893013, 0.4228909909725189, 0.8837074041366577, -0.0015133293345570564, 0.11953772604465485, 1.367603063583374, 1.2842613458633423, -0.4260605573654175, 0.40630537271499634, -0.8126806020736694, -0.4829443097114563, 0.33963316679000854, 0.30849260091781616, -0.03364885598421097, 0.3564741909503937, -0.941422164440155, -0.3467848300933838, -0.4229964315891266, -0.9317265748977661, -0.7183500528335571, -0.4105241298675537, -0.32239991426467896, 1.6422605514526367, 0.09263309836387634, -0.5049329400062561, 0.039938509464263916, -0.76054847240448, -0.14005279541015625, -1.143937110900879, 0.14126579463481903, -0.0739247277379036, -0.1703280210494995, -0.04439318925142288, 1.8201727867126465, -0.9635921716690063, -2.105414867401123, 0.23538008332252502, 0.2409852147102356, -0.2941949963569641, 0.1916414052248001, 1.7115774154663086, 0.3942440152168274, 1.4011956453323364, 1.3619568347930908, 1.0493303537368774, -0.7595373392105103, -1.2716747522354126, 0.7722485661506653, 0.98089200258255, -1.4125738143920898, 0.8331636786460876, -0.05651625245809555, -0.5566103458404541, 0.7403903603553772, 1.2423067092895508, 0.4557991027832031, -1.9847803115844727, 0.8354238867759705, -0.9720832109451294, 0.7746939659118652, 0.7075092196464539, 0.7039071321487427, 0.27834612131118774, 0.8644760847091675, -1.1729193925857544, -1.1870440244674683, -0.7637088298797607, -0.7136645317077637, 1.9870729446411133, -0.33547264337539673, 0.6134059429168701, -0.08725767582654953, -1.3422240018844604, -0.1343803107738495, 0.8201138377189636, 0.40021252632141113, -0.396960586309433, 0.7681331038475037, -0.7170730233192444, -1.0058656930923462, -1.4599686861038208, -0.37726616859436035, -0.988090991973877, -0.9218138456344604, 1.0505346059799194, 0.8755705952644348, 0.27144676446914673, 1.9344087839126587, 0.6741732954978943, 0.3345896601676941, -2.5615241527557373, 0.9134507775306702, 0.3644125461578369, -0.10650666058063507, 0.880659818649292, 0.30600741505622864, 1.0562074184417725, 0.12924081087112427, 0.5162457823753357, -2.341709613800049, 2.275639772415161, -0.21746227145195007, 0.7677158117294312, -0.06058388948440552, -0.27699014544487, 1.183866024017334, 0.5747412443161011, 0.605996310710907, -1.1195043325424194, 0.6922028064727783, -0.49165549874305725, 1.1928995847702026, 0.9421222805976868, -0.8443244695663452, -0.01956094056367874, 1.3365076780319214, 0.4447718560695648, -0.5858573317527771, -0.9668506383895874, -0.9390623569488525, 0.8516420722007751, 1.7196582555770874, -0.0179603174328804, 0.017917195335030556, 0.7854466438293457, 0.637829065322876, -1.2544434070587158, 0.20499692857265472, -0.7492815852165222, -0.8665087819099426, 1.6548291444778442, 2.0097923278808594, -0.14909425377845764, -0.1889304220676422, -0.7361061573028564, -1.2570271492004395, 0.7818838357925415, -0.052577316761016846, 0.11273838579654694, 0.5594983100891113, -0.6752781867980957, 1.0760610103607178, 0.8757743239402771, 0.9391195178031921, 0.15346759557724, 0.24870659410953522, 0.4754372537136078, -0.3427782952785492, -1.0776400566101074, -0.22488343715667725, -1.1388146877288818, -2.549448251724243, 0.45137014985084534, -0.2111082524061203, -1.4494770765304565, -0.03835215047001839, -0.9716892242431641, 0.9358203411102295, -0.5310534834861755, -1.0950816869735718, -1.5368242263793945, 0.2332148551940918, -0.16073273122310638, 0.9569783210754395, -1.5832068920135498, -0.14323031902313232, 1.1677042245864868, 0.8455214500427246, -0.669277548789978, 1.023999810218811, 0.1663692444562912, 1.0556094646453857, 0.8620175719261169, -0.4664047956466675, 0.4902406632900238, 0.10734323412179947, -1.3542051315307617, 0.44901958107948303, 1.1228735446929932, 0.08014623075723648, 1.44064462184906, -0.5017210245132446, 0.014842197299003601, 0.4382181167602539, -0.5051915049552917, -0.46700379252433777, -0.5036705136299133, 0.7107506990432739, 0.01512041874229908, -0.8175308704376221, 0.13650423288345337, -0.191650852560997, -0.24612103402614594, 0.11145126074552536, -1.5763570070266724, -0.24908943474292755, -0.39750272035598755, -0.5450970530509949, -1.2990381717681885, -0.05059041827917099, 1.4200925827026367, -0.679410994052887, -0.2615376114845276, 0.534706711769104, 0.5245575904846191, 0.5073915123939514, 0.5907688736915588, -0.631507158279419, -0.34798312187194824, -0.29622742533683777, -0.3361862599849701, 0.34586256742477417, 1.2790189981460571, -0.1469801962375641, -0.8961800336837769, 0.6720682978630066, -0.3190644383430481, 0.05261869728565216, 1.9584139585494995, 0.1811312884092331, -0.7849277853965759, 0.3975883424282074, -0.6476919651031494, 1.9276634454727173, 1.7191627025604248, 1.356937050819397, -0.08288073539733887, -0.9269965291023254, 0.7356025576591492, -0.26333221793174744, -0.337127685546875, 1.005651593208313, 0.4195481240749359, -0.1743144690990448, -1.4610366821289062, 0.6205494403839111, 1.1671512126922607, -0.8432837724685669, -0.8195894360542297, -0.004408094100654125, -0.7347986102104187, 1.104373574256897, 0.6448577642440796, 0.4847569465637207, 0.21133680641651154, 1.7134777307510376, 0.753997266292572, -0.5299189686775208, 0.5743221044540405, 0.479160875082016, -0.17671601474285126, -2.1287858486175537, -1.1108441352844238, 0.27331751585006714, -0.4986485540866852, -1.5465105772018433, 1.3888822793960571, -1.1671892404556274, -1.0054341554641724, 0.5003712177276611, -0.03897685930132866, 1.3770157098770142, 0.30520376563072205, 1.5770851373672485, 2.1430139541625977, 0.8464069366455078, 0.42296406626701355, 1.321912407875061, -0.1663043200969696, -0.43341073393821716, 1.8795098066329956, -0.49347206950187683, 0.4230746924877167, 1.1156060695648193, -0.44134196639060974, -1.0523600578308105, -0.761581301689148, -1.0885378122329712, -0.6859506368637085, 1.1664073467254639, 0.00869983434677124, -0.9603517651557922, 0.3436129093170166, 1.6072053909301758, 0.08190310746431351, -0.3090755045413971, 0.5529482364654541, 0.5055521130561829, -0.7505863308906555, -0.0698767676949501, -0.8745815753936768, 0.5544649958610535, -0.14421114325523376, -0.35017672181129456, 0.417968213558197, 0.44581538438796997, 1.2674058675765991, -0.07716556638479233, 0.17008037865161896, 1.0941814184188843, -1.490676999092102, 1.4075132608413696, -0.5896254181861877, 0.20062905550003052, -2.4058029651641846, 1.4023641347885132, -0.6825051307678223, 1.9515531063079834, -2.6250967979431152, 0.374239057302475, -0.6619930267333984, -0.5183506011962891, 0.47475263476371765, -0.40587255358695984, 0.13215167820453644, -0.2390546351671219, -1.058595895767212, -0.06864475458860397, -0.6230410933494568, 0.6202724575996399, 1.1060105562210083, 1.2866171598434448, -1.0758304595947266, -0.17340123653411865, -1.6867716312408447, -0.14976440370082855, -0.7235735058784485, 0.21934886276721954, -1.9966667890548706, -0.18836568295955658, -1.983413815498352, -2.2722017765045166, -1.358510971069336, -0.8288862705230713, 1.028882384300232, 0.20253802835941315, -0.9374734163284302, 1.2065484523773193, -0.3242034316062927, -1.817989706993103, 1.1448523998260498, -2.05277681350708 ]
https://github.com/huggingface/datasets/issues/5157
Consistent caching between python and jupyter
Seems like a good solution, I will start a PR and see if I understood the changes needed. Thanks!
### Feature request I hope this is not my mistake, currently if I use `load_dataset` from a python session on a custom dataset to do the preprocessing, it will be saved in the cache and in other python sessions it will be loaded from the cache, however calling the same from a jupyter notebook does not work, meaning the preprocessing starts from scratch. If adjusting the hashes is impossible, is there a way to manually set dataset fingerprint to "force" this behaviour? ### Motivation If this is not already the case and I am doing something wrong, it would be useful to have the two fingerprints consistent so one can create the dataset once and then try small things on jupyter without preprocessing everything again. ### Your contribution I am happy to try a PR if you give me some pointers where the changes should happen
457
19
Consistent caching between python and jupyter ### Feature request I hope this is not my mistake, currently if I use `load_dataset` from a python session on a custom dataset to do the preprocessing, it will be saved in the cache and in other python sessions it will be loaded from the cache, however calling the same from a jupyter notebook does not work, meaning the preprocessing starts from scratch. If adjusting the hashes is impossible, is there a way to manually set dataset fingerprint to "force" this behaviour? ### Motivation If this is not already the case and I am doing something wrong, it would be useful to have the two fingerprints consistent so one can create the dataset once and then try small things on jupyter without preprocessing everything again. ### Your contribution I am happy to try a PR if you give me some pointers where the changes should happen Seems like a good solution, I will start a PR and see if I understood the changes needed. Thanks!
[ -1.1730329990386963, -0.9298734068870544, -0.8412758708000183, 1.4408092498779297, -0.28757062554359436, -1.275653600692749, 0.027657974511384964, -1.1112089157104492, 1.7039332389831543, -0.9325507283210754, 0.3408938944339752, -1.6681033372879028, 0.07997633516788483, -0.6199342012405396, -0.783378005027771, -0.9135268926620483, -0.3569938540458679, -0.8263993263244629, 0.9712222814559937, 2.5921263694763184, 1.103801965713501, -1.4839050769805908, 2.6670923233032227, 0.6274269223213196, -0.18799349665641785, -1.0210379362106323, 0.5982656478881836, 0.04352952167391777, -1.2055389881134033, -0.5235639810562134, -1.0505077838897705, -0.0435653030872345, -0.4791664779186249, -0.46099379658699036, -0.11206021159887314, 0.33044201135635376, -0.21865329146385193, -0.3092939853668213, -0.4884875416755676, -0.8126582503318787, 0.42106515169143677, -0.3336670696735382, 1.0893880128860474, -0.4154975712299347, 1.9604209661483765, -0.470144122838974, 0.36340659856796265, 0.7383813261985779, 1.3299239873886108, 0.22915968298912048, -0.06974296271800995, 0.2682954668998718, 0.4446524381637573, -0.08571846783161163, 0.2949117124080658, 0.9548145532608032, 0.521334171295166, 0.6453316807746887, 0.5802299976348877, -2.0943517684936523, 1.4184694290161133, -0.9908021688461304, 0.38863733410835266, 1.3250093460083008, -1.0585269927978516, 0.38551080226898193, -1.661081314086914, -0.028898978605866432, 0.5844883918762207, -2.187622308731079, 0.22545790672302246, -1.164104700088501, -0.604118824005127, 1.0322949886322021, 0.29548728466033936, -1.299845814704895, 0.1100180447101593, -0.4064178764820099, 1.0531179904937744, 0.5206676721572876, 1.11611807346344, -1.6837502717971802, -0.012309825047850609, -0.3789356052875519, 0.07972682267427444, -1.3656450510025024, -1.5507636070251465, 0.5222528576850891, 0.6606265306472778, 0.4748261570930481, -0.05142059549689293, 1.0135520696640015, -0.8972823023796082, 0.8248094320297241, -0.8601887822151184, -1.5938384532928467, -1.3901197910308838, -2.357017993927002, -2.34873366355896, 0.8488087058067322, -0.5939316749572754, -0.6587002277374268, 2.097508668899536, -1.0985043048858643, -1.6847319602966309, 1.2545148134231567, 0.1739833652973175, 0.002269475720822811, 2.445887565612793, 0.16229429841041565, -0.5870703458786011, 0.4760068655014038, -0.6549223065376282, 0.977532148361206, -0.675413191318512, 1.3805276155471802, 0.4687878489494324, -1.0778310298919678, 1.5507538318634033, -0.44685423374176025, 0.4003191888332367, -0.6105830073356628, -0.5178539156913757, -0.9420815706253052, 0.48069122433662415, 1.808366298675537, -0.32982194423675537, 1.6704479455947876, -0.3687812387943268, -1.5687289237976074, -1.7687772512435913, 0.974483847618103, 0.45035210251808167, -0.8514136672019958, 0.2103494107723236, -0.3921821117401123, 0.016004418954253197, -0.11962764710187912, 1.1056290864944458, 1.2861522436141968, 0.633095383644104, -0.23525577783584595, -0.8647081255912781, 0.2094820737838745, -0.194163978099823, -0.5925865769386292, -1.8086962699890137, -0.38041338324546814, 0.033578626811504364, 0.6958596110343933, -1.1308494806289673, 1.7257437705993652, 0.941860556602478, 1.9275497198104858, 1.0352901220321655, -0.2701510787010193, 1.502345085144043, 0.07598051428794861, 1.7745859622955322, -0.5357268452644348, 0.6987137198448181, -0.29150012135505676, -1.1269183158874512, 0.8258286118507385, -0.4987471401691437, -1.9018354415893555, -0.7789617776870728, -0.9243981242179871, -0.19412201642990112, -0.7729706764221191, 0.9718242287635803, -0.3402195870876312, -1.2868138551712036, 0.3675181269645691, -0.6605679988861084, 0.12319258600473404, -1.1316392421722412, 0.45786795020103455, 0.7556859254837036, -0.5836232304573059, -0.005324254743754864, -0.25503009557724, -1.257857084274292, -0.39374685287475586, 0.3159337043762207, 1.9730560779571533, -0.7621058821678162, 0.9885686635971069, 0.9419963955879211, -0.6189250349998474, -0.13247224688529968, 0.45394718647003174, -0.25200483202934265, 0.8392229080200195, -1.108010172843933, -0.36908724904060364, 1.113703727722168, -0.33904075622558594, -0.5083919763565063, 1.395241141319275, 0.6999534964561462, -0.9972442388534546, -0.09130318462848663, -0.20702731609344482, -0.8317760825157166, -0.05823608860373497, -1.5941648483276367, -0.04324593022465706, 0.23200327157974243, -1.6009689569473267, -0.49660995602607727, -0.22688862681388855, 1.2528294324874878, -0.15758568048477173, 1.3896620273590088, -0.42599985003471375, -0.31203493475914, -0.3823906183242798, -0.3928888440132141, 0.2194296419620514, -0.22350633144378662, -0.5282042622566223, 0.1615988314151764, -0.7253049612045288, 0.2959161102771759, 1.321364164352417, 0.3589632511138916, 0.08250430971384048, 0.5828047394752502, 1.0512279272079468, 0.33617261052131653, -0.0403481088578701, -0.9296398162841797, -1.4626563787460327, 2.0383450984954834, -1.4598721265792847, 1.9519319534301758, 0.9654713869094849, 0.01424676738679409, -1.821560025215149, -1.7737282514572144, 1.4065542221069336, 1.271153450012207, 2.204610824584961, 0.6099101305007935, 0.30284959077835083, -0.8698033094406128, -0.6228412985801697, 0.4472790062427521, -1.0672489404678345, -0.7992802858352661, -0.0008824882097542286, 2.334113121032715, 1.739674687385559, -0.45968517661094666, -0.20234307646751404, -1.0695953369140625, 1.3947354555130005, -0.06596951186656952, 0.15108025074005127, 2.026109218597412, -0.37251517176628113, -1.1178257465362549, 1.1372606754302979, -2.3211491107940674, -0.01179447304457426, 2.0129334926605225, 0.23875421285629272, 0.009154466912150383, -1.4698679447174072, -0.5793975591659546, -0.21350392699241638, -0.3410683274269104, -1.2589515447616577, 0.5344175696372986, -0.3628372848033905, -0.6662092208862305, -1.5636905431747437, 0.21402734518051147, -1.1616326570510864, -1.6200823783874512, 0.25324586033821106, 1.884061574935913, 2.1069910526275635, -0.7727044820785522, 1.6048091650009155, -0.21565008163452148, 0.17402386665344238, 1.2436211109161377, 1.1661040782928467, 3.221116781234741, 1.9648545980453491, -1.2675038576126099, 0.6043561100959778, -0.0673743486404419, -0.49408552050590515, 1.2007710933685303, -1.0836609601974487, 1.383902668952942, -0.1319032907485962, -1.1344897747039795, -1.2829817533493042, 0.8213350772857666, 0.4709186255931854, 0.030492182821035385, -0.4942283034324646, 1.3439422845840454, 0.08877156674861908, 1.242756724357605, 0.539143443107605, -0.3032151162624359, 0.5550016760826111, -0.46422117948532104, -0.5557565093040466, 1.543034315109253, 0.3115766644477844, -1.4526885747909546, -2.2792134284973145, -0.3026995360851288, -0.7840298414230347, 0.008559387177228928, -0.5855578184127808, -1.0049861669540405, 1.637536883354187, 0.37913405895233154, -1.1789863109588623, -0.4496006667613983, -0.3988160789012909, -0.6769174337387085, 2.5735039710998535, -1.3842452764511108, -0.20523247122764587, -0.9820464253425598, -0.5992327332496643, 1.618584394454956, -1.4095662832260132, -0.16404294967651367, -1.1020091772079468, -0.6167318224906921, -1.2646435499191284, -0.4889981746673584, -0.07595562934875488, -0.9479271769523621, 0.6961553692817688, 0.11045248061418533, -1.1038990020751953, -0.2022078037261963, -0.7552438378334045, 0.7633692622184753, -0.0031698066741228104, 0.40220099687576294, 1.8370379209518433, 0.42410025000572205, -0.4811476767063141, 0.6573293209075928, 1.2162491083145142, 0.5897948145866394, -0.7220433354377747, 0.16155123710632324, -0.7529046535491943, 0.2516787350177765, -1.1864951848983765, 0.35207444429397583, -2.9501373767852783, 0.6174746751785278, 0.02012125588953495, -0.18203136324882507, -0.04308413341641426, -1.2528852224349976, 1.1001845598220825, 2.553712844848633, -1.1651188135147095, 0.4713370203971863, 0.2678084969520569, 1.2941453456878662, -1.6806511878967285, 0.4135848879814148, -0.42554983496665955, 2.251617670059204, 0.2589978277683258, 1.0781830549240112, -0.45167019963264465, -2.365769147872925, 0.58876633644104, -1.297303557395935, -1.1616802215576172, 0.7293197512626648, -0.8215572834014893, -0.07094290107488632, -1.4467741250991821, -0.15333572030067444, -0.7993485927581787, -1.3115901947021484, 0.8466141223907471, 0.06951159238815308, 0.49598848819732666, -0.5398714542388916, 0.3154342770576477, -2.114370822906494, -1.4142608642578125, -0.23461052775382996, -0.9058255553245544, 0.33897075057029724, -0.38427743315696716, 0.7461737990379333, -0.26117533445358276, 0.17699965834617615, 0.33717265725135803, 1.3893029689788818, 3.4405360221862793, 0.25704044103622437, 0.5152638554573059, -0.07916730642318726, -0.859229564666748, 1.4893555641174316, 0.898287832736969, -0.07999474555253983, -0.6085188388824463, -0.9876081347465515, 1.2595515251159668, 2.0151772499084473, 1.0107524394989014, 0.1684534251689911, -0.7237387299537659, -0.5769752860069275, -0.06237996742129326, 0.18213990330696106, 0.40114280581474304, 0.8612945079803467, -0.009059920907020569, 0.1232672706246376, 1.4707577228546143, 1.2595704793930054, -0.4464637339115143, 0.43600738048553467, -0.7566661834716797, -0.5421252250671387, 0.3779468834400177, 0.3652856945991516, -0.00044007785618305206, 0.3593396544456482, -0.86817467212677, -0.42445608973503113, -0.3863694369792938, -1.0378512144088745, -0.6127185821533203, -0.45848336815834045, -0.3139188289642334, 1.64896559715271, 0.04045027866959572, -0.4938996732234955, -0.08507193624973297, -0.8272625207901001, -0.12700849771499634, -1.1330112218856812, 0.12855413556098938, -0.04313872754573822, -0.1856006383895874, 0.03134297579526901, 1.9060068130493164, -0.9625133872032166, -2.141986846923828, 0.2899447977542877, 0.3441842198371887, -0.2650839388370514, 0.203088641166687, 1.54493248462677, 0.46766918897628784, 1.3975236415863037, 1.3821312189102173, 1.0568026304244995, -0.7164835929870605, -1.3705518245697021, 0.759495735168457, 0.9726929664611816, -1.4033435583114624, 0.8330755829811096, -0.025593405589461327, -0.6034664511680603, 0.7007675170898438, 1.1888034343719482, 0.48036664724349976, -1.9054290056228638, 0.8258165717124939, -0.9018653035163879, 0.7964978814125061, 0.7182403206825256, 0.7280793786048889, 0.24280309677124023, 0.8424157500267029, -1.1875852346420288, -1.2184056043624878, -0.8178465962409973, -0.690323531627655, 2.0450634956359863, -0.3251844644546509, 0.6333391666412354, -0.13691741228103638, -1.3192696571350098, -0.1451699435710907, 0.7639465928077698, 0.3528810143470764, -0.31770196557044983, 0.7503387331962585, -0.7509686350822449, -1.1081445217132568, -1.5749233961105347, -0.3396760821342468, -0.9638341069221497, -0.9235886931419373, 1.1521580219268799, 0.8727999329566956, 0.14159241318702698, 1.9544756412506104, 0.5929421782493591, 0.2951781153678894, -2.5074243545532227, 0.8791440725326538, 0.2987065315246582, -0.028249602764844894, 0.8407672643661499, 0.28177714347839355, 1.0511176586151123, 0.10747908055782318, 0.4931368827819824, -2.362806558609009, 2.263932228088379, -0.2908949553966522, 0.7560800909996033, 0.05817499756813049, -0.18507352471351624, 1.242940902709961, 0.5878969430923462, 0.6008780598640442, -1.0642973184585571, 0.6550400257110596, -0.4973776936531067, 1.2617323398590088, 0.9919486045837402, -0.7899415493011475, -0.01134168729186058, 1.315753698348999, 0.5075424313545227, -0.5704670548439026, -0.9268437027931213, -0.9603424072265625, 0.8531809449195862, 1.740437626838684, 0.007253607735037804, 0.014848113059997559, 0.7212668061256409, 0.6140879392623901, -1.2702603340148926, 0.2396101951599121, -0.7727846503257751, -0.851047694683075, 1.6271380186080933, 2.014859676361084, -0.16683566570281982, -0.12108046561479568, -0.7093100547790527, -1.2250010967254639, 0.7533617615699768, -0.023711904883384705, 0.10482705384492874, 0.5977584719657898, -0.6325095295906067, 1.0109871625900269, 1.012253999710083, 0.9660443663597107, 0.2964070439338684, 0.24523910880088806, 0.47161567211151123, -0.2617884576320648, -1.0444920063018799, -0.22194012999534607, -1.0816928148269653, -2.5682101249694824, 0.4351058304309845, -0.34461334347724915, -1.4163572788238525, -0.010784078389406204, -0.9983778595924377, 0.9590290188789368, -0.5252828598022461, -0.9875348806381226, -1.6009799242019653, 0.09501605480909348, -0.1827748417854309, 0.9447906017303467, -1.538955569267273, -0.12489531189203262, 1.1790528297424316, 0.7997962832450867, -0.7321621775627136, 1.0892256498336792, 0.1338922679424286, 1.088569164276123, 0.9168161153793335, -0.512302815914154, 0.4362407326698303, 0.1771249771118164, -1.34678316116333, 0.4899137616157532, 1.0457799434661865, 0.08835680037736893, 1.4752283096313477, -0.5489317178726196, -0.0029852669686079025, 0.44786447286605835, -0.4075879156589508, -0.46784788370132446, -0.5839819312095642, 0.7260908484458923, 0.04220891743898392, -0.8014113306999207, 0.16567185521125793, -0.16401129961013794, -0.2962888777256012, 0.15113693475723267, -1.588779330253601, -0.16912266612052917, -0.44003206491470337, -0.5850684642791748, -1.2767977714538574, -0.10718917101621628, 1.397173523902893, -0.7014914751052856, -0.17315557599067688, 0.5068678259849548, 0.5571469068527222, 0.47196274995803833, 0.6419950127601624, -0.595696747303009, -0.3641224801540375, -0.20244908332824707, -0.39113497734069824, 0.35121020674705505, 1.2484731674194336, -0.25126826763153076, -0.8874419927597046, 0.6248441338539124, -0.21635472774505615, -0.012334792874753475, 1.9169212579727173, 0.2015029489994049, -0.8215728998184204, 0.34381213784217834, -0.6416460275650024, 1.9812860488891602, 1.5974384546279907, 1.3708441257476807, -0.04393862932920456, -0.9083092212677002, 0.7086170315742493, -0.12144976109266281, -0.33932730555534363, 0.9854837656021118, 0.4897903800010681, -0.13150626420974731, -1.4843991994857788, 0.6371565461158752, 1.161468267440796, -0.8838346004486084, -0.8620437979698181, -0.0375824011862278, -0.7496703267097473, 0.9544921517372131, 0.6962421536445618, 0.5457682013511658, 0.23478275537490845, 1.7310490608215332, 0.6707018613815308, -0.6230220198631287, 0.505857527256012, 0.41441959142684937, -0.0991421565413475, -2.097662925720215, -1.0789419412612915, 0.3243008553981781, -0.559973418712616, -1.54743230342865, 1.3183661699295044, -1.2122961282730103, -0.9356196522712708, 0.588038980960846, -0.022791024297475815, 1.4270063638687134, 0.2616749703884125, 1.562910556793213, 2.105598211288452, 0.8065329790115356, 0.40958964824676514, 1.2954177856445312, -0.11239058524370193, -0.4258348345756531, 1.8927128314971924, -0.42355236411094666, 0.40156033635139465, 1.1471858024597168, -0.41526898741722107, -0.9991887807846069, -0.7028268575668335, -1.1075115203857422, -0.6146216988563538, 1.0365636348724365, 0.07033585011959076, -1.0788763761520386, 0.2561444938182831, 1.5021895170211792, 0.10517691820859909, -0.2999986410140991, 0.42657461762428284, 0.5758548974990845, -0.7370361089706421, -0.014510223641991615, -0.9571998715400696, 0.5453444719314575, -0.17326202988624573, -0.3904434144496918, 0.4218735992908478, 0.4320933520793915, 1.2982667684555054, -0.13205020129680634, 0.15875595808029175, 1.1721365451812744, -1.4512146711349487, 1.3208903074264526, -0.5190874934196472, 0.10890036821365356, -2.423379898071289, 1.4791793823242188, -0.6832631230354309, 1.9329719543457031, -2.6859114170074463, 0.3431861102581024, -0.7522397637367249, -0.4683983623981476, 0.5631206631660461, -0.36293816566467285, 0.1342577338218689, -0.28574198484420776, -1.096312165260315, -0.01410400215536356, -0.6410593390464783, 0.49132588505744934, 1.1158474683761597, 1.154908537864685, -1.045181155204773, -0.1863926351070404, -1.7005866765975952, -0.1573655903339386, -0.679000973701477, 0.1878003180027008, -2.0296504497528076, -0.2310979664325714, -1.9768078327178955, -2.2544476985931396, -1.3546425104141235, -0.8565223217010498, 1.0919216871261597, 0.17450305819511414, -0.9672908186912537, 1.2047486305236816, -0.26664412021636963, -1.7951076030731201, 1.1092945337295532, -2.038881301879883 ]
https://github.com/huggingface/datasets/issues/5156
Unable to download dataset using Azure Data Lake Gen 2
Hi ! From the `adlfs` docs, there are two filesystems you can use: > To use the Gen1 filesystem: > - known_implementations[‘adl’] = {‘class’: ‘adlfs.AzureDatalakeFileSystem’} > > To use the Gen2 filesystem: > - known_implementations[‘abfs’] = {‘class’: ‘adlfs.AzureBlobFileSystem’} If I'm not mistaken you're using the second one - so you should use `abfs://` instead of `adl://`, and also run this at the beginning of your script: ```python from fsspec.registry import known_implementations known_implementations['abfs'] = {'class': 'adlfs.AzureDatalakeFileSystem'} ```
### Describe the bug When using the DatasetBuilder method with the credentials for the cloud storage Azure Data Lake (adl) Gen2, the following error is showed: ``` Traceback (most recent call last): File "download_hf_dataset.py", line 143, in <module> main() File "download_hf_dataset.py", line 102, in main builder.download_and_prepare(save_dir, storage_options=storage_options, max_shard_size="250MB", file_format="parquet") File "/home/clarisses/miniconda3/envs/hf_datasets_env/lib/python3.8/site-packages/datasets/builder.py", line 671, in download_and_prepare fs_token_paths = fsspec.get_fs_token_paths(output_dir, storage_options=storage_options) File "/home/clarisses/miniconda3/envs/hf_datasets_env/lib/python3.8/site-packages/fsspec/core.py", line 639, in get_fs_token_paths fs = cls(**options) File "/home/clarisses/miniconda3/envs/hf_datasets_env/lib/python3.8/site-packages/fsspec/spec.py", line 76, in __call__ obj = super().__call__(*args, **kwargs) TypeError: __init__() got an unexpected keyword argument 'account_name' ``` If I don't pass the storage_options argument (leave it as None), it requires the credentials used in ADL Gen 1: `TypeError: __init__() missing 3 required positional arguments: 'tenant_id', 'client_id', and 'client_secret'` Thus, it is not possible to download a dataset from the cloud using Azure Data Lake (adl) Gen2. ### Steps to reproduce the bug Assuming that you have an account on Azure and at Storage Account that can be used for reproduce: 1. Create a dict with the format to connect to Azure Data Lake Gen 2 ``` storage_options = {"account_name": ACCOUNT_NAME, "account_key": ACCOUNT_KEY) # gen 2 filesystem ``` 2. Create a dataset builder for any HF hosted dataset ``` builder = load_dataset_builder(dataset_name) ``` 3. Try to download the dataset passing the storage_options as an argument ``` save_dir = 'adl://my_save_dir' builder.download_and_prepare(save_dir, storage_options=storage_options, max_shard_size="250MB", file_format="parquet") ``` ### Expected behavior Not seeing the error mentioned above and being able to download the dataset to the provided path on ADL ### Environment info - `datasets` version: 2.6.1 - Platform: Linux-5.15.0-46-generic-x86_64-with-glibc2.17 - Python version: 3.8.13 - PyArrow version: 9.0.0 - Pandas version: 1.5.1
458
76
Unable to download dataset using Azure Data Lake Gen 2 ### Describe the bug When using the DatasetBuilder method with the credentials for the cloud storage Azure Data Lake (adl) Gen2, the following error is showed: ``` Traceback (most recent call last): File "download_hf_dataset.py", line 143, in <module> main() File "download_hf_dataset.py", line 102, in main builder.download_and_prepare(save_dir, storage_options=storage_options, max_shard_size="250MB", file_format="parquet") File "/home/clarisses/miniconda3/envs/hf_datasets_env/lib/python3.8/site-packages/datasets/builder.py", line 671, in download_and_prepare fs_token_paths = fsspec.get_fs_token_paths(output_dir, storage_options=storage_options) File "/home/clarisses/miniconda3/envs/hf_datasets_env/lib/python3.8/site-packages/fsspec/core.py", line 639, in get_fs_token_paths fs = cls(**options) File "/home/clarisses/miniconda3/envs/hf_datasets_env/lib/python3.8/site-packages/fsspec/spec.py", line 76, in __call__ obj = super().__call__(*args, **kwargs) TypeError: __init__() got an unexpected keyword argument 'account_name' ``` If I don't pass the storage_options argument (leave it as None), it requires the credentials used in ADL Gen 1: `TypeError: __init__() missing 3 required positional arguments: 'tenant_id', 'client_id', and 'client_secret'` Thus, it is not possible to download a dataset from the cloud using Azure Data Lake (adl) Gen2. ### Steps to reproduce the bug Assuming that you have an account on Azure and at Storage Account that can be used for reproduce: 1. Create a dict with the format to connect to Azure Data Lake Gen 2 ``` storage_options = {"account_name": ACCOUNT_NAME, "account_key": ACCOUNT_KEY) # gen 2 filesystem ``` 2. Create a dataset builder for any HF hosted dataset ``` builder = load_dataset_builder(dataset_name) ``` 3. Try to download the dataset passing the storage_options as an argument ``` save_dir = 'adl://my_save_dir' builder.download_and_prepare(save_dir, storage_options=storage_options, max_shard_size="250MB", file_format="parquet") ``` ### Expected behavior Not seeing the error mentioned above and being able to download the dataset to the provided path on ADL ### Environment info - `datasets` version: 2.6.1 - Platform: Linux-5.15.0-46-generic-x86_64-with-glibc2.17 - Python version: 3.8.13 - PyArrow version: 9.0.0 - Pandas version: 1.5.1 Hi ! From the `adlfs` docs, there are two filesystems you can use: > To use the Gen1 filesystem: > - known_implementations[‘adl’] = {‘class’: ‘adlfs.AzureDatalakeFileSystem’} > > To use the Gen2 filesystem: > - known_implementations[‘abfs’] = {‘class’: ‘adlfs.AzureBlobFileSystem’} If I'm not mistaken you're using the second one - so you should use `abfs://` instead of `adl://`, and also run this at the beginning of your script: ```python from fsspec.registry import known_implementations known_implementations['abfs'] = {'class': 'adlfs.AzureDatalakeFileSystem'} ```
[ -1.3055663108825684, -0.9339799880981445, -0.6370927691459656, 1.518212080001831, -0.18271560966968536, -1.2515560388565063, 0.1553952544927597, -1.088602900505066, 1.5381349325180054, -0.7773529887199402, 0.23737233877182007, -1.582140326499939, -0.06893029808998108, -0.5187291502952576, -0.7120531797409058, -0.8178710341453552, -0.37972280383110046, -0.8908596038818359, 1.1374229192733765, 2.4453346729278564, 1.3546334505081177, -1.3606544733047485, 2.7831997871398926, 0.6893303990364075, -0.2600065767765045, -1.024649739265442, 0.47560057044029236, -0.028523126617074013, -1.1273400783538818, -0.5334514379501343, -0.9156175851821899, -0.04372023418545723, -0.5897505879402161, -0.3379102647304535, 0.02436034008860588, 0.525507926940918, -0.3222771883010864, -0.33023038506507874, -0.5958847999572754, -0.7895135879516602, 0.5308963656425476, -0.3170122802257538, 0.9138679504394531, -0.33258795738220215, 1.7404882907867432, -0.5951719880104065, 0.4480222761631012, 0.734560489654541, 1.3398548364639282, 0.15684975683689117, 0.028021149337291718, 0.2875770628452301, 0.2886990010738373, -0.042193640023469925, 0.6192758679389954, 1.199276328086853, 0.6381300687789917, 0.5184189677238464, 0.6754369735717773, -2.209116220474243, 1.3369914293289185, -1.0141371488571167, 0.23490211367607117, 1.3490468263626099, -0.8202788829803467, 0.3563518822193146, -1.737609624862671, -0.07326121628284454, 0.6674972772598267, -2.2979156970977783, 0.35628369450569153, -1.2531764507293701, -0.48573821783065796, 0.9665502309799194, 0.35382628440856934, -1.2191654443740845, 0.183322936296463, -0.5439212322235107, 1.1601760387420654, 0.41412588953971863, 1.0125453472137451, -1.6835640668869019, -0.03978275507688522, -0.1321871429681778, 0.08395642042160034, -1.3313318490982056, -1.6704565286636353, 0.5832203030586243, 0.4758339524269104, 0.6945651173591614, -0.06711091846227646, 1.1178911924362183, -1.1197141408920288, 0.8385964632034302, -1.0340757369995117, -1.5420277118682861, -1.4350134134292603, -2.4677844047546387, -2.269376039505005, 0.7376488447189331, -0.5565704703330994, -0.5570863485336304, 2.0598864555358887, -0.9703062176704407, -1.6908224821090698, 1.0878558158874512, 0.2530708611011505, 0.1406380534172058, 2.4099209308624268, 0.19371958076953888, -0.7395274043083191, 0.5144197344779968, -0.7582974433898926, 0.876574695110321, -0.26058122515678406, 1.3007997274398804, 0.47873157262802124, -1.0228501558303833, 1.52268385887146, -0.38893112540245056, 0.615577757358551, -0.6124723553657532, -0.6102359890937805, -0.8219630122184753, 0.25973987579345703, 1.8273624181747437, -0.23310163617134094, 1.5578303337097168, -0.38022512197494507, -1.4986121654510498, -1.6015772819519043, 0.8804619312286377, 0.3703829348087311, -0.9287350177764893, 0.10204675793647766, -0.5168535113334656, 0.2230471521615982, -0.023903075605630875, 1.1521435976028442, 1.2772480249404907, 0.6434146761894226, -0.4152875542640686, -0.7982641458511353, 0.17581090331077576, -0.16604700684547424, -0.6645585298538208, -1.8283789157867432, -0.29277610778808594, 0.1033572107553482, 0.6202200651168823, -1.178902268409729, 1.7894365787506104, 0.8751453757286072, 1.9683794975280762, 0.9620503187179565, -0.39699140191078186, 1.4102836847305298, -0.03474970906972885, 1.848149299621582, -0.5087153911590576, 0.5708974599838257, -0.3465714454650879, -1.1692123413085938, 0.9515199065208435, -0.3586892783641815, -2.06184720993042, -0.8329069018363953, -0.6675763130187988, -0.2716193199157715, -0.7246535420417786, 0.8357195854187012, -0.3537084460258484, -1.462433934211731, 0.15777459740638733, -0.6479330062866211, 0.2714078724384308, -1.1633309125900269, 0.29097217321395874, 0.7107000350952148, -0.708408534526825, -0.055086661130189896, -0.2500140368938446, -1.2350618839263916, -0.5541123151779175, 0.4131917357444763, 1.9425370693206787, -0.5888658761978149, 0.8876703381538391, 1.050605297088623, -0.743401050567627, 0.14169231057167053, 0.09436006844043732, -0.3029230535030365, 0.7556501626968384, -1.0646212100982666, -0.5301432013511658, 1.2159395217895508, -0.39921796321868896, -0.7018043398857117, 1.4014372825622559, 0.6790946125984192, -1.1383440494537354, -0.2535807490348816, -0.22667370736598969, -0.9422149062156677, 0.05755462870001793, -1.4535683393478394, -0.2552393078804016, 0.4785776138305664, -1.533705711364746, -0.32536572217941284, -0.1297817826271057, 1.3982534408569336, -0.2535143494606018, 1.486185908317566, -0.38034364581108093, -0.10045543313026428, -0.21833501756191254, -0.4836762845516205, 0.2444370836019516, -0.1332167685031891, -0.5330819487571716, 0.10767783224582672, -0.8577722311019897, 0.3070138990879059, 1.4099678993225098, 0.31732863187789917, 0.0665956437587738, 0.3678574860095978, 1.140134334564209, 0.4499151408672333, -0.06577567756175995, -0.7888510227203369, -1.5377123355865479, 1.9575212001800537, -1.4357752799987793, 1.9625731706619263, 0.7882670760154724, -0.017608020454645157, -1.7547770738601685, -1.817702054977417, 1.225144386291504, 1.1396567821502686, 2.277315616607666, 0.48482897877693176, 0.35267332196235657, -0.7873963713645935, -0.7477030754089355, 0.35194480419158936, -1.0319405794143677, -0.6248438358306885, 0.09099972248077393, 2.3643980026245117, 1.7676644325256348, -0.48493337631225586, -0.20431643724441528, -0.8096779584884644, 1.3342416286468506, -0.2608674466609955, 0.34075433015823364, 2.037243604660034, -0.25195398926734924, -1.000491976737976, 1.3361127376556396, -2.4671835899353027, 0.3278373181819916, 2.1250667572021484, 0.2679760158061981, 0.23660896718502045, -1.3548436164855957, -0.5651460289955139, -0.32335224747657776, -0.39221858978271484, -1.2208142280578613, 0.5400169491767883, -0.25240010023117065, -0.7621573209762573, -1.4108818769454956, 0.1192992776632309, -1.2075475454330444, -1.6944421529769897, 0.3060058653354645, 2.031778573989868, 2.141371011734009, -0.7292448282241821, 1.464737892150879, -0.3248143792152405, -0.0051330700516700745, 1.2383378744125366, 1.3718562126159668, 3.012822151184082, 1.776247501373291, -1.267378807067871, 0.6026439666748047, -0.18778784573078156, -0.5100262761116028, 1.1534450054168701, -1.134832501411438, 1.2251085042953491, -0.13087202608585358, -1.1728178262710571, -1.3211110830307007, 1.0322822332382202, 0.5190269947052002, 0.01112845167517662, -0.4867505133152008, 1.2696659564971924, 0.11226920783519745, 1.3484405279159546, 0.5792814493179321, -0.40263429284095764, 0.44269153475761414, -0.3922944664955139, -0.5786531567573547, 1.5705844163894653, 0.18330836296081543, -1.568583369255066, -2.2703449726104736, -0.22631941735744476, -0.840167224407196, 0.07167704403400421, -0.6489734649658203, -0.9969691038131714, 1.6089116334915161, 0.31609806418418884, -1.1449782848358154, -0.28699466586112976, -0.30358532071113586, -0.4736955761909485, 2.6790409088134766, -1.2262135744094849, -0.12960834801197052, -0.9172775149345398, -0.6093711853027344, 1.60001802444458, -1.2837283611297607, -0.30733171105384827, -1.0178223848342896, -0.6919467449188232, -1.2020355463027954, -0.4063784182071686, 0.07365015149116516, -1.0842294692993164, 0.7538976669311523, 0.21353532373905182, -1.1757714748382568, -0.32510194182395935, -0.8711580634117126, 1.092350959777832, -0.15453311800956726, 0.18918077647686005, 1.8015528917312622, 0.24377702176570892, -0.4345385432243347, 0.8852428793907166, 1.2229042053222656, 0.6324158310890198, -0.5833877325057983, 0.015265077352523804, -0.6641902327537537, 0.45885971188545227, -1.3113985061645508, 0.3057350218296051, -3.0223283767700195, 0.6958982348442078, -0.1184551864862442, -0.1414049118757248, -0.08110637962818146, -1.3801543712615967, 1.086761236190796, 2.5769710540771484, -1.221452236175537, 0.515534520149231, 0.4541272222995758, 1.1182972192764282, -1.6614898443222046, 0.32248446345329285, -0.4707965850830078, 2.0939481258392334, 0.18045327067375183, 1.279165506362915, -0.5312393307685852, -2.302466869354248, 0.6694516539573669, -1.1907068490982056, -1.133863925933838, 0.7701993584632874, -0.9651479721069336, 0.29544416069984436, -1.49066162109375, -0.21846355497837067, -0.9255252480506897, -1.2403645515441895, 0.6251598000526428, 0.12539690732955933, 0.32752469182014465, -0.4817420542240143, 0.29562944173812866, -2.187777519226074, -1.4485979080200195, -0.20134058594703674, -1.0553076267242432, 0.6271263957023621, -0.5566990375518799, 0.5757216811180115, -0.0677320808172226, 0.08666135370731354, 0.29299503564834595, 1.5532293319702148, 3.441197156906128, 0.18536512553691864, 0.15392404794692993, -0.20293405652046204, -0.9528741836547852, 1.4968903064727783, 0.8309082984924316, -0.15351097285747528, -0.5863400101661682, -1.020678162574768, 1.3787578344345093, 2.0367894172668457, 0.9867345094680786, 0.04964270070195198, -0.7859752178192139, -0.664581298828125, -0.055850762873888016, 0.17321117222309113, 0.5565319061279297, 0.9672759771347046, 0.026471462100744247, 0.030555669218301773, 1.3612210750579834, 1.1823610067367554, -0.38645532727241516, 0.2889902889728546, -0.9081436991691589, -0.436259388923645, 0.40735751390457153, 0.14767813682556152, -0.02072654291987419, 0.5422225594520569, -0.8888353705406189, -0.2852743864059448, -0.34964805841445923, -0.8167322278022766, -0.7389818429946899, -0.3834780752658844, -0.485384464263916, 1.5477025508880615, 0.18716423213481903, -0.543795645236969, 0.03385099396109581, -0.6411123871803284, -0.19016803801059723, -1.102841854095459, 0.1623845398426056, -0.057316869497299194, -0.19634731113910675, -0.22880586981773376, 1.5419927835464478, -0.9056923389434814, -2.1520566940307617, 0.12349267303943634, 0.29765376448631287, -0.20242421329021454, 0.1445303112268448, 1.7713658809661865, 0.41600415110588074, 1.4149303436279297, 1.2968385219573975, 0.9244110584259033, -0.6017489433288574, -1.2238285541534424, 0.8050541281700134, 0.9498023986816406, -1.4190181493759155, 0.8732976913452148, -0.18086685240268707, -0.4929240942001343, 0.6648204922676086, 1.3241310119628906, 0.4954136610031128, -1.9865026473999023, 1.0052366256713867, -1.1207847595214844, 0.897157609462738, 0.7571284770965576, 0.6913658976554871, 0.25363317131996155, 0.9601348638534546, -1.1339521408081055, -1.1454664468765259, -0.6602795720100403, -0.7586822509765625, 1.9350372552871704, -0.392011433839798, 0.6361229419708252, -0.16010956466197968, -1.2184982299804688, -0.16917918622493744, 0.7802086472511292, 0.334751158952713, -0.4040471017360687, 0.922117292881012, -0.7115762233734131, -0.9015064835548401, -1.2698025703430176, -0.3975406289100647, -1.0815931558609009, -0.8985148668289185, 0.9785727858543396, 0.7736682295799255, 0.3783482611179352, 1.8949507474899292, 0.5847364664077759, 0.39044952392578125, -2.5628297328948975, 0.9183182120323181, 0.29388704895973206, -0.10437275469303131, 0.8799058794975281, 0.30729490518569946, 1.122544288635254, 0.05618869885802269, 0.5819403529167175, -2.3808043003082275, 2.249598979949951, -0.13080057501792908, 0.6309564113616943, 0.02695823833346367, -0.19967995584011078, 1.179633617401123, 0.6097840070724487, 0.4945497512817383, -1.1029417514801025, 0.7557241320610046, -0.5172338485717773, 1.1341134309768677, 0.9315266013145447, -0.8454145789146423, -0.006663105450570583, 1.4550113677978516, 0.4020458459854126, -0.6151149868965149, -0.9711251854896545, -0.8218057751655579, 0.9617633819580078, 1.6354851722717285, -0.05620989948511124, -0.03320057690143585, 0.7546395063400269, 0.6448947787284851, -1.130113124847412, 0.0763830691576004, -0.571221113204956, -0.7766161561012268, 1.6711963415145874, 2.048521041870117, -0.20241296291351318, -0.2080690562725067, -0.6548928022384644, -1.292806625366211, 0.8131005167961121, -0.1602482944726944, 0.043234262615442276, 0.5007603764533997, -0.6558998227119446, 0.960068941116333, 0.6644365191459656, 1.0174071788787842, -0.004286462906748056, 0.26228615641593933, 0.45141172409057617, -0.3897402882575989, -1.0700907707214355, -0.3349473476409912, -1.0960129499435425, -2.623753547668457, 0.3267627954483032, -0.23216521739959717, -1.4406553506851196, 0.06633169949054718, -1.0021378993988037, 0.9634718894958496, -0.5944745540618896, -1.1971182823181152, -1.5152186155319214, 0.273663192987442, -0.09915244579315186, 0.890484631061554, -1.6920771598815918, -0.26388487219810486, 1.2639169692993164, 0.7663350701332092, -0.6689749360084534, 0.9940871596336365, 0.2203364372253418, 1.0058330297470093, 0.7127232551574707, -0.40298327803611755, 0.6517935395240784, 0.0017228079959750175, -1.3859564065933228, 0.45628052949905396, 1.2828680276870728, 0.10366210341453552, 1.4376426935195923, -0.3765840232372284, 0.05574101582169533, 0.4028450548648834, -0.789033055305481, -0.5771169662475586, -0.32140275835990906, 0.7172562479972839, 0.001476941630244255, -0.9746690392494202, -0.1768297255039215, -0.16960595548152924, -0.3940170109272003, 0.11154608428478241, -1.5204482078552246, -0.2762988209724426, -0.4443203806877136, -0.4110819697380066, -1.3589575290679932, -0.02762611210346222, 1.3845824003219604, -0.6566575169563293, -0.27639517188072205, 0.4339933395385742, 0.4578774571418762, 0.5374231934547424, 0.5967727303504944, -0.7667273283004761, -0.20273041725158691, -0.3372591733932495, -0.21760691702365875, 0.3020455539226532, 1.249624490737915, -0.004238463006913662, -0.9276512861251831, 0.6827415227890015, -0.2968018352985382, 0.16403740644454956, 1.945902705192566, 0.06588247418403625, -0.6790469288825989, 0.3243478238582611, -0.795301079750061, 1.782699465751648, 1.6905494928359985, 1.3089269399642944, -0.15410061180591583, -0.8677940964698792, 0.6150907278060913, -0.3481121063232422, -0.3185221254825592, 0.8363555073738098, 0.4033014178276062, -0.3200402557849884, -1.4238946437835693, 0.786585807800293, 1.1259928941726685, -0.7546641230583191, -0.7423706650733948, 0.09621404111385345, -0.8080216646194458, 1.25498366355896, 0.4944864511489868, 0.3093697130680084, 0.2763042449951172, 1.649906039237976, 0.7746667861938477, -0.4639735519886017, 0.5343502759933472, 0.5916609764099121, -0.24458158016204834, -2.0810084342956543, -1.1357479095458984, 0.3683163821697235, -0.5120136737823486, -1.5941447019577026, 1.406769871711731, -1.051913857460022, -1.0328516960144043, 0.5710890889167786, 0.03648202121257782, 1.3026098012924194, 0.3987589180469513, 1.661470890045166, 2.105210781097412, 0.835150420665741, 0.5246036052703857, 1.2333953380584717, -0.17885655164718628, -0.5100353956222534, 1.8635910749435425, -0.35266241431236267, 0.45968085527420044, 1.105272650718689, -0.3847094476222992, -1.0993565320968628, -0.782035231590271, -1.158333420753479, -0.6691204905509949, 1.176340937614441, 0.14081931114196777, -1.0103569030761719, 0.21745522320270538, 1.6119005680084229, 0.20816302299499512, -0.2213551253080368, 0.6347681283950806, 0.45343565940856934, -0.7991868853569031, -0.11815838515758514, -0.8704797029495239, 0.5336028337478638, -0.24493083357810974, -0.3618488907814026, 0.3328644931316376, 0.5267820954322815, 1.3158609867095947, -0.09488050639629364, 0.15255482494831085, 0.990464985370636, -1.504515528678894, 1.4645881652832031, -0.6339458227157593, 0.34064075350761414, -2.316685438156128, 1.354168176651001, -0.6804733872413635, 2.119030475616455, -2.5399372577667236, 0.44207775592803955, -0.6429773569107056, -0.5178480744361877, 0.2836735248565674, -0.38088834285736084, 0.10068047046661377, -0.11579714715480804, -0.993903398513794, 0.005427313037216663, -0.6419969201087952, 0.6861757636070251, 1.1992231607437134, 1.4099823236465454, -1.0871012210845947, -0.24839471280574799, -1.6587400436401367, -0.2300851196050644, -0.7740179896354675, 0.28634026646614075, -1.9893170595169067, -0.20552147924900055, -2.066730260848999, -2.294687509536743, -1.1961337327957153, -0.7872253656387329, 1.097739338874817, 0.17361831665039062, -0.8822996616363525, 1.385205864906311, -0.34364181756973267, -1.7868750095367432, 1.1738622188568115, -2.1113181114196777 ]