MCPcopy Create free account
hub / github.com/agentscope-ai/Trinity-RFT / log

Method log

trinity/utils/monitor.py:206–211  ·  view source on GitHub ↗

Log metrics.

(self, data: dict, step: int, commit: bool = False)

Source from the content-addressed store, hash-verified

204 mlflow.log_table(data=experiences_table, artifact_file=f"{table_name}.json")
205
206 def log(self, data: dict, step: int, commit: bool = False) -> None:
207 """Log metrics."""
208 self.console_logger.info(f"{self.format_data_str(data, step)}")
209 # Replace all '@' in keys with '_at_', as MLflow does not support '@' in metric names
210 data = {k.replace("@", "_at_"): v for k, v in data.items()}
211 mlflow.log_metrics(metrics=data, step=step)
212
213 def close(self) -> None:
214 mlflow.end_run()

Callers

nothing calls this directly

Calls 1

format_data_strMethod · 0.80

Tested by

no test coverage detected