Skip to content

Instantly share code, notes, and snippets.

import os
_proc_status = '/proc/%d/status' % os.getpid()
_scale = {'kB': 1024.0, 'mB': 1024.0*1024.0,
'KB': 1024.0, 'MB': 1024.0*1024.0}
def _VmB(VmKey):
'''Private.
'''
global _proc_status, _scale
import os
import networkx as nx
import memory # include memory.py
import random
import math
def get_filename(i):
return 'foo/foo' + str(i) + '.gml'
if not os.path.exists('foo'):