Skip to content

Is it possible to embed image types which are not in the given list of keys? #15

@DJLevy97

Description

@DJLevy97

Hi,

I'm trying to see if I can use AnySat to embed high resolution UAV imagery. The images are 3 channel RGB and of resolution 0.25m/pixel.

I've been playing around with hubconf.py, e.g. by adding my own custom key such as:

            'uav': {
                    'patch_size':    8,      # δₘ in px
                    'in_chans':      3,      # RGB
                    'resolution':   0.25,    # m/px
                    'embed_dim':    dim,     # the same dim variable in that function
                    'bias':       False,
                    'mlp':      [dim,dim*2,dim],
                    },

But then I'm having issues, e.g. if I try to do

    with torch.no_grad():
        feats = model(
            {"uav": x}, 
            patch_size=real_patch_size_m
        )

Can you advise if this should be possible, and if it is, are there any best practices for adding in a custom key?

Apologies if I'm missing something obvious. Many thanks

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