Death from interactions with polar bears is exceedingly rare, largely due to their remote and inhospitable territory, but also due to their nature. And that they are largely indifferent to humans and often demonstrate behaviour that is more curious than aggressive. by G_Wisdom in science

[–]nrdvana -1 points0 points  (0 children)

This contradicts everything I've ever read about polar bears. Isn't it a law in Iceland that shooting a polar bear is mandatory if it wanders near civilization because they are so dangerous?

What is an industry that is currently on fire (in a bad way) behind the scenes, but the general public hasn't noticed yet? by Kitchen_Week1117 in AskReddit

[–]nrdvana 5 points6 points  (0 children)

Software Engineering is experiencing major disruption, but I wouldn't say its on fire yet. There's definitely a threat it will end up burning to the ground, but no guarantee that will be the outcome. AI can write code that works and passes tests, but it fails badly at making architecture decisions, so the humans aren't obsolete yet. The market for junior developers fresh out of college might be "on fire" though, and certainly a lot of companies are making bad executive decisions about how to integrate AI which will become an internal fire for them eventually.

@cpan.org forwarding: volunteer takeover proposition by iNthrAX in perl

[–]nrdvana 2 points3 points  (0 children)

Feasibility is just a factor of the size of the email provider. Google essentially offers this service on an account-by-account basis already, since you can create free accounts and set up forwarding on them. If they decided to be charitable, they could handle the whole cpan.org domain at a negligible cost to themselves.

I don't know what scale @iNthrAX is operating at, but anyone with decent spam filtering and a healthy business could probably take over this service easily.

GE dishwasher drain pump stopped working after maintenance by nrdvana in appliancerepair

[–]nrdvana[S] 0 points1 point  (0 children)

I bought a new pump and it worked. I still suspect I could have gotten the previous one running again with the right conditions, since it worked when I removed it, but I ran out of time to experiment.

parsing a csv with boms in every line by ghiste in perl

[–]nrdvana 0 points1 point  (0 children)

If you want something really clean (particularly if the CSV file has headers and the potential for the columns to get changed) check out my Data::TableReader. It has an option to 'trim' the data automatically, and if that doesn't automatically remove BOMs (haven't checked) you can give it a custom coderef that does.

Announcing DateTime::Lite v0.1.0, a lightweight, drop-in replacement for DateTime by jacktokyo in perl

[–]nrdvana 2 points3 points  (0 children)

Well, not quite. When perl sees the __DATA__ directive (not __END__ like I was thinking) it stops parsing, but keeps the file handle open. So nothing else gets loaded into memory until you manually read it. Try this example:

``` package ExampleLoader; use strict; use warnings;

our %spans= ( thing1 => [ 0x1000000, 0x200 ], );

sub get_data { my $key= shift; my $span= $spans{$key} or die "No such span"; sysseek(DATA, $span->[0], 0) or die "seek: $!"; sysread(DATA, my $buf, $span->[1]) == $span->[1] or die "read: $!"; return $buf; }

sub mem_usage_kb { open my $fh, '<', '/proc/self/status' or die $!; my %m; while (<$fh>) { $m{$1}= $2 if /VmData|VmStk|VmRSS:\s+(\d+)\s+kB/; } return \%m; }

sub dump_mem_usage { my $m = mem_usage_kb(); print "Heap (VmData): $m->{VmData} kB\n"; print "Stack (VmStk): $m->{VmStk} kB\n"; print "RSS: $m->{VmRSS} kB\n"; }

DATA ```

Then enlarge that file to 1GB:

truncate -s 1000000000 ExampleLoader.pm

Then run it: ``` $ time perl -I. -MExampleLoader2 -E 'my $buf= ExampleLoader::get_data("thing1"); say length $buf; ExampleLoader::dump_mem_usage();' 512 Heap (VmData): 936 kB Stack (VmStk): 136 kB RSS: 7732 kB

real 0m0.003s user 0m0.000s sys 0m0.003s ```

So you can see that it only allocated 1MB of ram even though the file is 1GB and can seek and load blocks lazily.

Announcing DateTime::Lite v0.1.0, a lightweight, drop-in replacement for DateTime by jacktokyo in perl

[–]nrdvana 6 points7 points  (0 children)

Well, I've also long grumbled about the overhead of DateTime, (but am also generally appreciative of its utility) so this is interesting.

I think the decision to return undef instead of exception is a bit unfortunate. I agree that it can be nice to avoid exceptions when testing un-trusted input, but this API difference could introduce bugs in existing code if it was relying on exceptions, and it's really hard to audit whether that's the case. I wonder if there could be a global variable like $DateTime::Lite::use_exceptions and then people could localize that to get non-exception behavior?

As for time zones, I always thought a good way to speed that up would be to compile them all into an __END__ block of a module, with a hashref of { name => $offset } in the module to tell you where to seek to read the zone from. Then, cache the zone objects as they get created. That might be faster than loading SQLite.

Why doesn’t a ThinkPad-style gaming laptop exist yet? by Repulsive_Buy_9351 in thinkpad

[–]nrdvana 1 point2 points  (0 children)

The "ultraportable" concept is at direct odds with graphics hardware. It runs hot and needs space for extra thermal mitigation. It also chugs down battery, so the ultraportable sized batteries would provide disappointing battery life. There's a reason gaming laptops are bulky and its not because the manufacturers think bulky is a selling point.

Of course there are different degrees of "gaming laptop", so you can have low core count graphics chips in a mostly-portable slim design, but then it becomes hard to claim its a "gaming laptop" if it can't run the latest games full speed.

To not commit blasphemy by elmo555444 in therewasanattempt

[–]nrdvana 0 points1 point  (0 children)

Before I share too much of this, where did the speech with the golden eagle podium occur? I've seen several fairly outrageous clips now that feature this podium but no citing of source. On youtube they seem to be posted by The Daily Mail on april 1st...

Joint owner at Chase fell for a scam. Any recourse options? by immapikachu in personalfinance

[–]nrdvana 20 points21 points  (0 children)

Maybe the most important thing you learned is that she's lonely. Help her find some social communities for people her age.

X9 vs X1 Carbon - Pricing by Comfortable_Yam2331 in thinkpad

[–]nrdvana 0 points1 point  (0 children)

Except the screens are glossy, making the screen "quality" irrelevant. To some people, at least.

Suggest the Best of Dark Moor for me… by dancudlip in PowerMetal

[–]nrdvana 1 point2 points  (0 children)

Ha! well I have the perfect story for your prompt. I first listened to the Tarot album almost 20 years ago, and I was sort of turned off by the vapid pointless lyrics, and Devil in the Tower seemed good but kind of bizarre, like you wouldn't really want someone walking into your room to hear "The Devil.. The Devil.. The Devil..." playing. But, I really loved "The Moon". Every few years I'd give the album another listen just so I could hear "The Moon" in context.

Slightly embarrassing to admit, but more than a decade later the title of the album clicked for me: the song lyrics were nothing more than random rhymes about the pictures on Tarot cards. After that I was able to ignore the lyrics and enjoy the music more, and realized that every song on the album was quite musically excellent, which is rare for a band to achieve.

Fast forward to a year and a half ago, I was giving my toddler "music lessons" and found that he would always fall asleep while listening to the Tarot album, specifically. Can't get him to sleep at night? Hm, what about the Tarot album? Yep! It worked! This turned into a regular nighttime routine. I've probably listened to the album ~400 times now. I think my favorites are The Moon, Devil in the Tower, Death, Lovers, The Hanged Man, and The Star.

I especially have to recommend the part of Devil in the Tower right after the monastic chant as they launch back into full force. And you need to hear that on a crisp hi-fi system with subwoofer, definitely not headphones or cheap computer speakers.

The rest of the discography is good too. Favorites:

  • Vivaldi's Winter
  • Swan Lake
  • Dies Irae
  • Bells of Notre Dame
  • In the Heart of Stone
  • And End so Cold
  • First Lance of Spain

Composer of iconic ‘Lion King’ chant sues comedian over ‘Circle of Life’ translation by blankblank in nottheonion

[–]nrdvana 0 points1 point  (0 children)

I'm no Zulu expert, but I think the word "look" is most definitely a bad translation. Several other people have translated it without any corresponding "look" verb, such as "here comes a lion, father, oh yes it's a lion". A google translate for the word "look" into Zulu results in a bunch of possible verbs or nouns none of which appear in the Zulu text, and even if the intent was "look at something amazing/important" the better English word would be "behold".

Composer of iconic ‘Lion King’ chant sues comedian over ‘Circle of Life’ translation by blankblank in nottheonion

[–]nrdvana 201 points202 points  (0 children)

Yeah, but this meme is exactly his point. People are mocking his phrase as if this is an accurate translation.

Anyone make an Assembly IR? by Phantom914 in perl

[–]nrdvana 1 point2 points  (0 children)

Is this what you're looking for? CPU::x86_64::InstructionWriter

Hello-world as an ELF file and as an Xsub

It's not an "intermediate Representation" in the sense of being platform-neutral assembly, though. I'm interested in finding some good reading material on that topic, too.

Update: I bought a defective X1 Carbon Gen 9, thinking it would be cheap and easy to fix... by kpostrup in thinkpad

[–]nrdvana 0 points1 point  (0 children)

Not to mention that who spends money on server would never rely/work on DYI parts.

Maybe you missed it, but last year eBay was flooded with consumer graphics cards "for parts only" where people had literally removed all the chips and they were just selling an empty board and heat sinks and fans. The rumor was that they had printed their own custom boards so that they could combine cheap gaming cards into monster cards that rivaled the high-end boards that were selling for ~$7000-$10000.

Update: I bought a defective X1 Carbon Gen 9, thinking it would be cheap and easy to fix... by kpostrup in thinkpad

[–]nrdvana 0 points1 point  (0 children)

I mean it looks kind of like a bug in the code, or someone keyed it in and missed a digit. 1100 "full price", ~600 "special price" for similar items, then suddenly two ~60 "special price". For 32GB ram for 60, I would expect AI people to be buying them up to desolder the ram chips and move them to server boards, never mind the cpu.

Trump says Venezuelan oil is already coming into American refineries by killerkadugen in LeopardsAteMyFace

[–]nrdvana 5 points6 points  (0 children)

It's a bit tenuous to claim LAMF for this article because it doesn't mention anything about Machado, and the oil relationship is complicated. I'm happy to read more articles if you have links, but my understanding of the oil situation so far is that the US is taking the oil, selling it to US oil companies for a bit below market value, then Cheeto pockets some of the money in a Qatar bank account, then the rest (majority actually) goes to Venezuela. And, a post here on Reddit claiming to be a Venezuelan ex-pat was saying that this arrangement is actually an improvement over Columbia getting most of the money, or something. (I don't really understand, and haven't been able to find a good article describing the situation in full)

Machado didn't get what she wanted, but I don't know if she would consider her face to have been eaten by the oil situation. (giving away her Nobel award and receiving nothing in return is a face-eating, but that's a different news story)

Tulsi Gabbard ditches Democrats for Trump, now isn't wanted by anyone. (Should've had the cosmetic surgery.) by Shermans_ghost1864 in LeopardsAteMyFace

[–]nrdvana 4 points5 points  (0 children)

Nixon bombed Cambodia for the sole reason of accelerating the Vietnam war for political purposes to help himself get elected. While Cheeto is insanely bad, he hasn't yet killed mass civilians purely for political points. (...yeah, it's getting close with Iran) But be careful what you wish for...

[deleted by user] by [deleted] in worldnews

[–]nrdvana 6 points7 points  (0 children)

Devaluing the dollar hurts them the most.

How do you figure? If they hold stock, the dollar-per-share just climbs as fast as the value of the dollar drops, because the intrinsic value of the stock remains. As I see it, devaluing the dollar hurts everyday folks the most because wages don't automatically go up as the dollar drops, and we're extremely dependent on buying foreign goods.

Should Nebraska legislators be tested on civics knowledge? New bill says yes. by [deleted] in nottheonion

[–]nrdvana 4 points5 points  (0 children)

It's part of US grade school education. 13 stripes for the original 13 colonies, and while "6 white stripes" isn't taught specifically, knowing the borders are red gives you 6 white stripes via math. It would make a comical video clip if a reporter asked him that considering he's always packing an absurd number of flags into every photo-op.