Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #28851
| Path | csiph.com!usenet.pasdenom.info!weretis.net!feeder4.news.weretis.net!cs.uu.nl!news.stack.nl!newsfeed.xs4all.nl!newsfeed6.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail |
|---|---|
| Return-Path | <wanderer@dialup4less.com> |
| X-Original-To | python-list@python.org |
| Delivered-To | python-list@mail.python.org |
| X-Spam-Status | OK 0.002 |
| X-Spam-Evidence | '*H*': 1.00; '*S*': 0.00; 'skip:[ 20': 0.03; 'mrab': 0.05; 'that?': 0.05; '[1,': 0.09; 'to:addr:comp.lang.python': 0.09; 'cc:addr:python-list': 0.10; 'value.': 0.15; '2],': 0.16; '[2,': 0.16; 'dashes.': 0.16; 'decoding': 0.16; 'dots': 0.16; 'numpy': 0.16; 'wrote:': 0.17; '>>>': 0.18; 'code.': 0.20; 'import': 0.21; 'cc:2**0': 0.23; 'monday,': 0.23; 'cc:no real name:2**0': 0.24; 'command': 0.24; 'cc:addr:python.org': 0.25; 'header:In-Reply-To:1': 0.25; 'header:User-Agent:1': 0.26; 'looks': 0.26; 'received:209.85.212': 0.28; 'array': 0.29; 'probably': 0.29; "i'm": 0.29; 'received:google.com': 0.34; 'received:209.85': 0.35; 'there': 0.35; 'but': 0.36; 'should': 0.36; 'received:209': 0.37; 'subject:: ': 0.38; 'think': 0.40; 'maximum': 0.63; 'sum': 0.66; 'skip:n 30': 0.69; 'average.': 0.84; 'stereo': 0.84; 'received:209.85.212.56': 0.91 |
| Newsgroups | comp.lang.python |
| Date | Mon, 10 Sep 2012 13:14:18 -0700 (PDT) |
| In-Reply-To | <mailman.465.1347307911.27098.python-list@python.org> |
| Complaints-To | groups-abuse@google.com |
| Injection-Info | glegroupsg2000goo.googlegroups.com; posting-host=65.205.52.2; posting-account=_dIAQQoAAAB7Yieol6fmkK_HviJUbJt3 |
| References | <de5d9415-f3d8-47b9-bcc2-822dc57fd1d8@googlegroups.com> <mailman.465.1347307911.27098.python-list@python.org> |
| User-Agent | G2/1.0 |
| X-Google-Web-Client | true |
| X-Google-IP | 65.205.52.2 |
| MIME-Version | 1.0 |
| Subject | Re: Numpy combine channels |
| From | Wanderer <wanderer@dialup4less.com> |
| To | comp.lang.python@googlegroups.com |
| Content-Type | text/plain; charset=ISO-8859-1 |
| Cc | python-list@python.org |
| X-BeenThere | python-list@python.org |
| X-Mailman-Version | 2.1.15 |
| Precedence | list |
| List-Id | General discussion list for the Python programming language <python-list.python.org> |
| List-Unsubscribe | <http://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe> |
| List-Archive | <http://mail.python.org/pipermail/python-list/> |
| List-Post | <mailto:python-list@python.org> |
| List-Help | <mailto:python-list-request@python.org?subject=help> |
| List-Subscribe | <http://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe> |
| Message-ID | <mailman.466.1347308061.27098.python-list@python.org> (permalink) |
| Lines | 56 |
| NNTP-Posting-Host | 2001:888:2000:d::a6 |
| X-Trace | 1347308061 news.xs4all.nl 6959 [2001:888:2000:d::a6]:39290 |
| X-Complaints-To | abuse@xs4all.nl |
| Xref | csiph.com comp.lang.python:28851 |
Show key headers only | View raw
On Monday, September 10, 2012 4:12:40 PM UTC-4, MRAB wrote: > On 10/09/2012 20:39, Wanderer wrote: > > > I have an array generated by audiolab of left and right stereo > > > channels. It looks like [[1,1],[1,2],[2,3]]. I would like to combine > > > the left and right channels to get an array [2,3,5]. Is there a numpy > > > command to do that? > > > > > >>> import numpy > > >>> numpy.array([[1,1],[1,2],[2,3]], dtype="i") > > array([[1, 1], > > [1, 2], > > [2, 3]]) > > >>> a[:, 0] > > array([1, 1, 2]) > > >>> a[:, 1] > > array([1, 2, 3]) > > >>> a[:, 0] + a[:, 1] > > array([2, 3, 5]) > > > > But should they be added together to make mono? > > > > Suppose, for example, that both channels have a maximum value. Their > > sum would be _twice_ the maximum. > > > > Therefore, I think that it should probably be the average. > > > > >>> (a[:, 0] + a[:, 1]) / 2 > > array([1, 1, 2]) I'm decoding morse code. So it's CV dots and dashes.
Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Numpy combine channels Wanderer <wanderer@dialup4less.com> - 2012-09-10 12:39 -0700
Re: Numpy combine channels Wanderer <wanderer@dialup4less.com> - 2012-09-10 12:56 -0700
RE: Numpy combine channels Nick Cash <nick.cash@npcinternational.com> - 2012-09-10 19:50 +0000
Re: Numpy combine channels MRAB <python@mrabarnett.plus.com> - 2012-09-10 21:11 +0100
Re: Numpy combine channels Wanderer <wanderer@dialup4less.com> - 2012-09-10 13:14 -0700
Re: Numpy combine channels Wanderer <wanderer@dialup4less.com> - 2012-09-10 13:15 -0700
Re: Numpy combine channels Wanderer <wanderer@dialup4less.com> - 2012-09-10 13:15 -0700
Re: Numpy combine channels Wanderer <wanderer@dialup4less.com> - 2012-09-10 13:14 -0700
Re: Numpy combine channels aahz@pythoncraft.com (Aahz) - 2012-11-09 20:30 -0800
Re: Numpy combine channels Dave Angel <d@davea.name> - 2012-11-10 08:05 -0500
csiph-web