prediction

Any simple way to get regression prediction intervals in R?

泄露秘密 提交于 2019-12-06 16:25:56
问题 I am working on a big data set having over 300K elements, and running some regression analysis trying to estimate a parameter called Rate using the predictor variable Distance. I have the regression equation. Now I want to get the confidence and prediction intervals. I can easily get the confidence intervals for the coefficients by the command: > confint(W1500.LR1, level = 0.95) 2.5 % 97.5 % (Intercept) 666.2817393 668.0216072 Distance 0.3934499 0.3946572 which gives me the upper and lower

CNTK python API: How to get predictions from the trained model?

巧了我就是萌 提交于 2019-12-06 15:46:35
I have a trained model which I am loading using CNTK.load_model() function. I was looking at the MNIST Tutorial on the CNTK git repo as reference for model evaluation code. I have created a data reader (which is a MinibatchSource object) and trying to run model.eval(mb) where mb = minibatch_source.next_minibatch(...) (Similar to this answer ) But, I'm getting the following error message Traceback (most recent call last): File "LID_test.py", line 162, in <module> test_and_evaluate() File "LID_test.py", line 159, in test_and_evaluate predictions = model.eval(mb) File "/home/t-asbahe/anaconda3

Which computer vision library & algorithm(s), for human behaviour analysis?

穿精又带淫゛_ 提交于 2019-12-06 15:13:38
问题 Objective: Detect / determine human actions, s.a. picking / lifting items to read label and keeping it back on rack (in a store), sitting-on, mounting/climbing-atom objects s.a. chair, bench, ladder etc. Environment: Store / shop, which is mostly well lit. Cameras (VGA -> 1MP), fixed (i.e. not PTZ). Constraints: Presence of known and unknown human beings. Possible rearrangement of objects (items for sale) in the store, over a period of time. Possible changes in lighting over time. For example

How to predict multiple images in Keras at a time using multiple-processing (e.g. with different CPUs)?

老子叫甜甜 提交于 2019-12-06 14:42:39
问题 I have a lot of PNG images that I want to classify, using a trained CNN model. To speed up the process, I would like to use multiple-processing with CPUs (I have 72 available, here I'm just using 4). I don't have a GPU available at the moment, but if necessary, I could get one. My workflow: read a figure with openCV adapt shape and format use mymodel.predict(img) to get the probability for each class When it comes to the prediction step, it never finishes the mymodel.predict(img) step. When I

train() in caret package returns an error about names & gsub

余生长醉 提交于 2019-12-06 13:41:11
I am using caret package to predict the improvementNoticed variable library(caret) head(trainData) improvementNoticed V1 V2 681 0 0.06451613 0.006060769 1484 0 0.77924586 0.331009145 1356 0 0.22222222 0.017538684 541 0 0.21505376 0.011102470 2214 1 0.59195217 0.064764408 1111 0 0.97979798 0.036445064 V3 V4 V5 681 0.008182531 0.05263158 0 1484 0.316603794 0.88825188 0 1356 0.016182822 0.20000000 0 541 0.012665610 0.10000000 0 2214 0.051008693 0.55000000 0 1111 0.034643632 0.93333333 0 and I run myControl = trainControl(method='cv',number=5,repeats=2,returnResamp='none') model1 = train

Predictional Logic in Programming?

泪湿孤枕 提交于 2019-12-06 12:41:32
问题 I was thinking about how in the probably distant future many people think that we wont rely on physical input (i.e. keyboard) as much because the technology that reads brain waves (which already exists to some extent) will be available. Kinda scares me....anyway, I while I was daydreaming about this, the idea came to me that: what if a programmer could implement logic in their code to accurately predict the users intentions and then carry out the intended operation with no need for human

Vector representation in multidimentional time-series prediction in Tensorflow

左心房为你撑大大i 提交于 2019-12-06 11:39:09
问题 I have a large data set (~30 million data-points with 5 features) that I have reduced using K-means down to 200,000 clusters. The data is a time-series with ~150,000 time-steps. The data on which I would like to train the model is the presence of particular clusters at each time-step. The purpose of the predictive model is generate a generalized sequence similar to generating syntactically correct sentences from a model trained on word sequences. The easiest way to think about this data is

How do I plot predictions from new data fit with gee, lme, glmer, and gamm4 in R?

三世轮回 提交于 2019-12-06 04:06:32
问题 I have fit my discrete count data using a variety of functions for comparison. I fit a GEE model using geepack , a linear mixed effect model on the log(count) using lme ( nlme ), a GLMM using glmer ( lme4 ), and a GAMM using gamm4 ( gamm4 ) in R. I am interested in comparing these models and would like to plot the expected (predicted) values for a new set of data (predictor variables). My goal is to compare the predicted effects for each model under particular conditions (x variables). Of

CSAGAN的几大重点 - 2

懵懂的女人 提交于 2019-12-06 00:08:06
1.生成器 1)MRU(SketchyGAN) 计算过程为: 与DCGAN[46]和ResNet生成架构的定性和定量比较可以在5.3节中找到。MRU块有两个输入:输入特征图x i 和图像I,输出特征图y i 。为了方便起见,我们只讨论输入和输出具有相同空间维数的情况。令[·,·]为串联,Conv(x)为x上的卷积,f(x)为激活函数。我们首先要将输入图像I中的信息合并到输入特征映射xi中。一种幼稚的方法是沿着特征深度维度将它们串联起来并执行卷积: 然而,如果块能够在接收到新图像时决定它希望保留多少信息,那就更好了。所以我们采用以下方法: m i 是输入特征图上的掩码。可以在这里堆叠多个卷积层以提高性能。然后,我们希望动态地组合来自新卷积的特征图z i 和原始输入特征图x i 的信息,因此我们使用另一个掩码: 用来将输入特征图和新的特征图连接起来,得到最后的输出: 方程7中的第二项是残差连接。由于有确定信息流的内部掩码,我们称这种结构为掩码残差单元。我们可以将多个这样的单元堆叠起来,重复输入不同的比例的相同的图像,这样网络就可以在其计算路径上动态地从输入图像中检索信息。 2)CSAM(SAGAN) 大多数基于GAN的模型(Radford et al., 2016; Salimans et al., 2016; Karras et al., 2018)使用卷积层构建图像生成。卷积

Time series prediction using support vector regression

时光怂恿深爱的人放手 提交于 2019-12-05 11:07:34
I've been trying to implement time series prediction tool using support vector regression in python language. I use SVR module from scikit-learn for non-linear Support vector regression. But I have serious problem with prediction of future events. The regression line fits the original function great (from known data) but as soon as I want to predict future steps, it returns value from the last known step. My code looks like this: import numpy as np from matplotlib import pyplot as plt from sklearn.svm import SVR X = np.arange(0,100) Y = np.sin(X) svr_rbf = SVR(kernel='rbf', C=1e5, gamma=1e5) y