MCPcopy Create free account
hub / github.com/PyWavelets/pywt / decompose

Method decompose

pywt/_wavelet_packets.py:171–187  ·  view source on GitHub ↗

Decompose node data creating DWT coefficients subnodes. Performs Discrete Wavelet Transform on the `~BaseNode.data` and returns transform coefficients. Note ---- Descends to subnodes and recursively calls `~BaseNode.reconstruct` on them.

(self)

Source from the content-addressed store, hash-verified

169 return self.path[-self.PART_LEN:]
170
171 def decompose(self):
172 """
173 Decompose node data creating DWT coefficients subnodes.
174
175 Performs Discrete Wavelet Transform on the `~BaseNode.data` and
176 returns transform coefficients.
177
178 Note
179 ----
180 Descends to subnodes and recursively
181 calls `~BaseNode.reconstruct` on them.
182
183 """
184 if self.level < self.maxlevel:
185 return self._decompose()
186 else:
187 raise ValueError("Maximum decomposition level reached.")
188
189 def _decompose(self):
190 raise NotImplementedError()

Callers 1

get_subnodeMethod · 0.95

Calls 1

_decomposeMethod · 0.95

Tested by

no test coverage detected