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
from python import Python as py
let torch = py.import_module("torch")
let pd = py.import_module("pandas")
let plt = py.import_module("matplotlib.pyplot")
let np = py.import_module("numpy")
let MATRIX = torch.tensor([[1, 2], [3, 4]])
print(MATRIX)
It'll pop up an error says
error: Expression [4] wrapper:7:1: no viable expansions found
fn __lldb_expr__4(inout __mojo_repl_arg: __mojo_repl_context__):
^
Expression [4] wrapper:9:28: call expansion failed - no concrete specializations
__mojo_repl_expr_impl__(__mojo_repl_arg, __get_address_as_lvalue(__mojo_repl_arg.`torch`.load().address), __get_address_as_lvalue(__mojo_repl_arg.`plt`.load().address), __get_address_as_lvalue(__mojo_repl_arg.`pd`.load().address), __get_address_as_lvalue(__mojo_repl_arg.`np`.load().address))
^
Expression [4] wrapper:13:1: no viable expansions found
def __mojo_repl_expr_impl__(inout __mojo_repl_arg: __mojo_repl_context__, inout `torch`: __mojo_repl_persistent_var_type_torch, inout `plt`: __mojo_repl_persistent_var_type_plt, inout `pd`: __mojo_repl_persistent_var_type_pd, inout `np`: __mojo_repl_persistent_var_type_np) -> None:
^
Expression [4] wrapper:20:26: call expansion failed - no concrete specializations
__mojo_repl_expr_body__()
^
Expression [4] wrapper:16:3: no viable expansions found
def __mojo_repl_expr_body__() -> None:
^
Expression [4]:1:27: call expansion failed - no concrete specializations
let MATRIX = torch.tensor([[1, 2], [3, 4]])
^
expression failed to parse (no further compiler diagnostics)
And I think the problem is that mojo couldnt pass list in lists types of data
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Apparently when I run this code:
It'll pop up an error says
And I think the problem is that mojo couldnt pass list in lists types of data
Beta Was this translation helpful? Give feedback.
All reactions