def detach_volume(self, volume_id, instance_id=None,
                      device=None, force=False):
        params = {'VolumeId' : volume_id}
        if instance_id:
            params['InstanceId'] = instance_id
        if device:
            params['Device'] = device
        if force:
            params['Force'] = 'true'
        return self.get_status('DetachVolume', params, verb='POST')

    # Snapshot methods
Detach an EBS volume from an EC2 instance.
dataset/ETHPy150Open darcyliu/storyboard/boto/ec2/connection.py/EC2Connection.detach_volume