Get rid of all the commas in your file (i.e. use only whitespace as the separator) and then use Graph.Read_Ncol. This should do the trick. The numeric IDs in your files will be assigned to the name vertex attribute and the edge weights will be stored in the weight edge attribute.