Commit edad55d
[MRG+1] Threshold for pairs learners (#168)
* add some tests for testing that different scores work using the scoring function
* ENH: Add tests and basic threshold implementation
* Add support for LSML and more generally quadruplets
* Make CalibratedClassifierCV work (for preprocessor case) thanks to classes_
* Fix some tests and PEP8 errors
* change the sign in decision function
* Add docstring for threshold_ and classes_ in the base _PairsClassifier class
* remove quadruplets from the test with scikit learn custom scorings
* Remove argument y in quadruplets learners and lsml
* FIX fix docstrings of decision functions
* FIX the threshold by taking the opposite (to be adapted to the decision function)
* Fix tests to have no y for quadruplets' estimator fit
* Remove isin to be compatible with old numpy versions
* Fix threshold so that it has a positive value and add small test
* Fix threshold for itml
* FEAT: Add calibrate_threshold and tests
* MAINT: remove starred syntax for compatibility with older versions of python
* Remove debugging prints and make tests for ITML pass, while waiting for #175 to be solved
* FIX: from __future__ import division to pass tests for python 2.7
* Add some documentation for calibration
* DOC: fix style
* Address most comments from aurelien's reviews
* Remove classes_ attribute and test for CalibratedClassifierCV
* Rename make_args_inc_quadruplets into remove_y_quadruplets
* TST: Fix remaining threshold into min_rate
* Remove default_threshold and put calibrate_threshold instead
* Use calibrate_threshold for ITML, and remove description
* ENH: use calibrate_threshold by default and display its parameters from the fit method
* Add a small test to test automatic calibration
* Update documentation of the default threshold
* Inverse sense for threshold comparison to be more intuitive
* Address remaining review comments
* MAINT: Rename threshold_params into calibration_params
* TST: Add test for extreme cases
* MAINT: rename threshold_params into calibration_params
* MAINT: rename threshold_params into calibration_params
* FIX: Make tests work, and add the right threshold (mean between lowest accepted value and highest rejected value), and max + 1 or min - 1 for extreme points
* Go back to previous version of finding the threshold
* Extract method for validating calibration parameters
* Validate calibration params before fit
* Address #168 (comment)1 parent b28933c commit edad55d
File tree
11 files changed
+1066
-148
lines changed- doc
- metric_learn
- test
11 files changed
+1066
-148
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
148 | 148 | | |
149 | 149 | | |
150 | 150 | | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
151 | 190 | | |
152 | | - | |
| 191 | + | |
153 | 192 | | |
154 | 193 | | |
155 | 194 | | |
| |||
192 | 231 | | |
193 | 232 | | |
194 | 233 | | |
195 | | - | |
196 | | - | |
197 | | - | |
198 | | - | |
199 | | - | |
200 | | - | |
201 | | - | |
202 | | - | |
203 | | - | |
204 | | - | |
205 | | - | |
206 | | - | |
207 | | - | |
208 | | - | |
209 | | - | |
210 | | - | |
211 | | - | |
212 | | - | |
213 | | - | |
214 | | - | |
215 | | - | |
216 | | - | |
217 | | - | |
218 | | - | |
219 | | - | |
220 | | - | |
221 | | - | |
222 | | - | |
223 | | - | |
224 | | - | |
225 | | - | |
226 | | - | |
227 | | - | |
228 | 234 | | |
229 | 235 | | |
230 | 236 | | |
| |||
343 | 349 | | |
344 | 350 | | |
345 | 351 | | |
| 352 | + | |
| 353 | + | |
| 354 | + | |
| 355 | + | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
| 359 | + | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
| 369 | + | |
| 370 | + | |
| 371 | + | |
| 372 | + | |
| 373 | + | |
| 374 | + | |
| 375 | + | |
| 376 | + | |
| 377 | + | |
| 378 | + | |
| 379 | + | |
| 380 | + | |
| 381 | + | |
| 382 | + | |
| 383 | + | |
| 384 | + | |
| 385 | + | |
| 386 | + | |
| 387 | + | |
| 388 | + | |
| 389 | + | |
| 390 | + | |
| 391 | + | |
| 392 | + | |
| 393 | + | |
| 394 | + | |
0 commit comments