def find_geo_coords(s):
coords = []<EOL>LOG.debug("<STR_LIT>", len(s))<EOL>for c in INFO_BOX_LAT_LON.findall(s):<EOL><INDENT>try:<EOL><INDENT>coord = (float(c[<NUM_LIT:1>]), float(c[<NUM_LIT:2>]))  <EOL>coords.append(coord)<EOL>LOG.debug("<STR_LIT>", coord)<EOL><DEDENT>except Exception as ex:<EOL><INDENT>LOG.warn("<STR_LIT>", c, ex)<EOL><DEDENT><DEDENT>for c in COORDS_GEN.findall(s):<EOL><INDENT>if skip_coords(c):<EOL><INDENT>LOG.debug("<STR_LIT>", c)<EOL>continue<EOL><DEDENT>m = COORDS_GROUPS.search(c)<EOL>if not m:<EOL><INDENT>LOG.warn("<STR_LIT>", c)<EOL>continue<EOL><DEDENT>try:<EOL><INDENT>g = [(s[<NUM_LIT:0>:-<NUM_LIT:1>] if s[-<NUM_LIT:1>] == '<STR_LIT:|>' else s) for s in list(m.groups()) if s is not None and len(s)]<EOL>if len(g) == <NUM_LIT:1>: <EOL><INDENT>lat, lon = g[<NUM_LIT:0>].split('<STR_LIT:|>')<EOL>coord = (float(lat), float(lon))  <EOL>coords.append(coord)<EOL>LOG.debug("<STR_LIT>", coord)<EOL><DEDENT>elif g[<NUM_LIT:3>] == '<STR_LIT:E>' or g[<NUM_LIT:3>] == '<STR_LIT>':<EOL><INDENT>lat = depipe(g[<NUM_LIT:0>]) * (<NUM_LIT:1> if g[<NUM_LIT:1>].upper() == '<STR_LIT:N>' else -<NUM_LIT:1>)<EOL>lon = depipe(g[<NUM_LIT:2>]) * (<NUM_LIT:1> if g[<NUM_LIT:3>].upper() == '<STR_LIT:E>' else -<NUM_LIT:1>)<EOL>coord = (lat, lon)  <EOL>coords.append(coord)<EOL>LOG.debug("<STR_LIT>", coord)<EOL><DEDENT>else:<EOL><INDENT>LOG.warn("<STR_LIT>", c, g)<EOL><DEDENT><DEDENT>except Exception as ex:<EOL><INDENT>LOG.warn("<STR_LIT>", c, ex)<EOL><DEDENT><DEDENT>l = []<EOL>for c in set(coords):  <EOL><INDENT>if c[<NUM_LIT:0>] > <NUM_LIT> or c[<NUM_LIT:0>] < -<NUM_LIT> or c[<NUM_LIT:1>] > <NUM_LIT> or c[<NUM_LIT:1>] < -<NUM_LIT> or (c[<NUM_LIT:0>] == <NUM_LIT:0> and c[<NUM_LIT:1>] == <NUM_LIT:0>):<EOL><INDENT>LOG.warn("<STR_LIT>", c)<EOL><DEDENT>else:<EOL><INDENT>l.append({"<STR_LIT:type>": "<STR_LIT>", "<STR_LIT>": (c[<NUM_LIT:1>], c[<NUM_LIT:0>])})  <EOL><DEDENT><DEDENT>return l<EOL>
Returns a list of lat/lons found by scanning the given text