-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Warn when SPA is reloaded #614
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
||
# Forecast functions | ||
|
||
def get_num_intervals(end, start, deltat): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
E302 expected 2 blank lines, found 1
K = get_num_intervals(start, max(history.index), deltat) | ||
|
||
# find number of deltat intervals covering dataWindowLength in history | ||
N = get_num_intervals(start - K*deltat, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
E226 missing whitespace around arithmetic operator
|
||
# find number of deltat intervals covering dataWindowLength in history | ||
N = get_num_intervals(start - K*deltat, | ||
start - K*deltat - dataWindowLength, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
E226 missing whitespace around arithmetic operator
# calculate base time for resample, minutes out of phase with midnight | ||
midnight = resample_start.replace(hour=0, minute=0, second=0) | ||
first_after_midnight = resample_start - \ | ||
int((resample_start - midnight) / deltat) * deltat |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
E127 continuation line over-indented for visual indent
base=base).mean() | ||
|
||
# extract window from resampled history | ||
return idata.loc[(idata.index>=resample_start) & |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
E225 missing whitespace around operator
trend='n', | ||
order=order) | ||
|
||
# if not provided, generate guess of model parameters, helps overcome |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
W291 trailing whitespace
# if not provided, generate guess of model parameters, helps overcome | ||
# non-stationarity | ||
if not start_params: | ||
# generate a list with one entry '0' for each AR or MA parameter |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
W291 trailing whitespace
# generate a list with one entry '0' for each AR or MA parameter | ||
# plus an entry '1' for the variance parameter | ||
start_params = [] | ||
for i in range(0, order[0]+order[2]): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
E226 missing whitespace around arithmetic operator
end=end, | ||
freq=pd.to_timedelta(deltat)) | ||
|
||
f_intervals = len(idr-1) # first time in idr is last data point |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
E226 missing whitespace around arithmetic operator
E261 at least two spaces before inline comment
# return the requested forecast times | ||
|
||
return f[fdr] | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
W391 blank line at end of file
pvlib python pull request guidelines
Thank you for your contribution to pvlib python! You may delete all of these instructions except for the list below.
You may submit a pull request with your code at any stage of completion.
The following items must be addressed before the code can be merged. Please don't hesitate to ask for help if you're unsure of how to accomplish any of the items below:
docs/sphinx/source/api.rst
for API changes.docs/sphinx/source/whatsnew
file for all changes.Brief description of the problem and proposed solution (if not already fully described in the issue linked to above):