Giter Club home page Giter Club logo

Comments (15)

dreamflasher avatar dreamflasher commented on May 17, 2024 1

Sorry, my bad, I didn't realize that wwf and timm are seperate libraries, updated wwf and now it's working.

from walkwithfastai.github.io.

muellerzr avatar muellerzr commented on May 17, 2024 1

Great! Glad to see it's working now

from walkwithfastai.github.io.

muellerzr avatar muellerzr commented on May 17, 2024

This should now be fixed!

from walkwithfastai.github.io.

dreamflasher avatar dreamflasher commented on May 17, 2024

I installed the latest timm version from pip: "0.3.4", but still receiving this error.

from walkwithfastai.github.io.

muellerzr avatar muellerzr commented on May 17, 2024

from walkwithfastai.github.io.

dreamflasher avatar dreamflasher commented on May 17, 2024
python3 -c "import fastai; import torch; import fastcore; import timm; print(torch.__version__, fastai.__version__, fastcore.__version__, timm.__version__)" 
1.7.0+cu110 2.2.2 1.3.16 0.3.4
from wwf.vision.timm import timm_learner

from fastai.vision.all import *


def label_func(f):
    return f[0].isupper()


path = untar_data(URLs.PETS)
files = get_image_files(path / "images")
dls = ImageDataLoaders.from_name_func(path, files, label_func, item_tfms=Resize(224))
learn = timm_learner(dls, "efficientnet_b2", metrics=error_rate)

learn.fit_one_cycle(3, slice(0.001, 0.03))

from walkwithfastai.github.io.

davecampbell avatar davecampbell commented on May 17, 2024

i am using an offline copy of timm (0.3.4) and wwf (0.0.10) in a kaggle notebook, and just got this error.
it actually ran perfectly earlier today, and was able to do a submission from that notebook.

fairly green to all this, but wanted to use an efficientnet in fast.ai so was so glad i discovered wwf!

RuntimeError: running_mean should contain 3072 elements not 1536

from walkwithfastai.github.io.

muellerzr avatar muellerzr commented on May 17, 2024

@davecampbell what is your version of fastai? Looks like it's not the most recent version

from walkwithfastai.github.io.

davecampbell avatar davecampbell commented on May 17, 2024

whatever is on the kaggle containers, i suppose.
!pip freeze produced:

fastai==2.1.8

from walkwithfastai.github.io.

muellerzr avatar muellerzr commented on May 17, 2024

You need to update fastai as well, as that is outdated. This fix is for versions > 2.2.4 I believe. This library will always be updated to the latest fastai version, which Kaggle will not always be

from walkwithfastai.github.io.

davecampbell avatar davecampbell commented on May 17, 2024

that sounds reasonable - let me work on getting that fixed and will report back. will also inform another fellow who said he had the same issue.
funky thing is that it actually ran error-free earlier today.
thanks so much for your attention.

from walkwithfastai.github.io.

davecampbell avatar davecampbell commented on May 17, 2024

i did load fastai 2.2.5 - but as it loaded, it said it was already there.
nonetheless, it ran after that - so i think that was the right advice!
thanks for that!

from walkwithfastai.github.io.

craine avatar craine commented on May 17, 2024

I ran a notebook last night, woke up this morning and re-ran it and it is giving me this error:
RuntimeError: running_mean should contain 4304 elements not 8608

Here is what happened with my frozen parameters.
Screen Shot 2021-10-18 at 8 22 12 AM

from walkwithfastai.github.io.

muellerzr avatar muellerzr commented on May 17, 2024

from walkwithfastai.github.io.

craine avatar craine commented on May 17, 2024

fastai : 2.5.2
fastcore : 1.3.26
timm : 0.4.12

from walkwithfastai.github.io.

Related Issues (20)

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.