This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import json | |
from xml.etree import ElementTree | |
tree = ElementTree.parse('raml20.xml') | |
ns = {'ns': 'raml20.xsd'} | |
nsP, nsList, nsItem = ('{%s}%s' % (ns['ns'], i) for i in ('p', 'list', 'item')) | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using DSP | |
function cheby1(n, r, wp) | |
# Chebyshev Type I digital filter design. | |
# | |
# b, a = cheby1(n, r, wp) | |
# | |
# Designs an nth order lowpass digital Chebyshev filter with | |
# R decibels of peak-to-peak ripple in the passband. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"""Finding a pattern in a list | |
A solution to the Stack Overflow question: | |
http://stackoverflow.com/questions/6656310/finding-patterns-in-a-list | |
""" | |
import itertools | |
def pattern_match(pattern, sequence): |