Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up

Application for verifying ripped audio files using AccurateRip database.

License

NotificationsYou must be signed in to change notification settings

arcctgx/ARver

Repository files navigation

Unit testsPyPI versionPePy downloads

ARver is a command-line program for verifying audio tracks ripped from a CDagainst checksums stored in AccurateRip database.

The idea behind AccurateRip verification is that it's virtually impossible toget exact same errors when ripping different copies of the same CD on variousCD drives. If the copies are scratched or otherwise degraded, read errors willoccur in different disc sectors. CD drive defects are unlikely to manifest inthe same way on different machines. Essentially, all read errors are expectedto be unique, but in absence of errors only a single correct result exists.

AccurateRip database stores track checksums submitted by multiple users. Whenmany users rip the same disc without errors, correct checksums are submitted tothe database repeatably, boosting their "confidence" statistic. If a checksumof a ripped track is not found in the database, it indicates that the result isunique, meaning that disc read errors likely occurred while ripping.

ARver calculates the AccurateRip checksums of local files, fetches checksumsfor a given CD from the database, and displays a report which compares them.

Features

The package provides following command-line tools:

  • arver: the main program. It determines the AccurateRip disc ID, fetchesAccurateRip data, calculates checksums of ripped audio files, compares themwith downloaded AccurateRip data and displays the result.

  • arver-discinfo: displays disc IDs and the Table of Contents, fetches anddisplays all AccurateRip track checksums.

  • arver-ripinfo: calculates checksums of audio files (ARv1, ARv2 and CRC32)and presents them as a table.

  • arver-bin-parser: parses cached binary AccurateRip response and displaysall AccurateRip track checksums.

Usage example

This example demonstrates the typical use case ofarver: verification offiles just ripped from a CD.

Animated ARver usage example

The tracks have been ripped usingcdparanoia prior to runningarver.AccurateRip disc ID is calculated based on the TOC of the CD which still isin the drive.arver fetches the checksums from the database, and compareschecksums of local files with database entries.

In this casearver found that the third track was not ripped correctly, andreports a verification failure. The disc used for this example is affected byCD bronzing, andcdparanoia reported multiple issues toward the end of thelast track.

Installation

For typical use:

python3 -m pip install arver

ARver requires Python 3.7 or newer. A pre-built wheel package is available onPyPI forCPython versions 3.7 and newer, targeting thex86_64 architecturefor Linux. For other platforms installation is only supported from the sourcedistribution (see the "Dependencies" section below).

While the wheel is forward-compatible with future 3.x Python versions, the latestPython releases may not have been tested. The latest tested Python version islisted in the PyPI trove classifiers.

For development:

git clone https://github.com/arcctgx/ARvercd ARverpython3 -m pip install --editable.

For packaging:

git clone https://github.com/arcctgx/ARvercd ARverpython3 setup.py install --root=/tmp/pkg-arver# use contents of /tmp/pkg-arver to create a package.

Dependencies

ARver depends on following Python packages at runtime:

  • discid
  • musicbrainzngs
  • pycdio
  • requests

They will be installed automatically bypip install if needed. Alternatively,one can install them using providedrequirements.txt file.

The source code includes aC extension which depends onlibsndfile, sobuilding from source requires aC compiler (gcc) andlibsndfile headers.This makeslibsndfile both compile-time and runtime dependency whenARveris installed from the source distribution.

Note aboutpycdio dependency

pycdio does not provide wheels, so if it's not already installed on yoursystem,pip install arver will attempt to build it from source. Buildingfrom source may fail due to missing build-time dependencies. To work aroundthis, you can try installingpycdio using your Linux distribution's packagemanager before installingARver. If that doesn't work, you'll need to installthe build-time dependencies listed on thepycdio GitHub page and then retrythe installation withpip.

Restrictions

CD read offset corrections

Audio files must be corrected forCD drive read offset (e.g. by using-Ooption incdparanoia). This is crucial for AccurateRip verification: withoutit the checksums of ripped tracks cannot be directly compared with databaseentries.ARver expects the input files to have zero offset, i.e. it assumesthat required offset corrections were applied by the CD ripper. If this is notthe case, all tracks will be reported as failing verification.

Hidden Track One Audio ("pregap track")

In some discs audio content is hidden in the pregap of track one. Many CDrippers (e.g.EAC orcdparanoia) can detect and rip it. Unfortunately,AccurateRip database does not store checksums of such tracks, so they can'tbe verified.

ARver will detect the presence of track one pregap, and will display it inCD TOC summary. If your ripper did extract the pregap track, do not pass itsfile name as argument toarver. It will change the track sequence and causeverification errors in other tracks. If you used a wildcard to specify audiofiles, use-x/--exclude option to ignore the pregap track.

Verifying Mixed Mode CDs

AccurateRip database does not store checksums of last audio tracks in MixedMode CDs. These tracks cannot be verified and their verification status willalways show asN/A in the results summary.

Verifying Copy Controlled CDs

Copy Controlled CDs were designed specifically to prevent ripping. The way itis achieved makes these discs more sensitive to normal wear, and makes themnot compliant with CD audio standard. Such CDs can often be ripped, but aremuch more likely to produce errors.

These CDs appear toarver andarver-discinfo as ordinary Enhanced CDs(multisession with data track in the end). It is not possible to distinguishthem from normal Enhanced CDs based on the table of contents alone. If yourdisc bears "Copy Controlled CD" logo, verification problems are expected.

Verification without a physical disc

The regular use case ofARver is to verify a set of audio files right afterthey have been ripped, while the CD they have been ripped from is still in thedrive.

Commandsarver andarver-discinfo support an alternative mode of operation,where disc information is downloaded from MusicBrainz by disc ID lookup. Whilethis can be useful, it is reliable only for Audio CDs. Information about datatracks is not encoded in MusicBrainz disc ID, but it is necessary to calculateAccurateRip disc ID. Attempts to verify discs with data tracks (Enhanced orMixed Mode CDs) using disc ID lookup may not work at all, result in falsenegatives or low confidence values.

arver can try to guess the disc TOC based on the lengths of provided audiofiles with-t/--track-lengths option. This is considered expert usage: thereis no way to know that files were ripped from a CD containing a pregap trackor a data track, but it affects disc ID calculation. Options-D/--data-lengthand-P/--pregap-length can be used to provide this information if it is knownfrom another source. Note that the lengths must be specified exactly: even anoff-by-one mistake will result in a different (and probably wrong) disc ID.

If the data track length is provided,arver will calculate the disc ID as ifit was an Enhanced CD. Verifying Mixed Mode CDs this way is not supported.

Acknowledgements

AccurateRip database is (c) Illustrate. Used with permission.

Thanks to the following people and projects for source code and inspiration:


[8]ページ先頭

©2009-2025 Movatter.jp