Giter Club home page Giter Club logo

first-impressions's Introduction

Arulkumar's github stats

first-impressions's People

Contributors

can-taslicukur avatar innovarul avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

first-impressions's Issues

visualization software

Hi,

I was wondering in which software tool have you used in order to generate the network's visualization as seen in your paper: "Bi-modal First Impressions Recognition using Temporally Ordered Deep Audio and Stochastic Visual Features".
screen shot 2018-03-18 at 5 04 25 pm

How to import and run the test videos on LSTMModel#440.net

Hello,

I am able to import the file
by
require "nn"
require "cunn"
require "rnn"
net = torch.load("LSTMModel#440.net")

but I don't understand how to use it.

it throws an error saying

torch.load("LSTMModel#440.net")
/home/conankapoor/torch/install/bin/luajit: ...or/torch/install/share/lua/5.1/rnn/AbstractRecurrent.lua:287: attempt to call field 'tostring' (a nil value)
stack traceback:
...or/torch/install/share/lua/5.1/rnn/AbstractRecurrent.lua:287: in function <...or/torch/install/share/lua/5.1/rnn/AbstractRecurrent.lua:283>
[C]: in function 'tostring'
...onankapoor/torch/install/share/lua/5.1/nn/Sequential.lua:118: in function <...onankapoor/torch/install/share/lua/5.1/nn/Sequential.lua:107>
[C]: in function 'tostring'
...e/conankapoor/torch/install/share/lua/5.1/trepl/init.lua:262: in function 'rawprint'
...e/conankapoor/torch/install/share/lua/5.1/trepl/init.lua:302: in function 'print'
...e/conankapoor/torch/install/share/lua/5.1/trepl/init.lua:663: in function 'repl'
...poor/torch/install/lib/luarocks/rocks/trepl/scm-1/bin/th:204: in main chunk
[C]: at 0x00405d50

problem to execute LSTM model

Hi Arul,

Many thanks for your contribution. I wrote a script that executes a video through your trained LSTM/3DNN models. The 3DNN is working fine, but LSTM model throws the following errors. Any comment about my code would be greatly appreciated. Thanks in advance.

require 'torch'
require 'cutorch'
require 'cunn'
dofile 'utilities.lua'
require 'rnn'
require 'nngraph'


logger = dofile 'log.lua'
VIDEOFEATURESROWS = 6
VIDEOFEATURESCOLS = 0
VIDEOFEATURESLMROWS = 6
VIDEOFEATURESLMCOLS = 0

opt = {}
opt.targetScaleFactor = 1
opt.type= 'float'
--opt.type= 'cuda'
opt.LSTM = true

 mp4name = 'somename.mp4'

--audio data
 validationAudioFeaturePath = 'data/validationaudiofeat';
 validationaudiofiles = dir.getallfiles(validationAudioFeaturePath)
 validationAudioData = loadAudioFeaturesFromFolder(validationaudiofiles)
 local inputaudio = validationAudioData[mp4name]

 if opt.type == 'float' then
  inputaudio = inputaudio:float();
 else
  inputaudio = inputaudio:cuda();
 end


--video data
 local validationVideoData = prepareVideoFramesData({[mp4name]=1}, VIDEOFEATURESROWS, 'validation',opt.LSTM)

 if(opt.type == 'cuda') then
  validationVideoData[mp4name]= validationVideoData[mp4name]:cuda()
 else
  validationVideoData[mp4name] = validationVideoData[mp4name]:float()
 end


--all post-processed inputs
 local currentInput = {inputaudio, validationVideoData[mp4name] }

--load the traied model
 if(not opt.LSTM) then
  model = torch.load('models/3DCNNModel#600.net')
 else
  model = torch.load('models/LSTMModel#440.net')
 end

 model:evaluate()
 local pred = model:forward(currentInput)


--building a tensor to add the results
 validationPredictions = {}
 validationPredictions = torch.Tensor(5):fill(0)

 if(not opt.LSTM) then
  validationPredictions = validationPredictions + torch.squeeze( pred:double() / opt.targetScaleFactor )
 else
  validationPredictions = validationPredictions + torch.squeeze( (torch.mean(pred:double(),1) / opt.targetScaleFactor) )
 end



The errors:

/root/torch/install/bin/luajit: /root/torch/install/share/lua/5.1/nn/Container.lua:67: 
In 5 module of nn.Sequential:
/root/torch/install/share/lua/5.1/rnn/LSTM.lua:188: attempt to perform arithmetic on field 'step' (a nil value)
stack traceback:
	/root/torch/install/share/lua/5.1/rnn/LSTM.lua:188: in function </root/torch/install/share/lua/5.1/rnn/LSTM.lua:187>
	[C]: in function 'xpcall'
	/root/torch/install/share/lua/5.1/nn/Container.lua:63: in function 'rethrowErrors'
	/root/torch/install/share/lua/5.1/nn/Sequential.lua:44: in function 'forward'
	5_validate.lua:70: in main chunk
	[C]: in function 'dofile'
	/root/torch/install/lib/luarocks/rocks/trepl/scm-1/bin/th:150: in main chunk
	[C]: at 0x00405d50

WARNING: If you see a stack trace below, it doesn't point to the place where this error occurred. Please use only the one above.
stack traceback:
	[C]: in function 'error'
	/root/torch/install/share/lua/5.1/nn/Container.lua:67: in function 'rethrowErrors'
	/root/torch/install/share/lua/5.1/nn/Sequential.lua:44: in function 'forward'
	5_validate.lua:70: in main chunk
	[C]: in function 'dofile'
	/root/torch/install/lib/luarocks/rocks/trepl/scm-1/bin/th:150: in main chunk
	[C]: at 0x00405d50

Testing the pre-trained model

Hello,

I would like to test the pre-trained model LSTMModel#440.net and 3DCNNModel#600.net, which you uploaded.
However, I'm completely new to Lua, so would you release your testing code if you have the one?
Thank you!

Can we use this code for feature extraction?

Hi Arul,
Can we use the pre-trained models in your repository for feature extraction?
I installed OpenFace and pyAudioAnalysis libraries.

Can you please share the details to use this code for feature extraction alone without any training?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.