Просмотр исходного кода

chillax_extrapolator: Fixed wrong shortest_path in DepthSteps

Clemens-Alexander Brust 5 лет назад
Родитель
Сommit
731c9efa87
2 измененных файлов с 1 добавлено и 6 удалено
  1. 1 1
      chillax/chillax_extrapolator.py
  2. 0 5
      chillax/experiment_selfsupervised.py

+ 1 - 1
chillax/chillax_extrapolator.py

@@ -172,7 +172,7 @@ class DepthStepsCHILLAXExtrapolator(CHILLAXExtrapolator):
 
             root = list(nx.topological_sort(self.rgraph))[0]
             self.uid_to_depth = {
-                concept.uid: nx.shortest_path(root, concept.uid)
+                concept.uid: nx.shortest_path(self.rgraph, root, concept.uid)
                 for concept in self.knowledge_base.concepts()
             }
 

+ 0 - 5
chillax/experiment_selfsupervised.py

@@ -7,11 +7,6 @@ import config as pcfg
 import argparse
 
 
-class CheapObserver(instrumentation.Observer):
-    def update(self, message: instrumentation.Message):
-        print(f"Message: {message}")
-
-
 def main(config_files):
     # This shouldn't be necessary, but...
     helpers.setup_environment()