PyTorch implementation of the bistable recurrent cell (BRC) and recurrently neuromodulated bistable recurrent cell (nBRC)