sahooora commented on pull request #8070:
URL: https://github.com/apache/tvm/pull/8070#issuecomment-844165770


   > I don't think %dense/kernel is a valid variable name. where did that come 
from? try replacing the slash with an underscore. What importer are you using?
   > […](#)
   > On Wed, May 19, 2021, 2:03 AM sahooora ***@***.***> wrote: Thanks 
@gussmith23 <https://github.com/gussmith23> . My error which is related to 
custom data type has been solved. Now for the following snippet code, I get an 
error that is not related to custom data type: r = """ #[version = "0.0.5"] def 
@main (%input_1: Tensor[(100, 128, 3), custom_float_st128], %dense/kernel:0: 
Tensor[(128, 6), custom_float_st128], %dense/bias:0: Tensor[(6), 
custom_float_st128], %lstm_W: Tensor[(1, 512, 3), custom_float_st128], %lstm_R: 
Tensor[(1, 512, 128), custom_float_st128], %lstm_B: Tensor[(1, 1024), 
custom_float_st128]) { ... } """ module = tvm.parser.fromtext(source = r) 
Error: error: expected a local variable found `/` --> from_string:3:75 | 3 | 
def @main (%input_1: Tensor[(100, 128, 3), custom_float_st128], 
%dense/kernel:0: Tensor[(128, 6), custom_float_st128], %dense/bias:0: 
Tensor[(6), custom_float_st128], %lstm_W: Tensor[(1, 512, 3), 
custom_float_st128], %lstm_R: Tensor[(1, 512, 128), cu
 stom_float_st128], %lstm_B: Tensor[(1, 1024), custom_float_st128]) { | ^ note: 
run with `TVM_BACKTRACE=1` environment variable to display a backtrace. Any 
idea? — You are receiving this because you were mentioned. Reply to this email 
directly, view it on GitHub <[#8070 
(comment)](https://github.com/apache/tvm/pull/8070#issuecomment-843901916)>, or 
unsubscribe 
<https://github.com/notifications/unsubscribe-auth/AAJFZAN5PMM3URRN4WXOK5DTON5F5ANCNFSM45DBBYRQ>
 .
   
   I've replaced slash with underscore and this time I got the following error:
   
   ```
   error: failed to parse type found Token(span=Span(SourceName(from_string, 
0x31aa140), 3, 3, 83, 84), token_type=Integer, data=0)
    --> from_string:3:83
      |  
    3 |  def @main (%input_1: Tensor[(100, 128, 3), custom_float_st128], 
%dense_kernel:0: Tensor[(128, 6), custom_float_st128], %dense_bias:0: 
Tensor[(6), custom_float_st128], %lstm_W: Tensor[(1, 512, 3), 
custom_float_st128], %lstm_R: Tensor[(1, 512, 128), custom_float_st128], 
%lstm_B: Tensor[(1, 1024), custom_float_st128]) {
      |                                                                         
           ^                                                                    
                                                                                
                                                                                
       
   note: run with `TVM_BACKTRACE=1` environment variable to display a backtrace.
   ```
   
   I also tried with another model with a variable name such as: 
%project_inp.bias and I got the same error:
   ```
   error: expected a local variable found `.`
   ...
   ```
   
   I'm using `relay.frontend.from_onnx` for importing my onnx model.
   
   Thanks


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to