pydicom is nice but it lacks network functionality: find, send, store and so on. And it cannot decompress jpegs.
Two large open source toolkits are dcmtk[1] and gdcm[2]. Both comes with commandline applications for viewing dicom files and querying pacs servers. gdcm is bundled with itk[3].
[1] http://dicom.offis.de/dcmtk.php.en
[2] http://sourceforge.net/projects/gdcm/
[3] http://www.itk.org/