'Filter the list and only keep those under the current variable scope.
If this tower doesn\'t contain its own variable scope, return the list as-is.
Args:
varlist (list[tf.Variable] or list[tf.Tensor]):'

def filter_vars_by_vs_name(self, varlist):

    if (not self.has_own_variables):
        return varlist
    if (len(self._vs_name) == 0):
        return varlist
    prefix = (self._vs_name + '/')
    return [v for v in varlist if v.op.name.startswith(prefix)]
