Skip to content

Embeddings model d #107

@sonfire186

Description

@sonfire186

I am embedding with
resnet_v1_50/E_BN2/Identity:0
I count the distance

dot = np.sum(np.multiply(em1, em2), axis=1)
norm = np.linalg.norm(em1, axis=1) * np.linalg.norm(em2, axis=1)
similarity = dot / norm

But get weird numbers
Also, the question is about the input layer, should the image be filed like this? RGB/BGR?

crops = cv2.resize(face, (112, 112), interpolation=cv2.INTER_CUBIC)
crops = np.array(crops)
crops = crops.astype('float64')
crops -= 127.5
crops *= 0.0078125

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions