Support loading old models in ML module

- added test for loading legacy files
- added version to new written models
- fixed loading of several fields in some models
- added generation of new fields from old data
This commit is contained in:
Maksim Shabunin
2014-12-16 18:15:50 +03:00
parent 1c8493fb0d
commit d004ee58c5
9 changed files with 211 additions and 13 deletions

View File

@@ -115,6 +115,7 @@ void StatModel::save(const String& filename) const
{
FileStorage fs(filename, FileStorage::WRITE);
fs << getDefaultModelName() << "{";
fs << "format" << (int)3;
write(fs);
fs << "}";
}