{"id":16525626,"url":"https://github.com/camdavidsonpilon/lifelike","last_synced_at":"2025-03-21T09:30:45.625Z","repository":{"id":66073630,"uuid":"202424456","full_name":"CamDavidsonPilon/lifelike","owner":"CamDavidsonPilon","description":"WIP predicted survival functions ","archived":false,"fork":false,"pushed_at":"2019-08-29T19:30:40.000Z","size":1705,"stargazers_count":37,"open_issues_count":2,"forks_count":4,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-03-17T23:38:58.908Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Python","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/CamDavidsonPilon.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,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-08-14T20:53:37.000Z","updated_at":"2025-03-14T02:01:39.000Z","dependencies_parsed_at":null,"dependency_job_id":"ea399fab-bebd-46ea-bc54-c08c3754b1f8","html_url":"https://github.com/CamDavidsonPilon/lifelike","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/CamDavidsonPilon%2Flifelike","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CamDavidsonPilon%2Flifelike/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CamDavidsonPilon%2Flifelike/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CamDavidsonPilon%2Flifelike/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/CamDavidsonPilon","download_url":"https://codeload.github.com/CamDavidsonPilon/lifelike/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244771371,"owners_count":20507795,"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":[],"created_at":"2024-10-11T17:04:21.008Z","updated_at":"2025-03-21T09:30:44.996Z","avatar_url":"https://github.com/CamDavidsonPilon.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n## Lifelike\n\nSimple neural network approach to predicting survival curves based on maximizing the likelihood. See introduction blog article [Non-parametric survival function prediction\n](https://dataorigami.net/blogs/napkin-folding/non-parametric-survival-function-prediction).\n\n\n```python\nfrom jax.experimental.stax import Dense, Dropout, Tanh\nfrom jax.experimental import optimizers\n\nimport lifelike.losses as losses\nfrom lifelike import Model\nfrom lifelike.callbacks import ModelCheckpoint, Logger\nfrom lifelike.utils import dump, load\n\n\nmodel = Model([\n    Dense(20), Tanh,\n    Dense(16), Tanh,\n    Dropout(),\n    Dense(10),\n])\n\n\nmodel.compile(optimizer=optimizers.adam,\n              loss=losses.NonParametric(),\n              weight_l2=0.1, smoothing_l2=10.0)\n\nmodel.fit(x_train, t_train, e_train,\n    epochs=1000,\n    batch_size=32,\n    callbacks=[ModelCheckpoint(\"filename.pickle\"), Logger()]\n)\n\nmodel.predict(x_novel)\n\n\n# serialization\ndump(model, \"filename.pickle\")\nmodel = load(\"filename.pickle\")\nmodel.fit(...)\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcamdavidsonpilon%2Flifelike","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcamdavidsonpilon%2Flifelike","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcamdavidsonpilon%2Flifelike/lists"}