Hacker News new | past | comments | ask | show | jobs | submit | aschwo's comments login

I'm curious, on the Currying (Standard Library) slide, the author uses `attrgetter` from the `operator` module -- I've always used `getattr` to achieve the same thing. Am I missing something by not using `attrgetter`?


Short answer: not really.

Long answer:

  In [1]: from operator import attrgetter

  In [2]: class Person:
     ...:     def __init__(self, name):
     ...:         self.name = name
     ...:         

  In [3]: me = Person('walrus')

  In [4]: getattr(me, 'name')
  Out[4]: 'walrus'

  In [5]: attrgetter('name')(me)
  Out[5]: 'walrus'
This is potentially useful if you're using `map`:

  In [6]: people = [me, Person('aschwo')]

  In [7]: list(map(lambda obj: getattr(obj, 'name'), people))
  Out[7]: ['walrus', 'aschwo']

  In [8]: list(map(attrgetter('name'), people))
  Out[8]: ['walrus', 'aschwo']
Really, though, the functional programming idioms don't meld too well with Python. I think this is a lot nicer:

  In [9]: [person.name for person in people]
  Out[9]: ['walrus', 'aschwo']


On the last point, a list comprehension is just a much a functional programming idiom--Python got them from Haskell! I use both in my code, whichever is shortest.

PS: map returns a list, no need to call list() on it.


In Python 3, map returns a iterator, not a list:

  In [1]: sq = lambda x: x * x
  
  In [2]: map(sq, [1,2,3,4])
  Out[2]: <builtins.map at 0x2135050>
  
  In [3]: list(_)
  Out[3]: [1, 4, 9, 16]


attrgetter takes an attribute name and returns a function that, when passed an object, returns that attribute from that object. So it's a curried getattr. These are equivalent:

f = attrgetter("some_property")

f = lambda obj: getattr(obj, "some_property")


Having worked on node-graph UIs in the past and used software that relies on this metaphor, it's a dangerous thing to not build in undo/redo support. It's too easy to delete an edge, and spend a bunch of time trying to redo your work. That really pisses off users.

Also, not giving the edges of the graph a direction is a problem -- it's hard to quickly grasp what the 'result' node should be. Ditto for not using fixed-position plugs on the nodes: input plugs should be at the top, outputs at the bottom (or left and right).

In the end, I'm not sure who this is for: if you just want to click a button to deploy some services, it's doubtful that you'll want to muck around with wiring up nodes; and if you're putting these packages together, it'll probably be faster to just use a text editor.


what's the tool they've used to build the UI front-end? Looks nice.


This is seriously cool, but can't there be a better way to embed fragment shaders in javascript for WebGL? Check out this effect: https://github.com/brianchirls/Seriously.js/blob/develop/eff...

Or is there a tool that needs to be created that will compile a fragment shader for WebGL down to .js, kind of like CoffeeScript?

Now all you need is for someone to write an OpenEXR implementation in JS or WebKit and you'll have all you need to build a Nuke killer in the browser. Well, you'll still need the UI framework for the node graph.


You can always write your shaders in Haskell... : http://www.haskell.org/haskellwiki/GPipe


This is a great development for decoding ProRes with non-OSX OSes. What are the legal implications? Will ffmpeg need to pay to license the ProRes codec from Apple? Does Apple even offer a license for the codec?


if ffmpeg worried about patents and licensing, they would have stopped development a long time ago.


Your snarky remark can be read both ways:

  - if ffmpeg [developers] were overly scared about even remote risks of being sued, they'd stop.
  - if ffmpeg [developers] wanted to abide by the law, they'd have to stop.
and the second interpretation is quite unfair IMHO.


I meant it both ways, however the second interpretation is really only true under US law. A lot of parties would want a lot of money to license things, how would they pay?


Haven't they had this for a while (Post Date: August 28, 2008). http://support.apple.com/downloads/Apple_ProRes_QuickTime_De...

However, it's nice that they have it built into ffmpeg now.


It's read only for Windows, so Win apps can't write out a prores file. (In reference to Apple's decoder)


Windows is read only (although clipster somehow manages to write out prores files). There are two licensed products (hardware) that write out prores that I am aware of - ARRI Alexa cameras and AJA ki pro.


The ARRI Alexa records in Apple ProRes 4444 or Apple ProRes 422. I am not sure if they got a license, but they have been doing it a while.


This is awesome! Are you able to implement the physically based specular term and still have acceptable performance?

You'll need the precomputed Beckmann distribution in a texture: http://developer.nvidia.com/node/171


Maybe. I didn't get yet to play with specular term, current one is just vanilla Phong.

There should be still some performance margin left, I tried to tune it to keep 60 fps on my notebook.


And it's done, if you clear cache and reload, it should be using physically based specular term.

Visual difference is quite subtle - skin feels more "silky" and ears are more shiny.

No noticeable degradation of performance.


Exactly! If they had done this before killing off Shake, I bet we'd still have a half decent competitor to Nuke in the high end compositing space, instead of nothing.

Instead, Apple killed Shake and let big studios buy the source code from them so they could continue to use it.

http://en.wikipedia.org/wiki/Shake_(software)#History


Apple used the Shake team to build Motion, an application which a much larger user base.


What? Shake was THE node based compositing app!

There is a massive difference to Motion and the highend compositing apps like Shake, Nuke, Fusion, Softimage(Illusion+Matador=FXTree), Houdini(COPS), Flame, Toxik(Autodesk Composite). After Effects and Combustion are time-line based like Motion, but Motion doesn't begin to compare to them. Even Blender has fantastic compositing tools.

Shake was serious business. It's last well known big project was 'The Dark Knight' which Framestore CFC mangled a 64bit wrapper around it to better manage the 8k-frame workload. Shake was ported to Intel, then killed off, with no intention to take it to 64bit. I don't think you can buy the source code anymore.


The Foundry is absolutely kicking everyone else's ass with Nuke. They have an interesting business model as well: don't do much research in house, instead work with studios with big R&D budgets and license their tools when they're mature, bringing it to a wider audience.

They've done it with Digital Domain and Nuke (compositing), Weta and Mari (3d paint), and now Sony and Katana (lighting).


pretty much everyone is on After Effects these days instead


Shake was the king. But now the industries have Nuke. The king is dead long live the king!


I've known more than one colleague that has commuted from Portland to the Bay Area. In each case they were older men with wives and children that didn't want to (or couldn't) leave Portland. They rented small, cheap places during the week then spent the weekends at home with their families.


Disney Animation also posts its papers online: http://www.disneyanimation.com/library/list.html

I can't find similar pages for PDI/Dreamworks or Blue Sky.

If this stuff interests you, check out the SIGGRAPH 2011 papers: http://kesen.realtimerendering.com/sig2011.html


We've also been putting stuff up on github:

https://github.com/wdas

http://ptex.us/


Ptex is awesome! Any chance Disney's hair tools will get open sourced?


Even when considering professional cameras, it's more about the size of the sensor than raw megapixel output:

"Bigger chips mean so many good things. Big chips mean shallower depth-of-field at equivalent settings. Big chips mean big pixels, which means more light hits each photosite. More light means less gain, less noise per pixel. Less noise means more dynamic range. Bigger chips mean better pictures."

http://prolost.blogspot.com/2008/07/panasonic-is-my-hero.htm...

http://rebelsguide.com/dl/sensorSizes_06_cheatSheet.png


Reminds me of this last.fm visualization by Lee Byron: http://megamu.com/lastfm/


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: