switchign
This commit is contained in:
parent
3686e820fe
commit
cdf0200430
|
@ -326,7 +326,7 @@ class KDEyMLauto2(KDEyML):
|
||||||
if self.target == 'likelihood':
|
if self.target == 'likelihood':
|
||||||
loss_fn = neg_loglikelihood_prev
|
loss_fn = neg_loglikelihood_prev
|
||||||
else:
|
else:
|
||||||
loss_fn = lambda prev_hat: qp.error.from_name(self.target)(prev, prev_hat)
|
loss_fn = lambda prev_hat: qp.error.from_name(self.target)(prevtrue, prev_hat)
|
||||||
|
|
||||||
pred_prev, neglikelihood = optim_minimize(loss_fn, init_prev, return_loss=True)
|
pred_prev, neglikelihood = optim_minimize(loss_fn, init_prev, return_loss=True)
|
||||||
loss_accum += neglikelihood
|
loss_accum += neglikelihood
|
||||||
|
|
|
@ -43,7 +43,7 @@ METHODS = [
|
||||||
('KDEy-AE', KDEyMLauto2(newLR(), bandwidth='auto', target='mae', search='grid'), wrap_hyper(logreg_grid)),
|
('KDEy-AE', KDEyMLauto2(newLR(), bandwidth='auto', target='mae', search='grid'), wrap_hyper(logreg_grid)),
|
||||||
('KDEy-AE+', KDEyMLauto2(newLR(), bandwidth='auto', target='mae', search='optim'), wrap_hyper(logreg_grid)),
|
('KDEy-AE+', KDEyMLauto2(newLR(), bandwidth='auto', target='mae', search='optim'), wrap_hyper(logreg_grid)),
|
||||||
('KDEy-RAE', KDEyMLauto2(newLR(), bandwidth='auto', target='mrae', search='grid'), wrap_hyper(logreg_grid)),
|
('KDEy-RAE', KDEyMLauto2(newLR(), bandwidth='auto', target='mrae', search='grid'), wrap_hyper(logreg_grid)),
|
||||||
('KDEy-RAE', KDEyMLauto2(newLR(), bandwidth='auto', target='mrae', search='optim'), wrap_hyper(logreg_grid)),
|
('KDEy-RAE+', KDEyMLauto2(newLR(), bandwidth='auto', target='mrae', search='optim'), wrap_hyper(logreg_grid)),
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
|
@ -167,4 +167,4 @@ if __name__ == '__main__':
|
||||||
for method_name, quantifier, param_grid in METHODS + TRANSDUCTIVE_METHODS:
|
for method_name, quantifier, param_grid in METHODS + TRANSDUCTIVE_METHODS:
|
||||||
run_experiment(method_name, quantifier, param_grid)
|
run_experiment(method_name, quantifier, param_grid)
|
||||||
|
|
||||||
show_results(global_result_path)
|
show_results(global_result_path)
|
||||||
|
|
Loading…
Reference in New Issue