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

TypeError: 0.84068537 is not JSON serializable #22

Open
sara-kassani opened this issue Oct 26, 2018 · 0 comments
Open

TypeError: 0.84068537 is not JSON serializable #22

sara-kassani opened this issue Oct 26, 2018 · 0 comments

Comments

@sara-kassani
Copy link

The error is for utils.py

utils.py", line 80, in train
write_event(log, step, loss=mean_loss)

utils.py", line 26, in write_event
log.write(json.dumps(data, sort_keys=True))

File "C:\Users\Lab\AppData\Local\Programs\Python\Python35\lib\json_init_.py", line 237, in dumps
**kw).encode(obj)
File "C:\Users\Lab\AppData\Local\Programs\Python\Python35\lib\json\encoder.py", line 198, in encode
chunks = self.iterencode(o, _one_shot=True)
File "C:\Users\Lab\AppData\Local\Programs\Python\Python35\lib\json\encoder.py", line 256, in iterencode
return _iterencode(o, 0)
File "C:\Users\Lab\AppData\Local\Programs\Python\Python35\lib\json\encoder.py", line 179, in default
raise TypeError(repr(o) + " is not JSON serializable")
TypeError: 0.84068537 is not JSON serializable

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

1 participant