System Message: WARNING/2 (/Users/anas/python/music22/docs/source/core.rst, line 2)

Field list ends without a blank line; unexpected unindent.

core API

Core : Functions useful for all the package.

class music22.core.f0file(path)[source]

A class to manage data files (.txt).

clean_data()[source]

Remove zeros or NaNs in the list.

Paramètres:L (numpy.ndarray) – A numpy list.
Retourne:L – A cleaned numpy list.
Type retourné:numpy.ndarray
get_data()[source]
class music22.core.file(path)[source]

A class to manage files.

Paramètres:path (str) – absolute path of a file.
path

str

The path of the file.

basename

str

The name of the file.

dirname

str

The directory path of the file.

name

str

The name of the file.

extension

str

The extension of the file.

Example

>>> audio = "/Users/anas/Barraq/AUDIO/P0.wav"
>>> A = file(audio)
>>> print A.path
/Users/anas/Barraq/AUDIO/P0.wav
>>> print A.basename
P0.wav
>>> print A.dirname
/Users/anas/Barraq/AUDIO
>>> print A.name
P0
>>> print A.extension
wav
class music22.core.wavfile(path)[source]

A class to manage audio files (.wav).

pitch_extract()[source]

Extracts the fundamental frequencies (f0).

Paramètres:self.wav_path (str) – a path to a .wav file.
Retourne:self.txt_path – a path to a .txt file contraing a list of frequencies.
Type retourné:str