annotate help_html/source/messl_massef.m @ 38:c7d11a428a0d tip master

Merge branch 'develop' * develop: Updated copyright year.
author Christopher Hummersone <c.hummersone@surrey.ac.uk>
date Tue, 16 May 2017 12:15:34 +0100
parents f4d7400f5cf4
children
rev   line source
c@11 1 classdef messl_massef < MASSEFseparator
c@11 2 %MESSL_MASSEF Wrapper class for the MESSL algorithm.
c@11 3 %
c@11 4 % A wrapper class for the MESSL algorithm (https://github.com/mim/messl).
c@11 5 %
c@11 6 % MESSL_MASSEF properties:
c@11 7 % label - A label for the instance of the algorithm (shown in
c@11 8 % the results file).
c@11 9 % estTag - Tags for the estimated outputs.
c@11 10 % fs - The sampling frequency that the separator will run
c@11 11 % at.
c@11 12 %
c@11 13 % MESSL_MASSEF methods:
c@11 14 % messl_massef - Create an instance of the algorithm.
c@11 15 % separate - Run the separation algorithm on the time-domain
c@11 16 % mixture.
c@11 17 %
c@11 18 % See also MASSEF.
c@11 19
c@11 20 % Copyright 2016 University of Surrey.
c@11 21
c@11 22 properties % Public properties
c@11 23 fs % Sampling frequency
c@11 24 end
c@11 25
c@11 26 methods
c@11 27
c@11 28 function obj = messl_massef(fs) % constructor
c@11 29 %MESSL_MASSEF Create an instance of the separation algorithm
c@11 30 %
c@11 31 % OBJ = MESSL_MASSEF(FS) creates an instance of the MESSL
c@11 32 % algorithm at the sampling frequency FS.
c@11 33
c@11 34 % this code creates an instance of the object
c@11 35 obj.label = 'MESSL';
c@11 36 obj.estTag = {'Fancier usage'};
c@11 37 obj.fs = fs;
c@11 38
c@11 39 % check dependency is compiled
c@11 40 iosr.general.checkMexCompiled('logProbGmm.cpp');
c@11 41
c@11 42 end
c@11 43
c@11 44 % separation
c@11 45 function [signal,mask,est_azis,est_eles] = separate(obj,mixture)
c@11 46 %SEPARATE separate the mixture
c@11 47 %
c@11 48 % SIGNAL = OBJ.SEPARATE(MIXTURE) separates the time-domain
c@11 49 % mixture signal MIXTURE and produces the estimated output
c@11 50 % SIGNAL.
c@11 51
c@11 52 lr = mixture';
c@11 53 tau = tauGrid(0.15, obj.fs, 31);
c@11 54
c@11 55 m = messl(lr, tau, 2, 'vis', 1, 'ildPriorPrec', 3, ...
c@11 56 'GarbageSrc', 1, 'sr', 16000, 'vis', 0);
c@11 57
c@11 58 m2 = prob2mask(m);
c@11 59 signal = reconstruct(m2, lr, 1);
c@11 60
c@11 61 mask = [];
c@11 62 est_azis = [];
c@11 63 est_eles = [];
c@11 64
c@11 65 end
c@11 66
c@11 67 end
c@11 68
c@11 69 end