ex-6: fix EMD typo
This commit is contained in:
parent
bdc12117a7
commit
e17f493cd5
@ -10,7 +10,7 @@ a, b, f = loadtxt(sys.stdin, unpack=True)
|
||||
|
||||
subplot(131)
|
||||
title('FFT')
|
||||
xlabel('EDM')
|
||||
xlabel('EMD')
|
||||
ylabel('counts')
|
||||
hist(a[:n], insert(b[:n], 0, a[0]), weights=f[:n],
|
||||
histtype='stepfilled', color='#e3c5ca', edgecolor='#92182b')
|
||||
@ -18,7 +18,7 @@ ticklabel_format(style='sci', axis='x', scilimits=(0, 0), useMathText=True)
|
||||
|
||||
subplot(132)
|
||||
title('RL')
|
||||
xlabel('EDM')
|
||||
xlabel('EMD')
|
||||
ylabel('counts')
|
||||
hist(a[n:2*n], insert(b[n:2*n], 0, a[n]), weights=f[n:2*n],
|
||||
histtype='stepfilled', color='#e3c5ca', edgecolor='#92182b')
|
||||
@ -26,7 +26,7 @@ ticklabel_format(style='sci', axis='x', scilimits=(0, 0), useMathText=True)
|
||||
|
||||
subplot(133)
|
||||
title('convolution')
|
||||
xlabel('EDM')
|
||||
xlabel('EMD')
|
||||
ylabel('counts')
|
||||
hist(a[2*n:], insert(b[2*n:], 0, a[2*n]), weights=f[2*n:],
|
||||
histtype='stepfilled', color='#e3c5ca', edgecolor='#92182b')
|
||||
|
@ -95,10 +95,16 @@ double *experiment(
|
||||
* histogram and store add each one to the respective
|
||||
* distance histogram.
|
||||
*/
|
||||
<<<<<<< HEAD
|
||||
static double dist[3];
|
||||
dist[0] = emd_between(hist, fft_clean);
|
||||
dist[1] = emd_between(hist, rl_clean);
|
||||
dist[2] = emd_between(hist, conv);
|
||||
=======
|
||||
pair_t dist;
|
||||
dist.a = emd_between(hist, fft_clean);
|
||||
dist.b = emd_between(hist, rl_clean);
|
||||
>>>>>>> ex-6: fix EMD typo
|
||||
|
||||
// free memory
|
||||
gsl_histogram_free(hist);
|
||||
@ -170,7 +176,7 @@ int main(int argc, char **argv) {
|
||||
double conv_skew = gsl_stats_skew_m_sd(conv_dist, 1, opts.num_exps, conv_mean, conv_stdev);
|
||||
double conv_min, conv_max; gsl_stats_minmax(&conv_min, &conv_max, conv_dist, 1, opts.num_exps);
|
||||
|
||||
/* Create EDM distance histograms.
|
||||
/* Create EMD distance histograms.
|
||||
* Since the distance depends wildly on the noise we can't
|
||||
* set a fixed range and therefore use the above values.
|
||||
*/
|
||||
|
Loading…
Reference in New Issue
Block a user