def initialize_from_gaussian_lds(self, N_samples=100):
        from pylds.models import DefaultLDS
        init_model = DefaultLDS(n=self.n, p=self.K)

        for data in self.data_list:
            init_model.add_data(data["x"])

        print("Initializing with Gaussian LDS")
        for smpl in xrange(20):
            init_model.resample_model()

        # Use the init model's parameters
        self.A = init_model.A.copy()
        self.C = init_model.C[:self.K-1,:].copy()
        self.sigma_states = init_model.sigma_states.copy()
        self.mu_init = init_model.mu_init.copy()
        self.sigma_init = init_model.sigma_init.copy()

        # Use the init model's latent state sequences too
        for data, init_data in zip(self.data_list, init_model.states_list):
            data["z"] = init_data.stateseq.copy()

        # Now resample omega
        self.emission_distn.resample_omega(self.data_list)
Initialize z, A, C, sigma_states using a Gaussian LDS
dataset/ETHPy150Open HIPS/pgmult/pgmult/lds.py/_MultinomialLDSGibbsSampling.initialize_from_gaussian_lds