Skip to content

Commit

Permalink
Try Ionnis new idea #1.
Browse files Browse the repository at this point in the history
  • Loading branch information
li-zhi committed Dec 14, 2016
1 parent f1098c5 commit 6071d5e
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 5 deletions.
13 changes: 9 additions & 4 deletions feature/src/adm_tools.c
Original file line number Diff line number Diff line change
Expand Up @@ -90,9 +90,11 @@ float adm_sum_cube_s(const float *x, int w, int h, int stride, double border_fac
}

// adding noise floor
accum += (bottom - top) * (right - left) / 32.0f;
// accum += (bottom - top) * (right - left) / 32.0f;

return powf(accum, 1.0f / 3.0f);
// return powf(accum, 1.0f / 3.0f);

return powf(accum, 1.0f / 3.0f) + powf((bottom - top) * (right - left) / 32.0f, 1.0f / 3.0f);
}

double adm_sum_cube_d(const double *x, int w, int h, int stride, double border_factor)
Expand Down Expand Up @@ -121,9 +123,12 @@ double adm_sum_cube_d(const double *x, int w, int h, int stride, double border_f
}

// adding noise floor
accum += (bottom - top) * (right - left) / 32.0;
// accum += (bottom - top) * (right - left) / 32.0;

// return pow(accum, 1.0 / 3.0);

return powf(accum, 1.0 / 3.0) + powf((bottom - top) * (right - left) / 32.0, 1.0 / 3.0);

return pow(accum, 1.0 / 3.0);
}

void adm_decouple_s(const adm_dwt_band_t_s *ref, const adm_dwt_band_t_s *dis, const adm_dwt_band_t_s *r, const adm_dwt_band_t_s *a, int w, int h, int ref_stride, int dis_stride, int r_stride, int a_stride)
Expand Down
4 changes: 3 additions & 1 deletion python/core/feature_extractor.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,9 @@ class VmafFeatureExtractor(FeatureExtractor):
# VERSION = '0.2.1' # expose vif num/den of each scale
# VERSION = '0.2.2' # adm abs-->fabs, corrected border handling, uniform reading with option of offset for input YUV, updated VIF corner case
# VERSION = '0.2.2b' # expose adm_den/num_scalex
VERSION = '0.2.3' # AVX for VMAF convolution; update adm features by folding noise floor into per coef

# VERSION = '0.2.3' # AVX for VMAF convolution; update adm features by folding noise floor into per coef
VERSION = '0.2.3a' # try ioannis new idea #1

ATOM_FEATURES = ['vif', 'adm', 'ansnr', 'motion',
'vif_num', 'vif_den', 'adm_num', 'adm_den', 'anpsnr',
Expand Down

0 comments on commit 6071d5e

Please sign in to comment.