I decided to go with the approach of drawing from GHub data/source code, so now I have:
import nmpi
c = nmpi.Client("rjjarvis")
token = c.token
collabs = c.my_collabs()
job_id = c.submit_job(source="https://github.com/russelljjarvis/HippNetTE.git",
platform=nmpi.SPINNAKER,
collab_id=5458,
inputs=["https://github.com/russelljjarvis/HippNetTE/blob/master/wire_map_online.p"],
command="HippNetTE/neuromophic.py")
c.job_status(job_id)
job = c.get_job(job_id, with_log=True)
from pprint import pprint
pprint(job)
filenames = c.download_data(job, local_dir=".")
print(filenames)
The script returns:
python submit.py
Job submitted
{'code': 'https://github.com/russelljjarvis/HippNetTE.git',
'collab_id': '5458',
'command': 'neuromophic.py',
'hardware_config': {'resource_allocation_id': 202},
'hardware_platform': 'SpiNNaker',
'id': 120426,
'input_data': [{'id': 65091,
'resource_uri': '/api/v2/dataitem/65091',
'url': 'https://github.com/russelljjarvis/HippNetTE/blob/master/wire_map_online.p'}],
'log': '',
'output_data': [],
'provenance': None,
'resource_uri': '/api/v2/queue/120426',
'resource_usage': None,
'status': 'submitted',
'tags': [],
'timestamp_completion': None,
'timestamp_submission': '2018-08-13T02:25:20.303038+00:00',
'user_id': '302429'}
[]
Is there a way of testing what paths are visible to the machine I am uploading to? Like a way of running os.system('ls *')
from the server? I am unsure if I should be supplying absolute or relative URL paths as the input.
ie
inputs=["https://github.com/russelljjarvis/HippNetTE/blob/master/wire_map_online.p"],
command=["HippNetTE/neuromophic.py")
```,
or:
command=[“neuromophic.py”)
inputs=[“wire_map_online.p”],
as if I had run ```git clone https://github.com/russelljjarvis/HippNetTE.git; cd HippNetTE``` on a server.
Also how far off is the new feature you allude to in GH issue 92?
"
Note that we are planning a feature which would avoid you having to create and upload the archive yourself, see https://github.com/HumanBrainProject/hbp-neuromorphic-client/issues/92"