Examples: query, "exact match", wildcard*, wild?ard, wild*rd
Fuzzy search: cake~ (finds cakes, bake)
Term boost: "red velvet"^4, chocolate^2
Field grouping: tags:(+work -"fun-stuff")
Escaping: Escape characters +-&|!(){}[]^"~*?:\ with \, e.g. \+
Range search: properties.timestamp:[1587729413488 TO *] (inclusive), properties.title:{A TO Z}(excluding A and Z)
Combinations: chocolate AND vanilla, chocolate OR vanilla, (chocolate OR vanilla) NOT "vanilla pudding"
Field search: properties.title:"The Title" AND text
Answered
Hi, I'M Having Problems With The Installed Packages When Creating An Experiment. The Installed Packages Used To Be A List With The Versions Of All The Installed Packages In The Venv. However, Now I Get The Following:

Hi, I'm having problems with the installed packages when creating an experiment. The installed packages used to be a list with the versions of all the installed packages in the venv. However, now I get the following:
` # Python 3.7.6 | packaged by conda-forge | (default, Jun 1 2020, 18:57:50) [GCC 7.5.0]

Pillow == 8.3.1
clearml == 1.1.4
google_cloud_storage == 1.37.1
joblib == 1.0.1
numpy == 1.17.3
pandas == 1.3.0
seaborn == 0.11.1
tensorflow_gpu == 2.3.1
tqdm == 4.54.1 My problem is that this is an incomplete list and when I try to clone my experiment I get a ModuleNotFoundError ` because an import of a not installed package is being attempted. I tried this using clearml 1.1.4, but also tried with the version I used before (0.17.5) and the results are still the same. I don't know what I'm doing differently now.

  
  
Posted 3 years ago
Votes Newest

Answers 30


Previously we had similar issues when we switched images used in agent. Might want to check on that.

  
  
Posted 3 years ago

images?

  
  
Posted 3 years ago

So what changed?

We changed other bits of code, but not that one..
But maybe we are focusing on the wrong thing, the question now is why is ClearML only detecting these packages (running a different experiment than Diego)

Pillow == 8.0.1
clearml == 0.17.5
google_cloud_storage == 1.40.0
joblib == 0.17.0
numpy == 1.19.5
pandas == 1.3.1
seaborn == 0.11.0
tensorflow_gpu == 2.3.1
tqdm == 4.54.1

  
  
Posted 3 years ago

how can we debug this?

  
  
Posted 3 years ago

I'm assuming these are the Only packages that are imported directly (i.e. pandas requires other packages but the code imports pandas so this is what listed).
The way ClearML detect packages, it first tries to understand if this is a "standalone" scrip, if it does, than only imports in the main script are logged. Then if it "thinks" this is not a standalone script, then it will analyze the entire repository.
make sense ?

  
  
Posted 3 years ago

I see, I can confirm that these packages (except for google_cloud_storage) are imported directly in the main script

  
  
Posted 3 years ago

ok, so ClearML doesn't add all the imported packages needed to run the task to the Installed Packages, only the ones in the main script?

  
  
Posted 3 years ago

Ok, I think figured it out. We started with a main script that imported sklearn and then we moved that function outside the main script, and instead imported that function.
So when we cloned the first time we had sklearn in the Installed Packages, and therefore our agent was able to run. The (now) cached clearml-venv had sklearn installed, and when it run the second experiment without the sklearn import in the main script and therefore without it in the Installed Packages it didn't matter, because the package was already installed..

  
  
Posted 3 years ago

so what we should do is turn pip freeze on in the clearml.conf file?

  
  
Posted 3 years ago

Ok,ย I think figured it out.

Nice!

ClearML doesn't add all the imported packages needed to run the task to the Installed Packages

It does (but not derivative packages, that are used by the required packages, the derivative packages will be added when the agent is running it, because it creates a new clean venv and then it add the required packages, then it updates back with everything in pip freeze, because it now represents All the packages the Task needs)

Two questions:
Is the code running from a git repository Is the "second function" (the one actually importing sklearn) in a different file? if so how do you import it

  
  
Posted 3 years ago

yes, the code is inside a git repository In the main script: from callbacks import function_plot_conf_matrix
and inside callbacks.py of course at the beginning we have from sklearn.metrics import confusion_matrix or something like that

  
  
Posted 3 years ago

Hmm, I think "it" misses the fact callbacks are not a package.
Any chance you can post the code here? (or DM me)

  
  
Posted 3 years ago

right, callbacks.py is a file inside the repo, but is not part of the package

  
  
Posted 3 years ago

which part of the code?

  
  
Posted 3 years ago

the main bits are those ๐Ÿ™‚

  
  
Posted 3 years ago

which part of the code?

the main script?!

but is not part of the package

is the repo it self a package ?

  
  
Posted 3 years ago

we'll create a minimal working example :-)

  
  
Posted 3 years ago

Thank you, I would love to make sure we fix it

  
  
Posted 3 years ago

Ok, tried the following four things:
(fail = sklearn not listed in installed packages)
no _ init _.py file in the module_a folder, not a git repo: fail no _ init _.py file in module_a folder, git repo: fail with _ init _.py file in module_a folder, not git repo: fail with _ init _.py file in module_a folder, with git repo: OK!

  
  
Posted 3 years ago

MuddySquid7 , we're having a look and testing it. Thanks!

  
  
Posted 3 years ago

MuddySquid7 , I couldn't reproduce case 4.
In all cases it didn't detect sklearn.

Did you put anything inside _init_.py ?
Can you please zip up the folder from scenario 4. and post it here?

  
  
Posted 3 years ago

I've included a requirements.txt file

  
  
Posted 3 years ago

Did you put anything insideย 

init.py

?

nope

  
  
Posted 3 years ago

did you do a git init?

  
  
Posted 3 years ago

Nope, will try with ๐Ÿ™‚

  
  
Posted 3 years ago

And thanks again!

  
  
Posted 3 years ago

no prob! ๐Ÿ™‚

  
  
Posted 3 years ago

Hi! were you able to reproduce the issue CostlyOstrich36 ?

  
  
Posted 3 years ago

MuddySquid7 , Yes! Reproduced like a charm. We're looking into it ๐Ÿ™‚

  
  
Posted 3 years ago

great, let me know if I can help you in any way. Thanks!

  
  
Posted 3 years ago
1K Views
30 Answers
3 years ago
one year ago
Tags
Similar posts