Upload fusion_t2i_CLIP_interrogator.ipynb
Browse files
Google Colab Jupyter Notebooks/fusion_t2i_CLIP_interrogator.ipynb
CHANGED
@@ -593,15 +593,20 @@
|
|
593 |
"LIST_SIZE = 1000 # @param {type:'number' , placeholder:'set how large the list should be'}\n",
|
594 |
"_START_AT = '0' # @param [\"0\", \"10000\", \"50000\"] {allow-input: true}\n",
|
595 |
"START_AT = 0\n",
|
596 |
-
"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
597 |
"\n",
|
598 |
"output_folder = home_directory + 'results/'\n",
|
599 |
"output_folder_sims = home_directory + 'results/sims/'\n",
|
600 |
"my_mkdirs(output_folder)\n",
|
601 |
"my_mkdirs(output_folder_sims)\n",
|
602 |
"\n",
|
603 |
-
"\n",
|
604 |
-
"\n",
|
605 |
"# @markdown -----\n",
|
606 |
"# @markdown Select vocab\n",
|
607 |
"general = True # @param {type:\"boolean\"}\n",
|
@@ -782,21 +787,11 @@
|
|
782 |
"image\n"
|
783 |
],
|
784 |
"metadata": {
|
785 |
-
"id": "kOYZ8Ajn-DD8"
|
786 |
-
"cellView": "form"
|
787 |
},
|
788 |
"execution_count": null,
|
789 |
"outputs": []
|
790 |
},
|
791 |
-
{
|
792 |
-
"cell_type": "markdown",
|
793 |
-
"source": [
|
794 |
-
"# π Evaluate similarities"
|
795 |
-
],
|
796 |
-
"metadata": {
|
797 |
-
"id": "RbFayOGtCdUN"
|
798 |
-
}
|
799 |
-
},
|
800 |
{
|
801 |
"cell_type": "markdown",
|
802 |
"source": [
|
@@ -811,7 +806,7 @@
|
|
811 |
{
|
812 |
"cell_type": "code",
|
813 |
"source": [
|
814 |
-
"# @title β π
|
815 |
"%cd {output_folder_sims}\n",
|
816 |
"index = 0\n",
|
817 |
"for filename in os.listdir(output_folder_sims):\n",
|
@@ -887,8 +882,7 @@
|
|
887 |
"plt.show()"
|
888 |
],
|
889 |
"metadata": {
|
890 |
-
"id": "ln6DsZPG99ez"
|
891 |
-
"cellView": "form"
|
892 |
},
|
893 |
"execution_count": null,
|
894 |
"outputs": []
|
|
|
593 |
"LIST_SIZE = 1000 # @param {type:'number' , placeholder:'set how large the list should be'}\n",
|
594 |
"_START_AT = '0' # @param [\"0\", \"10000\", \"50000\"] {allow-input: true}\n",
|
595 |
"START_AT = 0\n",
|
596 |
+
"#-----#\n",
|
597 |
+
"if _START_AT.find('K')>-1:\n",
|
598 |
+
" START_AT = _START_AT.replace('K','')\n",
|
599 |
+
" if START_AT.isnumeric(): START_AT = int(START_AT)*1000\n",
|
600 |
+
"#------#\n",
|
601 |
+
"else:\n",
|
602 |
+
" if _START_AT.isnumeric(): START_AT = int(_START_AT)\n",
|
603 |
+
"#----#\n",
|
604 |
"\n",
|
605 |
"output_folder = home_directory + 'results/'\n",
|
606 |
"output_folder_sims = home_directory + 'results/sims/'\n",
|
607 |
"my_mkdirs(output_folder)\n",
|
608 |
"my_mkdirs(output_folder_sims)\n",
|
609 |
"\n",
|
|
|
|
|
610 |
"# @markdown -----\n",
|
611 |
"# @markdown Select vocab\n",
|
612 |
"general = True # @param {type:\"boolean\"}\n",
|
|
|
787 |
"image\n"
|
788 |
],
|
789 |
"metadata": {
|
790 |
+
"id": "kOYZ8Ajn-DD8"
|
|
|
791 |
},
|
792 |
"execution_count": null,
|
793 |
"outputs": []
|
794 |
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
795 |
{
|
796 |
"cell_type": "markdown",
|
797 |
"source": [
|
|
|
806 |
{
|
807 |
"cell_type": "code",
|
808 |
"source": [
|
809 |
+
"# @title β π Test how unique the encoding is\n",
|
810 |
"%cd {output_folder_sims}\n",
|
811 |
"index = 0\n",
|
812 |
"for filename in os.listdir(output_folder_sims):\n",
|
|
|
882 |
"plt.show()"
|
883 |
],
|
884 |
"metadata": {
|
885 |
+
"id": "ln6DsZPG99ez"
|
|
|
886 |
},
|
887 |
"execution_count": null,
|
888 |
"outputs": []
|