Skip to content

Conversation

@rentainhe
Copy link
Contributor

@rentainhe rentainhe commented Jan 17, 2022

TODO

  • Refine linspace op and trunc_normal_ usage in PVT, Swin, CSWin and CrossFormer
  • Simple test
  • Evaluate model inference

Simple Test

from flowvision.models.swin_transformer import swin_tiny_patch4_window7_224
from flowvision.models.pvt import pvt_tiny
from flowvision.models.cswin import cswin_tiny_224
from flowvision.models.crossformer import crossformer_tiny_patch4_group7_224

model = crossformer_tiny_patch4_group7_224()

import oneflow as flow

x = flow.randn(1, 3, 224 ,224)
output = model(x)
print(output.shape)  # oneflow.Size([1, 1000])

@rentainhe rentainhe requested a review from Ldpe2G January 17, 2022 06:11
@rentainhe rentainhe changed the title Supported linspace and trunc_normal Support linspace and trunc_normal Jan 17, 2022
@simonJJJ simonJJJ merged commit 79aa8f2 into main Jan 20, 2022
@simonJJJ simonJJJ deleted the refine_linspace_relative_code branch January 20, 2022 11:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants