PageRenderTime 98ms CodeModel.GetById 40ms app.highlight 19ms RepoModel.GetById 31ms app.codeStats 0ms

/apidocs/echonest.audio.AudioSegment-class.html

http://echo-nest-remix.googlecode.com/
HTML | 322 lines | 284 code | 15 blank | 23 comment | 0 complexity | 5b5d6bab561ae9f5f611bf07166432ad MD5 | raw file
  1<?xml version="1.0" encoding="ascii"?>
  2<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  3          "DTD/xhtml1-transitional.dtd">
  4<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
  5<head>
  6  <title>echonest.audio.AudioSegment</title>
  7  <link rel="stylesheet" href="epydoc.css" type="text/css" />
  8  <script type="text/javascript" src="epydoc.js"></script>
  9</head>
 10
 11<body bgcolor="white" text="black" link="blue" vlink="#204080"
 12      alink="#204080">
 13<!-- ==================== NAVIGATION BAR ==================== -->
 14<table class="navbar" border="0" width="100%" cellpadding="0"
 15       bgcolor="#a0c0ff" cellspacing="0">
 16  <tr valign="middle">
 17
 18  <!-- Tree link -->
 19      <th>&nbsp;&nbsp;&nbsp;<a
 20        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>
 21
 22  <!-- Index link -->
 23      <th>&nbsp;&nbsp;&nbsp;<a
 24        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>
 25
 26  <!-- Help link -->
 27      <th>&nbsp;&nbsp;&nbsp;<a
 28        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>
 29
 30  <!-- Project homepage -->
 31      <th class="navbar" align="right" width="100%">
 32        <table border="0" cellpadding="0" cellspacing="0">
 33          <tr><th class="navbar" align="center"
 34            ><a class="navbar" target="_top" href="http://code.google.com/p/echo-nest-remix/">Project Homepage</a></th>
 35          </tr></table></th>
 36  </tr>
 37</table>
 38<table width="100%" cellpadding="0" cellspacing="0">
 39  <tr valign="top">
 40    <td width="100%">
 41      <span class="breadcrumbs">
 42        <a href="echonest-module.html">Package&nbsp;echonest</a> ::
 43        <a href="echonest.audio-module.html">Module&nbsp;audio</a> ::
 44        Class&nbsp;AudioSegment
 45      </span>
 46    </td>
 47    <td>
 48      <table cellpadding="0" cellspacing="0">
 49        <!-- hide/show private -->
 50        <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink"
 51    onclick="toggle_private();">hide&nbsp;private</a>]</span></td></tr>
 52        <tr><td align="right"><span class="options"
 53            >[<a href="frames.html" target="_top">frames</a
 54            >]&nbsp;|&nbsp;<a href="echonest.audio.AudioSegment-class.html"
 55            target="_top">no&nbsp;frames</a>]</span></td></tr>
 56      </table>
 57    </td>
 58  </tr>
 59</table>
 60<!-- ==================== CLASS DESCRIPTION ==================== -->
 61<h1 class="epydoc">Class AudioSegment</h1><p class="nomargin-top"><span class="codelink"><a href="echonest.audio-pysrc.html#AudioSegment">source&nbsp;code</a></span></p>
 62<center>
 63
 64</center>
 65<hr />
 66Subclass of <a href="echonest.audio.AudioQuantum-class.html" class="link">AudioQuantum</a> for the data-rich segments returned by
 67the Analyze API.
 68
 69<!-- ==================== INSTANCE METHODS ==================== -->
 70<a name="section-InstanceMethods"></a>
 71<table class="summary" border="1" cellpadding="3"
 72       cellspacing="0" width="100%" bgcolor="white">
 73<tr bgcolor="#70b0f0" class="table-header">
 74  <td colspan="2" class="table-header">
 75    <table border="0" cellpadding="0" cellspacing="0" width="100%">
 76      <tr valign="top">
 77        <td align="left"><span class="table-header">Instance Methods</span></td>
 78        <td align="right" valign="top"
 79         ><span class="options">[<a href="#section-InstanceMethods"
 80         class="privatelink" onclick="toggle_private();"
 81         >hide private</a>]</span></td>
 82      </tr>
 83    </table>
 84  </td>
 85</tr>
 86<tr>
 87    <td width="15%" align="right" valign="top" class="summary">
 88      <span class="summary-type">&nbsp;</span>
 89    </td><td class="summary">
 90      <table width="100%" cellpadding="0" cellspacing="0" border="0">
 91        <tr>
 92          <td><span class="summary-sig"><a href="echonest.audio.AudioSegment-class.html#__init__" class="summary-sig-name">__init__</a>(<span class="summary-sig-arg">self</span>,
 93        <span class="summary-sig-arg">start</span>=<span class="summary-sig-default">0.0</span>,
 94        <span class="summary-sig-arg">duration</span>=<span class="summary-sig-default">0.0</span>,
 95        <span class="summary-sig-arg">pitches</span>=<span class="summary-sig-default">None</span>,
 96        <span class="summary-sig-arg">timbre</span>=<span class="summary-sig-default">None</span>,
 97        <span class="summary-sig-arg">loudness_begin</span>=<span class="summary-sig-default">0.0</span>,
 98        <span class="summary-sig-arg">loudness_max</span>=<span class="summary-sig-default">0.0</span>,
 99        <span class="summary-sig-arg">time_loudness_max</span>=<span class="summary-sig-default">0.0</span>,
100        <span class="summary-sig-arg">loudness_end</span>=<span class="summary-sig-default">None</span>,
101        <span class="summary-sig-arg">kind</span>=<span class="summary-sig-default"><code class="variable-quote">'</code><code class="variable-string">segment</code><code class="variable-quote">'</code></span>,
102        <span class="summary-sig-arg">source</span>=<span class="summary-sig-default">None</span>)</span><br />
103      Initializes an <a href="echonest.audio.AudioSegment-class.html" class="link">AudioSegment</a>.</td>
104          <td align="right" valign="top">
105            <span class="codelink"><a href="echonest.audio-pysrc.html#AudioSegment.__init__">source&nbsp;code</a></span>
106            
107          </td>
108        </tr>
109      </table>
110      
111    </td>
112  </tr>
113  <tr>
114    <td colspan="2" class="summary">
115    <p class="indent-wrapped-lines"><b>Inherited from <code><a href="echonest.audio.AudioQuantum-class.html">AudioQuantum</a></code></b>:
116      <code><a href="echonest.audio.AudioQuantum-class.html#__getstate__">__getstate__</a></code>,
117      <code><a href="echonest.audio.AudioQuantum-class.html#__repr__">__repr__</a></code>,
118      <code><a href="echonest.audio.AudioQuantum-class.html#__str__">__str__</a></code>,
119      <code><a href="echonest.audio.AudioQuantum-class.html#absolute_context">absolute_context</a></code>,
120      <code><a href="echonest.audio.AudioQuantum-class.html#children">children</a></code>,
121      <code><a href="echonest.audio.AudioQuantum-class.html#context_string">context_string</a></code>,
122      <code><a href="echonest.audio.AudioQuantum-class.html#get_end">get_end</a></code>,
123      <code><a href="echonest.audio.AudioQuantum-class.html#get_source">get_source</a></code>,
124      <code><a href="echonest.audio.AudioQuantum-class.html#group">group</a></code>,
125      <code><a href="echonest.audio.AudioQuantum-class.html#local_context">local_context</a></code>,
126      <code><a href="echonest.audio.AudioQuantum-class.html#next">next</a></code>,
127      <code><a href="echonest.audio.AudioQuantum-class.html#parent">parent</a></code>,
128      <code><a href="echonest.audio.AudioQuantum-class.html#prev">prev</a></code>,
129      <code><a href="echonest.audio.AudioQuantum-class.html#render">render</a></code>,
130      <code><a href="echonest.audio.AudioQuantum-class.html#set_source">set_source</a></code>,
131      <code><a href="echonest.audio.AudioQuantum-class.html#toxml">toxml</a></code>
132      </p>
133    <p class="indent-wrapped-lines"><b>Inherited from <code><a href="echonest.audio.AudioRenderable-class.html">AudioRenderable</a></code></b>:
134      <code><a href="echonest.audio.AudioRenderable-class.html#encode">encode</a></code>,
135      <code><a href="echonest.audio.AudioRenderable-class.html#resolve_source">resolve_source</a></code>,
136      <code><a href="echonest.audio.AudioRenderable-class.html#sources">sources</a></code>
137      </p>
138    <p class="indent-wrapped-lines"><b>Inherited from <code>object</code></b>:
139      <code>__delattr__</code>,
140      <code>__format__</code>,
141      <code>__getattribute__</code>,
142      <code>__hash__</code>,
143      <code>__new__</code>,
144      <code>__reduce__</code>,
145      <code>__reduce_ex__</code>,
146      <code>__setattr__</code>,
147      <code>__sizeof__</code>,
148      <code>__subclasshook__</code>
149      </p>
150    </td>
151  </tr>
152</table>
153<!-- ==================== STATIC METHODS ==================== -->
154<a name="section-StaticMethods"></a>
155<table class="summary" border="1" cellpadding="3"
156       cellspacing="0" width="100%" bgcolor="white">
157<tr bgcolor="#70b0f0" class="table-header">
158  <td colspan="2" class="table-header">
159    <table border="0" cellpadding="0" cellspacing="0" width="100%">
160      <tr valign="top">
161        <td align="left"><span class="table-header">Static Methods</span></td>
162        <td align="right" valign="top"
163         ><span class="options">[<a href="#section-StaticMethods"
164         class="privatelink" onclick="toggle_private();"
165         >hide private</a>]</span></td>
166      </tr>
167    </table>
168  </td>
169</tr>
170  <tr>
171    <td colspan="2" class="summary">
172    <p class="indent-wrapped-lines"><b>Inherited from <code><a href="echonest.audio.AudioRenderable-class.html">AudioRenderable</a></code></b>:
173      <code><a href="echonest.audio.AudioRenderable-class.html#init_audio_data">init_audio_data</a></code>
174      </p>
175    </td>
176  </tr>
177</table>
178<!-- ==================== PROPERTIES ==================== -->
179<a name="section-Properties"></a>
180<table class="summary" border="1" cellpadding="3"
181       cellspacing="0" width="100%" bgcolor="white">
182<tr bgcolor="#70b0f0" class="table-header">
183  <td colspan="2" class="table-header">
184    <table border="0" cellpadding="0" cellspacing="0" width="100%">
185      <tr valign="top">
186        <td align="left"><span class="table-header">Properties</span></td>
187        <td align="right" valign="top"
188         ><span class="options">[<a href="#section-Properties"
189         class="privatelink" onclick="toggle_private();"
190         >hide private</a>]</span></td>
191      </tr>
192    </table>
193  </td>
194</tr>
195  <tr>
196    <td colspan="2" class="summary">
197    <p class="indent-wrapped-lines"><b>Inherited from <code><a href="echonest.audio.AudioQuantum-class.html">AudioQuantum</a></code></b>:
198      <code><a href="echonest.audio.AudioQuantum-class.html#end">end</a></code>,
199      <code><a href="echonest.audio.AudioQuantum-class.html#source">source</a></code>
200      </p>
201    <p class="indent-wrapped-lines"><b>Inherited from <code>object</code></b>:
202      <code>__class__</code>
203      </p>
204    </td>
205  </tr>
206</table>
207<!-- ==================== METHOD DETAILS ==================== -->
208<a name="section-MethodDetails"></a>
209<table class="details" border="1" cellpadding="3"
210       cellspacing="0" width="100%" bgcolor="white">
211<tr bgcolor="#70b0f0" class="table-header">
212  <td colspan="2" class="table-header">
213    <table border="0" cellpadding="0" cellspacing="0" width="100%">
214      <tr valign="top">
215        <td align="left"><span class="table-header">Method Details</span></td>
216        <td align="right" valign="top"
217         ><span class="options">[<a href="#section-MethodDetails"
218         class="privatelink" onclick="toggle_private();"
219         >hide private</a>]</span></td>
220      </tr>
221    </table>
222  </td>
223</tr>
224</table>
225<a name="__init__"></a>
226<div>
227<table class="details" border="1" cellpadding="3"
228       cellspacing="0" width="100%" bgcolor="white">
229<tr><td>
230  <table width="100%" cellpadding="0" cellspacing="0" border="0">
231  <tr valign="top"><td>
232  <h3 class="epydoc"><span class="sig"><span class="sig-name">__init__</span>(<span class="sig-arg">self</span>,
233        <span class="sig-arg">start</span>=<span class="sig-default">0.0</span>,
234        <span class="sig-arg">duration</span>=<span class="sig-default">0.0</span>,
235        <span class="sig-arg">pitches</span>=<span class="sig-default">None</span>,
236        <span class="sig-arg">timbre</span>=<span class="sig-default">None</span>,
237        <span class="sig-arg">loudness_begin</span>=<span class="sig-default">0.0</span>,
238        <span class="sig-arg">loudness_max</span>=<span class="sig-default">0.0</span>,
239        <span class="sig-arg">time_loudness_max</span>=<span class="sig-default">0.0</span>,
240        <span class="sig-arg">loudness_end</span>=<span class="sig-default">None</span>,
241        <span class="sig-arg">kind</span>=<span class="sig-default"><code class="variable-quote">'</code><code class="variable-string">segment</code><code class="variable-quote">'</code></span>,
242        <span class="sig-arg">source</span>=<span class="sig-default">None</span>)</span>
243    <br /><em class="fname">(Constructor)</em>
244  </h3>
245  </td><td align="right" valign="top"
246    ><span class="codelink"><a href="echonest.audio-pysrc.html#AudioSegment.__init__">source&nbsp;code</a></span>&nbsp;
247    </td>
248  </tr></table>
249  
250  Initializes an <a href="echonest.audio.AudioSegment-class.html" class="link">AudioSegment</a>.
251  <dl class="fields">
252    <dt>Parameters:</dt>
253    <dd><ul class="nomargin-top">
254        <li><strong class="pname"><code>start</code></strong> - offset from start of the track, in seconds</li>
255        <li><strong class="pname"><code>duration</code></strong> - duration of the <a href="echonest.audio.AudioSegment-class.html" class="link">AudioSegment</a>, in seconds</li>
256        <li><strong class="pname"><code>pitches</code></strong> - a twelve-element list with relative loudnesses of each
257pitch class, from C (pitches[0]) to B (pitches[11])</li>
258        <li><strong class="pname"><code>timbre</code></strong> - a twelve-element list with the loudness of each of a
259principal component of time and/or frequency profile</li>
260        <li><strong class="pname"><code>kind</code></strong> - string identifying the kind of AudioQuantum: &quot;segment&quot;</li>
261        <li><strong class="pname"><code>loudness_begin</code></strong> - loudness in dB at the start of the segment</li>
262        <li><strong class="pname"><code>loudness_max</code></strong> - loudness in dB at the loudest moment of the
263segment</li>
264        <li><strong class="pname"><code>time_loudness_max</code></strong> - time (in sec from start of segment) of
265loudest moment</li>
266        <li><strong class="pname"><code>loudness_end</code></strong> - loudness at end of segment (if it is given)</li>
267    </ul></dd>
268    <dt>Overrides:
269        object.__init__
270    </dt>
271  </dl>
272</td></tr></table>
273</div>
274<br />
275<!-- ==================== NAVIGATION BAR ==================== -->
276<table class="navbar" border="0" width="100%" cellpadding="0"
277       bgcolor="#a0c0ff" cellspacing="0">
278  <tr valign="middle">
279
280  <!-- Tree link -->
281      <th>&nbsp;&nbsp;&nbsp;<a
282        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>
283
284  <!-- Index link -->
285      <th>&nbsp;&nbsp;&nbsp;<a
286        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>
287
288  <!-- Help link -->
289      <th>&nbsp;&nbsp;&nbsp;<a
290        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>
291
292  <!-- Project homepage -->
293      <th class="navbar" align="right" width="100%">
294        <table border="0" cellpadding="0" cellspacing="0">
295          <tr><th class="navbar" align="center"
296            ><a class="navbar" target="_top" href="http://code.google.com/p/echo-nest-remix/">Project Homepage</a></th>
297          </tr></table></th>
298  </tr>
299</table>
300<table border="0" cellpadding="0" cellspacing="0" width="100%%">
301  <tr>
302    <td align="left" class="footer">
303    Generated by Epydoc 3.0.1 on Wed Sep  1 16:08:58 2010
304    </td>
305    <td align="right" class="footer">
306      <a target="mainFrame" href="http://epydoc.sourceforge.net"
307        >http://epydoc.sourceforge.net</a>
308    </td>
309  </tr>
310</table>
311
312<script type="text/javascript">
313  <!--
314  // Private objects are initially displayed (because if
315  // javascript is turned off then we want them to be
316  // visible); but by default, we want to hide them.  So hide
317  // them unless we have a cookie that says to show them.
318  checkCookie();
319  // -->
320</script>
321</body>
322</html>