Enabling cuDF using a single flag is insane! However, I just wannted to point out (especially for new pandas users) that the proper way to calculate average price per city in pandas is by using groupby. Running `df.groupby('Town/City')['price'].mean()` in plain pandas is blazing fast (a few ms), nothing compared to 19 minutes. That doesn't mean that cuDF is not useful, but don't forget that using plain pandas properly can get you a long way.
@AchileasGalatis9 ай бұрын
😊
@bantaibaman5662 Жыл бұрын
Hey Sentdex, can you take this video down so my manager doesn't find out that I sped up the entire codebase by 200 fold with just one line and I end up getting appreciation bonuses?? Jokes aside, this is absolutely wild. What a gamechanger. Thanks a lot as always, Kevin!
@harshvaragiya8834 Жыл бұрын
Awesome video! I encountered a similar issue where I had to process ~8 GB of data using an AWS Lambda (limited RAM and time). I used polars (pandas alternative written in rust from scratch for performance) and I found it to be blazing fast . It's really really useful - especially with non nvidia devices like my raspberry pi and the AWS lambda function. You should definitely check it out!
@incremental_failure Жыл бұрын
I've nearly forgotten pandas after going with polars. Pandas was great for its time.
@xylem87 Жыл бұрын
there is also dask which also allows deployment on clusters with several workers similar to spark
@AyahuascaDataScientist Жыл бұрын
@@incremental_failurepolars doesn’t even offer a .info() method. Simply inferior()
@incremental_failure Жыл бұрын
@@AyahuascaDataScientist df.describe()
@perryholman5302 Жыл бұрын
Wonderful! Thank you. It would be an interesting comparison with polars library as well.
@kenchang3456 Жыл бұрын
Once again thank you for sharing :-) You are appreciated.
@Brickkzz Жыл бұрын
Missing your tutorials man, trying to install this on windows...
@damianshaw8456 Жыл бұрын
For the read_csv operation I would be curious what is actually taking the most amount of time with the Pandas object, I suspect it's building the Python string objects, and if so I wonder if you have PyArrow installed and set pd.options.future.infer_string = True it would be much faster? And in general it makes sense that using strings are slow in Pandas, because it's falling back to looking up a Python object by via reference to it, it's actually a much more interesting comparison for number or datetime data types. For strings it would be much more interesting if you had use the PyArrow string data type.
@noormohammedshikalgar Жыл бұрын
Hello Sentdex, I am reaching out to you regarding your Neural network from scratch series ? any updates on that, you left on pt 9 Please do continue its an awesome series and any updated on Book discounts for use for the Black friday ?? please do help
@megalomaniacal Жыл бұрын
Thanks bro, will give it a test run.
@extrememike Жыл бұрын
Great find!🎉
@__python__ Жыл бұрын
Thanks for sharing... I would be curious about a comparison between accelerated version of pandas and polars.
@Mil-Keeway11 ай бұрын
3:38 it doesn't have the prices "in quotes like a string", it's a properly exported csv that has ALL fields quoted. Your pd.read_csv is missing quoting=csv.QUOTE_ALL (or just quoting=1) and optionally quotechar='\"' . The only "magic" pandas is doing is interpreting that column as quoted. If you add those options, I'm guessing cudf will run just as well, since the ingest portion will still be using python standard lib or at least pandas C implementations.
@HeigthTrielli8 ай бұрын
Hi! Can you share what hardware were you operating on?
@acelaox6836 Жыл бұрын
the kubota warrior is back with the heat 🗣🗣🗣
@jameslucas5590 Жыл бұрын
Outstanding. Thank you for this informatoin.
@usamatahir7091 Жыл бұрын
Thanks a lot for sharing. super useful
@oguzhanyldrm962 Жыл бұрын
Please post more often videos Harrison
@ahmed-yassinechraa8731 Жыл бұрын
Can you make a tutorial on howa to install cuDF, i saw that there is a lot of things to install before it
@maurice9327 Жыл бұрын
What if my RAM (128GB) is larger than my VRAM (32GB)? Is normal pandas still faster for data that's larger than the VRAM?
@thetdg Жыл бұрын
Great video. Just one thing: instead of comparing cuDF with vanilla Pandas, wouldn’t a comparison with Modin be a more appropriate one?
@droit19 Жыл бұрын
I'd like to see this as well, scale Modin on a Ray Cluster/Single Node using a GPU
@sternsemasuka9716 Жыл бұрын
How about Polar?
@vigneshpadmanabhan Жыл бұрын
CuDF vs Polars may be.
@EtienneTremblay Жыл бұрын
What happens if your dataset doesn't fit in GPU memory?
@jurajjakubik2185 Жыл бұрын
I have tested that and it is slower than on CPU. Pretty much you use all GPU memory and rest going to RAM. Then it is back and forward.
@BDog_111 ай бұрын
how would you start to make an AI that deals with data using python. I'm trying to learn more about this
@theMintyRaven5 ай бұрын
hi thank you for showing this great way to use gpu, it seems really easy but I ran into an error that I couldn't find the solution anywhere: UserWarning: cudf.pandas detected an already configured memory resource, ignoring 'CUDF_PANDAS_RMM_MODE'=managed_pool can anyone help me?
@kascesar Жыл бұрын
Impresive!
@BohonChina Жыл бұрын
how about Mojo? Mojo can actually use GPU to accelerate calculation too, currently Mojo support numpy,pandas in cpu. It will be fun to make a comparison with CuDF. Mojo is more like a superset for python.
@theMintyRaven5 ай бұрын
Can you please make a video for using cudf in python scripts? it's much trickier in the scripts
@catslover4745 Жыл бұрын
Hey does anyone know how to get this working on normal visual studio code python file instead of opening it in jupyter? Thanks
@Andrea-du3or8 ай бұрын
Has anyone been able to install the library with pip as he shown ? I keep getting errors like - Preparing metadata (pyproject.toml): finished with status 'error' :')
@mikahoy8 ай бұрын
Hi, how to do it for geopandas? is it same?
@VermontStrolls Жыл бұрын
Thanks a ton!
@d_b_ Жыл бұрын
This looks like it would beat out something like Dask for non-distributed large datasets. Is that the case?
@youknowmyname12345 Жыл бұрын
Does this new accelerator speed up groupby() operations?
@shashisaini7919 Жыл бұрын
@sentdex sir please make videos on 3d deep learning, its really exciting to see your work on point cloud
@AyahuascaDataScientist Жыл бұрын
Does cudf.pandas work with apple silicon MPS GPU framework instead of just cuda?
@r.k.vignesh7832 Жыл бұрын
9:01 I'm running late for work, but wouldn't it be possible to vectorize this code and it be faster than both the CuDF and the CPU versions of this benchmark? Curious to see how CuDF plays with vectorized versions. If I get the time I'll try some experiments and update this comment.
@r.k.vignesh7832 Жыл бұрын
On a trial dataset with 10000 rows of fake data (~500kB in size), using GroupBy to find the mean of the "unique prices" was 72x faster than the one implemented in this one at 6:45 or so. I expect that it will become exponentially faster with a dataset 5GB in size. I used groupby in another part and that naively halved the time, but it's still far from optimized and I'll probably upload my findings here with a ~5GB dataset running on Colab sometime in the next couple of weeks. After that, I'll try the CuDF version.
@EarlZMoade Жыл бұрын
Very interested to see this comparison. No one writes pandas code like this video where looping is both unnatural and terribly optimised.
@r.k.vignesh7832 Жыл бұрын
@@EarlZMoade thanks for your comment! I made a dataset with random data of 1.5GB for benchmarks, and for 2 operations (the first groupby at 6:45 and the upper-lower price bands) it took Sentdex's code 4 mins and 2 seconds, and 19 mins and 43 secs respectively on my computer. An optimized version (just Groupby and vectorization, nothing fancy) took 2.25 SECONDS and 13.5 seconds respectively. I'm sure CuDF would be even faster but in this case there was a lot of performance left on the table.
@ivchatov Жыл бұрын
Is this compatible with Python 3.7 at all? Last time I tried installing CuDF I remember version incompatibility stopping me.
@gingerjiang666 Жыл бұрын
Does it still use memorry to fit the entire dataset?
@bikkikumarsha Жыл бұрын
please make a video on custom GPTs, actions and open ai dev event
@Summersault666 Жыл бұрын
Will it work on apple notebook?
@sillybuttons925 Жыл бұрын
**does scipy work with it?
@EarlZMoade Жыл бұрын
What's the reasoning for not using groupby in this demo? Wouldn't that be the more natural and faster pandas method to use - instead of looping over everything. Feels a little disingenuous to compare poorly optimised pandas code that no one would actually write.
@JuanRamirez-di9bl Жыл бұрын
Is this faster than numpy??
@shaftymaze Жыл бұрын
Polars in rust wrapped in tqdm.
@kelkka7 Жыл бұрын
Will this work with geopandas?
@poloceccati Жыл бұрын
what about amd gpu ?
@AlignmentLabAI Жыл бұрын
jesus christ my life has totally changed
@delt19 Жыл бұрын
10 sec compared to 19 min?!?! Holy f....!!!!!
@SwissPGO Жыл бұрын
Any alternative for Apple Silicon ?
@mlcat Жыл бұрын
Dask maybe
@Adaministrator Жыл бұрын
Dask and swifter have like 1000x processing speed for some batch jobs I have with airflow, so def try that. It’s also drop in
@andreaqui16536 ай бұрын
Anyone have any luck getting it installed on a local windows machine?
@Harmxn4 ай бұрын
You cannot install it on Windows because CuDF is only supported on Linux. Instead, you can make a WSL instance and install Python and CuDF on there.
@Stinosko Жыл бұрын
Cool!
@citizenR1203 Жыл бұрын
Very interesting, thank you for sharing 😊but this seems to be not compatible with MacOS and 2,9 GHz Quad-Core Intel Core i7 processor.
@henryyoo3032 Жыл бұрын
which would make perfect sense since you would need a cuda enabled nvidia gpu for cudf to work
@MuhammadNurdinnewspecies Жыл бұрын
Next brow... how to manage your gpu memory. Loading your dataset and training your model
@ai.simplified.. Жыл бұрын
3:20
@jamoncitovideos Жыл бұрын
Ditch pandas and use spark, your local data engineer will thank you
@spicy.d Жыл бұрын
I'm waiting on AMD to enter the DS space so I can use my 7900XTX to do things LOL
@Arctect Жыл бұрын
like ** 10 == 0.0s
@ashu- Жыл бұрын
Ngl, your video looks like Deepfaked, I also think at this point you can probably deepfake yourself with a bit editing to make an people believe its real.