changed load() to load_flat() to stop confusion
pushed flat binary functions to new file