1. A computer-implemented method to generate a video, the method comprising: grouping media items associated with a user into segments based on a timestamp associated with each media item and a total number of media items; selecting target media from the media items for each of the segments based on media attributes associated with the media item, wherein the target media includes two or more media items; generating the video that includes the target media for each of the segments by: generating a first animation that illustrates a first transition from a first item from the target media to a second item from the target media with movement of the first item from an onscreen location to an offscreen location, wherein the first item is adjacent to the second item in the first animation; determining whether the target media includes one or more additional items; and responsive to determining that the target media includes one or more additional items, generating a second animation that illustrates a second transition from the second item to a first additional item and that further illustrates additional transitions between a remainder of the one or more additional items; and adding a song to the video, wherein one or more features of the song are synchronized with the first transition and the second transition.