Script generated from AppiumStudio is not getting executed in pycharm

I am trying to execute the script generated from AppiumStudio in pycharm.
Script gets executed without error/s when AppiumStudio is Open.
But, when Appium Studio is closed , and script is executed from pycharm , it throws the following error:

/Library/Frameworks/Python.framework/Versions/2.7/bin/python2.7 /Users/bkamath/PycharmProjects/Appium/AppiumIos.py
Traceback (most recent call last):
File “/Users/bkamath/PycharmProjects/Appium/AppiumIos.py”, line 22, in
driver = webdriver.Remote(‘http://localhost:4723/wd/hub’, dc)
File “/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/appium/webdriver/webdriver.py”, line 36, in init
super(WebDriver, self).init(command_executor, desired_capabilities, browser_profile, proxy, keep_alive)
File “/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/selenium/webdriver/remote/webdriver.py”, line 154, in init
self.start_session(desired_capabilities, browser_profile)
File “/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/selenium/webdriver/remote/webdriver.py”, line 243, in start_session
response = self.execute(Command.NEW_SESSION, parameters)
File “/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/selenium/webdriver/remote/webdriver.py”, line 310, in execute
response = self.command_executor.execute(driver_command, params)
File “/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/selenium/webdriver/remote/remote_connection.py”, line 466, in execute
return self._request(command_info[0], url, body=data)
File “/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/selenium/webdriver/remote/remote_connection.py”, line 528, in _request
resp = opener.open(request, timeout=self._timeout)
File “/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py”, line 429, in open
response = self._open(req, data)
File “/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py”, line 447, in _open
‘_open’, req)
File “/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py”, line 407, in _call_chain
result = func(*args)
File “/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py”, line 1228, in http_open
return self.do_open(httplib.HTTPConnection, req)
File “/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py”, line 1198, in do_open
raise URLError(err)
urllib2.URLError: <urlopen error [Errno 61] Connection refused>

Process finished with exit code 1

Appium Studio has to remain open…
Appium Studio has a UI but it’s running an embedded server (so you don’t need to run standard appium)

Hello, I don’t quite understand what you mean. What do I need to do? Thank you

There is no need to standard appium and we just have to keep Appium Studio running and then execute script