HN user

Corazoor

126 karma
Posts0
Comments53
View on HN
No posts found.

As far as I can tell: yes. The top z-layer of designated stairs will always become pure down, the bottom layer pure up.

But I think you can get around that by designating one more z-level than you need, and then removing that. Blueprint mode or designation priorities might also work.

Tell you what, I am going to try now, will post my results shortly.

Edit: Yes this works. After finishing the designation, it will change to the corresponding stair type. By doing one more z-level, you move the "down/up only" layer there, and can remove it. The designations in the level below will not change as a result.

For anyone wondering: Yes, this is still an improvement over the old way of doing it.

I want to point out that none of your points are an actual indicator of how good someone is at programming. They are important in the context of a job, especially in a team, but not for actual coding. So its really two different things we are talking about here.

For Want of a JOIN 4 years ago

Most likely, yes. Combined indexes are real cool, because if the database can satisfy a join only from the index, it can usually perform it completely in memory, instead of having to do a table scan/hitting the disk for the values.

Another trick people usually shy away from: temporary tables. It might seem slow and wasteful to create a table (plus indices) just to store results for a fraction of a second, but for very large tables with large indices, creating a smaller index from the baseteable and joining against that can be magnitudes faster!

There is even dedicated syntax for that: CREATE TEMPORARY TABLE. They are local to the connection and will get dropped automatically at the end of the sql session.

They are also great for storing the results of (nondependent) subqueries, because for large sets, not every database is able to find the proper optimizations. Mysql versions < 8 for example.

I really recommend you to try that one. So far I could fix every "query takes too long" problem that resisted other solutions that way.

Yeah thats fair I guess, it IS hard to see whats so special about it.

Imho, it's the same deal as with monads: Outside of pure functional languages with a strong type system there is not much appeal. But for e.g. a Haskell programmer its like the next coming of christ...

But I think it could be very useful if combined with the equivalent of javas checked exceptions, even in other languages.

Something like "fun readFile(Name: Path):String performs FS.open, FS.read, FS.close throws FileNotFound, FileRead, ..."

A bit excessive, but potentially very useful for all kinds of error checking.

Hah, when I wrote that I was thinking of qualifying it a bit better to prevent the very obvious objections.

It really depends on the language and what kind of goto you mean.

But in the context of the post I replied to, yes, because you cannot replace algebraic effects with "neutered" gotos (like the ones in c), you need the equivalent of longjmp, or maybe gosub.

You can obviously design a language where goto does implicitely run finalizers or does similar fancy stuff, but this is again leaving the scope of the original discussion I think...

One big difference: GOTO ist not bound to any scope. Which ist no wonder, its usually just syntactic sugar for an omnipresent assembly instruction: JMP.

Algebraic effects are less general and play nicer with scoped constructs like finalizers and exceptions. The downside is that they work via stack unwindindig, so they incur some performace penalties.

I highly recommend reading the original article - "Algebraic Effects for the Rest of Us". It demonstrates their operation via Javascript by renaming try/catch, and I think it will answer your questions nicely.

Probably by learning how humans have to balance their extremities to remain standing upright. The camera angle with respect to the enviroment is likely a factor too, since errors got larger when outdoors.

Errors are also not exactly small, ~6cm average, although it's more like 1-2 or 5-12, depending on body part. I think this would very likely be noticeable in VR applications, but it is still very impressive accuracy overall.

The question also nicely highlights the disadvantages of trained algorithms: No one knows for sure, and it certainly isn't obvious by looking at the network weights...

On the other hand, when looking at the pictures, I felt like the authors: There should be enough information in there to get at least a good estimate. And it is extremely useful that one can nowadays "just" train a model to confirm such theories.

Nvidia PhysX 5.0 4 years ago

Cyberpunk 2077 at least pushed the rendering part of the engine into next-gen territory: Volumetric lightning and fog almost everywhere, environment reflection on even the smallest water surface and monochromatic light actually turns many surfaces into mirrors. All that in an outdoors setting with a ton of assets and an almost impracticle amount of verticality (no naturally empty half of the Screen). Before that release, most game devs would have told you that this is still impossible on todays hardware.

But that engine also shows that you are not wrong with your remark about consoles holding progress back: The game barely ran on the ps4, and even on the ps5 you won't get stellar framerates... You need a really nice PC to run the thing smoothely...

Yes! The game itself supports [PRINT_MODE:TEXT] in the ini. Depending on the version you might need a virtual x server to trick the game into starting though.

Used that to run it via wine + quemu on my android phone, at a whopping 5fps at embark. Didn't play for long, but was totally worth it!

No need to assume, it's publicly documented history: The 1969-1974 German goverment of Willy Brandt pursued a new foreign policy towards the Soviet Union, "Neue Ostpolitik". Part of that strategy was to build a system of mutual economic dependency, so that neither the german nor the soviet side would have any interest in going to war against each other.

And while Brandt was eventually replaced by the more conservative (but still social democrat) Helmut Schmidt, the general strategy of mutual economic dependency was upheld, and contributed to the eventual reunion of both Germanies.

In general, back then this strategy worked so well, that even the chancelors from the conservative CDU didn't feel compelled to change it.

Even Merkel, while far more cool and restrained towards russia than her predecessor, did not really change much in that regard. Kinda expected from a conservative though...

The categorical imperative (kinda) ALWAYS works for a single action, thats the real power of it. No matter the situation, applying Kants reasoning to a possible action will always give you a definite answer - Moral or Immoral.

It is actually rather easy to apply: If you can generalize an action (i.e. "what would happen if everyone does this in this situation") without contradiction, then it is moral. Otherwise not.

What it cannot do is weigh two actions against each other: Lying is immoral, but so is treason. You might be forced to break one principle to protect the other.

Kant is kinda famous for taking extremist views in these circumstances. He regarded lying as the worst kind of immorality. Which, with a bit of hindsight, leads to the questionable stance, that it is worse to lie to a nazi, than to protect and harbor a jew from death. Obviously not a popular stance nowadays, and probably not even back then...

But you can fix that by applying a different 'order' to the individual principles. Modern kantian theories heavily focus on these parts.

I'm not sure if you can dismiss context entirely when thinking about a single action, I have the feeling that not. But on the other hand, I cannot think of an example where context does matter, but does not simultaniously pit two moral principles against each other... The answer to your first question kinda hinges on that...

About the loner part: Kant was among the most influentual figures in the european enlightenment movement, he wrote the very influental pamphlet "What is the enlightenment", and he regularly held lectures at various universities. I dunno if he was an introvert, but he certainly didn't avoid society or discussions.

He was a racist, though. Even made money through questionable lectures on the inferiority of non white races. Not that uncommon (and widely accepted) in Germany at that time, but yeah... Great intellectual, an actual liberal in many ways, but still a shitty asshole in many others...

And for academic vs practical: Another name for the whole branch of moral philosophy is "practical philosophy". It is not possible to make an actual useful distinction between academic and practical application of morality. The questions are the same, the reasoning is the same. Only difference is if you have to actually go through with your choices, which makes it emotionally different, but not logically...

I'm a bit of a Kant fan, but here are some telling quotes from wikipedia: (Not all about his moral phlosophy thoguh) "Kant's influence on Western thought has been profound." "Kant is credited with having innovated the way philosophical inquiry has been carried at least up to the early nineteenth century" "Arthur Schopenhauer was strongly influenced by Kant's transcendental idealism." "With his Perpetual Peace: A Philosophical Sketch, Kant is considered to have foreshadowed many of the ideas that have come to form the democratic peace theory, one of the main controversies in political science" "Jürgen Habermas and John Rawls are two significant political and moral philosophers whose work is strongly influenced by Kant's moral philosophy." "Kant's influence also has extended to the social, behavioral, and physical sciences, as in the sociology of Max Weber, the psychology of Jean Piaget and Carl Gustav Jung,[199][200] and the linguistics of Noam Chomsky." "Kant's work on mathematics and synthetic a priori knowledge is also cited by theoretical physicist Albert Einstein as an early influence on his intellectual development, but which he later criticised heavily and rejected."

Kants moral philosophy (the categorical imperative) is deontological, which means it is based on the action (and only the action) itself.

Intent and Outcome are important in other moral philosophies, but for Kant these were hypothetical imperatives: Nothing more than mere whishes, nothing concrete.

For him, moral philosophy should be based on concrete, testable tenets, which have to be unconditionally true (categorical) and are always required (imperative).

While one might disagree with that worldview, Kant's work on this kind of moral philosophy was so comprehensive and - quite franky - logically sound, that to this very day any deontological philosopher or moral theory is still called "Kantian" or in "Kantian tradition"...

To come back to your question: While dismissing intent and outcome can be seen as a limitation of Kant's view, it also provides a very strong logical underpinning for the whole philosophy. Of all the moral philosophies, it's the one based most on pure reasoning.

Of course, it qickly breaks down when pitting two moral wrongs against each other (ratting out innocents vs. lying to state forces, various trolley problems etc.), but any moral system seems to get in trouble in these kind of situations.

Depending on the clock frequency of the chip, a change in the length of signal carrying lines (i.e. from one gate to the next) can already result in a phase/timing shift that ruins the circuit. It is not uncommon to have data lanes that are longer than necessary, just to keep signals on different lines in sync.

Even if you ignore all the other complications when switching nodes (and there are a LOT!), this alone prevents simple downscaling of circuits. It is very likely that after downscaling at least part of the interconnects have to be rerouted.

As for automation of that task: It's the traveling salesman problem in disguise. Which means that you CAN automate it, and there exists software for that purpose, but the result are hardly optimal, and most likely leave quite a lot of possible performance on the table.

Add to that all the other necessary changes when switching nodes, and it becomes fairly obvious that switching nodes, even if only porting 1:1, is a massive effort that can easily span YEARS.

You cannot separate the morality of an action from it's usefulness to business, thats putting the horse before the cart.

Modifying your last sentence illustrates this nicely:

You can argue that slavery is a net negative for the world or that it's evil or whatever you want, but if you frame it as "how can we take steps to make things better for slaves without completely destroying the way business on the world make money" then I think the current path is a reasonable one.

Driving with D 5 years ago

Maybe something changed, but I thought array concatenation with ~, associative and dynamic arrays as well as exceptions rely on the GC as well.

It's a short list, for sure, but thats not the point: Anyone looking into using D without GC will see that there are some language features that require special care.

At that point it becomes a valid question why one should learn about the pitfalls of GC free D, when one already knows that about the currently used language.

GC free D is low friction, but seemingly not low enough for uptake from interested parties.

Driving with D 5 years ago

I dunno why you assume that I don't know about them...

Apart from that, they came pretty late, are still in experimental, and don't change the fact that only a subset of D is usable without GC.

I very much like D, I really do, but I never encountered a usecase where the pros of using D outweight the cons. It sits in a very very weird spot design-wise, and while Walter and Andrei tried their best to get rid of the most common problems, not much of that effort resulted in actual useful change: Still no other GC than the default linear one, the stdlib is still not fully noGC usable (and probably never will), and "proper" compile time functions are still not done, after quite a few years now...

Which is a shame, D is very close to being the perfect C++ replacement.

Driving with D 5 years ago

Certainly not the sole reason, but the mix of language features puts it into a weird spot: You have great control over memory layout and can easily embed assembler, which would be perfect for performance sensitive software like games. Yet "default" D comes with a garbage collector and - more importantly - language features that require said GC.

If you want to go the noGC route, you have to refrain from using certain language constructs, which puts you in a similar spot as with C++...

And if you actually want a GC, you might find the simple linear allocator of D to be lacking...

D is a very cool language, but it is also a lot like QTified C++... Which, well, already exists...

The ruling by the german constitutional court was definitely not judicial overreach.

For one because rejecting laws on constitutional grounds is the main purpose of that court.

But more importantly, the court started it's argument with the observation that the german goverment and parliament committed themselves to the goal of co2 reduction, by signing and ratifying the kyoto protocol.

From that follows that it is quite unfair (unconstitutional even) to put the major portion of reductions towards the end of the deadline, effectively pushing the burden on younger generations.

Measured by their own standards and all that...

I find the argument for this move unconvincing: Nvidias failure to meet demand is somehow the fault of... the customers? But since there are morally aprehensible workloads, it is totally fine to... throttle them? Not prevent or contractually prohibit, as one might expect... And of course it is Nvidia who decicdes on the morals of your workload.

I mean, seriously, how can anyone be ok with that?

I can agree that writing documentation is certainly more boring than writing code, and lazyness tends to play a role in the willingness to complete boring tasks.

But there are many legitimate reasons why one would clarify it as "harder" than programming:

- It requires a different skillset, namely writing.

- It is not uncommon for non-english shops to have a policy of documentation in english. That might be sensible, but complicates the task even further.

- In programming, it suffers from the same problems as math: Natural language is more often than not unsuited to express entirely abstract concepts, at least in concise and easily understandable ways.

- Conversely, natural language often lacks the necessary precision to talk about technical details.

- To alleviate all these problems with language somewhat, you might opt to use diagrams. Which requires yet another skillset.

- It requires time. And quite a lot of it actually. Usually more than you need for the actual programming task. This is why most managers care way less about documentation than they should: They know very well that it detracts time from actual programming tasks.

So sure, people tend to be lazy, but there are certainly good reasons why that happens more often in this area of our work than in others.

Hydrogen brings with it other challenges. Maybe it's easier, maybe it's not. Neither of these two solutions have been deployed at any significant scale so we really don't have a good idea.

We do have a rather good idea. There are several studies and large test facilities both in Europe and the US. Specifically in the area I was mentioning (salt caverns). From wikipedia on hydrogen storage: "Underground hydrogen storage is the practice of hydrogen storage in caverns, salt domes and depleted oil and gas fields. Large quantities of gaseous hydrogen have been stored in caverns by ICI for many years without any difficulties." "Another study referenced by a European staff working paper found that for large scale storage, the cheapest option is hydrogen at €140/MWh for 2,000 hours of storage using an electrolyser, salt cavern storage and combined-cycle power plant."

There is more here: https://en.wikipedia.org/wiki/Hydrogen_storage

Power to gas needs a source of carbon to produce methane. Only if you want to produce syngas (methane).

If you store the resulting hydrogen directly, no carbon source is needed. That makes storage more location dependent, because the cost-competitive options are salt-caverns, but we are talking about long term storage here...

Production of SynGas is more important to replace the current use of ground-pumped methane with CO2 neutral variants.

Also, exist prototype power to gas facilities are ~50% efficient. Even with a 66% efficient combined cycle gas turbine, which is the best we have, net efficiency is ~33%.

Which is why there are proposals to go purely via hydrogen and reversible oxidation cells. That way you can get up to about 70-80%.

But again, we are talking about long term storage. ALL other options of energy storage are more expensive when you reach the "weekly to monthly" storage timeframe. At that timeframe, the low efficiency becomes irrelevant, as storage cost ($/kWh) is dominating, and we are talking about renewables anayway.

That is simply not true.

In order to convert elecricity to methane you first have to REMOVE CO2 from the enviroment. If you subsequently burn that gas, you arrive back at the CO2 level you had before the P2G process.

That of course only works out to net zero when you use co2 that was recently captured, like from waste-biogas or trees.

The big problem with fossil fuels is not directly that they release CO2, it is that they release CO2 that was captured over millenia in the comparatively short timespan of decades.

You can avoid that problem entirely with P2G systems.

but the challenges of needing to store such vast amounts of energy seems like an almost impossible task

Only if you don't look at all available solutions: https://en.wikipedia.org/wiki/Power-to-gas "P2G is often considered the most promising technology for seasonal renewable energy storage"

I dunno why this is such an unknown technique, natural gas storage is a very old and proven technology. Yet it is ommitted from almost any discussion about the subject...

Gödel's Loophole 5 years ago

The constitutional court in germany already made a ruling that specificially rules out removing the protections of article 79. (Correction: It was not the constitutional court, but it is the current interpretation among lawyers and judges.)

The logic is rather sound: The article already protects the principles of articles 1-20, not the articles themselves. So changing article 79 to remove the protections is already touching on these principles, and is therefore inadmissible.