有什么 python 的包能够间接生成图片的向量吗?用于以图搜图,比拟图片的类似度?

有什么封装好的 python 的包,能够间接生成图片的向量吗?
有什么封装好的 python 的包,能够开箱即用,间接生成图片的向量吗?
有什么封装好的 python 的包,能够通过 resnet,残差神经网络开箱即用,间接生成图片的向量吗?

当然有了,看这个:https://github.com/ponponon/i...

from pathlib import Pathfrom typing import Listfrom iv import ResNet, l2# Initialize a residual neural networkresnet: ResNet = ResNet(    weight_file='weight/gl18-tl-resnet50-gem-w-83fdc30.pth')# Generate a vector of specified images# The generated vector is a List[float] data structure,# the length of the list is 512, which means the vector is of 512 dimensionsvector_1: List[float] = resnet.gen_vector('example-1.jpg')vector_2: List[float] = resnet.gen_vector('example-2.jpg')# Compare the Euclidean distance of two vectorsdistance: float = l2(vector_1, vector_2)print('Euclidean Distance is ', distance)

非常简单,开箱即用