Geometric Deep Learning for Flux
GeometricFlux is a geometric deep learning library for Flux. This library aims to be compatible with packages from JuliaGraphs ecosystem and have support of CUDA GPU acceleration with CUDA. Message passing scheme is implemented as a flexbile framework and fused with Graph Network block scheme. GeometricFlux is compatible with other packages that are composable with Flux.
Suggestions, issues and pull requsts are welcome.
Construct GCN layer:
graph = # can be adj_mat, adj_list, simple_graphs... GCNConv([graph, ]input_dim=>output_dim, relu)
model = Chain(GCNConv(g, 1024=>512, relu), Dropout(0.5), GCNConv(g, 512=>128), Dense(128, 10), softmax) ## Loss loss(x, y) = logitcrossentropy(model(x), y) accuracy(x, y) = mean(onecold(model(x)) .== onecold(y))
ps = Flux.params(model) train_data = [(train_X, train_y)] opt = ADAM(0.01) evalcb() = @show(accuracy(train_X, train_y))
Flux.train!(loss, ps, train_data, opt, cb=throttle(evalcb, 10))