{"id":19721082,"url":"https://github.com/paramsiddharth/titanic-prediction","last_synced_at":"2026-06-12T11:31:24.294Z","repository":{"id":109335557,"uuid":"324147079","full_name":"paramsiddharth/titanic-prediction","owner":"paramsiddharth","description":"A web application that predicts the survival of a Titanic passenger.","archived":false,"fork":false,"pushed_at":"2020-12-24T18:01:47.000Z","size":885,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-09-18T00:48:00.130Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Jupyter Notebook","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/paramsiddharth.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2020-12-24T12:04:36.000Z","updated_at":"2020-12-24T18:01:49.000Z","dependencies_parsed_at":"2023-03-15T00:01:21.315Z","dependency_job_id":null,"html_url":"https://github.com/paramsiddharth/titanic-prediction","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/paramsiddharth/titanic-prediction","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paramsiddharth%2Ftitanic-prediction","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paramsiddharth%2Ftitanic-prediction/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paramsiddharth%2Ftitanic-prediction/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paramsiddharth%2Ftitanic-prediction/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/paramsiddharth","download_url":"https://codeload.github.com/paramsiddharth/titanic-prediction/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paramsiddharth%2Ftitanic-prediction/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34243051,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-12T02:00:06.859Z","response_time":109,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":[],"created_at":"2024-11-11T23:13:17.895Z","updated_at":"2026-06-12T11:31:24.273Z","avatar_url":"https://github.com/paramsiddharth.png","language":"Jupyter Notebook","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Titanic Survival Prediction\r\nA web application that predicts the survival of a Titanic passenger.\r\n\r\nThe back-end is made using Flask in Python, and located inside `model_service`.  \r\nThe front-end is made using React in NodeJS, and located inside `react_frontend`.\r\n\r\n## Development (Back-end)\r\nGo to the back-end directory.\r\n``` bash\r\ncd model_service\r\n```\r\n\r\nIt is suggested to create and activate a Python virtual environment before proceeding, to avoid polluting the local Python installation.\r\n``` bash\r\npython -m venv env\r\n. ./env/bin/activate # This step may be different in other operating systems\r\n```\r\n\r\nInstall `wheel`, which is required for the installation of many dependencies and needs to be installed prior to them.\r\n``` bash\r\npip install wheel\r\n```\r\n\r\nInstall the PyPI requirements as needed.\r\n``` bash\r\npip install requirements.txt\r\n```\r\n\r\nThere are 2 `requirements.txt` files, one for generating the model, and another for running the back-end server in Flask (Python).\r\n- Model-only dependencies: `model_service/model/requirements.txt`\r\n- Model and server dependencies: `model_service/requirements.txt`\r\n\r\nThe former is just a subset of the latter. Hence, the server `requirements.txt` is preferred.\r\n\r\nBefore starting the server, the `FLASK_RUN_HOST` and `FLASK_RUN_PORT` environment variables should be set to the desired host URL and port. If not, default values will be used.\r\n\r\nThe server may either be started using the `flask` command or manually executing `app.py`. Both will behave differently if the environment variables aren't assigned values.\r\n- ``` bash\r\n  # If variables are not set, uses 127.0.0.1 and 5000 as the default values\r\n  flask run\r\n  ```\r\n- ``` bash\r\n  # If variables are not set, uses 0.0.0.0 and 3000 as the default values\r\n  python app.py\r\n  ```\r\n- ``` bash\r\n  # Values may be supplied separately to 'flask run'\r\n  flask run --host=0.0.0.0 --port=3000\r\n  ```\r\n\r\nThis will start the server. Using `python app.py` is preferred, which would start the server on http://localhost:3000/.\r\n\r\n## Development (Front-end)\r\nGo to the front-end directory.\r\n``` bash\r\ncd react_frontend\r\n```\r\n\r\nInstall the Node.js modules using `package.json` using either of the following commands:\r\n- ``` bash\r\n  npm ci\r\n  ```\r\n- ``` bash\r\n  npm install\r\n  ```\r\n\r\nThe `REACT_APP_API_URL` environment variable must be set to the API server URL. By default, the React application assumes the server to be running on http://localhost:3000/.\r\n\r\nThe development server will run on http://localhost:3006/ by default. To start it, execute:\r\n``` bash\r\nnpm start\r\n```\r\n\r\nTo build a production-optimized build for the React application, use the following command. Make sure to set the `REACT_APP_API_URL` variable to point to the API URL before building.\r\n``` bash\r\nnpm run build\r\n```\r\n\r\nThe production build will be created in the `react_frontend/build` directory and may then be statically served.\r\n\r\n# Made with ❤ by [Param](http://www.paramsid.com).","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fparamsiddharth%2Ftitanic-prediction","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fparamsiddharth%2Ftitanic-prediction","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fparamsiddharth%2Ftitanic-prediction/lists"}