tech-srl / code2vec

TensorFlow code for the neural network presented in the paper: "code2vec: Learning Distributed Representations of Code"
https://code2vec.org
MIT License
1.1k stars 286 forks source link

Training error #156

Closed colebuckleyy closed 2 years ago

colebuckleyy commented 2 years ago

Hello, I successfully preprocessed my dataset to work with code2vec but when I try running the train.sh script I run into a few errors, is there any way I can fix this? code2vec_error

urialon commented 2 years ago

Hi @colebuckleyy , Thank you for your interest in our work!

  1. Do you successfully manage to load our preprocessed datasets?
  2. Which operating system did you run this on?
colebuckleyy commented 2 years ago

Ok well apparently my preprocessed data somehow got corrupted before I attempted to train and that is why I received those errors but I have one more question. How could I go about labelling the dataset/vectors if I wanted to use this for classification?

urialon commented 2 years ago

The method name is taken as the label for classification. So if you retain the same data format, you can replace the method name in the processed data with any label.

See also: https://github.com/tech-srl/code2vec#extending-to-other-languages

Best, Uri

colebuckleyy commented 2 years ago

Ah I see, thank you