Confirms that the given NoteSequence has been quantized by absolute time.
Confirms that the given NoteSequence has been quantized.
Confirms that the given NoteSequence has been quantized relative to tempo.
Confirms there is no tempo change.
Returns a list of events with a time and quantizedStep properties.
Returns whether the given NoteSequence has been quantized by absolute time.
Returns whether or not a NoteSequence proto has been quantized.
Returns whether the given NoteSequence has been quantized relative to tempo.
Assign instruments to the notes, pitch bends, and control changes of a
NoteSequence based on program numbers and drum status. All drums will be
assigned the last instrument (and program 0). All non-drum events with the
same program number will be assigned to a single instrument.
The NoteSequence for which to merge instruments. Will not be
modified.
A copy of ns with merged instruments.
Quantize a NoteSequence proto relative to tempo.
The input NoteSequence is copied and quantization-related fields are
populated. Sets the steps_per_quarter field in the quantization_info
message in the NoteSequence.
Note start and end times, and chord times are snapped to a nearby quantized
step, and the resulting times are stored in a separate field (e.g.,
QuantizedStartStep). See the comments above QUANTIZE_CUTOFF for details
on how the quantizing algorithm works.
The NoteSequence to quantize.
Each quarter note of music will be divided into this many quantized time steps.
A copy of the original NoteSequence, with quantized times added.
Quantize the notes and events of a NoteSequence proto in place.
Note start and end times, and chord times are snapped to a nearby
quantized step, and the resulting times are stored in a separate field
(e.g. QuantizedStartStep). See the comments above QUANTIZE_CUTOFF for
details on how the quantizing algorithm works.
A NoteSequence to quantize. Will be modified in place.
Each second will be divided into this many quantized time steps.
Quantizes seconds to the nearest step, given steps_per_second.
See the comments above QUANTIZE_CUTOFF for details on how the
quantizing algorithm works.
Seconds to quantize.
Quantizing resolution.
Value to use for quantizing cutoff.
the quantized step.
Calculates steps per second given stepsPerQuarter and a QPM.
Create an unquantized version of a quantized NoteSequence.
Any existing times will be replaced in the output NoteSequence and
quantization info and steps will be removed.
The tempo to use. If not provided, the tempo in ns is used,
or the default of 120 if it is not specified in the sequence either.
a new non-quantized NoteSequence wih time in seconds.
Generated using TypeDoc
A library for common manipulations of
NoteSequences.Copyright 2018 Google Inc. All Rights Reserved.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.