Return-Path: X-Original-To: apmail-hadoop-hdfs-user-archive@minotaur.apache.org Delivered-To: apmail-hadoop-hdfs-user-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id D1CA9D51F for ; Wed, 21 Nov 2012 19:51:24 +0000 (UTC) Received: (qmail 86987 invoked by uid 500); 21 Nov 2012 19:51:20 -0000 Delivered-To: apmail-hadoop-hdfs-user-archive@hadoop.apache.org Received: (qmail 86770 invoked by uid 500); 21 Nov 2012 19:51:20 -0000 Mailing-List: contact user-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@hadoop.apache.org Delivered-To: mailing list user@hadoop.apache.org Received: (qmail 86760 invoked by uid 99); 21 Nov 2012 19:51:20 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 21 Nov 2012 19:51:20 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of jamalshasha@gmail.com designates 209.85.219.48 as permitted sender) Received: from [209.85.219.48] (HELO mail-oa0-f48.google.com) (209.85.219.48) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 21 Nov 2012 19:51:12 +0000 Received: by mail-oa0-f48.google.com with SMTP id h2so8572244oag.35 for ; Wed, 21 Nov 2012 11:50:51 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=4/N1rJLwbroVGzvGL+VIxVQXS52j/gO7JRiBB5t4cgc=; b=rLxY25ywobMopP0X0Jiu9ImrHg4mEeLbGcvYxJ/igoE0//H3QNwkYnwrZnls790CS5 VxqEa/SX2DpEKw+MnO8nOmJqF1T1VEGGaLvvH55CMQYfS/4Qje9ihJ3itqfgbj9Zaaf4 OAVER59tc4mV04yLRwFbTTRiFWXvDynRgNOqp5K5D4+69CHKgOIELZd5D6njQQX5/CMe rkTZLua3jo9QqXRCO5mpmCjDKHSVcSbL0LOkQjoPpN5QCcYr6hJRJRWNeuxExoIuHQNz J+Be4fu8KJfmNxx1mbqlpIVSZOUvvLWBEsn13PFD+CcBJtbLPYSvxTtn3VJgY3Ql5xPL Hyhw== MIME-Version: 1.0 Received: by 10.182.115.34 with SMTP id jl2mr17140961obb.74.1353527451114; Wed, 21 Nov 2012 11:50:51 -0800 (PST) Received: by 10.60.66.37 with HTTP; Wed, 21 Nov 2012 11:50:51 -0800 (PST) Date: Wed, 21 Nov 2012 14:50:51 -0500 Message-ID: Subject: fundamental doubt From: jamal sasha To: "user@hadoop.apache.org" Content-Type: multipart/alternative; boundary=f46d04448141eadb8c04cf06aa83 X-Virus-Checked: Checked by ClamAV on apache.org --f46d04448141eadb8c04cf06aa83 Content-Type: text/plain; charset=ISO-8859-1 Hi.. I guess i am asking alot of fundamental questions but i thank you guys for taking out time to explain my doubts. So i am able to write map reduce jobs but here is my mydoubt As of now i am writing mappers which emit key and a value This key value is then captured at reducer end and then i process the key and value there. Let's say i want to calculate the average... Key1 value1 Key2 value 2 Key 1 value 3 So the output is something like Key1 average of value 1 and value 3 Key2 average 2 = value 2 Right now in reducer i have to create a dictionary with key as original keys and value is a list. Data = defaultdict(list) == // python usrr But i thought that Mapper takes in the key value pairs and outputs key: ( v1,v2....)and Reducer takes in this key and list of values and returns Key , new value.. So why is the input of reducer the simple output of mapper and not the list of all the values to a particular key or did i understood something. Am i making any sense ?? --f46d04448141eadb8c04cf06aa83 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Hi..
I guess i am asking alot of fundamental questions but i thank you = guys for taking out time to explain my doubts.
So i am able to write map= reduce jobs but here is my mydoubt
As of now i am writing mappers which= emit key and a value
This key value is then captured at reducer end and then i process the key a= nd value there.
Let's say i want to calculate the average...
Key1= value1
Key2 value 2
Key 1 value 3

So the output is something = like
Key1 average of value =A01 and value 3
Key2 average 2 =3D value 2
Right now in reducer i have to create a dictionary with key as original ke= ys and value is a list.
Data =3D defaultdict(list) =3D=3D // python usrr=
But i thought that
Mapper takes in the key value pairs and outputs key: ( v1,v2....)and
Re= ducer takes in this key and list of values and returns
Key , new value.= .

So why is the input of reducer the simple output of mapper and not= the list of all the values to a particular key or did i =A0understood some= thing.
Am i making any sense ?? --f46d04448141eadb8c04cf06aa83--