Giter VIP home page Giter VIP logo

Comments (4)

dfm avatar dfm commented on June 3, 2024 1

You must be fitting a white noise component in the GPyTorch model! In celerite, you should include a JitterTerm.

Even so, it's not obvious to me that a stationary GP is a good choice for your particular data set.

from celerite.

dfm avatar dfm commented on June 3, 2024

(I should mention that I know this because without a white noise term, the model will exactly go through every data point by construction...)

from celerite.

HkmMerwan avatar HkmMerwan commented on June 3, 2024

Ok thank you for the quick answer it does give a similar result now !

Yes I was trying to compare GPyTorch and celerite on random data with a random kernel. Now I have data for my work on which I am trying to do a Gaussian regression using celerite and might want some help. These data come from different orders of a spectrograph on which I was forgetting to add a jitter and was getting this result :

image
Final log-likelihood: -34152.13490724329
OrderedDict([('kernel:log_sigma', 7.880630186965559), ('kernel:log_rho', -3.6806385290403085), ('mean:alpha', -15196058.545724938), ('mean:beta', 20969.494149527465), ('mean:gamma', -7.232764975132396)])

And once I add the jitter I still get :

image
Final log-likelihood: -34136.52418631356
OrderedDict([('kernel:terms[0]:log_sigma', 7.932584498094634), ('kernel:terms[0]:log_rho', -3.6436370800533444), ('kernel:terms[1]:log_sigma', -2.758714124608422), ('mean:alpha', -15196058.545724858), ('mean:beta', 20969.494266574093), ('mean:gamma', -7.232530879898518)])

I am fitting a second orderl polynomial model


class MeanModel(Model):
    parameter_names = ("alpha", "beta", "gamma")

    def get_value(self, t):
        return self.alpha + self.beta * t + self.gamma * t * t


    def compute_gradient(self, t):
        dalpha = np.ones(len(t))
        dbeta = t
        dgamma = t*t
        return np.array([dalpha, dbeta, dgamma])

and a simple Matern32 kernel

    rho = .03
    sigma = np.var(y)
    kernel = terms.Matern32Term(log_sigma = np.log(sigma),log_rho = np.log(rho))
    #kernel += terms.JitterTerm(log_sigma = np.log(sigma))

This is the spectrum of a Fabry-Pérot and I wish it could retrieve the sharp lines of the spectrum as in this paper [https://arxiv.org/abs/1912.09563]

Following this paper, it would be normal to have an obvious noise fitting for a Matern32 kernel but would not happen using a Matern52 kernel. So here is my next question, is there an existing robust way to implement a Matern52 kernel ? I was thinking to use

image

for small ε but I figured I might as well ask how you do it :)

Thank you !

from celerite.

dfm avatar dfm commented on June 3, 2024

I'm happy to chat about this via email after the holidays. Send me an email (should be easy enough to find!) and I'll get back to you in the new year.

from celerite.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.