unmount drive in Google Colab

Unmount drive in Google Colab and remount to another drive by following these steps:
1-terminate your session: site menu bar> Runtime> Manage sessions> Terminate
2-running the code:
”’
from google.colab import drive
drive.flush_and_unmount()
!rm -rf /content/drive
”’
3-running the code:
”’
from google.colab import drive
drive.mount(‘/content/drive’)
”’

Add a Comment

Your email address will not be published. Required fields are marked *