

def im_getsize(path_in):
    cmd = [b'identify', b'-format', b'%w %h', util.syspath(path_in, prefix=False)]
    try:
        out = util.command_output(cmd)
    except subprocess.CalledProcessError as exc:
        log.warn('ImageMagick size query failed')
        log.debug('`convert` exited with (status {}) when getting size with command {}:\n{}', exc.returncode, out, exc.output.strip())
        return
    try:
        return tuple(map(int, out.split(b' ')))
    except IndexError:
        log.warn('Could not understand IM output: {0!r}', out)

dataset/ETHPy150Open beetbox/beets/beets/util/artresizer.py im_getsize/VarMisuse@71/132 `cmd`->`out`