### Navigation

- index
- modules |
- modules |
- next |
- previous |
- SciPy v0.9 Reference Guide (DRAFT) »
- Maximum entropy models (`scipy.maxentropy`) »

# scipy.maxentropy.basemodel.setcallback

`basemodel.``setcallback`(callback=None, callback_dual=None, callback_grad=None)

  Sets callback functions to be called every iteration, every function evaluation, or every gradient evaluation. All callback functions are passed one argument, the current model object.

  Note that line search algorithms in e.g. CG make potentially several function and gradient evaluations per iteration, some of which we expect to be poor.

### Navigation

- index
- modules |
- modules |
- next |
- previous |
- SciPy v0.9 Reference Guide (DRAFT) »
- Maximum entropy models (`scipy.maxentropy`) »