aboutsummaryrefslogblamecommitdiff
path: root/nerv/nn/network.lua
blob: 2cb83ced8db3d99832d624612dea12036bc17af9 (plain) (tree)
1
2
3
4
5
6
7

                                          

                                                      


                                       










                                                     
                    

                         
                                            
















                                                        
                              




                                                  







                                                      
                                        
                               

                                 

                                               
                                         


                                          







                                                                          





                                                       

                                                        
                   


                                                                       



                                                                          


                                                             

                                                           



                                                                                                   
                       

                                                                     





                   





                                             
 

                             
   
 
                             
                              
                                                             
       


                          
                                      


                                 
                                  









                                                       
                                                         


















                                                                             
                   





                                                          
                                                     
















                                                                         
                                        

































                                                                                 
                                   








































































































                                                                                 
                                 
                                 










                                                                 
                                 










                                                                 
                                 





















                                                                      














                                                                                                      




                                 
                                 








                                                         

           
 
                  



                                                       


                                                                                          



                                                                             


               



                                                 
 









                                                                    




               
                            




                                                                               
                                  









                                                                          
                                 


                                                           
                                    

                                               

                                                            



                                                                                                                                   





                                                                         



           
                         





                                                                                                   
   











                                        
local network = nerv.class('nerv.Network')

function network:__init(id, global_conf, network_conf)
    self.id = id
    self.network = network_conf.network
    self.dim_in = self.network.dim_in
    self.dim_out = self.network.dim_out
    self.gconf = global_conf
    if self.gconf.use_cpu then
        self.mat_type = self.gconf.mmat_type
    else
        self.mat_type = self.gconf