: typing.Any) -> int:
            return data

        self.assertEqual(sample(1), 1)
        with self.assertRaises(RuntimeTypeError):
            sample(1.0)

        with self.assertRaises(RuntimeTypeError):
            sample_bad("")

    def test_float(self):
        """
        Floats should accept only floats in invariant mode
        """

        @runtime_validation
        def sample(data: float) -> float:
            return data

        @runtime_validation
        def sample_bad(data: typing.Any) -> float:
            return data

        self.assertEqual(sample(1.0), 1.0)
        with self.assertRaises(RuntimeTypeError):
            sample(1)
        with self.assertRaises(RuntimeTypeError):
            sample("")

        with self.assertRaises(RuntimeTypeError):
            sample_bad("")

        config({"mode": "covariant"})
        sample(1)

    def test_complex(self):
        """
        Complex numbers should accept complex, integers and floats
        """

        @runtime_validation
        def sample(data: complex) -> complex:
            return data

        @runtime_validation
        def sample_bad(data: typing.Any) -> complex:
            return data

        self.assertEqual(sample(1 + 1j), 1 + 1j)
        self.assertEqual(sample(1), 1)
        self.assertEqual(sample(1.0), 1.0)
        with self.assertRaises(RuntimeTypeError):
            sample("")

        with self.assertRaises(RuntimeTypeError):
            sample_bad("")

    def test_string(self):
        @runtime_validation
        def sample(data: str) -> str:
            return data

        @runtime_validation
        def sample_bad(data: typing.Any) -> str:
            return data

        self.assertEqual(sample(""), "")
        with self.assertRaises(RuntimeTypeError):
            sample(1)

        with self.assertRaises(RuntimeTypeError):
            sample_bad(1)

    def test_bytes(self):
        """
        Bytes should accept bytes as well bytearray and memorieview
        """

        @runtime_validation
        def sample(data: bytes) -> bytes:
            return data

        @runtime_validation
        def sample_bad(data: typing.Any) -> bytes:
            return data

        self.assertEqual(sample(b""), b"")
        self.assertEqual(sample(bytearray(2)), bytearray(2))
        self.assertEqual(sample(memoryview(b"")), memoryview(b""))
        with self.assertRaises(RuntimeTypeError):
            sample("")

        with self.assertRaises(RuntimeTypeError):
            sample_bad(1)

    def test_bytearray(self):
        @runtime_validation
        def sample(data: bytearray) -> bytearray:
            return data

        @runtime_validation
        def sample_bad(data: typing.Any) -> bytearray:
            return data

        self.assertEqual(sample(bytearray(2)), bytearray(2))
        with self.assertRaises(RuntimeTypeError):
            sample(b"")

        with self.assertRaises(RuntimeTypeError):
            sample_bad(1)

    def test_memoryview(self):
        @runtime_validation
        def sample(data: memoryview) -> memoryview:
            return data

        @runtime_validation
        def sample_bad(data: typing.Any) -> memoryview:
            return data

        self.assertEqual(sample(memoryview(b"")), memoryview(b""))
        with self.assertRaises(RuntimeTypeError):
            sample(b"")

        with self.assertRaises(RuntimeTypeError):
            sample_bad(1)


if __name__ == "__name__":
    unittest.main()
Math Rock Information
Math rock is a rhythmically complex guitar-based style of experimental rock[1] that emerged in the 1980s. It is characterized by complex, atypical rhythmic structures (including irregular stopping and starting), angular melodies, and dissonant chords.[2]
Math rock shares its place of origin in the late 80s underground music scene of the American Midwest.]
It was invented by a friend of ours as a derogatory term for a band me and James (Lo).
Development
Early influences
Some rock musicians who emerged in the 1960s and '70s experimented with unusual meters and structures. Notable examples include The Beatles, Frank Zappa, Henry Cow, Cream, Captain Beefheart, Emerson, Lake & Palmer, Genesis, Jethro Tull, Gentle Giant, Yes, Rush, King Crimson, Gong, Cardiacs, Mahavishnu Orchestra sound, Kiriller, Dazzling Killmen, The Flying Luttenbachers, Big’N, Mount Shasta) The Great Brain forged a unique musical taxonomy using.
One of the few math rock bands from the Detroit area was Philo Beddow. The band originally leaned toward an aggressive and dissonant sound that would be more associated with mathcore. They went on to develop a warmer sound that often consisted of more traditionally melodic vocal lines laid over angular instrumentation in patterned mixed meters and triplet-time. These compositions tended to emphasize the range and counterpoint between bass lines that were influenced by progressive rock, and guitars that balanced ostinato figures with textural harmonies.
Several other math rock groups of the 1990s, all characterized by extreme rhythmic complexity and sonic brutality, were based in Midwestern cities: Cleveland's Craw and Keelhaul, St. Louis's Dazzling Killmen, and Minneapolis' Colossamite. These groups were notable for compositions with a relentless and often dark quality, along with especially thick layers of sound.
Pittsburgh groups
The city of Pittsburgh is home to one of the most defining examples of the math rock genre: the four-piece instrumental band Don Caballero. Formed in 1991 after the breakup of Sludgehammer (which featured Ian Williams and Karl Hendricks),. Damon Che also was involved in a collaboration called Bellini between Catania, Italy's duo Agostino Tillota and Giovanna Cacciola of Uzeda. Today, the math rock genre is growing in the Sicilian region, such as Suzanne's Silver, and Diane and the Shell.[7]
Later, Che reformed Don Caballero, Creta Bourzia, and Six Horse (featuring original Don Caballero bassist Pat Morris), all of whom shared similarities with their local contemporaries in the sound of "mathy", precise, metallic rock. The genre has persisted in Pittsburgh to the present, represented by such recent act as Red Team Blue Team, Black Moth Super Rainbow, A Voice Like Rhetoric, Token Black Guy, Tabula Rasa, Hero Destroyed, Adam Koisor's current band Mail Order Brides, Kalon and Knot Feeder.[8]".[9]
D.C. groups
Washington, D.C. also contributed to the sound of math rock with the bands Kerosene 454, The Dismemberment Plan,.
The South Hampton Roads-area bands tied in with the genre: Buzzard, Kenmores, Sordid Doctrine, MEN, Alter Natives, Hoi Polloi, Guana, Kill/Joy, Loibon, Mao Tse Helen, Hell Mach 4, Hose.got.cable, Mulch, Hegoat, King Sour, chutney, Fulflej, HRM, Nudibranch, Ebonite, Engine Down, Gore De Vol and Human Thurma. Most recently the band Hex Machine, composed of members of Human Thurma, Discordance Axis (from New York/New Jersey) and Sliang Laos, carries on the Richmond tradition. Richmond's Lamb of God cite Breadwinner and Sliang Laos as major early influences.
Polvo, formed in Chapel Hill, North Carolina in 1990, is widely considered to be another math rock standard bearer, although in interviews the band disavowed that categorization.[10]
The Louisville sound
In 1991, a young band from Louisville, Kentucky than most other math rock groups, and thus its style (and those of its imitators) represents a separate branch of the category. Several groups which followed Slint's lead (including a few that featured ex-members) also used unusual meters; such bands include Rodan, Crain, The For Carnation, June of 44, Sonora Pine, Stick People, Roadside Monument, Separation of M.A.Y., Shipping News, and August Moon.
Toronto/Windsor Ontario
Toronto, ON and Windsor, ON are known to have a small math rock scene. In Windsor, a few bands under the names of Red Red Run, The Bulletproof Tiger and Fin occupy the math rock scene.
Vanguarda Paulistana
In the early 1980s, São Paulo gave rise to a movement called Vanguarda Paulistana (. It had a 'faccao zona norte' (Northerners)