Finding Exoplanets with TESS
Transcript
Hello everybody and welcome to this tutorial in which we are going to be teaching you, the user, how to find an exoplanet with TESS data. Now, when a planet passes in front of its host star from a certain viewpoint, this can cause the observer to see a dip in the light from the star. So this is a light curve of this star here. And as the planet crosses in front of it, we observe this dip in brightness and this is called a transit.
And from this, we can derive all sorts of information about the planetary system. Now there are many space missions that have been specifically designed to detect planets using the transit method. one such mission is a transiting exoplanet survey satellite or, as we like to call it. TESS, you can learn all about TESS through clicking this link here, and this will take you to the guest investigator office for TESS and gives you all sorts of information about the mission and its objectives. And the telescope.
Now TESS is NASA sponsored Astrophysics Explorer Class Mission. This performing in thier all sky survey to search for planets transiting to nearby stars. The mission, observes with a unique elliptical high earth orbit that provides an unobstructed view of its field to contain, to obtain continuous light curves and provide a more stable platform for precise photometry than a lower orbit. So this is an artist's illustration of the TESS satellite
and TESS equipped with four CCD cameras that have adjacent fields of view to the use of four by one array or observing sector. And this yields a combined field of view of 26 by 24 degrees, as illustrated below. So this is a 26 by 24 degrees from the four CCD's. It's a strip that goes across the sky. Now Each hemisphere is split into these observing sectors and each sector observe about 27 days now since 2018, when the TESS mission started is observed, approximately 80% of the sky mapping both the northern and southern hemispheres and detecting thousands of planetary candidates.
Now, data from the TESS mission are publicly available from the MAST Archive, and if you click, that link will take you to the archive, as shown here. And if you scroll down and click here, it shows you how to search for objects of interest. hmm, It tells you,, and you can use this to collect and obtain data. Now, the data from TESS Mission come in various forms, and these are full framed images. These are full sector images with a cadence of about 30 minutes and the years one and two and ten minutes in years three and four, the target pixel files, which are persistent cutouts from the FFIs. And these are focused on selected targets of interest. Each stamp has a cadence of two minutes or 20 seconds. Or the light curve files and these are the time series
data produced each two minute or 22nd target pixel file objects. So again, we have full framed images, and you can click on this link and I'll give you more information about these target pixel files, and you can learn more by clicking this link here. Or light curve files These are the three main products produced by the TESS mission to learn more about the TESS its mission and its products. Please visit the GI pages that I previously shared. OK, so the learning goals of this tutorial. In this tutorial will teach you the user how to access, analyze and manipulate data from the TESS mission. And this data can also be applied to Kepler and K2, which the earlier exoplanet missions. We'll be utilizing a Python package called Lightkurve. You can learn more about light curve from this website,
and this offers a user friendly way to analyze time series data on the brightness of planets, stars and galaxies. The package is focused on supporting science with Kepler and TESS space telescopes, but can equally be used to analyze light curves obtained by backyard telescopes. This workshop assumes that you have a basic knowledge of python and astronomy and a walk you, the user, through several concepts outlined below. So how to use Lightkurve to access the various data products and create time series how to account for instrumental and noise effects within your data and how to recover a planet transit from your data.
First, we're going to talk about what we need to import to get started. So this just, however, causes of some specific packages Lightkurve, Matplotlib and Numpy. We can import all of these through this cell here. This is the Jupyter notebook that I'm using. However, you can take the code that I provide to here, put this into our own Python scripts. If you have never used Jupyter notebooks or Python or complete first time user, you can actually download.
You can actually download this as a CoLab notebook, and if you have a Google account, you can run this notebook through Google. All you need to do at the top of this notebook is just install this one line and that will download the Light Curve package for you on the server, not to your computer. And you can work through the note book as we are now. OK, so first off, we're going to start with how to use Lightkurve to access the various data products and create a time series. You can search the various TESS products using the following Lightkurve function search_tesscut().
And again, if you click on each one of these links will give you a bit more information from Lightkurve. So search_tesscut(), search_targetpixelfile() or search_lightcurve() search_lightcurve() so these will get you data from the FFIs. This will get you data from the target pixel files, and these will get you the light curve files you spoke about previously. So in this tutorial, going to be examining a nearby bright target, Pi Mansae now around which the star scientists discovered a short period planets and this has an orbital period of about 6.27 days. And you can read more about this from this paper here.
OK, so first, we want to access the data products, so let's go through each of the above functions and see what data is available. So again, we're using these functions, we're entering our objects of interest and we're running three. So take a moment to search for each one of these, and when it is finished, it will produce a table of your results in each case.
Okay so these are the FFI data for objects of interest. This table here tells you which sector TESS to observe to in what year. This, if you click on it, will give you information about what TESScut is. There's more information here. This tells you the exposure time of your observations. This is the name of your object. It also tells you that it definitely is your object because it's not farther away. And this just gives you the array index.
So we'll note the inspectors one through 13 that the cadence of the FFI data is a half hour, but in sectors 27 and above, it's ten minutes. This because there was a cadence change from the primary mission, which was years one and two. So the extended mission, which was, years three and four. So let's see if this any other data products. So these target pixel files were Light Curve files. We can do that by running the following cells. OK, so there's a whole bunch of TPF data.
Some of it are from the SPOC, which is the the Science Processing Operations Center at NASA Ames, and some of it will be from the TESS SPOC. And that gives you information about this data product here. There are also higher level science products, but we won't be talking about those in this tutorial. OK? So our object was observed as a target of interest And it has both two minute and 20 second cadence data. This means that there should be light curve files already in the archive. And so you should be able to check these out.
So let's do that. Great. So we can see there's a bunch of data for multiple sectors, for our objects of interest. OK, so let's not create a light curve using a light curve file. So for the purposes of this tutorial, we're going to stick with the SPOC data and data, which have a two minute cadence. I'm only going to return these results so we can do that by specifying not only the target name, but also the author and the exposure time.
It would take just a moment to filter out the results. OK, great. We can now see the observed in these sectors. We've definitely made sure we're asking for the SPOC data and we're asking only for the two minute data, brilliant. We have eleven search results, so let's download all these and see what the data looks like. So we can do that by using this download function here and then we can just see what this looks like. So this tells us that we've got stored in our variable Lcf here eleven light curve objects, and it gives you some information about each one. So which sector the author origin
OK, so now we want to have a look at a specific light curve in a specific sector. So we're going to look at Sector one so we can do that by specifying the first element of our array. As you can see here, this zero corresponds to sector one. So let's run that here. OK, so this produce a very nice table. This table gives the time the flux and electrons per second, the error on the flux, any correction in time, the cadence number and a lot of other information.
Now one thing I want to say here is when you look at this and you look for flux specifically, there's something called sap_flux and then there's something called pdcsap_flux. Now just want to explain what this means. So S A P corresponds to what we see here as simple aperture photometry. The S A P light curve is calculated by summoned together the brightness of pixels for within an aperture set by the TESS mission. This is often referred to as the optimal aperture. But despite its name, sometimes it can be improved upon because the S A P light curve is the sum of brightnesses in a chosen pixel range. It is still subject to artifacts of the motion, say noise and other instrumental effects.
The next level above this is what's called the PDC SAP Flux or pre search data conditioning flux, and this is the SAP flux from which long term trends have been removed using so-called co trending basis vectors. And the PDC SAP flux is therefore usually cleaner data as it has fewer systematic trends. If first time uses, this might be what you want to look at if it's available now. If you when we come to plotting this up, we can switch between what we want to plot up using the following commands. So if you want to specify PDC SAP Flux, you can put this also in this case, the default will be this flux. We don't need to specify it this way, but if we wanted to look at the SAP flux, we could do this here. So let's put up the PDCSAP and the SAP flux and see what they look like, and we can see that using the following command.
OK. This is a light curve for objects. The S&P is in black, we can see that there are some interesting trends happening here and some dips and divots, and the PDC SAP is much flatter . OK, so we do want to manipulate these light curves just to put out our transit. And later, I'm also going to be assessing how if we only have the SAP flux, how we can remove some of these trends. So for now, let's stick with the PDC SAP, and let's try and manipulate this light curve to pull out our transiting exoplanet. So there are a lot of useful functions in Lightkurve that you can apply to work with the data. These include Flatten. So again, if you click this link, it'll give you more information
and removing outliers and all sorts of fun things like binning and folding and stuff like that. Now let's, as I say, we're working with the PDCSAP Flux, which is going to plot this up again by itself. And let's now flatten this to see if we can pull out the transit. There might be some hints here. I'm not sure if you can tell, but let's flatten out to see if we can do this. OK, so the light curve now is much flatter. Unfortunately, there's a portion of the light curve that's very noisy due to some jitter it in the in the TESS spacecraft, and we can remove this simply by masking this out. So this is this area here. So let's get rid of this. We can do this by applying a mass. We're defining a mask here and then we're going to apply it to our light curve that we created earlier.
OK. I'm going to use light curve to plot these two light curves over each other to see and make sure that we fully maxed out our bad data. Great. We have. That's great. This looks much better. This is something we can work with now. So let's also try to remove any sort of outliers from my light curve, and we can do this using the function defined here we're applying that OK, things are now getting a little bit cleaner. Can we see if we can see our transit anywhere? Some of you might be able to see it, but again, let's do some more work to pull it out. So one thing we can do is for this object. We know that the Planet C, which is going around, has a period of 6.27 days so we can use a fold function to find the transit in our data, as shown below. So you might be able to see something kind of here, maybe here, even.
And so what we can do is we can put in our period, we can put in an epoch time and we can fold around that. So let's try that. OK, so there's definitely something here going on. Let's see if we can pull this out a little bit more. Maybe we need to bin our data because we have quite a high cadence and maybe if I binning it, it will make it a little bit clearer and will also reduce some of it, reduce some of the uncertainty in these points that we're seeing. So you can do that by applying the bin function.
And now you can see clearly the transit of Planet C around our object of interest. It's a butieful of transit that we've been able to out. So great. Now you found that this and the transit of your first exoplanet. Wonderful. However what if there isn't any light curve data? Well, there wasn't any light curve data from the archive available. What if we don't have the PDCSAP flux, but only the SAP flux? How can we pull out the same transit from data that hasn't been as thoroughly processed? Well, you can do this by following the steps outlined below,
so we're going look at Sector one again. We're going to look at the full frame data, which has a cadence of 30 minutes, and we're going to download this. But remember, the full frame data consists of the entire 96 by 24 sector, and we only want a small vision focused around our object of interest. So what we can do is we can say, OK, look at the full frame data from sector one, but only cut out a small region of ten by ten pixels around our object of interest.
Please. And that's what this is doing here. So this will cut out a small ten by ten pixel region around our object of interest. And now we're going to product just to make sure that it's actually there. OK. This is our object of interest. It's definitely there. But now there's no aperture that's been defined for this data that we currently have. So we're going to define it ourselves. So what we can do is we can define an aperture mask, and many decisions go into the choice of aperture mask, including blending and other effects.
But in this tutorial, we're going to define an aperture by a defining a medium flux value and only selecting pixels, a certain segment above that threshold. So in most situations, a threshold mask will be the best choice between doing custom aperture photography. It doesn't involve trial and error beyond finding the best sigma value. So you can define a threshold mask using the following code. So they're saying our threshold is ten, we're going to apply. This says that there are 18 pixels in this image that meet our threshold requirements. So we're going to plot this up and see what it looks like. OK, great. The 18 pixels, it seems like objects as well covered. Brilliant. The next thing to do is sum up the value in those pixels for every single image that we have. So we can do that by using the "to_lightcurve" function. Again, more information is provided if click on that
and applying our target mask that we previously just defined. I we want that to be here and now we're going to want to plot this up. So this is a table which has all the information time flux, remember this is a SAP flux only. And then this is the light curve that gets produced now. This looks a bit different from before. There is a lot of scattered data here. There's a lot of things going on where we can't really see any transit. So we're going to really need to filter out and remove some of the noise from this light curve. So again, we're going to apply that mask that we have previously to get rid of some of this jitter that was going on here. We can do that very similarly to before.
OK. It's a little bit better, but still there's a lot of scatter and there's maybe some trends long term trends happening here. Let's first collect the data. See, see if we can remove some of the uncertainty. OK, that helps a little bit, but there is still this long term trend, so we're going to have to figure out how to remove this. And in this example, to remove this long term trend, we're going to use one of light curves built in correct class functions. These functions are very useful for moving scattered light and other effects, and you can learn more about them in the tutorials that you can find here.
Now, specifically for this tutorial, we're going to use pixel level decorrelation to remove this long term trend that we're seeing, and the PLD method has primarily been used to remove systematic trends induced by small spacecraft. Motions during observations have been shown to be successful in improving the precision of data taken by various space telescopes from Spitzer to TESS. PLD works by identifying a set of trends in the pixels surrounding the target star and performing linear regression to create a combination of these trends effectively models the systematic noise introduced by spacecraft motion, the noise model is then subtracted from the uncorrected light curve. We can apply that to our data using the code shown below.
So this is us importing the PLD corrector. This is us applying it to our mask data. Using the target mask. that we had already, hmm specified above and we're saying the number of "pca_components" is three because we don't want to overcorrect. and we're going to apply this and see what it looks like now. A useful thing here is showing the code. You can do this diagnostic block and this will show you the original light curve, a background that gets fitted and removed and a spline that gets applied. And once those things are applied, you get the light curve, as you can see here, which is removed this long trend.
OK? Things seem to look a little bit better so lets again plot this up and see what it looks like. All right, so the black one here shows the original SAP flux that wasn't corrected and the blue one shows our corrected. S, A, P, Flux With the mask, it's been applied to remove the jitter. This looks a lot better, so let's now go through the processes that we did before when we had the light curve file object. So we're going to first flatten. OK. And then we're going to fold. We're going to use the same values from before. So we fold our light curve, Oh, OK.
We can kind of make something out here that's very similar to beforehand. It's a little noisier and a bit more difficult to see because of the longer cadence that we have from the FFI data. But there still is something going on here. So let's compare our light curves. OK, great. So in the black, we have the transit that we derived from the light curve file object data and then the blue and I can see the same transit from FFI data that has been corrected.
This is great. The FFI corrected light curve isn't as perfect as the light curve object data, and we can make further adjustments. But for the purposes of this tutorial, this is a good start. So this comes to the end of our tutorial, and we just want to point you some additional resources. We've shown you the basics of how to obtain, reduce and analyze TESS data using Lightkurve, and we've only really skimmed the surface. So if you want to learn more about Lightkurve, there is a Lightkurve tutorial page that you can find here.
There's also some TESS GI data products. Page information, which you can find here, is a set of seven tutorials that gives you a lot of information and the other notebooks that you can find provided by space telescope. Once again, I'd like to thank you for your attention. My name is Rebekah Hounsell. I am a support scientist and the TESS Guest Investigator Office. If you have any questions, please feel free to contact us tesshelp@bigbang.gsfc.nasa.gov. And thank you very much for your time. Have a good day!

Ask anything
We've read this whole study set, so questions about it get the best answers.