18 Jan 2021 |
hugogranstrom | Yeah I'll stick to my Tensors as long as I can | 11:25:15 |
hugogranstrom | Btw couldn't get toTorchView to work yesterday when I wanted to try passing an IntRefArray to a function | 11:26:13 |
hugogranstrom | Oh no wait, I might not have compiled ut with arc... | 11:26:40 |
hugogranstrom | Nope didn't make a difference: \raw_bindings\tensors.nim(72, 14) Error: invalid type: 'lent UncheckedArray[int64]' in this context: 'proc (ar: ArrayRef[system.int64]): ptr UncheckedArray[int64]{.cdecl, noSideEffect.}' for proc | 11:29:03 |
hugogranstrom | * Nope didn't make a difference: \raw_bindings\tensors.nim(72, 14) Error: invalid type: 'lent UncheckedArray[int64]' in this context: 'proc (ar: ArrayRef[system.int64]): ptr UncheckedArray[int64]{.cdecl, noSideEffect.}' for proc | 11:30:59 |
hugogranstrom | This was when running poc03 | 11:31:09 |
mratsim | what if you pass --experimental:views | 11:55:10 |
mratsim | we might need a "tensors.nim.cfg" with --experimental:views" like I did for interop | 11:56:06 |
hugogranstrom | Ah yes that solved it, don't know why I thought it was already enabled in some config file. Now the c++ compiler is complaining instead though | 11:59:30 |
mratsim | It was but in a .nims file | 12:00:18 |
mratsim | in flambeau .nims, I deleted it because those are applied only if you compile from the project directory | 12:00:45 |
mratsim | and would have to be copy-pasted if you use flambeau in your own code for example | 12:01:04 |
mratsim | I deleted it when i introduced interop.nim.cfg but forgot about ArrayRef | 12:01:22 |
hugogranstrom | Ok, that might have been it then | 12:02:37 |
hugogranstrom | The part that c++ is complaining about seems to be T4_ = (NI64*)0;
T4_ = t__9bjO9cCSag10Z9adt9cTzQW9a4A.sizes().data(); | 12:08:10 |
hugogranstrom | On the second line it gives this error: error C2440: '=': cannot convert from 'const T *' to 'NI64 *'
with
[
T=int64_t
] | 12:08:44 |
mratsim | try with noInit on "data" | 12:11:06 |
hugogranstrom | Didn't solve it :/ | 12:11:56 |
mratsim | can you create a gist or a branch with the issue, will look int he evening | 12:13:17 |
hugogranstrom | It's in the current master | 12:14:10 |
hugogranstrom | Can write up an issue in an hour or so | 12:15:52 |
| amysdante joined the room. | 14:15:04 |
hugogranstrom | From what I've been able to google myself to, it has to do with the fact that ArrayRef.data gives us a const ptr to the data. But we have a non-const ptr as the type of our variable. And the variable seems to be initialized even though I added noInit on data and sizes | 14:57:12 |
| ShalokShalom#6109 changed their profile picture. | 16:02:59 |
| konsumlamm joined the room. | 17:16:43 |
| Awici joined the room. | 20:54:22 |
| awici joined the room. | 20:55:20 |
| Mini joined the room. | 21:23:08 |
| cji joined the room. | 21:58:40 |
19 Jan 2021 |
Quibono | Redacted or Malformed Event | 00:42:07 |