Returns `True` if short cadence data is available for this target.

    :param int EPIC: The EPIC ID number
    :param int season: The campaign number. Default :py:obj:`None`
13883
def HasShortCadence(EPIC, season=None):
    '''
    

    '''

    if season is None:
        season = Campaign(EPIC)
        if season is None:
            return None
    stars = GetK2Campaign(season)
    i = np.where([s[0] == EPIC for s in stars])[0]
    if len(i):
        return stars[i[0]][3]
    else:
        return None
1326920
public Collection<Epic> getEpics(EpicFilter filter) {
        filter = (filter != null) ? filter : new EpicFilter();

        filter.goals.clear();
        filter.goals.add(this);
        return getInstance().get().epics(filter);
    }
1068903
def setup_seasonal(self):
        

        # If we've specified a season, just run that one
        if self.ns.season:
            return self.load_season(self.ns.season)

        # If we've specified another doge or no doge at all, it does not make
        # sense to use seasons.
        if self.ns.doge_path is not None and not self.ns.no_shibe:
            return

        now = datetime.datetime.now()

        for season, data in wow.SEASONS.items():
            start, end = data['dates']
            start_dt = datetime.datetime(now.year, start[0], start[1])

            # Be sane if the holiday season spans over New Year's day.
            end_dt = datetime.datetime(
                now.year + (start[0] > end[0] and 1 or 0), end[0], end[1])

            if start_dt <= now <= end_dt:
                # Wow, much holiday!
                return self.load_season(season)
662414
def update(self, *args):
        
        g = get_root(self).globals
        expTime, deadTime, cycleTime, dutyCycle, frameRate = g.ipars.timing()

        total, peak, peakSat, peakWarn, ston, ston3 = \
            self.counts(expTime, cycleTime)

        if cycleTime < 0.01:
            self.cadence.config(text='{0:7.5f} s'.format(cycleTime))
        elif cycleTime < 0.1:
            self.cadence.config(text='{0:6.4f} s'.format(cycleTime))
        elif cycleTime < 1.:
            self.cadence.config(text='{0:5.3f} s'.format(cycleTime))
        elif cycleTime < 10.:
            self.cadence.config(text='{0:4.2f} s'.format(cycleTime))
        elif cycleTime < 100.:
            self.cadence.config(text='{0:4.1f} s'.format(cycleTime))
        elif cycleTime < 1000.:
            self.cadence.config(text='{0:4.0f} s'.format(cycleTime))
        else:
            self.cadence.config(text='{0:5.0f} s'.format(cycleTime))

        if expTime < 0.01:
            self.exposure.config(text='{0:7.5f} s'.format(expTime))
        elif expTime < 0.1:
            self.exposure.config(text='{0:6.4f} s'.format(expTime))
        elif expTime < 1.:
            self.exposure.config(text='{0:5.3f} s'.format(expTime))
        elif expTime < 10.:
            self.exposure.config(text='{0:4.2f} s'.format(expTime))
        elif expTime < 100.:
            self.exposure.config(text='{0:4.1f} s'.format(expTime))
        elif expTime < 1000.:
            self.exposure.config(text='{0:4.0f} s'.format(expTime))
        else:
            self.exposure.config(text='{0:5.0f} s'.format(expTime))

        self.duty.config(text='{0:4.1f} %'.format(dutyCycle))
        self.peak.config(text='{0:d} cts'.format(int(round(peak))))
        if peakSat:
            self.peak.config(bg=g.COL['error'])
        elif peakWarn:
            self.peak.config(bg=g.COL['warn'])
        else:
            self.peak.config(bg=g.COL['main'])

        self.total.config(text='{0:d} cts'.format(int(round(total))))
        self.ston.config(text='{0:.1f}'.format(ston))
        self.ston3.config(text='{0:.1f}'.format(ston3))
1247037
def initSeasonFactors(self, timeSeries):
        

        seasonLength = self.get_parameter("seasonLength")
        try:
            seasonValues = self.get_parameter("seasonValues")
            assert seasonLength == len(seasonValues), "Preset Season Values have to have to be of season's length"
            return seasonValues
        except KeyError:
            pass

        seasonValues = []
        completeCycles = len(timeSeries) / seasonLength
        A = {} #cache values for A_j

        for i in xrange(seasonLength):
            c_i = 0
            for j in xrange(completeCycles):
                if j not in A:
                    A[j] = self.computeA(j, timeSeries)
                c_i += timeSeries[(seasonLength * j) + i][1] / A[j] #wikipedia suggests j-1, but we worked with indices in the first place
            c_i /= completeCycles
            seasonValues.append(c_i)
        return seasonValues
605212
def tempo_account_add_account(self, data=None):
        
        url = 'rest/tempo-accounts/1/account/'
        if data is None:
            return """Please, provide data e.g.
                       {name: "12312312321",
                       key: "1231231232",
                       lead: {name: "myusername"},
                       }
                       detail info: http://developer.tempo.io/doc/accounts/api/rest/latest/#-700314780
                   """
        return self.post(url, data=data)
186541
def episode_info(self, cosmoid, season, episode, **kwargs):
        

        resource = 'season/%d/episode/%d/info' % (season, episode)

        return self._cosmoid_request(resource, cosmoid, **kwargs)
683837
def hasSubseries(self):
        
        if self.c and self.c[0] and ((self.c[0].level in ('series', 'subseries')) or
                                     (self.c[0].c and self.c[0].c[0])):
            return True
        else:
            return False
1303937
def get_season_points(self, season_key):
        

        season_points_url = self.api_path + "season/" + season_key + "/points/"
        response = self.get_response(season_points_url)
        return response
887983
private static Episode parseEpisode(Element eEpisode, String season) {
        Episode episode = new Episode();
        EpisodeNumber en = new EpisodeNumber();

        en.setSeason(season);
        en.setEpisode(DOMHelper.getValueFromElement(eEpisode, "seasonnum"));
        en.setAbsolute(DOMHelper.getValueFromElement(eEpisode, "epnum"));
        episode.setEpisodeNumber(en);

        episode.setProductionId(DOMHelper.getValueFromElement(eEpisode, "prodnum"));
        episode.setAirDate(DOMHelper.getValueFromElement(eEpisode, AIRDATE));
        episode.setLink(DOMHelper.getValueFromElement(eEpisode, "link"));
        episode.setTitle(DOMHelper.getValueFromElement(eEpisode, TITLE));
        episode.setSummary(DOMHelper.getValueFromElement(eEpisode, SUMMARY));
        episode.setRating(DOMHelper.getValueFromElement(eEpisode, "rating"));
        episode.setScreenCap(DOMHelper.getValueFromElement(eEpisode, "screencap"));

        return episode;
    }
204077
def season_id(x):
    
    if len(str(x)) == 4:
        try:
            return "".join(["2", str(x)])
        except ValueError:
            raise ValueError("Enter the four digit year for the first half of the desired season")
    else:
        raise ValueError("Enter the four digit year for the first half of the desired season")
1137552
def _pillar(self, load):
        '''
        
        '''
        if any(key not in load for key in ('id', 'grains')):
            return False
#        pillar = salt.pillar.Pillar(
        log.debug('Master _pillar using ext: %s', load.get('ext'))
        pillar = salt.pillar.get_pillar(
                self.opts,
                load['grains'],
                load['id'],
                load.get('saltenv', load.get('env')),
                load.get('ext'),
                self.mminion.functions,
                pillar_override=load.get('pillar_override', {}))
        data = pillar.compile_pillar()
        if self.opts.get('minion_data_cache', False):
            self.cache.store('minions/{0}'.format(load['id']),
                             'data',
                             {'grains': load['grains'], 'pillar': data})
            if self.opts.get('minion_data_cache_events') is True:
                self.event.fire_event({'comment': 'Minion data cache refresh'}, salt.utils.event.tagify(load['id'], 'refresh', 'minion'))
        return data
58393
def is_series(data):
    
    dd = None
    if 'dask' in sys.modules:
        import dask.dataframe as dd
    return((pd is not None and isinstance(data, pd.Series)) or
          (dd is not None and isinstance(data, dd.Series)))
1036759
def batting_stats_bref(season=None):
    
    if season is None:
        season = datetime.datetime.today().strftime("%Y")
    season = str(season)
    start_dt = season + '-03-01' #opening day is always late march or early april
    end_dt = season + '-11-01' #season is definitely over by November
    return(batting_stats_range(start_dt, end_dt))
495940
def _season_overflow(season, moved_year, now):
    """"""

    if season > 4:
        while season > 4:
            if moved_year is None:
                moved_year = now.year + 1
            else:
                moved_year += 1
            season -= 5
    elif season < 0:
        while season < 0:
            if moved_year is None:
                moved_year = now.year - 1
            else:
                moved_year -= 1
            season += 5
    return season, moved_year
1204566
def __is_valid(loc_data):
    """"""
    for key, [value, func] in SENSOR_TYPES.items():
        if (key != CONDITION and key != STATIONNAME and key != MEASURED):
            if (func is not None):
                sens_data = loc_data.get(value)
                if func(sens_data) != 0:
                    return True
654878
def initialTrendSmoothingFactors(self, timeSeries):
        

        result = 0.0
        seasonLength = self.get_parameter("seasonLength")
        k = min(len(timeSeries) - seasonLength, seasonLength) #In case of only one full season, use average trend of the months that we have twice
        for i in xrange(0, k):
            result += (timeSeries[seasonLength + i][1] - timeSeries[i][1]) / seasonLength
        return result / k