Does the library have some type of licensing agreement with the media it purchases? The article indicates that it isn't the case, but if there was, could that be the reason why libraries aren't attacked but torrent sites are? Though libraries have a lot less traffic and loss in potential sales compared to a torrent tracker.
This type of discrimination happens with website scraping too. Websites don't go after big search indexers like Google and Bing but will and can sue local scrapers who never entered some type of agreement with the website.