Created using Colaboratory
This commit is contained in:
parent
bae522ba61
commit
bfdcf16a91
|
@ -10,6 +10,19 @@
|
||||||
"<a href=\"https://colab.research.google.com/github/nawnie/EveryDream/blob/main/EveryDream_Tools.ipynb\" target=\"_parent\"><img src=\"https://colab.research.google.com/assets/colab-badge.svg\" alt=\"Open In Colab\"/></a>"
|
"<a href=\"https://colab.research.google.com/github/nawnie/EveryDream/blob/main/EveryDream_Tools.ipynb\" target=\"_parent\"><img src=\"https://colab.research.google.com/assets/colab-badge.svg\" alt=\"Open In Colab\"/></a>"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"cell_type": "code",
|
||||||
|
"source": [
|
||||||
|
"#@title #Connect to Google Drive\n",
|
||||||
|
"from google.colab import drive\n",
|
||||||
|
"drive.mount('/content/drive')\n"
|
||||||
|
],
|
||||||
|
"metadata": {
|
||||||
|
"id": "Z_ZHfnQ52dg9"
|
||||||
|
},
|
||||||
|
"execution_count": null,
|
||||||
|
"outputs": []
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"cell_type": "markdown",
|
"cell_type": "markdown",
|
||||||
"metadata": {
|
"metadata": {
|
||||||
|
@ -57,7 +70,8 @@
|
||||||
"!pip install fairscale=='0.4.4'\n",
|
"!pip install fairscale=='0.4.4'\n",
|
||||||
"!pip install transformers=='4.19.2'\n",
|
"!pip install transformers=='4.19.2'\n",
|
||||||
"!pip install timm\n",
|
"!pip install timm\n",
|
||||||
"!pip install aiofiles"
|
"!pip install aiofiles\n",
|
||||||
|
"!pip install colorama"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -221,7 +235,7 @@
|
||||||
"\n",
|
"\n",
|
||||||
"* --find: will search for a word in this case man\n",
|
"* --find: will search for a word in this case man\n",
|
||||||
"\n",
|
"\n",
|
||||||
"* --replace: will replace our found word with in this case VictorChall\n",
|
"* --replace: will replace our found word with in this case bob smith\n",
|
||||||
"\n",
|
"\n",
|
||||||
"* --append_only: this will allow us to add a tag at he end "
|
"* --append_only: this will allow us to add a tag at he end "
|
||||||
],
|
],
|
||||||
|
@ -235,7 +249,7 @@
|
||||||
"!python scripts/filename_replace.py \\\n",
|
"!python scripts/filename_replace.py \\\n",
|
||||||
"--img_dir output \\\n",
|
"--img_dir output \\\n",
|
||||||
"--find \"man\" \\\n",
|
"--find \"man\" \\\n",
|
||||||
"--replace \"VictorChall\""
|
"--replace \"bob smith\""
|
||||||
],
|
],
|
||||||
"metadata": {
|
"metadata": {
|
||||||
"id": "6Y1md3OHAvhw"
|
"id": "6Y1md3OHAvhw"
|
||||||
|
@ -275,7 +289,7 @@
|
||||||
{
|
{
|
||||||
"cell_type": "code",
|
"cell_type": "code",
|
||||||
"source": [
|
"source": [
|
||||||
"/content/EveryDream/scripts/compress_img.py \\\n",
|
"!python scripts/compress_img.py \\\n",
|
||||||
"--img_dir output \\\n",
|
"--img_dir output \\\n",
|
||||||
"--out_dir output/compressed_images \\\n",
|
"--out_dir output/compressed_images \\\n",
|
||||||
"--max_mp 1.5 \n",
|
"--max_mp 1.5 \n",
|
||||||
|
@ -309,8 +323,6 @@
|
||||||
},
|
},
|
||||||
"outputs": [],
|
"outputs": [],
|
||||||
"source": [
|
"source": [
|
||||||
"from google.colab import drive\n",
|
|
||||||
"drive.mount('/content/drive')\n",
|
|
||||||
"\n",
|
"\n",
|
||||||
"!mkdir /content/drive/MyDrive/Auto_Data_sets\n",
|
"!mkdir /content/drive/MyDrive/Auto_Data_sets\n",
|
||||||
"!cp -r output/ /content/drive/MyDrive/Auto_Data_sets"
|
"!cp -r output/ /content/drive/MyDrive/Auto_Data_sets"
|
||||||
|
@ -350,6 +362,7 @@
|
||||||
"metadata": {
|
"metadata": {
|
||||||
"colab": {
|
"colab": {
|
||||||
"provenance": [],
|
"provenance": [],
|
||||||
|
"machine_shape": "hm",
|
||||||
"include_colab_link": true
|
"include_colab_link": true
|
||||||
},
|
},
|
||||||
"kernelspec": {
|
"kernelspec": {
|
||||||
|
@ -365,7 +378,9 @@
|
||||||
"interpreter": {
|
"interpreter": {
|
||||||
"hash": "faf4a6abb601e3a9195ce3e9620411ceec233a951446de834cdf28542d2d93b4"
|
"hash": "faf4a6abb601e3a9195ce3e9620411ceec233a951446de834cdf28542d2d93b4"
|
||||||
}
|
}
|
||||||
}
|
},
|
||||||
|
"accelerator": "GPU",
|
||||||
|
"gpuClass": "standard"
|
||||||
},
|
},
|
||||||
"nbformat": 4,
|
"nbformat": 4,
|
||||||
"nbformat_minor": 0
|
"nbformat_minor": 0
|
||||||
|
|
Loading…
Reference in New Issue