MCPcopy Create free account
hub / github.com/Graphify-Labs/graphify / to_float

Function to_float

graphify/callflow_html.py:123–128  ·  view source on GitHub ↗

Convert graph numeric fields that may be serialized as strings.

(value, default: float = 0.0)

Source from the content-addressed store, hash-verified

121
122
123def to_float(value, default: float = 0.0) -> float:
124 """Convert graph numeric fields that may be serialized as strings."""
125 try:
126 return float(value)
127 except (TypeError, ValueError):
128 return default
129
130
131def endpoint_id(value) -> str:

Callers 4

normalize_edgeFunction · 0.85
edge_scoreFunction · 0.85
should_include_edgeFunction · 0.85
node_importanceFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected