Recent content by Wrichik Basu

  1. Wrichik Basu

    SATA NAND SSD vs NVMe M.2 — Which one has a higher lifespan?

    A friend of mine is setting up a gaming PC. His platform (MSI Mag X670E Tomahawk WiFi) supports four M.2 drives. The OS will definitely be on an M.2, of 2 TB capacity. He is also getting a few high-capacity HDDs (Seagate Barracuda, works on SATA3) to store stuff that isn't used much, like...
  2. Wrichik Basu

    Unable to crack this image enhancement code -- Matlab is throwing errors

    Please copy-paste the errors too, we can't help unless we see the errors and in which line they are occurring. MATLAB isn't concerned about indentation, unlike Python.
  3. Wrichik Basu

    Python Most efficient way to randomly choose a word from a file with a list of words

    I am using SQLite so that the database file is local to the bot. My host has an option of a MySQL database (free of charge), but I don't use it because of issues related to backing up the data. With an SQLite file, I can just download the file to create a backup. It's a Discord bot, and I am...
  4. Wrichik Basu

    Python Most efficient way to randomly choose a word from a file with a list of words

    Less than 256 MB to be specific. Your idea is good, I will check how much memory is needed if I need to do it that way.
  5. Wrichik Basu

    Python Most efficient way to randomly choose a word from a file with a list of words

    Interesting, probably I can do that in a database too! One column with the first letter of each word, another column with the word itself. Then proceed as shown in this answer on SO: SELECT words FROM table_name ORDER BY RANDOM() LIMIT 1 WHERE initial_letter = 'a';
  6. Wrichik Basu

    Python Most efficient way to randomly choose a word from a file with a list of words

    I have a file consisting of a bunch of words, with one word in each line. For example, consider this webpage, or this one, but instead of being online, there is a .txt file is locally on my PC. My aim is to pick a word at random from this list that starts with a specific given letter. Say I want...
  7. Wrichik Basu

    Happy Birthday to our founder Greg Bernhardt!

    Wish you a very happy birthday @Greg Bernhardt! :partytime: 🥳 🎉 Hope you have a wonderful day today, and wish you the very best in your endeavours.
  8. Wrichik Basu

    Arduino mini pro 328p 16Mhz Voltage

    The pro mini board is outdated and no longer produced. The alternative would be to use Nano, or maybe directly program an ATmega chip using another Arduino board via the Arduino as ISP protocol (which is what I do to reduce costs).
  9. Wrichik Basu

    Query runs fine in MySQL, but returns empty list in Python

    I tried splitting into two execute() statements, but it was not working. Now I tried it again and it is working. Programming can be spooky at times! Indeed, that's the best approach. Selecting less data means lesser memory overhead, especially for a bot that's supposed to be online all the...
  10. Wrichik Basu

    Query runs fine in MySQL, but returns empty list in Python

    I have a database that looks like this: I want to get the "leaderboard position" of a particular member. The idea is to order the data by the score column, and then retrieve the row position of that particular member id. This is my query in MySQL: SET @rowNum := 0; SELECT rowNum FROM(...
  11. Wrichik Basu

    Arduino mini pro 328p 16Mhz Voltage

    Brown-Out Detection.
  12. Wrichik Basu

    Arduino mini pro 328p 16Mhz Voltage

    The specs page for Arduino pro mini says that they had two boards, one at 3.3V, and another at 5V. If you have the 5V board, it appears that they want it to be powered at 5-12V. However, there should be an option for BOD in the Arduino IDE. You can lower that value and then experiment a bit on...
  13. Wrichik Basu

    What's the Deal with Negative Reaction Scores?

    That's correct. Basically, reacting with "sad" or "skeptical" has no effect on the reaction score. Yes. If I am correct, "Like", "Love", "Informative", "Care" and "Haha" increase the reaction score by 1. "Sad" and "Skeptical" have no effect. No, see above. You can get Trophies based on your...
  14. Wrichik Basu

    What's the Deal with Negative Reaction Scores?

    In the original XF software, skeptical is actually a downvote emoji. But here in PF, that was changed to skeptical and the value was set to neutral.
  15. Wrichik Basu

    Python Best way to fix "externally managed environment" error?

    It's actually not a solution to be exact, but a workaround. Virtual environments were not really made to be used like that. Each project should anyway have its own venv or Poetry environment to avoid clashes with any other project, similar to the way we use Gradle. But we cannot forget that in...
Back
Top