Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Roadmap] external memory support for tree_method='hist' #4093

Closed
CodingCat opened this issue Jan 31, 2019 · 15 comments
Closed

[Roadmap] external memory support for tree_method='hist' #4093

CodingCat opened this issue Jan 31, 2019 · 15 comments
Assignees

Comments

@CodingCat
Copy link
Member

in the doc we mentioned that Distributed and external memory version only support tree_method=approx

but is it valid now? what's the problem with external memory + hist? I tested but didn't see any issue, did I miss anything?

@CodingCat
Copy link
Member Author

@hcho3

@CodingCat
Copy link
Member Author

hmmm....looks like the training converged too early....but didn't get the idea why it is related to external memory or the row.page has some problem....

@hcho3
Copy link
Collaborator

hcho3 commented Jan 31, 2019

@CodingCat When I wrote the fast hist, I assumed that each DMatrix would have a single block, i.e. entire data fit in the memory. External memory support has not been tested. Is external memory high in your priority?

@trivialfis
Copy link
Member

There's open issue related to external memory #4037. I'm still struggling to understand it...

@CodingCat
Copy link
Member Author

@hcho3 , yes, our data size makes external memory a must-have......but I am a bit confused which part makes hist does not work with external memory....

@trivialfis what I observed is that when I setup external memory with hist tree_method, the metrics (train/test) doesn't change after 5 - 6 iterations, though the training still moves forward.....

@CodingCat
Copy link
Member Author

I have started looking into why external memory version of hist is messed up with accuracy

@CodingCat CodingCat self-assigned this Feb 8, 2019
@hcho3
Copy link
Collaborator

hcho3 commented Feb 8, 2019

@CodingCat Is this issue blocking?

@CodingCat
Copy link
Member Author

no, it just means you need more memory to use distributed hist,

@hcho3 hcho3 changed the title Distributed and external memory version only support tree_method=approx??? [Roadmap] external memory support for tree_method='hist' Mar 8, 2019
@rongou
Copy link
Contributor

rongou commented Feb 21, 2020

@CodingCat Is this still an issue? As part of my work on gpu external memory support, I tested hist on the Higgs dataset and got identical AUC metrics. The external memory version is actually slightly faster.

Mode Time(seconds) AUC
hist 1309.64 0.8393
hist external memory 1228.53 0.8393

@CodingCat
Copy link
Member Author

CodingCat commented Feb 21, 2020 via email

@PeterPanonGit
Copy link

@rongou In my experiments external memory seems to run much slower than the in-memory counterpart regardless of the tree_method I use. However in your benchmark it seems that hist and hist external memory speed is almost the same. Could you post a script that we can use to re-produce your benchmark?

@rongou
Copy link
Contributor

rongou commented Jan 22, 2021

@PeterPanonGit I don't have the script anymore, but I wasn't doing anything special, just the standard approach for enabling external memory. Since in external memory mode a lot of data is written out to disk and read back, the speed of your disk might be a factor. Are you on a local desktop with a late model SSD? In the cloud environment I/O might be more constrained.

@PeterPanonGit
Copy link

@rongou I used an SSD but external memory version is still ~3x slower than in memory version. Maybe my SSD is not good. Is there a way to check how much time is spent on disk I/O and how much time is spend on in-memory computation?

@rongou
Copy link
Contributor

rongou commented Jan 23, 2021

There should be some logging output when the files are written out, before tree construction starts.

@trivialfis
Copy link
Member

Closing in favor of #7354 .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants