1. A method of modeling a data generating process, said method comprising: observing a data sequence comprising irregularly sampled data; obtaining an observation sequence based on the observed data sequence; assigning a time index sequence to said data sequence; obtaining a hidden state sequence of said data sequence; and decoding said data sequence based on a combination of said time index sequence and said hidden state sequence to model said data sequence.