This is one of Martin Scorsese's favorite films; as he expressly said during the 2018 edition of the Cannes Film Festival, when he personally presented and introduced a restored 4K copy of the film.
The ending sequence draws heavily from Morocco (1930).