forum.alglib.net

ALGLIB forum
It is currently Wed Feb 05, 2025 4:55 am

All times are UTC


Forum rules


1. This forum can be used for discussion of both ALGLIB-related and general numerical analysis questions
2. This forum is English-only - postings in other languages will be removed.



Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: ap_error
PostPosted: Tue Jan 14, 2025 12:00 pm 
Offline

Joined: Tue Jan 14, 2025 11:56 am
Posts: 2
I am training a random forest with 10 features and 1 continuous target variable. When I train the random forest with 10 trees, everything works successfully. When I increase the number of trees to 50 or 100, I get ap_error.

my code is:

ae_int_t ntrees = 50;
ae_int_t mtry = 6;
fraction = 0.5;
decisionforestbuilder builder;
ae_int_t nvars = 10;
ae_int_t nclasses = 1;
ae_int_t npoints = train_size;

dfbuildercreate(builder);
dfbuildersetdataset(builder, train_data, npoints, nvars, nclasses);
dfbuildersetrndvars(builder,mtry);
dfbuildersetseed(builder, 1);
dfbuildersetsubsampleratio(builder, fraction);
dfreport rep;
dfbuilderbuildrandomforest(builder, ntrees, model, rep);

What can this error be?


Top
 Profile  
 
 Post subject: Re: ap_error
PostPosted: Tue Jan 14, 2025 12:05 pm 
Offline

Joined: Tue Jan 14, 2025 11:56 am
Posts: 2
Using a try and catch block, I got:


error msg: ae_malloc(): out of memory

What should I do?


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 10 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group