Learnable latent embeddings for joint behavioral and neural analysis