Trouble loading a patient file

I’m trying to load a patient file (not a state file), but I cannot get it to actually work. I’m trying to run HowTo_EngineUse, modified to use the PatientFile case, and to provide the absolute path to a patient file in the patient_configuration.setPatientFile line, and it the engine initialization always returns false. There are no error messages to indicate what the problem is, and I have not been able to get visual studio to connect to the process with the symbols loaded, so I can’t step through it on the C++ side (which I’ve done before, so I’m not sure why it’s not working this time).

I’m on Windows 10 x64, building with VS2019. I’m using commit 4519dc8e76e5c533b269fdf399ffd5fe94d7eb64 from March 4.

Any ideas of what I should try?

Thanks!

To create a new patient, you will need to ensure your dataRootDir is properly set to a directory where you have all the folders full of json data files.

These directories should have been created in the install bin folder during the build

To get debug symbols, make sure you are loading the PulseJNId.dll by telling Pulse to load the properly named dll

Let me know if you are still having trouble

I’ve tried a few variants, none of which have worked:

SEPatientConfiguration patient_configuration = new SEPatientConfiguration();
patient_configuration.setPatientFile("C:\\Users\\bob.marinier\\git\\isaac\\pulse-engine\\build\\install\\bin\\patients\\Bradycardic.json");
// Optionally add conditions to the patient_configuration

// Allocate an engine
pe.initializeEngine(patient_configuration, dataRequests);
SEPatientConfiguration patient_configuration = new SEPatientConfiguration();
patient_configuration.setDataRootDir("C:\\Users\\bob.marinier\\git\\isaac\\pulse-engine\\build\\install\\bin\\patients\\");
patient_configuration.setPatientFile("Bradycardic.json");
// Optionally add conditions to the patient_configuration

// Allocate an engine
pe.initializeEngine(patient_configuration, dataRequests);
SEPatientConfiguration patient_configuration = new SEPatientConfiguration();
patient_configuration.setDataRootDir("C:\\Users\\bob.marinier\\git\\isaac\\pulse-engine\\build\\install\\bin\\");
patient_configuration.setPatientFile("patients\\Bradycardic.json");
// Optionally add conditions to the patient_configuration

// Allocate an engine
pe.initializeEngine(patient_configuration, dataRequests);

I also tried it with forward slashes, with and without trailing slashes in the data root dir and leading slashes in the patient file.

Try this:

SEPatientConfiguration patient_configuration = new SEPatientConfiguration();
patient_configuration.setDataRootDir("C:\\Users\\bob.marinier\\git\\isaac\\pulse-engine\\build\\install\\bin\\");
patient_configuration.setPatientFile("Bradycardic.json");

That worked! Thanks!

Great!

I obviously need to look at, clean up, and document the code to specify a file

FWIW, it would be super helpful if the Java methods had Javadoc comments, because most IDEs will display those during autocomplete, which makes it easier to understand what a method does and what it’s arguments should be.

Privacy Notice