I agree that it is completely redundant.

On the other hand, since these classes are in the same file, I think it
introduces a chance to make a mistake: eg. trying to modify the module I
had mistakenly modified the wrong function. Obviously that is avoidable if
one is more careful and does not just grep for the function. So, not a big
deal  either way.

If you decide you want bandflux_rcov, and want me to change it, I can do
that.

Rahul

On Mon, May 12, 2014 at 8:15 PM, Kyle Barbary <notifications@github.com>wrote:

> In sncosmo/models.py:
>
> > +        # (wave will be central value of rest-frame bandpass)
> > +        # That is, we want a 1-d array, for points (phase[0], wave[0]),
> > +        # (phase[1], wave[1]), ...
> > +        lcrv00 = np.diagonal(self._model['LCRV00'](phase, cwave))
> > +        lcrv11 = np.diagonal(self._model['LCRV11'](phase, cwave))
> > +        lcrv01 = np.diagonal(self._model['LCRV01'](phase, cwave))
> > +	scale = np.diagonal(self._model['errscale'](phase, cwave))
> > +        errsnakesq = scale*scale * (lcrv00 + 2*x1*lcrv01 + x1*x1*lcrv11)
> > +
> > +
> > +        # Correct negative values to some small number
> > +	#errsnakesq[errsnakesq < 0.] = 0.01*0.01  # Can this just be zero?
> > +
> > +	return errsnakesq
> > +
> > +    #Can we change the name to restbandflux_rcov
>
> This is a method of SALT2Source, which is a class that is not
> redshift-aware. Therefore, everything in the class is in the "rest frame",
> so I think it is redundant to call it restbandflux_rcov rather than
> bandflux_rcov.
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/sncosmo/sncosmo/pull/24/files#r12562984>
> .
>