Skip to content
Snippets Groups Projects
Commit 28fe75fa authored by LILI JIN's avatar LILI JIN
Browse files

tf et bm25

parents b10c87ab ae33d959
No related branches found
No related tags found
1 merge request!19Mehdi lili index inverse
......@@ -19,6 +19,7 @@ lipn-search:
- pytest test_bm25.py
- cd ../../
- echo "Fin des tests sur l'index inversé"
<<<<<<< HEAD
......@@ -26,3 +27,11 @@ lipn-search:
=======
- echo "Début des tests sur le pagerank"
- cd pagerank/test/
- echo "Faire des trucs"
- cd ../../
- echo "Début des tests sur le pagerank"
- echo "Fin de la phase de test"
>>>>>>> master
......@@ -46,8 +46,14 @@ class IndexInverse :
a=a+1
self.invert_index.setdefault(word,[]).append(doc_id)
IndexInverse.vocaCount=len(self.vocabulary)
<<<<<<< HEAD
=======
print(IndexInverse.vocaCount)
>>>>>>> master
def get_index(self):
'''Obtenir le dictionnaire invert_index.
......
......@@ -11,6 +11,17 @@ dot -Tpdf graphe_3.dot -o graphe_3.pdf
#define NB_SOMMETS 7
void test_creation(){
//Test création
graphe g;
creer_graphe(&g, NB_SOMMETS);
assert(g.max > 0);
assert(g.premierVide == 0);
assert(g.ligne);
assert(g.col);
}
int main()
{
graphe g;
......@@ -22,13 +33,7 @@ int main()
char* fichier3 = "graphe_3.dot";
assert(fichier3);
//Test création
creer_graphe(&g, NB_SOMMETS);
assert(g.max > 0);
assert(g.premierVide == 0);
assert(g.ligne);
assert(g.col);
test_creation();
//Test insertion
graphe_ajouter_arete(&g, 0, 1);
......
......@@ -22,7 +22,7 @@ int main()
liste_add(&l, pasGoogle);
assert(!strcmp(l.urls[1], pasGoogle));
liste_add(&l, fichierNico);
assert(!strcmp(l.urls[2], fichierNico));
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment