Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for id = 1:32 | |
sdata = load(strcat('s',num2str(id),'.mat')); | |
sdata = sdata.data; | |
slabels = load(strcat('s',num2str(id),'.csv')); | |
[~,idx] = sort(slabels(:,2)); | |
sortedlabels = slabels(idx,:); | |
sorteddata = sdata(idx,:,:); |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import cv2 | |
import numpy as np | |
import dlib | |
cap = cv2.VideoCapture(0) | |
detector = dlib.get_frontal_face_detector() | |
predictor = dlib.shape_predictor("shape_predictor_68_face_landmarks.dat") | |
while True: |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
%Applying bandpass filter to filter out the unwanted signal <4 and >30Hz | |
yy1=bandpass(SSS1,[4 30],128); | |
%Apply DWT at 5 level of decomposition | |
waveletFunction = 'db2'; | |
[C,L] = wavedec(yy1,5,waveletFunction); | |
cD11 = detcoef(C,L,1); | |
cD21 = detcoef(C,L,2); | |
cD31 = detcoef(C,L,3); | |
cD41 = detcoef(C,L,4); | |
cD51 = detcoef(C,L,5); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
se = strel(3,3); | |
basic_gradient = imdilate(I,se)- imerode(I,se); | |
external_gradient= I-basic_gradient; | |
peakpsnr = psnr(external_gradient,I); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
% plotting the power spectral density of the image available | |
% using the psd plot to obtain further information | |
psd = imagesc(log10(abs(fftshift(fft2(I))).^2)) | |
mesh(psd); |