Hi, I want to know what is the best way to keep the databases I use in different projects? I use a lot of CSVs that I need to prepare every time I'm working with them (I just copy paste the code from other projects) but would like to make some module that I can import and it have all the processes of the databases for example...
I'm new to programming a bit, and am learning python so I can learn flask, using the python crash course book. I was learning about list comprehension but it briefly talks about it. If I do...
List comprehensions return a new list. For the sake of code clarity, you probably shouldn't change a second list from within a list comprehension. If you're trying to concatenate two lists, you can do so in a second line:
a = list(range(10))
b = [ value for value in range(5) ]
a.extend(b)
# a has 15 elements
print(a)
the initial location doesn't need to be GPS, just a known anchor location. Which is trivial to implement in the case of trains, since stations don't move that drastically.
you're thinking anywhere on the platform, I'm suggesting a known place near a station by which the train passes and its location - at that moment - is known.
All the system needs is a ground-truth location after a certain amount of time. GPS is just a cheap and convenient way to do it almost anywhere, but this location correction doesn't need to be satellite-based at all.
surely these are things that should be considered, but they move in relation to what? And is this surprising amount of any significance for tens or hundreds of miles of rail?
Google Earth is almost not usable in Firefox. I’d like to ask for suggestions from the community because I really don’t want to use Google Chrome where it works great. I’m on Linux Mint, an Ubuntu derivative.
Actually, really liked the Apple Intelligence announcement. It must be a very exciting time at Apple as they layer AI on top of the entire OS. A few of the major themes....
Running Endeavour OS Linux and just updated to plasma 6.0.5, framework 6.3.0, Qt version 6.7.1 on Wayland. I use capslock strictly as my brain refuses to learn using shift (I do touch type no problem), but as well know the capslock is very slow on Linux which always results in text like THis. So, I've found a fix for it online...
I don't know what you mean by that. It's a locale, it has nothing to do with KDE or Plasma. It doesn't even need a desktop environment. Plasma Settings will just pick up the ones you have installed.
It was really much better than fb and other platforms, really easy to group and filter content on it.
I just hated their forced integration with YouTube comments section which only served to artificially pump up the number of G+ users. Great platform, bad management decisions.
Good evening, everyone. I have, but one quick inquiry. What are the best resources in your opinion to learn python by yourself as a complete beginner?...
I guess partly because the Python tooling catastrophe makes it a quite a pain to set them up.
Salty huh
Saying you need to set up type hinting in Python shows that you're the one assuming it's a hassle like TS, where you need a different runtime to have access to something the language (JS) should have provided from the start.
Everything you need is provided by typing, which is included in a Python install. Just import it and start using it.
Just updated to Plasma 6, and got a question: is there a way to make the bottom panel keep at the bottom (like when fullscreen windows are opened) and not float regardless of windows?...
Well, it's not exactly impossible because of that, it's just unlikely they'll use a discriminator for the task because great part of generated content is effectively indistinguishable from human-written content - either because the model was prompted to avoid "LLM speak", or because the text was heavily edited. Thus they'd risk a high false positive rate.
True. I wanted to replace it with OSM or similar, but my main use of Maps after navigation is exploring places, reading reviews, and browsing pictures. They have a database that is tough to replace.
You can say any execution flow controls are like gotos - continue, break, exceptions, switch, even ifs are not much more than special cases of gotos.
This is true regardless of the size of the function which shows that the size of the function isn’t the determinant
Logical clarity does tend to worsen as the function grows. In general, it is easier to make sense of a shorter function than a longer one. I don't know how you could even say otherwise.
Early returns are still great for argument validation. The alternative means letting the function execute to the end when it shouldn't, just guarded by if conditions - and these conditions any reader would have to keep in mind.
When a reader comes across an early return, that's a state they can free from their reader memory, as any code below that would be unreachable if that condition was met.
Any validation you can write with a few early returns you can write with an equivalent conditional/s followed by a single nested block under it, followed by a single return. The reader is free to leave the validation behind just the same.
And that conditional indents your entire function one level - if you have more validation checks, that's one level of indentation per check (or a complicated condition, depends whether you can validate it all in one place). It's pretty much the case the other user illustrated above.
Returns inside business logic past validation is where the problematic bugs of this class show up
That much we agree. But again, this is not an early return issue, putting too much logic in a function is the issue. Rewriting it without early returns won't make it much clearer. Creating other functions to handle different scenarios will.
Telegram is the only massively popular messaging service that allows everyone to make sure that all of its apps indeed use the same open source code that is published on Github.
Not true. Signal has a very similar client verification process to Telegram's, described here. The lack of an iOS reproducible build is an Apple limitation / nuisance.
It’s very complicated, the 2nd jailbroken device is necessary because there’s no other way to download the .ipa, but even if you manage to do that and bit-for-bit reproduce the .ipa you downloaded from source, there’s no way to know if the App Store is sending every user the same .ipa or if your other, non-jailbroken iPhone downloaded a backdoored one.
Telegram docs even acknowledge these limitations.
Ultimately, this client verification is not the selling point Telegram's founder makes it sound like, since most messages are not E2EE and the server code is closed.
tl;dr "Signal might be untrustworthy because the tech came from a State-sponsored project and the current chairman acknowledges that Wikipedia has a white and Western bias."
just wait until they find out pretty much all tech we have can be traced back to government-funded research.
I'd look into AV1 decoding benchmarks, regardless of NVIDIA vs AMD, as I've been using NVIDIA on Jellyfin for a while with no issues.
HEVC is not as relevant IMO, as it's not available through browsers due to license restrictions (ffmpeg / mpv works fine), so I'd focus on AV1 capabilities, which is not available in many cards.
Compression might be useful in some cases, but the bulk of my data is already compressed or not much compressible (think videos, images, compressed archives, game assets). So the trade off doesn't make much sense to me.
best way to access databases in different projects
Hi, I want to know what is the best way to keep the databases I use in different projects? I use a lot of CSVs that I need to prepare every time I'm working with them (I just copy paste the code from other projects) but would like to make some module that I can import and it have all the processes of the databases for example...
Why can't I append to list inside of a list comprehension?
I'm new to programming a bit, and am learning python so I can learn flask, using the python crash course book. I was learning about list comprehension but it briefly talks about it. If I do...
‘It’s the perfect place’: London Underground hosts tests for ‘quantum compass’ that could replace GPS ( www.theguardian.com )
Google Earth Very Slow in Firefox ( infosec.pub )
Google Earth is almost not usable in Firefox. I’d like to ask for suggestions from the community because I really don’t want to use Google Chrome where it works great. I’m on Linux Mint, an Ubuntu derivative.
McDonald’s will stop testing AI to take drive-thru orders, for now ( www.theverge.com )
$335 espresso ( youtu.be )
Andrej Karpathy endorses Apple Intelligence ( lemmy.world )
Actually, really liked the Apple Intelligence announcement. It must be a very exciting time at Apple as they layer AI on top of the entire OS. A few of the major themes....
"make capslock an additional Ctrl" option was removed in the latest update
Running Endeavour OS Linux and just updated to plasma 6.0.5, framework 6.3.0, Qt version 6.7.1 on Wayland. I use capslock strictly as my brain refuses to learn using shift (I do touch type no problem), but as well know the capslock is very slow on Linux which always results in text like THis. So, I've found a fix for it online...
List of locales in Plasma ( lemmy.kde.social )
In the Region & Language section of the System Settings, when choosing formats, a list of locales is displayed....
Gemini doesn't share Google search's AI advice on pizza cheese solutions? ( sh.itjust.works )
Valve confirms your Steam account cannot be transferred to anyone after you die | Your Steam games will go to the grave with you ( www.techspot.com )
Gemini is the new Google+ ( www.computerworld.com )
New Windows AI feature records everything you’ve done on your PC ( arstechnica.com )
Python beginner
Good evening, everyone. I have, but one quick inquiry. What are the best resources in your opinion to learn python by yourself as a complete beginner?...
[SOLVED] Is there a way to make panel NOT float in Plasma 6?
Just updated to Plasma 6, and got a question: is there a way to make the bottom panel keep at the bottom (like when fullscreen windows are opened) and not float regardless of windows?...
RIP Twitter Dot Com: Elon Musk Moves Social Network to X Web Address ( variety.com )
I tracked my SOT on my Pixel 8 for 2 months across stock and GrapheneOS ( lemmy.world )
Charts...
Twitter is officially X.com now ( www.theverge.com )
my reaction to day 1 of Google i/o ( youtube.com )
Google is redesigning its search engine — and it’s AI all the way down ( www.theverge.com )
Comcast Unveils Peacock, Netflix, Apple TV+ Streaming Bundle ( www.hollywoodreporter.com )
Cable is dead. Long live the cable bundle. Curious to see the pricing and if the bundle only includes ad tiered options.
Is there any way to change this order in the Application Launcher? ( lemmy.world )
got him ( lemy.lol )
Telegram founder and CEO alledges signal has backdoors, they don't provide reproduceible builds, etc.
Here's what he said in a post on his telegram channel:...
Prime Video subs will soon see ads for Amazon products when they hit pause ( arstechnica.com )
As if the Prime Video app couldn't get any worse.
What's a good graphics card for jellyfin?
I assume it's not nvidia. Yet I have no idea how to differentiate between them and neither do I know what a good price is....
Which file system do you recommend for Linux?
Just a simple question :...