{"id":21285828,"url":"https://github.com/heatingma/mnist_generate","last_synced_at":"2025-12-30T18:12:14.354Z","repository":{"id":190372826,"uuid":"646683614","full_name":"heatingma/MNIST_GENERATE","owner":"heatingma","description":"Multiple Generation Models for MNIST Data Based on the MNIST Dataset","archived":false,"fork":false,"pushed_at":"2023-12-20T11:09:57.000Z","size":166711,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-22T05:18:09.722Z","etag":null,"topics":["mnist-classification","mnist-dataset","mnist-generation"],"latest_commit_sha":null,"homepage":"","language":"Python","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/heatingma.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}},"created_at":"2023-05-29T05:26:29.000Z","updated_at":"2023-08-29T10:00:29.000Z","dependencies_parsed_at":"2023-08-24T11:07:38.428Z","dependency_job_id":null,"html_url":"https://github.com/heatingma/MNIST_GENERATE","commit_stats":null,"previous_names":["heatingma/mnist_generate"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heatingma%2FMNIST_GENERATE","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heatingma%2FMNIST_GENERATE/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heatingma%2FMNIST_GENERATE/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heatingma%2FMNIST_GENERATE/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/heatingma","download_url":"https://codeload.github.com/heatingma/MNIST_GENERATE/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243746238,"owners_count":20341204,"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":["mnist-classification","mnist-dataset","mnist-generation"],"created_at":"2024-11-21T11:25:51.834Z","updated_at":"2025-12-30T18:12:14.312Z","avatar_url":"https://github.com/heatingma.png","language":"Python","readme":"### 说明文档\n\n    文件说明：\n\n        train_func.py 文件用于训练模型参数\n        module.py 文件是我们的神经网络模型\n        utils.py 文件是一些函数，主要用于获得一些输出图像\n        aigcmn.py 文件中的接口类AiGcMn实现了输入n维tensor\n            （n是batch的大小，每个整数在0~9范围内，代表需要生成的数字），输出n*1*28*28的tensor\n\n    文件夹说明\n        data文件夹 是MNIST原始数据集\n        weights文件夹 存放了预训练参数\n        example文件夹 存放了我们训练时获得的一些图片信息\n\n### AiGcMn接口说明\n    \n    \n    \n```python\n    # AiGcMn 提供generate接口，支持随机输入label生成对应随机的MNIST数字\n    # generate 函数原型如下\n    generate(self, label:torch.Tensor, retrain=True, mode=\"all\", show=False, pretrain=\"1\")\n    \"\"\"\n        label: 输入的标签\n        retrain: 是否重新训练，\n        mode: 重新训练的模式\n        show: 是否展示图片/保存图片\n        pretrain: 由于我们设计了3种不同的网络，因此提供3种选择\n    \"\"\"\n```\n\n### 使用样例\n\n```python\n    from aigcmn import AiGcMn\n    import torch\n    ai = AiGcMn()\n    label = torch.randint(low=0,high=10,size=(1,100)).squeeze()\n    ai.generate(label)\n```\n\n### 结果展示\n\n\u003cdiv\u003e\u003ccenter\u003e\n\u003cimg src=example/1_after_all_optimize.png width=100% height=100% \u003e\n\u003cbr\u003e\n\u003cstrong\u003e\u003cfont face=\"仿宋\" size=2\u003e方法1生成的MNIST数字结果\u003c/font\u003e\n\u003c/strong\u003e\n\u003c/center\u003e\u003c/div\u003e","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fheatingma%2Fmnist_generate","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fheatingma%2Fmnist_generate","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fheatingma%2Fmnist_generate/lists"}