OSCAR C++ UI Feature Expansion
Budget: $10 – $30 USD
Modify the Open source project OSCAR which is written in C++
Currently when Oximeter data is imported, a baseline value is calculated from the first hour of data. This baseline is an integer, usually 80-98. That baseline is then used for further calculations but that's beyond the simple scope of this project.
We are going to add an option to override the calculated baseline value with a static value. We’ll need to update the UI so the user can set whether they want the Baseline to be calculated as it is now, or what override value to use.
The changes themselves should be easy for someone with C++ experience under Linux. Note: OSCAR also tracks other data and uses baselines for those. We are not touching those parts.
1. The project and build instructions can be found and cloned from here:
https://gitlab.com/CrimsonNape/OSCAR-code
I was able to build the project on my Debian Trixie system with no difficulty using the instructions from the project.
2. We’re going to modify the UI (preferencesdialog.ui) and add an option under the Oximetry tab. We’ll add a new section “Experimental Options” Then a label “Baseline SpO2” then a picklist field.
Picklist choices will be:
Default (Calculated from Hour 1)
99
98
97
96
95...
...85
Text for Tooltip: “By defult OSCAR uses a calculation from the first hour of oximetry data as baseline. This setting allows you to override that with a static value. This may be useful when the first hour is not typical of the whole dataset. It may also be useful to provide easier comparison between days. “
3. This option will be saved into the Profile.xml where other user settings are stored.
4. When Oximetry data is imported, the Baseline is calculated in calcs.cpp around line 1550. This is where our override code should go. If the user has selected “Default (Calculated from Hour 1)” then the existing logic continues. If the user has selected another value, i.e. 95, then we just use 95 as the Baseline.
5. Note that if OSCAR is executed from the terminal, there is debug printed to the console. We should include text in the debug to show whether we are using the Default SpO2 baseline logic or Overriding Baseline to %baseline%. Running from the Console may help you as you develop.
6. I will provide you with a test.spo2 file that you can import into OSCAR to test your work.
7. Most likely you will be modifying at least these files: calcs.cpp, preferencesdialog.cpp, preferencesdialog.ui
8. Deliverables:
a. You will test importing the sample test.spo2 file with the Preference set to default as well as an override value of 97 and provide screenshots of the “daily view”. This file and some screenshots will be provided to you when the project starts.
b. Copies of the updated source files so that I can build it on my system. Please document your code.
c. Please – minimal changes to achieve the outcome only. If you use AI tools, those may want to refactor code and I don’t want to do that. Most likely I will submit the diffs to the project to see ask the maintainer to include our enhancements, so we want minimal changes to achieve the result.
Tips:
1. To ithe import the .spo2 file, click Oximetry Wizard then Import datafile saved by another program.
2. To view the daily view, click Daily View, then click on the calendar to pick the day that the data was imported from. Note “SpO2 Basline Used:” will change with the enhancement we’re making. Also, SpO2 Desaturations count, % and per hour will automatically change.
I will give you the test.spo2 test file as well as a couple of screenshots to help once the project starts, but you will find this easy anyway.
Currently when Oximeter data is imported, a baseline value is calculated from the first hour of data. This baseline is an integer, usually 80-98. That baseline is then used for further calculations but that's beyond the simple scope of this project.
We are going to add an option to override the calculated baseline value with a static value. We’ll need to update the UI so the user can set whether they want the Baseline to be calculated as it is now, or what override value to use.
The changes themselves should be easy for someone with C++ experience under Linux. Note: OSCAR also tracks other data and uses baselines for those. We are not touching those parts.
1. The project and build instructions can be found and cloned from here:
https://gitlab.com/CrimsonNape/OSCAR-code
I was able to build the project on my Debian Trixie system with no difficulty using the instructions from the project.
2. We’re going to modify the UI (preferencesdialog.ui) and add an option under the Oximetry tab. We’ll add a new section “Experimental Options” Then a label “Baseline SpO2” then a picklist field.
Picklist choices will be:
Default (Calculated from Hour 1)
99
98
97
96
95...
...85
Text for Tooltip: “By defult OSCAR uses a calculation from the first hour of oximetry data as baseline. This setting allows you to override that with a static value. This may be useful when the first hour is not typical of the whole dataset. It may also be useful to provide easier comparison between days. “
3. This option will be saved into the Profile.xml where other user settings are stored.
4. When Oximetry data is imported, the Baseline is calculated in calcs.cpp around line 1550. This is where our override code should go. If the user has selected “Default (Calculated from Hour 1)” then the existing logic continues. If the user has selected another value, i.e. 95, then we just use 95 as the Baseline.
5. Note that if OSCAR is executed from the terminal, there is debug printed to the console. We should include text in the debug to show whether we are using the Default SpO2 baseline logic or Overriding Baseline to %baseline%. Running from the Console may help you as you develop.
6. I will provide you with a test.spo2 file that you can import into OSCAR to test your work.
7. Most likely you will be modifying at least these files: calcs.cpp, preferencesdialog.cpp, preferencesdialog.ui
8. Deliverables:
a. You will test importing the sample test.spo2 file with the Preference set to default as well as an override value of 97 and provide screenshots of the “daily view”. This file and some screenshots will be provided to you when the project starts.
b. Copies of the updated source files so that I can build it on my system. Please document your code.
c. Please – minimal changes to achieve the outcome only. If you use AI tools, those may want to refactor code and I don’t want to do that. Most likely I will submit the diffs to the project to see ask the maintainer to include our enhancements, so we want minimal changes to achieve the result.
Tips:
1. To ithe import the .spo2 file, click Oximetry Wizard then Import datafile saved by another program.
2. To view the daily view, click Daily View, then click on the calendar to pick the day that the data was imported from. Note “SpO2 Basline Used:” will change with the enhancement we’re making. Also, SpO2 Desaturations count, % and per hour will automatically change.
I will give you the test.spo2 test file as well as a couple of screenshots to help once the project starts, but you will find this easy anyway.