Skip to content

Commit

Permalink
Merge pull request #37 from ispras/add_model_test_combo
Browse files Browse the repository at this point in the history
Add test combo model with different activations on SG
  • Loading branch information
LukyanovKirillML authored Nov 27, 2024
2 parents a0a0803 + c2d98a2 commit 1426490
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions tests/models_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,26 @@ def test_combo_model_on_single_graph(self):
sg_example_model_path = gnn_model_manager_sg_example.model_path_info() / 'model'
gnn_model_manager_sg_example.load_model_executor(path=sg_example_model_path)

def test_combo_model_differ_acts_on_single_graph(self):
gat_gcn_sage_gcn_gcn = model_configs_zoo(dataset=self.gen_dataset_sg_example, model_name="gat_gcn_sage_gcn_gcn")

gnn_model_manager_sg_example = FrameworkGNNModelManager(
gnn=gat_gcn_sage_gcn_gcn,
dataset_path=self.results_dataset_path_sg_example,
modification=self.default_config,
manager_config=self.manager_config,
)

gnn_model_manager_sg_example.train_model(gen_dataset=self.gen_dataset_sg_example, steps=50,
save_model_flag=True,
metrics=[Metric("F1", mask='test')])
metric_loc = gnn_model_manager_sg_example.evaluate_model(
gen_dataset=self.gen_dataset_sg_example, metrics=[Metric("F1", mask='test', )])
print(metric_loc)

sg_example_model_path = gnn_model_manager_sg_example.model_path_info() / 'model'
gnn_model_manager_sg_example.load_model_executor(path=sg_example_model_path)

def test_model_on_multiple_graph(self):
gin3_lin2_mg_small = model_configs_zoo(dataset=self.gen_dataset_mg_small,
model_name='gin_gin_gin_lin_lin')
Expand Down

0 comments on commit 1426490

Please sign in to comment.