Live data from Hacker News

Tinygrad

github.com

71–80 of 159 posts

Re: Tinygrad

#71
post #67
post #60

Earlier quoted context omitted.

Why the need to conflate personality traits with skill? If I have a rare disease, I don't care if the doctor is nice. I want them to get the diagnosis correct. Van Gogh painted brilliantly. And he cut off his ear. Eminem is a great rapper. His themes can be violent.

The post I replied to was one about personality traits, not skill.

The poster probably meant that "«it would be nice» - yet largely irrelevant". You can abstract from those "personality traits" as long as """he is one who delivers""" - respectfully saying, as he is not obliged: he provided us with another tool, for our use, for free: he is a benefactor.

Re: Tinygrad

#72
post #63

Earlier quoted context omitted.

You're saving yourself from one kind of golfing, but not all of them. Additionally, I feel like installing an additional tool is kind of against the spirit of 1kLOC simplicity.

I'm getting distinct uses Eclipse to write vogon poetry and Jira Master vibes from you. Any notes on the actual code in the OP beyond the import lines formatting?

I'm sorry to have offended you, but I don't feel personal insults over the README of an open source project are particularly reasonable.

This affects the actual code, too! See, for example, https://github.com/geohot/tinygrad/commit/cfb7a4c41a2b6bcc09..., which includes this gem:

  diff --git a/tinygrad/ops/ops_cpu.py b/tinygrad/ops/ops_cpu.py
  index a454f56f..0686f810 100644
  --- a/tinygrad/ops/ops_cpu.py
  +++ b/tinygrad/ops/ops_cpu.py
  @@ -2,22 +2,15 @@
   from ..tensor import Function
   
   class CPUBuffer(np.ndarray):
  -  def log(x):
  -    return np.log(x)
  -  def exp(x):
  -    return np.exp(x)
  -  def relu(x):
  -    return np.maximum(x, 0)
  -  def expand(x, shp):
  -    return np.broadcast_to(x, shp)
  +  log = lambda x: np.log(x)
  +  exp = lambda x: np.exp(x)
  +  relu = lambda x: np.maximum(x, 0)
  +  expand = lambda x,shp: np.broadcast_to(x, shp)
  +  permute = lambda x,order: x.transpose(order)
  +  type = lambda x,tt: x.astype(tt)
  +  custompad = lambda x,padding: np.pad(x, padding)
     def amax(x, *args, **kwargs):
       return np.amax(x, *args, **kwargs)
  -  def permute(x, order):
  -    return x.transpose(order)
  -  def type(x, tt):
  -    return x.astype(tt)
  -  def custompad(x, padding):
  -    return np.pad(x, padding)
     def toCPU(x):
       return x
     @staticmethod
The "actual code" is being golfed for no other reason than to keep the line count down, for the sake of a promise that never needed to be made. This commit recovered a total of seven lines wherein new code can be added, in exchange for readability. It is not just a quirk, not just some sort of interesting aside like one could argue for suckless' `dwm`: this promise actively makes the code worse over time, for no reason.

Re: Tinygrad

#73
post #36

Earlier quoted context omitted.

Having gone to college and knowing this guy personally from then, you would have a much different opinion... Maybe he has grown up, but back then... yeeesh

I cannot take this criticism seriously unless you are more specific than “yeesh.” If you aren’t willing to be specific then better to not say anything at all.

[deleted]

Re: Tinygrad

#74
post #65

Earlier quoted context omitted.

Everyone should kill their heroes. They almost never live up to the pedestals people place them on. They are all just people and have flaws. They don’t have to be some perfect person to do cool things we can respect.

I respect geohotz' achievements (generally). I would never hold him up as an example of hacker culture, or his persona as one to emulate. There is a difference between these things.

Is hacker culture not filled with "weird jerks"? Linus doesn't qualify? Who does?

Re: Tinygrad

#75

Earlier quoted context omitted.

Having gone to college and knowing this guy personally from then, you would have a much different opinion... Maybe he has grown up, but back then... yeeesh

Who cares if he’s a nice guy?

Talented but bad people breed a new generation of unnecessary untalented bad people.

Re: Tinygrad

#76
post #12

Earlier quoted context omitted.

Completely disagree - limiting lines of code as an ethos makes as much sense as using lines of code written as a business metric. What if they want to add a new feature that takes another ~1000 LoC? Can they just write it as a separate library and include it as a dependency? IMO trying to minimize LoC creates a perverse incentive to split up your package when it might not need it (in the same way maximizing LoC creat…

> What if they want to add a new feature that takes another ~1000 LoC? They don't. The LoC limit exists as much to avoid scope creep and maintain focus as it is about anything else.

This one arguably does have a bit of scope creep it's just in a separate directory.

Re: Tinygrad

#77
How about we show simple admiration and appreciation? We could learn way more if we try to understand the actions rather than criticize. He's a nerd. If we are here we are nerd too. Keep up the nerd sht geohot!

Re: Tinygrad

#78
post #63

Earlier quoted context omitted.

I'm getting distinct uses Eclipse to write vogon poetry and Jira Master vibes from you. Any notes on the actual code in the OP beyond the import lines formatting?

I'm sorry to have offended you, but I don't feel personal insults over the README of an open source project are particularly reasonable. This affects the actual code, too! See, for example, https://github.com/geohot/tinygrad/commit/cfb7a4c41a2b6bcc09... , which includes this gem: diff --git a/tinygrad/ops/ops_cpu.py b/tinygrad/ops/ops_cpu.py index a454f56f..0686f810 100644 --- a/tinygrad/ops/ops_cpu.py +++ b/tinygrad…

No offense taken and no offense intended at all friend.

In my opinion we are down the rabbit hole of arguing style over substance. I just think you are grasping at straws. Tools like black (if there was a just god it would just be part of the language, like gofmt) can easily settle stylistic choices.

Really not worth endlessly debating, what next, tabs vs spaces?

This commit seems fine to me as well. Consider the golfing serves the purpose of "the lols" if you must. Heck this particular commit looks slightly better with the change!

Excessive golfing to the detriment of code quality over time is a well known and wholly irrelevant point to make with something like Tinygrad.

If you are so convinced of what you are saying, fork and rewrite it as verbosely as you prefer and demonstrate some significant improvement to the project quality. Would be insightful.

Re: Tinygrad

#79
I'd like to ship a video game that does machine learning and trains on its experiences with the player. Yes, I know there are many potential problems with this.

What is the best way to ship training code in a game? Do I embed Python and PyTorch or something? Do I code my own NN training algorithm? Do I use a library such as Tinygrad?

Re: Tinygrad

#80
post #68
post #61

Earlier quoted context omitted.

I don't know. I ran the idea of purposely getting addicted to opioids to see if i can quit by my wife and she assured me i was crazy.

This direction goes off-topic, but: look, if you married her, -- either you go along well, hence that she agrees with your opinion is a weak test; -- or you married her to test yourself, which would prove my point. TND; QED. /J

What does TND mean?
Post reply on HN