Git Product home page Git Product logo

echo_clip's People

Contributors

echonet avatar mkaic avatar vukadinovic936 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

echo_clip's Issues

Dataset

Is there a open dataset link for this project?

Thanks.

Questions about reproduce of the results

Description

We came into a problem when trying to reproduce the results on EchoNet-Dynamic dataset.
While predicting results for the exmaple_video.avi are easy to do (reproduce example went well) the overall results for the whole dataset are far from the results reported in the paper (~13.2 MAE).

Furthermore, while trying to reproduce the scatterplot, we got data which is seems to be centered around the mean

Screenshots

image

To Reproduce

model, _, preprocess_val = create_model_and_transforms(
    "mkaichristensen/echo-clip-r", cache_dir="~/.cache/huggingface/hub",pretrained="...open_clip_pytorch_model.bin",precision="bf16", device="cuda"
)
# wrapping code for the model etc.
...
def test_step(self, batch, batch_idx):
        # this is the test loop
        x = batch["video"].to(torch.bfloat16)
        y = batch[self.gt_fieldname]
        bs,c,T,h,w = x.shape
        x = x.reshape(-1,c,h,w)
        x = F.normalize(self.model.encode_image(x),dim=-1)
        # now the c is not here - the embedding dimension is 512
        x = x.reshape(bs,T,-1)
        x_hat,*_ = compute_regression_metric(
                video_embeddings=x,
                prompt_embeddings=self.query_embeddings,
                prompt_values=self.prompt_values
            )
        
        # now the logic how to convert the similarity into prediction and than loss
        # check if the model is correct. what is the loss here?
        self.log("test_xhat",x_hat)

where the compute_regression_matrix is the function that is supplied in that repository.
In order to plot -

list_of_batchs,list_of_xy_pairs,list_of_minmaxs = zip(*results)
mat = torch.stack(list_of_xy_pairs)
offsets = torch.stack(list_of_minmaxs,dim=1)
summary_writer.add_pr_curve(labels=mat[:,0],predictions=mat[:,1],tag="foo")
summary_writer.add_embedding(
    mat=mat
)


# plot errors


# plt.style.use('_mpl-gallery')

# make data:
x = mat[:,0]
y = mat[:,1]
yerr = offsets.detach().cpu().numpy()

fig,ax1 = plt.subplots()
# plot:
plt.figure()
plt.errorbar(x, y, yerr, fmt='o',ecolor="cornflowerblue",capthick=1,lw=2)
# for EF the scale is 1 to 100 percents of efficiency
ax1.set(xlim=(0, 100), xticks=np.arange(0, 100,10),
       ylim=(0, 100), yticks=np.arange(0, 100,10))
ax1.set_xlabel("real EF")
ax1.set_title("EF plot")
plt.axline((0, 0), (100, 100), color='gray',linestyle="--",linewidth=0.9)
ax1.plot([0, 0], [100, 100], transform=ax1.transAxes)
plt.show()
plt.savefig("docs/assets/img/plot")

Notes

  • The echoNet Dynamic dataset version we have consist 7465 train examples, 1288 validation examples, 1277 test examples

The version of transformers library?

Thank for your great job!
When I use the words “open_clip.get_tokenizer('hf-hub:mkaichristensen/echo-clip')” to load the tokenizer, I encountered a problem as the picture depict.
image
I guess this may be a mismatch between the tokenizer version and the transformers library, so I want to know what the transformers library version is for this project. Or can you give me any other advice to address this problem.

When will the higher resolution Echo-Dynamic Dataset be released?

Dear authors, thanks for your great work.

I want to know when will you release the higher resolution (224x224) Echo-Dynamic Dataset, since the current open-source Echo-Dynamic dataset is 112X112.

The performance of zero-shot inference for LVEF prediction on the current 112X112 Echo-Dynamic dataset is not satisfactory.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.