{"action":"created","issue":{"url":"https://api.github.com/repos/Microsoft/LightGBM/issues/110","repository_url":"https://api.github.com/repos/Microsoft/LightGBM","labels_url":"https://api.github.com/repos/Microsoft/LightGBM/issues/110/labels{/name}","comments_url":"https://api.github.com/repos/Microsoft/LightGBM/issues/110/comments","events_url":"https://api.github.com/repos/Microsoft/LightGBM/issues/110/events","html_url":"https://github.com/Microsoft/LightGBM/issues/110","id":193465001,"number":110,"title":"Python - metric and nthread","user":{"login":"gugatr0n1c","id":17110787,"avatar_url":"https://avatars.githubusercontent.com/u/17110787?v=3","gravatar_id":"","url":"https://api.github.com/users/gugatr0n1c","html_url":"https://github.com/gugatr0n1c","followers_url":"https://api.github.com/users/gugatr0n1c/followers","following_url":"https://api.github.com/users/gugatr0n1c/following{/other_user}","gists_url":"https://api.github.com/users/gugatr0n1c/gists{/gist_id}","starred_url":"https://api.github.com/users/gugatr0n1c/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gugatr0n1c/subscriptions","organizations_url":"https://api.github.com/users/gugatr0n1c/orgs","repos_url":"https://api.github.com/users/gugatr0n1c/repos","events_url":"https://api.github.com/users/gugatr0n1c/events{/privacy}","received_events_url":"https://api.github.com/users/gugatr0n1c/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":18,"created_at":"2016-12-05T10:48:49Z","updated_at":"2017-01-20T15:18:34Z","closed_at":"2016-12-06T08:15:15Z","body":"Hi,\r\n\r\n1] it seems to me that nthread is not working in Python interface - no matter what I set all threads are used.\r\n\r\n2] If I have 4cpu with multithreading = 8 threads, this still call all 8 - default setting is -1, so it should call 4 or not?\r\n\r\n3] is there way to set metric from default l2 to l1 in python? set metric = 'l1' is not working\r\n\r\nthx\r\n\r\ncalling this:\r\n\r\nmodel = lg.LGBMRegressor(\r\n                            objective = 'regression',\r\n                            #metric = 'l2', - commented\r\n                            n_estimators = 25000,\r\n                            learning_rate = 0.0025,\r\n                            num_leaves = 1000,\r\n                            max_depth = 15,\r\n                            min_child_samples = 500,\r\n                            colsample_bytree = 0.2,\r\n                            subsample = 0.83,\r\n                            subsample_freq = 1,\r\n                            nthread = 1,\r\n                            silent = True\r\n                        ).fit(matrix_train, target_train, [(matrix_test, target_test)])"},"comment":{"url":"https://api.github.com/repos/Microsoft/LightGBM/issues/comments/274096852","html_url":"https://github.com/Microsoft/LightGBM/issues/110#issuecomment-274096852","issue_url":"https://api.github.com/repos/Microsoft/LightGBM/issues/110","id":274096852,"user":{"login":"supdizh","id":3666690,"avatar_url":"https://avatars.githubusercontent.com/u/3666690?v=3","gravatar_id":"","url":"https://api.github.com/users/supdizh","html_url":"https://github.com/supdizh","followers_url":"https://api.github.com/users/supdizh/followers","following_url":"https://api.github.com/users/supdizh/following{/other_user}","gists_url":"https://api.github.com/users/supdizh/gists{/gist_id}","starred_url":"https://api.github.com/users/supdizh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/supdizh/subscriptions","organizations_url":"https://api.github.com/users/supdizh/orgs","repos_url":"https://api.github.com/users/supdizh/repos","events_url":"https://api.github.com/users/supdizh/events{/privacy}","received_events_url":"https://api.github.com/users/supdizh/received_events","type":"User","site_admin":false},"created_at":"2017-01-20T15:18:34Z","updated_at":"2017-01-20T15:18:34Z","body":"I have the same issue with 1)\r\nnthread  is not working in both python vanila and scikit API. \r\nit works in bin + train.conf, however.\r\nmy settings:\r\n    param = {                                                                                           \r\n             'task': 'train',                                                                           \r\n             'boost_type': 'gbdt',                                                                      \r\n             'objective': 'multiclass',                                                                 \r\n             'num_class': 3,                                                                            \r\n             'max_bin': 255,                                                                            \r\n             'learning_rate': 1,                                                                        \r\n             'num_leaves': 31,                                                                          \r\n             'verbose': 1,                                                                              \r\n             'nthread': 1,                                                                              \r\n             }"}}
{"actor":{"display_login":"supdizh"}}