mirror of
https://github.com/SheffieldML/GPy.git
synced 2026-04-24 20:36:23 +02:00
fixed a weird regular expression bug in ensure_def_constraints
This commit is contained in:
parent
d402047ff3
commit
2205c333b2
1 changed files with 2 additions and 1 deletions
|
|
@ -13,6 +13,7 @@ import priors
|
|||
from ..util.linalg import jitchol
|
||||
from ..inference import optimization
|
||||
from .. import likelihoods
|
||||
import re
|
||||
|
||||
class model(parameterised):
|
||||
def __init__(self):
|
||||
|
|
@ -239,7 +240,7 @@ class model(parameterised):
|
|||
for s in positive_strings:
|
||||
for i in self.grep_param_names(s):
|
||||
if not (i in currently_constrained):
|
||||
to_make_positive.append(param_names[i])
|
||||
to_make_positive.append(re.escape(param_names[i]))
|
||||
if warn:
|
||||
print "Warning! constraining %s postive"%name
|
||||
if len(to_make_positive):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue