merge Sasha/Peter and my changes, reorganize files