If the previous owner isn't present, connect the device to a Wi-Fi or cellular network and then contact the previous owner and ask them to follow these steps to remove the device from their account.
From the Find My iPhone app on another device:
Sign in with their Apple ID.
Select the device that they want to remove from their account.
Tap Actions > Erase iPhone > Erase iPhone.
Enter their Apple ID > Erase.
Click Remove from Account.
From iCloud.com:
Go to iCloud.com/#find on another device and sign in with their Apple ID.
Click All Devices at the top of the screen.
Select the device that you want to remove from iCloud.
Click Erase iPhone.
After your device has been erased, click Remove from Account.
After the previous owner erases and removes the device from their account, turn off the device and then turn it back on to begin the setup process.