HN user

phorese

138 karma
Posts0
Comments51
View on HN
No posts found.

In Icelandic, a compass is a direction-shower, and a microscope a small-watcher.

I find this somehow very poignant :) What exactly does the author think "microscope" means? From Wikipedia:

microscope (from the Ancient Greek: μικρός, mikrós, "small" and σκοπεῖν, skopeîn, "to look" or "see")

As far as I can tell, the network is trained on a specific geometry and must be re-trained if the geometry changes.

The model is trained on a "training set" of various 3D models, and tested on a "test set" of different 3D models. The network can generalize to other 3D models and does not need retraining (see e.g. last part of abstract).

I think what they mean is that they would need to retrain the model if the boundary conditions at the outer boundary of the "studio" (the simulation domain) changed.

If I just want to unpack a function's tuple result, I use "std::tie":

  tuple<int, bool, char> t = make_tuple(1, true, 'a');
  int  n = get<0>(t);
  bool b = get<1>(t);
  char c = get<2>(t);
can be written as
  int  n;
  bool b;
  char c;
  std::tie(n,b,c) = make_tuple(1, true, 'a');
This is not necessarily better or more dynamic, but at least it looks more pythonic (to me). One can even write
  std::tie(n,b,std::ignore) = make_tuple(1, true, 'a');
if not all results are needed!
Netpbm format 11 years ago

Good question :)

I needed a quick way to hack the output of 2D float data (pixel annotations to complement some image) into some legacy C without adding dependencies.

Thanks to CImg, I can read and display the PFM files in 10 lines of my own C++. I thought about just writing a width/height-annotated binary blob instead, but then realized that's really what PFM already is.

I have no idea if anything is really using PFM. I certainly have not found any "big" compatible programs.

Netpbm format 11 years ago

I've been using the PFM format (http://netpbm.sourceforge.net/doc/pfm.html) for a project recently.

It's the most obscure member of the Netpbm family. Almost no image viewer understands it, and no image editor can read or write it. Luckily there's the incredible CImg (http://www.cimg.eu/) lib.

PFM is stored in left to right, bottom to top order pixel. It has exactly one or three channels. One pixel is four bytes. There's an obscure "scale/endianness" parameter to tell you the byte order.

I love it, and I hate it.

"It was a tool for me," Metcalf said. "Like Mom's hot skillet; don't stick your hand on it. Like Dad's power saw; don't stick your finger in it. A gun; don't stand in front of it."

I honestly do not understand how these things are comparable. A skillet is a tool for making food. It does not hurt or kill unless used incorrectly. A power saw is a tool for shaping useful objects. It does not hurt or kill unless used incorrectly. A gun is a tool for killing. Unless it is used incorrectly, it always destroys or hurts or kills.

Would you argue the same way about being allowed to carry mustard gas? Or smallpox? That the freedom to do so is worth more than the immense hurt it is guaranteed to bring on the world?

The U.S.' obsession with firearms is utterly beyond me (I am from Germany). Just my 2 cents.

------------------------------------------------------

  Did I ever tell you that Programmer McCave
  Had twenty-three variables and named them all `a`
   
  Well, the programmer did. And that wasn't a smart thing to do.
  You see, when the programmer wants to add `a` to 2
   
  The programmer doesn't get a number oh no no no
  All twenty-three `a`s cause a buffer overflow
   
  This makes things quite difficult at the McCaves'
  As you can imagine, with so many `a`s.
   
  And often the programmer wishes that, while coding,
  The programmer hadn't ignored that sense of foreboding
   
  And called one of them runCount, And one of them lastNum
  And one of them allSales and another roundSum
   
  And one of them lastId, and another userNames
  And one subnetMask, or numStartedGames
   
  Any old names would actually do
  even if they were just `bar` or `foo`
   
  And adding hyphens or humble underscores
  The programmer could have come up with so many more!
   
  Like read_app_config_from_this_file_name
  But no, the programmer went and called them all the same
   
  If only the programmer hadn't given into the hype
  And used a language strongly typed
   
  The programmer would have avoided this horrible fate
  But didn't and so now it's too late. 
------------------------------------------------------

There, FTFY. People will still think the programmer is a male, but now it's their own damn bias at fault :)

Ah, good call, thanks!

I now think we both got it wrong (but me more so than you): Table 2 specifies "1 min/frame", but the source frame selection happens for output frames, not input frames. Table 1 lists a total of 2189 output frames for the 23700 input frames of the "BIKE 3" sequence, so I guess we're looking at 2189 minutes?

Correct me if I misread anything. Again.

Actually, the article describes a SEP as an actual problem in need of recognition. No matter how much HN becomes redditified, it's still not a real issue, and only affects those who care about it.

So no, it's really just your problem. :P

I hope I didn't just contribute to the problem.

Maybe because too often that's real-life economics, too. It's just not usually about retrieving the item (as comic books might imply).

"Oh no, that dude stole [insert item of low value X]! Let's imprison him and cause [insert vastly larger number Y] in tax dollars to punish him!"

The time regex is, too. In German you can expect to encounter the text fragment

um 6:00 am 05.12. (at 6:00 on 12/05/..)

If i read it correctly, the time regex would extract "6:00 am" as time, but the "am" is wrong (German uses 24h format).

You're right, it doesn't need to be said. Everyone knows you don't drive or commit when drunk. The problem is that "drunk you" might disagree with "sober you", and want to drive/commit anyway.

That's why you install this cool thingy that doesn't let you commit when drunk. Sadly, it's not as easy with cars and drunk drivers...

Being colorblind, the bottom row in Figure 5 is completely useless to me. I can also not distinguish +1000 from -1000 on the left side of Figure 1.

Publishers, please use color only when it's really neccessary, and then please have some colorblind person available for sanity checking! While it might be hard to find someone with the less common variants, you can at least cover red-green.