<SYSTEM_TASK:>
Given the following text description, write Python code to implement the functionality described below step by step
<END_TASK>
<USER_TASK:>
Description:
 AlientVault OTX <> Graphistry
Step1:  Start
Step2:  Continue
<ASSISTANT_TASK:>
Python Code:
#!pip install graphistry -q
#!pip install OTXv2 -q
import graphistry
import pandas as pd
from OTXv2 import OTXv2, IndicatorTypes
from gotx import G_OTX 
# To specify Graphistry account & server, use:
# graphistry.register(api=3, username='...', password='...', protocol='https', server='hub.graphistry.com')
# For more options, see https://github.com/graphistry/pygraphistry#configure
otx = OTXv2("MY_KEY")
g_otx = G_OTX(graphistry, otx)
Explanation: AlientVault OTX <> Graphistry: LockerGoga investigation
End of explanation
lockergoga_pulses = otx.search_pulses('LockerGoga').get('results')
lockergoga_pulses_df = g_otx.pulses_to_df(lockergoga_pulses)
lockergoga_indicators_df = g_otx.pulses_to_indicators_df(lockergoga_pulses)
g = g_otx.indicatormap(lockergoga_pulses_df, lockergoga_indicators_df)
g.plot()
Explanation: Start: rough hits
We find there are 3 clusters of activity
End of explanation
ip_pulses = otx.get_indicator_details_by_section(IndicatorTypes.IPv4, lockergoga_indicators_df[lockergoga_indicators_df['indicator_type'] == 'IPv4'].values[0][0])
ip_pulses_df = g_otx.indicator_details_by_section_to_pulses_df(ip_pulses)
ip_indicators_df = g_otx.indicator_details_by_section_to_indicators_df(ip_pulses)
g_otx.indicatormap(ip_pulses_df, ip_indicators_df).plot()
Explanation: Continue: Expand on IPv4 hits
Let's expand the small cluster related to "Powershell Backdoor calling back on port 443". Use the OTX API to get other pulses containing the same IP address and then expand them and create a new graph
End of explanation
<END_TASK>