<s> import numpy as np <EOL> import os <EOL> import oscaar <EOL> '''<STR_LIT>''' <EOL> global exoplanetDB <EOL> def period ( planet ) : <EOL> '''<STR_LIT>''' <EOL> try : <EOL> return np . float64 ( exoplanetDB [ planet ] [ '<STR_LIT>' ] ) <EOL> except KeyError : <EOL> return - <NUM_LIT:1> <EOL> def epoch ( planet ) : <EOL> '''<STR_LIT>''' <EOL> if exoplanetDB [ planet ] [ '<STR_LIT>' ] == '<STR_LIT>' : return <NUM_LIT:0.0> <EOL> else : return np . float64 ( exoplanetDB [ planet ] [ '<STR_LIT>' ] ) <EOL> def aOverRs ( planet ) : <EOL> '''<STR_LIT>''' <EOL> try : <EOL> return float ( exoplanetDB [ planet ] [ '<STR_LIT>' ] ) <EOL> except KeyError : <EOL> return - <NUM_LIT:1> <EOL> def depth ( planet ) : <EOL> '''<STR_LIT>''' <EOL> try : <EOL> if exoplanetDB [ planet ] [ '<STR_LIT>' ] == '<STR_LIT>' : return <NUM_LIT:0.0> <EOL> else : return float ( exoplanetDB [ planet ] [ '<STR_LIT>' ] ) <EOL> except KeyError : <EOL> return - <NUM_LIT:1> <EOL> def RpOverRs ( planet ) : <EOL> '''<STR_LIT>''' <EOL> temp = depth ( planet ) <EOL> if temp == - <NUM_LIT:1> : <EOL> return - <NUM_LIT:1> <EOL> else : <EOL> return np . sqrt ( depth ( planet ) ) <EOL> def inclination ( planet ) : <EOL> try : <EOL> return float ( exoplanetDB [ planet ] [ '<STR_LIT:I>' ] ) <EOL> except KeyError : <EOL> return - <NUM_LIT:1> <EOL> def eccentricity ( planet ) : <EOL> try : <EOL> if float ( exoplanetDB [ planet ] [ '<STR_LIT>' ] ) == '<STR_LIT>' : return <NUM_LIT:0.0> <EOL> else : return float ( exoplanetDB [ planet ] [ '<STR_LIT>' ] ) <EOL> except KeyError : <EOL> return - <NUM_LIT:1> <EOL> def transiterParams ( planet ) : <EOL> '''<STR_LIT>''' <EOL> from getLatestParams import downloadAndPickle <EOL> global exoplanetDB <EOL> exoplanetDB = downloadAndPickle ( ) <EOL> return [ RpOverRs ( planet ) , aOverRs ( planet ) , period ( planet ) , inclination ( planet ) , eccentricity ( planet ) ] </s>
