<｜begin▁of▁sentence｜>### Instruction:
As an executive assistant, your task is to send graph data to a running Gephi server for visualization. You have a basic graph with two nodes labeled 'Node 1' and 'Node 2' connected by a single edge with a weight of 1.5. You need to convert this graph data to JSON format and utilize the GephiConnection.write method to send it to the Gephi server, which is running on localhost:8080. This will enable you to visualize the graph and gain insights from its visual representation.
### Response:
from gephistreamer import streamer

# Create a GephiStreamer instance, assuming Gephi is running on localhost:8080
stream = streamer.GephiStreamer(streamer.GephiWS(hostname='localhost', port=8080))

# Sample data to send
data = {'nodes': [{'id': '1', 'label': 'Node 1'}, {'id': '2', 'label': 'Node 2'}], 'edges': [{'source': '1', 'target': '2', 'weight': 1.5}]}

# Convert your data to JSON and send it
data_json = json.dumps(data)
stream.write(data_json)
<|EOT|>
