Skip to content
This repository has been archived by the owner on Oct 30, 2024. It is now read-only.

Analyse also static-drift stimuli pattern (prv: [BUG] Signal dataframe is not created correctly) #74

Open
lauraporta opened this issue Jul 24, 2023 · 2 comments
Labels
enhancement New feature or request

Comments

@lauraporta
Copy link
Member

lauraporta commented Jul 24, 2023

Describe the bug
When analysing some datasets the signal pd.DataFrame is not created as expected, the same stimulus is repeated 3576 times (the max is 9). This issue was revealed by the sanity check methods in PhotonData object.

To Reproduce
Run the analysis on dataset CX_122_2_hR_RSPd_monitor_right

Expected behaviour
No exception thrown and 6 repetitions in the pivot table for each stim, as the data comes from 2 days of experiments.

Log file
file name: slurm.enc1-node3.3770436.out

2023-07-19 16:20:28 PM ERROR    2023-07-19 16:20:28 PM - ERROR -       app.py:45
                                MainProcess app.py:45 - Signal table            
                                was not populated correctly                     
                                with stimulus information.                      
                                Pivot table:sf    tf    direction               
                                0.01  0.5   0.0          3576                   
                                            45.0         3576                   
                                            90.0         3576                   
                                            135.0        3576                   
                                            180.0        3576                   
                                                         ...                    
                                0.32  16.0  135.0        3576                   
                                            180.0        3576                   
                                            225.0        3576                   
                                            270.0        3576                   
                                            315.0        3576                   
                                Length: 288, dtype: int64,                      
                                expercted:2384                                  
                                Traceback (most recent call last):              
                                  File                                          
                                "/nfs/nhome/live/lporta/source/rsp-vis          
                                ion/rsp_vision/console_application/app          
                                .py", line 42, in inner_function                
                                    func(*args, **kwargs)                       
                                  File                                          
                                "/nfs/nhome/live/lporta/source/rsp-vis          
                                ion/rsp_vision/console_application/app          
                                .py", line 148, in analysis_pipeline            
                                    photon_data = PhotonData(data,              
                                PhotonType.TWO_PHOTON, config)                  
                                                  ^^^^^^^^^^^^^^^^^^^^          
                                ^^^^^^^^^^^^^^^^^^^^^^^^^^^                     
                                  File                                          
                                "/nfs/nhome/live/lporta/source/rsp-vis          
                                ion/rsp_vision/objects/photon_data.py"          
                                , line 114, in __init__                         
                                    self.check_consistency_of_signal_d          
                                f(self.signal)                                  
                                  File                                          
                                "/nfs/nhome/live/lporta/source/rsp-vis          
                                ion/rsp_vision/objects/photon_data.py"          
                                , line 557, in                                  
                                check_consistency_of_signal_df                  
                                    raise ValueError(                           
                                ValueError: Signal table was not                
                                populated correctly                             
                                with stimulus information.                      
                                Pivot table:sf    tf    direction               
                                0.01  0.5   0.0          3576                   
                                            45.0         3576                   
                                            90.0         3576                   
                                            135.0        3576                   
                                            180.0        3576                   
                                                         ...                    
                                0.32  16.0  135.0        3576                   
                                            180.0        3576                   
                                            225.0        3576                   
                                            270.0        3576                   
                                            315.0        3576                   
                                Length: 288, dtype: int64,                      
                                expercted:2384                                  

Computer used (please complete the following information):

  • OS: Linux on hpc
  • Version: on branch shell-script, latest commit: 583a118a5525f9e51da3c6bba06ee5690ece0cf1
  • Hardware specs: RAM requested 150G per cpu, cpu as assigned

Additional context
Sbatch settings:

#SBATCH --array=0-2
#SBATCH -p cpu # partition (queue)
#SBATCH --mem-per-cpu=150G
#SBATCH -t 00-04:00 # time (D-HH:MM)
@lauraporta lauraporta added the bug Something isn't working label Jul 24, 2023
@lauraporta
Copy link
Member Author

Another similar case, dataset BY_324_2_hL_RSPd_monitor_front

                                Pivot table:sf    tf    direction               
                                0.01  0.5   0.0          1122                   
                                            45.0         1122                   
                                            90.0         1122                   
                                            135.0         935                   
                                            180.0        1122                   
                                                         ...                    
                                0.32  16.0  135.0        1122                   
                                            180.0        1122                   
                                            225.0         935                   
                                            270.0        1122                   
                                            315.0        1122    

@lauraporta
Copy link
Member Author

The file CX_122_2_hR_RSPd_monitor_right has a longer number of frames than expected, 7800.
The stimulus protocol is static_drift. This analysis is not implemented yet

@lauraporta lauraporta added enhancement New feature or request and removed bug Something isn't working labels Jul 31, 2023
@lauraporta lauraporta changed the title [BUG] Signal dataframe is not created correctly Analyse also static-drift stimuli pattern (prv: [BUG] Signal dataframe is not created correctly) Jul 31, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant