Ben Chuanlong Du's Blog

It is never too late to learn.

Tree-Based Models in scikit-learn

Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!

Comments

  1. If you want a simple decision tree,

DecisionTreeRegressor is prefer to DecisionTreeClassifier as DecisionTreeRegressor is more flexible.

As a matter of fact, ensemble tree-based models (no matter classifiers or regressors) are based on DecisionTreeRegressor instead of DecisionTreeClassifier .

Useful Rust Crates for Numeric Computation

Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!

num

num A collection of numeric types and traits for Rust, including bigint, complex, rational, range iterators, generic integers, and more!

num-derive

num-derive providess procedural macros to derive numeric traits in …

Tips on the Mojo Programming Language

Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!

Check installed Python packages in Mojo notebook.

%%python
import os
os.system("pip list")

References

https://playground.modular.com/

Get Location of Max Value in a Pandas Series

Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!

idxmax Return the row label of the maximum value.

argmax: Return int position of the largest value in the Series.

Manipulate Bits in Rust

Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!

bitvec

bitvec Addresses memory by bits, for packed collections and bitfields bitvec provides a foundational API for bitfields in Rust. It specializes standard-library data structures (slices, arrays, and vectors of bool …