Closed danielsf closed 1 year ago
In the process of looking through #2566, I attempted to see if I could reuse the existing scripts and code to produce a VBN behavior only json file for testing of that ticket. However, I found that much of the scripts and SDK code uses the ecephys_session_id to query for the data from LIMS. As these behavior only sessions by definition do not have an ecephys_session_id we will need to modify the code or create a new module for retrieving the json data.
@morriscb one idea is to use the to_json
API (which was originally intended for this purpose). I.e BehaviorSession.to_json()
should just work. We never implemented to_json
. Another idea is to use the behavior_write_nwb_strategy
which we used for VBO which generates the json.
Okay, but we need to create the initial session_data before doing to_json
. If I'm understanding how things are setup correctly, that is what the scripts this ticket and I was referring to. Using BehaviorSession.to_json()
is a little circular at present as I need to create the json session_data
to create the BehaviorSession
in the first place.
Sure, first BehaviorSession.from_lims()
, followed by BehaviorSession.to_json()
There is no from_lims()
implementation for VBN at present. So the suggestion is, doing from_lims
using the session ID for the behavior only session and then porting it down to json using to_json()
? Is that correct.
The from_lims
module is successful at packaging the data modulo a few missing data. I've fixed up all the failures I found for the data so we should be good to go except for finishing up #2574
Just merged a pull request to make from_lims
work for all of the behavior only sessions so we don't need to worry about porting the json creation for these sessions.
VBO behavior-only sessions are generated by a ruby strategy. Since we are trying to move away from that model, we need to write a python module to produce the input JSONs needed to create input JSONs that can be fed into the
BehaviorSession.from_json
method.There's a good chance that we can just take the ecephys session input JSONs that we generated for VBN 1.0 and NULL the ecephys-related fields. We should try that first.