fix: when PGF loading forgot reading "functions per cat"

This commit is contained in:
krangelov
2021-08-05 17:13:11 +02:00
parent e298410e57
commit 7d85d3ca9a

View File

@@ -395,6 +395,14 @@ ref<PgfAbsCat> PgfReader::read_abscat()
{
ref<PgfAbsCat> abscat = read_name<PgfAbsCat>(&PgfAbsCat::name);
abscat->context = read_vector<PgfHypo>(&PgfReader::read_hypo);
// for now we just read the set of functions per category and ignore them
size_t n_funs = read_len();
for (size_t i = 0; i < n_funs; i++) {
read_double();
read_name();
}
abscat->prob = - log(read_double());
return abscat;
}