Skip to content

Commit

Permalink
[docs] added MAP to list when eval_at is used (#1509)
Browse files Browse the repository at this point in the history
  • Loading branch information
StrikerRUS committed Jul 12, 2018
1 parent 1437ce8 commit 5d7eb23
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
4 changes: 2 additions & 2 deletions docs/Parameters.rst
Original file line number Diff line number Diff line change
Expand Up @@ -785,11 +785,11 @@ Metric Parameters

- set this to ``true`` to output metric result over training dataset

- ``eval_at`` :raw-html:`<a id="eval_at" title="Permalink to this parameter" href="#eval_at">&#x1F517;&#xFE0E;</a>`, default = ``1,2,3,4,5``, type = multi-int, aliases: ``ndcg_eval_at``, ``ndcg_at``
- ``eval_at`` :raw-html:`<a id="eval_at" title="Permalink to this parameter" href="#eval_at">&#x1F517;&#xFE0E;</a>`, default = ``1,2,3,4,5``, type = multi-int, aliases: ``ndcg_eval_at``, ``ndcg_at``, ``map_eval_at``, ``map_at``

- used only with ``ndcg`` and ``map`` metrics

- `NDCG <https://en.wikipedia.org/wiki/Discounted_cumulative_gain#Normalized_DCG>`__ evaluation positions, separated by ``,``
- `NDCG <https://en.wikipedia.org/wiki/Discounted_cumulative_gain#Normalized_DCG>`__ and `MAP <https://makarandtapaswi.wordpress.com/2012/07/02/intuition-behind-average-precision-and-map/>`__ evaluation positions, separated by ``,``

Network Parameters
------------------
Expand Down
4 changes: 2 additions & 2 deletions include/LightGBM/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -695,9 +695,9 @@ struct Config {

// type = multi-int
// default = 1,2,3,4,5
// alias = ndcg_eval_at, ndcg_at
// alias = ndcg_eval_at, ndcg_at, map_eval_at, map_at
// desc = used only with ``ndcg`` and ``map`` metrics
// desc = `NDCG <https://en.wikipedia.org/wiki/Discounted_cumulative_gain#Normalized_DCG>`__ evaluation positions, separated by ``,``
// desc = `NDCG <https://en.wikipedia.org/wiki/Discounted_cumulative_gain#Normalized_DCG>`__ and `MAP <https://makarandtapaswi.wordpress.com/2012/07/02/intuition-behind-average-precision-and-map/>`__ evaluation positions, separated by ``,``
std::vector<int> eval_at;

#pragma endregion
Expand Down
2 changes: 2 additions & 0 deletions src/io/config_auto.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,8 @@ std::unordered_map<std::string, std::string> Config::alias_table({
{"train_metric", "is_provide_training_metric"},
{"ndcg_eval_at", "eval_at"},
{"ndcg_at", "eval_at"},
{"map_eval_at", "eval_at"},
{"map_at", "eval_at"},
{"num_machine", "num_machines"},
{"local_port", "local_listen_port"},
{"port", "local_listen_port"},
Expand Down

0 comments on commit 5d7eb23

Please sign in to comment.