Skip to content

sumansahoo16/University-of-Liverpool---Ion-Switching

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 

Repository files navigation

University-of-Liverpool---Ion-Switching

Problem Statement

Ion channels are pore-forming membrane proteins, that allow ions to pass through the channel pore. When ion channels open, they pass electric currents. Existing methods of detecting these state changes are slow and laborious.

image

Data

  • A timestamp
  • Ampere values (current) for each timestamp. These values were measured at a sampling frequency of 10 kHz.
  • The corresponding number of open channels at that timestamp (only provided for the train data).

image

Pre-processing

We noticed that drift is present in the beginning and in the end of the signal data. We notice two types of drift: Slant drift and Parabolic drift. We removed them.

image image image image

Modeling

WaveNet is superior at finding patterns in waveforms. Using dilated convolutions, it decomposes a signal into its different frequency sine waves just like the Fourier Transform.

def wave_block(x, filters, kernel_size, n):
        dilation_rates = [2**i for i in range(n)]
        x = Conv1D(filters = filters,
                   kernel_size = 1,
                   padding = 'same')(x)
        res_x = x
        for dilation_rate in dilation_rates:
            tanh_out = Conv1D(filters = filters,
                              kernel_size = kernel_size,
                              padding = 'same', 
                              activation = 'tanh', 
                              dilation_rate = dilation_rate)(x)
            sigm_out = Conv1D(filters = filters,
                              kernel_size = kernel_size,
                              padding = 'same',
                              activation = 'sigmoid', 
                              dilation_rate = dilation_rate)(x)
            x = Multiply()([tanh_out, sigm_out])
            x = Conv1D(filters = filters,
                       kernel_size = 1,
                       padding = 'same')(x)
            res_x = Add()([res_x, x])
        return res_x
        
        
    inp = Input(shape = (shape_))
    
    x = wave_block(x, 16, 3, 12)
    x = wave_block(x, 32, 3, 8)
    x = wave_block(x, 64, 3, 4)
    x = wave_block(x, 128, 3, 1)
    
    out = Dense(11, activation = 'softmax', name = 'out')(x)

Releases

No releases published

Packages

No packages published