GRU4Rec Third Party Implementations#

The original GRU4Rec [2,3] algorithm was implemented in Theano. Since then, support for Theano has been discontinued, and newer frameworks like PyTorch or TensorFlow have arisen. Convenience and/or standardization alongside with other factors (e.g. the popularity of the algorithm) has led to the creation of several third party implementations. Our experiments compare the original implementation with third party reimplementations (created in either PyTorch or TensorFlow), on multiple datasets [Yoochoose/RSC15, Rees46, Coveo, RetailRocket, Diginetica]. We found that third party (unofficial) reimplementations lack many of the distinguishing features of GRU4Rec and contain serious implementation flaws and thus their performance - both in terms of recommendation accuracy and training times - is suboptimal [1].

To support research in the field of sequential recommenders, we released an official PyTorch and TensorFlow implementation of GRU4Rec available on GitHub. These implementations are bechmarked against the original Theano implementation to ensure correctness, but runtimes still differ due to the differences in frameworks. For further information, please visit the GitHub repositories and refer to the README files.

[1] Balázs Hidasi, Ádám Czapp: The Effect of Third Party Implementations on Reproducibility, RecSys 2023

[2] Balázs Hidasi, Alexandros Karatzoglou, Linas Baltrunas, Domonkos Tikk: Session-based Recommendations with Recurrent Neural Networks, ICLR 2016

[3] Balázs Hidasi, Alexandros Karatzoglou: Recurrent Neural Networks with Top-k Gains for Session-based Recommendations, CIKM 2018