On Sat, Mar 26, 2016 at 1:42 PM, Paulo van Breugel <[email protected]> wrote:
> *2nd try - input random sample of 100 points, 1 (12) and 0 (88), with b > flag* > r.randomforest -b igroup=predictors@SampleSize roi=test2 > output=test2_output ntrees=500 mfeatures=-1 minsplit=2 randst=1 lines=100 > Group <predictors> references the following raster maps: > Traceback (most recent call last): > File "/home/paulo/.grass7/addons/scripts/r.randomforest", > line 335, in <module> > main() > File "/home/paulo/.grass7/addons/scripts/r.randomforest", > line 243, in main > class_weight = "balanced", max_features = mfeatures, > min_samples_split = minsplit, random_state = randst) > TypeError: __init__() got an unexpected keyword argument > 'class_weight' > Removing raster <tmp_jNyNcqZa> Of course, another great addition to the module code is a test suite [1]. The basic test can be on small random data and it may not event test the correctness of result. It is enough when it just tests that the modules does not fail and gives some results. [1] https://grass.osgeo.org/grass71/manuals/libpython/gunittest_testing.html
_______________________________________________ grass-dev mailing list [email protected] http://lists.osgeo.org/mailman/listinfo/grass-dev
