Posts

Showing posts with the label neural-network

How to build a Language model using LSTM that assigns probability of occurence for a given sentence

How to build a Language model using LSTM that assigns probability of occurence for a given sentence Currently, I am using Trigram to do this. It assigns the probability of occurrence for a given sentence. But Its limited to the only context of 2 words. But LSTM's can do more. So how to build an LSTM Model that assigns the probability of occurrence for a given sentence? This question has not received enough attention. (TensorFlow Implementation)[tensorflow.org/versions/master/tutorials/… Can some body provide keras implementation? – Shashi Tunga yesterday 1 Answer 1 I have just coded a very simple example showing how one might compute the probability of occurrence of a sentence with a LSTM model. The full code can be found here. Suppose we want to pre...

How to make the openpose use caffe without cuda supported

How to make the openpose use caffe without cuda supported I wan to try Openpose: https://github.com/CMU-Perceptual-Computing-Lab/openpose in my laptop with an AMD video card,so no cuda is possible, is that possiable?How? 4 Answers 4 Running caffe with non-NVIDIA card requires opencl branch. Integrating that branch with the caffe branch used by OpenPose might be tricky (and might be straight forward - I haven't tried it myself). If you want to "play it safe", you can disable ALL GPU support by setting OpenPose CPU_ONLY := 1 In your Makefile.config before compiling caffe. This way you'll have a CPU version that does not require any CUDA/NVIDIA support. Makefile.config I would add to Shai's answer that you need to disable # USE_CUDNN := 1 sometime when its left on,the setup function of layers do some CUDA ASSERT checking that fails and prevent the program to continue There is...

Which part of the code is wrong for artificial neural network in R? [on hold]

Which part of the code is wrong for artificial neural network in R? [on hold] I'm trying to predict a sales demand by using artificial neural network and 10 fold cross validation. So, I coded by using nnet package as follows: library(nnet) library(plyr) k = 10 question$id <- sample(1:k, nrow(question), replace = TRUE) list <- 1:k prediction <- data.frame() testsetCopy <- data.frame() progress.bar <- create_progress_bar("text") progress.bar$init(k) for(i in 1:k){ trainingset <- subset(question, id %in% list[-i]) testset <- subset(question, id %in% c(i)) mymodel <- nnet(Sales1~ResidentA+ResidentB+ResidentD+DOW+Weather+Amt_Rainfall+Air_Quality+Avg_Temp+Humidity, data=trainingset, size=7, decay=0.1) temp <- as.data.frame(predict(mymodel, testset[,-5])) prediction <- rbind(prediction, temp) testsetCopy <- rbind(testsetCopy, as.data.frame(testset[,3])) progress.bar$step() } However, the result showed less than 1 that it seems something wrong. So...