bleNaviPy.indoorGML.geometry.floorGeometry module

This is a module for floor geometry for indoorGML

class bleNaviPy.indoorGML.geometry.floorGeometry.FloorGeometry(cells: List[bleNaviPy.indoorGML.geometry.cellGeometry.CellGeometry], transitions: List[bleNaviPy.indoorGML.geometry.transitionGeometry.TransitionGeometry], beacons: Optional[List[bleNaviPy.beacon.beacon.Beacon]] = None)

Bases: object

Class Floor Contains information about cells, transitions on a floor

addBeacon(beacon: bleNaviPy.beacon.beacon.Beacon) → None

Add a beacon to a floor

Parameters

beacon (Beacon) – Beacon to add

addUser(user: bleNaviPy.beacon.user.User) → None

Add user to a floor

Parameters

user (User) – User to add

getCellByLocation(location: bleNaviPy.indoorGML.geometry.pointGeometry.Point) → bleNaviPy.indoorGML.geometry.cellGeometry.CellGeometry

Get a cell by given location

Parameters

location (Point)

Returns

found cell

Return type

CellGeometry

getDict() → dict

Get dictionary form of floor ready for a saving

Returns

Save ready dict form of floor

Return type

dict

getPropertiesDict() → dict

Get properties part of floor geometry dictionary

Returns

properties part of floor geometry dictionary

Return type

dict

getUserLocation(user_id: int = 0, get_on_transition: bool = False) → bleNaviPy.indoorGML.geometry.pointGeometry.Point

Get user location based on beacons :returns: User location :rtype: Location

setNoise(noise: bool = True) → None

Set if floor should add noise to a simulation

Parameters

noise (bool, optional) – Should floor add noise when checking RSSI for beacons. Defaults to True.

setScale(scale: float) → None

Set scale according to a json file (to match a json units to meters)

Parameters

scale (float) – Scale factor

setWallDetection(wall_detection: bool = True) → None

Set if floor should detect walls

Parameters

wall_detection (bool, optional) – Should floor detect walls when checking RSSI for beacons. Defaults to True.