pytorch/caffe2/python/layers
Huazhong Ning 15c6f637d6 create bucket-based calibration - layer
Summary:
The basic idea of bucket-based calibration:
1. given a model and a calibration data set
2. apply the model to the calibration data set and sort the prediction scores
3. bucketize the prediction scores
4. for the samples in each bucket, compute the proportion of positive samples
5. build a set of piecewise linear functions that map from the bucket range to the proportion
6. appends an operator of piecewise linear transform to the prediction net that is supposed to calibrate the raw predictions.
7. to support calibration in realtime training, we create a new type of Net -- bucket calibration net. This needs a new Context to add_calibration_ops(), to export and load the new Net.

This includes a series of diffs.

This diff implements a layer that adds different operators for train/cali/eval for bucket based calibration.

Reviewed By: dragonxlwang

Differential Revision: D4817119

fbshipit-source-id: 44f8fcad2a94f40f7439cc1ad47e7bae5e17397d
2017-04-11 12:30:26 -07:00
..
__init__.py fbsync. TODO: check if build files need update. 2016-11-15 00:00:46 -08:00
batch_distill_lr_loss.py doxygen python block added 2017-03-29 06:46:16 -07:00
batch_lr_loss.py fix trunk for push and small cleanup 2017-04-02 23:35:49 -07:00
batch_mse_loss.py doxygen python block added 2017-03-29 06:46:16 -07:00
batch_sigmoid_cross_entropy_loss.py doxygen python block added 2017-03-29 06:46:16 -07:00
batch_softmax_loss.py doxygen python block added 2017-03-29 06:46:16 -07:00
concat.py doxygen python block added 2017-03-29 06:46:16 -07:00
dot_product.py doxygen python block added 2017-03-29 06:46:16 -07:00
expand_dims.py doxygen python block added 2017-03-29 06:46:16 -07:00
fc_without_bias.py doxygen python block added 2017-03-29 06:46:16 -07:00
fc.py doxygen python block added 2017-03-29 06:46:16 -07:00
functional.py support multilabel in generic preprocessor 2017-03-29 15:20:54 -07:00
layers.py create bucket-based calibration - layer 2017-04-11 12:30:26 -07:00
optimizers.py Make optimization methods configurable and allow flexible optimization settings 2017-04-01 23:02:21 -07:00
sampling_train.py Add option to subtract log odd from sampled trained prediction. 2017-04-03 17:50:58 -07:00
sampling_trainable_mixin.py doxygen python block added 2017-03-29 06:46:16 -07:00
simple_operator_layers.py doxygen python block added 2017-03-29 06:46:16 -07:00
sparse_lookup.py Add option to use id_score_list_features column 2017-04-03 17:03:09 -07:00
sparse_to_dense.py Add option to use id_score_list_features column 2017-04-03 17:03:09 -07:00
split.py doxygen python block added 2017-03-29 06:46:16 -07:00
tags.py doxygen python block added 2017-03-29 06:46:16 -07:00
uniform_sampling.py uniform_sampling layer 2017-03-29 14:36:12 -07:00