Report whether the bundled sensing backend is installed and running.
()
| 1643 | xi, yi = poly[i]['x'], poly[i]['y'] |
| 1644 | xj, yj = poly[j]['x'], poly[j]['y'] |
| 1645 | if ((yi > pt['y']) != (yj > pt['y'])) and \ |
| 1646 | (pt['x'] < (xj - xi) * (pt['y'] - yi) / ((yj - yi) or 1e-9) + xi): |
| 1647 | inside = not inside |
| 1648 | j = i |
| 1649 | return inside |
| 1650 | |
| 1651 | |
| 1652 | def _gf_inset(poly, frac): |
| 1653 | if not poly or len(poly) < 3 or not frac: |
| 1654 | return poly |
| 1655 | n = len(poly) |
| 1656 | cx = sum(p['x'] for p in poly) / n |
| 1657 | cy = sum(p['y'] for p in poly) / n |
| 1658 | return [{'x': p['x'] + (cx - p['x']) * frac, 'y': p['y'] + (cy - p['y']) * frac} |
| 1659 | for p in poly] |
nothing calls this directly
no test coverage detected