parselmouth.Pitch

Contents

parselmouth.Pitch#

class parselmouth.Pitch#

Bases: TimeFrameSampled, Sampled

Methods

__init__

copy

count_differences

count_voiced_frames

fifth_down

fifth_up

formula

frame_number_to_time

get_end_time

get_frame

get_frame_number_from_time

get_mean_absolute_slope

get_number_of_frames

get_slope_without_octave_jumps

get_start_time

get_time_from_frame_number

get_time_step

get_total_duration

get_value_at_time

get_value_in_frame

info

interpolate

kill_octave_jumps

octave_down

octave_up

path_finder

read

Read a file into a parselmouth.Data object.

save

save_as_binary_file

save_as_short_text_file

save_as_text_file

scale_times_by

scale_times_to

scale_x_by

scale_x_to

shift_times_by

shift_times_to

shift_x_by

shift_x_to

smooth

step

subtract_linear_fit

t_bins

t_grid

time_to_frame_number

to_array

to_matrix

to_sound_hum

to_sound_pulses

to_sound_sine

ts

unvoice

x_bins

x_grid

xs

Attributes

ceiling

centre_time

class_name

dt

duration

dx

end_time

full_name

max_n_candidates

n_frames

name

nt

nx

selected

selected_array

start_time

t1

time_range

time_step

tmax

tmin

total_duration

trange

x1

xmax

xmin

xrange

class Candidate#

Bases: pybind11_object

__init__(*args, **kwargs)#
__new__(**kwargs)#
property frequency#
property strength#
class FileFormat#

Bases: pybind11_object

__eq__(self: object, other: object) bool#
__hash__(self: object) int#
__index__(self: parselmouth.Data.FileFormat) int#
__init__(self: parselmouth.Data.FileFormat, value: int) None#
__init__(self: parselmouth.Data.FileFormat, arg0: str) None
__int__(self: parselmouth.Data.FileFormat) int#
__ne__(self: object, other: object) bool#
__new__(**kwargs)#
__repr__(self: object) str#
__str__()#

name(self: handle) -> str

BINARY = <FileFormat.BINARY: 2>#
SHORT_TEXT = <FileFormat.SHORT_TEXT: 1>#
TEXT = <FileFormat.TEXT: 0>#
property name#
property value#
class Frame#

Bases: pybind11_object

__getitem__(self: parselmouth.Pitch.Frame, i: int) parselmouth.Pitch.Candidate#
__init__(*args, **kwargs)#
__len__(self: parselmouth.Pitch.Frame) int#
__new__(**kwargs)#
as_array(self: parselmouth.Pitch.Frame) numpy.ndarray#
select(self: parselmouth.Pitch.Frame, candidate: parselmouth.Pitch.Candidate) None#
select(self: parselmouth.Pitch.Frame, i: int) None
unvoice(self: parselmouth.Pitch.Frame) None#
property candidates#
property intensity#
property selected#
__copy__(self: parselmouth.Data) parselmouth.Data#
__deepcopy__(self: parselmouth.Data, memo: dict) parselmouth.Data#
__eq__(self: parselmouth.Data, other: parselmouth.Data) bool#
__getitem__(self: parselmouth.Pitch, i: int) parselmouth.Pitch.Frame#
__getitem__(self: parselmouth.Pitch, ij: Tuple[int, int]) parselmouth.Pitch.Candidate
__init__(*args, **kwargs)#
__iter__(self: parselmouth.Pitch) Iterator#
__len__(self: parselmouth.Sampled) int#
__ne__(self: parselmouth.Data, other: parselmouth.Data) bool#
__new__(**kwargs)#
__str__(self: parselmouth.Thing) str#
copy(self: parselmouth.Data) parselmouth.Data#
count_differences(self: parselmouth.Pitch, other: parselmouth.Pitch) str#
count_voiced_frames(self: parselmouth.Pitch) int#
fifth_down(self: parselmouth.Pitch, from_time: float | None = None, to_time: float | None = None) None#
fifth_up(self: parselmouth.Pitch, from_time: float | None = None, to_time: float | None = None) None#
formula(self: parselmouth.Pitch, formula: str) None#
frame_number_to_time(self: parselmouth.Sampled, frame_number: Positive[int]) float#
get_end_time(self: parselmouth.Function) float#
get_frame(self: parselmouth.Pitch, frame_number: Positive[int]) parselmouth.Pitch.Frame#
get_frame_number_from_time(self: parselmouth.Sampled, time: float) float#
get_mean_absolute_slope(self: parselmouth.Pitch, unit: parselmouth.PitchUnit = <PitchUnit.HERTZ: 0>) float#
get_number_of_frames(self: parselmouth.Sampled) int#
get_slope_without_octave_jumps(self: parselmouth.Pitch) float#
get_start_time(self: parselmouth.Function) float#
get_time_from_frame_number(self: parselmouth.Sampled, frame_number: Positive[int]) float#
get_time_step(self: parselmouth.Sampled) float#
get_total_duration(self: parselmouth.Function) float#
get_value_at_time(self: parselmouth.Pitch, time: float, unit: parselmouth.PitchUnit = <PitchUnit.HERTZ: 0>, interpolation: parselmouth.ValueInterpolation = <ValueInterpolation.LINEAR: 1>) float#
get_value_in_frame(self: parselmouth.Pitch, frame_number: int, unit: parselmouth.PitchUnit = <PitchUnit.HERTZ: 0>) float#
info(self: parselmouth.Thing) str#
interpolate(self: parselmouth.Pitch) parselmouth.Pitch#
kill_octave_jumps(self: parselmouth.Pitch) parselmouth.Pitch#
octave_down(self: parselmouth.Pitch, from_time: float | None = None, to_time: float | None = None) None#
octave_up(self: parselmouth.Pitch, from_time: float | None = None, to_time: float | None = None) None#
path_finder(self: parselmouth.Pitch, silence_threshold: float = 0.03, voicing_threshold: float = 0.45, octave_cost: float = 0.01, octave_jump_cost: float = 0.35, voiced_unvoiced_cost: float = 0.14, ceiling: Positive[float] = 600.0, pull_formants: bool = False) None#
static read(file_path: str) parselmouth.Data#

Read a file into a parselmouth.Data object.

Parameters:

file_path (str) – The path of the file on disk to read.

Returns:

The Praat Data object that was read.

Return type:

parselmouth.Data

save(self: parselmouth.Data, file_path: str, format: parselmouth.Data.FileFormat = <FileFormat.TEXT: 0>) None#
save_as_binary_file(self: parselmouth.Data, file_path: str) None#
save_as_short_text_file(self: parselmouth.Data, file_path: str) None#
save_as_text_file(self: parselmouth.Data, file_path: str) None#
scale_times_by(self: parselmouth.Function, scale: Positive[float]) None#
scale_times_to(self: parselmouth.Function, new_start_time: float, new_end_time: float) None#
scale_x_by(self: parselmouth.Function, scale: Positive[float]) None#
scale_x_to(self: parselmouth.Function, new_xmin: float, new_xmax: float) None#
shift_times_by(self: parselmouth.Function, seconds: float) None#
shift_times_to(self: parselmouth.Function, time: float, new_time: float) None#
shift_times_to(self: parselmouth.Function, time: str, new_time: float) None
shift_x_by(self: parselmouth.Function, shift: float) None#
shift_x_to(self: parselmouth.Function, x: float, new_x: float) None#
smooth(self: parselmouth.Pitch, bandwidth: Positive[float] = 10.0) parselmouth.Pitch#
step(self: parselmouth.Pitch, step: float, precision: Positive[float] = 0.1, from_time: float | None = None, to_time: float | None = None) None#
subtract_linear_fit(self: parselmouth.Pitch, unit: parselmouth.PitchUnit = <PitchUnit.HERTZ: 0>) parselmouth.Pitch#
t_bins(self: parselmouth.Sampled) numpy.ndarray[numpy.float64]#
t_grid(self: parselmouth.Sampled) numpy.ndarray[numpy.float64]#
time_to_frame_number(self: parselmouth.Sampled, time: float) float#
to_array(self: parselmouth.Pitch) numpy.ndarray[parselmouth.Pitch.Candidate]#
to_matrix(self: parselmouth.Pitch) parselmouth.Matrix#
to_sound_hum(self: parselmouth.Pitch, from_time: float | None = None, to_time: float | None = None) parselmouth.Sound#
to_sound_pulses(self: parselmouth.Pitch, from_time: float | None = None, to_time: float | None = None) parselmouth.Sound#
to_sound_sine(self: parselmouth.Pitch, from_time: float | None = None, to_time: float | None = None, sampling_frequency: Positive[float] = 44100.0, round_to_nearest_zero_crossing: float = True) parselmouth.Sound#
ts(self: parselmouth.Sampled) numpy.ndarray[numpy.float64]#
unvoice(self: parselmouth.Pitch, from_time: float | None = None, to_time: float | None = None) None#
x_bins(self: parselmouth.Sampled) numpy.ndarray[numpy.float64]#
x_grid(self: parselmouth.Sampled) numpy.ndarray[numpy.float64]#
xs(self: parselmouth.Sampled) numpy.ndarray[numpy.float64]#
__hash__ = None#
property ceiling#
property centre_time#
property class_name#
property dt#
property duration#
property dx#
property end_time#
property full_name#
property max_n_candidates#
property n_frames#
property name#
property nt#
property nx#
property selected#
property selected_array#
property start_time#
property t1#
property time_range#
property time_step#
property tmax#
property tmin#
property total_duration#
property trange#
property x1#
property xmax#
property xmin#
property xrange#