question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Unable to run example code - TypeError('require string label')

See original GitHub issue

Hi,

I am unable to run the first hyperas example. Specifically this line:

>>> model.add(Dropout({{uniform(0, 1)}}))
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/Users/brohoro/Documents/PyProjects/envs/tensorflow/lib/python2.7/site-packages/hyperopt/pyll_utils.py", line 21, in wrapper
    raise TypeError('require string label')

The example without hyperas runs fine.

Here is my env

Python 2.7.13 Name: Keras Version: 2.0.4 Name: hyperas Version: 0.3 Name: hyperopt Version: 0.1

I have tried this both via Jupyter and via the python interpreter.

Thanks

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:18 (6 by maintainers)

github_iconTop GitHub Comments

5reactions
maxpumperlacommented, Jul 11, 2017

sorry to hear that. will look into the issue once back from vacation

4reactions
nchuramanicommented, Jun 30, 2017

Hi @maxpumperla , I am facing the same problem with uniform and choice. I tried installing hyperas from master i.e. hyperas 0.4 but I am still facing the same issue.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Error trying to pass list to hyperas as a parameter
The problem is with this line: model.add(Dropout({{uniform(dropout)}})). The variable dropout is defined within the scope of your model() ...
Read more >
Developers - Unable to run example code - TypeError('require string ...
Unable to run example code - TypeError('require string label')
Read more >
TypeError: can't assign to property "x" on "y": not an object
In strict mode, a TypeError is raised when attempting to create a property on primitive value such as a symbol, a string, a...
Read more >
How to Fix TypeError Exceptions in Python - Rollbar
The Python TypeError is an exception that occurs when the data type of an object in an operation is inappropriate. Learn how to...
Read more >
Typeerror: str object is not callable – How to Fix in Python
You pass a variable named str as a parameter to the str() function. When you call a string like a function. In the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found