Add getVocabSize
Change-Id: I642b39b1186752387da2b555b6e6cb20a0952be5
diff --git a/lib/IDS/DeReKoVecs/Read.pm b/lib/IDS/DeReKoVecs/Read.pm
index 4887210..cf323cc 100644
--- a/lib/IDS/DeReKoVecs/Read.pm
+++ b/lib/IDS/DeReKoVecs/Read.pm
@@ -26,7 +26,7 @@
use Mojo::JSON qw(decode_json encode_json to_json);
use Exporter qw(import);
-our @EXPORT = qw(init_net load_sprofiles getDowntimeCalendar getCollocationAssociation getClassicCollocatorsCached getSimilarProfiles getSimilarProfilesCached getBiggestMergedDifferences filter_garbage get_neighbours getWordNumber dump_vecs dump_for_numpy cos_similarity_as_json);
+our @EXPORT = qw(init_net load_sprofiles getVocabSize getDowntimeCalendar getCollocationAssociation getClassicCollocatorsCached getSimilarProfiles getSimilarProfilesCached getBiggestMergedDifferences filter_garbage get_neighbours getWordNumber dump_vecs dump_for_numpy cos_similarity_as_json);
sub getDowntimeCalendar {
my ($url) = @_;
diff --git a/lib/IDS/DeReKoVecs/derekovecs-server.c b/lib/IDS/DeReKoVecs/derekovecs-server.c
index b2cdb20..2234c66 100644
--- a/lib/IDS/DeReKoVecs/derekovecs-server.c
+++ b/lib/IDS/DeReKoVecs/derekovecs-server.c
@@ -1185,3 +1185,7 @@
fclose(f);
return (0);
}
+
+unsigned long getVocabSize() {
+ return (unsigned long) words;
+}