Created
August 25, 2019 07:36
-
-
Save nivleshc/25e5e34917e5972b4ba0fdaee0eef51f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#most of the times, lambda functions get re-used by AWS for consequetive runs. To ensure the global variables are sanitised and do not | |
#cause issues because they contain values from last run, we will initialise them | |
def initialise_global_variables(): | |
global lastpushpinLabel | |
global dict_pushpinLabel_to_desc_map | |
global dict_vehicleId_to_pushpinLabel_map | |
global pushpin_url | |
global total_vehicles_found | |
#initialise the values for the above global variables | |
print("Initialising global variables") | |
lastpushpinLabel = 0 | |
dict_pushpinLabel_to_desc_map = {} | |
dict_vehicleId_to_pushpinLabel_map = {} | |
pushpin_url = "" | |
total_vehicles_found = 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment