• 6 Posts
  • 125 Comments
Joined 1 year ago
cake
Cake day: June 21st, 2023

help-circle



  • When it comes to writing code, there is a huge difference between code that works and code that works *well." Lets say you’re tasked with writing a function that takes an array of RGB values and converts them to grayscale. ChatGPT is probably going to give you two nested loops that iterate over the X and Y values, applying a grayscale transformation to each pixel. This will get the job done, but it’s slow, inefficient, and generally not well-suited for production code. An experienced programmer is going to take into account possible edge cases (what if a color is out of the 0-255 bounds), apply SIMD functions and parallel algorithms, factor in memory management (do we need a new array or can we write back to the input array), etc.

    ChatGPT is great for experienced programmers to get new ideas; I use it as a modern version of “rubber ducky” debugging. The problem is that corporations think that LLMs can replace experienced programmers, and that’s just not true. Sure, ChatGPT can produce code that “works,” but it will fail at edge cases and will generally be inefficient and slow.


  • I can’t find a decent screen protector for my Galaxy S23, no matter how I try, and it’s all due to the damned in-display fingerprint reader. Any adhesive-style screen protector has an open area for the fingerprint reader, and it’s either a different material or a different thickness; they all look like shit. I’ve tried the screen protectors that use a UV-cured adhesive, and they’re messy, difficult to apply properly, and generally a pain in the ass.

    I’ve relegated myself to not using a screen protector at all, but considering my pocket lint scratches my screen, it sucks.


  • There are really two reasons ECC is a “must-have” for me.

    • I’ve had some variant of a “homelab” for probably 15 years, maybe more. For a long time, I was plagued with crashes, random errors, etc. Once I stopped using consumer-grade parts and switched over to actual server hardware, these problems went away completely. I can actually use my homelab as the core of my home network instead of just something fun to play with. Some of this improvement is probably due to better power supplies, storage, server CPUs, etc, but ECC memory could very well play a part. This is just anecdotal, though.
    • ECC memory has saved me before. One of the memory modules in my NAS went bad; ECC detected the error, corrected it, and TrueNAS sent me an alert. Since most of the RAM in my NAS is used for a ZFS cache, this likely would have caused data loss had I been using non-error-corrected memory. Because I had ECC, I was able to shut down the server, pull the bad module, and start it back up with maybe 10 minutes of downtime as the worst result of the failed module.

    I don’t care about ECC in my desktop PCs, but for anything “mission-critical,” which is basically everything in my server rack, I don’t feel safe without it. Pfsense is probably the most critical service, so whatever machine is running it had better have ECC.

    I switched from bare-metal to a VM for largely the same reason you did. I was running Pfsense on an old-ish Supermicro server, and it was pushing my UPS too close to its power limit. It’s crazy to me that yours only pulled 40 watts, though; I think I saved about 150-175W by switching it to a VM. My entire rack contains a NAS, a Proxmox server, a few switches, and a couple of other miscellaneous things. Total power draw is about 600-650W, and jumps over 700W under a heavy load (file transfers, video encoding, etc). I still don’t like the idea of having Pfsense on a VM, though; I’d really like to be able to make changes to my Proxmox server without dropping connectivity to the entire property. My UPS tops out at 800W, though, so if I do switch back to bare-metal, I only have realistically 50-75W to spare.


  • Social media companies, adult websites, whatever, can try to find ways to block children from accessing their content, but kids will always find a way around it.

    It’s the parents’ responsibility to control their children. I’ve said 1000 times, children don’t need access to smartphones and tablets. A desktop PC or laptop with strict parental controls is adequate enough for school work, learning about technology, and some basic entertainment.

    When a child is old enough to work and pay for a smartphone themselves, then they’re old enough to have a smartphone. A prepaid flip phone with basic voice and SMS is more than enough for a 15-year-old.


  • corroded@lemmy.worldtoSelfhosted@lemmy.worldLow Cost Mini PCs
    link
    fedilink
    English
    arrow-up
    5
    arrow-down
    1
    ·
    13 days ago

    I have a few services running on Proxmox that I’d like to switch over to bare metal. Pfsense for one. No need for an entire 1U server, but running on a dedicated machine would be great.

    Every mini PC I find is always lacking in some regard. ECC memory is non-negotiable, as is an SFP+ port or the ability to add a low-profile PCIe NIC, and I’m done buying off-brand Chinese crop on Amazon.

    If someone with a good reputation makes a reasonably-priced mini PC with ECC memory and at least some way to accept a 10Gb DAC, I’ll probably buy two.



  • This is very situational. I’m not a contractor, but I spend a significant portion of my time doing hobbies that require power tools. I don’t need a drill that will last for an entire day at a jobsite. Ryobi works fine for me. On the other hand, I wish I had never spent $600 on a cheap planer; I knew I’d want a better one eventually, and sure enough, I found a need to upgrade after a few years. Now I’ve spent $3600 on planers. I could have just gone with the $3k one and saved myself $600.

    If I’m going to use it once, I borrow it. If I’m going to use it every few months, I buy a cheap one. If I’m going to use it every week, then it’s worth it to me to buy something I can keep for at least a decade or two.



  • The problem isn’t that Harris is being held to a higher standard. The problem is that Americans think of elections the same way they think of a sporting match. It’s “my team is going to win!” not “I’m going to vote for the candidate that is best aligned with my beliefs.” A huge number of the people who are voting Republican are doing so because the Republican party is their “team,” and damn it, their team is going to win even if it kills them.

    Many years ago, I was discussing politics with a coworker (always a bad idea, but whatever). It went something like this:

    “So, you don’t think the less-fortunate should be able to afford medical care?” “No, of course not, everyone should be able to see a doctor.”

    “You don’t think gay people should be allowed to marry?” “I’m not gay, but they can do whatever makes them happy.”

    “You support the war in Iraq, then?” “I support our troops, but the war is kind of a waste.”

    “We definitely should legalize weed, right?” “Um, I’d smoke it if I didn’t get drug tested.”

    “So why are you voting Republican, then?” “My family is Republican; we always do.”



  • I can’t speak to the AI voice generation part of this, but you might be interested in the Domesday Duplicator for digitizing your audio, especially if some or it is slightly degraded.

    https://github.com/harrypm/DomesdayDuplicator

    The project was originally designed for laserdisc, but it’s been expanded to support VHS and cassette tape. Traditionally, you would play your tape on a cassette player, then the built in analog circuitry would convert the magnetic signals into audio, amplify them, and feed them to a sound card on your PC, which then converts the analog signal to a digital audio stream.

    With the Domesdsy Duplicator, you record the raw magnetic signal from the read head and directly digitize it into a bitstream that you can then process as needed. For DIY archiving from an analog source, it’s one of the best options for signal fidelity, and it will give you the truest representation of what’s actually on the tape.




  • Like several people here, I’ve also been interested in setting up an SSO solution for my home network, but I’m struggling to understand how it would actually work.

    Lets say I set up an LDAP server. I log into my PC, and now my PC “knows” my identity from the LDAP server. Then I navigate to the web UI for one of my network switches. How does SSO work in this case? The way I see it, there are two possible solutions.

    • The switch has some built-in authentication mechanism that can authenticate with the LDAP server or something like Keycloak. I don’t see how this would work as it relies upon every single device on the network supporting a particular authentication mechanism.
    • I log into and authenticate with an HTTP forwarding server that then supplies the username/password to the switch. This seems clunky but could be reasonably secure as long as the username/password is sufficiently complex.

    I generally understand how SSO works within a curated ecosystem like a Windows-based corporate network that uses primarily Microsoft software for everything. I have various Linux systems, Windows, a bunch of random software that needs authentication, and probably 10 different brands of networking equipment. What’s the solution here?