Vectorization of get_p_conn and get_input complete, ready to tune w_ee and scale_latency