Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ImportError: cannot import name 'distributed_init' from 'tensorlayerx.backend.ops.load_backend' #77

Open
AnsonCNS opened this issue Aug 29, 2023 · 5 comments

Comments

@AnsonCNS
Copy link

New Issue Checklist

Issue Description

When running with tensorflow as backend, it gives this error which relates to the tensorlayerx package.

ImportError: cannot import name 'distributed_init' from 'tensorlayerx.backend.ops.load_backend'

I think the issue is caused by the add torch distribution commit, where there is no distributed_init() in tensorflow_backend.py.

Reproducible Code

  • Which OS are you using ? Windows 10, Python3.8, Cuda10.2,

  • Please provide a reproducible code of your issue. Without any reproducible code, you will probably not receive any help.

I'm trying to run the SRGAN project train.py --mode=eval with tensorflow as backend and with the given pretrained tensorflow weights.

@sinnuswong
Copy link

Hello, I also encounter this issue, have you any progress

@zsdonghao
Copy link
Member

will fix soon

@aemrhb
Copy link

aemrhb commented Sep 14, 2023

HI thanks for your response I still have the same issue, any update?

@QuantumLiu
Copy link
Contributor

HI thanks for your response I still have the same issue, any update?

Can you give a sample code? @aemrhb @AnsonCNS

@AnsonCNS
Copy link
Author

@QuantumLiu I was running the code from the SRGAN project. And setting tensorflow as backend within the SRGAN train.py:

os.environ['TL_BACKEND'] = 'tensorflow'

I used the pretrained tensorflow model weights g and d provided by the project.

But I get the mentioned issue when I run the SRGAN project in eval mode.

python train.py --mode=eval

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants