codalab / codalab-competitions

CodaLab Competitions
https://codalab.lisn.fr
Other
513 stars 129 forks source link

ModuleNotFoundError: No module named 'tensorflow_text' #2968

Closed tmarrakchi closed 3 years ago

tmarrakchi commented 3 years ago

Hi, I have a python script which uses the tensorflow and tensorflow_text modules. Here is the run command: cl run "model_javagen_conala:0x1abbb4" "requirements.txt:0xd1ac11" "run_java_challenge.sh:0x4c62dc" "run_predict_script.py:0xc9fe06" "sh run_java_challenge.sh" -n run-evaluations

When a execute this command here is the error :

Traceback (most recent call last):
  File "run_predict_script.py", line 4, in <module>
    import tensorflow_text  # Required to run exported model.
ModuleNotFoundError: No module named 'tensorflow_text'

I noticed tensorflow exists in the default docker image, however the installed version is V1 and I need tensorflow-text for my script and this module works only with tensorflow V2.

I also tried adding --request-docker-image spellrun / tensorflow2-cpu but it's still the same problem.

Any idea please ?

Didayolo commented 3 years ago

Hi,

Can you please give us more context? At which point this is linked with CodaLab Competitions?

tmarrakchi commented 3 years ago

Hi,

I have an execution bundle which contains the following instructions:

pip install tensorflow_text
python run_predict_script.py

The "run_predict_script.py" file imports the tensorflow_text module and this is the problem as I mentioned above.

I do not know if there is a link with codalab competitions because I am still a novice and I have not found another place to ask this question. Really I'm stuck

I am counting on your collaboration :)

Didayolo commented 3 years ago

I do not know if there is a link with codalab competitions because I am still a novice

I don't get it. Are you trying to organize a competition on CodaLab, or at least to participate in one?

If you are just trying to solve a generic tensorflow programming problem, then please ask your question on Stack Overflow.