MCPcopy Create free account
hub / github.com/CScorza/IntelOSINT / _parse_iso6709

Function _parse_iso6709

IntelOSINT.py:20004–20017  ·  view source on GitHub ↗
(raw)

Source from the content-addressed store, hash-verified

20002 return None
20003
20004 def _parse_iso6709(raw):
20005 txt = str(raw or "").strip()
20006 if not txt:
20007 return None
20008 m = re.search(r"([+-]\d{1,3}\.\d+)([+-]\d{1,3}\.\d+)", txt)
20009 if not m:
20010 m = re.search(r"([+-]\d{1,3}\.\d+),\s*([+-]\d{1,3}\.\d+)", txt)
20011 if not m:
20012 return None
20013 lat = _parse_video_coord(m.group(1))
20014 lon = _parse_video_coord(m.group(2))
20015 if lat is None or lon is None:
20016 return None
20017 return {"latitude": lat, "longitude": lon}
20018
20019 def _collect_tags(*tag_dicts):
20020 merged = {}

Callers 1

probe_metadataFunction · 0.85

Calls 1

_parse_video_coordFunction · 0.85

Tested by

no test coverage detected