{"id":13487134,"url":"https://github.com/keplr-io/hera","last_synced_at":"2026-02-19T16:39:23.442Z","repository":{"id":75910236,"uuid":"63009043","full_name":"keplr-io/hera","owner":"keplr-io","description":"Train/evaluate a Keras model, get metrics streamed to a dashboard in your browser.","archived":false,"fork":false,"pushed_at":"2017-05-24T22:26:10.000Z","size":156,"stargazers_count":487,"open_issues_count":5,"forks_count":47,"subscribers_count":19,"default_branch":"master","last_synced_at":"2024-10-30T22:39:49.709Z","etag":null,"topics":["dashboard","deep-learning","visualization"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/keplr-io.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2016-07-10T16:55:41.000Z","updated_at":"2024-07-25T15:10:44.000Z","dependencies_parsed_at":"2024-01-03T02:30:16.060Z","dependency_job_id":"e3d740ff-7e51-488d-8aa3-bcfe3e926aa4","html_url":"https://github.com/keplr-io/hera","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/keplr-io%2Fhera","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/keplr-io%2Fhera/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/keplr-io%2Fhera/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/keplr-io%2Fhera/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/keplr-io","download_url":"https://codeload.github.com/keplr-io/hera/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245927332,"owners_count":20695216,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["dashboard","deep-learning","visualization"],"created_at":"2024-07-31T18:00:55.744Z","updated_at":"2025-03-27T21:31:54.462Z","avatar_url":"https://github.com/keplr-io.png","language":"JavaScript","funding_links":[],"categories":["The Data Science Toolbox","JavaScript","Deep Learning","Tensor Flow"],"sub_categories":["Deep Learning Packages","TensorFlow","Automated Machine Learning"],"readme":"# Hera\n\nTrain/evaluate a Keras model, get metrics streamed to a dashboard in your browser.\n\n![demo](https://j.gifs.com/3lO37p.gif)\n\n## Setting up\n\n### Step 1. Plant the spy\n\n**Install the package**\n\n```\n\n    pip install heraspy\n\n```\n\n**Add the callback**\n\n```python\n\n    herasCallback = HeraCallback(\n        'model-key',\n        'localhost',\n        4000\n    )\n\n    model.fit(X_train, Y_train, callbacks=[herasCallback])\n\n```\n\n### Step 2. Start the server\n\nGit clone this repository, then run\n\n```\n\n    cd server\n    npm install\n    gulp # optional, for now the build file is kept track in git\n    node build/server\n```\n\n\n### Step 3. Start the dashboard\n\n```\n\n    cd client\n    npm install\n    npm start\n```\n\n\n## Using RabbitMQ\n\n\nBy default hera uses socket.io for messaging - both from keras callback to server, and from server to dashboard. This is to minimize the number of things one needs to install before getting up and running with hera.\n\nHowever, in production socket.io is outperformed by a number of alternatives, also it is good in general to decouple the server-client communication from the inter-process communitation (python -\u003e node) so that each can be managed and optimized independently.\n\nTo demonstrate how this works Hera ships with the option to use rabbitMQ for interprocess communication. Here's how to use it.\n\n**In your model file**\n\n```python\n\n    from heraspy.callback import HeraCallback\n    from heraspy.dispatchers.rabbitmq import get_rabbitmq_dispatcher\n\n    herasCallback = HeraCallback(\n        'model-key', 'localhost', 4000,\n        dispatch=get_rabbitmq_dispatcher(\n          queue='[my-queue]',\n          amqps_url='amqps://[user]:[pass]@my-amqp-address'\n        )\n    )\n\n```\n\n\n**In server/src/server.js**\n\nReplace the only line in the file with\n```js\n\n    getServer({\n        dispatcher: 'rabbitmq',\n        dispatcherConfig: {\n            amqpUrl: 'amqps://[user]:[pass]@my-amqp-address',\n            amqpQueue: '[my-queue]'\n        }\n    }).start();\n\n\n```\n\nThat's it! Now communication from the python process and the node webserver process goes through rabbitmq.\n\n## Credits\n\nAside from the obvious ones:\n\n- The dashboard is built on [React-Redux starter kit](https://github.com/davezuko/react-redux-starter-kit)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkeplr-io%2Fhera","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkeplr-io%2Fhera","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkeplr-io%2Fhera/lists"}