waxmorph.torch.graph.build_node_features#
- waxmorph.torch.graph.build_node_features(c, particle_count, device=None)[source]#
Return float concentrations as
[N, C], promoting[N]to[N, 1].Nonpositive
particle_countuses all rows;devicedefaults from the input.Examples
>>> c = torch.tensor([0.2, 0.4, 0.8]) >>> print(build_node_features(c, 3).tolist()) [[0.20000000298023224], [0.4000000059604645], [0.800000011920929]]