10 def debug(str1, str2=""):
11 'print only if debug enabled'
16 print('Number of arguments:', len(sys.argv), 'arguments.')
18 with open(sys.argv[1]) as json_file:
19 json_data = json.load(json_file)
20 for x in json_data['vertices']:
22 nodeLabel = x.get('nodeLabel')
24 if nodeLabel == 'user':
26 elif nodeLabel == 'tag':
28 elif nodeLabel is None:
30 elif nodeLabel == 'lockNode':
37 existId = dict.get(uid)
39 dict[uid] = x.get('_id')
41 dupliacteUid[uid] = existId
45 # with open('data.txt', 'w') as outfile:
46 # json.dump(json_data, outfile)