implementing sklearn
fixed problems