You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We have get for python, which automatically returns the correct type, i.e. get('my_vector') and get('my_int') return a numpy array and an int respectively.
Now, why don't we do the same thing for creating shogun objects via factories? (In Python)
That should be possible using exactly the same mechanics as in get, or do I get this wrong? @gf712 Maybe you can provide pointers for a student to do this
The text was updated successfully, but these errors were encountered:
Hmmm, this would be more complicated, because we call get with a visitor pattern, so we have Any to visit on. What you need is a way to dispatch with sgobject to the “base” class. Will have to think about it! Otherwise there is the naive with a try except for loop in Python..
We have
get
for python, which automatically returns the correct type, i.e.get('my_vector')
andget('my_int')
return a numpy array and an int respectively.Now, why don't we do the same thing for creating shogun objects via factories? (In Python)
create_kernel('GaussianKernel')
->create('GaussianKernel')
That should be possible using exactly the same mechanics as in
get
, or do I get this wrong? @gf712 Maybe you can provide pointers for a student to do thisThe text was updated successfully, but these errors were encountered: