-
Notifications
You must be signed in to change notification settings - Fork 0
/
blahut_arimoto.h
28 lines (23 loc) · 962 Bytes
/
blahut_arimoto.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
/* Main module for the Blahut-Arimoto algorithm with multivariate continuous
* output, discrete input, and Monte Carlo integration on the outputs.
*
* WARNING: This module uses the C99 standard, esp. variable-length arrays.
*
* It also uses the Python-C API because it is part of a C extension and must
* deal with exceptions and Ctrl-C exits, but it can easily be made pure C:
* just remove the call to PyErr_CheckSignals and to PyErr_SetString.
*
*/
#ifndef BLAHUT_ARIMOTO_H
#define BLAHUT_ARIMOTO_H
// Need to include because prototypes below use this.
#include <stddef.h>
// Prototypes
double amax(size_t n, double arr[n]);
double cj_integrand_gaussout(
size_t dim, size_t nin, size_t argj, double x[dim], double means[nin][dim],
double invLs[nin][dim][dim], double p_vec[nin]);
double blahut_arimc_gaussout(size_t dim, size_t nin, double pvec[nin],
double means[nin][dim], double covmats[nin][dim][dim],
double rtol, int seed);
#endif