Skip to content

yhwang/im2txt-inference

Repository files navigation

Python Flask for Show and Tell Inference Mode

This application runs the show and tell pretained model and serves the inference requests.

Run the app locally

  1. Install Python
  2. cd into this project's root directory
  3. Run pip install -r requirements.txt to install the app's dependencies
  4. Run python concat_chkp.py to concatenate the checkpoint chunks
  5. Run python app.py
  6. Access the running app in a browser at http://localhost:5000
  7. The default ID/Passwd is admin/time4fun

Run the app in IBM Cloud

  1. Log into IBM Cloud
  2. Create a Python Flask app with a unique app name and a unique host name
  3. Go to your workstation, Install Python
  4. cd into this project's root directory
  5. Run pip install -r requirements.txt to install the app's dependencies
  6. Run python concat_chkp.py to concatenate the checkpoint chunks
  7. Update manifest.yml with your app name and host name
  8. Upload the app to IBM Cloud, as described in https://console.bluemix.net/docs/starters/upload_app.html
  9. Access the running app in a browser at https://yourhostname.mybluemix.net/
  10. The default ID/Passwd is admin/time4fun

The source code of 'Show and Tell' model

The original source code of 'Show and Tell' model is from here. The only modification is to change the folder into a Python module.