-
Notifications
You must be signed in to change notification settings - Fork 73
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Stress Level Detector Meter Correction #167
Comments
Sure @Xblade9669, go ahead! |
i am just a newbie!! you can assign others |
Heyyyy @yashasvini121 I agree upon @Xblade9669 and I believe the Stress Level Detector meter should start from 0, as some categories (e.g., compare_to_successful_people,) might not apply to everyone. Based on my experience with similar projects, and my eagerness to contribute to Open source(gssoc-ext), I’d like to work on resolving this. Could you please assign me to this issue? |
Hey, I agree that the Stress Level Detector doesn’t start from 0 because the dataset it’s based on doesn’t include 0. As mentioned in this discussion, the scale ranges from 1 to 5, representing "strongly disagree" to "strongly agree." So, whether it starts from 0 or 1 doesn’t carry any meaningful significance. If you'd like, you could add a description to clarify the scale or include text on the slider for better context. Let me know if you’d like to proceed in this direction @Shreyas-GN. |
Hey @yashasvini121 , I'd be happy to work on this, but I’m unsure how to test the changes or use Streamlit for this project. Could you guide me on that? Once I have the info, I can submit a pull request with the updates. Let me know if that works! |
Unfortunately, Streamlit sliders only accept numerical values internally, so you can't directly replace the slider values with text labels. Instead, you can use radio buttons to achieve a similar effect. To implement this, modify the Additionally, refer to the To run the Streamlit project, use the command |
Hey @yashasvini121 , I'll also check out the form_handler.py file to understand how the JSON is handled. Thanks for the guidance, I’ll get started on this! |
Hey @yashasvini121 , However, when I clicked the predict button, I encountered a Should I focus on resolving that issue, or would you prefer that I proceed with the radio button design for now? Thanks for your guidance! Best, |
Apologies for the late response; I was busy with exams. The error occurs because strings are being returned where integers are expected. To fix this, add the following input_mapping = {
"Strongly Disagree": 1,
"Disagree": 2,
"Neutral": 3,
"Agree": 4,
"Strongly Agree": 5,
} Also, adjust the function parameters before passing them to freq_no_purpose = input_mapping[freq_no_purpose] |
Hey @yashasvini121 Thanks for the guidance! I’ll work on implementing the input_mapping in the predict.py file and adjust the parameters accordingly. I’ll let you know once it’s done and tested. Thanks again for your help! Best, |
The Stress Level Detector asks us readings from 1 to 5 which according to me needs slight modification i.e. the meter reading should in my opinion start from 0.
As for some cases the category might be 0 , for example : seeking validation might be 0 for few people as they might be self satisfied with what they are doing or someone despite of watching social media might not be depressed and might as well be feeling extremely contended.
The text was updated successfully, but these errors were encountered: