From 9217438d903fb8694d959d9361452c296016a182 Mon Sep 17 00:00:00 2001 From: Zhenwen Dai Date: Fri, 7 Aug 2015 13:37:47 +0100 Subject: [PATCH] allow Y to be uncertain --- GPy/core/gp.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/GPy/core/gp.py b/GPy/core/gp.py index 5ca86d9e..12fb3d27 100644 --- a/GPy/core/gp.py +++ b/GPy/core/gp.py @@ -60,9 +60,11 @@ class GP(Model): self.normalizer.scale_by(Y) self.Y_normalized = ObsAr(self.normalizer.normalize(Y)) self.Y = Y - else: + elif isinstance(Y, np.ndarray): self.Y = ObsAr(Y) self.Y_normalized = self.Y + else: + self.Y = Y if Y.shape[0] != self.num_data: #There can be cases where we want inputs than outputs, for example if we have multiple latent