code
stringlengths
3
6.57k
tz.localize(datetime.combine(next_day, time()
relativedelta(days=1)
_pop_head_while(predicate, list_)
len(list_)
predicate(list_[0])
res.append(list_[0])
list_.pop(0)
_other_day_url(self, date)
format_date(date, 'yyyy-MM-dd')
_process_multiday_events(self, info, event)
sorted(chain(*info[event.id].values()
attrgetter('timetable_entry.start_dt')
list(x[1])
groupby(timetable_objects, key=lambda x: x.start_dt.astimezone(tzinfo)
date()
self._get_days(max(self.start_dt, event.start_dt.astimezone(tzinfo)
min(self.end_dt, event.end_dt.astimezone(tzinfo)
_EventProxy(event, day, tzinfo, timetable_objects_by_date.get(day.date()
_EventProxy(object)
__init__(self, event, date, tzinfo, timetable_objects)
datetime.combine(date, event.start_dt.astimezone(tzinfo)
timetz()
object.__setattr__(self, '_start_dt', start_dt)
object.__setattr__(self, '_real_event', event)
object.__setattr__(self, '_event_tz_start_date', event.start_dt.astimezone(tzinfo)
date()
object.__setattr__(self, '_timetable_objects', timetable_objects)
__getattribute__(self, name)
object.__getattribute__(self, '_start_dt')
object.__getattribute__(self, '_real_event')
object.__getattribute__(self, '_timetable_objects')
dates (in the tz of the category)
proxy (calendar entry)
object.__getattribute__(self, '_event_tz_start_date')
self.start_dt.date()
getattr(event, name)
__setattr__(self, name, value)
AttributeError('This instance is read-only')
__repr__(self)
_EventProxy({}, {})
format(self.start_dt, object.__getattribute__(self, '_real_event')
RHCategoryCalendarView(RHDisplayCategoryBase)
_process(self)
request.args.get('start_dt')
tz.localize(dateutil.parser.parse(request.args['start'])
astimezone(utc)
tz.localize(dateutil.parser.parse(request.args['end'])
astimezone(utc)
filter(Event.starts_between(start, end)
Event.is_visible_in(self.category.id)
options(load_only('id', 'title', 'start_dt', 'end_dt', 'category_id')
self._get_event_data(query)
filter(Event.is_visible_in(self.category.id)
options(load_only('id', 'title', 'start_dt', 'end_dt', 'timezone')
order_by(Event.title)
all()
jsonify_data(flash=False, events=events, ongoing_event_count=len(ongoing_events)
self._render_ongoing_events(ongoing_events)
_get_event_data(self, event_query)
event.start_dt.astimezone(tz)
replace(tzinfo=None)
isoformat()
event.end_dt.astimezone(tz)
replace(tzinfo=None)
isoformat()
len(CALENDAR_COLOR_PALETTE)
event_data.update({'textColor': '#' + colors.text, 'color': '#' + colors.background})
data.append(event_data)
_render_ongoing_events(self, ongoing_events)
get_template_module('categories/display/_calendar_ongoing_events.html')
template.render_ongoing_events(ongoing_events, self.category.display_tzinfo)
RHCategoryUpcomingEvent(RHDisplayCategoryBase)
_process(self)
self._get_upcoming_event()
redirect(event.url)
flash(_('There are no upcoming events for this category')
redirect(self.category.url)
_get_upcoming_event(self)
filter(Event.is_visible_in(self.category.id)
now_utc()
options(subqueryload('acl_entries')
order_by(Event.start_dt, Event.id)
get_n_matching(query, 1, lambda event: event.can_access(session.user)
Foundation (ASF)
logging.getLogger("strategy")
naive_schedule(_, outs, target)
te.create_schedule(outs[-1].op)
wrap_topi_schedule(topi_schedule)
wrapper(attrs, outs, target)
topi_schedule(outs)
get_conv2d_in_channels(data_shape, data_layout)
get_const_tuple(data_shape)
len(data_shape)
data_layout.find("C")
format(data_layout)
re.match(r"NCHW\d*c", data_layout)
ValueError("Unknown conv2d data layout {}".format(data_layout)
get_conv2d_out_channels(kernel_shape, kernel_layout)
get_const_tuple(kernel_shape)
len(kernel_shape)