bidic / jahmm

Automatically exported from code.google.com/p/jahmm
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

Funny charc in mean values #15

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Sometimes i get funny characters in the model:

digraph G {
    0 -> 0 [label=0.5];
    0 -> 6 [label=0.5];
    1 -> 6 [label=1];
    2 -> 1 [label=0.1];
    2 -> 2 [label=0.3];
    2 -> 4 [label=0.1];
    2 -> 6 [label=0.3];
    2 -> 8 [label=0.1];
    2 -> 9 [label=0.1];
    3 -> 2 [label=1];
    4 -> 2 [label=0.09];
    4 -> 4 [label=0.27];
    4 -> 6 [label=0.09];
    4 -> 7 [label=0.45];
    4 -> 12 [label=0.09];
    5 -> 5 [label=0.43];
    5 -> 6 [label=0.57];
    6 -> 0 [label=0.11];
    6 -> 2 [label=0.11];
    6 -> 3 [label=0.06];
    6 -> 4 [label=0.11];
    6 -> 5 [label=0.11];
    6 -> 6 [label=0.39];
    6 -> 7 [label=0.06];
    6 -> 11 [label=0.06];
    7 -> 4 [label=0.12];
    7 -> 6 [label=0.06];
    7 -> 7 [label=0.41];
    7 -> 8 [label=0.18];
    7 -> 9 [label=0.06];
    7 -> 12 [label=0.18];
    8 -> 2 [label=0.12];
    8 -> 5 [label=0.25];
    8 -> 7 [label=0.12];
    8 -> 8 [label=0.12];
    8 -> 9 [label=0.12];
    8 -> 12 [label=0.25];
    9 -> 7 [label=0.25];
    9 -> 9 [label=0.25];
    9 -> 10 [label=0.5];
    10 -> 10 [label=1];
    11 -> 1 [label=1];
    12 -> 4 [label=0.15];
    12 -> 7 [label=0.08];
    12 -> 8 [label=0.23];
    12 -> 10 [label=0.08];
    12 -> 12 [label=0.46];
    0 [shape=circle, label="0 - [ Multi-variate Gaussian distribution --- Mean: [ � � � � � � � � � ] ]"];
    1 [shape=circle, label="1 - [ Multi-variate Gaussian distribution --- Mean: [ � � � � � � � � � ] ]"];
    2 [shape=circle, label="2 - [ Multi-variate Gaussian distribution --- Mean: [ � � � � � � � � � ] ]"];
    3 [shape=circle, label="3 - [ Multi-variate Gaussian distribution --- Mean: [ � � � � � � � � � ] ]"];
    4 [shape=circle, label="4 - [ Multi-variate Gaussian distribution --- Mean: [ � � � � � � � � � ] ]"];
    5 [shape=circle, label="5 - [ Multi-variate Gaussian distribution --- Mean: [ � � � � � � � � � ] ]"];
    6 [shape=circle, label="6 - [ Multi-variate Gaussian distribution --- Mean: [ � � � � � � � � � ] ]"];
    7 [shape=circle, label="7 - [ Multi-variate Gaussian distribution --- Mean: [ � � � � � � � � � ] ]"];
    8 [shape=circle, label="8 - [ Multi-variate Gaussian distribution --- Mean: [ � � � � � � � � � ] ]"];
    9 [shape=circle, label="9 - [ Multi-variate Gaussian distribution --- Mean: [ � � � � � � � � � ] ]"];
    10 [shape=circle, label="10 - [ Multi-variate Gaussian distribution --- Mean: [ � � � � � � � � � ] ]"];
    11 [shape=circle, label="11 - [ Multi-variate Gaussian distribution --- Mean: [ � � � � � � � � � ] ]"];
    12 [shape=circle, label="12 - [ Multi-variate Gaussian distribution --- Mean: [ � � � � � � � � � ] ]"];
}

what could be the reason. please help.

thanks
asutosh

Original issue reported on code.google.com by asutosh....@gmail.com on 5 Oct 2010 at 5:45

GoogleCodeExporter commented 9 years ago
Hey Ashutosh,

Could you find the reason for this. I too have same problem.

Original comment by mahaveer...@gmail.com on 4 Feb 2011 at 12:53

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
before saving the hmm,simply check if the mean is NaN

 OpdfMultiGaussian obsvec = (OpdfMultiGaussian) trainedHmm.getOpdf(0);
 double mean[] = obsvec.mean();

 if (Double.isNaN(mean[0])) {
                System.out.println( " Terminating training: mean is NaN");
  }

--
hope it works for you.

asutosh

Original comment by asutosh....@gmail.com on 22 Apr 2011 at 5:14