Skip to content

error in intro / tutorial: time_interval = Positions(plotter.klicker)[0] #14

@LFSaw

Description

@LFSaw

Hello there,

thank you for your repository, it looks quite interesting and I'd like to generate some bird calls with it!
Unfortunately, the syllable tutorial prodices an error in this line:

time_interval = Positions(plotter.klicker)[0]

Since I do not know the specifics of the Position implementation it is hard for me to debug... would you mind helping me out here?

The error is this:

---------------------------------------------------------------------------
ValueError                                Traceback (most recent call last)
Cell In[18], line 1
----> 1 Positions(plotter.klicker)

File ~/vol/projects/artificial-birds/birdsongs/venv/lib/python3.9/site-packages/birdsongs/util.py:125, in Positions(klicker)
    123     return np.array([[tinis[i], tends[i]] for i in range(len(tinis))])
    124 else:
--> 125     return np.array([tinis, tends])

ValueError: setting an array element with a sequence. The requested array has an inhomogeneous shape after 1 dimensions. The detected shape was (2,) + inhomogeneous part.

Thanks in advance!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions