A partial characterization by forbidden subgraphs of edge path graphs