The usual word counting example would look like this:
@map(produces=['word'])
def split_lines(tuple):
for word in tuple.get('line').split():
yield [word]
def main():
...
input | split_lines | GroupBy('word') | Count() | output
....
Decorators are used to decorate functions to be used in flows, pipes
are chained together with the '|' operator, and merged with '&' in
joins.
PyCascading is open source, and hosted at https://github.com/twitter/pycascading
. Please see the examples folder for usage patterns, and submit any
questions or reports to the cascading-user list.
Happy hacking,
Gabor
chris
> --
> You received this message because you are subscribed to the Google Groups "cascading-user" group.
> To post to this group, send email to cascadi...@googlegroups.com.
> To unsubscribe from this group, send email to cascading-use...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/cascading-user?hl=en.
>
--
Chris K Wensel
ch...@concurrentinc.com
http://concurrentinc.com